(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-e11dfe14","chunk-4d52a562"],{"15c0":function(t,e,a){},3379:function(t,e,a){"use strict";a("9813")},5305:function(t,e,a){"use strict";a.r(e);a("99af");var n=function(){var t=this,e=t._self._c;return e("div",[e("a-table",{attrs:{columns:t.columns,"row-key":"code",bordered:"","data-source":t.tableData,loading:t.tableLoading,pagination:!1,scroll:{x:"max-content"}},scopedSlots:t._u([{key:"id",fn:function(a,n,i){return[e("span",[t._v(t._s(parseInt(i)+1))])]}},{key:"status",fn:function(a){return[e("span",[t._v(t._s(a?"已核验":"未核验"))])]}}])}),e("div",{staticStyle:{"text-align":"right","margin-top":"24px"}},[e("a-pagination",{attrs:{total:t.total,"show-size-changer":"","show-quick-jumper":"","show-total":function(e){return"共".concat(e,"条记录  第 ").concat(t.pageNum,"页")}},on:{change:t.handleCurrentChange,showSizeChange:t.onPageShowSizeChange},model:{value:t.pageNum,callback:function(e){t.pageNum=e},expression:"pageNum"}})],1)],1)},i=[],r=a("b018"),o=[{title:"序号",dataIndex:"consumableId",align:"center",width:70,ellipsis:!0,scopedSlots:{customRender:"id"}},{title:"监管码/追溯码",dataIndex:"code",align:"center",ellipsis:!0},{title:"码等级",dataIndex:"codeLevelTxt",align:"center",ellipsis:!0},{title:"最小包装数量",dataIndex:"pkgAmount",align:"center",ellipsis:!0},{title:"最小制剂数量",dataIndex:"prepnAmount",align:"center",ellipsis:!0},{title:"核验状态",dataIndex:"status",align:"center",width:100,fixed:"right",scopedSlots:{customRender:"status"}}],s={props:["modelData","codeType"],name:"zsm",mixins:[r["a"]],data:function(){return{columns:o,queryUrl:"",modelTitle:"追溯码",modelVisible:!1,modelConfirmLoading:!1,modelType:"edit",queryParams:{keyword:""},otherParams:{method:"get"}}},created:function(){this.queryParams.queryId=this.modelData.id,this.codeType&&(this.queryParams.codeType=this.codeType),this.queryUrl="/api/code-info/codes"},methods:{handleSubmit:function(){this.pageNum=1,this.loadData()},handleReset:function(){this.queryParams.keyword="",this.loadData()}}},c=s,d=(a("9d08"),a("2877")),l=Object(d["a"])(c,n,i,!1,null,"f8699e74",null);e["default"]=l.exports},9813:function(t,e,a){},"9d08":function(t,e,a){"use strict";a("15c0")},b018:function(t,e,a){"use strict";var n=a("5530"),i=(a("99af"),a("a15b"),a("d3b7"),a("ac1f"),a("5319"),a("c1df")),r=a.n(i),o={data:function(){return{advanced:!1,exportLoading:!1,selectedRowKeys:[],pageNum:1,pageSize:10,total:0,tableData:[],tableLoading:!1,queryParams:{},otherParams:{}}},mounted:function(){this.isCancelHttp||this.loadData()},methods:{handleSubmit:function(t){t&&t.preventDefault();var e=this.queryParams,a={};for(var n in e)(e[n]||0===e[n])&&("rangeTime"===n?(a.beginTime=r()(e[n][0]).format("YYYY-MM-DD"),a.endTime=r()(e[n][1]).format("YYYY-MM-DD")):"f3"===n?a.startTime=r()(e[n]).format("YYYY-MM-DD"):a[n]=e[n]);this.queryParams=a,1!==this.pageNum&&(this.pageNum=1),this.loadData()},handleReset:function(){"{}"!==JSON.stringify(this.queryParams)&&(this.queryParams={},this.handleSubmit())},toggleAdvanced:function(){this.advanced=!this.advanced},setUrlQuery:function(t){var e=t.query,a="";if(e){var n=[];for(var i in e)e.hasOwnProperty(i)&&n.push("".concat(i,"=").concat(e[i]));a=-1!==a.indexOf("?")?"".concat(a,"&").concat(n.join("&")):"".concat(a,"?").concat(n.join("&"))}return a},loadData:function(){var t=this;if(this.queryUrl||this.otherParams.queryUrl){var e=Object.assign({pageNum:this.pageNum,pageSize:this.pageSize},this.queryParams,this.otherParams);this.tableLoading=!0;var a=this.otherParams.method||"POST",i="";"get"==a&&(i=this.setUrlQuery({query:Object(n["a"])(Object(n["a"])({},this.queryParams),{},{pageNum:this.pageNum,pageSize:this.pageSize})}),i=i.replace(/undefined/g,"")),this.$http({url:this.otherParams.queryUrl||this.queryUrl+i,method:a,data:"POST"==a?e:{},params:"GET"==a?e:{}}).then((function(e){if(Array.isArray(e.data)){var a=e.data;t.tableData=a}else if(e.data){var n=e.data,i=n.rows,r=n.total,o=n.records,s=n.items;t.tableData=i||o||s||[],t.total=r||0}else{var c=e.rows,d=e.total,l=e.records,u=e.items;t.tableData=c||l||u||[],t.total=d||0}})).catch((function(e){t.$notification.error({message:"失败",description:e.msg})})).finally((function(){t.tableLoading=!1}))}},handleCurrentChange:function(t){this.loadData()},onPageShowSizeChange:function(t,e){Object.assign(this,{pageNum:t,pageSize:e}),this.loadData()},onSelectChange:function(t){this.selectedRowKeys=t},pcsChangeHandle:function(t,e){var a={},n=Object.assign({},this.queryParams);e||(delete n.provinceId,delete n.provinceName,delete n.cityId,delete n.cityName,delete n.strictId,delete n.strictName),e&&1===e.length&&(a.provinceId=e[0].code,a.provinceName=e[0].label,delete n.cityId,delete n.cityName,delete n.strictId,delete n.strictName),e&&2===e.length&&(a.cityId=e[1].code,a.cityName=e[1].label,delete n.strictId,delete n.strictName),e&&3===e.length&&(a.strictId=e[2].code,a.strictName=e[2].label),this.queryParams=Object.assign({},n,a)},rangDateChangeHandle:function(t,e){var a={},n=Object.assign({},this.queryParams);e&&e[0]&&(a.beginTime=e[0]),e&&e[1]&&(a.endTime=e[1]),"{}"===JSON.stringify(a)&&(delete n.beginTime,delete n.endTime),this.queryParams=Object.assign({},n,a)},handleDateQuickChange:function(t){t.startDate?(this.$set(this.queryParams,"rangDate",[r()(t.startDate),r()(t.endDate)]),this.queryParams.beginTime=t.startDate,this.queryParams.endTime=t.endDate):(delete this.queryParams.beginTime,delete this.queryParams.endTime,this.$set(this.queryParams,"rangDate",void 0))}}};e["a"]=o},b7a6:function(t,e,a){"use strict";a.d(e,"p",(function(){return s})),a.d(e,"c",(function(){return c})),a.d(e,"i",(function(){return d})),a.d(e,"o",(function(){return l})),a.d(e,"b",(function(){return u})),a.d(e,"h",(function(){return m})),a.d(e,"f",(function(){return p})),a.d(e,"u",(function(){return h})),a.d(e,"d",(function(){return f})),a.d(e,"v",(function(){return g})),a.d(e,"j",(function(){return b})),a.d(e,"a",(function(){return y})),a.d(e,"g",(function(){return v})),a.d(e,"r",(function(){return x})),a.d(e,"q",(function(){return O})),a.d(e,"w",(function(){return S})),a.d(e,"y",(function(){return q})),a.d(e,"e",(function(){return D})),a.d(e,"z",(function(){return w})),a.d(e,"A",(function(){return j})),a.d(e,"s",(function(){return k})),a.d(e,"x",(function(){return I})),a.d(e,"n",(function(){return P})),a.d(e,"t",(function(){return N})),a.d(e,"m",(function(){return C})),a.d(e,"k",(function(){return T})),a.d(e,"l",(function(){return _}));a("99af");var n=a("bc3a"),i=a.n(n),r=a("b775"),o=a("9fb0");function s(){return Object(r["b"])({url:"/api/sys-menu/list",method:"get"})}function c(t,e){return Object(r["b"])({url:"/api/sys-menu",method:e,data:t})}function d(t){var e=t.id;return Object(r["b"])({url:"/api/sys-menu/".concat(e),method:"delete"})}function l(t){return Object(r["b"])({url:"/api/dept/list",method:"post",data:t})}function u(t){return Object(r["b"])({url:"/api/dept/save",method:"post",data:t})}function m(t){var e=t.id;return Object(r["b"])({url:"/api/dept/".concat(e),method:"delete"})}function p(t){var e=t.userId;return Object(r["b"])({url:"/api/user/".concat(e),method:"delete"})}function h(t){return Object(r["b"])({url:"/api/sys/user/resetpwd",method:"post",data:t})}function f(t){return Object(r["b"])({url:"/api/role/save",method:"post",data:t})}function g(){return Object(r["b"])({url:"/api/sys-role/list",method:"get"})}function b(t){var e=t.roleIds;return Object(r["b"])({url:"/api/system/role/".concat(e),method:"delete"})}function y(t){return Object(r["b"])({url:"/api/sys/user/save",method:"post",data:t})}function v(t){var e=t.id;return Object(r["b"])({url:"/api/sys/user/".concat(e),method:"delete"})}function x(t){return Object(r["b"])({url:"/api/consumable/list?udi=".concat(t),method:"get"})}function O(t){return Object(r["b"])({url:"/api/sys-user/list?type=".concat(t),method:"get"})}function S(t){return Object(r["b"])({url:"/api/purchase",method:"post",data:t})}function q(t){return Object(r["b"])({url:"/api/qrcode/scan/".concat(t),method:"get"})}function D(t){return Object(r["b"])({url:"/api/qrcode/".concat(t),method:"get"})}function w(t){return Object(r["b"])({url:"/api/qrcode/usage",method:"post",data:t})}function j(t){return Object(r["b"])({url:"/api/qrcode/charge",method:"post",data:t})}function k(t){return Object(r["b"])({url:"/api/open/qrcode/query?patientIdCard=".concat(t.idCard,"&outpatientNo=").concat(t.outpatientNo),method:"get"})}function I(t){return Object(r["b"])({url:"/api/consumable",method:"post",data:t})}function P(){return Object(r["b"])({url:"/api/sys-dept/list?pid=1",method:"get"})}function N(t){return Object(r["b"])({url:"/api/purchase/batch/".concat(t),method:"get"})}function C(t){return i.a.post("/api/consumable/excel/import",t,{headers:{Authorization:sessionStorage.getItem(o["a"]),"Content-Type":"multipart/form-data"}})}function T(t){var e=t.billCode,a=t.entSendName;return Object(r["b"])({url:"/api/bill/query?billCode=".concat(e,"&entSendName=").concat(a),method:"get"})}function _(t){var e=t.code;return Object(r["b"])({url:"/api/bill/storage/".concat(e),method:"get"})}},ed18:function(t,e,a){"use strict";a.r(e);a("99af");var n=function(){var t=this,e=t._self._c;return e("a-card",{attrs:{border:!1}},[e("div",{staticClass:"table-page-search-wrapper"},[e("a-form",{attrs:{layout:"inline"}},[e("a-row",{attrs:{type:"flex",gutter:24}},[e("a-col",{staticStyle:{width:"280px"},attrs:{md:5,sm:24}},[e("a-form-item",{attrs:{label:"搜索"}},[e("a-input",{attrs:{placeholder:"输入关键词查询"},model:{value:t.queryParams.keyword,callback:function(e){t.$set(t.queryParams,"keyword",e)},expression:"queryParams.keyword"}})],1)],1),e("a-col",[e("span",{staticClass:"table-page-search-submitButtons"},[e("a-button",{attrs:{type:"primary",icon:"search"},on:{click:t.handleSubmit}},[t._v("查询")]),e("a-button",{staticStyle:{"margin-left":"8px"},attrs:{icon:"redo"},on:{click:t.handleReset}},[t._v("重置")])],1)])],1)],1)],1),e("a-table",{attrs:{columns:t.columns,"row-key":"id","data-source":t.tableData,loading:t.tableLoading,pagination:!1,scroll:{x:"max-content"}},scopedSlots:t._u([{key:"id",fn:function(a,n,i){return[e("span",[t._v(t._s(parseInt(i)+1))])]}},{key:"buyer",fn:function(a){return[e("span",[t._v(t._s(2==a?"医疗机构":"供应商"))])]}},{key:"isSplit",fn:function(a){return[e("span",[t._v(t._s(a?"是":"否"))])]}},{key:"operation",fn:function(a,n){return[n.outQuantity!=n.purchaseQuantity&&1!=n.buyer?e("a",{staticStyle:{color:"#1890ff"},on:{click:function(e){return t.handleShowModel("edit",n)}}},[t._v("一键入库")]):e("a",{staticStyle:{color:"#1890ff"},on:{click:function(e){return t.handleShowModel("",n)}}},[t._v("追溯码列表")])]}}])}),e("div",{staticStyle:{"text-align":"right","margin-top":"24px"}},[e("a-pagination",{attrs:{total:t.total,"show-size-changer":"","show-quick-jumper":"","show-total":function(e){return"共".concat(e,"条记录  第 ").concat(t.pageNum,"页")}},on:{change:t.handleCurrentChange,showSizeChange:t.onPageShowSizeChange},model:{value:t.pageNum,callback:function(e){t.pageNum=e},expression:"pageNum"}})],1),e("a-modal",{attrs:{title:"["+t.modelData.prodName+"] 追溯码列表",width:"900px",destroyOnClose:!0,maskClosable:!1,visible:t.modelVisible,"confirm-loading":t.modelConfirmLoading},on:{ok:t.handleModelOk,cancel:function(e){t.modelVisible=!1}}},[e("ypxxForm",{attrs:{modelData:t.modelData}}),e("div",{attrs:{slot:"footer"},slot:"footer"},[e("a-button",{on:{click:function(e){t.modelVisible=!1}}},[t._v("关闭")]),"edit"==t.modelType?e("a-button",{attrs:{type:"primary"},on:{click:t.addition}},[t._v("一键入库")]):t._e()],1)],1)],1)},i=[],r=(a("d3b7"),a("b018")),o=a("5305"),s=a("b7a6"),c=[{title:"序号",dataIndex:"consumableId",align:"center",width:70,ellipsis:!0,scopedSlots:{customRender:"id"}},{title:"单据编码",dataIndex:"billCode",align:"center",ellipsis:!0},{title:"发货企业名称",dataIndex:"entSendName",align:"center",ellipsis:!0},{title:"药品商品名",dataIndex:"prodName",align:"center",ellipsis:!0},{title:"制剂规格",dataIndex:"prepnSpec",align:"center",ellipsis:!0},{title:"批次号",dataIndex:"produceBatchNo",align:"center",ellipsis:!0},{title:"生产企业名称",dataIndex:"productEntName",align:"center",ellipsis:!0},{title:"生产日期",dataIndex:"produceDate",align:"center",ellipsis:!0},{title:"产品包装规格",dataIndex:"packageSpec",align:"center",ellipsis:!0},{title:"有效期至",dataIndex:"validEndDate",align:"center",ellipsis:!0},{title:"最小包装计量",dataIndex:"leastPkgAmount",align:"center",ellipsis:!0},{title:"最小制剂计量",dataIndex:"leastPrepnAmount",align:"center",ellipsis:!0},{title:"批准文号",dataIndex:"approvalNo",align:"center",ellipsis:!0},{title:"药品类型",dataIndex:"physicTypeName",align:"center",ellipsis:!0},{title:"制剂单位",dataIndex:"preparationsUnit",align:"center",ellipsis:!0},{title:"制剂规格",dataIndex:"prepnTypeDesc",align:"center",ellipsis:!0},{title:"包装单位",dataIndex:"pkgUnitDesc",align:"center",ellipsis:!0},{title:"操作",dataIndex:"operation",align:"center",fixed:"right",scopedSlots:{customRender:"operation"},width:140}],d={name:"ypxx",mixins:[r["a"]],components:{ypxxForm:o["default"]},data:function(){return{columns:c,queryUrl:"/api/drug-info/list",modelTitle:"查看二维码",modelData:{},modelVisible:!1,modelConfirmLoading:!1,modelType:"edit",queryParams:{keyword:""},otherParams:{method:"get"}}},created:function(){},methods:{addition:function(){var t=this;this.$confirm({title:"确认提示",content:"是否确认一键入库？",okText:"一键入库",okType:"primary",onOk:function(){return new Promise((function(){Object(s["t"])(t.modelData.id).then((function(e){t.$notification.success({message:"成功",description:"入库成功！"}),t.modelVisible=!1,t.loadData()})).cache((function(e){t.$notification.error({message:"失败",description:e.msg})}))})).catch((function(){}))}})},handleSubmit:function(){this.pageNum=1,this.loadData()},handleReset:function(){this.queryParams.keyword="",this.loadData()},handleModelOk:function(){var t=this;this.modelConfirmLoading=!0,this.$refs.editForm.onSubmit().then((function(e){t.loadData(),t.modelVisible=!1})).catch((function(t){})).finally((function(){t.modelConfirmLoading=!1}))},handleShowModel:function(t,e){var a={modelType:t,modelVisible:!0,modelData:{}};a.modelData=Object.assign({},e),Object.assign(this,a)}}},l=d,u=(a("3379"),a("2877")),m=Object(u["a"])(l,n,i,!1,null,"0c7ed230",null);e["default"]=m.exports}}]);