|
|
@ -1,4 +1,7 @@ |
|
|
|
import FineUi, {FineType} from '../../shared/FineUI'; |
|
|
|
import FineUi, {FineType} from '../../shared/FineUI'; |
|
|
|
|
|
|
|
const linkList = [ |
|
|
|
|
|
|
|
'APACHE KYLIN', 'DERBY', 'HP Vertica', 'IBM DB2', 'INFORMIX', 'Microsoft SQL Server', 'MySQL', 'Oracle', 'Privotal Greenplum Database', 'Postgresql', 'GaussDB 200', |
|
|
|
|
|
|
|
]; |
|
|
|
export default class Select extends FineUi { |
|
|
|
export default class Select extends FineUi { |
|
|
|
public render(): FineType { |
|
|
|
public render(): FineType { |
|
|
|
return { |
|
|
|
return { |
|
|
@ -8,23 +11,36 @@ export default class Select extends FineUi { |
|
|
|
adjustYOffset: 4, |
|
|
|
adjustYOffset: 4, |
|
|
|
el: { |
|
|
|
el: { |
|
|
|
type: 'bi.button', |
|
|
|
type: 'bi.button', |
|
|
|
text: '测试', |
|
|
|
text: '新建数据连接', |
|
|
|
height: 24, |
|
|
|
height: 24, |
|
|
|
}, |
|
|
|
}, |
|
|
|
popup: { |
|
|
|
popup: { |
|
|
|
el: { |
|
|
|
el: { |
|
|
|
type: 'bi.button_group', |
|
|
|
type: 'bi.button_group', |
|
|
|
items: BI.makeArray(5, { |
|
|
|
cls:'database-link-items', |
|
|
|
|
|
|
|
items: [...BI.map(linkList, (index: number, item: string) => { |
|
|
|
|
|
|
|
return { |
|
|
|
|
|
|
|
type: 'bi.text_item', |
|
|
|
|
|
|
|
height: 24, |
|
|
|
|
|
|
|
width: 152, |
|
|
|
|
|
|
|
text: item, |
|
|
|
|
|
|
|
}; |
|
|
|
|
|
|
|
}), { |
|
|
|
type: 'bi.text_item', |
|
|
|
type: 'bi.text_item', |
|
|
|
height: 24, |
|
|
|
height: 24, |
|
|
|
width: 173, |
|
|
|
width: 152, |
|
|
|
text: 'item', |
|
|
|
text: '更多数据连接...', |
|
|
|
}), |
|
|
|
}, { |
|
|
|
|
|
|
|
type: 'bi.text_item', |
|
|
|
|
|
|
|
height: 24, |
|
|
|
|
|
|
|
width: 152, |
|
|
|
|
|
|
|
text: '其他', |
|
|
|
|
|
|
|
}], |
|
|
|
layouts: [{ |
|
|
|
layouts: [{ |
|
|
|
type: 'bi.vertical', |
|
|
|
type: 'bi.vertical', |
|
|
|
}], |
|
|
|
}], |
|
|
|
}, |
|
|
|
}, |
|
|
|
maxHeight: 200, |
|
|
|
maxHeight: 400, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}; |
|
|
|
}; |
|
|
|
} |
|
|
|
} |
|
|
|