Merge remote-tracking branch 'origin/master'

master
schry 2 years ago
commit ba5a2f738f

@ -1,15 +1,15 @@
import axios from "axios";
import { Notification, MessageBox, Message, Loading } from "element-ui";
import {Notification, MessageBox, Message, Loading} from "element-ui";
import store from "@/store";
import { getAdminId, getToken } from "@/utils/auth";
import {getAdminId, getToken} from "@/utils/auth";
import errorCode from "@/utils/errorCode";
import { tansParams, blobValidate } from "@/utils/ruoyi";
import {tansParams, blobValidate} from "@/utils/ruoyi";
import cache from "@/plugins/cache";
import { saveAs } from "file-saver";
import {saveAs} from "file-saver";
let downloadLoadingInstance;
// 是否显示重新登录
export let isRelogin = { show: false };
export let isRelogin = {show: false};
axios.defaults.headers["Content-Type"] = "application/json;charset=utf-8";
// 对应国际化资源文件后缀
@ -32,6 +32,7 @@ service.interceptors.request.use(
if (getToken() && !isToken) {
// config.headers['ADMIN_TOKEN'] = getToken() // 让每个请求携带自定义token 请根据实际情况自行修改
config.headers = {
CLIENT_TYPE: "locWeb",
ADMIN_ID: getAdminId(),
ADMIN_TOKEN: getToken(),
};
@ -148,7 +149,7 @@ service.interceptors.response.use(
*/
(error) => {
console.log("err" + error);
let { message } = error;
let {message} = error;
if (message == "Network Error") {
message = "后端接口连接异常";
} else if (message.includes("timeout")) {
@ -179,7 +180,7 @@ export function download(url, params, filename) {
return tansParams(params);
},
],
headers: { "Content-Type": "application/x-www-form-urlencoded" },
headers: {"Content-Type": "application/x-www-form-urlencoded"},
responseType: "blob",
})
.then(async (data) => {

@ -9,7 +9,6 @@
<el-input v-model="unionQuery.udiCode"
placeholder="请扫描或输入UDI码"
clearable="true"
@keyup.enter.native="keyup_submit($event)"></el-input>
</el-form-item>
</el-col>

@ -8,6 +8,7 @@
<el-input v-model="filterQuery.recordCode"
style="width: 200px;"
placeholder="请输入记录号"
clearable
></el-input>
</el-form-item>
</el-col>
@ -16,6 +17,7 @@
<el-input v-model="filterQuery.cpmctymc"
style="width: 200px;"
placeholder="请输入产品名称"
clearable
></el-input>
</el-form-item>
</el-col>
@ -24,43 +26,48 @@
<el-input v-model="filterQuery.ggxh"
style="width: 200px;"
placeholder="请输入规格型号"
clearable
></el-input>
</el-form-item>
</el-col>
<el-col type="flex" :span="8" v-show='false'>
<el-form-item label="批次号:" class="query-form-item">
<el-input v-model="filterQuery.batchNo"
style="width: 200px;"
placeholder="请输入批次号"
></el-input>
</el-form-item>
</el-col>
<el-col type="flex" :span="8" v-show='false'>
<el-form-item class="query-form-item">
<el-button-group style="display:flex;">
<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-group>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col type="flex" :span="8">
<el-form-item label="批次号:" class="query-form-item">
<el-form-item label="批次号:" class="query-form-item" >
<el-input v-model="filterQuery.batchNo"
style="width: 200px;"
placeholder="请输入批次号"
clearable
></el-input>
</el-form-item>
</el-col>
<el-col type="flex" :span="8">
<el-form-item label="查询方式:" prop="traceSource" class="query-form-item">
<el-select v-model="filterQuery.traceSource" placeholder="请选择查询方式" style="width: 200px" @change="onSubmit" clearable>
<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 type="flex" :span="8">
<el-form-item label="查询方案:" prop="traceType" class="query-form-item">
<el-select v-model="filterQuery.traceType" placeholder="请选择查询方案" style="width: 200px" @change="onSubmit" clearable>
<el-option label="按UDI码查询" 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-form>
<div class="top-right-btn" style="display:flex;">
<el-button-group>
<el-button icon="el-icon-view" type="primary" @click="hideSearch">/
</el-button>
<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-group>
@ -75,14 +82,24 @@
<el-table-column label="UDI码" prop="udiCode" width="220"></el-table-column>
<el-table-column label="产品名称" prop="cpmctymc" width="180"></el-table-column>
<el-table-column label="规格型号" prop="ggxh" width="120"></el-table-column>
<el-table-column label="医疗器械注册人" prop="ylqxzcrbarmc" width="180"></el-table-column>
<el-table-column label="注册备案人" prop="ylqxzcrbarmc" width="180"></el-table-column>
<el-table-column label="注册/备案号" prop="zczbhhzbapzbh" width="180"></el-table-column>
<el-table-column label="批次号" prop="batchNo" width="180"></el-table-column>
<el-table-column label="查询人" prop="createUser" width="180"></el-table-column>
<!-- <el-table-column label="发货单位" prop="fromCorp" width="180"></el-table-column>-->
<!-- <el-table-column label="收货单位" prop="toCorp" width="180"></el-table-column>-->
<!-- <el-table-column label="所属企业" prop="companyName" width="180"></el-table-column>-->
<el-table-column label="查询方式" prop="traceType" width="120"></el-table-column>
<!-- <el-table-column label="查询方式" prop="traceSource" width="120"></el-table-column>-->
<el-table-column label="查询方式" prop="traceSource" width="120">
<template slot-scope="traceSource">
{{ formatTaskType(traceSource.row) }}
</template>
</el-table-column>
<el-table-column label="查询方案" prop="traceType" width="120">
<template slot-scope="traceType">
{{ formatTaskType1(traceType.row) }}
</template>
</el-table-column>
<el-table-column label="备注" prop="remark" width="220"></el-table-column>
<el-table-column label="操作" width="100" fixed="right">
<template slot-scope="scope">
@ -113,8 +130,7 @@
<el-row type="flex">
<el-col :span="11" type="flex">
<el-form-item label="查询方案" prop="traceType">
<el-input v-model="formView.traceType" size="small" style="width: 90%" :disabled="true"
></el-input>
<el-input v-model="traceTypeText" size="small" style="width: 90%" :disabled="true"></el-input>
</el-form-item>
</el-col>
<el-col :span="11" class="el-col">
@ -215,37 +231,33 @@
</el-form-item>
</el-col>
</el-row>
<!-- <el-row type="flex">-->
<!-- <el-col :span="11" type="flex">-->
<!-- <el-form-item label="发货单位" prop="fromCorp">-->
<!-- <el-input v-model="formView.fromCorp" size="small" style="width: 90%" :disabled="true"-->
<!-- ></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="11" class="el-col">-->
<!-- <el-form-item label="收货单位" prop="toCorp">-->
<!-- <el-input v-model="formView.toCorp" size="small"-->
<!-- style="width: 90%" :disabled="true"-->
<!-- ></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<el-row type="flex">
<el-col :span="11" type="flex">
<el-form-item label="发货单位" prop="fromCorp">
<el-input v-model="formView.fromCorp" size="small" style="width: 90%" :disabled="true"
></el-input>
</el-form-item>
</el-col>
<!-- <el-col :span="11" type="flex">-->
<!-- <el-form-item label="所属企业" prop="companyName">-->
<!-- <el-input v-model="formView.companyName" size="small" style="width: 90%" :disabled="true"-->
<!-- ></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<el-col :span="11" class="el-col">
<el-form-item label="收货单位" prop="toCorp">
<el-input v-model="formView.toCorp" size="small"
style="width: 90%" :disabled="true"
></el-input>
<el-form-item label="查询方式" prop="traceSource">
<el-input v-model="traceSourceText" size="small" style="width: 90%" :disabled="true"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row type="flex">
<el-col :span="11" type="flex">
<el-form-item label="所属企业" prop="companyName">
<el-input v-model="formView.companyName" size="small" style="width: 90%" :disabled="true"
></el-input>
</el-form-item>
</el-col>
<el-col :span="11" class="el-col">
<el-form-item label="查询方式" prop="traceType">
<el-input v-model="formView.traceType" size="small"
style="width: 90%" :disabled="true"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row type="flex">
<el-col :span="11" type="flex">
<el-form-item label="备注" prop="remark">
<el-input v-model="formView.remark" size="small" style="width: 90%" :disabled="true"
@ -254,6 +266,7 @@
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click.native="open = false" size="small">关闭</el-button>
@ -274,22 +287,72 @@ export default {
cpmctymc: null,
ggxh: null,
batchNo: null,
traceSource:null,
traceType:null,
page: 1,
limit: 10,
},
options: [
{value: 'A', label: 'UDI码查询(源头查询)'},
{value: 'B', label: '按产品信息组合查询'},
{value: 'C', label: '现场检查查询'}
],
// options: [
// {value: 'A', label: 'UDI()'},
// {value: 'B', label: ''},
// {value: 'C', label: ''}
// ],
total: 0,
loading: true,
list: [],
open: false,
formView: {}
formView: {
traceType: null,
traceSource:null,
},
traceTypes: [
{ value: 1, label: '按UDI码查询' },
{ value: 2, label: '按批次号查询' },
//{ value: 3, label: '3' },
],
traceSources: [
{ value: 1, label: '源头查询' },
{ value: 2, label: '现在检查查询' },
// { value: 3, label: '3' },
],
showSearch: true,
}
},
computed: {
traceTypeText() {
const traceType = this.traceTypes.find(item => item.value === this.formView.traceType);
return traceType ? traceType.label : '';
},
traceSourceText() {
const traceSource = this.traceSources.find(item => item.value === this.formView.traceSource);
return traceSource ? traceSource.label : '';
},
},
methods: {
//
hideSearch() {
this.showSearch = !this.showSearch;
},
formatTaskType(row) {
switch (row.traceSource) {
case 1:
return '源头查询';
case 2:
return '现在检查查询';
default:
return '查询方式有误!!';
}
},
formatTaskType1(row) {
switch (row.traceType) {
case 1:
return '按UDI码方案查询';
case 2:
return '按批次号方案查询';
default:
return '查询方案有误!!';
}
},
handleView(row){
this.list.forEach(obj => {
if (row.id == obj.id) {

@ -1,9 +1,9 @@
<template>
<div>
<el-card>
<el-form label-width="110px" v-show="showSearch" size="mini">
<el-row type="flex">
<el-col type="flex">
<el-form label-width="120px" v-show="showSearch" size="mini">
<el-row type="flex" >
<el-col type="flex" >
<el-form-item label="记录号:" prop="recordCode" class="query-form-item">
<el-input v-model="filterQuery.recordCode"
style="width: 200px"
@ -11,7 +11,7 @@
></el-input>
</el-form-item>
</el-col>
<el-col type="flex">
<el-col type="flex" >
<el-form-item label="注册企业:" prop="companyName" class="query-form-item">
<el-input v-model="filterQuery.companyName"
style="width: 200px"
@ -20,7 +20,7 @@
></el-input>
</el-form-item>
</el-col>
<el-col type="flex">
<el-col type="flex" >
<el-form-item label="DI标识:" prop="nameCode" class="query-form-item">
<el-input v-model="filterQuery.nameCode"
style="width: 200px"
@ -28,7 +28,10 @@
></el-input>
</el-form-item>
</el-col>
<el-col type="flex">
</el-row>
<el-row type="flex" >
<el-col type="flex" >
<el-form-item label="产品名称:" prop="cpmctymc" class="query-form-item">
<el-input v-model="filterQuery.cpmctymc"
style="width: 200px"
@ -36,9 +39,7 @@
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row type="flex">
<el-col type="flex">
<el-col type="flex" >
<el-form-item label="规格型号:" prop="ggxh" class="query-form-item">
<el-input v-model="filterQuery.ggxh"
style="width: 200px"
@ -46,7 +47,7 @@
></el-input>
</el-form-item>
</el-col>
<el-col type="flex">
<el-col type="flex" >
<el-form-item label="医疗器械注册人:" prop="ylqxzcrbarmc" class="query-form-item">
<el-input v-model="filterQuery.ylqxzcrbarmc"
style="width: 200px"
@ -54,7 +55,10 @@
></el-input>
</el-form-item>
</el-col>
<el-col type="flex">
</el-row>
<el-row type="flex" >
<el-col type="flex" >
<el-form-item label="注册备案号:" prop="zczbhhzbapzbh" class="query-form-item">
<el-input v-model="filterQuery.zczbhhzbapzbh"
style="width: 200px"
@ -62,8 +66,6 @@
></el-input>
</el-form-item>
</el-col>
<el-col type="flex">
</el-col>
</el-row>
</el-form>
<div class="top-right-btn" style="display:flex;">

@ -4,20 +4,13 @@
<el-form label-width="110px" v-show="showSearch" size="mini">
<el-row type="flex">
<el-col type="flex">
<!-- <el-form-item label="任务类型:" prop="taskType" class="query-form-item">-->
<!-- <el-input v-model="filterQuery.taskType"-->
<!-- style="width: 200px"-->
<!-- placeholder="请选择任务类型"-->
<!-- @keyup.native="onSubmit"-->
<!-- ></el-input>-->
<!--&lt;!&ndash; <el-select v-model="filterQuery.taskType" placeholder="请选择任务类型">&ndash;&gt;-->
<!--&lt;!&ndash; <el-option label="关联关系" value="1"></el-option>&ndash;&gt;-->
<!--&lt;!&ndash; <el-option label="入库" value="2"></el-option>&ndash;&gt;-->
<!--&lt;!&ndash; <el-option label="出库" value="3"></el-option>&ndash;&gt;-->
<!--&lt;!&ndash; </el-select>&ndash;&gt;-->
<!-- </el-form-item>-->
<el-form-item label="任务类型:" prop="taskType" class="query-form-item">
<el-select v-model="filterQuery.taskType" placeholder="请选择任务类型" style="width: 200px" @change="onSubmit" clearable>
<el-select v-model="filterQuery.taskType"
placeholder="请选择任务类型"
style="width: 200px"
@change="onSubmit"
clearable
>
<el-option label="关联关系" value="1"></el-option>
<el-option label="入库" value="2"></el-option>
<el-option label="出库" value="3"></el-option>
@ -27,12 +20,6 @@
</el-col>
<el-col type="flex">
<el-form-item label="任务状态:" prop="status" class="query-form-item">
<!-- <el-input v-model="filterQuery.status"-->
<!-- style="width: 200px"-->
<!-- placeholder="请选择任务状态"-->
<!-- @keyup.native="onSubmit"-->
<!-- clearable-->
<!-- ></el-input>-->
<el-select v-model="filterQuery.status" placeholder="请选择任务状态" style="width: 200px" @change="onSubmit" clearable>
<el-option label="未处理" value="1"></el-option>
<el-option label="正在处理" value="2"></el-option>

Loading…
Cancel
Save