我是供应商

20231126-yw
yuanwei 1 year ago
parent b6a6deb5c7
commit 6ace176dcb

File diff suppressed because it is too large Load Diff

@ -132,6 +132,7 @@
<el-form-item v-if="item.columnType == 'select' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`"> <el-form-item v-if="item.columnType == 'select' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-select v-model="filterQuery[item.columnName]" <el-select v-model="filterQuery[item.columnName]"
:placeholder="item.columnDesc" :placeholder="item.columnDesc"
@change="executeFuc($event,'5',item.checkRules)"
:disabled="executeEval(null,item.disabledFuc,false)" :disabled="executeEval(null,item.disabledFuc,false)"
clearable> clearable>
<el-option <el-option
@ -147,6 +148,7 @@
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)"
@change="executeFuc($event,'5',item.checkRules)"
filterable filterable
remote remote
:remote-method="(query) => executeFuc(query,'5',item.clickFuc)" :remote-method="(query) => executeFuc(query,'5',item.clickFuc)"
@ -528,7 +530,7 @@ import {
import {selectAuthMenu} from "@/api/system/sysMenuHelp"; import {selectAuthMenu} from "@/api/system/sysMenuHelp";
import {getBasicUnitMaintainsOptimize} from "@/api/basic/basicUnitMaintain"; import {getBasicUnitMaintainsOptimize} from "@/api/basic/basicUnitMaintain";
import {getDeptListByUserOptimize} from "@/api/auth/authDept"; import {getDeptListByUserOptimize} from "@/api/auth/authDept";
import {filterSubAllOptimize} from "@/api/system/invWarehouse"; import {getInvListByUserOptimize} from "@/api/system/invWarehouse";
import { import {
getHead,executeFuc getHead,executeFuc
} from "@/utils/customConfig"; } from "@/utils/customConfig";
@ -548,7 +550,7 @@ export default {
corpName: null, corpName: null,
type: 1, type: 1,
editStatus: 1, editStatus: 1,
dealStatus: 0, dealStatus: "0",
}, },
corpLoading: false, corpLoading: false,
@ -688,8 +690,8 @@ export default {
page: 1, page: 1,
limit: 10, limit: 10,
corpName: null, corpName: null,
type: 1, type: "1",
editStatus: 1, editStatus: "1",
}; };
this.auditTimes = []; this.auditTimes = [];
this.detailList = []; this.detailList = [];

