ccf84b4d by lxs

结果确认字段查询添加参数

1 parent 7901b7d1
...@@ -99,7 +99,7 @@ const getTableData = () => { ...@@ -99,7 +99,7 @@ const getTableData = () => {
99 if (res.code == proxy.$passCode) { 99 if (res.code == proxy.$passCode) {
100 let data = res.data.records || []; 100 let data = res.data.records || [];
101 data.map(item => { 101 data.map(item => {
102 item.cellClass = item.confirmCnt>0?'':'is-regular' 102 item.cellClass = item.confirmCnt > 0 ? '' : 'is-regular'
103 }) 103 })
104 tableInfo.value.data = data; 104 tableInfo.value.data = data;
105 } else { 105 } else {
...@@ -223,7 +223,13 @@ onBeforeMount(() => { ...@@ -223,7 +223,13 @@ onBeforeMount(() => {
223 <template> 223 <template>
224 <div class="container_wrap" v-loading="loading"> 224 <div class="container_wrap" v-loading="loading">
225 <div class="table_tool_wrap" v-if="tableInfo.data.length"> 225 <div class="table_tool_wrap" v-if="tableInfo.data.length">
226 <div class="table_title">分类分级任务</div> 226 <div class="table_title">
227 <span>分类分级任务</span>
228 <div class="title_tool">
229 <el-button @click="getTableData" v-preReClick>刷新结果</el-button>
230 <span class="tips_text">请及时刷新查看最终结果</span>
231 </div>
232 </div>
227 </div> 233 </div>
228 <div class="table_panel_wrap" v-if="tableInfo.data.length"> 234 <div class="table_panel_wrap" v-if="tableInfo.data.length">
229 <Table :tableInfo="tableInfo" @tableBtnClick="tableBtnClick" /> 235 <Table :tableInfo="tableInfo" @tableBtnClick="tableBtnClick" />
...@@ -247,6 +253,19 @@ onBeforeMount(() => { ...@@ -247,6 +253,19 @@ onBeforeMount(() => {
247 font-weight: 600; 253 font-weight: 600;
248 font-size: 16px; 254 font-size: 16px;
249 color: #212121; 255 color: #212121;
256 display: flex;
257
258 .title_tool {
259 display: flex;
260 margin-left: 16px;
261 align-items: center;
262
263 .tips_text {
264 margin-left: 16px;
265 font-size: 14px;
266 color: #b2b2b2;
267 }
268 }
250 } 269 }
251 } 270 }
252 271
......
...@@ -157,6 +157,22 @@ const fieldItemList = ref([ ...@@ -157,6 +157,22 @@ const fieldItemList = ref([
157 disabled: true 157 disabled: true
158 }, 158 },
159 { 159 {
160 type: "select",
161 label: "",
162 placeholder: '分类情况',
163 field: 'isClassify',
164 default: '',
165 options: [
166 { label: '已分类', value: 'Y' },
167 { label: '未分类', value: 'N' },
168 ],
169 props: {
170 // label: 'name',
171 // value: 'dbGuid'
172 },
173 clearable: true,
174 },
175 {
160 type: "cascader", 176 type: "cascader",
161 label: "", 177 label: "",
162 placeholder: '分类', 178 placeholder: '分类',
...@@ -437,17 +453,13 @@ const getFieldTree = () => { ...@@ -437,17 +453,13 @@ const getFieldTree = () => {
437 getTaskExeTreeList({ execGuid: taskDetail.value.execGuid }).then((res: any) => { 453 getTaskExeTreeList({ execGuid: taskDetail.value.execGuid }).then((res: any) => {
438 // treeInfo.value.loading = false; 454 // treeInfo.value.loading = false;
439 if (res.code == proxy.$passCode) { 455 if (res.code == proxy.$passCode) {
440 const data = res.data || []; 456 const data: any = res.data || [];
441 const children: any = [ 457 treeData.value[0].children.push(...data);
442 { classifyName: '未分类', classifyDetailGuid: 'unclassified' },
443 ...data
444 ]
445 treeData.value[0].children = children;
446 treeInfo.value.data = treeData.value; 458 treeInfo.value.data = treeData.value;
447 treeInfo.value.expandedKey = ['all']; 459 treeInfo.value.expandedKey = ['all'];
448 treeInfoRef.value.setCurrentKey('all'); 460 treeInfoRef.value.setCurrentKey('all');
449 formItems.value[0].options = JSON.parse(JSON.stringify(data)); 461 formItems.value[0].options = JSON.parse(JSON.stringify(data));
450 fieldItemList.value[4].options = JSON.parse(JSON.stringify(children)); 462 fieldItemList.value[5].options = JSON.parse(JSON.stringify(data));
451 fieldTableInfo.value.fields[4].options = JSON.parse(JSON.stringify(data)); 463 fieldTableInfo.value.fields[4].options = JSON.parse(JSON.stringify(data));
452 } else { 464 } else {
453 ElMessage.error(res.msg); 465 ElMessage.error(res.msg);
...@@ -496,13 +508,14 @@ const tabChange = (val) => { ...@@ -496,13 +508,14 @@ const tabChange = (val) => {
496 const nodeClick = (data, node) => { 508 const nodeClick = (data, node) => {
497 currTreeNode.value = data; 509 currTreeNode.value = data;
498 if (data.classifyDetailGuid == 'all') { 510 if (data.classifyDetailGuid == 'all') {
499 fieldItemList.value[4].default = []; 511 fieldItemList.value[4].default = '';
512 fieldItemList.value[5].default = [];
500 getFieldTableData() 513 getFieldTableData()
501 } else { 514 } else {
502 const parentGuids = data.parentGuids || []; 515 const parentGuids = data.parentGuids || [];
503 parentGuids.push(data.classifyDetailGuid) 516 parentGuids.push(data.classifyDetailGuid)
504 fieldItemList.value[4].default = parentGuids; 517 fieldItemList.value[4].default = 'Y';
505 console.log('tree', parentGuids) 518 fieldItemList.value[5].default = parentGuids;
506 getFieldTableData(); 519 getFieldTableData();
507 } 520 }
508 } 521 }
...@@ -545,7 +558,7 @@ const getFieldTableData = () => { ...@@ -545,7 +558,7 @@ const getFieldTableData = () => {
545 isMergeClassify: checked1.value ? 'Y' : 'N' 558 isMergeClassify: checked1.value ? 'Y' : 'N'
546 } 559 }
547 const classifyName = params.classifyName?.at(-1) || undefined; 560 const classifyName = params.classifyName?.at(-1) || undefined;
548 params.isClassify = classifyName === undefined ? '' : classifyName == 'unclassified' ? 'N' : 'Y'; 561 // params.isClassify = classifyName === undefined ? '' : classifyName == 'unclassified' ? 'N' : 'Y';
549 if (classifyName && classifyName != 'unclassified') { 562 if (classifyName && classifyName != 'unclassified') {
550 params.classifyDetail = classifyName; 563 params.classifyDetail = classifyName;
551 } 564 }
...@@ -768,7 +781,7 @@ const selectChange = (val, item, scope = null) => { ...@@ -768,7 +781,7 @@ const selectChange = (val, item, scope = null) => {
768 let row = scope.row; 781 let row = scope.row;
769 row.gradeGuid = val || ''; 782 row.gradeGuid = val || '';
770 row.gradeDetailName = val ? item.options.find(i => i.guid == val)?.gradeName : ''; 783 row.gradeDetailName = val ? item.options.find(i => i.guid == val)?.gradeName : '';
771 } else { 784 } else if (item.field == 'databaseGuid' || item.field == 'tableGuid') {
772 const params: any = scope; 785 const params: any = scope;
773 if (tabsInfo.value.activeName == 'sheet') { 786 if (tabsInfo.value.activeName == 'sheet') {
774 if (!val) { 787 if (!val) {
...@@ -809,7 +822,7 @@ const selectChange = (val, item, scope = null) => { ...@@ -809,7 +822,7 @@ const selectChange = (val, item, scope = null) => {
809 params.fieldGuid = ''; 822 params.fieldGuid = '';
810 } 823 }
811 824
812 if (val && item.field != "fieldGuid") { 825 if (val) {
813 const params = { 826 const params = {
814 type: item.field == "databaseGuid" ? 2 : 3, 827 type: item.field == "databaseGuid" ? 2 : 3,
815 dbGuid: val || '' 828 dbGuid: val || ''
...@@ -817,6 +830,13 @@ const selectChange = (val, item, scope = null) => { ...@@ -817,6 +830,13 @@ const selectChange = (val, item, scope = null) => {
817 getSheetFieldList(params) 830 getSheetFieldList(params)
818 } 831 }
819 } 832 }
833 } else if (item.field == 'isClassify') {
834 fieldItemList.value[5].default = [];
835 fieldItemList.value[6].default = '';
836 treeInfo.value.expandedKey = ['all'];
837 treeInfoRef.value.setCurrentKey('all');
838 fieldItemList.value[4].default = val || '';
839 getFieldTableData();
820 } 840 }
821 } 841 }
822 842
...@@ -954,7 +974,7 @@ onMounted(() => { ...@@ -954,7 +974,7 @@ onMounted(() => {
954 <el-button plain @click="btnClick({ value: 'export' })">导出</el-button> 974 <el-button plain @click="btnClick({ value: 'export' })">导出</el-button>
955 </div> 975 </div>
956 <div class="checkboxs"> 976 <div class="checkboxs">
957 <el-checkbox v-model="checked1" @change="getFieldTableData()">仅看多分级分</el-checkbox> 977 <el-checkbox v-model="checked1" @change="getFieldTableData()">仅看多分类</el-checkbox>
958 </div> 978 </div>
959 </div> 979 </div>
960 </div> 980 </div>
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!