首营资质管理功能新增

featFunction
anthonywj 2 years ago
parent dfa73e1e29
commit 821bbd07d3

@ -1,6 +1,6 @@
{
"BASE_URL": "http://127.0.0.1:9906",
"SERVER_IP": "http://127.0.0.1:9906",
"BASE_URL": "http://192.168.0.109:9906",
"SERVER_IP": "http://192.168.0.109:9906",
"hosp_name": "福建省XX市医院"
}

@ -43,6 +43,7 @@ export function auditSupCert(query) {
export function deleteCompanyCert(query) {
return axios(
{

@ -0,0 +1,54 @@
import axios from "../../utils/axios";
export function filterCertSet(query) {
return axios(
{
url: "/sup/cert/set/filter",
method: "get",
params: query
}
);
}
export function delSupCertCert(query) {
return axios(
{
url: "/sup/cert/set/delete",
method: "post",
data: query
}
);
}
export function addSupCertSet(query) {
return axios(
{
url: "/sup/cert/set/add",
method: "post",
data: query
}
);
}
export function modifySupCertSet(query) {
return axios(
{
url: "/sup/cert/set/update",
method: "post",
data: query
}
);
}
export function selectAllCert(query) {
return axios(
{
url: "/sup/info/selectAllCert",
method: "post",
data: query
}
);
}

@ -98,5 +98,17 @@ export function getSubCompany(query) {
export function bindCorp(query) {
return axios(
{
url: "/sup/company/selectBind",
method: "post",
data: query
}
);
}

@ -7,6 +7,13 @@ export function getCompanyList(query) {
params: query
});
}
export function getCompanyBySup(query) {
return axios({
url: "/sup/manufacturer/getCompanyBySup",
method: "get",
params: query
});
}
export function getCompanyInfo(query) {
return axios({

@ -44,4 +44,13 @@ export function auditSupProduct(data) {
data: data
})
}
export function bindProduct(data) {
return axios({
url: '/sup/product/selectBind',
method: 'post',
data: data
})
}

@ -53,6 +53,7 @@ import stockOrderInCode from "../views/warehouse/stockOrderInCode";
import stockOrderDelSearch from "../views/warehouse/stockOrderDelSearch";
import stockOrderInvSearch from "../views/warehouse/stockOrderInvSearch";
import stockOrderDelete from "../views/warehouse/stockOrderDelete";
import stockOrderChange from "../views/warehouse/stockOrderChange";
import stockOrderEditor from "../views/warehouse/stockOrderEditor";
import stockOrderSearch from "../views/warehouse/stockOrderSearch";
import stockOrderNew from "../views/warehouse/stockOrderNew";
@ -117,6 +118,22 @@ import sysUdimsDownloadData from "../views/thrsys/SysUdimsDownloadData";
import thrProductsAddDi from "@/views/thrsys/ThrProductsAddDi";
//资质审核
import supCompany from "../views/purchase/supCompanyAdd.vue";
import supCompanyAudit from "../views/purchase/supCompanyAudit.vue";
import supCompanySearch from "../views/purchase/supCompanySearch.vue";
import supManufacturer from "../views/purchase/supManufacturerAdd.vue";
import supManufacturerAudit from "../views/purchase/supManufacturerAudit.vue";
import supManufacturerSearch from "../views/purchase/supManufacturerSearch.vue";
import supProduct from "../views/purchase/supProductAdd.vue";
import supProductAudit from "../views/purchase/supProductAudit.vue";
import supProductSearch from "../views/purchase/supProductSearch.vue";
import supCertAudit from "../views/purchase/supCertAudit.vue";
import supCertSearch from "../views/purchase/supCertSearch.vue";
import supCertSet from "../views/purchase/supCertSet.vue";
import supCertificationAdd from "../views/purchase/supCertificationAdd.vue";
const err401 = r =>
require.ensure([], () => r(require("../views/error/err401.vue")), "home");
@ -464,8 +481,6 @@ export const asyncRouterMap = [
]
},
{
path: "/basicProduct",
redirect: "/udiInfo/UdiInfoManage",
@ -601,6 +616,205 @@ export const asyncRouterMap = [
]
},
{
path: "/firstCamp",
component: Home,
redirect: "/firstCamp/certAdd",
icon: "tongyong",
name: "首营资质",
noDropdown: false,
meta: {
authRule: ["firstCamp"]
},
children: [
{
path: "/certAdd",
redirect: "/certAdd/supplierAdd",
name: "资质新增",
hidden: true,
component: Empty,
meta: {
authRule: ["firstCamp/certAdd"]
},
children: [
{
path: "supplierAdd",
name: "供应商资质新增",
component: supCompany,
meta: {
authRule: ["firstCamp/certAdd/supplierAdd"]
}
},
{
path: "manufacturerAdd",
name: "生产企业资质新增",
component: supManufacturer,
meta: {
authRule: ["firstCamp/certAdd/manufacturerAdd"]
}
},
{
path: "productAdd",
name: "产品资质新增",
component: supProduct,
meta: {
authRule: ["firstCamp/certAdd/productAdd"]
}
},
]
},
{
path: "certAudit",
component: supCertAudit,
name: "资质审核",
icon: "",
meta: {
authRule: ["firstCamp/certAudit"]
}
},
{
path: "certSearch",
component: supCertSearch,
name: "资质查询",
icon: "",
meta: {
authRule: ["firstCamp/certSearch"]
}
},
{
path: "certSet",
component: supCertSet,
name: "资质上传设置",
icon: "",
meta: {
authRule: ["firstCamp/certSet"]
}
},
{
path: "/supplierManage",
redirect: "/supplierManage/supplierAdd",
name: "供应商资质管理",
component: Empty, hidden: true,
meta: {
authRule: ["firstCamp/supplierManage"]
},
children: [
{
path: "supplierAdd",
name: "供应商资质新增",
component: supCompany,
meta: {
authRule: ["firstCamp/supplierManage/supplierAdd"]
}
},
{
path: "supplierAudit",
name: "供应商资质审核",
component: supCompanyAudit,
meta: {
authRule: ["firstCamp/supplierManage/supplierAudit"]
}
},
{
path: "supplierSearch",
name: "供应商资质查询",
component: supCompanySearch,
meta: {
authRule: ["firstCamp/supplierManage/supplierSearch"]
}
},
]
},
{
path: "/manufacturerManage",
redirect: "/manufacturerManage/manufacturerAdd",
name: "生产企业资质管理", hidden: true,
component: Empty,
meta: {
authRule: ["firstCamp/manufacturerManage"]
},
children: [
{
path: "manufacturerAdd",
name: "生产企业资质新增",
component: supManufacturer,
meta: {
authRule: ["firstCamp/manufacturerManage/manufacturerAdd"]
}
},
{
path: "manufacturerAudit",
name: "生产企业资质审核",
component: supManufacturerAudit,
meta: {
authRule: ["firstCamp/manufacturerManage/manufacturerAudit"]
}
},
{
path: "manufacturerSearch",
name: "生产企业资质查询",
component: supManufacturerSearch,
meta: {
authRule: ["firstCamp/manufacturerManage/manufacturerSearch"]
}
},
]
},
{
path: "/productManage",
redirect: "/productManage/productAdd",
name: "产品资质管理", hidden: true,
component: Empty,
meta: {
authRule: ["firstCamp/productManage"]
},
children: [
{
path: "productAdd",
name: "产品资质新增",
component: supProduct,
meta: {
authRule: ["firstCamp/productManage/productAdd"]
}
},
{
path: "supProductAudit",
name: "产品资质审核",
component: supProductAudit,
meta: {
authRule: ["firstCamp/productManage/supProductAudit"]
}
},
{
path: "supProductSearch",
name: "产品资质查询",
component: supProductSearch,
meta: {
authRule: ["firstCamp/productManage/supProductSearch"]
}
},
]
},
]
},
{
path: "/supplierManagement",
redirect: "/supplierManagement/config/index",
@ -1006,6 +1220,15 @@ export const asyncRouterMap = [
}
},
{
path: "stockOrderChange",
component: stockOrderChange,
name: "单据流转查询",
meta: {
authRule: ["stock/stockOrderChange"]
}
},
]
},
@ -1200,6 +1423,14 @@ export const asyncRouterMap = [
authRule: ["basic/basicCompany"]
}
},
{
path: "supCertificationAdd",
name: "本企业资质",
component: supCertificationAdd,
meta: {
authRule: ["basic/supCertificationAdd"]
}
},
{
path: "basicCompanyProduct",
name: "本企业产品",

@ -393,6 +393,7 @@ export default {
selectDrugDialogVisible: false,
selectSingleUnitVisible: false,
list: [],
loading:false,
sysList: [],
total: 0,
multipleSelection: [],

@ -0,0 +1,159 @@
<template>
<div>
<el-card class="el-card">
<div>
<el-form :inline="true" :model="query" style="display: flex" size="mini">
<el-form-item class="query-form-item">
<el-input v-model="query.key" placeholder="搜索" style="width: 300px" clearable="true"></el-input>
</el-form-item>
<el-form-item style="display: flex">
<el-button-group>
<el-button type="primary" icon="search" @click="getList"></el-button>
<el-button type="primary" size="mini" icon="search" @click="combine"
:loading="combineLoading"
>选入
</el-button>
</el-button-group>
</el-form-item>
</el-form>
<el-table
v-loading="loading"
:data="list"
highlight-current-row
@current-change="handleSelectChange"
style="width: 100%"
>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="往来单位编码"
prop="erpId"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="第三方主系统ID"
prop="thirdId"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="名称"
prop="name"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="简写"
prop="spell"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="社会信用号"
prop="creditNo"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="地址"
prop="addr"
show-overflow-tooltip
></el-table-column>
</el-table>
</div>
</el-card>
<el-pagination
:page-size="query.limit"
@current-change="handleCurrentChange"
layout="prev, pager, next"
:total="total"
:current-page="query.page"
></el-pagination>
</div>
</template>
<script>
import {combineSingle, getBasicUnitMaintains} from "../../api/basic/basicUnitMaintain";
export default {
name: "combinType",
props: {
closeDialog: {
type: Function,
required: true,
},
},
data() {
return {
query: {
key: "",
page: 1,
limit: 20,
},
total: 0,
loading: false,
list: [],
currentRow: null,
combineLoading: false,
};
},
methods: {
handlepageChange(val) {
this.unitQuery.page = val;
this.getList();
},
handleErppageChange(val) {
this.erpQuery.page = val;
this.getErpList();
},
onReset() {
this.$router.push({
path: "",
});
this.query = {
key: "",
page: 1,
limit: 20,
};
this.getList();
},
getList() {
this.loading = true;
getBasicUnitMaintains(this.query)
.then((response) => {
this.loading = false;
this.list = response.data.page.list || [];
this.total = response.data.page.total || 0;
})
.catch(() => {
this.loading = false;
this.list = [];
this.total = 0;
});
},
handleSelectChange(val) {
this.currentRow = val;
},
handleCurrentChange(val) {
this.query.page = val;
this.getList();
},
combine() {
this.closeDialog(this.currentRow);
},
handleSelectionUdiChange(val) {
console.log("----" + val[0].id);
this.multipleUdiSelection = val;
},
},
created() {
},
};
</script>
<style scoped>
</style>

@ -8,11 +8,23 @@
>
<el-card class="el-card">
<div style="display: flex; ">
<div>
<span>
本企业信息审核状态
<el-tag :type="(inputQuery.auditStatus) | statusFilterType">
{{ checkFlag[inputQuery.auditStatus] }}
</el-tag>
</span>
</div>
<div style="float:right ;margin-top: -20px">
<el-button
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 0"
@click="onModifySubmit(0)"
>草稿保存
</el-button
@ -21,12 +33,24 @@
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 0|| inputQuery.auditStatus == 6"
@click="onModifySubmit(6)"
>提交审核
</el-button
>
<el-button
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 4|| inputQuery.auditStatus == 1|| inputQuery.auditStatus == 2"
@click="onModifySubmit(4)"
>提交变更
</el-button
>
</div>
<el-row :gutter="20" class="el-row" type="flex" style="margin-top: 20px">
<el-row :gutter="20" class="el-row" type="flex" style="margin-top: 25px">
<el-col :span="10" class="el-col">
<el-form-item label="企业名称:" label-width="150px" prop="companyName">
<el-input
@ -123,7 +147,14 @@
text-align: right;
margin-bottom: 8px;"
>
<el-button type="primary" size="mini" icon="search" @click="addCert"
<el-button type="primary" size="mini" icon="search" @click="selectCert"
style="text-align:right"
>选入资质证书
</el-button
>
<el-button type="primary" size="mini" icon="search" @click="addCert()"
style="text-align:right"
>添加资质证书
</el-button
@ -136,7 +167,7 @@
style="width: 100%">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="证书名称" prop="name"></el-table-column>
<el-table-column label="证书编号" prop="name"></el-table-column>
<el-table-column label="证书编号" prop="code"></el-table-column>
<el-table-column label="有效期" prop="vailDate"></el-table-column>
<el-table-column label="失效期" prop="expireDate"></el-table-column>
<el-table-column label="审核状态" prop="auditStatus" width="120">
@ -146,10 +177,29 @@
</el-tag>
</template>
</el-table-column>
<el-table-column label="状态" prop="status" width="120">
<template slot-scope="scope">
<el-tag :type="(scope.row.status) | statusType">
{{ statusFlag[scope.row.status] }}
</el-tag>
</template>
</el-table-column>
<el-table-column label="备注" prop="remark"></el-table-column>
<el-table-column label="操作" fixed="right" width="180">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native="addCert(scope.row)"
v-if="scope.row.auditStatus == 0 || scope.row.auditStatus == 2|| scope.row.auditStatus == 6"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@ -160,10 +210,30 @@
<el-button
type="text"
size="small"
v-if="scope.row.auditStatus == 0 || scope.row.auditStatus == 2|| scope.row.auditStatus == 6"
@click.native="deleteCompanyCert(scope.row)"
>删除
</el-button
>
<el-button
type="text"
size="small"
v-if=" scope.row.auditStatus == 1 && scope.row.status==0"
@click.native="disableCert(scope.row,1)"
>禁用
</el-button
>
<el-button
type="text"
size="small"
v-if=" scope.row.auditStatus == 1 && scope.row.status==1"
@click.native="disableCert(scope.row,0)"
>启用
</el-button
>
</template>
</el-table-column>
</el-table>
@ -178,7 +248,7 @@
<el-dialog
title="添加资质证书"
:title="formMap[formName]"
:visible.sync="addCertVisible"
:close-on-click-modal="false"
:close-on-press-escape="false"
@ -191,10 +261,28 @@
:closeDialog="closeLocalDialog"
:inputQuery="inputQuery"
:addType="addType"
:editTye="editTye"
></companyAddCert>
</el-dialog>
<el-dialog
title="选入资质证书"
:visible.sync="selectCertVisible"
:close-on-click-modal="false"
:close-on-press-escape="false"
width="70%"
v-if="selectCertVisible"
append-to-body
@close='closeLocalDialog'
>
<supCertSetSelectDialog
:certType="certType"
:closeDialog="closeLocalDialog"
></supCertSetSelectDialog>
</el-dialog>
</el-form>
</div>
</template>
@ -210,8 +298,11 @@ import {
CodeToText,
TextToCode,
} from "element-china-area-data";
import {filterCompanyCert, deleteCompanyCert} from "../../api/purchase/companyCert";
import {filterCompanyCert, deleteCompanyCert, updateCompanyCert} from "../../api/purchase/companyCert";
import companyAddCert from "./../purchase/supCertAddDialog";
import supCertSetSelectDialog from "./../purchase/supCertSetSelectDialog";
import draggable from "vuedraggable";
import {BASE_URL} from "@/config/app";
import {getUUID} from "@/utils/strUtil";
@ -220,8 +311,6 @@ import {getCompany} from "@/api/warehouse/company";
export default {
name: "supCompanyEdit",
data() {
return {
inputQuery: {},
@ -299,6 +388,7 @@ export default {
certFileUrl: "",
url: 'http://127.0.0.1:9996/udiwms/image/register/file/getImage?type=image1&name=t11111.jpg',
certQuery: {
type: 1,
page: 1,
limit: 20
},
@ -306,6 +396,7 @@ export default {
certTotal: 0,
certLoading: false,
addCertVisible: false,
certType: 1,
salesmanQuery: {
name: "",
page: 1,
@ -334,17 +425,29 @@ export default {
companyEditDisabled: true,
companyEditButtonStr: "编辑",
addType: "1", //1:2.3.
editTye: 1,
checkFlag: {
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
statusFlag: {
0: "正常",
1: "禁用",
},
formName: 1,
formMap: {
1: "新增本企业资质证书",
2: "编辑本企业资质证书",
},
selectCertVisible: false,
};
},
created() {
this.getCompanyCertList();
this.getCompanyInfo();
this.headers = {
@ -353,13 +456,13 @@ export default {
};
},
components: {
draggable, companyAddCert
draggable, companyAddCert, supCertSetSelectDialog
},
methods: {
getCompanyInfo() {
let query={
customerId:this.$store.getters.customerId
let query = {
customerId: this.$store.getters.customerId
}
getCompany(query)
.then((response) => {
@ -429,6 +532,20 @@ export default {
},
disableCert(row, status) {
row.status = status;
updateCompanyCert(row).then(response => {
this.loading = false;
if (response.code === 20000) {
this.$message.success("更新成功!");
this.getCompanyCertList();
} else {
this.$message.error(response.message);
}
});
},
cancelDialog() {
this.closeDialog();
@ -436,6 +553,7 @@ export default {
closeLocalDialog() {
this.addCertVisible = false;
this.selectCertVisible = false;
this.getCompanyCertList();
},
@ -445,15 +563,22 @@ export default {
this.inputQuery.areaCode = value.toString();
},
addCert(index, row) {
this.inputQuery.id = '';
if (this.$isNotBlank(row) && this.$isNotBlank(row.id)) {
this.inputQuery.id = row.id;
addCert(row) {
if (this.$isNotBlank(row)) {
this.formName = 2
this.inputQuery.formData = row;
this.editTye = 2;
} else {
this.formName = 1;
this.editTye = 1;
}
this.addCertVisible = true;
},
selectCert() {
this.selectCertVisible = true;
},
toViewCompanyCert(row) {
this.certFileUrl = BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name=";
window.open(this.certFileUrl + row.filePath);
@ -516,10 +641,22 @@ export default {
0: "warning",
1: "success",
2: "danger",
4: "warning",
6: "warning",
};
return statusMap[status];
},
statusType(status) {
const statusMap = {
0: "success",
1: "warning",
};
return statusMap[status];
},
},
};
</script>

@ -55,7 +55,7 @@
</el-table-column>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="最222小销售产品标识"
label="最小销售产品标识"
prop="nameCode"
width="140"
show-overflow-tooltip
@ -967,13 +967,13 @@ export default {
});
},
cellClass(row){
if (row.columnIndex === 0) {
return 'disabledCheck'
}
cellClass(row){
if (row.columnIndex === 0) {
return 'disabledCheck'
}
},
selectExport() {
var selectData = this.multipleSelection;
if (selectData == null || selectData.length == 0) {
this.$message.warning("请先选入产品!");
@ -982,7 +982,7 @@ export default {
if (this.repEditQuery.price<0) {
this.$message.error("产品价格不能小于0元");
return;
}
}
this.postQuery.rlIds.push(selectData.id);
this.allExport();
@ -1047,13 +1047,13 @@ export default {
});
},
handleSelectionChange(selection) {
this.radioCheck=selection.id;
this.radioCheck=selection.id;
this.curSelectDi = selection;
if (selection.length > 1) {
this.$refs.diList.clearSelection();
this.$refs.diList.toggleRowSelection(selection.pop());
}
this.multipleSelection = selection
this.currentRow = selection;
this.replTitle = "(" + this.currentRow.cpmctymc + ")" + "产品信息补齐:";
@ -1185,7 +1185,7 @@ export default {
<style scoped>
.el-table .disabledCheck .cell .el-checkbox .el-checkbox__input{
display: none !important;
display: none !important;
}
.itemTag {
float: left;

@ -0,0 +1,881 @@
<template>
<div>
<el-card>
<el-form :inline="true" :model="filterQuery" size="mini">
<el-row>
<el-form-item class="query-form-item">
<el-input v-model="filterQuery.unionCode" placeholder="DI/医保编码/商品条码"
clearable="true"></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input v-model="filterQuery.cpmctymc" placeholder="产品通用名" clearable="true"></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input v-model="filterQuery.ggxh" placeholder="规格型号" clearable="true"></el-input>
</el-form-item>
</el-row>
<el-row>
<el-form-item class="query-form-item">
<el-input v-model="filterQuery.ylqxzcrbarmc" placeholder="生产企业/注册备案人"
clearable="true"></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input v-model="filterQuery.supName" placeholder="配送企业" clearable="true"></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input v-model="filterQuery.thrPiId" placeholder="第三方产品编码" clearable="true"></el-input>
</el-form-item>
<el-form-item>
<el-button-group>
<el-button type="primary" icon="el-icon-refresh" @click="onReset"></el-button>
<el-button type="primary" icon="search" @click="submitSearch"></el-button>
<el-button type="primary" icon="search" @click="selectExport"
>选中导入
</el-button>
</el-button-group>
</el-form-item>
</el-row>
</el-form>
<el-table
v-loading="loading"
:data="list"
style="width: 100%"
ref="diList"
highlight-current-row
:header-cell-class-name="cellClass"
@current-change="handleSelectionChange"
>
<el-table-column label width="45">
<template slot-scope="scope">
<el-radio :label="scope.row.id" v-model="radioCheck"><span></span></el-radio>
</template>
</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="thirdId"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="生产企业"
prop="ylqxzcrbarmc"
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="zczbhhzbapzbh"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="器械类别"
prop="qxlb"
show-overflow-tooltip
></el-table-column>
<el-table-column width="200" label="操作" fixed="right">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="handleModifyClick(scope.row)"
>详情
</el-button>
</template>
</el-table-column>
</el-table>
<el-dialog
title="产品信息详情"
:visible.sync="editDialogVisible"
width="70%"
:close-on-click-modal="false"
:close-on-press-escape="false"
append-to-body
v-if="editDialogVisible"
>
<el-table :data="sysList" style="width: 100%" border>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="第三方系统名称"
prop="sysName"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="第三方产品名称"
prop="thirdName"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="第三方产品ID"
prop="thirdId"
show-overflow-tooltip
></el-table-column>
</el-table>
<el-table
v-loading="loading"
:data="detailList"
style="width: 100%; margin-top: 20px"
border
@current-change="handleDetail"
>
<el-table-column
label="产品标识"
prop="nameCode"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="产品通用名"
prop="cpmctymc"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="包装级别"
prop="packLevel"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="包装层级"
prop="bzcj"
show-overflow-tooltip
></el-table-column>
</el-table>
<el-form
:model="editQuery"
:rules="rules"
ref="editQuery"
label-width="100px"
style="margin-top: 20px"
>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>产品名称:&nbsp;</span>
</div>
<el-input
style="width: 65%"
size="small"
splaceholder="请输入内容"
:disabled="true"
v-model="editQuery.cpmctymc"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>产品标识:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.nameCode"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>规格型号:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.ggxh"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>器械类别:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.qxlb"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>产品类别:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.cplb"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>分类编码:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.flbm"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>商品条码:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.sptm"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>医保编码:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.ybbm"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>医疗器械注册人:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="ylqxzcrbarmc"
v-model="editQuery.ylqxzcrbarmc"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>注册人英文名称:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.ylqxzcrbarywmc"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>统一社会信用号:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.tyshxydm"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>注册证/备案号:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.zczbhhzbapzbh"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>上级产品编码:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="true"
size="small"
splaceholder="请输入内容"
v-model="editQuery.sjcpbm"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>包装级别:&nbsp;</span>
</div>
<el-input
style="width: 65%"
size="small"
splaceholder="请输入内容"
:disabled="true"
v-model="editQuery.packLevel"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>包装单位/包装级别:&nbsp;</span>
</div>
<el-input
style="width: 65%"
size="small"
splaceholder="请输入内容"
v-model="editQuery.bzcj"
:disabled="true"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>包含下级包装数量:&nbsp;</span>
</div>
<el-input
style="width: 65%"
size="small"
splaceholder="请输入内容"
:disabled="true"
v-model="editQuery.bhxjsl"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>包含下级产品编码:&nbsp;</span>
</div>
<el-input
style="width: 65%"
size="small"
:disabled="true"
splaceholder="请输入内容"
v-model="editQuery.bhxjcpbm"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>包含最小销售包装数量:&nbsp;</span>
</div>
<el-input
style="width: 65%"
size="small"
:disabled="true"
splaceholder="请输入内容"
v-model="editQuery.bhzxxsbzsl"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>是否包含批号:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="!checked"
size="small"
splaceholder="请输入内容"
v-model="editQuery.scbssfbhph"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>是否包含序列号:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="!checked"
size="small"
v-model="editQuery.scbssfbhxlh"
splaceholder="请输入内容"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>是否包含生产日期:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="!checked"
size="small"
splaceholder="请输入内容"
v-model="editQuery.scbssfbhscrq"
></el-input>
</div>
</el-col>
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>是否包含失效日期:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="!checked"
v-model="editQuery.scbssfbhsxrq"
size="small"
splaceholder="请输入内容"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>产品描述:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="!checked"
size="small"
splaceholder="请输入内容"
v-model="editQuery.cpms"
></el-input>
</div>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col">
<div class="text item">
<div class="itemTag">
<span>最小包装单元内包含使用单元数量:&nbsp;</span>
</div>
<el-input
style="width: 65%"
:disabled="!checked"
size="small"
splaceholder="请输入内容"
v-model="editQuery.zxxsbzbhsydysl"
></el-input>
</div>
</el-col>
</el-row>
</el-form>
</el-dialog>
<el-pagination
:page-size="filterQuery.limit"
@current-change="handleCurrentChange"
layout="prev, pager, next"
:total="total"
:current-page="filterQuery.page"
></el-pagination>
</el-card>
</div>
</template>
<script>
import {
updateErpProduct,
thirdSysDetail,
getSmUdiInfos
} from "../../api/basic/udiRelevance";
import {udiUpload} from "../../api/thrsys/smp"
import {finProductSet, selectSysParamByKey} from "../../api/param/systemParamConfig";
import {filterByUuid} from "../../api/basic/udiInfo";
import {
insertCompanyProductRelevance,
insertFilter
} from "../../api/warehouse/companyProductRelevance";
import store from "../../store";
export default {
name: "basicSelectSingleProducts",
props: {
selectType: {
type: Object,
required: true,
},
closeSelDialog: {
type: Function,
required: true,
},
},
data() {
return {
radioCheck: null,
filterQuery: {
customerId: null,
ylqxzcrbarmc: "",
supName: null,
cpmctymc: "",
nameCode: "",
page: 1,
limit: 10,
addType: 1,
isDisable: false,
},
postQuery: {
customerId: null,
uuids: [],
rlIds: [],
supplementRequest: null,
},
loading: false,
editQuery: null,
repEditQuery: {},
relevanceEdit: {
id: null,
thirdId: "",
isUseDy: false,
},
replTitle: "产品信息补齐:",
isImport: false,
isImportUdi: false,
isUploadSmp: false,
isImportFile: false,
uploadFileUrl: null,
checked: false,
list: [],
detailList: [],
sysList: [],
total: 0,
thirdNo: "",
uuid: "111",
thirdId: null,
relId: "",
thisData: {
nameCode: null,
cpmctymc: null,
ggxh: null
},
currentRow: null,
multipleSelection: [],
editDialogVisible: false,
selectUdiDialogVisible: false,
selectErpDialogVisible: false,
selectLocalVisible: false,
productRemarkSet: {},
supplementRequest: null,
};
},
methods: {
onReset() {
this.radioCheck = null;
this.$router.push({
path: "",
});
this.filterQuery = {
customerId: null,
ylqxzcrbarmc: "",
supName: null,
cpmctymc: "",
nameCode: "",
page: 1,
limit: 10,
addType: 1,
};
this.getList();
},
submitSearch() {
this.filterQuery.page = 1;
this.getList();
},
getList() {
this.loading = true;
this.filterQuery.customerId = store.getters.customerId;
getSmUdiInfos(this.filterQuery)
.then((response) => {
this.loading = false;
this.list = response.data.list || [];
this.total = response.data.total || 0;
})
.catch(() => {
this.loading = false;
this.list = [];
this.total = 0;
});
},
getDetailList(detailQuery) {
this.loading = true;
filterByUuid(detailQuery)
.then((response) => {
this.loading = false;
this.detailList = response.data || [];
})
.catch(() => {
this.loading = false;
this.detailList = [];
});
},
handleDetail(row) {
this.editQuery = row;
},
combine() {
this.combineQuery.productUuid = this.currentRow.uuid;
this.combineQuery.customerId = store.getters.customerId;
insertCompanyProductRelevance(this.combineQuery).then(response => {
this.loading = false;
if (response.code === 20000) {
this.$message.success("添加成功");
this.closeDialog(true);
} else {
this.$message.error(response.message);
}
});
},
cellClass(row) {
if (row.columnIndex === 0) {
return 'disabledCheck'
}
},
selectExport() {
var selectData = this.multipleSelection;
if (selectData == null || selectData.length == 0) {
this.$message.warning("请先选入产品!");
return;
}
this.closeSelDialog(selectData.id);
},
allExport() {
this.postQuery.customerId = store.getters.customerId;
this.postQuery.supplementRequest = this.repEditQuery;
insertFilter(this.postQuery).then(response => {
this.loading = false;
if (response.code == 20000) {
this.$message.success(response.data);
this.$emit("closeSelDialog", true);
this.closeSelDialog();
} else {
this.$message.error(response.message);
}
});
},
intentDetail() {
this.isImportUdi = false;
this.selectUdiDialogVisible = true;
},
intentImportErp(val) {
this.uuid = val.uuid;
this.relId = val.id;
this.isImport = true;
this.thisData = val;
this.selectErpDialogVisible = true;
},
handleSelectionChange(selection) {
this.radioCheck = selection.id;
this.curSelectDi = selection;
if (selection.length > 1) {
this.$refs.diList.clearSelection();
this.$refs.diList.toggleRowSelection(selection.pop());
}
this.multipleSelection = selection
this.currentRow = selection;
this.replTitle = "(" + this.currentRow.cpmctymc + ")" + "产品信息补齐:";
},
handleErpChange(val) {
this.currentRow = val;
},
handleCurrentChange(val) {
this.filterQuery.page = val;
this.getList();
},
handleModifyClick(row) {
this.editDialogVisible = true;
this.editQuery = row;
this.relevanceEdit = {
id: row.id,
thirdId: row.thirdId,
isUseDy: row.isUseDy,
};
this.checked = row.isUseDy == 1;
let ttquery = {
uuid: row.uuid,
page: 1,
limit: 10,
};
this.getDetailList(ttquery);
this.getThirdSysDetail();
},
closeUdi(val) {
this.selectUdiDialogVisible = false;
this.selectErpDialogVisible = false;
this.selectLocalVisible = false;
if (val) {
this.getList();
}
},
getThirdSysDetail() {
let query = {
id: this.relevanceEdit.id,
};
thirdSysDetail(query)
.then((response) => {
this.loading = false;
this.sysList = response.data.list || [];
})
.catch(() => {
this.loading = false;
this.sysList = [];
});
},
checkSelectable(row) {
return !row.isSelect;
},
closeDialog() {
this.selectErpDialogVisible = false;
this.selectLocalVisible = false;
},
},
mounted() {
},
components: {},
created() {
},
};
</script>
<style scoped>
.el-table .disabledCheck .cell .el-checkbox .el-checkbox__input {
display: none !important;
}
.itemTag {
float: left;
text-align: left;
margin-top: 10px;
width: 25%;
}
.query-form-item {
display: block !important;
margin-right: 10px;
margin-bottom: 5px;
}
.text {
font-size: 13px;
font-family: "Microsoft YaHei";
}
.el-row {
display: flex;
flex-wrap: wrap;
margin-bottom: 6px;
}
.el-col {
border-radius: 4px;
flex-wrap: wrap;
}
</style>

@ -1,7 +1,6 @@
<template>
<div>
<el-form :model="formData" :rules="formRules" ref="dataForm">
<el-card style="margin-top: -30px">
<el-button-group style="display: flex">
<el-button
@ -112,9 +111,15 @@
:file-list="fileList"
:data="{type:'image2'}"
:auto-upload="false">
<el-button slot="trigger" size="small" type="primary">选取文件</el-button>
<el-button slot="trigger" size="small" type="primary">{{ choiceFile }}</el-button>
<div>只能上传 .jpg,.png 文件且不超过 2 MB</div>
</el-upload>
<!-- <el-button type="primary" size="mini" icon="search" @click="toViewCompanyCert"-->
<!-- style="text-align:right"-->
<!-- >文件预览-->
<!-- </el-button-->
<!-- >-->
</el-form-item>
</el-col>
</el-row>
@ -138,11 +143,10 @@
<script>
import draggable from "vuedraggable";
import {saveAs} from "file-saver";
import {parseTime} from "../../filtres/index";
import store from "../../store";
import {BASE_URL} from "../../config/app";
import {insertCompanyCert} from "../../api/purchase/companyCert";
import {insertCompanyCert, updateCompanyCert} from "../../api/purchase/companyCert";
import ThrInvWarehouse from "@/views/thrsys/ThrInvWarehouse";
export default {
name: "supCompanyCertAdd",
@ -155,10 +159,15 @@ export default {
type: Object,
required: true,
},
editTye: {
type: Object,//1:2
required: true,
},
addType: {
type: Object,
required: true,
},
},
data() {
return {
@ -171,7 +180,7 @@ export default {
code: null,
name: null,
manufacturerIdFk: null,
auditStatus:6
auditStatus: 6
},
formRules: {
name: [
@ -182,6 +191,8 @@ export default {
uploadUrl: "",
fileList: [],
headers: {},
choiceFile: "选取文件",
};
},
components: {
@ -189,13 +200,26 @@ export default {
},
methods: {
submitUpload() {
this.$refs["dataForm"].validate(valid => {
if (valid) {
if (this.$refs.upload.uploadFiles.length > 0) {
this.$refs.upload.submit();
if (this.$isNotBlank(this.formData.filePath)) {
if (this.$refs.upload.uploadFiles.length > 0) {
this.$refs.upload.submit();
} else {
this.onSubmit();
}
} else {
this.$message.warning(`请选择文件`);
if (this.$refs.upload.uploadFiles.length > 0) {
this.$refs.upload.submit();
} else {
this.$message.warning(`请选择文件`);
}
}
}
});
},
@ -210,15 +234,32 @@ export default {
this.formData.manufacturerIdFk = this.inputQuery.manufacturerIdFk;
this.formData.productIdFk = this.inputQuery.productId;
}
insertCompanyCert(this.formData).then(response => {
this.loading = false;
if (response.code === 20000) {
this.$message.success("添加成功");
this.closeDialog(true);
} else {
this.$message.error(response.message);
}
});
this.formData.auditStatus = "6";
if (this.editTye == 1) {
insertCompanyCert(this.formData).then(response => {
this.loading = false;
if (response.code === 20000) {
this.$message.success("添加成功");
this.closeDialog(true);
} else {
this.$message.error(response.message);
}
});
} else {
updateCompanyCert(this.formData).then(response => {
this.loading = false;
if (response.code === 20000) {
this.$message.success("添加成功");
this.closeDialog(true);
} else {
this.$message.error(response.message);
}
});
}
},
uploadHandleRemove(file, fileList) {
console.log(file, fileList);
@ -267,6 +308,11 @@ export default {
uploadHandleError() {
},
toViewCompanyCert() {
this.certFileUrl = BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name=";
window.open(this.certFileUrl + this.formData.filePath);
},
},
filters: {},
mounted() {
@ -281,6 +327,16 @@ export default {
ADMIN_ID: store.getters.adminId,
ADMIN_TOKEN: store.getters.token,
};
if (this.inputQuery.formData == null) {
this.formData = {}
} else this.formData = this.inputQuery.formData;
if (this.formData.filePath != null) {
this.choiceFile = "更换文件";
} else {
this.choiceFile = "选取文件";
}
},
};
</script>

@ -69,7 +69,7 @@
<el-button
type="text"
size="small"
v-if="scope.row.auditStatus ==6 || scope.row.auditStatus ==3"
v-if="scope.row.auditStatus ==6 || scope.row.auditStatus ==3|| scope.row.auditStatus ==4"
@click.native.stop="editCompany(scope.row)"
>审核
</el-button>
@ -77,7 +77,7 @@
<el-button
type="text"
size="small"
v-if="scope.row.auditStatus !=6 && scope.row.auditStatus !=3"
v-if="scope.row.auditStatus !=6 && scope.row.auditStatus !=3 && scope.row.auditStatus !=4"
@click.native.stop="editCompany(scope.row)"
>详情
</el-button>
@ -169,7 +169,7 @@
<el-button
type="text"
size="small"
v-if="scope.row.auditStatus ==6 || scope.row.auditStatus ==3"
v-if="scope.row.auditStatus ==6 || scope.row.auditStatus ==3|| scope.row.auditStatus ==4"
@click.native.stop="addInfoDialog(scope.row)"
>审核
</el-button>
@ -178,7 +178,7 @@
<el-button
type="text"
size="small"
v-if="scope.row.auditStatus !=6 && scope.row.auditStatus !=3"
v-if="scope.row.auditStatus !=6 && scope.row.auditStatus !=3 && scope.row.auditStatus !=4"
@click.native.stop="addInfoDialog(scope.row)"
>详情
</el-button>
@ -273,7 +273,7 @@
<el-button
type="text"
size="small"
v-if="scope.row.auditStatus ==6 || scope.row.auditStatus ==3"
v-if="scope.row.auditStatus ==6 || scope.row.auditStatus ==3|| scope.row.auditStatus ==4"
@click.native.stop="registrationDialog(scope.row)"
>审核
</el-button>
@ -282,7 +282,7 @@
<el-button
type="text"
size="small"
v-if="scope.row.auditStatus !=6 && scope.row.auditStatus !=3"
v-if="scope.row.auditStatus !=6 && scope.row.auditStatus !=3 && scope.row.auditStatus !=4"
@click.native.stop="registrationDialog(scope.row)"
>详情
</el-button>
@ -346,9 +346,10 @@ export default {
2: "配送企业资质审核",
},
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
supCompanyVisible: false,
@ -367,8 +368,8 @@ export default {
},
manufacturerTotal: 0,
companyTypeMap: {
1: "注册人/备案人",
2: "代理人"
1: "境内企业",
2: "境外企业"
},
productManageTypeMap: {
1: "Ⅰ类",
@ -435,6 +436,7 @@ export default {
1: "success",
2: "danger",
6: "warning",
4: "warning",
};
return statusMap[status];
},
@ -484,7 +486,7 @@ export default {
this.getList();
},
editCompany(row) {
if (row.auditStatus == 6 || row.auditStatus == 3) {
if (row.auditStatus == 6 || row.auditStatus == 3 || row.auditStatus == 4) {
this.formName = 2;
this.editType = 2;
} else {
@ -561,7 +563,7 @@ export default {
},
addInfoDialog(row) {
if (row.auditStatus == 6 || row.auditStatus == 3) {
if (row.auditStatus == 6 || row.auditStatus == 3 || row.auditStatus == 4) {
this.editManufacturerType = 2;
this.formManufacturerName = 2;
} else {
@ -613,7 +615,7 @@ export default {
this.getRegistrationList();
},
registrationDialog(row) {
if (row.auditStatus == 6 || row.auditStatus == 3) {
if (row.auditStatus == 6 || row.auditStatus == 3 || row.auditStatus == 4) {
this.formProductName = 2;
this.editProductType = 2;
} else {

@ -346,9 +346,10 @@ export default {
2: "配送企业资质审核",
},
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
supCompanyVisible: false,
@ -367,8 +368,8 @@ export default {
},
manufacturerTotal: 0,
companyTypeMap: {
1: "注册人/备案人",
2: "代理人"
1: "境内企业",
2: "境外企业"
},
productManageTypeMap: {
1: "Ⅰ类",

@ -0,0 +1,719 @@
<template>
<div>
<el-card>
<div>
<p class="form-title">配送企业资质设置</p>
</div>
<div style=" float: right;
text-align: right;
margin-bottom: 8px;">
<el-button type="primary" size="mini" icon="search" @click="addCert"
style="text-align:right"
>添加设置
</el-button>
</div>
<el-table v-loading="loading" :data="list" style="width: 100%">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="证书名称" prop="name"></el-table-column>
<el-table-column label="是否必传" prop="require" s>
<template slot-scope="scope">
<span>{{ enableMap[scope.row.need] }}</span>
</template>
</el-table-column>
<el-table-column label="说明" prop="remark"></el-table-column>
<el-table-column label="操作" fixed="right" width="200">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click="handleEdit(scope.row)"
>编辑
</el-button>
<el-button
type="text"
size="small"
@click="handleDel( scope.row)"
>删除
</el-button>
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="query.limit"
@current-change="handleCurrentChange"
layout="prev, pager, next"
:total="total"
>
</el-pagination>
<el-dialog
:title="formMap[formName]"
:visible.sync="addDialogVisible"
width="70%"
:close-on-click-modal="false"
:close-on-press-escape="false"
v-if="addDialogVisible"
>
<el-form :model="currentSup" :rules="formRules" ref="dataForm">
<el-row>
<el-col :span="3">
<div class="ao-text">
<span>证书名称</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="name">
<el-input v-model="currentSup.name" auto-complete="off"></el-input>
</el-form-item>
</el-col>
<el-col :span="3">
<div class="ao-text">
<span>是否必传</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="require">
<el-select v-model="currentSup.need">
<el-option label="是" :value=true></el-option>
<el-option label="否" :value=false></el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="3">
<div class="ao-text">
<span>备注</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="remark">
<el-input v-model="currentSup.remark" auto-complete="off" type="textarea"
autosize></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div style="text-align: center">
<el-button type="primary" size="small" icon="search" @click="onAddSubmit"
>提交
</el-button
>
<el-button type="primary" size="small" icon="search" @click="cancelDialog"
>取消
</el-button
>
</div>
</el-dialog>
</el-card>
<el-card>
<div>
<p class="form-title">生产企业资质设置</p>
</div>
<div style=" float: right;
text-align: right;
margin-bottom: 8px;"
>
<el-button type="primary" size="mini" icon="search" @click="addManufacturerCert"
style="text-align:right"
>添加设置
</el-button
>
</div>
<el-table v-loading="loading" :data="manufacturerList" style="width: 100%">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="证书名称" prop="name"></el-table-column>
<el-table-column label="是否必传" prop="require" s>
<template slot-scope="scope">
<span>{{ enableMap[scope.row.need] }}</span>
</template>
</el-table-column>
<el-table-column label="产地" prop="foreign">
<template slot-scope="scope">
<span>{{ foreignMap[scope.row.foreign] }}</span>
</template>
</el-table-column>
<el-table-column label="说明" prop="remark"></el-table-column>
<el-table-column label="操作" fixed="right" width="200">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click="handleManufacturerEdit( scope.row)"
>编辑
</el-button>
<el-button
type="text"
size="small"
@click="handleManufacturerDel( scope.row)"
>删除
</el-button>
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="query.limit"
@current-change="handleCurrentChange"
layout="prev, pager, next"
:total="total"
>
</el-pagination>
<el-dialog
:title="formManufacturerMap[formManufacturerName]"
:visible.sync="addManufacturerDialogVisible"
width="60%"
:close-on-click-modal="false"
:close-on-press-escape="false"
v-if="addManufacturerDialogVisible"
>
<el-form :model="currentManufacturer" :rules="formRules" ref="dataForm">
<el-row>
<el-col :span="3">
<div class="ao-text">
<span>证书名称</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="name">
<el-input v-model="currentManufacturer.name" auto-complete="off"></el-input>
</el-form-item>
</el-col>
<el-col :span="3">
<div class="ao-text">
<span>是否必传</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="require">
<el-select v-model="currentManufacturer.need" style="width: 100%">
<el-option label="是" :value=true></el-option>
<el-option label="否" :value=false></el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="3">
<div class="ao-text">
<span>产地</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="require">
<el-select v-model="currentManufacturer.foreign" style="width: 100%">
<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="3">
<div class="ao-text">
<span>备注</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="remark">
<el-input v-model="currentManufacturer.remark" auto-complete="off" type="textarea"
autosize></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div style="text-align: center">
<el-button type="primary" size="small" icon="search" @click="onAddManufacturerSubmit"
>提交
</el-button
>
<el-button type="primary" size="small" icon="search" @click="cancelDialog"
>取消
</el-button
>
</div>
</el-dialog>
</el-card>
<el-card>
<div>
<p class="form-title">产品资质设置</p>
</div>
<div style=" float: right;
text-align: right;
margin-bottom: 8px;"
>
<el-button type="primary" size="mini" icon="search" @click="addProductCert"
style="text-align:right"
>添加设置
</el-button
>
</div>
<el-table v-loading="productLoading" :data="productList" style="width: 100%">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="证书名称" prop="name"></el-table-column>
<el-table-column label="是否必传" prop="need" s>
<template slot-scope="scope">
<span>{{ enableMap[scope.row.need] }}</span>
</template>
</el-table-column>
<el-table-column label="产地" prop="imports">
<template slot-scope="scope">
<span>{{ foreignMap[scope.row.imports] }}</span>
</template>
</el-table-column>
<el-table-column label="产品类型" prop="cplx">
</el-table-column>
<el-table-column label="产品类别" prop="hchzsb">
</el-table-column>
<el-table-column label="说明" prop="remark"></el-table-column>
<el-table-column label="操作" fixed="right" width="200">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click="handleProductEdit( scope.row)"
>编辑
</el-button>
<el-button
type="text"
size="small"
@click="handleProductDel( scope.row)"
>删除
</el-button>
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="query.limit"
@current-change="handleCurrentChange"
layout="prev, pager, next"
:total="total"
>
</el-pagination>
<el-dialog
:title="formProductMap[formProductName]"
:visible.sync="addProductDialogVisible"
width="60%"
:close-on-click-modal="false"
:close-on-press-escape="false"
v-if="addProductDialogVisible"
>
<el-form :model="currentProduct" :rules="formRules" ref="dataForm">
<el-row>
<el-col :span="3">
<div class="ao-text">
<span>证书名称</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="name">
<el-input v-model="currentProduct.name" auto-complete="off"></el-input>
</el-form-item>
</el-col>
<el-col :span="3">
<div class="ao-text">
<span>是否必传</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="require">
<el-select v-model="currentProduct.need" style="width: 100%">
<el-option label="是" :value=true></el-option>
<el-option label="否" :value=false></el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="3">
<div class="ao-text">
<span>产品类型</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="require">
<el-select v-model="currentProduct.cplx" style="width: 100%">
<el-option label="全部" value="全部"></el-option>
<el-option label="器械" value="器械"></el-option>
<el-option label="试剂" value="试剂"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="3">
<div class="ao-text">
<span>产品类别</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="require">
<el-select v-model="currentProduct.hchzsb" style="width: 100%">
<el-option label="全部" value="全部"></el-option>
<el-option label="耗材" value="耗材"></el-option>
<el-option label="设备" value="设备"></el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="3">
<div class="ao-text">
<span>产地</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="require">
<el-select v-model="currentProduct.imports" style="width: 100%">
<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="3">
<div class="ao-text">
<span>备注</span>
</div>
</el-col>
<el-col :span="8">
<el-form-item prop="remark">
<el-input v-model="currentProduct.remark" auto-complete="off" type="textarea"
autosize></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div style="text-align: center">
<el-button type="primary" size="small" icon="search" @click="onAddProductSubmit"
>提交
</el-button
>
<el-button type="primary" size="small" icon="search" @click="cancelDialog"
>取消
</el-button
>
</div>
</el-dialog>
</el-card>
</div>
</template>
<script>
import {filterCertSet, delSupCertCert, modifySupCertSet, addSupCertSet} from "@/api/purchase/supCertSet";
export default {
data() {
return {
/**--------配送企业资质设置--------------*/
query: {
type: 1,
page: 1,
limit: 20
},
list: [],
total: 0,
loading: false,
enableMap: {
true: "是",
false: "否",
},
addDialogVisible: false,
currentSup: {},
formName: "add",
formMap: {
add: "新增配送企业资质设置",
update: "编辑配送企业资质设置",
},
/**--------生产企业资质设置 0--------------*/
manufacturerList: [],
manufacturerQuery: {
type: 2,
page: 1,
limit: 20
},
foreignMap: {
"1": "全部",
"2": "国外",
"3": "国内",
},
manufacturerTotal: 0,
manufacturerLoading: false,
addManufacturerDialogVisible: false,
currentManufacturer: {},
formManufacturerName: "add",
formManufacturerMap: {
add: "新增生产企业资质设置",
update: "编辑生产企业资质设置",
},
/**--------产品资质设置--------------*/
productList: [],
productQuery: {
type: 3,
page: 1,
limit: 20
},
productTotal: 0,
productLoading: false,
addProductDialogVisible: false,
currentProduct: {},
formProductName: "add",
formProductMap: {
add: "新增产品资质设置",
update: "编辑产品资质设置",
},
};
},
methods: {
/**--------配送企业资质设置--------------*/
handleCurrentChange(val) {
this.query.page = val;
this.getList();
},
getList() {
this.loading = true;
filterCertSet(this.query)
.then(response => {
this.loading = false;
this.list = response.data.list || [];
this.total = response.data.total || 0;
})
.catch(() => {
this.loading = false;
this.list = [];
this.total = 0;
});
},
handleEdit(row) {
this.formName = "update";
this.currentSup = row;
this.addDialogVisible = true;
},
handleDel(row) {
let query = {
id: row.id,
}
delSupCertCert(query)
.then((response) => {
this.getList();
})
.catch(() => {
});
},
addCert() {
this.formName = "add";
this.currentSup = {};
this.addDialogVisible = true;
},
onAddSubmit() {
this.addDialogVisible = false;
if (this.formName == "add") {
this.currentSup.type = 1;
addSupCertSet(this.currentSup)
.then((response) => {
this.getList();
})
.catch(() => {
});
} else {
modifySupCertSet(this.currentSup).then((res) => {
if (res.code == 20000) {
this.getList();
this.$message.success("保存成功!");
} else {
this.$message.error(res.message);
}
})
}
},
cancelDialog() {
this.addDialogVisible = false;
this.addManufacturerDialogVisible = false;
this.addProductDialogVisible = false;
},
/**--------生产企业资质设置--------------*/
getManufacturerList() {
this.manufacturerLoading = true;
filterCertSet(this.manufacturerQuery)
.then(response => {
this.manufacturerLoading = false;
this.manufacturerList = response.data.list || [];
this.manufacturerTotal = response.data.total || 0;
})
.catch(() => {
this.manufacturerLoading = false;
this.manufacturerList = [];
this.manufacturerTotal = 0;
});
},
handleManufacturerEdit(row) {
this.formManufacturerName = "update";
this.currentManufacturer = row;
this.addManufacturerDialogVisible = true;
},
handleManufacturerDel(row) {
let query = {
id: row.id,
}
delSupCertCert(query)
.then((response) => {
this.getManufacturerList();
})
.catch(() => {
});
},
addManufacturerCert() {
this.formManufacturerName = "add";
this.currentManufacturer = {};
this.addManufacturerDialogVisible = true;
},
onAddManufacturerSubmit() {
this.addManufacturerDialogVisible = false;
if (this.formManufacturerName == "add") {
this.currentManufacturer.type = 2;
addSupCertSet(this.currentManufacturer)
.then((response) => {
this.getManufacturerList();
})
.catch(() => {
});
} else {
modifySupCertSet(this.currentManufacturer).then((res) => {
if (res.code == 20000) {
this.getManufacturerList();
this.$message.success("保存成功!");
} else {
this.$message.error(res.message);
}
})
}
},
/**--------产品资质设置--------------*/
getProductList() {
this.productLoading = true;
filterCertSet(this.productQuery)
.then(response => {
this.productLoading = false;
this.productList = response.data.list || [];
this.productTotal = response.data.total || 0;
})
.catch(() => {
this.productLoading = false;
this.productList = [];
this.productTotal = 0;
});
},
handleProductEdit(row) {
this.formProductName = "update";
this.currentProduct = row;
this.addProductDialogVisible = true;
},
handleProductDel(row) {
let query = {
id: row.id,
}
delSupCertCert(query)
.then((response) => {
this.getProductList();
})
.catch(() => {
});
},
addProductCert() {
this.formProductName = "add";
this.currentProduct = {};
this.addProductDialogVisible = true;
},
onAddProductSubmit() {
this.addProductDialogVisible = false;
if (this.formProductName == "add") {
this.currentProduct.type = 3;
addSupCertSet(this.currentProduct)
.then((response) => {
this.getProductList();
})
.catch(() => {
});
} else {
modifySupCertSet(this.currentProduct).then((res) => {
if (res.code == 20000) {
this.getProductList();
this.$message.success("保存成功!");
} else {
this.$message.error(res.message);
}
})
}
},
},
filters: {},
mounted() {
},
created() {
//
this.getList();
this.getManufacturerList();
this.getProductList();
}
};
</script>
<style scoped
>
.form-title {
font-size: 16px;
font-family: Noto Sans SC;
font-weight: bold;
color: #303133;
}
</style>

@ -0,0 +1,146 @@
<template>
<div>
<el-card style="margin-top: -20px">
<div style="float: right;margin-bottom: 10px;margin-right: 25px">
<el-button type="primary" size="small" @click="selectSet()"></el-button>
</div>
<el-table v-loading="loading" :data="list" style="width: 100%"
@selection-change="handleCheckedChange">
<el-table-column type="selection" width="55"></el-table-column>
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="证书名称" prop="name"></el-table-column>
<el-table-column label="是否必传" prop="require" s>
<template slot-scope="scope">
<span>{{ enableMap[scope.row.need] }}</span>
</template>
</el-table-column>
<el-table-column label="说明" prop="remark"></el-table-column>
</el-table>
<el-pagination
:page-size="query.limit"
@current-change="handleCurrentChange"
layout="prev, pager, next"
:total="total"
>
</el-pagination>
</el-card>
</div>
</template>
<script>
import {filterCertSet, selectAllCert} from "@/api/purchase/supCertSet";
export default {
name: "supCertSetDialog",
props: {
closeDialog: {
type: Function,
required: true,
},
certType: {
type: Object,
required: true,
},
manufacturerId: {
type: Object,
required: true,
},
productId: {
type: Object,
required: true,
},
},
data() {
return {
query: {
manufacturerIdFk: null,
type: 1,
page: 1,
limit: 20
},
multipleSelection: [],
enableMap: {
true: "是",
false: "否",
},
list: [],
total: 0,
loading: false,
};
},
methods: {
handleCheckedChange(val) {
this.multipleSelection = val;
},
handleCurrentChange(val) {
this.query.page = val;
this.getList();
},
getList() {
this.loading = true;
this.query.type = this.certType;
filterCertSet(this.query)
.then(response => {
this.loading = false;
this.list = response.data.list || [];
this.total = response.data.total || 0;
})
.catch(() => {
this.loading = false;
this.list = [];
this.total = 0;
});
},
selectSet() {
let postQuery = {
certType: this.certType,
manufacturerIdFk: this.manufacturerId,
productIdFk: this.productId,
supCertSetEntities: this.multipleSelection
};
selectAllCert(postQuery)
.then(response => {
if (response.code === 20000) {
this.closeDialog();
} else {
this.$message.error(response.message);
}
})
.catch(() => {
this.$message.error(response.message);
});
},
},
filters: {},
mounted() {
document.body.ondrop = function (event) {
event.preventDefault();
event.stopPropagation();
};
},
created() {
this.getList();
},
}
</script>
<style scoped>
</style>

@ -0,0 +1,558 @@
<template>
<div>
<!---生产企业资质----->
<el-card class="el-card">
<el-form :inline="true" :model="filterQuery" class="query-form" size="mini" style="margin-top: 5px">
<el-row style="width: 100%">
<el-form-item class="query-form-item">
<el-input
v-model="filterQuery.companyName"
placeholder="企业名称"
></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input
v-model="filterQuery.creditCode"
placeholder="社会信用号"
></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-select v-model="filterQuery.auditStatus" placeholder="处理状态">
<el-option label="全部" value=""></el-option>
<el-option label="草稿" value="0"></el-option>
<el-option label="未审核" value="6"></el-option>
<el-option label="已审核" value="1"></el-option>
<el-option label="已拒绝" value="2"></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button-group>
<el-button
type="primary"
icon="el-icon-refresh"
@click="onReset"
></el-button>
<el-button type="primary" icon="search" @click="onSubmit"
>查询
</el-button
>
<el-button type="primary" icon="search" @click="addInfoDialog()"></el-button>
</el-button-group>
</el-form-item>
</el-row>
</el-form>
<el-table v-loading="loading" :data="list" style="width: 100%" highlight-current-row
@current-change="supManufacturerClick">
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column label="企业名称" prop="companyName" width="250"></el-table-column>
<el-table-column label="社会信用号" prop="creditCode"></el-table-column>
<el-table-column label="企业类型" prop="bussinessStatus" width="120">
<template slot-scope="scope">
<span>{{ companyTypeMap[scope.row.companyType] }}</span>
</template>
</el-table-column>
<el-table-column label="所在地区" prop="placeArea"></el-table-column>
<el-table-column label="所在地址" prop="placeAddress" :show-overflow-tooltip="true"></el-table-column>
<el-table-column label="审核状态" prop="auditStatus" width="120">
<template slot-scope="scope">
<el-tag :type="(scope.row.auditStatus) | statusFilterType">
{{ checkFlag[scope.row.auditStatus] }}
</el-tag>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" width="120">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="addInfoDialog(scope.row)"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@click.native.stop="deleteDialog(scope.row)"
>删除
</el-button
>
<el-button
type="text"
size="small"
v-if="scope.row.auditStatus === 2"
@click.native.stop="rejectInfo(scope.row)"
>说明
</el-button>
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="filterQuery.limit"
@current-change="handleCurrentChange"
layout="prev, pager, next"
:total="total"
></el-pagination>
<el-dialog
title="生产企业信息编辑"
:visible.sync="addInfoVisible"
width="80%"
:close-on-click-modal="false"
:close-on-press-escape="false"
v-if="addInfoVisible"
@close='closeDialog'
>
<suppliersEnterpriseBasicAdd
:addCloseDialog="closeDialog"
:inputQuery="inputQuery"
:editType="editType"
:fromType="fromType"
></suppliersEnterpriseBasicAdd>
</el-dialog>
</el-card>
<!---配送企业资质----->
<el-card class="el-card">
<el-form :inline="true" :model="registrationQuery" class="query-form" size="mini" style="margin-top: 5px">
<el-row style="width: 100%">
<el-form-item class="query-form-item">
<el-input
v-model="registrationQuery.recordProductName" clearable
placeholder="产品名称"
></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input
v-model="registrationQuery.recordCode" clearable
placeholder="注册备案号"
></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input
v-model="registrationQuery.recordPeopleName" clearable
placeholder="注册备案人"
></el-input>
</el-form-item>
<el-form-item>
<el-button-group>
<el-button
type="primary"
icon="el-icon-refresh"
@click="onReset2"
></el-button>
<el-button type="primary" icon="search" @click="onSubmit2"
>查询
</el-button
>
<el-button type="primary" icon="search" @click="registrationDialog()"></el-button>
</el-button-group>
</el-form-item>
</el-row>
</el-form>
<el-table v-loading="registrationLoading"
:data="registrationList"
style="width: 100%">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="注册/备案产品名称" prop="recordProductName" show-overflow-tooltip></el-table-column>
<el-table-column label="注册/备案号" prop="recordCode" show-overflow-tooltip></el-table-column>
<el-table-column label="注册/备案人名称" prop="recordPeopleName" show-overflow-tooltip></el-table-column>
<el-table-column label="生产企业" prop="manufacturerName" show-overflow-tooltip></el-table-column>
<el-table-column label="所属供应商" prop="supName" show-overflow-tooltip></el-table-column>
<el-table-column label="审核状态" prop="auditStatus" width="120">
<template slot-scope="scope">
<el-tag :type="(scope.row.auditStatus) | statusFilterType">
{{ checkFlag[scope.row.auditStatus] }}
</el-tag>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" width="120">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="registrationDialog(scope.row)"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@click.native="deleteRegistration(scope.row)"
>删除
</el-button
>
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="registrationQuery.limit"
@current-change="certHandleCurrentChange"
layout="prev, pager, next"
:total="certTotal"
>
</el-pagination>
<el-dialog
:title="formProductMap[formName]"
:visible.sync="registrationVisible"
width="80%"
:close-on-click-modal="false"
:close-on-press-escape="false"
v-if="registrationVisible"
@close='closeProductDialog'
>
<suppliersRegistrationBasic
:closeRegistrationDialog="closeProductDialog"
:inputQuery="curProductQuery"
:editType="editProductType"
:currentManufacturer="currentManufacturer"
></suppliersRegistrationBasic>
</el-dialog>
</el-card>
</div>
</template>
<script>
import {deleteCompany, getCompanyList, getCompanyBySup} from "../../api/purchase/supManufacturer"
import suppliersEnterpriseBasicAdd from "./supManufacturerEditDialog";
import {BASE_URL} from "../../config/app";
import {getSupComapnys} from "@/api/purchase/supCompany";
import {getRegistrationList, deleteRegistration} from "../../api/purchase/suppliersRegistrationBasic";
import suppliersRegistrationBasic from "./supProductEditDialog";
export default {
name: "supCertificationAdd",
data() {
return {
/**------------------生产企业资质--------------------*/
filterQuery: {
customerId: null,
companyName: "",
auditStatus: null,
creditCode: "",
placeArea: "",
page: 1,
limit: 20,
},
total: 0,
companyTypeMap: {
1: "境内企业",
2: "境外企业"
},
productManageTypeMap: {
1: "Ⅰ类",
2: "Ⅱ类",
3: "Ⅲ类",
},
checkFlag: {
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
loading: false,
list: [],
addInfoVisible: false,
fileUrl: "",
inputQuery: {
auditStatus: 6
},
editType: 1,
fromType: 1,//1:2:
formMap: {
add: "新增生产企业资质信息",
update: "编辑生产企业资质信息",
},
currentManufacturer: null,
/**------------------配送企业资质--------------------*/
registrationVisible: false,
enterpriseId: "",
registrationQuery: {
auditStatus: null,
customerId: null,
manufacturerIdFk: null,
recordProductName: "",
recordCode: "",
recordPeopleName: "",
page: 1,
limit: 20
},
registrationList: [],
certTotal: 0,
registrationLoading: false,
registrationId: "",
pmQuery: {
customerId: null,
companyName: null,
page: 1,
limit: 10,
},
curProductQuery: {
auditStatus: 6
},
editProductType: 0,
formName: "add",
formProductMap: {
add: "新增配送产品资质信息",
update: "编辑配送产品资质信息",
},
};
},
filters: {
statusFilterType(status) {
const statusMap = {
0: "warning",
1: "success",
2: "danger",
4: "warning",
6: "warning",
};
return statusMap[status];
},
statusFilterName(status) {
const statusMap = {
0: "禁用",
1: "正常",
2: "未验证",
};
return statusMap[status];
},
},
methods: {
/**-------------------------生产企业资质---------------------*/
onReset() {
this.$router.push({
path: "",
});
this.filterQuery = {
customerId: null,
companyName: "",
creditCode: "",
placeArea: "",
auditStatus: "",
page: 1,
limit: 20,
};
this.getList();
this.registrationList = [];
},
onSubmit() {
this.getList();
this.registrationList = [];
},
toViewRegistrationCert(row, num) {
let path = num === 1 ? row.filePath : row.instructions;
window.open(this.fileUrl + path);
},
getList() {
this.loading = true;
getCompanyBySup(this.filterQuery)
.then((response) => {
this.loading = false;
this.list = response.data.list || [];
this.total = response.data.total || 0;
})
.catch(() => {
this.loading = false;
this.list = [];
this.total = 0;
});
},
addInfoDialog(row) {
if (this.$isNotBlank(row)) {
this.enterpriseId = row.id;
this.editType = 1;
this.inputQuery = row;
} else {
this.enterpriseId = null;
this.editType = 0;
this.inputQuery = {
auditStatus: 0
};
}
this.addInfoVisible = true;
},
closeDialog(type) {
this.addInfoVisible = false;
this.registrationVisible = false;
this.enterpriseId = null;
this.registrationId = null;
this.getList();
this.registrationList = [];
},
handleSizeChange(val) {
this.filterQuery.limit = val;
this.getList();
},
handleCurrentChange(val) {
this.filterQuery.page = val;
this.getList();
},
handleCheckedChange(val) {
console.log(val);
console.log(this.check);
},
rejectInfo(row) {
this.$confirm(row.auditComment, "驳回说明", {
confirmButtonText: "确定",
type: "warning",
showCancelButton: false,
})
.then(() => {
});
},
deleteDialog(row) {
this.$confirm("删除后将清空该生产企业以及所有关联信息?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
let tQuery = {
id: row.id,
};
deleteCompany(tQuery).then(() => {
this.getList();
});
})
.catch(() => {
});
},
supManufacturerClick(row) {
this.registrationQuery.customerId = row.customerId;
this.registrationQuery.manufacturerIdFk = row.manufacturerId;
this.getRegistrationList();
this.currentManufacturer = row;
},
/**---------------------------配送产品资质----------------------*/
onReset2() {
this.registrationQuery = {
customerId: null,
manufacturerIdFk: null,
recordProductName: "",
recordCode: "",
recordPeopleName: "",
auditStatus: null,
page: 1,
limit: 20
};
this.getRegistrationList();
},
onSubmit2() {
this.getRegistrationList();
},
registrationDialog(row) {
if (this.$isNotBlank(row)) {
this.registrationId = row.id;
this.curProductQuery = row;
this.formName = "update";
this.editProductType = 1;
} else {
this.editProductType = 0;
this.formName = "add";
this.curProductQuery = {
auditStatus: 0
};
}
this.registrationVisible = true;
},
deleteRegistration(row) {
this.$confirm("是否删除?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}).then(() => {
this.certLoading = true;
let tQuery = {
id: row.id,
filePath: row.filePath,
filePath2: row.instructions,
};
deleteRegistration(tQuery)
.then((response) => {
this.certLoading = false;
if (response.code === 20000) {
this.getRegistrationList();
this.$message({
type: "success",
message: "删除成功!",
});
} else {
this.$message.error(response.message);
}
})
.catch(() => {
this.certLoading = false;
});
}).catch(() => {
});
},
closeProductDialog() {
this.registrationVisible = false;
this.enterpriseId = null;
this.registrationId = null;
this.getList();
this.registrationList = [];
},
getRegistrationList() {
this.registrationLoading = true;
getRegistrationList(this.registrationQuery)
.then((response) => {
this.registrationLoading = false;
this.registrationList = response.data.list || [];
})
.catch(() => {
this.registrationLoading = false;
this.registrationList = [];
});
},
supChange(val) {
this.pmQuery.customerId = val;
this.findPMMethod();
},
certHandleCurrentChange(val) {
this.registrationQuery.page = val;
this.registrationList();
}
},
components: {
suppliersEnterpriseBasicAdd, suppliersRegistrationBasic
},
mounted() {
},
created() {
this.fileUrl = BASE_URL + "/udiwms/image/register/file/getImage?type=image4&name=";
this.getList();
this.getRegistrationList();
},
}
</script>
<style scoped>
</style>

@ -152,9 +152,10 @@ export default {
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},

@ -349,9 +349,10 @@ export default {
companyEditDisabled: true,
companyEditButtonStr: "编辑",
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
certAuditVisible: false,

@ -141,9 +141,10 @@ export default {
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},

@ -8,7 +8,17 @@
>
<el-card class="el-card" style="margin-top: -15px">
<div style="display: flex; ">
<div style="float: right; ">
<el-button
type="primary"
size="mini"
icon="search"
@click="selectBasicCorp()"
>选入往来单位
</el-button
>
<el-button
type="primary"
size="mini"
@ -26,7 +36,7 @@
</el-button
>
</div>
<el-row :gutter="20" class="el-row" type="flex" style="margin-top: 20px">
<el-row :gutter="20" class="el-row" type="flex" style="margin-top: 35px">
<el-col :span="10" class="el-col">
<el-form-item label="企业名称:" label-width="150px" prop="companyName">
<el-input
@ -177,7 +187,6 @@
</el-pagination>
</el-card>
<el-dialog
title="添加资质证书"
:visible.sync="addCertVisible"
@ -192,16 +201,33 @@
:closeDialog="closeLocalDialog"
:inputQuery="inputQuery"
:addType="addType"
:editTye="editTye"
></companyAddCert>
</el-dialog>
<el-dialog
title="选入往来单位"
:visible.sync="selectCorpVisible"
:close-on-click-modal="false"
:close-on-press-escape="false"
width="70%"
v-if="selectCorpVisible"
append-to-body
@close='closeLocalDialog'
>
<corpMaintainSelect
:closeDialog="closeSelectCorpDialog"
></corpMaintainSelect>
</el-dialog>
</el-form>
</div>
</template>
<script>
import {modifyCompany, addCompany} from "../../api/purchase/supCompany";
import {modifyCompany, addCompany, bindCorp} from "../../api/purchase/supCompany";
import store from "../../store/index";
import {
provinceAndCityData,
@ -212,10 +238,13 @@ import {
TextToCode,
} from "element-china-area-data";
import {filterCompanyCert, deleteCompanyCert} from "../../api/purchase/companyCert";
import corpMaintainSelect from "../../views/basic/CorpMaintainSelect"
import companyAddCert from "./supCertAddDialog";
import draggable from "vuedraggable";
import {BASE_URL} from "@/config/app";
import {getUUID} from "@/utils/strUtil";
import {bindProduct} from "@/api/purchase/suppliersRegistrationBasic";
export default {
@ -351,10 +380,16 @@ export default {
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
editTye: 1,
selectCorpVisible: false,
};
},
}
,
created() {
if (this.editType == 0) {
this.inputQuery.customerId = getUUID("");
@ -364,10 +399,12 @@ export default {
ADMIN_ID: store.getters.adminId,
ADMIN_TOKEN: store.getters.token,
};
},
}
,
components: {
draggable, companyAddCert
},
draggable, companyAddCert, corpMaintainSelect
}
,
methods: {
onModifySubmit(val) {
@ -424,46 +461,80 @@ export default {
}
});
}
},
}
,
onAuditSubmit() {
},
}
,
selectBasicCorp() {
this.selectCorpVisible = true;
}
,
cancelDialog() {
this.closeDialog();
},
}
,
closeLocalDialog() {
this.addCertVisible = false;
this.getCompanyCertList();
}
,
closeSelectCorpDialog(val) {
if (val != null) {
let query = {
customerId: val.erpId
};
bindCorp(query).then(response => {
this.loading = false;
if (response.code === 20000) {
this.inputQuery = response.data;
this.selectCorpVisible = false;
} else {
this.$message.error(response.message);
}
});
}
},
handleChange(value) {
this.inputQuery.area =
CodeToText[value[0]] + CodeToText[value[1]] + CodeToText[value[2]];
this.inputQuery.areaCode = value.toString();
},
}
,
addCert(index, row) {
this.inputQuery.id = '';
if (this.$isNotBlank(row) && this.$isNotBlank(row.id)) {
this.inputQuery.id = row.id;
this.inputQuery.formData = row;
} else {
this.inputQuery.formData = {};
}
this.addCertVisible = true;
},
}
,
toViewCompanyCert(row) {
this.certFileUrl = BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name=";
window.open(this.certFileUrl + row.filePath);
},
}
,
certHandleCurrentChange(val) {
this.certQuery.page = val;
this.getCompanyCertList();
},
}
,
getCompanyCertList() {
this.certLoading = true;
@ -477,7 +548,8 @@ export default {
this.certLoading = false;
this.certList = [];
});
},
}
,
deleteCompanyCert(row) {
this.$confirm("是否删除?", "提示", {
@ -508,9 +580,11 @@ export default {
});
}).catch(() => {
});
},
}
,
},
}
,
filters: {
statusFilterType(status) {
const statusMap = {
@ -520,9 +594,12 @@ export default {
6: "warning",
};
return statusMap[status];
},
},
};
}
,
}
,
}
;
</script>
<style>
.itemTag {

@ -133,9 +133,10 @@ export default {
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},

@ -151,8 +151,8 @@ export default {
value: "",
total: 0,
companyTypeMap: {
1: "注册人/备案人",
2: "代理人"
1: "境内企业",
2: "境外企业"
},
productManageTypeMap: {
1: "Ⅰ类",
@ -163,6 +163,7 @@ export default {
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
loading: false,

@ -135,8 +135,8 @@ export default {
value: "",
total: 0,
companyTypeMap: {
1: "注册人/备案人",
2: "代理人"
1: "境内企业",
2: "境外企业"
},
productManageTypeMap: {
1: "Ⅰ类",
@ -144,9 +144,10 @@ export default {
3: "Ⅲ类",
},
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
loading: false,

@ -87,8 +87,8 @@
placeholder="企业类型" disabled
style="width: 100%;"
>
<el-option label="注册人/备案人" value="1"></el-option>
<el-option label="代理人" value="2"></el-option>
<el-option label="境内企业" value="1"></el-option>
<el-option label="境外企业" value="2"></el-option>
</el-select>
</el-form-item>
</el-col>
@ -397,9 +397,10 @@ export default {
addType: "2", //1:2.3.
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
certAuditVisible: false,

@ -9,11 +9,12 @@
>
<el-card class="el-card">
<div style="display: flex;">
<div style="float:right ">
<el-button
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 0"
@click="onModifySubmit(0)"
>草稿保存
</el-button
@ -22,13 +23,23 @@
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 0|| inputQuery.auditStatus == 6"
@click="onModifySubmit(6)"
>提交审核
</el-button
>
<el-button
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 4|| inputQuery.auditStatus == 1|| inputQuery.auditStatus == 2"
@click="onModifySubmit(4)"
>提交变更
</el-button
>
</div>
<el-row :gutter="20" class="el-row" type="flex" style="margin-top: 20px">
<el-col :span="10" class="el-col">
<el-row :gutter="20" class="el-row" type="flex" style="margin-top: 40px">
<el-col :span="10" class="el-col" v-if="fromType==2">
<el-form-item label="所属供应商:" label-width="150px" prop="customerId">
<el-select
v-model="inputQuery.customerId"
@ -52,7 +63,8 @@
<span style="float: left">{{ item.companyName }}</span>
</el-option>
</el-select>
</el-form-item>
</el-form-item
>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
@ -87,8 +99,8 @@
placeholder="企业类型"
style="width: 100%;"
>
<el-option label="注册人/备案人" value="1"></el-option>
<el-option label="代理人" value="2"></el-option>
<el-option label="境内企业" value="1"></el-option>
<el-option label="境外企业" value="2"></el-option>
</el-select>
</el-form-item>
</el-col>
@ -176,20 +188,25 @@
</el-card>
<el-card class="el-card">
<div style="display: flex">
<div style="float:right ">
<el-button type="primary" size="mini" icon="search" @click="selectCert"
>选入资质证书
</el-button
>
<el-button
type="primary"
size="small"
size="mini"
icon="search"
style="margin: 0 100px 20px auto; width: 100px"
@click="addCert()"
>添加资质证书
</el-button
>
</div>
<el-table v-loading="certLoading"
:data="certList"
style="width: 100%">
style="width: 100%;margin-top: 30px">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="证书名称" prop="name"></el-table-column>
<el-table-column label="证书编号" prop="name"></el-table-column>
@ -205,6 +222,15 @@
<el-table-column label="备注" prop="remark"></el-table-column>
<el-table-column label="操作" fixed="right" width="250">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native="addCert(scope.row)"
v-if="scope.row.auditStatus == 0 || scope.row.auditStatus == 2|| scope.row.auditStatus == 6"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@ -215,10 +241,29 @@
<el-button
type="text"
size="small"
v-if="scope.row.auditStatus == 0 || scope.row.auditStatus == 2|| scope.row.auditStatus == 6"
@click.native="deleteCompanyCert(scope.row)"
>删除
</el-button
>
<el-button
type="text"
size="small"
v-if=" scope.row.auditStatus == 1 && scope.row.status==0"
@click.native="disableCert(scope.row,1)"
>禁用
</el-button
>
<el-button
type="text"
size="small"
v-if=" scope.row.auditStatus == 1 && scope.row.status==1"
@click.native="disableCert(scope.row,0)"
>启用
</el-button
>
</template>
</el-table-column>
</el-table>
@ -245,9 +290,25 @@
:closeDialog="closeLocalDialog"
:inputQuery="inputQuery"
:addType="addType"
:editTye="editTye"
></companyAddCert>
</el-dialog>
<el-dialog
title="选入资质证书"
:visible.sync="selectCertVisible"
:close-on-click-modal="false"
:close-on-press-escape="false"
width="70%"
v-if="selectCertVisible"
append-to-body
@close='closeLocalDialog'
>
<supCertSetSelectDialog
:certType="certType"
:manufacturerId="manufacturerId"
:closeDialog="closeLocalDialog"
></supCertSetSelectDialog>
</el-dialog>
</el-form>
</div>
</template>
@ -263,12 +324,13 @@ import {
TextToCode,
} from "element-china-area-data";
import {BASE_URL} from "../../config/app";
import {filterCompanyCert, deleteCompanyCert} from "../../api/purchase/companyCert";
import {filterCompanyCert, deleteCompanyCert, updateCompanyCert} from "../../api/purchase/companyCert";
import companyAddCert from "./supCertAddDialog";
import draggable from "vuedraggable";
import {getBasicUnitMaintains} from "@/api/basic/basicUnitMaintain";
import {getSupComapnys} from "@/api/purchase/supCompany";
import {getUUID} from "@/utils/strUtil";
import supCertSetSelectDialog from "@/views/purchase/supCertSetSelectDialog";
export default {
name: "supManufacturerEdit",
@ -281,10 +343,13 @@ export default {
type: Object,
required: true,
},
enterpriseId: "",
editType: {
type: Object,
required: true,
},
fromType: {
type: Object,
required: true,
}
},
data() {
@ -377,7 +442,8 @@ export default {
customerId: null,
manufacturerIdFk: null,
page: 1,
limit: 20
limit: 20,
type: 2,
},
certList: [],
certTotal: 0,
@ -392,18 +458,31 @@ export default {
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
editTye: 1,
formName: 1,
formMap: {
1: "新增生产企业资质证书",
2: "编辑生产企业资质证书",
},
manufacturerId: null,
selectCertVisible: false,
certType: 2,
};
},
created() {
if (this.editType == 0) {
this.enterpriseId = getUUID("");
this.inputQuery.manufacturerId = this.enterpriseId;
} else
this.inputQuery.manufacturerId = getUUID("")
} else {
this.certQuery.customerId = this.inputQuery.customerId;
this.certQuery.manufacturerIdFk = this.inputQuery.manufacturerId;
this.selectedOptions = this.inputQuery.placeAreaCode.split(",");
this.selectedOptions2 = this.inputQuery.productionAreaCode.split(",");
}
this.certQuery.manufacturerIdFk = this.inputQuery.manufacturerId;
this.manufacturerId = this.inputQuery.manufacturerId
// this.getData();
this.getCompanyCertList();
this.findMethod();
@ -413,13 +492,14 @@ export default {
},
components: {
draggable,
companyAddCert,
companyAddCert, supCertSetSelectDialog
},
methods: {
onModifySubmit(type) {
this.inputQuery.auditStatus = type;
this.$refs["inputQuery"].validate(valid => {
if (valid) {
this.inputQuery.auditStatus = type;
this.loading = true;
let urlName = this.editType == 0 ? 'add' : 'update';
addOrModifyCompany(this.inputQuery, urlName).then(response => {
@ -453,14 +533,22 @@ export default {
this.certList = [];
});
},
addCert(index, row) {
this.idQuery.id = '';
if (this.$isNotBlank(row) && this.$isNotBlank(row.id)) {
this.idQuery.id = row.id;
this.idQuery.formData = row;
addCert(row) {
if (this.$isNotBlank(row)) {
this.formName = 2
this.inputQuery.formData = row;
this.editTye = 2;
} else {
this.formName = 1;
this.editTye = 1;
}
this.addCertVisible = true;
},
selectCert() {
this.selectCertVisible = true;
},
toViewCompanyCert(row) {
window.open(this.certFileUrl + row.filePath);
},
@ -495,8 +583,25 @@ export default {
});
},
disableCert(row, status) {
row.status = status;
updateCompanyCert(row).then(response => {
this.loading = false;
if (response.code === 20000) {
this.$message.success("更新成功!");
this.getCompanyCertList();
} else {
this.$message.error(response.message);
}
});
},
closeLocalDialog() {
this.addCertVisible = false;
this.selectCertVisible = false;
this.getCompanyCertList();
},
@ -579,6 +684,7 @@ export default {
uploadHandleError() {
},
},
filters: {
statusFilterType(status) {

@ -137,8 +137,8 @@ export default {
value: "",
total: 0,
companyTypeMap: {
1: "注册人/备案人",
2: "代理人"
1: "境内企业",
2: "境外企业"
},
productManageTypeMap: {
1: "Ⅰ类",
@ -146,9 +146,10 @@ export default {
3: "Ⅲ类",
},
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
loading: false,

@ -1,152 +1,152 @@
<template>
<div>
<div>
<el-card class="el-card">
<el-form :inline="true" :model="registrationQuery" class="query-form" size="mini">
<el-row style="width: 100%">
<el-form-item class="query-form-item">
<el-input
v-model="registrationQuery.recordProductName" clearable
placeholder="产品名称"
></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input
v-model="registrationQuery.recordCode" clearable
placeholder="注册备案号"
></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input
v-model="registrationQuery.recordPeopleName" clearable
placeholder="注册备案人"
></el-input>
</el-form-item>
<el-card class="el-card">
<el-form :inline="true" :model="registrationQuery" class="query-form" size="mini">
<el-row style="width: 100%">
<el-form-item class="query-form-item">
<el-input
v-model="registrationQuery.recordProductName" clearable
placeholder="产品名称"
></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input
v-model="registrationQuery.recordCode" clearable
placeholder="注册备案号"
></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-input
v-model="registrationQuery.recordPeopleName" clearable
placeholder="注册备案人"
></el-input>
</el-form-item>
<el-form-item class="query-form-item">
<el-select
v-model="registrationQuery.customerId"
filterable
remote
clearable
reserve-keyword
placeholder="请输入供应商"
:remote-method="findMethod"
:loading="loading"
style="width: 100%;"
@change="supChange"
>
<el-option
v-for="item in fromOptions"
:key="item.customerId"
:label="item.companyName"
:value="item.customerId"
>
<span style="float: left">{{ item.companyName }}</span>
</el-option>
</el-select>
</el-form-item>
<el-form-item class="query-form-item">
<el-select
v-model="registrationQuery.customerId"
filterable
remote
clearable
reserve-keyword
placeholder="请输入供应商"
:remote-method="findMethod"
:loading="loading"
style="width: 100%;"
@change="supChange"
>
<el-option
v-for="item in fromOptions"
:key="item.customerId"
:label="item.companyName"
:value="item.customerId"
>
<span style="float: left">{{ item.companyName }}</span>
</el-option>
</el-select>
</el-form-item>
<el-form-item class="query-form-item">
<el-select
v-model="registrationQuery.manufacturerIdFk"
filterable
remote
clearable
reserve-keyword
placeholder="请输入生产企业"
:remote-method="findPMMethod"
:loading="loading"
style="width: 100%;"
>
<el-option
v-for="item in fromPMOptions"
:key="item.manufacturerId"
:label="item.companyName"
:value="item.manufacturerId"
>
<span style="float: left">{{ item.companyName }}</span>
</el-option>
</el-select>
</el-form-item>
<el-form-item class="query-form-item">
<el-select
v-model="registrationQuery.manufacturerIdFk"
filterable
remote
clearable
reserve-keyword
placeholder="请输入生产企业"
:remote-method="findPMMethod"
:loading="loading"
style="width: 100%;"
>
<el-option
v-for="item in fromPMOptions"
:key="item.manufacturerId"
:label="item.companyName"
:value="item.manufacturerId"
>
<span style="float: left">{{ item.companyName }}</span>
</el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button-group>
<el-button
type="primary"
icon="el-icon-refresh"
@click="onReset2"
></el-button>
<el-button type="primary" icon="search" @click="onSubmit2"
>查询
</el-button
>
<el-button type="primary" icon="search" @click="registrationDialog()"></el-button>
</el-button-group>
</el-form-item>
<el-form-item>
<el-button-group>
<el-button
type="primary"
icon="el-icon-refresh"
@click="onReset2"
></el-button>
<el-button type="primary" icon="search" @click="onSubmit2"
>查询
</el-button
>
<el-button type="primary" icon="search" @click="registrationDialog()"></el-button>
</el-button-group>
</el-form-item>
</el-row>
</el-form>
<el-table v-loading="registrationLoading"
:data="registrationList"
style="width: 100%">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="注册/备案产品名称" prop="recordProductName" show-overflow-tooltip></el-table-column>
<el-table-column label="注册/备案号" prop="recordCode" show-overflow-tooltip></el-table-column>
<el-table-column label="注册/备案人名称" prop="recordPeopleName" show-overflow-tooltip></el-table-column>
<el-table-column label="生产企业" prop="manufacturerName" show-overflow-tooltip></el-table-column>
<el-table-column label="所属供应商" prop="supName" show-overflow-tooltip></el-table-column>
<el-table-column label="审核状态" prop="auditStatus" width="120">
<template slot-scope="scope">
<el-tag :type="(scope.row.auditStatus) | statusFilterType">
{{ checkFlag[scope.row.auditStatus] }}
</el-tag>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" width="120">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="registrationDialog(scope.row)"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@click.native="deleteRegistration(scope.row)"
>删除
</el-button
</el-row>
</el-form>
<el-table v-loading="registrationLoading"
:data="registrationList"
style="width: 100%">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="注册/备案产品名称" prop="recordProductName" show-overflow-tooltip></el-table-column>
<el-table-column label="注册/备案号" prop="recordCode" show-overflow-tooltip></el-table-column>
<el-table-column label="注册/备案人名称" prop="recordPeopleName" show-overflow-tooltip></el-table-column>
<el-table-column label="生产企业" prop="manufacturerName" show-overflow-tooltip></el-table-column>
<el-table-column label="所属供应商" prop="supName" show-overflow-tooltip></el-table-column>
<el-table-column label="审核状态" prop="auditStatus" width="120">
<template slot-scope="scope">
<el-tag :type="(scope.row.auditStatus) | statusFilterType">
{{ checkFlag[scope.row.auditStatus] }}
</el-tag>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" width="120">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="registrationDialog(scope.row)"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@click.native="deleteRegistration(scope.row)"
>删除
</el-button
>
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="registrationQuery.limit"
@current-change="certHandleCurrentChange"
layout="prev, pager, next"
:total="certTotal"
>
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="registrationQuery.limit"
@current-change="certHandleCurrentChange"
layout="prev, pager, next"
:total="certTotal"
>
</el-pagination>
</el-card>
</el-pagination>
</el-card>
<el-dialog
:title="formMap[formName]"
:visible.sync="registrationVisible"
width="80%"
:close-on-click-modal="false"
:close-on-press-escape="false"
v-if="registrationVisible"
@close='closeDialog'
>
<suppliersRegistrationBasic
:closeRegistrationDialog="closeDialog"
:inputQuery="inputQuery"
:editType="editType"
></suppliersRegistrationBasic>
</el-dialog>
</div>
<el-dialog
:title="formMap[formName]"
:visible.sync="registrationVisible"
width="80%"
:close-on-click-modal="false"
:close-on-press-escape="false"
v-if="registrationVisible"
@close='closeDialog'
>
<suppliersRegistrationBasic
:closeRegistrationDialog="closeDialog"
:inputQuery="inputQuery"
:editType="editType"
></suppliersRegistrationBasic>
</el-dialog>
</div>
</template>
<script>
@ -156,208 +156,209 @@ import {getSupComapnys} from "@/api/purchase/supCompany";
import {getCompanyList} from "@/api/purchase/supManufacturer";
export default {
data() {
return {
loading: false,
fromOptions: [],
fromPMOptions: [],
value: "",
total: 0,
companyTypeMap: {
1: "注册人/备案人",
2: "代理人"
},
productManageTypeMap: {
1: "Ⅰ类",
2: "Ⅱ类",
3: "Ⅲ类",
},
checkFlag: {
0: "未提交",
1: "已通过",
2: "已拒绝",
6: "未审核",
},
list: [],
registrationVisible: false,
enterpriseId: "",
registrationQuery: {
auditStatus: "20",
customerId: null,
manufacturerIdFk: null,
recordProductName: "",
recordCode: "",
recordPeopleName: "",
page: 1,
limit: 20
},
registrationList: [],
certTotal: 0,
registrationLoading: false,
registrationId: "",
data() {
return {
loading: false,
fromOptions: [],
fromPMOptions: [],
value: "",
total: 0,
companyTypeMap: {
1: "境内企业",
2: "境外企业"
},
productManageTypeMap: {
1: "Ⅰ类",
2: "Ⅱ类",
3: "Ⅲ类",
},
checkFlag: {
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
list: [],
registrationVisible: false,
enterpriseId: "",
registrationQuery: {
auditStatus: "20",
customerId: null,
manufacturerIdFk: null,
recordProductName: "",
recordCode: "",
recordPeopleName: "",
page: 1,
limit: 20
},
registrationList: [],
certTotal: 0,
registrationLoading: false,
registrationId: "",
pmQuery: {
customerId: null,
companyName: null,
page: 1,
limit: 10,
},
inputQuery: {},
editType: 0,
formName: "add",
formMap: {
add: "新增配送产品资质信息",
update: "编辑配送产品资质信息",
},
};
},
filters: {
statusFilterType(status) {
const statusMap = {
0: "warning",
1: "success",
2: "danger",
6: "success",
};
return statusMap[status];
},
statusFilterName(status) {
const statusMap = {
0: "禁用",
1: "正常",
2: "未验证",
};
return statusMap[status];
},
},
methods: {
onReset2() {
this.registrationQuery = {
customerId: null,
manufacturerIdFk: null,
recordProductName: "",
recordCode: "",
recordPeopleName: "",
auditStatus: "20",
page: 1,
limit: 20
};
this.getRegistrationList();
},
onSubmit2() {
this.getRegistrationList();
},
registrationDialog(row) {
if (this.$isNotBlank(row)) {
this.registrationId = row.id;
this.inputQuery = row;
this.formName = "edit";
this.editType = 1;
} else {
this.editType = 0;
this.formName = "add";
this.inputQuery = {};
}
this.registrationVisible = true;
},
deleteRegistration(row) {
this.$confirm("是否删除?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}).then(() => {
this.certLoading = true;
let tQuery = {
id: row.id,
filePath: row.filePath,
filePath2: row.instructions,
pmQuery: {
customerId: null,
companyName: null,
page: 1,
limit: 10,
},
inputQuery: {},
editType: 0,
formName: "add",
formMap: {
add: "新增配送产品资质信息",
update: "编辑配送产品资质信息",
},
};
deleteRegistration(tQuery)
.then((response) => {
this.certLoading = false;
if (response.code === 20000) {
this.getRegistrationList();
this.$message({
type: "success",
message: "删除成功!",
});
} else {
this.$message.error(response.message);
}
})
.catch(() => {
this.certLoading = false;
});
}).catch(() => {
});
},
closeDialog() {
this.registrationVisible = false;
this.enterpriseId = null;
this.registrationId = null;
this.getList();
this.registrationList = [];
filters: {
statusFilterType(status) {
const statusMap = {
0: "warning",
1: "success",
2: "danger",
6: "success",
};
return statusMap[status];
},
statusFilterName(status) {
const statusMap = {
0: "禁用",
1: "正常",
2: "未验证",
};
return statusMap[status];
},
},
getRegistrationList() {
this.registrationLoading = true;
getRegistrationList(this.registrationQuery)
.then((response) => {
this.registrationLoading = false;
this.registrationList = response.data.list || [];
})
.catch(() => {
this.registrationLoading = false;
methods: {
onReset2() {
this.registrationQuery = {
customerId: null,
manufacturerIdFk: null,
recordProductName: "",
recordCode: "",
recordPeopleName: "",
auditStatus: "20",
page: 1,
limit: 20
};
this.getRegistrationList();
},
onSubmit2() {
this.getRegistrationList();
},
registrationDialog(row) {
if (this.$isNotBlank(row)) {
this.registrationId = row.id;
this.inputQuery = row;
this.formName = "edit";
this.editType = 1;
} else {
this.editType = 0;
this.formName = "add";
this.inputQuery = {};
}
this.registrationVisible = true;
},
deleteRegistration(row) {
this.$confirm("是否删除?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}).then(() => {
this.certLoading = true;
let tQuery = {
id: row.id,
filePath: row.filePath,
filePath2: row.instructions,
};
deleteRegistration(tQuery)
.then((response) => {
this.certLoading = false;
if (response.code === 20000) {
this.getRegistrationList();
this.$message({
type: "success",
message: "删除成功!",
});
} else {
this.$message.error(response.message);
}
})
.catch(() => {
this.certLoading = false;
});
}).catch(() => {
});
},
closeDialog() {
this.registrationVisible = false;
this.enterpriseId = null;
this.registrationId = null;
this.getList();
this.registrationList = [];
});
},
getRegistrationList() {
this.registrationLoading = true;
getRegistrationList(this.registrationQuery)
.then((response) => {
this.registrationLoading = false;
this.registrationList = response.data.list || [];
})
.catch(() => {
this.registrationLoading = false;
this.registrationList = [];
});
},
findMethod(query) {
this.fromOptions = [];
let cQuery = {
companyName: query,
};
getSupComapnys(cQuery)
.then((response) => {
this.loading = false;
this.fromOptions = response.data.list || [];
})
.catch(() => {
this.loading = false;
});
},
supChange(val) {
this.pmQuery.customerId = val;
this.findPMMethod();
},
findPMMethod(key) {
this.fromPMOptions = [];
this.pmQuery.companyName = key;
getCompanyList(this.pmQuery)
.then((response) => {
this.loading = false;
this.fromPMOptions = response.data.list || [];
this.total = response.data.total || 0;
})
.catch(() => {
this.loading = false;
this.fromPMOptions = [];
this.total = 0;
});
}
,
certHandleCurrentChange(val) {
this.registrationQuery.page = val;
this.registrationList();
}
},
findMethod(query) {
this.fromOptions = [];
let cQuery = {
companyName: query,
};
getSupComapnys(cQuery)
.then((response) => {
this.loading = false;
this.fromOptions = response.data.list || [];
})
.catch(() => {
this.loading = false;
});
components: {
suppliersRegistrationBasic,
},
supChange(val) {
this.pmQuery.customerId = val;
this.findPMMethod();
mounted() {
},
created() {
this.findMethod();
this.getRegistrationList();
},
findPMMethod(key) {
this.fromPMOptions = [];
this.pmQuery.companyName = key;
getCompanyList(this.pmQuery)
.then((response) => {
this.loading = false;
this.fromPMOptions = response.data.list || [];
this.total = response.data.total || 0;
})
.catch(() => {
this.loading = false;
this.fromPMOptions = [];
this.total = 0;
});
}
,
certHandleCurrentChange(val) {
this.registrationQuery.page = val;
this.registrationList();
}
},
components: {
suppliersRegistrationBasic,
},
mounted() {
},
created() {
this.findMethod();
this.getRegistrationList();
},
};
</script>

@ -157,10 +157,11 @@ export default {
value: "",
total: 0,
checkFlag: {
0: "未提交",
1: "已通过",
2: "已拒绝",
6: "未审核",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
list: [],
registrationVisible: false,

@ -417,10 +417,11 @@ export default {
certFileUrl: "",
addType: "3", //1:2.3.
checkFlag: {
0: "未提交",
1: "已通过",
2: "已拒绝",
6: "未审核",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
certAuditVisible: false,

@ -5,14 +5,25 @@
:rules="rules"
ref="inputQuery"
label-width="100px"
style="margin-top: -20px"
style="margin-top: -30px"
>
<el-card class="el-card">
<div style="display: flex">
<div style="float: right">
<el-button
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 0"
@click="selectProduct()"
>选入产品
</el-button
>
<el-button
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 0"
@click="onModifySubmit(0)"
>草稿保存
</el-button
@ -21,13 +32,23 @@
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 0|| inputQuery.auditStatus == 6"
@click="onModifySubmit(6)"
>提交审核
</el-button
>
<el-button
type="primary"
size="mini"
icon="search"
v-if="inputQuery.auditStatus == 4|| inputQuery.auditStatus == 1|| inputQuery.auditStatus == 2"
@click="onModifySubmit(4)"
>提交变更
</el-button
>
</div>
<el-row :gutter="20" class="el-row" type="flex" style="margin-top: 20px">
<el-row :gutter="20" class="el-row" type="flex" style="margin-top:50px">
<el-col :span="10" class="el-col">
<el-form-item label="所属供应商:" label-width="150px" prop="customerId">
<el-select
@ -36,6 +57,7 @@
remote
clearable="true"
reserve-keyword
disabled
placeholder="请选择供应商"
:remote-method="findMethod"
:loading="loading"
@ -61,6 +83,7 @@
remote
clearable="true"
reserve-keyword
disabled
placeholder="请选择生产企业"
:remote-method="findPMMethod"
:loading="loading"
@ -128,16 +151,15 @@
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="10" class="el-col">
<el-form-item label="医疗器械管理类别:" label-width="150px" prop="productManageType">
<el-form-item label="产品类别:" label-width="150px" prop="hchzsb">
<el-select
size="small"
v-model="inputQuery.productManageType"
placeholder="医疗器械管理类别"
v-model="inputQuery.hchzsb"
placeholder="产品类别"
style="width: 100%;"
>
<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="耗材"></el-option>
<el-option label="设备" value="设备"></el-option>
</el-select>
</el-form-item>
</el-col>
@ -146,11 +168,11 @@
<el-select
size="small"
v-model="inputQuery.productType"
placeholder="医疗器械管理类别"
placeholder="器械类别"
style="width: 100%;"
>
<el-option label="器械" value="1"></el-option>
<el-option label="诊断试剂" value="2"></el-option>
<el-option label="器械" value="器械"></el-option>
<el-option label="诊断试剂" value="诊断试剂"></el-option>
</el-select>
</el-form-item>
</el-col>
@ -213,13 +235,9 @@
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="20" class="el-col">
<el-col :span="10" class="el-col">
<el-form-item label="规格型号:" label-width="150px" prop="specification">
<el-input
type="textarea"
size="small"
placeholder="请输入内容"
v-model="inputQuery.specification"
@ -228,6 +246,7 @@
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="20" class="el-col">
<el-form-item label="备注:" label-width="150px" prop="remark">
@ -245,12 +264,15 @@
</el-form>
<el-card class="el-card">
<div style="display: flex">
<div style="float:right ">
<el-button type="primary" size="mini" icon="search" @click="selectCert"
>选入资质证书
</el-button
>
<el-button
type="primary"
size="small"
size="mini"
icon="search"
style="margin: 0 100px 20px auto; width: 100px"
@click="addCert()"
>添加资质证书
</el-button
@ -258,7 +280,7 @@
</div>
<el-table v-loading="certLoading"
:data="certList"
style="width: 100%">
style="width: 100%;margin-top: 30px">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="证书名称" prop="name"></el-table-column>
<el-table-column label="证书编号" prop="name"></el-table-column>
@ -274,6 +296,14 @@
<el-table-column label="备注" prop="remark"></el-table-column>
<el-table-column label="操作" fixed="right" width="250">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native="addCert(scope.row)"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@ -301,7 +331,7 @@
</el-card>
<el-dialog
title="添加电子档"
title="添加资质证书"
:visible.sync="addCertVisible"
:close-on-click-modal="false"
:close-on-press-escape="false"
@ -314,15 +344,49 @@
:closeDialog="closeLocalDialog"
:inputQuery="inputQuery"
:addType="addType"
:editTye="editTye"
></companyAddCert>
</el-dialog>
<el-dialog
title="选入资质证书"
:visible.sync="selectCertVisible"
:close-on-click-modal="false"
:close-on-press-escape="false"
width="70%"
v-if="selectCertVisible"
append-to-body
@close='closeLocalDialog'
>
<supCertSetSelectDialog
:certType="certType"
:manufacturerId="manufacturerId"
:productId="productId"
:closeDialog="closeLocalDialog"
></supCertSetSelectDialog>
</el-dialog>
<el-dialog
title="选入产品"
:visible.sync="selectSingleProductVisible"
:close-on-click-modal="false"
:close-on-press-escape="false"
width="70%"
v-if="selectSingleProductVisible"
append-to-body
@close='closeLocalDialog'
>
<basicSelectSingleProducts
:selectType="selectType"
:closeSelDialog="closeSelDialog"
></basicSelectSingleProducts>
</el-dialog>
</div>
</template>
<script>
import {getRegistrationInfo, addOrModifyRegistration} from "../../api/purchase/suppliersRegistrationBasic";
import {getRegistrationInfo, addOrModifyRegistration, bindProduct} from "../../api/purchase/suppliersRegistrationBasic";
import {
provinceAndCityData,
regionData,
@ -336,6 +400,8 @@ import {getSupComapnys} from "@/api/purchase/supCompany";
import {getCompanyList} from "@/api/purchase/supManufacturer";
import {deleteCompanyCert, filterCompanyCert} from "@/api/purchase/companyCert";
import companyAddCert from "@/views/purchase/supCertAddDialog";
import supCertSetSelectDialog from "@/views/purchase/supCertSetSelectDialog";
import basicSelectSingleProducts from "@/views/basic/basicSelectSingleProducts";
import {getUUID} from "@/utils/strUtil";
import {BASE_URL} from "@/config/app";
@ -353,6 +419,10 @@ export default {
editType: {
type: Object,
required: true,
},
currentManufacturer: {
type: Object,
required: true,
}
},
data() {
@ -441,9 +511,6 @@ export default {
},
fileList: [],
fileList2: [],
idQuery: {
id: "",
},
certQuery: {
customerId: null,
@ -461,34 +528,53 @@ export default {
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
editTye: 1,
manufacturerId: null,
productId: null,
selectCertVisible: false,
selectSingleProductVisible: false,
selectType: 1,
certType: 3,
};
},
created() {
if (this.editType == 0) {
this.inputQuery.productId = getUUID("");
this.inputQuery.customerId = this.currentManufacturer.customerId;
this.inputQuery.manufacturerIdFk = this.currentManufacturer.manufacturerId;
} else {
this.getCompanyCertList();
this.pmQuery.customerId = this.inputQuery.customerId;
this.findPMMethod();
}
}
this.manufacturerId = this.inputQuery.manufacturerIdFk
this.productId = this.inputQuery.productId
this.findMethod();
this.findPMMethod();
this.certFileUrl = BASE_URL + "/udiwms/image/register/file/getImage?type=image2&name=";
},
components: {
draggable, companyAddCert
draggable, companyAddCert, supCertSetSelectDialog, basicSelectSingleProducts
},
methods: {
onModifySubmit(val) {
this.inputQuery.auditStatus = val;
this.$refs['inputQuery'].validate(valid => {
if (valid) {
// this.inputQuery.auditStatus = val;
let formData = JSON.parse(JSON.stringify(this.inputQuery));
formData.auditStatus = val;
this.loading = true;
let urlName = this.editType == 0 ? 'add' : 'update';
addOrModifyRegistration(this.inputQuery, urlName).then(response => {
addOrModifyRegistration(formData, urlName).then(response => {
this.loading = false;
if (response.code === 20000) {
this.closeRegistrationDialog(true);
@ -541,18 +627,50 @@ export default {
},
closeLocalDialog() {
this.addCertVisible = false;
this.selectCertVisible = false;
this.getCompanyCertList();
},
addCert(index, row) {
this.idQuery.id = '';
if (this.$isNotBlank(row) && this.$isNotBlank(row.id)) {
this.idQuery.id = row.id;
this.idQuery.formData = row;
closeSelDialog(val) {
if (val != null) {
let query = {
productId: this.inputQuery.productId,
relIdFk: val,
manufacturerId: this.inputQuery.manufacturerIdFk,
customerId: this.inputQuery.customerId,
auditStatus: this.inputQuery.auditStatus
};
bindProduct(query).then(response => {
this.loading = false;
if (response.code === 20000) {
this.inputQuery = response.data;
this.selectSingleProductVisible = false;
} else {
this.$message.error(response.message);
}
});
}
},
addCert(row) {
if (this.$isNotBlank(row)) {
this.formName = 2
this.inputQuery.formData = row;
this.editTye = 2;
} else {
this.formName = 1;
this.editTye = 1;
this.inputQuery.formData = {};
}
this.addCertVisible = true;
},
selectCert() {
this.selectCertVisible = true;
},
deleteCompanyCert(row) {
this.$confirm("是否删除?", "提示", {
confirmButtonText: "确定",
@ -598,6 +716,11 @@ export default {
this.certList = [];
});
},
selectProduct() {
this.selectSingleProductVisible = true;
},
},
filters: {
statusFilterType(status) {

@ -159,8 +159,8 @@ export default {
value: "",
total: 0,
companyTypeMap: {
1: "注册人/备案人",
2: "代理人"
1: "境内企业",
2: "境外企业"
},
productManageTypeMap: {
1: "Ⅰ类",
@ -168,9 +168,10 @@ export default {
3: "Ⅲ类",
},
checkFlag: {
0: "未提交",
0: "草稿",
1: "已通过",
2: "已拒绝",
4: "变更未审核",
6: "未审核",
},
list: [],

@ -245,8 +245,8 @@ import {BASE_URL} from "../../config/app";
value: "",
total: 0,
companyTypeMap: {
1: "注册人/备案人",
2: "代理人"
1: "境内企业",
2: "境外企业"
},
productManageTypeMap: {
1: "Ⅰ类",

@ -52,8 +52,8 @@
placeholder="企业类型"
style="width: 100%;"
>
<el-option label="注册人/备案人" value="1"></el-option>
<el-option label="代理人" value="2"></el-option>
<el-option label="境内企业" value="1"></el-option>
<el-option label="境外企业" value="2"></el-option>
</el-select>
</el-form-item>
</el-col>

@ -142,16 +142,15 @@
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="10" class="el-col">
<el-form-item label="医疗器械管理类别:" label-width="150px" prop="productManageType">
<el-form-item label="产品类别:" label-width="150px" prop="hchzsb">
<el-select
size="small"
v-model="inputQuery.productManageType"
placeholder="医疗器械管理类别"
v-model="inputQuery.hchzsb"
placeholder="产品类别"
style="width: 100%;"
>
<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="耗材"></el-option>
<el-option label="设备" value="设备"></el-option>
</el-select>
</el-form-item>
</el-col>
@ -160,11 +159,11 @@
<el-select
size="small"
v-model="inputQuery.productType"
placeholder="医疗器械管理类别"
placeholder="器械类别"
style="width: 100%;"
>
<el-option label="器械" value="1"></el-option>
<el-option label="诊断试剂" value="2"></el-option>
<el-option label="器械" value="器械"></el-option>
<el-option label="诊断试剂" value="诊断试剂"></el-option>
</el-select>
</el-form-item>
</el-col>
@ -181,31 +180,31 @@
></el-input>
</el-form-item>
</el-col>
<!-- <el-col :span="10" class="el-col">-->
<!-- <el-form-item label="说明书附件:" label-width="150px" prop="instructions">-->
<!-- <el-input-->
<!-- size="small"-->
<!-- placeholder="请输入内容"-->
<!-- v-model="inputQuery.instructions"-->
<!-- @input="change()"-->
<!-- ></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="10" class="el-col">-->
<!-- <el-form-item label="说明书附件:" label-width="150px" prop="instructions">-->
<!-- <el-input-->
<!-- size="small"-->
<!-- placeholder="请输入内容"-->
<!-- v-model="inputQuery.instructions"-->
<!-- @input="change()"-->
<!-- ></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
</el-row>
<!-- <el-row :gutter="20" class="el-row" type="flex">-->
<!-- <el-col :span="20" class="el-col">-->
<!-- <el-form-item label="注册/备案证电子档案:" label-width="150px" prop="recordText">-->
<!-- <el-input-->
<!-- type="textarea"-->
<!-- size="small"-->
<!-- placeholder="请输入内容"-->
<!-- v-model="inputQuery.recordText"-->
<!-- @input="change()"-->
<!-- ></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- <el-row :gutter="20" class="el-row" type="flex">-->
<!-- <el-col :span="20" class="el-col">-->
<!-- <el-form-item label="注册/备案证电子档案:" label-width="150px" prop="recordText">-->
<!-- <el-input-->
<!-- type="textarea"-->
<!-- size="small"-->
<!-- placeholder="请输入内容"-->
<!-- v-model="inputQuery.recordText"-->
<!-- @input="change()"-->
<!-- ></el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="10" class="el-col">
@ -326,11 +325,11 @@
</el-row>
<el-row :gutter="20" class="el-row" type="flex">
<!-- <el-col :span="2" class="el-col">-->
<!-- <div class="ao-text">-->
<!-- <span>文件</span>-->
<!-- </div>-->
<!-- </el-col>-->
<!-- <el-col :span="2" class="el-col">-->
<!-- <div class="ao-text">-->
<!-- <span>文件</span>-->
<!-- </div>-->
<!-- </el-col>-->
<el-col :span="10" class="el-col">
<el-form-item label="电子档:" label-width="150px">
<el-upload
@ -421,6 +420,7 @@ export default {
recordPeopleName: "",
productDirectoryCode: "",
specification: "",
hchzsb: "",
},
loading: false,
headers: {},

@ -67,7 +67,7 @@
</el-form>
<el-table v-loading="loading" :data="list" style="width: 100%">
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column label="扫码单据类型" prop="action">
<el-table-column label="扫码单据类型" prop="action" width="120">
<template slot-scope="scope">
<span>{{ getActionName(scope.row.action) }}</span>
</template>
@ -84,7 +84,7 @@
</el-table-column>
<el-table-column label="当前仓库" prop="invName" width="150"></el-table-column>
<el-table-column label="当前分库" prop="subInvName" width="120"></el-table-column>
<el-table-column label="创建时间" prop="actDate" show-overflow-tooltip>
<el-table-column label="创建时间" prop="actDate" width="120" show-overflow-tooltip>
<template slot-scope="scope">
<i class="el-icon-time"></i>
<span>{{ scope.row.actDate }}</span>

@ -1,412 +1,417 @@
<template>
<div>
<el-form :inline="true" :model="query" class="query-form" size="mini">
<el-form-item class="query-form-item">
<el-input v-model="query.code" placeholder="条码查询"></el-input>
</el-form-item>
<div>
<el-form :inline="true" :model="query" class="query-form" size="mini">
<el-form-item class="query-form-item">
<el-input v-model="query.code" placeholder="条码查询"></el-input>
</el-form-item>
<el-form-item>
<el-button-group>
<el-button type="primary" icon="search" @click="search"
>查询
</el-button
>
<el-button type="primary" icon="search" @click="editOrderTime"
>编辑
</el-button
>
</el-button-group>
</el-form-item>
</el-form>
<el-table v-loading="loading" :data="codeArry" style="width: 100%">
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="条码"
prop="code"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="扫码数量"
prop="count"
width="180"
show-overflow-tooltip
></el-table-column>
<el-table-column label="创建时间" prop="actDate" width="220" show-overflow-tooltip>
<template slot-scope="scope">
<i class="el-icon-time"></i>
<span>{{ scope.row.actDate }}</span>
</template>
</el-table-column>
<el-table-column label="操作员" prop="actor" width="180"></el-table-column>
<el-table-column label="操作" fixed="right" width="180">
<template slot-scope="scope">
<el-button
size="small"
type="text"
@click.native.stop="replaceCodes(scope.row)"
>
减一
</el-button>
</template>
</el-table-column>
</el-table>
<el-form-item>
<el-button-group>
<el-button type="primary" icon="search" @click="search"
>查询
</el-button
>
<el-button type="primary" icon="search" @click="editOrderTime"
v-if="editType!=1"
>编辑
</el-button
>
</el-button-group>
</el-form-item>
</el-form>
<el-table v-loading="loading" :data="codeArry" style="width: 100%">
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="条码"
prop="code"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="扫码数量"
prop="count"
width="180"
show-overflow-tooltip
></el-table-column>
<el-table-column label="创建时间" prop="actDate" width="220" show-overflow-tooltip>
<template slot-scope="scope">
<i class="el-icon-time"></i>
<span>{{ scope.row.actDate }}</span>
</template>
</el-table-column>
<el-table-column label="操作员" prop="actor" width="180"></el-table-column>
<el-table-column label="操作" fixed="right" width="180" v-if="editType!=1">
<template slot-scope="scope">
<el-button
size="small"
type="text"
@click.native.stop="replaceCodes(scope.row)"
>
减一
</el-button>
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="query.limit"
@current-change="handleCurrentChange"
layout="prev, pager, next,total"
:total="total"
>
</el-pagination>
<el-dialog
title="码替换"
:visible.sync="replaceVisible"
:append-to-body="true"
width="70%"
>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="10" class="el-col">
<div class="text item">
<div class="itemTag">
<span>条码:&nbsp;</span>
</div>
<el-input
style="width: 400px"
size="small"
splaceholder="请输入内容"
disabled="true"
v-model="codeDetail.code"
></el-input>
</div>
</el-col>
<el-col :span="10" class="el-col">
<div class="text item">
<div class="itemTag">
<span>扫码数量:&nbsp;</span>
</div>
<el-input
style="width: 400px"
disabled="true"
size="small"
splaceholder="请输入内容"
v-model="codeDetail.count"
></el-input>
</div>
</el-col>
</el-row>
<el-pagination
:page-size="query.limit"
@current-change="handleCurrentChange"
layout="prev, pager, next,total"
:total="total"
>
</el-pagination>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="10" class="el-col">
<div class="text item">
<div class="itemTag">
<span>替换条码:&nbsp;</span>
</div>
<el-input
style="width: 400px"
size="small"
splaceholder="请输入内容"
v-model="codeDetail.newCode"
></el-input>
</div>
</el-col>
<el-col :span="10" class="el-col">
<div class="text item">
<div class="itemTag">
<span>扫码数量:&nbsp;</span>
</div>
<el-input
style="width: 400px"
size="small"
splaceholder="请输入内容"
v-model="codeDetail.newCount"
></el-input>
</div>
</el-col>
</el-row>
<el-dialog
title="码替换"
:visible.sync="replaceVisible"
:append-to-body="true"
width="70%"
>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="10" class="el-col">
<div class="text item">
<div class="itemTag">
<span>条码:&nbsp;</span>
</div>
<el-input
style="width: 400px"
size="small"
splaceholder="请输入内容"
disabled="true"
v-model="codeDetail.code"
></el-input>
</div>
</el-col>
<el-col :span="10" class="el-col">
<div class="text item">
<div class="itemTag">
<span>扫码数量:&nbsp;</span>
</div>
<el-input
style="width: 400px"
disabled="true"
size="small"
splaceholder="请输入内容"
v-model="codeDetail.count"
></el-input>
</div>
</el-col>
</el-row>
<div style="text-align: center">
<el-button type="primary" size="small" icon="search" @click="replaceCodes"
>提交
</el-button
>
<el-button type="primary" size="small" icon="search" @click="cancelDialog"
>取消
</el-button
>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="10" class="el-col">
<div class="text item">
<div class="itemTag">
<span>替换条码:&nbsp;</span>
</div>
<el-input
style="width: 400px"
size="small"
splaceholder="请输入内容"
v-model="codeDetail.newCode"
></el-input>
</div>
</el-col>
<el-col :span="10" class="el-col">
<div class="text item">
<div class="itemTag">
<span>扫码数量:&nbsp;</span>
</div>
</el-dialog>
<el-input
style="width: 400px"
size="small"
splaceholder="请输入内容"
v-model="codeDetail.newCount"
></el-input>
</div>
</el-col>
</el-row>
<el-dialog
title="修改时间"
:visible.sync="editOrderVisible"
width="35%"
append-to-body
v-if="editOrderVisible"
<div style="text-align: center">
<el-button type="primary" size="small" icon="search" @click="replaceCodes"
>提交
</el-button
>
<el-button type="primary" size="small" icon="search" @click="cancelDialog"
>取消
</el-button
>
</div>
</el-dialog>
<el-row style="width: 100%">
<el-lable>创建时间</el-lable>
<el-date-picker
v-model="actDate"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
:picker-options="pickerOptions"
placeholder="选择日期时间">
</el-date-picker>
</el-row>
<el-dialog
title="修改时间"
:visible.sync="editOrderVisible"
width="35%"
append-to-body
v-if="editOrderVisible"
>
<el-row style="width: 100%; margin-top: 20px;">
<el-lable>审核时间</el-lable>
<el-date-picker
v-model="auditTime"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
:picker-options="pickerOptions"
placeholder="选择日期">
</el-date-picker>
</el-row>
<el-row style="width: 100%">
<el-lable>创建时间</el-lable>
<el-date-picker
v-model="actDate"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
:picker-options="pickerOptions"
placeholder="选择日期时间">
</el-date-picker>
</el-row>
<div style="text-align: right; margin-top: 10px;">
<el-button type="primary" size="small" icon="search" @click="updateOrderInfo"
>提交
</el-button
>
<el-button type="primary" size="small" icon="search" @click="cancelEdit"
>取消
</el-button
>
</div>
</el-dialog>
</div>
<el-row style="width: 100%; margin-top: 20px;">
<el-lable>审核时间</el-lable>
<el-date-picker
v-model="auditTime"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
:picker-options="pickerOptions"
placeholder="选择日期">
</el-date-picker>
</el-row>
<div style="text-align: right; margin-top: 10px;">
<el-button type="primary" size="small" icon="search" @click="updateOrderInfo"
>提交
</el-button
>
<el-button type="primary" size="small" icon="search" @click="cancelEdit"
>取消
</el-button
>
</div>
</el-dialog>
</div>
</template>
<script>
import {codeList, updateOrderInfo, getOrderById} from "../../api/warehouse/order";
import draggable from "vuedraggable";
import {replaceCodes} from "@/api/basic/invWarehouse";
import {codeList, updateOrderInfo, getOrderById} from "../../api/warehouse/order";
import draggable from "vuedraggable";
import {replaceCodes} from "@/api/basic/invWarehouse";
export default {
name: "idQuery",
props: {
idQuery: {
type: Object,
required: true,
},
},
data() {
return {
query: {
code: "",
corpOrderId: "",
page: 1,
limit: 20,
},
codeArry: [],
total: 0,
loading: true,
index: null,
formLoading: false,
formVisible: false,
replaceVisible: false,
deleteLoading: false,
orderNo: null,
busTypes: [],
codeDetail: {
code: null,
count: null,
newCode: null,
newCount: null,
orderId: null
},
actDate: null,
auditTime: null,
editOrderVisible: false
};
},
components: {
draggable,
},
methods: {
onReset() {
this.$router.push({
path: "",
});
this.query = {
code: "",
corpOrderId: "",
page: 1,
limit: 20,
};
this.getCodeList();
},
onSubmit() {
this.$router.push({
path: "",
query: this.query,
});
this.getCodeList();
},
handleSizeChange(val) {
this.query.limit = val;
this.getCodeList();
},
handleCurrentChange(val) {
this.query.page = val;
this.getCodeList();
},
search() {
this.query.page = 1;
this.getCodeList();
},
getCodeList() {
this.loading = true;
this.query.corpOrderId = this.idQuery.id;
codeList(this.query) //
.then((response) => {
this.loading = false;
this.codeArry = response.data.list || [];
this.total = response.data.total || 0;
})
.catch(() => {
this.loading = false;
this.list = [];
this.total = 0;
});
},
intentBack() {
this.$router.go(-1);
},
showReplaceDialog(row) {
this.replaceVisible = true;
this.codeDetail = {
code: row.code,
count: row.count,
orderId: row.orderId
}
},
cancelDialog() {
this.replaceVisible = false;
this.codeDetail = {
code: null,
count: null,
newCode: null,
newCount: null
};
},
replaceCodes(row) {
this.$confirm("是否确认库存减一", "提示", {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.codeDetail = {
code: row.code,
count: row.count,
orderId: row.orderId
};
replaceCodes(this.codeDetail).then((res) => {
if (res.code === 20000) {
this.$message.success("操作成功");
this.getCodeList();
} else {
this.$message.error(res.message);
}
}).catch((error) => {
this.$message.error(error.message);
});
}).catch(() => {
this.$message({
type: 'info',
message: '已取消操作'
});
});
},
editOrderTime() {
let getOrderDataParam = {
id: this.query.corpOrderId,
};
getOrderById(getOrderDataParam).then((res) => {
this.actDate = res.data.actDate;
this.auditTime = res.data.auditTime;
this.editOrderVisible = true;
}).catch((error) => {
});
},
updateOrderInfo() {
if (this.actDate === null || this.auditTime === null) {
this.$message.warning("创建时间和审核时间不能为空");
return;
} else if (this.actDate > this.auditTime) {
this.$message.warning("请检查创建时间和审核时间是否正确");
return;
}
let data = {
actDate: this.actDate,
auditTime: this.auditTime,
orderIds: [this.query.corpOrderId]
};
updateOrderInfo(data).then((res) => {
if (res.code === 20000) {
this.$message.success("修改成功");
}
}).catch((error) => {
});
this.actDate = null;
this.auditTime = null;
this.editOrderVisible = false;
},
cancelEdit() {
this.editOrderVisible = false;
this.actDate = null;
this.auditTime = null;
}
},
filters: {},
mounted() {
document.body.ondrop = function (event) {
event.preventDefault();
event.stopPropagation();
};
},
created() {
//
let query = this.$route.query;
this.orderNo = query.id;
this.query = Object.assign(this.query, query);
this.query.limit = parseInt(this.query.limit);
this.query.corpOrderId = query.id;
//
export default {
name: "idQuery",
props: {
idQuery: {
type: Object,
required: true,
},
editType: { //1::
type: Object,
required: true,
}
},
data() {
return {
query: {
code: "",
corpOrderId: "",
page: 1,
limit: 20,
},
codeArry: [],
total: 0,
loading: true,
index: null,
formLoading: false,
formVisible: false,
replaceVisible: false,
deleteLoading: false,
orderNo: null,
busTypes: [],
codeDetail: {
code: null,
count: null,
newCode: null,
newCount: null,
orderId: null
},
actDate: null,
auditTime: null,
editOrderVisible: false
};
},
components: {
draggable,
},
methods: {
onReset() {
this.$router.push({
path: "",
});
this.query = {
code: "",
corpOrderId: "",
page: 1,
limit: 20,
};
this.getCodeList();
},
onSubmit() {
this.$router.push({
path: "",
query: this.query,
});
this.getCodeList();
},
handleSizeChange(val) {
this.query.limit = val;
this.getCodeList();
},
handleCurrentChange(val) {
this.query.page = val;
this.getCodeList();
},
search() {
this.query.page = 1;
this.getCodeList();
},
getCodeList() {
this.loading = true;
this.query.corpOrderId = this.idQuery.id;
codeList(this.query) //
.then((response) => {
this.loading = false;
this.codeArry = response.data.list || [];
this.total = response.data.total || 0;
})
.catch(() => {
this.loading = false;
this.list = [];
this.total = 0;
});
},
intentBack() {
this.$router.go(-1);
},
showReplaceDialog(row) {
this.replaceVisible = true;
this.codeDetail = {
code: row.code,
count: row.count,
orderId: row.orderId
}
},
cancelDialog() {
this.replaceVisible = false;
this.codeDetail = {
code: null,
count: null,
newCode: null,
newCount: null
};
},
replaceCodes(row) {
this.$confirm("是否确认库存减一", "提示", {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.codeDetail = {
code: row.code,
count: row.count,
orderId: row.orderId
};
replaceCodes(this.codeDetail).then((res) => {
if (res.code === 20000) {
this.$message.success("操作成功");
this.getCodeList();
},
} else {
this.$message.error(res.message);
}
}).catch((error) => {
this.$message.error(error.message);
});
}).catch(() => {
this.$message({
type: 'info',
message: '已取消操作'
});
});
},
editOrderTime() {
let getOrderDataParam = {
id: this.query.corpOrderId,
};
getOrderById(getOrderDataParam).then((res) => {
this.actDate = res.data.actDate;
this.auditTime = res.data.auditTime;
this.editOrderVisible = true;
}).catch((error) => {
});
},
updateOrderInfo() {
if (this.actDate === null || this.auditTime === null) {
this.$message.warning("创建时间和审核时间不能为空");
return;
} else if (this.actDate > this.auditTime) {
this.$message.warning("请检查创建时间和审核时间是否正确");
return;
}
let data = {
actDate: this.actDate,
auditTime: this.auditTime,
orderIds: [this.query.corpOrderId]
};
updateOrderInfo(data).then((res) => {
if (res.code === 20000) {
this.$message.success("修改成功");
}
}).catch((error) => {
});
this.actDate = null;
this.auditTime = null;
this.editOrderVisible = false;
},
cancelEdit() {
this.editOrderVisible = false;
this.actDate = null;
this.auditTime = null;
}
},
filters: {},
mounted() {
document.body.ondrop = function (event) {
event.preventDefault();
event.stopPropagation();
};
},
created() {
//
let query = this.$route.query;
this.orderNo = query.id;
this.query = Object.assign(this.query, query);
this.query.limit = parseInt(this.query.limit);
this.query.corpOrderId = query.id;
//
this.getCodeList();
},
};
</script>
<style scoped>
.itemTag {
float: left;
text-align: left;
margin-top: 10px;
width: 100px;
}
.itemTag {
float: left;
text-align: left;
margin-top: 10px;
width: 100px;
}
.text {
font-size: 13px;
font-family: "Microsoft YaHei";
}
.text {
font-size: 13px;
font-family: "Microsoft YaHei";
}
.el-row {
display: flex;
flex-wrap: wrap;
margin-bottom: 20px;
}
.el-row {
display: flex;
flex-wrap: wrap;
margin-bottom: 20px;
}
.el-col {
border-radius: 4px;
flex-wrap: wrap;
}
.el-col {
border-radius: 4px;
flex-wrap: wrap;
}
</style>

@ -248,7 +248,7 @@
size="small"
icon="search"
style="margin-top: 20px; width: 200px"
@click="onModifySubmit('inputQuery')"
@click="onModifySubmit()"
>
</el-button
>
@ -259,157 +259,149 @@
</template>
<script>
import {
getCompany,
modifyCompany,
getRefid,
} from "../../api/warehouse/company";
import store from "../../store/index";
import {
getCompany,
modifyCompany,
getRefid,
} from "../../api/warehouse/company";
import store from "../../store/index";
export default {
data() {
return {
inputQuery: {
companyName: "",
bussinessStatus: "",
creditNum: "",
classes: "",
area: "",
detailAddr: "",
contacts: "",
mobile: "",
tel: "",
email: "",
refEntId: "",
entId: "",
customerId: store.getters.customerId,
},
export default {
data() {
return {
inputQuery: {
companyName: "",
bussinessStatus: "",
creditNum: "",
classes: "",
area: "",
detailAddr: "",
contacts: "",
mobile: "",
tel: "",
email: "",
refEntId: "",
entId: "",
customerId: store.getters.customerId,
},
rules: {
companyName: [
{required: true, message: "请输入企业名称", trigger: "blur"},
],
creditCode: [
{
required: true,
message: "请输入统一社会信用代码",
trigger: "blur",
},
],
category: [
{
required: true,
message: "请选择企业类型",
trigger: "change",
},
],
rules: {
companyName: [
{required: true, message: "请输入企业名称", trigger: "blur"},
],
creditCode: [
{
required: true,
message: "请输入统一社会信用代码",
trigger: "blur",
},
],
category: [
{
required: true,
message: "请选择企业类型",
trigger: "change",
},
],
appId: [
{
required: true,
message: "请输入应用码",
trigger: "blur",
},
],
appId: [
{
required: true,
message: "请输入应用码",
trigger: "blur",
},
],
appSecret: [
{required: true, message: "请输入授权码", trigger: "blur"},
],
},
};
appSecret: [
{required: true, message: "请输入授权码", trigger: "blur"},
],
},
};
},
created() {
this.getData();
},
methods: {
onModifySubmit() {
this.loading = true;
modifyCompany(this.inputQuery).then((response) => {
if (response.code == 20000) {
this.getData();
this.loading = false;
this.$message.success("修改成功");
} else {
this.$message.error(response.message);
}
});
},
created() {
this.getData();
checkName() {
let tquery = {
companyName: this.inputQuery.companyName,
};
getRefid(tquery).then((response) => {
if (response.code == 20000) {
this.$message.success("校验成功!");
this.inputQuery.refEntId = response.data.ref_ent_id;
this.inputQuery.entId = response.data.ent_id;
} else {
this.$message.error(response.message);
}
});
},
methods: {
onModifySubmit(formName) {
// this.$refs[formName].validate((valid) => {
// if (valid) {
// } else {
// console.log("error submit!!");
// return false;
// }
// });
this.loading = true;
modifyCompany(this.inputQuery).then((response) => {
if (response.code == 20000) {
this.getData();
this.loading = false;
this.$message.success("修改成功");
} else {
this.$message.error(response.message);
}
});
},
checkName() {
let tquery = {
companyName: this.inputQuery.companyName,
};
getRefid(tquery).then((response) => {
if (response.code == 20000) {
this.$message.success("校验成功!");
this.inputQuery.refEntId = response.data.ref_ent_id;
this.inputQuery.entId = response.data.ent_id;
} else {
this.$message.error(response.message);
}
});
},
checkPanrentName() {
let tquery = {
companyName: this.inputQuery.parentCompany,
};
getRefid(tquery).then((response) => {
if (response.code == 20000) {
this.$message.success("校验成功!");
} else {
this.$message.error(response.message);
}
});
},
getData() {
this.loading = true;
let tquery = {
customerId: store.getters.customerId,
};
getCompany(tquery).then((response) => {
this.loading = false;
this.inputQuery = response.data;
this.inputQuery.bussinessStatus = this.inputQuery.bussinessStatus + "";
});
},
checkPanrentName() {
let tquery = {
companyName: this.inputQuery.parentCompany,
};
getRefid(tquery).then((response) => {
if (response.code == 20000) {
this.$message.success("校验成功!");
} else {
this.$message.error(response.message);
}
});
},
getData() {
this.loading = true;
let tquery = {
customerId: store.getters.customerId,
};
getCompany(tquery).then((response) => {
this.loading = false;
this.inputQuery = response.data;
this.inputQuery.bussinessStatus = this.inputQuery.bussinessStatus + "";
});
},
};
},
};
</script>
<style scoped>
.itemTag {
float: left;
text-align: left;
margin-top: 10px;
width: 120px;
}
.itemTag {
float: left;
text-align: left;
margin-top: 10px;
width: 120px;
}
.text {
width: 100%;
font-size: 13px;
font-family: "Microsoft YaHei";
}
.text {
width: 100%;
font-size: 13px;
font-family: "Microsoft YaHei";
}
.el-card {
margin-right: 20px;
margin-top: 15px;
/*transition: all .5s;*/
}
.el-card {
margin-right: 20px;
margin-top: 15px;
/*transition: all .5s;*/
}
.el-row {
display: flex;
flex-wrap: wrap;
}
.el-row {
display: flex;
flex-wrap: wrap;
}
.el-col {
border-radius: 4px;
flex-wrap: wrap;
}
.el-col {
border-radius: 4px;
flex-wrap: wrap;
}
</style>

@ -0,0 +1,593 @@
<template>
<div>
<el-card class="el-card">
<el-form
:inline="true"
:model="query"
class="query-form"
size="mini"
>
<el-row style="width: 100%">
<el-form-item class="query-form-item">
<el-input style="width: 300px" v-model="query.billNo" placeholder="单据号"></el-input>
</el-form-item>
<el-form-item>
<el-button-group>
<el-button type="primary" icon="el-icon-refresh" @click="onReset"></el-button>
<el-button type="primary" icon="search" @click="onSubmit"></el-button>
</el-button-group>
</el-form-item>
</el-row>
</el-form>
<el-table
v-loading="loading"
:data="list"
style="width: 100%"
@row-click="getOrderDetailList"
highlight-current-row
@selection-change="handleSelectionChange"
:row-class-name="tableRowClassName"
>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column label="扫码单据类型" prop="action">
<template slot-scope="scope">
<span>{{ getActionName(scope.row.action) }}</span>
</template>
</el-table-column>
<el-table-column
label="扫码单据号"
prop="id"
show-overflow-tooltip="true"
></el-table-column>
<el-table-column
label="业务单据号"
prop="erpFk"
show-overflow-tooltip="true"
></el-table-column>
<el-table-column label="来源" prop="fromType">
<template slot-scope="scope">
<span>{{ fromTypeMap[scope.row.fromType] }}</span>
</template>
</el-table-column>
<el-table-column label="往来单位" prop="fromCorp" width="250">
</el-table-column>
<el-table-column label="当前仓库" prop="locStorageCode" width="150">
<template slot-scope="scope">
<span>{{ getStorageName(scope.row.locStorageCode) }}</span>
</template>
</el-table-column>
<el-table-column label="所属科室" prop="deptName" width="120" v-if="enableDept">
</el-table-column>
<el-table-column
label="创建时间"
prop="actDate"
width="150"
show-overflow-tooltip="true"
>
<template slot-scope="scope">
<i class="el-icon-time"></i>
<span>{{ scope.row.actDate }}</span>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" width="150">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="intentDetail(scope.row)"
>详情
</el-button
>
</template>
</el-table-column>
</el-table>
</el-card>
<el-card class="el-card" v-if="true">
<el-table
v-loading="loading"
:data="detailList"
style="width: 100%"
>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="产品通用名"
prop="coName"
:show-overflow-tooltip="true"
></el-table-column>
<el-table-column
label="包装规格"
prop="packSpec"
:show-overflow-tooltip="true"
></el-table-column>
<el-table-column
label="批次号"
prop="batchNo"
:show-overflow-tooltip="true"
></el-table-column>
<el-table-column
label="生产日期"
prop="productDate"
:show-overflow-tooltip="true"
></el-table-column>
<el-table-column
label="失效日期"
prop="expireDate"
:show-overflow-tooltip="true"
></el-table-column>
<el-table-column
label="单据数量"
prop="erpCount"
:show-overflow-tooltip="true"
></el-table-column>
<el-table-column
label="实际数量"
prop="reCount"
:show-overflow-tooltip="true"
></el-table-column>
<el-table-column label="扫码数量" prop="count"></el-table-column>
<el-table-column
label="供应商"
prop="supName"
:show-overflow-tooltip="true"
></el-table-column>
<el-table-column
label="生产企业"
prop="productCompany"
:show-overflow-tooltip="true"
></el-table-column>
<el-table-column
label="注册/备案凭证号"
prop="authCode"
:show-overflow-tooltip="true"
></el-table-column>
</el-table>
</el-card>
<el-dialog
title="详情"
:visible.sync="codeDetailVisible"
width="80%"
v-if="codeDetailVisible"
:close-on-click-modal="false"
:close-on-press-escape="false"
>
<codeReplace
:idQuery="idQuery"
:editType="editType"
v-on:closeDetailDialog="closeDetailDialog"
></codeReplace>
</el-dialog>
<el-dialog title="校验信息" :visible.sync="errDialogVisible" width="30%">
<span>{{ errorDetail }}</span>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="errDialogVisible = false"> </el-button>
</span>
</el-dialog>
<el-dialog
title="修改时间"
:visible.sync="editOrderVisible"
width="35%"
v-if="editOrderVisible"
>
<el-row style="width: 100%">
<el-lable>创建时间</el-lable>
<el-date-picker
v-model="actDate"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
:picker-options="pickerOptions"
placeholder="选择日期时间">
</el-date-picker>
</el-row>
<el-row style="width: 100%; margin-top: 20px;">
<el-lable>审核时间</el-lable>
<el-date-picker
v-model="auditTime"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
:picker-options="pickerOptions"
placeholder="选择日期">
</el-date-picker>
</el-row>
<div style="text-align: right; margin-top: 10px;">
<el-button type="primary" size="small" icon="search" @click="updateOrderInfo"
>提交
</el-button
>
<el-button type="primary" size="small" icon="search" @click="cancelEdit"
>取消
</el-button
>
</div>
</el-dialog>
</div>
</template>
<script>
import {filterOrderForDelete, orderDetail, deleteByOrderId, updateOrderInfo} from "../../api/warehouse/order";
import store from "../../store";
import {getBussinessType} from "../../api/basic/bussinessType";
import {filterAllByUser} from "@/api/basic/invWarehouse";
import codeReplace from "./codeReplace";
import {selectSysParamByKey} from "@/api/param/systemParamConfig";
export default {
name: "stockOrderDelete",
data() {
return {
query: {
billNo: "",
page: 1,
limit: 10
},
detailQuery: {
orderIdFk: "",
page: 1,
limit: 20
},
busTypes: [],
list: [],
detailList: [],
currentCheckIndex: -1,
multipId: [],
formLabelWidth: '150px',
total: 0,
detailTotal: 0,
storageList: [],
loading: false,
detailLoading: false,
enableDept: false,
idQuery: {
id: "",
},
editType: 1,
sourceMap: {
"1": "web端新增单据",
"2": "第三方系统",
"3": "扫码单据转换",
},
fromTypeMap: {
"1": "UDIMS平台",
"2": "网页新增",
"3": "pda即时校验",
"4": "pda未校验",
"5": "pc端扫码精灵",
"6": "缺量补录单据",
"7": "UDI供应商平台",
"8": "平衡补录单据",
"10": "手动补单"
},
erpCheckStatus: {
0: "未校验",
1: "失败",
2: "成功",
},
isSp: store.getters.customerId,
detailFormData: {},
detailFormLoading: false,
actDateRange: [],
curRow: null,
codeDetailVisible: false,
editOrderVisible: false,
actDate: null, //
auditTime: null, //
orderIds: [],
pickerOptions: {
disabledDate: time => {
let endDate = new Date().getTime();
let nowDate = new Date(time).getTime();
return (nowDate > endDate);
}
}
}
},
methods: {
onReset() {
this.$router.push({
path: ""
});
this.query = {
billNo: ""
};
this.list = [];
this.detailList = [];
this.actDateRange = [];
},
onSubmit() {
this.query.page = 1;
this.getList();
},
handleCurrentChange(val) {
this.query.page = val;
this.getList();
},
changeFun(row) {
let _this = this;
_this.multipId = []; //ID
row.forEach((item) => {
_this.multipId.push(item.id);
})
},
detailHandleCurrentChange(val) {
this.query.page = val;
this.getOrderDetailList();
},
//
resetForm() {
if (this.$refs["dataForm"]) {
//
this.$refs["dataForm"].clearValidate();
//
this.$refs["dataForm"].resetFields();
this.getList();
}
},
getList() {
this.query.billNo = this.query.billNo.trim();
if (this.query.billNo === null || this.query.billNo === "") {
this.$message.warning("请输入需要查询的单号");
} else {
this.loading = true;
filterOrderForDelete(this.query)
.then(response => {
this.loading = false;
this.list = response.data.list || [];
this.detailList = [];
this.total = response.data.total || 0;
})
.catch(() => {
this.loading = false;
this.list = [];
this.total = 0;
this.detailList = [];
});
}
},
getOrderDetailList(row) {
if (this.$isNotBlank(row)) {
this.detailQuery.orderId = row.id;
this.detailQuery.orderIdFk = row.id;
}
this.detailLoading = true;
orderDetail(this.detailQuery)
.then((response) => {
this.detailLoading = false;
this.detailList = response.data || [];
})
.catch(() => {
this.detailLoading = false;
this.detailList = [];
});
},
tableRowClassName({row, rowIndex}) {
if (rowIndex === 0) {
return 'highlight-row';
}
return '';
},
getActionName(action) {
for (let i = 0; i < this.busTypes.length; i++) {
if (this.busTypes[i].action === action) {
return this.busTypes[i].name;
}
}
},
getBusType() {
let query = {
enabled: true,
};
getBussinessType(query)
.then((response) => {
this.busTypes = response.data.list || [];
})
.catch(() => {
});
},
getStorageName(code) {
for (let i = 0; i < this.storageList.length; i++) {
if (this.storageList[i].code === code) {
return this.storageList[i].name;
}
}
},
getStorage() {
this.storageList = [];
filterAllByUser()
.then((response) => {
this.storageList = response.data || [];
})
.catch(() => {
});
},
deleteOrder(row) {
this.$confirm('是否确认删除单据及相关数据?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let params = {
id: row.id
};
deleteByOrderId(params).then((res) => {
if (res.code === 20000) {
this.$message({
type: 'success',
message: '删除成功!'
});
this.getList();
this.detailList = [];
}
}).catch((error) => {
this.$message.error("删除失败");
});
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
});
});
},
deleteAllOrder() {
if (this.query.billNo === null || this.query.billNo === "" || this.list.length === 0) {
return;
}
this.$confirm("是否确认删除此单据及所有关联单据?", "提示", {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let ids = [];
this.list.forEach(item => {
ids.push(item.id);
});
let params = {
ids: ids
};
deleteByOrderId(params).then((res) => {
if (res.code === 20000) {
this.$message.success("删除成功");
this.list = [];
this.detailList = [];
}
}).catch((error) => {
this.$message.error("删除失败");
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
});
})
},
editAllOrderTime() {
if (this.query.billNo === null || this.query.billNo === "" || this.list.length === 0) {
return;
}
this.actDate = null;
this.auditTime = null;
this.editOrderVisible = true;
},
intentDetail(row) {
this.codeDetailVisible = true;
this.idQuery.id = row.id;
},
handleEdit(row) {
this.editOrderVisible = true;
let actDateSplit = row.actDate.split(" ");
this.actDate = actDateSplit[0];
this.actDate2 = actDateSplit[1];
let auditTimeSplit = row.auditTime.split(" ");
this.auditTime = auditTimeSplit[0];
this.auditTime2 = auditTimeSplit[1];
this.orderIds = [];
},
updateOrderInfo() {
if (this.actDate === null || this.actDate === '') {
this.$message.warning("创建时间不能为空");
return;
}
this.editOrderVisible = false;
this.list.forEach(item => {
this.orderIds.push(item.id);
});
let data = {
actDate: this.actDate,
auditTime: this.auditTime,
orderIds: this.orderIds
};
updateOrderInfo(data).then((res) => {
if (res.code === 20000) {
this.$message.success("修改成功");
this.getList();
}
}).catch((error) => {
this.$message.error(error.message);
});
},
cancelEdit() {
this.editOrderVisible = false;
}
},
components: {
codeReplace
},
filters: {
statusFilterType(status) {
const statusMap = {
0: "gray",
1: "success"
};
return statusMap[status];
},
statusFilterName(status) {
const statusMap = {
"1": "草稿",
"2": "未配货",
"3": "待校验",
"4": "已校验",
"5": "已核对",
};
return statusMap[status];
},
typeFilterName(type) {
const typeMap = {
1: "预入库",
2: "普通采购",
};
return typeMap[type];
}
},
created() {
this.getBusType();
this.getStorage();
selectSysParamByKey({paramKey: "muti_inv_mode"}).then((res) => {
if (res.code === 20000) {
if (res.data.paramValue === "0") {
this.enableDept = true;
}
}
})
}
}
</script>
<style scoped>
.el-dialog {
display: flex;
flex-direction: column;
margin: 0 !important;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}
.el-dialog .el-dialog__body {
flex: 1;
overflow: auto;
}
.el-table /deep/ .highlight-row {
background: #cae3f9;
}
</style>
Loading…
Cancel
Save