新增器械公告功能

master
yuanwei 1 year ago
parent 95d477fc70
commit 63a5c2e60d

@ -1,7 +1,7 @@
<template> <template>
<div> <div>
<el-card> <el-card>
<el-form v-if="queryList && queryList.length > 0" :model="filterQuery" class="query-form" size="mini" label-width="120px" :inline="true"> <el-form v-if="queryList && queryList.length > 0" :model="filterQuery" class="query-form" size="mini" label-width="120px" v-show="showSearch" :inline="true">
<el-row style=" display:flex; flex-wrap: wrap; "> <el-row style=" display:flex; flex-wrap: wrap; ">
<template v-for="(item, index) in queryList" > <template v-for="(item, index) in queryList" >
<el-form-item v-if="item.columnType == 'input' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`" :key="item.id"> <el-form-item v-if="item.columnType == 'input' && executeEval(row,item.expression,true)" :label="item.columnDesc+`:`" :key="item.id">
@ -67,15 +67,24 @@
></el-date-picker> ></el-date-picker>
</el-form-item> </el-form-item>
</template> </template>
<el-form-item>
<el-button-group>
<el-button type="primary" icon="el-icon-search" @click="onSubmit"></el-button>
<el-button type="primary" icon="el-icon-refresh" @click="onReset"></el-button>
<el-button type="primary" icon="el-icon-plus" @click="addOrderMuti"></el-button>
</el-button-group>
</el-form-item>
</el-row> </el-row>
</el-form> </el-form>
<div class="top-right-btn">
<el-button-group>
<el-button icon="el-icon-view" type="primary" @click="hideSearch">/</el-button>
<el-button
type="primary"
icon="el-icon-refresh"
@click="onReset"
>重置
</el-button>
<el-button type="primary" icon="el-icon-search" @click="onSubmit"
>查询
</el-button
>
<el-button type="primary" icon="el-icon-plus" @click="(event) => addOrderMuti()">新增</el-button>
</el-button-group>
</div>
<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>
<template v-for="(item, index) in tableHeader"> <template v-for="(item, index) in tableHeader">
<el-table-column <el-table-column
@ -209,6 +218,7 @@ export default {
name: "anncmntDev", name: "anncmntDev",
data() { data() {
return { return {
showSearch: true,
filterQuery: { filterQuery: {
page: 1, page: 1,
limit: 10, limit: 10,
@ -221,11 +231,51 @@ export default {
1: "新增器械公告", 1: "新增器械公告",
2: "编辑器械公告", 2: "编辑器械公告",
}, },
inputQuery:{},
orderMutiSetVisible: false, orderMutiSetVisible: false,
actDateRange: [],
pickerOptions: {
shortcuts: [
{
text: "最近一周",
onClick(picker) {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
picker.$emit("pick", [start, end]);
},
},
{
text: "最近一个月",
onClick(picker) {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
picker.$emit("pick", [start, end]);
},
},
{
text: "最近三个月",
onClick(picker) {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
picker.$emit("pick", [start, end]);
},
},
],
},
}; };
}, },
methods: { methods: {
onSubmit() { onSubmit() {
if (this.actDateRange !== null) {
this.filterQuery.startTime = this.actDateRange[0];
this.filterQuery.endTime = this.actDateRange[1];
} else {
this.filterQuery.startTime = null;
this.filterQuery.endTime = null;
}
this.filterQuery.page = 1; this.filterQuery.page = 1;
this.getList(); this.getList();
}, },
@ -239,6 +289,9 @@ export default {
}; };
this.getList(); this.getList();
}, },
hideSearch() {
this.showSearch = !this.showSearch;
},
handleCurrentChange(val) { handleCurrentChange(val) {
this.filterQuery.page = val.page; this.filterQuery.page = val.page;
this.getList(); this.getList();
@ -249,12 +302,7 @@ export default {
}, },
addOrderMuti(){ addOrderMuti(){
this.inputQuery={ this.inputQuery={
curInv: null,
checkUse: null,
fromCorp: null,
targetAction: null,
remark: null,
updateTime: null,
} }
this.formName=1; this.formName=1;
this.orderMutiSetVisible = true; this.orderMutiSetVisible = true;

@ -1,124 +1,311 @@
<template> <template>
<div> <div>
<el-form :model="inputQuery" label-width="120px" >
<el-card> <el-card>
<el-form :model="inputQuery" label-width="120px" > <div style="font-size: 25px;font-weight: bold;margin-bottom: 20px;">产品信息</div>
<template v-for="(itemRow, indexRow) in fromList">
<el-row :gutter="20" class="el-row" type="flex"> <el-row :gutter="20" class="el-row" type="flex">
<template v-for="(item, index) in itemRow.list"> <el-col class="el-col" type="flex">
<el-col :span="item.width" class="el-col" type="flex"> <el-form-item prop="productName" label="产品名称:" class="query-form-item">
<div class="text item"> <el-input
<el-form-item v-if="item.columnType =='input'" :rules="item.checkRulesObj" :prop="item.columnName"> style="width: 80%"
<span slot="label"> size="small"
{{item.columnDesc}} placeholder="请输入产品名称"
</span> v-model="inputQuery.productName"
<el-input ></el-input>
v-model="inputQuery[item.columnName]" </el-form-item>
:style="item.style" </el-col>
:size="item.size" <el-col class="el-col" type="flex">
:type="item.inputType" <el-form-item label="产品英文名称:" class="query-form-item">
:placeholder="item.columnDesc" <el-input
:disabled="item.disabled" style="width: 80%"
@change="executeFuc($event,item,'2')" size="small"
></el-input> placeholder="请输入产品英文名称"
</el-form-item> v-model="inputQuery.enProductName"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="规格型号:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入规格型号"
v-model="inputQuery.modelSpec"
></el-input>
</el-form-item>
</el-col>
<el-col class="el-col" type="flex">
<el-form-item label="注册/备案证号:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入注册/备案证号"
v-model="inputQuery.regCertCode"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="生产企业:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入生产企业"
v-model="inputQuery.manuName"
></el-input>
</el-form-item>
</el-col>
<el-col class="el-col" type="flex">
<el-form-item label="生产企业英文名称:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入生产企业英文名称"
v-model="inputQuery.enManuName"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="生产企业统一社会信用号:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入生产企业统一社会信用号"
v-model="inputQuery.manuCertCoe"
></el-input>
</el-form-item>
</el-col>
<el-col class="el-col" type="flex">
<el-form-item label="代理人名称:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入代理人名称"
v-model="inputQuery.agentName"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="代理人统一社会信用号:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入代理人统一社会信用号"
v-model="inputQuery.agentCertCode"
></el-input>
</el-form-item>
</el-col>
<el-col class="el-col" type="flex">
<el-form-item label="最小销售产品标识:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入最小销售产品标识"
v-model="inputQuery.nameCode"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="批次号:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入批次号"
v-model="inputQuery.batchNo"
></el-input>
</el-form-item>
</el-col>
<el-col class="el-col" type="flex">
<el-form-item label="生产日期:" class="query-form-item">
<el-date-picker
v-model="inputQuery.productionDate"
style="width: 80%"
value-format="yyyy-MM-dd"
type="date"
placeholder="请输入生产日期"
></el-date-picker>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="10" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="失效日期:" class="query-form-item">
<el-form-item v-if="item.columnType =='radio'" :prop="item.columnName"> <el-date-picker
<span slot="label"> v-model="inputQuery.expireDate"
{{item.columnDesc}} style="width: 80%"
</span> value-format="yyyy-MM-dd"
<el-radio-group :style="item.style" v-model="inputQuery[item.columnName]"> type="date"
<el-radio placeholder="请输入失效日期"
v-for="dict in item.lableRuleObj" ></el-date-picker>
:key="parseInt(dict.value)" </el-form-item>
:label="parseInt(dict.value)" </el-col>
:disabled="item.disabled"
>{{dict.label}}</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item v-if="item.columnType =='select'" :prop="item.columnName">
<span slot="label">
{{item.columnDesc}}
</span>
<el-select v-model="inputQuery[item.columnName]" :style="item.style">
<el-option
v-for="dict in item.lableRuleObj"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
<el-form-item v-if="item.columnType =='selectServer'" :prop="item.columnName">
<span slot="label">
{{item.columnDesc}}
</span>
<el-select
v-model="inputQuery[item.columnName]"
:placeholder="item.columnDesc"
@change="executeFuc($event,'5',item.clickFuc)"
:disabled="executeEval(null,item.disabledFuc,false)"
filterable
remote
:remote-method="(query) => executeFuc(query,'5',item.dataFuc)"
clearable>
<el-option
v-for="item in options[item.dataFuc]"
:key="item.code"
:label="item.label"
:value="item.code"
>
<span style="float: left">{{ item.label }}</span>
<span style="float: right; color: #8492a6; font-size: 13px">{{
item.code
}}</span>
</el-option>
</el-select>
</el-form-item>
<el-form-item v-if="item.columnType =='date'" :rules="item.checkRulesObj" :prop="item.columnName">
<span slot="label">
{{item.columnDesc}}
</span>
<el-date-picker
v-model="inputQuery[item.columnName]"
:style="item.style"
value-format="yyyy-MM-dd"
type="date"
:placeholder="item.columnDesc"
></el-date-picker>
</el-form-item>
<el-form-item v-if="item.columnType =='treeCustom'" :prop="item.columnName">
<span slot="label">
{{item.columnDesc}}
</span>
<treeselect
v-model="inputQuery[item.columnName]"
:options="menuOptions"
:normalizer="normalizer"
:show-count="true"
:placeholder="item.columnName"
/>
</el-form-item>
</div>
</el-col>
</template>
</el-row> </el-row>
</template> </el-card>
<el-card>
<div style="font-size: 25px;font-weight: bold;margin-bottom: 20px;">公告信息</div>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="公告类型:" class="query-form-item">
<el-select
size="small"
v-model="inputQuery.annType"
style="width: 80%"
placeholder="公告类型"
>
<el-option label="注销注册证公告" value="1"></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="3"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col class="el-col" type="flex">
<el-form-item label="检查方式:" class="query-form-item">
<el-select
size="small"
v-model="inputQuery.checkType"
style="width: 80%"
placeholder="检查方式"
>
<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 :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="公告发布索引号:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入公告发布索引号"
v-model="inputQuery.publicCode"
></el-input>
</el-form-item>
</el-col>
<el-col class="el-col" type="flex">
<el-form-item label="发布人:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入发布人"
v-model="inputQuery.publicName"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="发布主题分类:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入发布主题分类"
v-model="inputQuery.publicSubject"
></el-input>
</el-form-item>
</el-col>
<el-col class="el-col" type="flex">
<el-form-item label="发布时间:" class="query-form-item">
<el-date-picker
v-model="inputQuery.publicTime"
style="width: 80%"
value-format="yyyy-MM-dd"
type="date"
placeholder="请输入发布时间"
></el-date-picker>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="发布标题:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入发布标题"
v-model="inputQuery.publicTitle"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="发布来源名称:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入发布来源名称"
v-model="inputQuery.sourceName"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="发布来源地址:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
placeholder="请输入发布来源地址"
v-model="inputQuery.sourceUrl"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="公告内容:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
type="textarea"
placeholder="请输入公告内容"
v-model="inputQuery.annContent"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col class="el-col" type="flex">
<el-form-item label="检查异常信息:" class="query-form-item">
<el-input
style="width: 80%"
size="small"
type="textarea"
placeholder="请输入检查异常信息"
v-model="inputQuery.errContent"
></el-input>
</el-form-item>
</el-col>
</el-row>
<div style='text-align: center; margin-bottom: 10px;margin-top: 18px ;'> <div style='text-align: center; margin-bottom: 10px;margin-top: 18px ;'>
<el-button @click="closeDialog"></el-button> <el-button @click="closeDialog"></el-button>
<el-button type="primary" @click="submitInv"></el-button> <el-button type="primary" @click="submitInv"></el-button>
</div> </div>
</el-form>
</el-card> </el-card>
</el-form>
</div> </div>
</template> </template>
<script> <script>
import {savegg} from "@/api/anno/anncmntDev"; import {savegg} from "@/api/anno/anncmntDev";
import {
getHead,executeFuc
} from "@/utils/customConfig";
export default { export default {
name: "indexDialog", name: "indexDialog",
@ -138,13 +325,7 @@ export default {
}, },
data() { data() {
return { return {
tableHeader:[],
queryList:[],
fromList:[],
tableObj:[],
options: {
},
} }
}, },
methods: { methods: {
@ -175,25 +356,9 @@ 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;
}
}, },
components: {}, components: {},
created() { created() {
getHead("anncmntDev","1").then((re) => {
//
this.tableObj = re.data;
this.tableHeader = re.data.tableList;
this.queryList = re.data.queryList;
this.fromList = re.data.fromList;
});
}, },
} }
</script> </script>

Loading…
Cancel
Save