123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293 |
- export const defaultProps = {
- children: 'children',
- label: 'label'
- }
- export const columns = (_this) => [
- {
- prop: 'aircaftCatalogCode',
- label: '飞机编号',
- width: '150px'
- },
- {
- prop: 'mechanician',
- label: '机械师'
- },
- {
- prop: 'aircaftModelName',
- label: '所属机型'
- },
- {
- prop: 'army',
- label: '所属部队'
- },
- {
- prop: 'warZone',
- label: '所属战区'
- },
- {
- prop: 'station',
- label: '驻地'
- },
- {
- prop: 'assemblyTime',
- label: '装列时间'
- },
- {
- prop: 'manufacturer',
- label: '厂家',
- width: '240px'
- },
- {
- prop: 'factoryNumber',
- label: '出厂编号',
- width: '150px'
- },
- {
- prop: 'status',
- label: '状态',
- render: (h, params) => {
- if (params.row.status == 0) {
- return h('span', { class: 'success-state' }, '服役')
- } else {
- return h('span', { class: 'warning-state' }, '退役')
- }
- }
- },
- {
- button: true,
- label: '操作',
- width: '200px',
- group: [
- {
- name: '编辑',
- type: 'text',
- round: false,
- plain: false,
- onClick: (row, index, scope) => {
- _this.handUpdate(row)
- }
- },
- {
- name: '删除',
- type: 'text',
- round: false,
- plain: false,
- onClick: (row, index, scope) => {
- _this.remove([row])
- }
- }
- ]
- }
- ]
- export const options = {
- stripe: true, // 斑马纹
- mutiSelect: true, // 多选框
- index: false, // 显示序号, 多选则 mutiSelect
- loading: false, // 表格动画
- initTable: true, // 是否一挂载就加载数据
- border: true,
- height: 'calc(100vh - 300px)'
- }
|