|
@@ -17,6 +17,38 @@
|
17
|
17
|
<template #icon><close-outlined /></template>
|
18
|
18
|
</a-button>
|
19
|
19
|
</template>
|
|
20
|
+ <a-form ref="formRef" :model="searchData">
|
|
21
|
+ <a-row>
|
|
22
|
+ <a-col :span="4">
|
|
23
|
+ <a-form-item label="地区" name="cityId">
|
|
24
|
+ <a-select v-model:value="searchData.cityId" placeholder="请选择地区">
|
|
25
|
+ <a-select-option v-for="item in pageDicList.regionList" :value="item.id" :key="item.id">{{
|
|
26
|
+ item.name
|
|
27
|
+ }}</a-select-option>
|
|
28
|
+ </a-select>
|
|
29
|
+ </a-form-item>
|
|
30
|
+ </a-col>
|
|
31
|
+ <a-col :span="4">
|
|
32
|
+ <a-form-item label="粮食性质" name="lsxz">
|
|
33
|
+ <a-select v-model:value="searchData.lsxz" placeholder="请选择地区">
|
|
34
|
+ <a-select-option v-for="item in pageDicList.grainProperty" :value="item.value" :key="item.value">{{
|
|
35
|
+ item.label
|
|
36
|
+ }}</a-select-option>
|
|
37
|
+ </a-select>
|
|
38
|
+ </a-form-item>
|
|
39
|
+ </a-col>
|
|
40
|
+ <a-col :span="1">
|
|
41
|
+ <a-form-item>
|
|
42
|
+ <a-button type="primary" @click="getTableData">查询</a-button>
|
|
43
|
+ </a-form-item>
|
|
44
|
+ </a-col>
|
|
45
|
+ <a-col :span="6">
|
|
46
|
+ <a-form-item>
|
|
47
|
+ <a-button @click="resetForm">重置</a-button>
|
|
48
|
+ </a-form-item>
|
|
49
|
+ </a-col>
|
|
50
|
+ </a-row>
|
|
51
|
+ </a-form>
|
20
|
52
|
<!-- :scroll="{ x: 'calc(700px + 50%)', y: true }" -->
|
21
|
53
|
<div class="statisticsTableAll">
|
22
|
54
|
<a-table size="small" bordered :dataSource="tableData" :columns="tableColumns" :pagination="false">
|
|
@@ -32,9 +64,29 @@
|
32
|
64
|
import { ref } from 'vue'
|
33
|
65
|
import api from '@/api/RLGI/system.js'
|
34
|
66
|
|
|
67
|
+ const formRef = ref()
|
35
|
68
|
const tableData = ref([])
|
|
69
|
+ const searchData = ref({})
|
|
70
|
+ const pageDicList = ref({
|
|
71
|
+ regionList: [],
|
|
72
|
+ grainProperty: [
|
|
73
|
+ {
|
|
74
|
+ value: '6877',
|
|
75
|
+ label: '省级'
|
|
76
|
+ },
|
|
77
|
+ {
|
|
78
|
+ value: '6878',
|
|
79
|
+ label: '市级'
|
|
80
|
+ },
|
|
81
|
+ {
|
|
82
|
+ value: '6879',
|
|
83
|
+ label: '县级'
|
|
84
|
+ }
|
|
85
|
+ ]
|
|
86
|
+ })
|
36
|
87
|
const emit = defineEmits(['closeDrawer'])
|
37
|
88
|
const drawerStyle = ref({ position: 'absolute' })
|
|
89
|
+ const dicList = JSON.parse(localStorage.getItem('DICT_TYPE_TREE_DATA'))
|
38
|
90
|
|
39
|
91
|
const props = defineProps({
|
40
|
92
|
drawerInfo: {
|
|
@@ -44,7 +96,7 @@
|
44
|
96
|
})
|
45
|
97
|
const tableColumns = [
|
46
|
98
|
{ title: '序号', width: 60, key: 'INDEX', align: 'center' },
|
47
|
|
- { title: '承储企业', ellipsis: true, width: 250, key: 'orgName' },
|
|
99
|
+ { title: '承储企业', align: 'center', ellipsis: true, width: 250, key: 'orgName' },
|
48
|
100
|
{ title: '地方储备', align: 'center', children: getTableChildren('_地方储备', 'df') },
|
49
|
101
|
{ title: '省级储备', align: 'center', children: getTableChildren('_省级储备', 'sj') },
|
50
|
102
|
{ title: '市(州)级储备', align: 'center', children: getTableChildren('_市级储备', 'cj') },
|
|
@@ -84,13 +136,28 @@
|
84
|
136
|
]
|
85
|
137
|
}
|
86
|
138
|
onMounted(() => {
|
|
139
|
+ getDicList()
|
87
|
140
|
getTableData()
|
88
|
141
|
})
|
89
|
142
|
function getTableData() {
|
90
|
|
- api.getCrkKcswDatas().then((res) => {
|
|
143
|
+ api.getCrkKcswDatas(searchData.value).then((res) => {
|
91
|
144
|
tableData.value = res
|
92
|
145
|
})
|
93
|
146
|
}
|
|
147
|
+
|
|
148
|
+ // 获取字典
|
|
149
|
+ function getDicList() {
|
|
150
|
+ dicList.map((item) => {
|
|
151
|
+ if (item.dictValue == 'xzqh') {
|
|
152
|
+ item.children.map((el) => {
|
|
153
|
+ if (el.name == '青海省') {
|
|
154
|
+ pageDicList.value.regionList = el.children
|
|
155
|
+ // pageDicList.value.regionList.unshift(el)
|
|
156
|
+ }
|
|
157
|
+ })
|
|
158
|
+ }
|
|
159
|
+ })
|
|
160
|
+ }
|
94
|
161
|
// 全屏显示
|
95
|
162
|
function fullScreen() {
|
96
|
163
|
if (drawerStyle.value) {
|
|
@@ -99,7 +166,19 @@
|
99
|
166
|
drawerStyle.value = { position: 'absolute' }
|
100
|
167
|
}
|
101
|
168
|
}
|
|
169
|
+ function resetForm() {
|
|
170
|
+ formRef.value.resetFields()
|
|
171
|
+ getTableData()
|
|
172
|
+ }
|
102
|
173
|
function onClose() {
|
103
|
174
|
emit('closeDrawer')
|
104
|
175
|
}
|
105
|
176
|
</script>
|
|
177
|
+<style scoped lang="less">
|
|
178
|
+ .ant-form-item {
|
|
179
|
+ margin-left: 10px;
|
|
180
|
+ }
|
|
181
|
+ .ant-btn {
|
|
182
|
+ margin: 0 15px;
|
|
183
|
+ }
|
|
184
|
+</style>
|