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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
| <template>
| <a-card class="j-address-list-right-card-box" :bordered="false">
| <a-table
| ref="table"
| size="middle"
| :row-selection="rowSelection"
| bordered
| rowKey="id"
| :columns="columns"
| :dataSource="dataSource"
| >
| </a-table>
| </a-card>
| </template>
|
| <script>
| import { getAction } from '@/api/manage'
|
| export default {
| name: 'MomBaseUnitCategoryListRight',
| components: {},
| props: ['value'],
| data() {
| return {
| description: '计量单位分类信息',
| positionInfo: {},
| dataSource: null,
| url:{
| getList:'/base/getList'
| },
| columns: [
| {
| title: '分类编码',
| width: '10%',
| align: 'center',
| dataIndex: 'code',
| },
| {
| title: '分类名称',
| width: '15%',
| align: 'center',
| dataIndex: 'name',
| key: 'name',
| },
| {
| title: '上级分类',
| width: '10%',
| align: 'center',
| dataIndex: 'codeName',
| },
| {
| title: '创建人',
| width: '10%',
| align: 'center',
| dataIndex: 'createBy',
| },
| {
| title: '创建时间',
| width: '15%',
| align: 'center',
| dataIndex: 'createTime',
| },
| {
| title: '更新人',
| width: '10%',
| align: 'center',
| dataIndex: 'updateBy',
| },
| {
| title: '更新时间',
| width: '15%',
| align: 'center',
| dataIndex: 'updateTime',
| },
| {
| title: '备注',
| width: '15%',
| align: 'center',
| dataIndex: 'remark',
| },
| ],
| }
| },
| computed: {
| rowSelection() {
| return {
| onChange: (selectedRowKeys, selectedRows) => {
| this.selectedRowKeys = selectedRowKeys
| this.selectedRows = selectedRows
| this.$emit('searchkeys', selectedRowKeys,selectedRows)
| this.ids=selectedRowKeys.join(",")
| //this.getList()
| },
| getCheckboxProps: (record) => ({
| props: {
| disabled: record.name === 'Disabled User', // Column configuration not to be checked
| name: record.name,
| },
| }),
| }
| },
| },
| created() {
| this.loadData({ id: '' })
| },
| methods: {
| loadData({ id }) {
| let momBaseUnitCategory = {
| id,
| }
| getAction(this.url.getList, momBaseUnitCategory)
| .then((res) => {
| if (res.success) {
| this.dataSource = res.result
| }
| })
| .finally(() => {
| this.loading = false
| this.cardLoading = false
| })
| // update-end- --- author:wangshuai ------ date:20200102 ---- for:传过来的部门编码为空全查
| },
|
| },
| }
| </script>
| <style>
| .j-address-list-right-card-box .ant-table-placeholder {
| min-height: 46px;
| }
| </style>
| <style scoped>
| .j-address-list-right-card-box {
| height: 100%;
| min-height: 300px;
| }
| </style>
|
|