Browse Source

feat: 新建数据连接

master
alan 6 years ago
parent
commit
5d34614e42
  1. 3
      src/app/App.scss
  2. 28
      src/app/LinkSet/Select.ts
  3. BIN
      src/img/resources.png

3
src/app/App.scss

@ -38,6 +38,9 @@
border-bottom: 1px solid #e8eaed;
.select{
margin: 10px;
.database-link-items{
padding-left:10px;
}
}
}
}

28
src/app/LinkSet/Select.ts

@ -1,4 +1,7 @@
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 {
public render(): FineType {
return {
@ -8,23 +11,36 @@ export default class Select extends FineUi {
adjustYOffset: 4,
el: {
type: 'bi.button',
text: '测试',
text: '新建数据连接',
height: 24,
},
popup: {
el: {
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',
height: 24,
width: 173,
text: 'item',
}),
width: 152,
text: '更多数据连接...',
}, {
type: 'bi.text_item',
height: 24,
width: 152,
text: '其他',
}],
layouts: [{
type: 'bi.vertical',
}],
},
maxHeight: 200,
maxHeight: 400,
},
};
}

BIN
src/img/resources.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Loading…
Cancel
Save