字典功能处理

20231126-yw
yuanwei 1 year ago
parent 42886ccc72
commit cba58fec93

@ -1,5 +1,13 @@
import axios from "@/utils/request"; import axios from "@/utils/request";
export function getBasicUnitMaintainsOptimize(query) {
return axios({
url: "/udiwms/basic/unit/maintain/filterOptimize",
method: "get",
params: query
});
}
export function getBasicUnitMaintains(query) { export function getBasicUnitMaintains(query) {
return axios({ return axios({
url: "/udiwms/basic/unit/maintain/filter", url: "/udiwms/basic/unit/maintain/filter",

@ -1,4 +1,5 @@
import axios from "@/utils/request"; import axios from "@/utils/request";
import { sysFilterOptimize } from '../udiRelevance'
export function getUdiInfos(query) { export function getUdiInfos(query) {
return axios({ return axios({
@ -16,6 +17,14 @@ export function filterCompany(query) {
}); });
} }
export function filterCompanyOptimize(query) {
return axios({
url: "/udiwms/udiinfo/filterCompanyOptimize",
method: "get",
params: query
});
}
export function filterByUuid(query) { export function filterByUuid(query) {
return axios({ return axios({
url: "/udiwms/udiinfo/local/filterByUuid", url: "/udiwms/udiinfo/local/filterByUuid",

@ -168,6 +168,14 @@ export function sysFilter(query) {
}); });
} }
export function sysFilterOptimize(query) {
return axios({
url: "/udiwms/udirel/thirdSys/filterOptimize",
method: "get",
params: query
});
}
export function spcombie(query) { export function spcombie(query) {
return axios({ return axios({
url: "/udiwms/udiinfo/spcombie", url: "/udiwms/udiinfo/spcombie",

@ -60,7 +60,9 @@ export function executeFuc(_this,row,number,type,clickFuc,value){
} }
}else if("4" == type){ }else if("4" == type){
//颜色方法 //颜色方法
if(clickFuc) {
return getColer(clickFuc, value); return getColer(clickFuc, value);
}
}else if("5" == type){ }else if("5" == type){
//查询input方法 //查询input方法
if(clickFuc){ if(clickFuc){

@ -38,9 +38,9 @@
clearable> clearable>
<el-option <el-option
v-for="item in options[item.clickFuc]" v-for="item in options[item.clickFuc]"
:key="item.filterType" :key="item.code"
:label="item.sysName" :label="item.label"
:value="item.filterType" :value="item.code"
/> />
</el-select> </el-select>
</el-form-item> </el-form-item>
@ -489,7 +489,7 @@
</template> </template>
<script> <script>
import {getUdiInfos, filterCompany} from "@/api/basic/product/udiInfo"; import {getUdiInfos, filterCompanyOptimize} from "@/api/basic/product/udiInfo";
import {superSearch} from "@/api/basic/udiInfo"; import {superSearch} from "@/api/basic/udiInfo";
import {combineUdi, combineAllUdi, checkExitUdi} from "@/api/basic/product/udiRelevance"; import {combineUdi, combineAllUdi, checkExitUdi} from "@/api/basic/product/udiRelevance";
import selectDiDetail from "./SelectDIDetailDialog" import selectDiDetail from "./SelectDIDetailDialog"
@ -558,7 +558,9 @@ export default {
tableHeader:[], tableHeader:[],
queryList:[], queryList:[],
fromList:[], fromList:[],
options:[], options:{
findMethod:[]
},
total: 0, total: 0,
currentRow: null, currentRow: null,
fromOptions: [], fromOptions: [],
@ -595,6 +597,7 @@ export default {
this.filterQuery.cpmctymc = null; this.filterQuery.cpmctymc = null;
}, },
searchList() { searchList() {
console.log(this.options)
this.filterQuery.page = 1; this.filterQuery.page = 1;
this.getList(); this.getList();
}, },
@ -824,18 +827,14 @@ export default {
page: 1, page: 1,
limit: 10, limit: 10,
}; };
filterCompany(cQuery) filterCompanyOptimize(cQuery)
.then((response) => { .then((response) => {
_this.options.loading = false; _this.options.loading = false;
_this.options = { _this.options.findMethod = response.data.list || [];
findMethod: response.data || []
};
}) })
.catch(() => { .catch(() => {
_this.options.loading = false; _this.options.loading = false;
_this.options = { _this.options.findMethod = []
findMethod: []
};
}); });
}, },
executeFuc(row,number,type,clickFuc,value){ executeFuc(row,number,type,clickFuc,value){

@ -1843,7 +1843,9 @@ export default {
detailList: [], detailList: [],
sysList: [], sysList: [],
filterList: [], filterList: [],
options: {}, options: {
getSysFilter:[]
},
queryList:[], queryList:[],
tableHeader:[], tableHeader:[],
fromList:[], fromList:[],
@ -2250,15 +2252,11 @@ export default {
sysFilter() sysFilter()
.then((response) => { .then((response) => {
_this.loading = false; _this.loading = false;
_this.options = { _this.options.getSysFilter = response.data.list || []
getSysFilter: response.data.list || []
};
}) })
.catch(() => { .catch(() => {
_this.loading = false; _this.loading = false;
_this.options = { _this.options.getSysFilter = []
getSysFilter: []
};
}); });
}, },
singleDiEdit() { singleDiEdit() {

@ -28,7 +28,7 @@
</el-form-item> </el-form-item>
<el-form-item v-if="item.columnType == 'selectServer' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`"> <el-form-item v-if="item.columnType == 'selectServer' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-select <el-select
v-model="filterQuery[item.columnName]" v-model="filterQuery[`${item.columnName}`]"
:placeholder="item.columnDesc" :placeholder="item.columnDesc"
:disabled="executeEval(null,item.disabledFuc,false)" :disabled="executeEval(null,item.disabledFuc,false)"
filterable filterable
@ -37,9 +37,9 @@
clearable> clearable>
<el-option <el-option
v-for="item in options[item.clickFuc]" v-for="item in options[item.clickFuc]"
:key="item.filterType" :key="item.code"
:label="item.sysName" :label="item.label"
:value="item.filterType" :value="item.code"
/> />
</el-select> </el-select>
</el-form-item> </el-form-item>
@ -336,12 +336,12 @@ import {
updateErpProduct, updateErpProduct,
uploadSmp, uploadSmp,
thirdSysDetail, thirdSysDetail,
removeRl, sysFilter, spcombie, lockStatus removeRl, sysFilter,sysFilterOptimize, spcombie, lockStatus
} from "@/api/basic/udiRelevance"; } from "@/api/basic/udiRelevance";
import {selectSysParamByKey} from "@/api/param/systemParamConfig"; import {selectSysParamByKey} from "@/api/param/systemParamConfig";
import {filterByUuid, filterCompany} from "@/api/basic/udiInfo"; import {filterByUuid, filterCompany} from "@/api/basic/udiInfo";
import {filterCompanyProductRelevance, deleteCompanyProductRelevance} from "@/api/basic/udiRlSuptRelevance"; import {filterCompanyProductRelevance, deleteCompanyProductRelevance} from "@/api/basic/udiRlSuptRelevance";
import {getBasicUnitMaintains} from "@/api/basic/basicUnitMaintain" import {getBasicUnitMaintainsOptimize} from "@/api/basic/basicUnitMaintain"
import selectProduct from "./basicCompanyProductsImport"; import selectProduct from "./basicCompanyProductsImport";
import selectUdi from "./udiInfoRelevance.vue"; import selectUdi from "./udiInfoRelevance.vue";
import selectErp from "./udiInfoselectErpUdi"; import selectErp from "./udiInfoselectErpUdi";
@ -392,7 +392,10 @@ export default {
detailList: [], detailList: [],
sysList: [], sysList: [],
filterList: [], filterList: [],
options: {}, options: {
findMethod:[],
getSysFilter:[],
},
queryList:[], queryList:[],
tableHeader:[], tableHeader:[],
fromList:[], fromList:[],
@ -725,7 +728,7 @@ export default {
}); });
}, },
getSysFilter(_this,query) { getSysFilter(_this,query) {
sysFilter() sysFilterOptimize()
.then((response) => { .then((response) => {
_this.loading = false; _this.loading = false;
_this.options.getSysFilter = response.data.list || []; _this.options.getSysFilter = response.data.list || [];
@ -836,10 +839,10 @@ export default {
page: 1, page: 1,
limit: 10, limit: 10,
}; };
getBasicUnitMaintains(cQuery) getBasicUnitMaintainsOptimize(cQuery)
.then((response) => { .then((response) => {
_this.loading = false; _this.loading = false;
_this.options.findMethod = response.data.list || [] _this.options.findMethod = response.data.list || [];
}) })
.catch(() => { .catch(() => {
_this.loading = false; _this.loading = false;

Loading…
Cancel
Save