马宇豪
2022-12-12 c63545c5e3f297a5b9545f0cb2afeaa843ce52cb
1
(this.webpackJsonp=this.webpackJsonp||[]).push([["chunk-8cc0"],{"1Dvt":function(t,e,r){"use strict";r.d(e,"r",function(){return n}),r.d(e,"d",function(){return o}),r.d(e,"c",function(){return c}),r.d(e,"q",function(){return u}),r.d(e,"k",function(){return s}),r.d(e,"l",function(){return d}),r.d(e,"g",function(){return l}),r.d(e,"i",function(){return h}),r.d(e,"f",function(){return p}),r.d(e,"h",function(){return m}),r.d(e,"e",function(){return b}),r.d(e,"p",function(){return f}),r.d(e,"a",function(){return g}),r.d(e,"b",function(){return y}),r.d(e,"j",function(){return v}),r.d(e,"o",function(){return j}),r.d(e,"m",function(){return O}),r.d(e,"n",function(){return k});var a=r("X4fA"),i=r("t3Un");function n(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/stock/info",method:"get",params:t||{}})}function o(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/stock/enterpriseStaticStock",method:"get",params:t||{}})}function c(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/stock/enterpriseSale",method:"get",params:t||{}})}function u(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/stock/saleInfo",method:"get",params:t||{}})}function s(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/stock/detail",method:"get",params:t||{}})}function d(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/enterprise-type-delivery",method:"post",data:t})}function l(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/export/enterprise-type-delivery",method:"post",data:t})}function h(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/city-type-delivery",method:"post",data:t})}function p(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/export/city-type-delivery",method:"post",data:t})}function m(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/city-type-entry",method:"post",data:t})}function b(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/export/city-type-entry",method:"post",data:t})}function f(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/stock/refreshStock",method:"post",data:t})}function g(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/stock/clearStock",method:"post",data:t})}function y(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/stock/clearStockByItem",method:"post",data:t})}function v(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/city-stock",method:"post",data:t})}function j(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/stock/history",method:"post",data:t})}function O(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/export/stock/history",method:"post",data:t})}function k(t){return Object(i.a)({headers:{Authorization:Object(a.a)()},url:"http://39.104.85.193:4105/statistics/history/city-stock",method:"post",data:t})}},"3qdr":function(t,e,r){},X4DX:function(t,e,r){"use strict";var a=r("3qdr");r.n(a).a},cOQF:function(t,e,r){"use strict";r.r(e);var a=r("bS4n"),i=r.n(a),n=r("1Dvt"),o=r("8t5x"),c=r("7Qib"),u=r("8fCU"),s={name:"stockDetail",data:function(){return{itemCode:"",enterpriseNumber:"",detailDialogVisible:!1,detailForm:{},detailData:[],listLoading:!0,pageSize:10,recordTotal:0,currentPage:1,pageTotal:0,tableKey:0,status:[{id:0,name:"已停用"},{id:1,name:"已启用"}],queryForm:{directionCode:""}}},computed:i()({},Object(o.b)(["userType","username"])),methods:{open:function(t,e){this.enterpriseNumber=e,this.itemCode=t,this.detailDialogVisible=!0,this.queryForm={directionCode:""},this.getDetailDataList()},queryHandle:function(){this.currentPage=1,this.getDetailDataList()},getDetailDataList:function(){var t={},e=this;for(var r in t.itemCode=e.itemCode,t.enterpriseNumber=e.enterpriseNumber,t.pageIndex=e.currentPage,t.pageSize=e.pageSize,t.sort=e.sort,t.order=e.order,e.queryForm)void 0!=e.queryForm[r]&&""!==e.queryForm[r].toString()&&(t[r]=e.queryForm[r]);Object(n.k)(t).then(function(t){var r=t.data;if("200"===r.code){var a=r.result;e.recordTotal=a.totalCount,e.pageSize=a.pageSize,e.pageTotal=Object(c.a)(a.totalCount,a.pageSize),e.currentPage=a.pageIndex,e.detailData=a.result}else Object(u.a)({error:r.message,vm:e});e.listLoading=!1}).catch(function(t){e.listLoading=!1,Object(u.a)({error:t,vm:e})})},handleSizeChange:function(t){this.pageSize=t,this.currentPage=1,this.getDetailDataList()},handleCurrentChange:function(t){this.currentPage=t,this.getDetailDataList()},sortChange:function(t){this.sort=t.prop,this.order=t.order,this.getDetailDataList()},exportAllHandle:function(){var t=this,e={};for(var a in e.itemCode=t.itemCode,e.enterpriseNumber=t.enterpriseNumber,e.pageIndex=1,e.pageSize=1e5,e.sort=t.sort,e.order=t.order,t.queryForm)void 0!=t.queryForm[a]&&""!==t.queryForm[a].toString()&&(e[a]=t.queryForm[a]);Object(n.k)(e).then(function(e){var a=e.data;if("200"===a.code){var i=a.result.result;if(0==i.length)return void Object(u.a)({error:"当前没有数据",vm:t});Promise.all([r.e("chunk-1560"),r.e("chunk-7a50")]).then(r.bind(null,"S/jZ")).then(function(e){var r=t.formatJson(["name","directioncode","createddate","modifieddate","modifiedby"],i);e.export_json_to_excel({header:["产品名称","流向码","创建时间","最近修改时间","最近修改人"],data:r,filename:"stockDetails"})})}else Object(u.a)({error:a.message,vm:t})}).catch(function(e){Object(u.a)({error:e,vm:t})})},formatJson:function(t,e){return e.map(function(e){return t.map(function(t){return"createddate"===t?Object(c.f)(e[t],"{y}-{m}-{d}"):e[t]})})}}},d=(r("X4DX"),r("ZrdR")),l=Object(d.a)(s,function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("el-dialog",{attrs:{visible:t.detailDialogVisible,"modal-append-to-body":!1,"close-on-click-modal":!1,width:"900px"},on:{"update:visible":function(e){t.detailDialogVisible=e}}},[r("div",{staticStyle:{"padding-bottom":"20px"}},[t._v("\n        流向码:\n        "),r("el-input",{staticClass:"filter-item",staticStyle:{width:"20%","padding-right":"15px"},attrs:{placeholder:"流向码"},nativeOn:{keyup:function(e){return"button"in e||!t._k(e.keyCode,"enter",13,e.key,"Enter")?t.queryHandle(e):null}},model:{value:t.queryForm.directionCode,callback:function(e){t.$set(t.queryForm,"directionCode",e)},expression:"queryForm.directionCode"}}),t._v(" "),r("el-button",{staticClass:"filter-item",staticStyle:{"margin-left":"10px"},attrs:{type:"primary",icon:"el-icon-search"},on:{click:t.queryHandle}}),t._v(" "),r("el-button",{attrs:{type:"primary",plain:""},on:{click:t.exportAllHandle}},[t._v("导出商品详情")])],1),t._v(" "),r("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],key:t.tableKey,staticStyle:{width:"100%"},attrs:{data:t.detailData,border:"",fit:"","highlight-current-row":""}},[r("el-table-column",{attrs:{type:"index",label:"",align:"center",width:"60"}}),t._v(" "),r("el-table-column",{attrs:{label:"产品名称",prop:"name",align:"center"}}),t._v(" "),r("el-table-column",{attrs:{label:"流向码",prop:"directioncode",align:"center"}}),t._v(" "),r("el-table-column",{attrs:{label:"创建时间",prop:"createddate",align:"center"}}),t._v(" "),r("el-table-column",{attrs:{label:"最近修改时间",prop:"modifieddate",align:"center"}}),t._v(" "),r("el-table-column",{attrs:{label:"最近修改人",prop:"modifiedby",align:"center"}})],1),t._v(" "),r("br"),t._v(" "),r("el-pagination",{directives:[{name:"show",rawName:"v-show",value:t.recordTotal>0,expression:"recordTotal>0"}],staticStyle:{float:"right"},attrs:{"current-page":t.currentPage,"page-sizes":[10,20,30,50],"page-size":t.pageSize,total:t.recordTotal,layout:"total, sizes, prev, pager, next, jumper",background:""},on:{"size-change":t.handleSizeChange,"current-change":t.handleCurrentChange}})],1)},[],!1,null,"c794207a",null);l.options.__file="stockDetail.vue";e.default=l.exports}}]);