1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-6bc37c35"],{"09f4":function(t,e,r){"use strict";r.d(e,"a",(function(){return i})),Math.easeInOutQuad=function(t,e,r,o){return t/=o/2,t<1?r/2*t*t+e:(t--,-r/2*(t*(t-2)-1)+e)};var o=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(t){window.setTimeout(t,1e3/60)}}();function n(t){document.documentElement.scrollTop=t,document.body.parentNode.scrollTop=t,document.body.scrollTop=t}function a(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function i(t,e,r){var i=a(),s=t-i,c=20,u=0;e="undefined"===typeof e?500:e;var l=function t(){u+=c;var a=Math.easeInOutQuad(u,i,s,e);n(a),u<e?o(t):r&&"function"===typeof r&&r()};l()}},2543:function(t,e,r){"use strict";r.d(e,"q",(function(){return c})),r.d(e,"r",(function(){return u})),r.d(e,"u",(function(){return l})),r.d(e,"n",(function(){return d})),r.d(e,"o",(function(){return p})),r.d(e,"s",(function(){return m})),r.d(e,"p",(function(){return f})),r.d(e,"f",(function(){return g})),r.d(e,"g",(function(){return h})),r.d(e,"h",(function(){return b})),r.d(e,"m",(function(){return v})),r.d(e,"t",(function(){return y})),r.d(e,"k",(function(){return w})),r.d(e,"i",(function(){return O})),r.d(e,"j",(function(){return k})),r.d(e,"l",(function(){return j})),r.d(e,"d",(function(){return C})),r.d(e,"e",(function(){return x})),r.d(e,"c",(function(){return _})),r.d(e,"b",(function(){return S})),r.d(e,"a",(function(){return T}));var o=r("b775"),n=r("829b"),a=r("4328"),i=r.n(a),s="/api-web";function c(t){return Object(o["a"])({url:s+"/goods/queryPage",method:"get",params:t})}function u(t){return Object(o["a"])({url:s+"/goods/get/".concat(t),method:"get"})}function l(t){return Object(o["a"])({url:s+"/goods/updateGoodsStatus",method:"post",data:i.a.stringify(t)})}function d(t){return Object(o["a"])({url:s+"/goods/add",method:"post",data:t})}function p(t){return Object(o["a"])({url:s+"/goods/addBatch",method:"post",data:t})}function m(t){return Object(o["a"])({url:s+"/goods/update",method:"post",data:t})}function f(t){return Object(o["a"])({url:s+"/goods/del/".concat(t),method:"post"})}function g(t){return Object(o["a"])({url:s+"/category/queryPage",method:"get",params:t})}function h(t){return Object(o["a"])({url:s+"/category/upset",method:"post",data:t})}function b(t){return Object(o["a"])({url:s+"/category/del",method:"post",data:i.a.stringify(t)})}function v(t){return Object(o["a"])({url:s+"/subjectChange/queryPage",method:"get",params:t})}function y(t){return Object(o["a"])({url:s+"/subjectChange/updateCostMargin",method:"post",data:i.a.stringify(t)})}function w(t){return Object(o["a"])({url:s+"/goodsProcurement/queryGoodsProcurements",method:"get",params:t})}function O(t){return Object(o["a"])({url:s+"/goods/addGoodsProcurement",method:"post",params:t})}function k(t){return Object(o["a"])({url:s+"/swTempJc/queryPageForCourseSchedule",method:"get",params:t})}function j(t){return Object(o["a"])({url:s+"/swTempJc/queryPageForExtensionOrder",method:"get",params:t})}function C(t){return Object(n["a"])({url:s+"/goods/queryGoodsSubByPage",method:"GET",params:t,data:{}})}function x(t){return Object(n["a"])({url:s+"/goods/queryGoodsTypeList",method:"GET",params:t,data:{}})}function _(t){return Object(n["a"])({url:s+"/goods/queryGoodsCategoryList",method:"GET",params:t,data:{}})}function S(t){return Object(n["a"])({url:s+"/goods/queryGoodsBrandList",method:"GET",params:t,data:{}})}function T(t){return Object(n["a"])({url:s+"/goods/get/"+t.id,method:"GET",data:{}})}},"54ac":function(t,e,r){"use strict";r("8080")},8080:function(t,e,r){},"89f3":function(t,e,r){"use strict";r.r(e);var o=function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"m-container"},[r("h2",[r("el-page-header",{attrs:{content:"【"+t.goodsName+"】进货清单"},on:{back:t.onCancel}})],1),t._v(" "),r("div",{staticClass:"m-core"},[r("el-button",{directives:[{name:"permission",rawName:"v-permission",value:"goods/addGoodsProcurement",expression:"'goods/addGoodsProcurement'"}],attrs:{type:"primary"},on:{click:function(e){t.editVisible=!0}}},[t._v("新增")]),t._v(" "),r("save-form",{staticClass:"searchForm",staticStyle:{"margin-top":"20px"},attrs:{inline:"",model:t.searchForm},on:{submit:t.search,reset:t.onReSet}},[r("el-form-item",[r("el-input",{attrs:{clearable:"",placeholder:"备查货号"},model:{value:t.searchForm.search,callback:function(e){t.$set(t.searchForm,"search",e)},expression:"searchForm.search"}})],1),t._v(" "),r("el-form-item",[r("el-date-picker",{staticStyle:{width:"410px"},attrs:{type:"daterange","value-format":"yyyy-MM-dd","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期","picker-options":{firstDayOfWeek:1}},on:{change:t.searchOrderDate},model:{value:t.orderDate,callback:function(e){t.orderDate="string"===typeof e?e.trim():e},expression:"orderDate"}})],1),t._v(" "),r("el-form-item",[r("el-button",{attrs:{"native-type":"submit",type:"danger"}},[t._v("搜索")]),t._v(" "),r("el-button",{attrs:{"native-type":"reset",type:"primary"}},[t._v("重置")])],1)],1),t._v(" "),r("div",{staticClass:"tableWrap"},[r("el-table",{staticStyle:{width:"100%"},attrs:{data:t.tableList,"header-cell-style":{background:"#EDEEF0",color:"#444"}}},[r("el-table-column",{attrs:{align:"center",width:"180",prop:"batchNo",label:"批次号"}}),t._v(" "),r("el-table-column",{attrs:{align:"center",width:"150",prop:"supplyChannel",label:"备查货号"}}),t._v(" "),r("el-table-column",{attrs:{align:"center",width:"150",prop:"stockCount",label:"内部库存"}}),t._v(" "),r("el-table-column",{attrs:{align:"center",width:"150",prop:"stockSoldNum",label:"内部售出数量"}}),t._v(" "),r("el-table-column",{attrs:{align:"center",width:"150",prop:"taxStockCount",label:"税务库存"}}),t._v(" "),r("el-table-column",{attrs:{align:"center",width:"150",prop:"taxStockSoldNum",label:"税务售出数量"}}),t._v(" "),r("el-table-column",{attrs:{align:"center",width:"150",prop:"discountPrice",label:"商品采购价1"}}),t._v(" "),r("el-table-column",{attrs:{align:"center",width:"150",prop:"agreeCostPrice",label:"商品采购价2"}}),t._v(" "),r("el-table-column",{attrs:{align:"center",prop:"createTime",label:"入库日期"}})],1),t._v(" "),r("pagination",{attrs:{sync:"",total:t.pageInfo.total,page:t.pageInfo.page,limit:t.pageInfo.limit,"page-sizes":t.pageInfo.page_size},on:{"update:total":function(e){return t.$set(t.pageInfo,"total",e)},"update:page":function(e){return t.$set(t.pageInfo,"page",e)},"update:limit":function(e){return t.$set(t.pageInfo,"limit",e)},pagination:t.getList}})],1)],1),t._v(" "),t.editVisible?r("el-dialog",{attrs:{title:"新增进货清单",width:"500px",visible:t.editVisible},on:{"update:visible":function(e){t.editVisible=e},close:function(e){t.editVisible=!1}}},[r("purchaseForm",{attrs:{goodsId:t.goodsId},on:{submited:t.getList,close:t.closeEdit}})],1):t._e()],1)},n=[],a=r("5530"),i=(r("7f7f"),r("333d")),s=r("5a0c"),c=r.n(s),u=function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",[r("el-form",{ref:"form",attrs:{model:t.form,rules:t.rules}},[r("el-form-item",{attrs:{label:"备查货号",prop:"supplyChannel","label-width":"100px"}},[r("el-input",{attrs:{placeholder:"请输入备查货号"},model:{value:t.form.supplyChannel,callback:function(e){t.$set(t.form,"supplyChannel",e)},expression:"form.supplyChannel"}})],1),t._v(" "),r("el-form-item",{attrs:{label:"内部库存",prop:"stockCount","label-width":"100px"}},[r("el-input",{attrs:{type:"number",placeholder:"请输入内部库存"},model:{value:t.form.stockCount,callback:function(e){t.$set(t.form,"stockCount",e)},expression:"form.stockCount"}})],1),t._v(" "),r("el-form-item",{attrs:{label:"税务库存",prop:"taxStockCount","label-width":"100px"}},[r("el-input",{attrs:{type:"number",placeholder:"请输入税务库存"},model:{value:t.form.taxStockCount,callback:function(e){t.$set(t.form,"taxStockCount",e)},expression:"form.taxStockCount"}})],1),t._v(" "),r("el-form-item",{attrs:{label:"商品采购价1",prop:"discountPrice","label-width":"100px"}},[r("el-input",{attrs:{type:"number",placeholder:"请输入商品采购价1"},model:{value:t.form.discountPrice,callback:function(e){t.$set(t.form,"discountPrice",e)},expression:"form.discountPrice"}})],1),t._v(" "),r("el-form-item",{attrs:{label:"商品采购价2",prop:"agreeCostPrice","label-width":"100px"}},[r("el-input",{attrs:{type:"number",placeholder:"请输入商品采购价2"},model:{value:t.form.agreeCostPrice,callback:function(e){t.$set(t.form,"agreeCostPrice",e)},expression:"form.agreeCostPrice"}})],1)],1),t._v(" "),r("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[r("el-button",{on:{click:t.$listeners.close}},[t._v("取消")]),t._v(" "),r("el-button",{attrs:{type:"primary"},on:{click:t.submit}},[t._v("确认")])],1)],1)},l=[],d=r("c7eb"),p=(r("96cf"),r("1da1")),m=r("2543"),f={props:["goodsId"],data:function(){return{form:{supplyChannel:"",stockCount:"",taxStockCount:"",discountPrice:"",agreeCostPrice:""},rules:{supplyChannel:[{required:!0,message:"请输入备查货号",trigger:"blur"}],stockCount:[{required:!0,message:"请输入内部库存",trigger:"blur"}],taxStockCount:[{required:!0,message:"请输入税务库存",trigger:"blur"}],discountPrice:[{required:!0,message:"请输入商品采购价1",trigger:"blur"}],agreeCostPrice:[{required:!1,message:"请输入商品采购价2",trigger:"blur"}]}}},methods:{submit:function(){var t=Object(p["a"])(Object(d["a"])().mark((function t(){var e=this;return Object(d["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:this.$refs.form.validate(function(){var t=Object(p["a"])(Object(d["a"])().mark((function t(r){return Object(d["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(!r){t.next=13;break}return t.prev=1,t.next=4,e.$confirm("是否确认提交","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"});case 4:return t.next=6,Object(m["i"])(Object(a["a"])({goodsId:e.goodsId},e.form));case 6:e.$message.success("添加成功"),e.$listeners.submited(),e.$listeners.close(),t.next=13;break;case 11:t.prev=11,t.t0=t["catch"](1);case 13:case"end":return t.stop()}}),t,null,[[1,11]])})));return function(e){return t.apply(this,arguments)}}());case 1:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}()}},g=f,h=(r("54ac"),r("2877")),b=Object(h["a"])(g,u,l,!1,null,"4a04c9c5",null),v=b.exports,y={enterStorageStartTime:null,enterStorageEndTime:null,search:""},w={components:{purchaseForm:v,pagination:i["a"]},data:function(){var t=this.$route.query;return{goodsName:t.name,goodsId:t.goodsId,tableList:[],detail:null,editVisible:!1,searchForm:Object(a["a"])({},y),pageInfo:{limit:10,page:1,total:0,page_size:[10,20,40,50]},orderDate:[]}},mounted:function(){this.init()},methods:{init:function(){this.getNow();var t=this.$route.query;this.goodsId=t.goodsId,this.goodsName=t.name,this.getList()},getNow:function(){var t=this.searchForm;t.enterStorageStartTime?this.orderDate=[t.enterStorageStartTime,t.enterStorageEndTime]:(this.orderDate=[c()().format("YYYY-MM-DD"),c()().format("YYYY-MM-DD")],t.enterStorageStartTime=this.orderDate[0],t.enterStorageEndTime=this.orderDate[1])},searchOrderDate:function(t){this.searchForm.enterStorageStartTime=t?t[0]:"",this.searchForm.enterStorageEndTime=t?t[1]:""},getList:function(){var t=this,e=Object(a["a"])(Object(a["a"])({},this.searchForm),{},{goodsId:this.goodsId});Object(m["k"])(Object(a["a"])({rows:this.pageInfo.limit,page:this.pageInfo.page},e)).then((function(e){200==e.code&&e.data&&(t.tableList=e.data.rows,t.pageInfo.total=e.data.total)}))},onCancel:function(){this.$store.dispatch("delVisitedViews",this.$route),this.$router.push({path:"/shopList"})},onReSet:function(){this.orderDate=[],this.searchForm=Object(a["a"])({},y),this.getNow(),this.getList()},edit:function(t){this.editVisible=!0,this.detail=t},closeEdit:function(){this.editVisible=!1,this.detail=null},search:function(){this.getList()}}},O=w,k=Object(h["a"])(O,o,n,!1,null,"55afa6f0",null);e["default"]=k.exports}}]);
|