zxl
2026-03-25 d29d77e91951e30abba6596359b138bc4c6ac108
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
<template>
  <a-card :bordered="false">
    <!-- 操作按钮区域 -->
 
    <!-- table区域-begin -->
    <div>
      <a-table
        ref="table"
        size="middle"
        bordered
        rowKey="id"
        :scroll="{x: true}"
        :columns="columns"
        :dataSource="dataSource"
        :pagination="ipagination"
        :loading="loading"
        @change="handleTableChange"
      >
        <span slot="action" slot-scope="text, record">
          <a @click="handleEdit(record)">编辑</a>
        </span>
      </a-table>
    </div>
    <!-- table区域-end -->
 
    <!-- 表单区域 -->
    <sys-car-model-modal ref="modalForm" @ok="modalFormOk"></sys-car-model-modal>
  </a-card>
</template>
 
<script>
import SysCarModelModal from './modules/SysCarModelModal'
import { JeecgListMixin } from '@tievd/cube-block/lib/mixins/JeecgListMixin'
 
export default {
  name: 'SysCarModelList',
 
  mixins: [JeecgListMixin],
 
  components: {
    SysCarModelModal
  },
 
  data() {
    return {
      description: 'SysCarModel列表',
      // 表头
      // 列定义
      columns: [
        {
          title: '序号',
          dataIndex: '',
          key: 'rowIndex',
          width: 60,
          align: 'center',
          customRender: function(t, r, index) {
            return parseInt(index) + 1
          }
        },
          {
            title: '车型',
            align: 'center',
            dataIndex: 'modelName',
          },
          {
            title: '储油量(升)',
            align: 'center',
            dataIndex: 'oilCapacity',
          },
        {
          title: '操作',
          dataIndex: 'action',
          width: 150,
          align: 'center',
          scopedSlots: { customRender: 'action' }
        }
      ],
      url: {
        list: '/jyz/sysCarModel/list',
        delete: '/jyz/sysCarModel/delete',
        deleteBatch: '/jyz/sysCarModel/deleteBatch',
        exportXlsUrl: '/jyz/sysCarModel/exportXls'
      }
    }
  },
 
  methods: {},
 
  created() {}
}
</script>
<style scoped lang="less">
  @import '~@assets/less/common.less';
</style>