@ -1,68 +1,150 @@
<template> <template>
<div> <div>
<el-card class="el-card"> <el-card class="el-card">
<el-form :model="filterQuery" class="query-form" label-width="100px" v-show="showSearch"> <el-form v-if="queryList && queryList.length > 0" :model="filterQuery" class="query-form" label-width="100px" v-show="showSearch">
<el-row> <!-- <el-row>-->
<el-col :span="6" v-if="this.ckeck"> <!-- <el-col :span="6" v-if="this.ckeck">-->
<el-form-item class="query-form-item" label="配送企业名称:"> <!-- <el-form-item class="query-form-item" label="配送企业名称:">-->
<el-input v-model="filterQuery.name" placeholder="配送企业名称" <!-- <el-input v-model="filterQuery.name" placeholder="配送企业名称"-->
style="width: 90%" <!-- style="width: 90%"-->
clearable="true"></el-input> <!-- clearable="true"></el-input>-->
</el-form-item> <!-- </el-form-item>-->
</el-col> <!-- </el-col>-->
<el-col :span="6"> <!-- <el-col :span="6">-->
<el-form-item class="query-form-item" label="证书名称:"> <!-- <el-form-item class="query-form-item" label="证书名称:">-->
<el-input v-model="filterQuery.certName" placeholder="证书名称" <!-- <el-input v-model="filterQuery.certName" placeholder="证书名称"-->
style="width: 90%" <!-- style="width: 90%"-->
clearable="true"></el-input> <!-- clearable="true"></el-input>-->
</el-form-item> <!-- </el-form-item>-->
</el-col> <!-- </el-col>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item class="query-form-item" label="状态:">-->
<!-- <el-select v-model="filterQuery.status"-->
<!-- placeholder="请选择消息状态"-->
<!-- clearable-->
<!-- style="width: 90%"-->
<!-- >-->
<!-- <el-option label="未确认" :value="1"></el-option>-->
<!-- <el-option label="已确认" :value="2"></el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- &lt;!&ndash; <el-col :span="6">&ndash;&gt;-->
<!-- &lt;!&ndash; <el-form-item class="query-form-item" label="忽略状态:">&ndash;&gt;-->
<!-- &lt;!&ndash; <el-select v-model="filterQuery.ignoreStatus"&ndash;&gt;-->
<!-- &lt;!&ndash; placeholder="请选择消息忽略状态"&ndash;&gt;-->
<!-- &lt;!&ndash; clearable&ndash;&gt;-->
<!-- &lt;!&ndash; style="width: 90%"&ndash;&gt;-->
<!-- &lt;!&ndash; >&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option label="不忽略" :value="0"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option label="忽略7天" :value="1"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option label="忽略15天" :value="2"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option label="忽略30天" :value="3"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; </el-select>&ndash;&gt;-->
<!-- &lt;!&ndash; </el-form-item>&ndash;&gt;-->
<!-- &lt;!&ndash; </el-col>&ndash;&gt;-->
<!-- <el-col :span="6">-->
<!-- <el-form-item class="query-form-item" label="预警类型:">-->
<!-- <el-select v-model="filterQuery.type"-->
<!-- placeholder="请选择消息状态"-->
<!-- clearable-->
<!-- style="width: 90%"-->
<!-- @change="typeChange"-->
<!-- >-->
<!-- <el-option label="配送企业资质预警" :value="1"></el-option>-->
<!-- <el-option label="生产企业资质预警" :value="2"></el-option>-->
<!-- <el-option label="产品资质预警" :value="3"></el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<el-col :span="6"> <!-- </el-row>-->
<el-form-item class="query-form-item" label="状态:"> <el-row style=" display:flex; flex-wrap: wrap; ">
<el-select v-model="filterQuery.status" <template v-for="(item, index) in queryList" >
placeholder="请选择消息状态" <el-form-item v-if="item.columnType == 'input' && item.columnName !='queryName' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`" :key="item.id">
clearable <el-input
style="width: 90%" v-model="filterQuery[item.columnName]"
> :placeholder="item.columnDesc"
<el-option label="未确认" :value="1"></el-option> :disabled="executeEval(null,item.disabledFuc,false)"
<el-option label="已确认" :value="2"></el-option> @keyup.enter.native="executeFuc($event,'5',item.clickFuc)"
clearable
></el-input>
</el-form-item>
<el-form-item v-if="item.columnType == 'input' && item.columnName =='queryName' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`" :key="item.id">
<el-autocomplete
class="inline-input"
style="width: 90%"
v-model="queryName"
:fetch-suggestions="queryProductName"
placeholder="请输入内容"
clearable
@select="handleSelect"
@clear="clearQueryProduct"
></el-autocomplete>
</el-form-item>
<el-form-item v-if="item.columnType == 'select' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-select v-model="filterQuery[item.columnName]"
:placeholder="item.columnDesc"
:disabled="executeEval(null,item.disabledFuc,false)"
@change="executeFuc($event,'5',item.checkRules)"
clearable>
<el-option
v-for="dict in item.lableRuleObj"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<span style="float: left">{{ item.name }}</span>
<span v-if="item.isShowXx == '1'" style="float: right; color: #8492a6; font-size: 13px">{{ item.code }}</span>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> <el-form-item v-if="item.columnType == 'selectServer' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<!-- <el-col :span="6">--> <el-select
<!-- <el-form-item class="query-form-item" label="忽略状态:">--> v-model="filterQuery[item.columnName]"
<!-- <el-select v-model="filterQuery.ignoreStatus"--> :placeholder="item.columnDesc"
<!-- placeholder="请选择消息忽略状态"--> :disabled="executeEval(null,item.disabledFuc,false)"
<!-- clearable--> @change="executeFuc($event,'5',item.checkRules)"
<!-- style="width: 90%"--> filterable
<!-- >--> remote
<!-- <el-option label="不忽略" :value="0"></el-option>--> :remote-method="(query) => executeFuc(query,'5',item.clickFuc)"
<!-- <el-option label="忽略7天" :value="1"></el-option>--> clearable>
<!-- <el-option label="忽略15天" :value="2"></el-option>--> <el-option
<!-- <el-option label="忽略30天" :value="3"></el-option>--> v-for="item in options[item.clickFuc]"
<!-- </el-select>--> :key="item.code"
<!-- </el-form-item>--> :label="item.label"
<!-- </el-col>--> :value="item.code"
/>
<el-col :span="6"> <span style="float: left">{{ item.name }}</span>
<el-form-item class="query-form-item" label="预警类型:"> <span v-if="item.isShowXx == '1'" style="float: right; color: #8492a6; font-size: 13px">{{ item.code }}</span>
<el-select v-model="filterQuery.type"
placeholder="请选择消息状态"
clearable
style="width: 90%"
@change="typeChange"
>
<el-option label="配送企业资质预警" :value="1"></el-option>
<el-option label="生产企业资质预警" :value="2"></el-option>
<el-option label="产品资质预警" :value="3"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> <el-form-item v-if="item.columnType == 'datePicker' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-date-picker
:picker-options="pickerOptions"
v-model="actDateRange"
type="daterange"
format="yyyy 年 MM 月 dd 日"
value-format="yyyy-MM-dd"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
></el-date-picker>
</el-form-item>
<el-form-item v-if="item.columnType == 'date' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-date-picker
v-model="filterQuery[item.columnName]"
:style="`width:${item.width+'px'}`"
value-format="yyyy-MM-dd"
:disabled="executeEval(null,item.disabledFuc,false)"
type="date"
:placeholder="item.columnDesc"
></el-date-picker>
</el-form-item>
</template>
</el-row> </el-row>
</el-form> </el-form>
<div class="top-right-btn"> <div class="top-right-btn">
@ -75,48 +157,135 @@
<el-divider style="margin: 15px"></el-divider> <el-divider style="margin: 15px"></el-divider>
<el-table v-loading="loading" :data="list" style="width: 100%" border highlight-current-row> <el-table v-loading="loading" :data="list" style="width: 100%" border highlight-current-row>
<el-table-column type="index" label="序号" width="50"></el-table-column> <!-- <el-table-column type="index" label="序号" width="50"></el-table-column>-->
<el-table-column :label="msgName" prop="name" width="180" show-overflow-tooltip></el-table-column> <!-- <el-table-column :label="msgName" prop="name" width="180" show-overflow-tooltip></el-table-column>-->
<el-table-column label="证书名称" prop="certName" width="180" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="证书名称" prop="certName" width="180" show-overflow-tooltip></el-table-column>-->
<el-table-column label="有效期" prop="vailDate" width="120"></el-table-column> <!-- <el-table-column label="有效期" prop="vailDate" width="120"></el-table-column>-->
<el-table-column label="失效期" prop="expireDate" width="120" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="失效期" prop="expireDate" width="120" show-overflow-tooltip></el-table-column>-->
<el-table-column label="消息状态" prop="status" width="120"> <!-- <el-table-column label="消息状态" prop="status" width="120">-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
<el-tag>{{ statusMap[scope.row.status] }}</el-tag> <!-- <el-tag>{{ statusMap[scope.row.status] }}</el-tag>-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<!-- <el-table-column label="忽略预警" prop="ignoreStatus" width="100">--> <!-- &lt;!&ndash; <el-table-column label="忽略预警" prop="ignoreStatus" width="100">&ndash;&gt;-->
<!-- <template slot-scope="scope">--> <!-- &lt;!&ndash; <template slot-scope="scope">&ndash;&gt;-->
<!-- <el-tag>{{ ignoreStatusMap[scope.row.ignoreStatus] }}</el-tag>--> <!-- &lt;!&ndash; <el-tag>{{ ignoreStatusMap[scope.row.ignoreStatus] }}</el-tag>&ndash;&gt;-->
<!-- </template>--> <!-- &lt;!&ndash; </template>&ndash;&gt;-->
<!-- </el-table-column>--> <!-- &lt;!&ndash; </el-table-column>&ndash;&gt;-->
<el-table-column label="预警次数" prop="remindCount" width="120" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="预警次数" prop="remindCount" width="120" show-overflow-tooltip></el-table-column>-->
<el-table-column label="预警类型" prop="type" width="120"> <!-- <el-table-column label="预警类型" prop="type" width="120">-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
<el-tag>{{ typeMap[scope.row.type] }}</el-tag> <!-- <el-tag>{{ typeMap[scope.row.type] }}</el-tag>-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column label="预警内容" prop="msg" show-overflow-tooltip width="250"></el-table-column> <!-- <el-table-column label="预警内容" prop="msg" show-overflow-tooltip width="250"></el-table-column>-->
<el-table-column label="处理结果" prop="handleMsg" show-overflow-tooltip width="200"></el-table-column> <!-- <el-table-column label="处理结果" prop="handleMsg" show-overflow-tooltip width="200"></el-table-column>-->
<el-table-column label="操作" width="100" fixed="right"> <!-- <el-table-column label="操作" width="100" fixed="right">-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
<el-button <!-- <el-button-->
type="text" <!-- type="text"-->
size="small" <!-- size="small"-->
v-if="scope.row.status === 1" <!-- v-if="scope.row.status === 1"-->
@click.native="confirmMsg(scope.row)" <!-- @click.native="confirmMsg(scope.row)"-->
>确认 <!-- >确认-->
</el-button> <!-- </el-button>-->
<!-- <el-button--> <!-- &lt;!&ndash; <el-button&ndash;&gt;-->
<!-- type="text"--> <!-- &lt;!&ndash; type="text"&ndash;&gt;-->
<!-- size="small"--> <!-- &lt;!&ndash; size="small"&ndash;&gt;-->
<!-- v-if="scope.row.ignoreStatus === 0"--> <!-- &lt;!&ndash; v-if="scope.row.ignoreStatus === 0"&ndash;&gt;-->
<!-- @click.native="ignoreMsg(scope.row)"--> <!-- &lt;!&ndash; @click.native="ignoreMsg(scope.row)"&ndash;&gt;-->
<!-- >忽略--> <!-- &lt;!&ndash; >忽略&ndash;&gt;-->
<!-- </el-button>--> <!-- &lt;!&ndash; </el-button>&ndash;&gt;-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<template v-for="(item, index) in tableHeader">
<el-table-column
v-if="item.columnType == 'id' && executeEval(row,item.expression,true)"
type="index" :label="item.columnDesc"></el-table-column>
<el-table-column
v-if="item.columnType == 'selection'"
type="selection"
:width="item.width"
:selectable="(row,number) => executeFuc(row,'3',item.clickFuc)"
></el-table-column>
<el-table-column
v-if="item.columnType == 'radio' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<el-radio :label="scope.row.id" v-model="radioCheck"><span></span></el-radio>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'laber' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<span :style="{color: executeFuc(scope.row,'4',item.lableRuleObj[scope.row[item.columnName]])}">{{ item.lableRuleObj[scope.row[item.columnName]] }}</span>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'eltag' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<el-tag :type="executeFuc(scope.row,'4',item,item.lableRuleObj?item.lableRuleObj[scope.row[item.columnName]]:scope.row[item.columnName])">
<span>{{ item.lableRuleObj?item.lableRuleObj[scope.row[item.columnName]]:scope.row[item.columnName] }}</span>
</el-tag>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'button' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:width="item.width"
:key="item.columnName"
fixed="right"
>
<template slot-scope="scope">
<el-button v-for="(buttonItem, buttonIndex) in item.buttonRulObj"
:type="buttonItem.type"
:size="buttonItem.size"
:style="buttonItem.style"
:key="buttonItem"
v-if="executeEval(scope.row,buttonItem.hasPermi,true)"
:disabled="executeEval(scope.row,buttonItem.disabledFuc,false)"
@click.native.stop="executeFuc(scope.row,'1',buttonItem.clickFuc)"
>{{ buttonItem.name }}
</el-button>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'text' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<span :style="{color: executeFuc(scope.row,'4',item,scope.row[item.columnName])}">{{ scope.row[item.columnName] }}</span>
</template>
</el-table-column>
</template>
</el-table> </el-table>
<pagination <pagination
v-show="total>0" v-show="total>0"
@ -213,6 +382,9 @@
<script> <script>
import {getSupCertRemindMsgList, confirmMsg, ignoreMsg} from "@/api/purchase/supCertRedmindMsg"; import {getSupCertRemindMsgList, confirmMsg, ignoreMsg} from "@/api/purchase/supCertRedmindMsg";
import {
getHead,executeFuc
} from "@/utils/customConfig";
export default { export default {
name: "supCertRemindMsg", name: "supCertRemindMsg",
@ -221,9 +393,9 @@ export default {
showSearch: true, showSearch: true,
filterQuery: { filterQuery: {
name: null, name: null,
status: 1, status: "1",
ignoreStatus: 0, ignoreStatus: "0",
type: 1, type: "1",
page: 1, page: 1,
limit: 20, limit: 20,
certName:null certName:null
@ -276,7 +448,7 @@ export default {
page: 1, page: 1,
limit: 20, limit: 20,
}; };
this.typeChange(this.filterQuery.type); this.typeChange(this,this.filterQuery.type);
this.getList(); this.getList();
}, },
search() { search() {
@ -304,9 +476,9 @@ export default {
}, },
confirmMsg(row) { confirmMsg(_this,row) {
this.confirmVisible = true; _this.confirmVisible = true;
this.confirmQuery = row; _this.confirmQuery = row;
}, },
postConfirm() { postConfirm() {
confirmMsg(this.confirmQuery).then((res) => { confirmMsg(this.confirmQuery).then((res) => {
@ -346,13 +518,29 @@ export default {
this.currentId = null; this.currentId = null;
}) })
}, },
typeChange(val) { typeChange(_this,val) {
this.msgName = this.msgNameMap[val]; _this.msgName = _this.msgNameMap[val];
},
executeFuc(row,type,clickFuc,value){
return executeFuc(this,row,type,clickFuc,value);
},
executeEval(row,expression,defaultRet){
if(expression){
return eval(expression);
}
return defaultRet;
} }
}, },
created() { created() {
// //
this.getList(); getHead("supCertRemindMsg","1").then((re) => {
//
this.tableObj = re.data;
this.tableHeader = re.data.tableList;
this.queryList = re.data.queryList;
this.fromList = re.data.fromList;
this.getList();
});
if(this.$store.getters.customerId == 110){ if(this.$store.getters.customerId == 110){
this.ckeck=true; this.ckeck=true;
} }

@ -1,74 +1,157 @@
<template> <template>
<div> <div>
<el-card class="el-card"> <el-card class="el-card">
<el-form :model="filterQuery" class="query-form" label-width="100px" v-show="showSearch"> <el-form v-if="queryList && queryList.length > 0" :model="filterQuery" class="query-form" label-width="100px" v-show="showSearch">
<el-row> <!-- <el-row>-->
<el-col :span="8"> <!-- <el-col :span="8">-->
<el-form-item class="query-form-item" label="物资名称:"> <!-- <el-form-item class="query-form-item" label="物资名称:">-->
<el-input v-model="filterQuery.productName" placeholder="清输入物资名称" style="width: 90%" clearable></el-input> <!-- <el-input v-model="filterQuery.productName" placeholder="清输入物资名称" style="width: 90%" clearable></el-input>-->
</el-form-item> <!-- </el-form-item>-->
</el-col> <!-- </el-col>-->
<el-col :span="8"> <!-- <el-col :span="8">-->
<el-form-item class="query-form-item" label="规格型号:"> <!-- <el-form-item class="query-form-item" label="规格型号:">-->
<el-input v-model="filterQuery.ggxh" placeholder="清输入规格型号" style="width: 90%" clearable></el-input> <!-- <el-input v-model="filterQuery.ggxh" placeholder="清输入规格型号" style="width: 90%" clearable></el-input>-->
</el-form-item> <!-- </el-form-item>-->
</el-col> <!-- </el-col>-->
<el-col :span="8"> <!-- <el-col :span="8">-->
<el-form-item class="query-form-item" label="预警类型:"> <!-- <el-form-item class="query-form-item" label="预警类型:">-->
<el-select v-model="filterQuery.type" <!-- <el-select v-model="filterQuery.type"-->
placeholder="请选择消息状态" <!-- placeholder="请选择消息状态"-->
clearable <!-- clearable-->
style="width: 90%" <!-- style="width: 90%"-->
> <!-- >-->
<el-option label="库存不足预警" :value="1"></el-option> <!-- <el-option label="库存不足预警" :value="1"></el-option>-->
<el-option label="负库存预警" :value="2"></el-option> <!-- <el-option label="负库存预警" :value="2"></el-option>-->
<el-option label="库存积压预警" :value="3"></el-option> <!-- <el-option label="库存积压预警" :value="3"></el-option>-->
<el-option label="库存过期预警" :value="4"></el-option> <!-- <el-option label="库存过期预警" :value="4"></el-option>-->
<el-option label="近效期预警" :value="5"></el-option> <!-- <el-option label="近效期预警" :value="5"></el-option>-->
</el-select> <!-- </el-select>-->
</el-form-item> <!-- </el-form-item>-->
</el-col> <!-- </el-col>-->
<!-- <el-col :span="8">--> <!-- &lt;!&ndash; <el-col :span="8">&ndash;&gt;-->
<!-- <el-form-item class="query-form-item" label="批次号:">--> <!-- &lt;!&ndash; <el-form-item class="query-form-item" label="批次号:">&ndash;&gt;-->
<!-- <el-input v-model="filterQuery.batchNo" placeholder="批次号"--> <!-- &lt;!&ndash; <el-input v-model="filterQuery.batchNo" placeholder="批次号"&ndash;&gt;-->
<!-- style="width: 90%"--> <!-- &lt;!&ndash; style="width: 90%"&ndash;&gt;-->
<!-- clearable="true"></el-input>--> <!-- &lt;!&ndash; clearable="true"></el-input>&ndash;&gt;-->
<!-- </el-form-item>--> <!-- &lt;!&ndash; </el-form-item>&ndash;&gt;-->
<!-- </el-col>--> <!-- &lt;!&ndash; </el-col>&ndash;&gt;-->
</el-row> <!-- </el-row>-->
<el-row> <!-- <el-row>-->
<el-col :span="8"> <!-- <el-col :span="8">-->
<el-form-item class="query-form-item" label="状态:"> <!-- <el-form-item class="query-form-item" label="状态:">-->
<el-select v-model="filterQuery.status" <!-- <el-select v-model="filterQuery.status"-->
placeholder="请选择消息状态" <!-- placeholder="请选择消息状态"-->
clearable <!-- clearable-->
style="width: 90%" <!-- style="width: 90%"-->
> <!-- >-->
<el-option label="未确认" :value="1"></el-option> <!-- <el-option label="未确认" :value="1"></el-option>-->
<el-option label="已确认" :value="2"></el-option> <!-- <el-option label="已确认" :value="2"></el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- &lt;!&ndash; <el-col :span="6">&ndash;&gt;-->
<!-- &lt;!&ndash; <el-form-item class="query-form-item" label="忽略状态:">&ndash;&gt;-->
<!-- &lt;!&ndash; <el-select v-model="filterQuery.ignoreStatus"&ndash;&gt;-->
<!-- &lt;!&ndash; placeholder="请选择消息忽略状态"&ndash;&gt;-->
<!-- &lt;!&ndash; clearable&ndash;&gt;-->
<!-- &lt;!&ndash; style="width: 90%"&ndash;&gt;-->
<!-- &lt;!&ndash; >&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option label="不忽略" :value="0"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option label="忽略7天" :value="1"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option label="忽略15天" :value="2"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option label="忽略30天" :value="3"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; </el-select>&ndash;&gt;-->
<!-- &lt;!&ndash; </el-form-item>&ndash;&gt;-->
<!-- &lt;!&ndash; </el-col>&ndash;&gt;-->
<!-- </el-row>-->
<el-row style=" display:flex; flex-wrap: wrap; ">
<template v-for="(item, index) in queryList" >
<el-form-item v-if="item.columnType == 'input' && item.columnName !='queryName' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`" :key="item.id">
<el-input
v-model="filterQuery[item.columnName]"
:placeholder="item.columnDesc"
:disabled="executeEval(null,item.disabledFuc,false)"
@keyup.enter.native="executeFuc($event,'5',item.clickFuc)"
clearable
></el-input>
</el-form-item>
<el-form-item v-if="item.columnType == 'input' && item.columnName =='queryName' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`" :key="item.id">
<el-autocomplete
class="inline-input"
style="width: 90%"
v-model="queryName"
:fetch-suggestions="queryProductName"
placeholder="请输入内容"
clearable
@select="handleSelect"
@clear="clearQueryProduct"
></el-autocomplete>
</el-form-item>
<el-form-item v-if="item.columnType == 'select' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-select v-model="filterQuery[item.columnName]"
:placeholder="item.columnDesc"
@change="executeFuc($event,'5',item.checkRules)"
:disabled="executeEval(null,item.disabledFuc,false)"
clearable>
<el-option
v-for="dict in item.lableRuleObj"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<span style="float: left">{{ item.name }}</span>
<span v-if="item.isShowXx == '1'" style="float: right; color: #8492a6; font-size: 13px">{{ item.code }}</span>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> <el-form-item v-if="item.columnType == 'selectServer' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-select
<!-- <el-col :span="6">--> v-model="filterQuery[item.columnName]"
<!-- <el-form-item class="query-form-item" label="忽略状态:">--> :placeholder="item.columnDesc"
<!-- <el-select v-model="filterQuery.ignoreStatus"--> :disabled="executeEval(null,item.disabledFuc,false)"
<!-- placeholder="请选择消息忽略状态"--> filterable
<!-- clearable--> remote
<!-- style="width: 90%"--> @change="executeFuc($event,'5',item.checkRules)"
<!-- >--> :remote-method="(query) => executeFuc(query,'5',item.clickFuc)"
<!-- <el-option label="不忽略" :value="0"></el-option>--> clearable>
<!-- <el-option label="忽略7天" :value="1"></el-option>--> <el-option
<!-- <el-option label="忽略15天" :value="2"></el-option>--> v-for="item in options[item.clickFuc]"
<!-- <el-option label="忽略30天" :value="3"></el-option>--> :key="item.code"
<!-- </el-select>--> :label="item.label"
<!-- </el-form-item>--> :value="item.code"
<!-- </el-col>--> />
<span style="float: left">{{ item.name }}</span>
<span v-if="item.isShowXx == '1'" style="float: right; color: #8492a6; font-size: 13px">{{ item.code }}</span>
</el-select>
</el-form-item>
<el-form-item v-if="item.columnType == 'datePicker' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-date-picker
:picker-options="pickerOptions"
v-model="actDateRange"
type="daterange"
format="yyyy 年 MM 月 dd 日"
value-format="yyyy-MM-dd"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
></el-date-picker>
</el-form-item>
<el-form-item v-if="item.columnType == 'date' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-date-picker
v-model="filterQuery[item.columnName]"
:style="`width:${item.width+'px'}`"
value-format="yyyy-MM-dd"
:disabled="executeEval(null,item.disabledFuc,false)"
type="date"
:placeholder="item.columnDesc"
></el-date-picker>
</el-form-item>
</template>
</el-row> </el-row>
</el-form> </el-form>
@ -82,58 +165,145 @@
<el-divider style="margin: 15px"></el-divider> <el-divider style="margin: 15px"></el-divider>
<el-table v-loading="loading" :data="list" style="width: 100%" border highlight-current-row> <el-table v-loading="loading" :data="list" style="width: 100%" border highlight-current-row>
<el-table-column type="index" label="序号" width="50"></el-table-column> <!-- <el-table-column type="index" label="序号" width="50"></el-table-column>-->
<el-table-column label="物资名称" prop="productName" width="180" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="物资名称" prop="productName" width="180" show-overflow-tooltip></el-table-column>-->
<el-table-column label="规格型号" prop="ggxh" width="180" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="规格型号" prop="ggxh" width="180" show-overflow-tooltip></el-table-column>-->
<!-- <el-table-column label="批次号" prop="batchNo" width="120" show-overflow-tooltip></el-table-column>--> <!-- &lt;!&ndash; <el-table-column label="批次号" prop="batchNo" width="120" show-overflow-tooltip></el-table-column>&ndash;&gt;-->
<el-table-column label="预警次数" prop="remindCount" width="120" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="预警次数" prop="remindCount" width="120" show-overflow-tooltip></el-table-column>-->
<el-table-column label="预警类型" prop="productionDate" width="120"> <!-- <el-table-column label="预警类型" prop="productionDate" width="120">-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
<el-tag type="danger">{{ typeMap[scope.row.type] }}</el-tag> <!-- <el-tag type="danger">{{ typeMap[scope.row.type] }}</el-tag>-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column label="预警详情" prop="msg" width="250" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="预警详情" prop="msg" width="250" show-overflow-tooltip></el-table-column>-->
<el-table-column label="状态" prop="status" width="120"> <!-- <el-table-column label="状态" prop="status" width="120">-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
<el-tag :type="statusFilterType(scope.row.status)">{{ <!-- <el-tag :type="statusFilterType(scope.row.status)">{{-->
statusMap[scope.row.status] <!-- statusMap[scope.row.status]-->
}} <!-- }}-->
</el-tag> <!-- </el-tag>-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column label="处理结果" prop="handleMsg" width="200" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="处理结果" prop="handleMsg" width="200" show-overflow-tooltip></el-table-column>-->
<!-- <el-table-column label="忽略预警" prop="ignoreStatus" width="100">--> <!-- &lt;!&ndash; <el-table-column label="忽略预警" prop="ignoreStatus" width="100">&ndash;&gt;-->
<!-- <template slot-scope="scope">--> <!-- &lt;!&ndash; <template slot-scope="scope">&ndash;&gt;-->
<!-- <el-tag>{{ ignoreStatusMap[scope.row.ignoreStatus] }}</el-tag>--> <!-- &lt;!&ndash; <el-tag>{{ ignoreStatusMap[scope.row.ignoreStatus] }}</el-tag>&ndash;&gt;-->
<!-- </template>--> <!-- &lt;!&ndash; </template>&ndash;&gt;-->
<!-- </el-table-column>--> <!-- &lt;!&ndash; </el-table-column>&ndash;&gt;-->
<!-- <el-table-column label="入库数量" prop="inCount" width="100"></el-table-column>--> <!-- &lt;!&ndash; <el-table-column label="入库数量" prop="inCount" width="100"></el-table-column>&ndash;&gt;-->
<!-- <el-table-column label="出库数量" prop="outCount" width="100"></el-table-column>--> <!-- &lt;!&ndash; <el-table-column label="出库数量" prop="outCount" width="100"></el-table-column>&ndash;&gt;-->
<el-table-column label="库存数量" prop="reCount" width="100"></el-table-column> <!-- <el-table-column label="库存数量" prop="reCount" width="100"></el-table-column>-->
<!-- <el-table-column label="生产日期" prop="productionDate" width="120"></el-table-column>--> <!-- &lt;!&ndash; <el-table-column label="生产日期" prop="productionDate" width="120"></el-table-column>&ndash;&gt;-->
<!-- <el-table-column label="失效日期" prop="expireDate" width="120"></el-table-column>--> <!-- &lt;!&ndash; <el-table-column label="失效日期" prop="expireDate" width="120"></el-table-column>&ndash;&gt;-->
<!-- <el-table-column label="供应商" prop="supName" width="150" show-overflow-tooltip></el-table-column>--> <!-- &lt;!&ndash; <el-table-column label="供应商" prop="supName" width="150" show-overflow-tooltip></el-table-column>&ndash;&gt;-->
<el-table-column label="生产企业" prop="manufactory" width="150" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="生产企业" prop="manufactory" width="150" show-overflow-tooltip></el-table-column>-->
<el-table-column label="注册备案证号" prop="zczbhhzbapzbh" width="150" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="注册备案证号" prop="zczbhhzbapzbh" width="150" show-overflow-tooltip></el-table-column>-->
<el-table-column label="操作" width="100" fixed="right"> <!-- <el-table-column label="操作" width="100" fixed="right">-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
<el-button <!-- <el-button-->
type="text" <!-- type="text"-->
size="small" <!-- size="small"-->
v-if="scope.row.status === 1" <!-- v-if="scope.row.status === 1"-->
@click.native="confirmMsg(scope.row)" <!-- @click.native="confirmMsg(scope.row)"-->
>确认 <!-- >确认-->
</el-button> <!-- </el-button>-->
<!-- <el-button--> <!-- &lt;!&ndash; <el-button&ndash;&gt;-->
<!-- type="text"--> <!-- &lt;!&ndash; type="text"&ndash;&gt;-->
<!-- size="small"--> <!-- &lt;!&ndash; size="small"&ndash;&gt;-->
<!-- v-if="scope.row.ignoreStatus === 0"--> <!-- &lt;!&ndash; v-if="scope.row.ignoreStatus === 0"&ndash;&gt;-->
<!-- @click.native="ignoreMsg(scope.row)"--> <!-- &lt;!&ndash; @click.native="ignoreMsg(scope.row)"&ndash;&gt;-->
<!-- >忽略--> <!-- &lt;!&ndash; >忽略&ndash;&gt;-->
<!-- </el-button>--> <!-- &lt;!&ndash; </el-button>&ndash;&gt;-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<template v-for="(item, index) in tableHeader">
<el-table-column
v-if="item.columnType == 'id' && executeEval(row,item.expression,true)"
type="index" :label="item.columnDesc"></el-table-column>
<el-table-column
v-if="item.columnType == 'selection'"
type="selection"
:width="item.width"
:selectable="(row,number) => executeFuc(row,'3',item.clickFuc)"
></el-table-column>
<el-table-column
v-if="item.columnType == 'radio' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<el-radio :label="scope.row.id" v-model="radioCheck"><span></span></el-radio>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'laber' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<span :style="{color: executeFuc(scope.row,'4',item.lableRuleObj[scope.row[item.columnName]])}">{{ item.lableRuleObj[scope.row[item.columnName]] }}</span>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'eltag' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<el-tag :type="executeFuc(scope.row,'4',item,item.lableRuleObj?item.lableRuleObj[scope.row[item.columnName]]:scope.row[item.columnName])">
<span>{{ item.lableRuleObj?item.lableRuleObj[scope.row[item.columnName]]:scope.row[item.columnName] }}</span>
</el-tag>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'button' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:width="item.width"
:key="item.columnName"
fixed="right"
>
<template slot-scope="scope">
<el-button v-for="(buttonItem, buttonIndex) in item.buttonRulObj"
:type="buttonItem.type"
:size="buttonItem.size"
:style="buttonItem.style"
:key="buttonItem"
v-if="executeEval(scope.row,buttonItem.hasPermi,true)"
:disabled="executeEval(scope.row,buttonItem.disabledFuc,false)"
@click.native.stop="executeFuc(scope.row,'1',buttonItem.clickFuc)"
>{{ buttonItem.name }}
</el-button>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'text' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<span :style="{color: executeFuc(scope.row,'4',item,scope.row[item.columnName])}">{{ scope.row[item.columnName] }}</span>
</template>
</el-table-column>
</template>
</el-table> </el-table>
<pagination <pagination
v-show="total>0" v-show="total>0"
@ -239,6 +409,9 @@ import {getInvListByUser} from "@/api/system/invWarehouse";
import {getInvSpaceList} from "@/api/inventory/invSpace"; import {getInvSpaceList} from "@/api/inventory/invSpace";
import {filterProductNames} from "@/api/inventory/invPorduct"; import {filterProductNames} from "@/api/inventory/invPorduct";
import {getGgxhList} from "@/api/basic/product/udiRelevance"; import {getGgxhList} from "@/api/basic/product/udiRelevance";
import {
getHead,executeFuc
} from "@/utils/customConfig";
export default { export default {
name: "invRemindMsg", name: "invRemindMsg",
@ -250,8 +423,8 @@ export default {
relId: null, relId: null,
batchNo: null, batchNo: null,
ggxh: null, ggxh: null,
status: 1, status: "1",
ignoreStatus: 0, ignoreStatus: "0",
invCode: this.$store.getters.locInvCode, invCode: this.$store.getters.locInvCode,
invSpaceCode: null, invSpaceCode: null,
type: null, type: null,
@ -283,6 +456,12 @@ export default {
invList: [], invList: [],
spaceList: [], spaceList: [],
ggxhList: [], ggxhList: [],
tableHeader:[],
queryList:[],
fromList:[],
options: {
},
ignoreVisible: false, ignoreVisible: false,
currentId: null, currentId: null,
confirmVisible: false, confirmVisible: false,
@ -409,9 +588,9 @@ export default {
this.queryName = null; this.queryName = null;
this.filterQuery.relId = null; this.filterQuery.relId = null;
}, },
confirmMsg(row) { confirmMsg(_this,row) {
this.confirmVisible = true; _this.confirmVisible = true;
this.confirmQuery = row; _this.confirmQuery = row;
}, },
postConfirm() { postConfirm() {
confirmMsg(this.confirmQuery).then((res) => { confirmMsg(this.confirmQuery).then((res) => {
@ -461,11 +640,27 @@ export default {
}; };
return statusMap[status]; return statusMap[status];
}, },
executeFuc(row,type,clickFuc,value){
return executeFuc(this,row,type,clickFuc,value);
},
executeEval(row,expression,defaultRet){
if(expression){
return eval(expression);
}
return defaultRet;
}
}, },
created() { created() {
this.getInvList(); this.getInvList();
// //
this.getList(); getHead("supInvRemindMsg","1").then((re) => {
//
this.tableObj = re.data;
this.tableHeader = re.data.tableList;
this.queryList = re.data.queryList;
this.fromList = re.data.fromList;
this.getList();
});
}, },
}; };
</script> </script>

@ -1,62 +1,145 @@
<template> <template>
<div> <div>
<el-card> <el-card>
<el-form :model="filterQuery" size="mini" label-width="120px" v-show="showSearch"> <el-form v-if="queryList && queryList.length > 0" :model="filterQuery" size="mini" label-width="120px" v-show="showSearch">
<el-row> <!-- <el-row>-->
<el-col :span="6"> <!-- <el-col :span="6">-->
<el-form-item label="物资编码:"> <!-- <el-form-item label="物资编码:">-->
<el-input v-model="filterQuery.unionCode" style="width: 90%" placeholder="请输入产品编码" <!-- <el-input v-model="filterQuery.unionCode" style="width: 90%" placeholder="请输入产品编码"-->
clearable="true"></el-input> <!-- clearable="true"></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="物资名称:">-->
<!-- <el-input v-model="filterQuery.cpmctymc" style="width: 90%" placeholder="请输入物资名称"-->
<!-- clearable="true"></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="规格型号:">-->
<!-- <el-input v-model="filterQuery.ggxh" style="width: 90%" placeholder="请输入规格型号" clearable="true"></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="对照条件:">-->
<!-- <el-select v-model="filterQuery.filterType" style="width: 90%" placeholder="请选择过滤对照条件">-->
<!-- <el-option-->
<!-- v-for="item in filterList"-->
<!-- :key="item.filterType"-->
<!-- :label="item.sysName"-->
<!-- :value="item.filterType">-->
<!-- <span style="float: left">{{ item.sysName }}</span>-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- <el-row>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="生产企业:">-->
<!-- <el-input v-model="filterQuery.ylqxzcrbarmc" style="width: 90%" placeholder="请输入生产企业/注册备案人"-->
<!-- clearable="true"></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="第三方产品编码:">-->
<!-- <el-input v-model="filterQuery.thrPiId" style="width: 90%" placeholder="请输入第三方产品编码"-->
<!-- clearable="true"></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="审核状态:" v-if="isSpCombine">-->
<!-- <el-select v-model="filterQuery.lockStatus" style="width: 90%" placeholder="请选择审核状态">-->
<!-- <el-option label="全部" value=""></el-option>-->
<!-- <el-option label="未提交" value="1"></el-option>-->
<!-- <el-option label="已提交" value="2"></el-option>-->
<!-- <el-option label="已锁定" value="3"></el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<el-row style=" display:flex; flex-wrap: wrap; ">
<template v-for="(item, index) in queryList" >
<el-form-item v-if="item.columnType == 'input' && item.columnName !='queryName' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`" :key="item.id">
<el-input
v-model="filterQuery[item.columnName]"
:placeholder="item.columnDesc"
:disabled="executeEval(null,item.disabledFuc,false)"
@keyup.enter.native="executeFuc($event,'5',item.clickFuc)"
clearable
></el-input>
</el-form-item> </el-form-item>
</el-col> <el-form-item v-if="item.columnType == 'input' && item.columnName =='queryName' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`" :key="item.id">
<el-col :span="6"> <el-autocomplete
<el-form-item label="物资名称:"> class="inline-input"
<el-input v-model="filterQuery.cpmctymc" style="width: 90%" placeholder="请输入物资名称" style="width: 90%"
clearable="true"></el-input> v-model="queryName"
:fetch-suggestions="queryProductName"
placeholder="请输入内容"
clearable
@select="handleSelect"
@clear="clearQueryProduct"
></el-autocomplete>
</el-form-item> </el-form-item>
</el-col> <el-form-item v-if="item.columnType == 'select' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-col :span="6"> <el-select v-model="filterQuery[item.columnName]"
<el-form-item label="规格型号:"> :placeholder="item.columnDesc"
<el-input v-model="filterQuery.ggxh" style="width: 90%" placeholder="请输入规格型号" clearable="true"></el-input> @change="executeFuc($event,'5',item.checkRules)"
:disabled="executeEval(null,item.disabledFuc,false)"
clearable>
<el-option
v-for="dict in item.lableRuleObj"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<span style="float: left">{{ item.name }}</span>
<span v-if="item.isShowXx == '1'" style="float: right; color: #8492a6; font-size: 13px">{{ item.code }}</span>
</el-select>
</el-form-item> </el-form-item>
</el-col> <el-form-item v-if="item.columnType == 'selectServer' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-col :span="6"> <el-select
<el-form-item label="对照条件:"> v-model="filterQuery[item.columnName]"
<el-select v-model="filterQuery.filterType" style="width: 90%" placeholder="请选择过滤对照条件"> :placeholder="item.columnDesc"
:disabled="executeEval(null,item.disabledFuc,false)"
filterable
remote
@change="executeFuc($event,'5',item.checkRules)"
:remote-method="(query) => executeFuc(query,'5',item.clickFuc)"
clearable>
<el-option <el-option
v-for="item in filterList" 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"
<span style="float: left">{{ item.sysName }}</span> />
</el-option> <span style="float: left">{{ item.name }}</span>
<span v-if="item.isShowXx == '1'" style="float: right; color: #8492a6; font-size: 13px">{{ item.code }}</span>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> <el-form-item v-if="item.columnType == 'datePicker' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
</el-row> <el-date-picker
<el-row> :picker-options="pickerOptions"
<el-col :span="6"> v-model="actDateRange"
<el-form-item label="生产企业:"> type="daterange"
<el-input v-model="filterQuery.ylqxzcrbarmc" style="width: 90%" placeholder="请输入生产企业/注册备案人" format="yyyy 年 MM 月 dd 日"
clearable="true"></el-input> value-format="yyyy-MM-dd"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
></el-date-picker>
</el-form-item> </el-form-item>
</el-col> <el-form-item v-if="item.columnType == 'date' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`">
<el-col :span="6"> <el-date-picker
<el-form-item label="第三方产品编码:"> v-model="filterQuery[item.columnName]"
<el-input v-model="filterQuery.thrPiId" style="width: 90%" placeholder="请输入第三方产品编码" :style="`width:${item.width+'px'}`"
clearable="true"></el-input> value-format="yyyy-MM-dd"
:disabled="executeEval(null,item.disabledFuc,false)"
type="date"
:placeholder="item.columnDesc"
></el-date-picker>
</el-form-item> </el-form-item>
</el-col> </template>
<el-col :span="6">
<el-form-item label="审核状态:" v-if="isSpCombine">
<el-select v-model="filterQuery.lockStatus" style="width: 90%" placeholder="请选择审核状态">
<el-option label="全部" value=""></el-option>
<el-option label="未提交" value="1"></el-option>
<el-option label="已提交" value="2"></el-option>
<el-option label="已锁定" value="3"></el-option>
</el-select>
</el-form-item>
</el-col>
</el-row> </el-row>
</el-form> </el-form>
<div class="top-right-btn"> <div class="top-right-btn">
@ -71,66 +154,171 @@
<el-table v-loading="loading" :data="list" style="width: 100%" @selection-change="handleSelectionChange" border <el-table v-loading="loading" :data="list" style="width: 100%" @selection-change="handleSelectionChange" border
highlight-current-row> highlight-current-row>
<el-table-column label="序号" type="index"></el-table-column> <!-- <el-table-column label="序号" type="index"></el-table-column>-->
<el-table-column label="最小销售产品标识" prop="nameCode" width="140" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="最小销售产品标识" prop="nameCode" width="140" show-overflow-tooltip></el-table-column>-->
<el-table-column label="物资编码" prop="thirdId" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="物资编码" prop="thirdId" show-overflow-tooltip></el-table-column>-->
<el-table-column label="物资名称" prop="cpmctymc" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="物资名称" prop="cpmctymc" show-overflow-tooltip></el-table-column>-->
<el-table-column label="规格型号" prop="ggxh" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="规格型号" prop="ggxh" show-overflow-tooltip></el-table-column>-->
<el-table-column label="价格" prop="price" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="价格" prop="price" show-overflow-tooltip></el-table-column>-->
<el-table-column label="生产企业" prop="ylqxzcrbarmc" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="生产企业" prop="ylqxzcrbarmc" show-overflow-tooltip></el-table-column>-->
<el-table-column label="注册/备案号" prop="zczbhhzbapzbh" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="注册/备案号" prop="zczbhhzbapzbh" show-overflow-tooltip></el-table-column>-->
<el-table-column label="物资分类" prop="classifyName" show-overflow-tooltip></el-table-column> <!-- <el-table-column label="物资分类" prop="classifyName" show-overflow-tooltip></el-table-column>-->
<el-table-column v-if="isSpCombine" label="锁定状态" prop="lockStatus" show-overflow-tooltip> <!-- <el-table-column v-if="isSpCombine" label="锁定状态" prop="lockStatus" show-overflow-tooltip>-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
{{ lockStatusMap[scope.row.lockStatus] }} <!-- {{ lockStatusMap[scope.row.lockStatus] }}-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column width="180" label="操作" fixed="right"> <!-- <el-table-column width="180" label="操作" fixed="right">-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
<el-button v-if="isSpCombine" type="text" size="small" <!-- <el-button v-if="isSpCombine" type="text" size="small"-->
:disabled="scope.row.originUuid!=null || scope.row.lockStatus===3" <!-- :disabled="scope.row.originUuid!=null || scope.row.lockStatus===3"-->
@click.native.stop="intentSelectUdi(scope.row)">关联DI <!-- @click.native.stop="intentSelectUdi(scope.row)">关联DI-->
</el-button> <!-- </el-button>-->
<el-button type="text" size="small" :disabled="scope.row.lockStatus==3" <!-- <el-button type="text" size="small" :disabled="scope.row.lockStatus==3"-->
@click.native.stop="handleModifyClick(scope.row)">编辑 <!-- @click.native.stop="handleModifyClick(scope.row)">编辑-->
</el-button> <!-- </el-button>-->
<el-button type="text" size="small" <!-- <el-button type="text" size="small"-->
@click.native.stop="handleDetailClick(scope.row)">详情 <!-- @click.native.stop="handleDetailClick(scope.row)">详情-->
</el-button> <!-- </el-button>-->
<el-dropdown size="mini" @command="(command) => handleCommand(command, scope.row)" <!-- <el-dropdown size="mini" @command="(command) => handleCommand(command, scope.row)"-->
> <!-- >-->
<span class="el-dropdown-link"> <!-- <span class="el-dropdown-link">-->
<i class="el-icon-d-arrow-right el-icon--right"></i>更多 <!-- <i class="el-icon-d-arrow-right el-icon&#45;&#45;right"></i>更多-->
</span> <!-- </span>-->
<el-dropdown-menu slot="dropdown"> <!-- <el-dropdown-menu slot="dropdown">-->
<!-- <el-dropdown-item command="handleDetailClick" v-if=" scope.row.lockStatus!=3"></el-dropdown-item>--> <!-- &lt;!&ndash; <el-dropdown-item command="handleDetailClick" v-if=" scope.row.lockStatus!=3"></el-dropdown-item>&ndash;&gt;-->
<el-dropdown-item command="sumitLockStatus" v-if="isSpCombine" :disabled="scope.row.lockStatus===3"> <!-- <el-dropdown-item command="sumitLockStatus" v-if="isSpCombine" :disabled="scope.row.lockStatus===3">-->
提交审核 <!-- 提交审核-->
</el-dropdown-item> <!-- </el-dropdown-item>-->
<el-dropdown-item command="splitSelectUdi" v-if="isSpCombine" type="text" size="small" <!-- <el-dropdown-item command="splitSelectUdi" v-if="isSpCombine" type="text" size="small"-->
:disabled="scope.row.thirdId===scope.row.nameCode || scope.row.thirdId==null || scope.row.nameCode==null || scope.row.lockStatus===3"> <!-- :disabled="scope.row.thirdId===scope.row.nameCode || scope.row.thirdId==null || scope.row.nameCode==null || scope.row.lockStatus===3">-->
拆分产品 <!-- 拆分产品-->
</el-dropdown-item> <!-- </el-dropdown-item>-->
<el-dropdown-item command="deleteCompanyProductRelevance">移除</el-dropdown-item> <!-- <el-dropdown-item command="deleteCompanyProductRelevance">移除</el-dropdown-item>-->
</el-dropdown-menu> <!-- </el-dropdown-menu>-->
</el-dropdown> <!-- </el-dropdown>-->
<!-- <el-button v-if=" scope.row.lockStatus!=3" type="text" size="small"--> <!-- &lt;!&ndash; <el-button v-if=" scope.row.lockStatus!=3" type="text" size="small"&ndash;&gt;-->
<!-- @click.native.stop="handleDetailClick(scope.row)">详情--> <!-- &lt;!&ndash; @click.native.stop="handleDetailClick(scope.row)">详情&ndash;&gt;-->
<!-- </el-button>--> <!-- &lt;!&ndash; </el-button>&ndash;&gt;-->
<!-- <el-button v-if="isSpCombine" type="text" size="small" :disabled="scope.row.lockStatus===3"--> <!-- &lt;!&ndash; <el-button v-if="isSpCombine" type="text" size="small" :disabled="scope.row.lockStatus===3"&ndash;&gt;-->
<!-- @click.native.stop="sumitLockStatus(scope.row)">提交审核--> <!-- &lt;!&ndash; @click.native.stop="sumitLockStatus(scope.row)">提交审核&ndash;&gt;-->
<!-- </el-button>--> <!-- &lt;!&ndash; </el-button>&ndash;&gt;-->
<!-- <el-button v-if="isSpCombine" type="text" size="small" @click.native.stop="splitSelectUdi(scope.row)"--> <!-- &lt;!&ndash; <el-button v-if="isSpCombine" type="text" size="small" @click.native.stop="splitSelectUdi(scope.row)"&ndash;&gt;-->
<!-- :disabled="scope.row.thirdId===scope.row.nameCode || scope.row.thirdId==null || scope.row.nameCode==null || scope.row.lockStatus===3">--> <!-- &lt;!&ndash; :disabled="scope.row.thirdId===scope.row.nameCode || scope.row.thirdId==null || scope.row.nameCode==null || scope.row.lockStatus===3">&ndash;&gt;-->
<!-- 拆分产品--> <!-- &lt;!&ndash; 拆分产品&ndash;&gt;-->
<!-- </el-button>--> <!-- &lt;!&ndash; </el-button>&ndash;&gt;-->
<!-- <el-button type="text" size="small" @click.native.stop="deleteCompanyProductRelevance(scope.row)">移除--> <!-- &lt;!&ndash; <el-button type="text" size="small" @click.native.stop="deleteCompanyProductRelevance(scope.row)">移除&ndash;&gt;-->
<!-- </el-button>--> <!-- &lt;!&ndash; </el-button>&ndash;&gt;-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<template v-for="(item, index) in tableHeader">
<el-table-column
v-if="item.columnType == 'id' && executeEval(row,item.expression,true)"
type="index" :label="item.columnDesc"></el-table-column>
<el-table-column
v-if="item.columnType == 'selection'"
type="selection"
:width="item.width"
:selectable="(row,number) => executeFuc(row,'3',item.clickFuc)"
></el-table-column>
<el-table-column
v-if="item.columnType == 'radio' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<el-radio :label="scope.row.id" v-model="radioCheck"><span></span></el-radio>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'laber' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<span :style="{color: executeFuc(scope.row,'4',item.lableRuleObj[scope.row[item.columnName]])}">{{ item.lableRuleObj[scope.row[item.columnName]] }}</span>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'eltag' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<el-tag :type="executeFuc(scope.row,'4',item,item.lableRuleObj?item.lableRuleObj[scope.row[item.columnName]]:scope.row[item.columnName])">
<span>{{ item.lableRuleObj?item.lableRuleObj[scope.row[item.columnName]]:scope.row[item.columnName] }}</span>
</el-tag>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'button' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:width="item.width"
:key="item.columnName"
fixed="right"
>
<template slot-scope="scope">
<el-button v-if="isSpCombine" type="text" size="small"
:disabled="scope.row.originUuid!=null || scope.row.lockStatus===3"
@click.native.stop="intentSelectUdi(scope.row)">关联DI
</el-button>
<el-button type="text" size="small" :disabled="scope.row.lockStatus==3"
@click.native.stop="handleModifyClick(scope.row)">编辑
</el-button>
<el-button type="text" size="small"
@click.native.stop="handleDetailClick(scope.row)">详情
</el-button>
<el-dropdown size="mini" @command="(command) => handleCommand(command, scope.row)"
>
<span class="el-dropdown-link">
<i class="el-icon-d-arrow-right el-icon--right"></i>更多
</span>
<el-dropdown-menu slot="dropdown">
<!-- <el-dropdown-item command="handleDetailClick" v-if=" scope.row.lockStatus!=3"></el-dropdown-item>-->
<el-dropdown-item command="sumitLockStatus" v-if="isSpCombine" :disabled="scope.row.lockStatus===3">
提交审核
</el-dropdown-item>
<el-dropdown-item command="splitSelectUdi" v-if="isSpCombine" type="text" size="small"
:disabled="scope.row.thirdId===scope.row.nameCode || scope.row.thirdId==null || scope.row.nameCode==null || scope.row.lockStatus===3">
拆分产品
</el-dropdown-item>
<el-dropdown-item command="deleteCompanyProductRelevance">移除</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
</el-table-column>
<el-table-column
v-if="item.columnType == 'text' && executeEval(row,item.expression,true)"
:prop="item.columnName"
:label="item.columnDesc"
:sortable="item.sort"
:width="item.width"
:show-overflow-tooltip="item.tooltip"
:key="item.columnName"
>
<template slot-scope="scope">
<span :style="{color: executeFuc(scope.row,'4',item,scope.row[item.columnName])}">{{ scope.row[item.columnName] }}</span>
</template>
</el-table-column>
</template>
</el-table> </el-table>
@ -277,7 +465,7 @@ import {
updateErpProduct, updateErpProduct,
uploadSmp, uploadSmp,
thirdSysDetail, thirdSysDetail,
removeRl, sysFilter, spcombie, lockStatus, removeDiRl removeRl, sysFilterOptimize , spcombie, lockStatus, removeDiRl
} from "../../../api/basic/udiRelevance"; } from "../../../api/basic/udiRelevance";
import store from "../../../store/index"; import store from "../../../store/index";
import { import {
@ -295,7 +483,9 @@ import ThrProductsAdd from "@/views/supplier/company/ThrProductsAdd";
import selectUdiVersion from "@/views/basic/product/UdiinfoSelectVersion"; import selectUdiVersion from "@/views/basic/product/UdiinfoSelectVersion";
import basicProductEdit from "@/views/supplier/company/basicCompanyproductEdit"; import basicProductEdit from "@/views/supplier/company/basicCompanyproductEdit";
import basicProductDetail from "@/views/supplier/company/basicCompanyproductDetail" import basicProductDetail from "@/views/supplier/company/basicCompanyproductDetail"
import {
getHead,executeFuc
} from "@/utils/customConfig";
export default { export default {
data() { data() {
@ -331,6 +521,13 @@ export default {
pId: null, pId: null,
}, },
pId: 0, pId: 0,
tableHeader:[],
queryList:[],
fromList:[],
options: {
getSysFilter:[]
},
productType: null, productType: null,
defaultSys: null, defaultSys: null,
isImport: false, isImport: false,
@ -757,11 +954,11 @@ export default {
this.sysList = []; this.sysList = [];
}); });
}, },
getSysFilter() { getSysFilter(_this) {
sysFilter() sysFilterOptimize()
.then((response) => { .then((response) => {
this.loading = false; _this.loading = false;
this.filterList = response.data.list || []; _this.options.getSysFilter = response.data.list || [];
}) })
.catch(() => { .catch(() => {
this.loading = false; this.loading = false;
@ -882,7 +1079,15 @@ export default {
} }
}); });
}, },
executeFuc(row,type,clickFuc,value){
return executeFuc(this,row,type,clickFuc,value);
},
executeEval(row,expression,defaultRet){
if(expression){
return eval(expression);
}
return defaultRet;
}
} }
, ,
mounted() { mounted() {
@ -901,9 +1106,16 @@ export default {
, ,
created() { created() {
this.findBasicProductSet(); this.findBasicProductSet();
this.getList(); this.getList();getHead("basicCompanyProducts","1").then((re) => {
//
this.tableObj = re.data;
this.tableHeader = re.data.tableList;
this.queryList = re.data.queryList;
this.fromList = re.data.fromList;
this.getList();
});
this.selectSysParam(); this.selectSysParam();
this.getSysFilter(); this.getSysFilter(this);
} }
, ,
} }

Loading…
Cancel
Save