| 1 |
- {"code":"/*!\n * build: vue-admin-beautiful \n * copyright: chuzhixin 1204505056@qq.com \n * time: 2022-12-12 09:51:32\n */\n(window[\"webpackJsonp\"]=window[\"webpackJsonp\"]||[]).push([[\"chunk-28726557\"],{\"01aa\":function(t,e,a){\"use strict\";a(\"8f9e\")},\"0d36\":function(t,e,a){\"use strict\";a(\"b09a\")},1244:function(t,e,a){\"use strict\";a.r(e),a.d(e,\"getAllPurchaseByFields\",(function(){return n})),a.d(e,\"exportgetAllPurchaseByFields\",(function(){return r})),a.d(e,\"addSupplier\",(function(){return s})),a.d(e,\"getSupplierInfoById\",(function(){return c})),a.d(e,\"editSupplier\",(function(){return u})),a.d(e,\"supplierEnableStatus\",(function(){return i})),a.d(e,\"delSupplier\",(function(){return l})),a.d(e,\"getAllSupplier\",(function(){return d})),a.d(e,\"retMoney\",(function(){return h})),a.d(e,\"reStockIn\",(function(){return p})),a.d(e,\"addPurchase\",(function(){return f})),a.d(e,\"getPurchaseInfoById\",(function(){return m})),a.d(e,\"updatePurchaseStatus\",(function(){return g})),a.d(e,\"delPurchase\",(function(){return b})),a.d(e,\"getAllPurchase\",(function(){return _})),a.d(e,\"exportGetAllPurchase\",(function(){return k})),a.d(e,\"editPurchase\",(function(){return S})),a.d(e,\"getAllPurchaseDetails\",(function(){return y})),a.d(e,\"exportGetAllPurchaseDetails\",(function(){return I})),a.d(e,\"searchAllPurchaseDetails\",(function(){return v})),a.d(e,\"exportSearchAllPurchaseDetails\",(function(){return O})),a.d(e,\"addPurchaseOut\",(function(){return P})),a.d(e,\"getPurchaseOutInfoById\",(function(){return A})),a.d(e,\"updatePurchaseOut\",(function(){return w})),a.d(e,\"delPurchaseOut\",(function(){return j})),a.d(e,\"getAllPurchaseOut\",(function(){return N})),a.d(e,\"exportGetAllPurchaseOut\",(function(){return M})),a.d(e,\"editPurchaseOut\",(function(){return C})),a.d(e,\"getAllData\",(function(){return x})),a.d(e,\"getAllPurchaseAndDetails\",(function(){return D})),a.d(e,\"getPurchaseAndBatchInfoById\",(function(){return $})),a.d(e,\"addSupplierUserCenter\",(function(){return G})),a.d(e,\"supplierImport\",(function(){return L}));var o=a(\"b775\");function n(t){return Object(o[\"default\"])({url:\"/purchase/purchase/getAllPurchaseByFields\",method:\"post\",data:t})}function r(t){return Object(o[\"default\"])({url:\"/purchase/purchase/getAllPurchaseByFields\",method:\"post\",responseType:\"blob\",data:t})}function s(t){return Object(o[\"default\"])({url:\"/Purchase/Supplier/addSupplier\",method:\"post\",data:t})}function c(t,e){return Object(o[\"default\"])({url:\"/Purchase/Supplier/getSupplierInfoById/\"+t,method:\"get\",data:e})}function u(t,e){return Object(o[\"default\"])({url:\"/Purchase/Supplier/editSupplier/\"+t,method:\"put\",data:e})}function i(t,e){return Object(o[\"default\"])({url:\"/Purchase/Supplier/updateEnableStatus/\"+t,method:\"put\",data:e})}function l(t,e){return Object(o[\"default\"])({url:\"/Purchase/Supplier/delSupplier/\"+t,method:\"delete\",data:e})}function d(t){return Object(o[\"default\"])({url:\"/Purchase/Supplier/getAllSupplier\",method:\"post\",data:t})}function h(t,e){return Object(o[\"default\"])({url:\"/Purchase/Purchase/retMoney/\"+t,method:\"post\",data:e})}function p(t,e){return Object(o[\"default\"])({url:\"/Purchase/Purchase/reStockIn/\"+t,method:\"post\",data:e})}function f(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/addPurchase\",method:\"post\",data:t})}function m(t,e){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getPurchaseInfoById/\"+t,method:\"get\",data:e})}function g(t,e){return Object(o[\"default\"])({url:\"/Purchase/Purchase/updateAuditStatus/\"+t,method:\"put\",data:e})}function b(t,e){return Object(o[\"default\"])({url:\"/Purchase/Purchase/delPurchase/\"+t,method:\"delete\",data:e})}function _(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getAllPurchase\",method:\"post\",data:t})}function k(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getAllPurchase\",responseType:\"blob\",method:\"post\",data:t})}function S(t,e){return Object(o[\"default\"])({url:\"/Purchase/Purchase/editPurchase/\"+t,method:\"put\",data:e})}function y(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getAllPurchaseDetails\",method:\"post\",data:t})}function I(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getAllPurchaseDetails\",responseType:\"blob\",method:\"post\",data:t})}function v(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/searchAllPurchaseDetails\",method:\"post\",data:t})}function O(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/searchAllPurchaseDetails\",method:\"post\",responseType:\"blob\",data:t})}function P(t){return Object(o[\"default\"])({url:\"/Purchase/PurchaseOut/addPurchaseOut\",method:\"post\",data:t})}function A(t,e){return Object(o[\"default\"])({url:\"/Purchase/PurchaseOut/getPurchaseOutInfoById/\"+t,method:\"get\",data:e})}function w(t,e){return Object(o[\"default\"])({url:\"/Purchase/PurchaseOut/updateAuditStatus/\"+t,method:\"put\",data:e})}function j(t,e){return Object(o[\"default\"])({url:\"/Purchase/PurchaseOut/delPurchaseOut/\"+t,method:\"delete\",data:e})}function N(t){return Object(o[\"default\"])({url:\"/Purchase/PurchaseOut/getAllPurchaseOut\",method:\"post\",data:t})}function M(t){return Object(o[\"default\"])({url:\"/Purchase/PurchaseOut/getAllPurchaseOut\",responseType:\"blob\",method:\"post\",data:t})}function C(t,e){return Object(o[\"default\"])({url:\"/Purchase/PurchaseOut/editPurchase/\"+t,method:\"put\",data:e})}function x(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getAllData\",method:\"get\",data:t})}function D(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getAllPurchaseAndDetails\",method:\"post\",data:t})}function $(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getPurchaseAndBatchInfoById\",method:\"post\",data:t})}function G(t,e){return Object(o[\"default\"])({url:\"Purchase/Supplier/addSupplierUserCenter/\"+t,method:\"get\",data:e})}function L(t){return Object(o[\"default\"])({url:\"Purchase/Supplier/supplierImport\",method:\"post\",data:t})}},\"1ccb\":function(t,e,a){\"use strict\";a(\"8d2f\")},\"301b\":function(t,e,a){},\"478b\":function(t,e,a){\"use strict\";a.r(e),a.d(e,\"getWarehouseInfo\",(function(){return n})),a.d(e,\"getAllWarehouse\",(function(){return r})),a.d(e,\"enableWarehouse\",(function(){return s})),a.d(e,\"updateWarehouse\",(function(){return c})),a.d(e,\"deleteWarehouse\",(function(){return u})),a.d(e,\"addWarehouse\",(function(){return i})),a.d(e,\"addWarehouseBeginning\",(function(){return l})),a.d(e,\"stockaddLogistics\",(function(){return d})),a.d(e,\"getAllSaleOut\",(function(){return h})),a.d(e,\"exportGetAllSaleOut\",(function(){return p})),a.d(e,\"getSaleOutInfo\",(function(){return f})),a.d(e,\"getSaleOutInfoT\",(function(){return m})),a.d(e,\"searchAllSaleOut\",(function(){return g})),a.d(e,\"updateSaleOutStatus\",(function(){return b})),a.d(e,\"saveOutInventory\",(function(){return _})),a.d(e,\"statisticsAllSaleOut\",(function(){return k})),a.d(e,\"rejectInventory\",(function(){return S})),a.d(e,\"deleteDetailByInventoryInId\",(function(){return y})),a.d(e,\"searchAllPurchaseIn\",(function(){return I})),a.d(e,\"getPurchaseInInfo\",(function(){return v})),a.d(e,\"getPurchaseInInfoT\",(function(){return O})),a.d(e,\"getAllPurchaseIn\",(function(){return P})),a.d(e,\"exportsGetAllPurchaseIn\",(function(){return A})),a.d(e,\"updatePurchaseInStatus\",(function(){return w})),a.d(e,\"statisticsAllPurchaseIn\",(function(){return j})),a.d(e,\"getInventoryAll\",(function(){return N})),a.d(e,\"exportGetInventoryAll\",(function(){return M})),a.d(e,\"getInventoryDetailsAll\",(function(){return C})),a.d(e,\"exportGetInventoryDetailsAll\",(function(){return x})),a.d(e,\"searchAllInventoryDetails\",(function(){return D})),a.d(e,\"exportSearchAllInventoryDetails\",(function(){return $})),a.d(e,\"getAllBatch\",(function(){return G})),a.d(e,\"searchAllInventoryBatch\",(function(){return L})),a.d(e,\"getStocktakingInfo\",(function(){return B})),a.d(e,\"updateStocktaking\",(function(){return R})),a.d(e,\"auditStocktaking\",(function(){return T})),a.d(e,\"getAllStocktaking\",(function(){return W})),a.d(e,\"exportGetAllStocktaking\",(function(){return z})),a.d(e,\"searchAllStocktaking\",(function(){return E})),a.d(e,\"exportSearchAllStocktaking\",(function(){return U})),a.d(e,\"addStocktaking\",(function(){return F})),a.d(e,\"inventoryStatistics\",(function(){return q})),a.d(e,\"exportsInventoryStatistics\",(function(){return V})),a.d(e,\"searchInventoryStatistics\",(function(){return J})),a.d(e,\"StockGetAllPurchase\",(function(){return H})),a.d(e,\"PurchaseInGetAllPurchaseOut\",(function(){return K})),a.d(e,\"getWarehouseInventory\",(function(){return Q})),a.d(e,\"addAllocate\",(function(){return X})),a.d(e,\"getInventoryByWarehouseId\",(function(){return Y})),a.d(e,\"getAllAllocate\",(function(){return Z})),a.d(e,\"deleteAllocate\",(function(){return tt})),a.d(e,\"getAllocateInfo\",(function(){return et})),a.d(e,\"updateAllocate\",(function(){return at})),a.d(e,\"auditAllocate\",(function(){return ot})),a.d(e,\"searchAllocate\",(function(){return nt})),a.d(e,\"getBatchByIds\",(function(){return rt})),a.d(e,\"getSkuNum\",(function(){return st})),a.d(e,\"getMasterSkuNum\",(function(){return ct})),a.d(e,\"addReservoir\",(function(){return ut})),a.d(e,\"getReservoirInfo\",(function(){return it})),a.d(e,\"getAllReservoir\",(function(){return lt})),a.d(e,\"getListReservoir\",(function(){return dt})),a.d(e,\"enableReservoir\",(function(){return ht})),a.d(e,\"updateReservoir\",(function(){return pt})),a.d(e,\"deleteReservoir\",(function(){return ft})),a.d(e,\"getAllStorageLocation\",(function(){return mt})),a.d(e,\"addStorageLocation\",(function(){return gt})),a.d(e,\"getStorageLocationInfo\",(function(){return bt})),a.d(e,\"enableStorageLocation\",(function(){return _t})),a.d(e,\"updateStorageLocation\",(function(){return kt})),a.d(e,\"getAreaDateBySkuId\",(function(){return St})),a.d(e,\"addReportLoss\",(function(){return yt})),a.d(e,\"getAllReportLoss\",(function(){return It})),a.d(e,\"getReportLossInfo\",(function(){return vt})),a.d(e,\"auditReportLoss\",(function(){return Ot})),a.d(e,\"deleteReportLoss\",(function(){return Pt})),a.d(e,\"countPurchaseCost\",(function(){return At})),a.d(e,\"exportgetInventoryByWarehouseId\",(function(){return wt})),a.d(e,\"exportgetAllAllocate\",(function(){return jt})),a.d(e,\"getPickingInfo\",(function(){return Nt})),a.d(e,\"addPicking\",(function(){return Mt})),a.d(e,\"getAllPicking\",(function(){return Ct})),a.d(e,\"getAllPickingGoodsDetail\",(function(){return xt}));var o=a(\"b775\");function n(t,e){return Object(o[\"default\"])({url:\"/Stock/Warehouse/getWarehouseInfo/\"+t,method:\"get\",data:e})}function r(t){return Object(o[\"default\"])({url:\"/Stock/Warehouse/getAllWarehouse\",method:\"post\",data:t})}function s(t){return Object(o[\"default\"])({url:\"/Stock/Warehouse/enableWarehouse\",method:\"post\",data:t})}function c(t,e){return Object(o[\"default\"])({url:\"/Stock/Warehouse/updateWarehouse/\"+t,method:\"put\",data:e})}function u(t,e){return Object(o[\"default\"])({url:\"/Stock/Warehouse/deleteWarehouse/\"+t,method:\"delete\",data:e})}function i(t){return Object(o[\"default\"])({url:\"/Stock/Warehouse/addWarehouse\",method:\"post\",data:t})}function l(t){return Object(o[\"default\"])({url:\"/Stock/Warehouse/addWarehouseBeginning\",method:\"post\",data:t})}function d(t){return Object(o[\"default\"])({url:\"/Stock/InventoryOut/addLogistics\",method:\"post\",data:t})}function h(t){return Object(o[\"default\"])({url:\"/Stock/InventoryOut/getAllInventoryOut\",method:\"post\",data:t})}function p(t){return Object(o[\"default\"])({url:\"/Stock/InventoryOut/getAllInventoryOut\",method:\"post\",responseType:\"blob\",data:t})}function f(t,e){return Object(o[\"default\"])({url:\"/Stock/InventoryOut/getInventoryOutInfo/\"+t,method:\"get\",data:e})}function m(t){return Object(o[\"default\"])({url:\"/Stock/InventoryOut/getInventoryOutInfo\",method:\"post\",data:t})}function g(t){return Object(o[\"default\"])({url:\"/Stock/InventoryOut/searchAllInventoryOut\",method:\"post\",data:t})}function b(t){return Object(o[\"default\"])({url:\"/Stock/InventoryOut/updateInventoryOutStatus\",method:\"post\",data:t})}function _(t,e){return Object(o[\"default\"])({url:\"/Stock/InventoryOut/saveOutInventory/\"+t,method:\"put\",data:e})}function k(t){return Object(o[\"default\"])({url:\"/Stock/InventoryOut/statisticsAllInventoryOut\",method:\"post\",data:t})}function S(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/rejectInventory\",method:\"post\",data:t})}function y(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/deleteDetailByInventoryInId\",method:\"post\",data:t})}function I(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/searchAllInventoryIn\",method:\"post\",data:t})}function v(t,e){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/getInventoryInInfo/\"+t,method:\"put\",data:e})}function O(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/getInventoryInInfo\",method:\"put\",data:t})}function P(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/getAllInventoryIn\",method:\"post\",data:t})}function A(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/getAllInventoryIn\",method:\"post\",responseType:\"blob\",data:t})}function w(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/updateInventoryInStatus\",method:\"post\",data:t})}function j(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/statisticsAllInventoryIn\",method:\"post\",data:t})}function N(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/getInventoryAll\",method:\"post\",data:t})}function M(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/getInventoryAll\",responseType:\"blob\",method:\"post\",data:t})}function C(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/getInventoryDetailsAll\",method:\"post\",data:t})}function x(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/getInventoryDetailsAll\",responseType:\"blob\",method:\"post\",data:t})}function D(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/searchAllInventoryDetails\",method:\"post\",data:t})}function $(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/searchAllInventoryDetails\",responseType:\"blob\",method:\"post\",data:t})}function G(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/getAllBatch\",method:\"post\",data:t})}function L(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/searchAllInventoryBatch\",method:\"post\",data:t})}function B(t,e){return Object(o[\"default\"])({url:\"/Stock/Stocktaking/getStocktakingInfo/\"+t,method:\"get\",data:e})}function R(t,e){return Object(o[\"default\"])({url:\"/Stock/Stocktaking/updateStocktaking/\"+t,method:\"put\",data:e})}function T(t,e){return Object(o[\"default\"])({url:\"/Stock/Stocktaking/auditStocktaking/\"+t,method:\"put\",data:e})}function W(t){return Object(o[\"default\"])({url:\"/Stock/Stocktaking/getAllStocktaking\",method:\"post\",data:t})}function z(t){return Object(o[\"default\"])({url:\"/Stock/Stocktaking/getAllStocktaking\",responseType:\"blob\",method:\"post\",data:t})}function E(t){return Object(o[\"default\"])({url:\"/Stock/Stocktaking/searchAllStocktaking\",method:\"post\",data:t})}function U(t){return Object(o[\"default\"])({url:\"/Stock/Stocktaking/searchAllStocktaking\",method:\"post\",responseType:\"blob\",data:t})}function F(t){return Object(o[\"default\"])({url:\"/Stock/Stocktaking/addStocktaking\",method:\"post\",data:t})}function q(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/inventoryStatistics\",method:\"post\",data:t})}function V(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/inventoryStatistics\",method:\"post\",responseType:\"blob\",data:t})}function J(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/searchInventoryStatistics\",method:\"post\",data:t})}function H(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/getAllPurchaseIn\",method:\"post\",data:t})}function K(t){return Object(o[\"default\"])({url:\"/Stock/InventoryIn/getAllInventoryInByAudit\",method:\"post\",data:t})}function Q(t,e){return Object(o[\"default\"])({url:\"/Stock/Inventory/getWarehouseInventory/\"+t,method:\"get\",data:e})}function X(t){return Object(o[\"default\"])({url:\"/Stock/Allocate/addAllocate\",method:\"post\",data:t})}function Y(t){return Object(o[\"default\"])({url:\"/stock/Inventory/getInventoryByWarehouseId\",method:\"post\",data:t})}function Z(t){return Object(o[\"default\"])({url:\"/Stock/Allocate/getAllAllocate\",method:\"post\",data:t})}function tt(t,e){return Object(o[\"default\"])({url:\"/Stock/Allocate/deleteAllocate/\"+t,method:\"delete\",data:e})}function et(t,e){return Object(o[\"default\"])({url:\"/Stock/Allocate/getAllocateInfo/\"+t,method:\"get\",data:e})}function at(t,e){return Object(o[\"default\"])({url:\"/Stock/Allocate/updateAllocate/\"+t,method:\"post\",data:e})}function ot(t,e){return Object(o[\"default\"])({url:\"/Stock/Allocate/auditAllocate/\"+t,method:\"put\",data:e})}function nt(t){return Object(o[\"default\"])({url:\"/Stock/Allocate/searchAllocate\",method:\"post\",data:t})}function rt(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/getBatchByIds\",method:\"post\",data:t})}function st(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/getSkuNum\",method:\"post\",data:t})}function ct(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/getMasterSkuNum\",method:\"post\",data:t})}function ut(t){return Object(o[\"default\"])({url:\"/Stock/ReservoirArea/addReservoir\",method:\"post\",data:t})}function it(t,e){return Object(o[\"default\"])({url:\"/Stock/ReservoirArea/getReservoirInfo/\"+t,method:\"get\",data:e})}function lt(t){return Object(o[\"default\"])({url:\"/Stock/ReservoirArea/getAllReservoir\",method:\"post\",data:t})}function dt(t){return Object(o[\"default\"])({url:\"/Stock/ReservoirArea/getListReservoir\",method:\"post\",data:t})}function ht(t,e){return Object(o[\"default\"])({url:\"/Stock/ReservoirArea/enableReservoir/\"+t,method:\"put\",data:e})}function pt(t,e){return Object(o[\"default\"])({url:\"/Stock/ReservoirArea/updateReservoir/\"+t,method:\"put\",data:e})}function ft(t,e){return Object(o[\"default\"])({url:\"/Stock/ReservoirArea/deleteReservoir/\"+t,method:\"get\",data:e})}function mt(t){return Object(o[\"default\"])({url:\"/Stock/StorageLocation/getAllStorageLocation\",method:\"post\",data:t})}function gt(t){return Object(o[\"default\"])({url:\"/Stock/StorageLocation/addStorageLocation\",method:\"post\",data:t})}function bt(t,e){return Object(o[\"default\"])({url:\"/Stock/StorageLocation/getStorageLocationInfo/\"+t,method:\"post\",data:e})}function _t(t,e){return Object(o[\"default\"])({url:\"/Stock/StorageLocation/enableStorageLocation/\"+t,method:\"post\",data:e})}function kt(t,e){return Object(o[\"default\"])({url:\"/Stock/StorageLocation/updateStorageLocation/\"+t,method:\"post\",data:e})}function St(t){return Object(o[\"default\"])({url:\"/Stock/Inventory/getAreaDateBySkuId\",method:\"post\",data:t})}function yt(t){return Object(o[\"default\"])({url:\"/Stock/ReportLoss/addReportLoss\",method:\"post\",data:t})}function It(t){return Object(o[\"default\"])({url:\"/Stock/ReportLoss/getAllReportLoss\",method:\"post\",data:t})}function vt(t,e){return Object(o[\"default\"])({url:\"/Stock/ReportLoss/getReportLossInfo/\"+t,method:\"get\",data:e})}function Ot(t,e){return Object(o[\"default\"])({url:\"/Stock/ReportLoss/auditReportLoss/\"+t,method:\"put\",data:e})}function Pt(t,e){return Object(o[\"default\"])({url:\"/Stock/ReportLoss/deleteReportLoss/\"+t,method:\"delete\",data:e})}function At(t){return Object(o[\"default\"])({url:\"Stock/InventoryIn/countPurchaseCost\",method:\"post\",data:t})}function wt(t){return Object(o[\"default\"])({url:\"stock/Inventory/getInventoryByWarehouseId\",responseType:\"blob\",method:\"post\",data:t})}function jt(t){return Object(o[\"default\"])({url:\"Stock/Allocate/getAllAllocate\",responseType:\"blob\",method:\"post\",data:t})}function Nt(t,e){return Object(o[\"default\"])({url:\"Stock/Picking/getPickingInfo/\"+t,method:\"post\",data:e})}function Mt(t){return Object(o[\"default\"])({url:\"Stock/Picking/addPicking\",method:\"post\",data:t})}function Ct(t){return Object(o[\"default\"])({url:\"Stock/Picking/getAllPicking\",method:\"post\",data:t})}function xt(t){return Object(o[\"default\"])({url:\"Stock/Picking/getAllPickingGoodsDetail\",method:\"post\",data:t})}},\"4b63\":function(t,e,a){\"use strict\";a.r(e);var o=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"el-dialog\",{attrs:{title:\"选择仓库\",\"close-on-press-escape\":!1,\"close-on-click-modal\":!1,visible:t.isShow,width:\"70%\"},on:{close:t.cancel}},[a(\"el-table\",{directives:[{name:\"loading\",rawName:\"v-loading\",value:t.loading,expression:\"loading\"}],ref:\"warehouseTable\",attrs:{data:t.tableData,size:\"small\"},on:{\"row-dblclick\":t.dbSelect,\"selection-change\":t.selectionChange}},[t.isCheck?a(\"el-table-column\",{attrs:{type:\"selection\",width:\"55\",align:\"center\"}}):t._e(),a(\"el-table-column\",{attrs:{prop:\"warehouseCode\",\"show-overflow-tooltip\":\"\",\"min-width\":\"140\",label:\"仓库编码\"}}),a(\"el-table-column\",{attrs:{prop:\"warehouseName\",\"min-width\":\"130\",\"show-overflow-tooltip\":\"\",label:\"仓库名称\"}}),a(\"el-table-column\",{attrs:{prop:\"contactName\",label:\"联系人\",\"min-width\":\"100\"}}),a(\"el-table-column\",{attrs:{prop:\"contactMobile\",\"min-width\":\"100\",label:\"联系方式\"}}),a(\"el-table-column\",{attrs:{prop:\"address\",\"min-width\":\"160\",label:\"仓库地址\",\"show-overflow-tooltip\":\"\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[t._v(\" \"+t._s(e.row.contactAddress)+\" \")]}}])}),a(\"el-table-column\",{attrs:{prop:\"status\",label:\"状态\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[5===e.row.enableStatus?a(\"span\",{staticClass:\"success-status\"},[t._v(\" 启用 \")]):a(\"span\",{staticClass:\"danger-status\"},[t._v(\"禁用\")])]}}])}),a(\"el-table-column\",{attrs:{label:\"选择\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"el-button\",{attrs:{icon:\"el-icon-check\",size:\"mini\"},on:{click:function(a){return t.dbSelect(e.row)}}})]}}])})],1),a(\"FooterPage\",{attrs:{\"page-size\":t.pre_page,\"total-page\":t.total,\"current-page\":t.page},on:{\"update:totalPage\":function(e){t.total=e},\"update:total-page\":function(e){t.total=e},\"update:currentPage\":function(e){t.page=e},\"update:current-page\":function(e){t.page=e},pageChange:t.pageChange,sizeChange:t.sizeChange}},[t.isCheck?a(\"div\",{attrs:{slot:\"btn-div\"},slot:\"btn-div\"},[a(\"el-button\",{attrs:{size:\"small\",type:\"primary\"},on:{click:t.confirm}},[t._v(\"确定\")]),a(\"el-button\",{attrs:{size:\"small\"},on:{click:t.cancel}},[t._v(\"取消\")])],1):t._e()])],1)},n=[],r=a(\"3c48\"),s=a(\"478b\"),c={name:\"ClientListModal\",components:{FooterPage:r[\"default\"]},props:{isShow:{type:Boolean,default:!1},isCheck:{type:Boolean,default:!0},notId:{type:[Number,String],default:0}},data(){return{tableData:[],choose_data:[],searchForm:{},pre_page:10,page:1,total:0,loading:!1,pageLayout:\"total, prev, pager, next\"}},created(){this.getList()},methods:{async getList(){const{data:t,pageTotal:e}=await Object(s[\"getAllWarehouse\"])({page:this.page,pageSize:this.pre_page,notId:this.notId,enableStatus:5});this.tableData=t,this.total=e;for(let a=0;a<t.length;a++){const e=this.choose_data.find(e=>e.id===t[a].id);e&&this.$nextTick(()=>{this.$refs.warehouseTable.toggleRowSelection(t[a],!0)})}},searchClick(){this.page=1,this.getList()},selectionChange(t){this.choose_data.length?this.choose_data=this.$_common.unique(this.choose_data.concat(t),[\"id\"]):this.choose_data=t},confirm(){this.cancel(),this.$emit(\"confirm\",this.choose_data)},dbSelect(t){this.choose_data=[t],this.$emit(\"confirm\",this.choose_data),this.cancel()},cancel(){this.$emit(\"cancel\")},pageChange(t){this.page=t,this.getList()},sizeChange(t){this.pre_page=t,this.pageChange(1)}}},u=c,i=(a(\"01aa\"),a(\"2877\")),l=Object(i[\"a\"])(u,o,n,!1,null,\"9b04df50\",null);e[\"default\"]=l.exports},5600:function(t,e,a){\"use strict\";a.r(e);var o=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"el-dialog\",{attrs:{title:\"选择商户\",visible:t.isShow,width:\"70%\"},on:{close:t.cancelMerchant}},[a(\"div\",{staticStyle:{\"padding-bottom\":\"10px\"}},[a(\"el-input\",{staticStyle:{width:\"280px\"},attrs:{placeholder:\"请输入商户名称\",size:\"small\",clearable:\"\"},on:{clear:function(e){return t.pageChange(1)}},model:{value:t.keyword,callback:function(e){t.keyword=e},expression:\"keyword\"}},[a(\"el-button\",{attrs:{slot:\"append\",icon:\"el-icon-search\"},on:{click:function(e){return t.pageChange(1)}},slot:\"append\"})],1)],1),a(\"el-table\",{directives:[{name:\"loading\",rawName:\"v-loading\",value:t.loading,expression:\"loading\"}],ref:\"mearchTable\",attrs:{data:t.tableData,size:\"small\"},on:{\"row-dblclick\":t.confirmSelect,\"selection-change\":t.selectionChange}},[a(\"el-table-column\",{attrs:{prop:\"name\",\"show-overflow-tooltip\":\"\",\"min-width\":\"140\",label:\"商户名称\"}}),a(\"el-table-column\",{attrs:{prop:\"contactName\",label:\"联系人\",\"min-width\":\"100\"}}),a(\"el-table-column\",{attrs:{prop:\"contactMobile\",\"min-width\":\"100\",label:\"联系方式\"}}),a(\"el-table-column\",{attrs:{label:\"选择\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"el-button\",{attrs:{icon:\"el-icon-check\",size:\"mini\"},on:{click:function(a){return t.confirmSelect(e.row)}}})]}}])})],1),a(\"FooterPage\",{attrs:{\"page-size\":t.pre_page,\"total-page\":t.total,\"current-page\":t.page},on:{\"update:totalPage\":function(e){t.total=e},\"update:total-page\":function(e){t.total=e},\"update:currentPage\":function(e){t.page=e},\"update:current-page\":function(e){t.page=e},pageChange:t.pageChange,sizeChange:t.sizeChange}},[t.isCheck?a(\"div\",{attrs:{slot:\"btn-div\"},slot:\"btn-div\"},[a(\"el-button\",{attrs:{size:\"small\",type:\"primary\"},on:{click:t.confirmMerchant}},[t._v(\" 确定 \")]),a(\"el-button\",{attrs:{size:\"small\"},on:{click:t.cancelMerchant}},[t._v(\"取消\")])],1):t._e()])],1)},n=[],r=a(\"3c48\"),s=(a(\"478b\"),a(\"bdd1\")),c={name:\"ClientListModal\",components:{FooterPage:r[\"default\"]},props:{isShow:{type:Boolean,default:!1},isCheck:{type:Boolean,default:!0},notId:{type:[Number,String],default:0}},data(){return{tableData:[],Merchant_data:[],searchForm:{},pre_page:10,page:1,total:0,loading:!1,pageLayout:\"total, prev, pager, next\",keyword:\"\"}},created(){this.getAllMerchant()},methods:{async getAllMerchant(){const t=await Object(s[\"getAllMerchant\"])({deleteStatus:5,auditStatus:2,enabledStatus:5,page:this.page,pageSize:this.pre_page,search:this.keyword});this.tableData=t.data,this.total=t.pageTotal;for(let e=0;e<t.data.length;e++){const a=this.Merchant_data.find(a=>a.id===t.data[e].id);a&&this.$nextTick(()=>{this.$refs.mearchTable.toggleRowSelection(t.data[e],!0)})}},searchClick(){this.page=1,this.getAllMerchant()},selectionChange(t){this.Merchant_data.length?this.Merchant_data=this.$_common.unique(this.Merchant_data.concat(t),[\"id\"]):this.Merchant_data=t},confirmMerchant(){this.cancelMerchant(),this.$emit(\"confirmMerchant\",this.Merchant_data)},confirmSelect(t){this.Merchant_data=t,this.$emit(\"confirmMerchant\",t),this.cancelMerchant()},cancelMerchant(){this.$emit(\"cancelMerchant\")},pageChange(t){this.page=t,this.getAllMerchant()},sizeChange(t){this.pre_page=t,this.pageChange(1)}}},u=c,i=(a(\"edb3\"),a(\"2877\")),l=Object(i[\"a\"])(u,o,n,!1,null,\"4a38af7c\",null);e[\"default\"]=l.exports},\"64f1\":function(t,e,a){\"use strict\";a.r(e),a.d(e,\"getStaff\",(function(){return n})),a.d(e,\"updateStaffStaff\",(function(){return r})),a.d(e,\"addStaff\",(function(){return s})),a.d(e,\"deleteStaff\",(function(){return c})),a.d(e,\"updateStaff\",(function(){return u})),a.d(e,\"getAllStaff\",(function(){return i})),a.d(e,\"getStaffInfo\",(function(){return l})),a.d(e,\"updateStaffTargetAndReward\",(function(){return d})),a.d(e,\"getAllStaffRewardDesc\",(function(){return h})),a.d(e,\"addDepartment\",(function(){return p})),a.d(e,\"deleteDepartment\",(function(){return f})),a.d(e,\"updateDepartment\",(function(){return m})),a.d(e,\"getAllDepartment\",(function(){return g})),a.d(e,\"getDepartmentInfo\",(function(){return b})),a.d(e,\"getAllRole\",(function(){return _})),a.d(e,\"getRoleInfo\",(function(){return k})),a.d(e,\"updateRole\",(function(){return S})),a.d(e,\"deleteRole\",(function(){return y})),a.d(e,\"addRole\",(function(){return I})),a.d(e,\"getAllStaffStaff\",(function(){return v}));var o=a(\"b775\");function n(t,e){return Object(o[\"default\"])({url:\"/Department/Staff/getStaffInfo/\"+t,method:\"post\",data:e})}function r(t,e){return Object(o[\"default\"])({url:\"/Department/Staff/updateStaff/\"+t,method:\"post\",data:e})}function s(t){return Object(o[\"default\"])({url:\"/Department/Staff/addStaff\",method:\"post\",data:t})}function c(t){return Object(o[\"default\"])({url:\"/Department/Staff/deleteStaff\",method:\"post\",data:t})}function u(t,e){return Object(o[\"default\"])({url:\"/Department/Staff/updateStaff/\"+t,method:\"put\",data:e})}function i(t){return Object(o[\"default\"])({url:\"/Department/Staff/getAllStaff\",method:\"post\",data:t})}function l(t,e){return Object(o[\"default\"])({url:\"/Department/Staff/getStaffInfo/\"+t,method:\"get\",data:e})}function d(t,e){return Object(o[\"default\"])({url:\"/Department/Staff/updateStaffTargetAndReward/\"+t,method:\"post\",data:e})}function h(t){return Object(o[\"default\"])({url:\"/Department/Staff/getAllStaffRewardDesc\",method:\"post\",data:t})}function p(t){return Object(o[\"default\"])({url:\"/Department/Department/addDepartment\",method:\"post\",data:t})}function f(t,e){return Object(o[\"default\"])({url:\"/Department/Department/deleteDepartment/\"+t,method:\"delete\",data:e})}function m(t,e){return Object(o[\"default\"])({url:\"/Department/Department/updateDepartment/\"+t,method:\"put\",data:e})}function g(t){return Object(o[\"default\"])({url:\"/Department/Department/getAllDepartment\",method:\"post\",data:t})}function b(t,e){return Object(o[\"default\"])({url:\"/Department/Department/getDepartmentInfo/\"+t,method:\"get\",data:e})}function _(t){return Object(o[\"default\"])({url:\"/Department/Role/getAllRole\",method:\"post\",data:t})}function k(t,e){return Object(o[\"default\"])({url:\"/Department/Role/getRoleInfo/\"+t,method:\"get\",data:e})}function S(t,e){return Object(o[\"default\"])({url:\"/Department/Role/updateRole/\"+t,method:\"put\",data:e})}function y(t,e){return Object(o[\"default\"])({url:\"/Department/Role/deleteRole/\"+t,method:\"delete\",data:e})}function I(t){return Object(o[\"default\"])({url:\"/Department/Role/addRole\",method:\"post\",data:t})}function v(t){return Object(o[\"default\"])({url:\"/Department/Staff/getAllStaff\",method:\"post\",data:t})}},\"83cc\":function(t,e,a){\"use strict\";a(\"301b\")},\"8d2f\":function(t,e,a){},\"8f9e\":function(t,e,a){},a5bb:function(t,e,a){},b09a:function(t,e,a){},b53c:function(t,e,a){\"use strict\";a.r(e);var o=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"div\",[a(\"el-cascader\",{style:{width:t.width+\"px\"},attrs:{disabled:t.disabled,clearable:t.clearable,filterable:t.filterable,placeholder:t.placeholder,value:t.value,options:t.Department_data,props:t.props,size:t.size},on:{\"expand-change\":t.expandChange,change:t.change},scopedSlots:t._u([{key:\"default\",fn:function(e){return a(\"div\",{on:{click:t.clickChange}},[t._v(\" \"+t._s(e.data.departmentName)+\" \")])}}])}),t.isShowAdd?a(\"el-button\",{attrs:{type:\"text\",size:\"mini\"},on:{click:t.getAllDepartment}},[t._v(\" 【刷新】 \")]):t._e()],1)},n=[],r=a(\"64f1\"),s={name:\"DepartmentSel\",model:{prop:\"value\",event:\"change\"},props:{value:{type:Array,default:()=>[]},isShowAdd:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},placeholder:{type:String,default:\"请选择部门\"},clearable:{type:Boolean,default:!1},filterable:{type:Boolean,default:!1},width:{type:[Number,String],default:200},size:{type:String,default:\"small\"}},data(){return{Department_data:[],props:{label:\"departmentName\",value:\"id\",checkStrictly:!0}}},created(){this.getAllDepartment()},methods:{async getAllDepartment(){const t=await Object(r[\"getAllDepartment\"])();this.Department_data=t.data},change(t){this.$emit(\"change\",t)},expandChange(t){this.$emit(\"expandChange\",t)}}},c=s,u=a(\"2877\"),i=Object(u[\"a\"])(c,o,n,!1,null,\"0457a42c\",null);e[\"default\"]=i.exports},bdd1:function(t,e,a){\"use strict\";a.r(e),a.d(e,\"addMerchant\",(function(){return n})),a.d(e,\"getAllMerchant\",(function(){return r})),a.d(e,\"updateMerchant\",(function(){return s})),a.d(e,\"saveSettingMerchant\",(function(){return c})),a.d(e,\"getSettingMerchant\",(function(){return u})),a.d(e,\"getInfoMerchant\",(function(){return i})),a.d(e,\"delMerchant\",(function(){return l})),a.d(e,\"auditApply\",(function(){return d})),a.d(e,\"MerchantWithdrawAdd\",(function(){return h})),a.d(e,\"getMerchantWithdraw\",(function(){return p})),a.d(e,\"MerchantWithdrawGetAll\",(function(){return f})),a.d(e,\"MerchantUpdateAuditStatus\",(function(){return m})),a.d(e,\"MerchantGetSettingField\",(function(){return g})),a.d(e,\"Merchantlog\",(function(){return b})),a.d(e,\"enabledMerchant\",(function(){return _})),a.d(e,\"getAllMerchantSettlement\",(function(){return k})),a.d(e,\"updateMerchantSettlement\",(function(){return S})),a.d(e,\"getAllMerchantWithdraw\",(function(){return y})),a.d(e,\"addMerchantWithdraw\",(function(){return I})),a.d(e,\"getAllMerchantList\",(function(){return v})),a.d(e,\"getAllMerchantDetail\",(function(){return O})),a.d(e,\"exportgetAllMerchantDetail\",(function(){return P})),a.d(e,\"exportgetAllMerchantSettlement\",(function(){return A}));var o=a(\"b775\");function n(t){return Object(o[\"default\"])({url:\"Merchant/Merchant/addMerchant\",method:\"post\",data:t})}function r(t){return Object(o[\"default\"])({url:\"Merchant/Merchant/getAllMerchant\",method:\"post\",data:t})}function s(t,e){return Object(o[\"default\"])({url:\"Merchant/Merchant/updateMerchant/\"+t,method:\"put\",data:e})}function c(t){return Object(o[\"default\"])({url:\"Merchant/Merchant/saveSetting\",method:\"post\",data:t})}function u(t){return Object(o[\"default\"])({url:\"Merchant/Merchant/getSetting\",method:\"post\",data:t})}function i(t,e){return Object(o[\"default\"])({url:\"Merchant/Merchant/getInfoMerchant/\"+t,method:\"get\",data:e})}function l(t,e){return Object(o[\"default\"])({url:\"Merchant/Merchant/delMerchant/\"+t,method:\"get\",data:e})}function d(t,e){return Object(o[\"default\"])({url:\"Merchant/Merchant/auditApply/\"+t,method:\"put\",data:e})}function h(t){return Object(o[\"default\"])({url:\"Merchant/MerchantWithdraw/add\",method:\"post\",data:t})}function p(t){return Object(o[\"default\"])({url:\"Merchant/MerchantWithdraw/get\",method:\"post\",data:t})}function f(t){return Object(o[\"default\"])({url:\"Merchant/MerchantWithdraw/getAll\",method:\"post\",data:t})}function m(t,e){return Object(o[\"default\"])({url:\"Merchant/MerchantWithdraw/updateAuditStatus/\"+t,method:\"put\",data:e})}function g(t,e){return Object(o[\"default\"])({url:\"Merchant/Merchant/getSettingField\",method:\"post\",data:e})}function b(t){return Object(o[\"default\"])({url:\"Merchant/Merchant/log\",method:\"post\",data:t})}function _(t,e){return Object(o[\"default\"])({url:\"Merchant/Merchant/enabledMerchant/\"+t,method:\"get\",data:e})}function k(t){return Object(o[\"default\"])({url:\"Merchant/MerchantSettlement/getAllMerchantSettlement\",method:\"POST\",data:t})}function S(t){return Object(o[\"default\"])({url:\"Merchant/MerchantSettlement/updateMerchantSettlement\",method:\"POST\",data:t})}function y(t){return Object(o[\"default\"])({url:\"Merchant/MerchantWithdraw/getAll\",method:\"post\",data:t})}function I(t){return Object(o[\"default\"])({url:\"Merchant/MerchantWithdraw/add\",method:\"post\",data:t})}function v(t){return Object(o[\"default\"])({url:\"Merchant/Merchant/getAllMerchantList\",method:\"post\",data:t})}function O(t){return Object(o[\"default\"])({url:\"Merchant/MerchantDetail/getAllMerchantDetail\",method:\"post\",data:t})}function P(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getAllMerchantDetail\",method:\"post\",responseType:\"blob\",data:t})}function A(t){return Object(o[\"default\"])({url:\"/Purchase/Purchase/getAllMerchantSettlement\",method:\"post\",responseType:\"blob\",data:t})}},d177:function(t,e,a){\"use strict\";a.r(e);var o=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"div\",{staticClass:\"out-div\"},[a(\"el-select\",{staticStyle:{width:\"100%\"},attrs:{size:t.size,value:t.value,filterable:\"\",remote:\"\",\"reserve-keyword\":\"\",disabled:t.disabled,placeholder:\"请输入关键词首字母\",\"remote-method\":t.remoteMethod,loading:t.select_loading},on:{change:t.selectSelGoods,\"visible-change\":t.goodsVisibleChange}},t._l(t.goods_options,(function(t,e){return a(\"el-option\",{key:e,attrs:{label:t.title,value:t.id}})})),1),a(\"span\",{staticClass:\"el-icon-search sel-icon\",on:{click:t.openGoodsModel}}),a(\"el-dialog\",{staticStyle:{\"text-align\":\"left\"},attrs:{\"close-on-press-escape\":!1,\"close-on-click-modal\":!1,title:\"选择属性\",visible:t.spec_model,width:\"40%\"},on:{\"update:visible\":function(e){t.spec_model=e}}},[a(\"el-checkbox\",{on:{change:t.checkAllSpecChange},model:{value:t.check_all_spec,callback:function(e){t.check_all_spec=e},expression:\"check_all_spec\"}},[t._v(\" 全选 \")]),t._l(t.spec_check_list,(function(e,o){return a(\"div\",{key:o,staticStyle:{padding:\"10px\",border:\"1px solid #eee\",margin:\"10px 0\"}},[a(\"el-checkbox\",{attrs:{indeterminate:e.is_spec_indeterminate},on:{change:function(e){return t.checkUnitSpecChange(e,o)}},model:{value:e.check_unit_spec,callback:function(a){t.$set(e,\"check_unit_spec\",a)},expression:\"item.check_unit_spec\"}},[t._v(\" \"+t._s(e.unitName)+\" \")]),a(\"div\",{staticStyle:{padding:\"10px 15px 0\"}},[a(\"el-checkbox-group\",{on:{change:function(e){return t.specCheckChange(e,o)}},model:{value:e.spec_check,callback:function(a){t.$set(e,\"spec_check\",a)},expression:\"item.spec_check\"}},t._l(e.children,(function(e,o){return a(\"el-checkbox\",{key:o,staticStyle:{\"padding-bottom\":\"5px\"},attrs:{label:e.id}},[a(\"span\",{staticStyle:{\"font-weight\":\"400\"}},[t._v(t._s(e.specGropName))])])})),1)],1)],1)})),a(\"span\",{staticClass:\"dialog-footer\",attrs:{slot:\"footer\"},slot:\"footer\"},[a(\"el-button\",{on:{click:function(e){t.spec_model=!1}}},[t._v(\"取 消\")]),a(\"el-button\",{attrs:{type:\"primary\"},on:{click:t.specSelConfirm}},[t._v(\"确 定\")])],1)],2),t.show_goods?a(\"SaleGoodsSel\",{attrs:{\"merchant-id\":t.merchantId,\"base-goods\":t.type,\"is-show\":t.show_goods,\"user-center-id\":t.userCenterId,\"is-reveal-sku\":4,\"is-eq-master\":t.isEqMaster,\"is-purchase\":t.isPurchase,\"shop-id\":t.shopId},on:{cancel:function(e){t.show_goods=!1},confirm:t.selGoods}}):t._e()],1)},n=[],r=a(\"c40e\"),s=a(\"0d53\"),c={name:\"ConditionSelGoods\",components:{SaleGoodsSel:s[\"default\"]},model:{prop:\"value\",event:\"change\"},props:{merchantId:{type:[Number,String],default:\"\"},type:{type:Boolean,default:!1},isPurchase:{type:Boolean,default:!1},isEqMaster:{type:Boolean,default:!0},isAddGoods:{type:[Number,String],default:5},userCenterId:{type:[Number,String],default:\"\"},shopId:{type:[Number,String,Array],default:\"\"},enableStatus:{type:[Number,String],default:\"\"},value:{type:String,default:\"\"},disabled:{type:Boolean,default:!1},specCheck:{type:Array,default:()=>[]},isRevealSku:{type:[Number,String],default:4},size:{type:String,default:\"small\"}},data(){return{goodsName:\"\",goods_options:[],show_goods:!1,select_loading:!1,spec_model:!1,check_all_spec:!1,is_spec_indeterminate:!1,spec_check:[],spec_check_list:[],now_goods_data:{}}},watch:{specCheck(t){this.spec_check=t}},mounted(){console.log(this.isPurchase)},methods:{openGoodsModel(){this.disabled||(this.show_goods=!0)},async remoteMethod(t){if(!t)return void(this.goods_options=[]);let e={condition:t,type:this.type,enableStatus:this.enableStatus};this.shopId&&(e.shopId=Array.isArray(this.shopId)?this.shopId:[this.shopId]),this.merchantId&&(e.merchantId=this.merchantId),this.select_loading=!0;const{data:a}=await Object(r[\"getGoodsByCondition\"])(e);this.select_loading=!1,\"{}\"===JSON.stringify(a)?this.goods_options=[]:this.goods_options=a},goodsVisibleChange(t){this.$emit(\"goodsVisibleChange\",t)},selectSelGoods(t){this.$emit(\"selectSelGoods\",t),this.check_all_spec=!1,this.type?this.getGoodsBasicInfoById(t):this.getGoodsInfo(t)},async getGoodsInfo(t){const{data:e}=await Object(r[\"getGoodsInfo\"])(t,{userCenterId:this.userCenterId});this.now_goods_data=e,this.spec_model=!0,2===e.specType?this.spec_check_list=e.unitData.map(t=>({...t,is_spec_indeterminate:!1,check_unit_spec:!1,spec_check:[],children:e.specMultiple.filter(e=>e.unitId===t.unitId).map(t=>({...t,specGropName:t.specGroup.map(t=>t.specValueName).join(\"_\")}))})):this.spec_check_list=e.specMultiple.map(t=>({...t,is_spec_indeterminate:!1,check_unit_spec:!1,spec_check:[]})),1!==this.spec_check_list.length||this.spec_check_list[0].children?1===this.spec_check_list.length&&1===this.spec_check_list[0].children.length&&(this.spec_model=!1,this.$emit(\"specSelConfirm\",{goodsD:[{skuId:this.spec_check_list[0].children[0].id,spec:this.spec_check_list[0].children[0]}],spec_check_list:this.spec_check_list,now_goods_data:this.now_goods_data})):(this.spec_model=!1,this.$emit(\"specSelConfirm\",{goodsD:[{skuId:this.spec_check_list[0].id,spec:this.spec_check_list[0]}],spec_check_list:this.spec_check_list,now_goods_data:this.now_goods_data}))},async getGoodsBasicInfoById(t){const{data:e}=await Object(r[\"getGoodsBasicInfoById\"])(t,{isAddGoods:this.isAddGoods});this.now_goods_data=e,this.spec_model=!0,2===e.specType?this.spec_check_list=e.unitData.map(t=>({...t,is_spec_indeterminate:!1,check_unit_spec:!1,spec_check:[],children:e.specMultiple.filter(e=>e.unitId===t.unitId).map(t=>({...t,specGropName:t.specGroup.map(t=>t.specValueName).join(\"_\")}))})):this.spec_check_list=e.specMultiple.map(t=>({...t,is_spec_indeterminate:!1,check_unit_spec:!1,spec_check:[]})),this.isPurchase&&5===e.isEq&&(this.spec_check_list=this.spec_check_list.filter(t=>5===t.isMaster))},specSelConfirm(){let t=[],e=[];2===this.now_goods_data.specType?(this.spec_check_list.forEach(e=>{e.spec_check&&e.spec_check.length&&t.push(e.spec_check.join(\",\"))}),this.spec_check=t.join(\",\").split(\",\").map(t=>parseInt(t)),e=this.spec_check.map(t=>{let e={};for(let a in this.spec_check_list){let o=this.spec_check_list[a];const n=o.children&&o.children.length?o.children.find(e=>e.id===t):\"\";if(n){e=n;break}}return{skuId:t,spec:e}})):e=this.spec_check_list.filter(t=>t.check_unit_spec).map(t=>({skuId:t.id,spec:t})),this.$emit(\"specSelConfirm\",{goodsD:e,spec_check_list:this.spec_check_list,now_goods_data:this.now_goods_data}),this.spec_model=!1},specCheckChange(t,e){const a=this.$_common.deepClone(this.spec_check_list);let o=t.length;a[e].check_unit_spec=o===a[e].children.length,a[e].is_spec_indeterminate=o>0&&o<a[e].children.length,this.spec_check_list=a,this.check_all_spec=this.spec_check_list.every(t=>t.check_unit_spec)},checkAllSpecChange(t){this.spec_check_list.forEach(e=>{e.check_unit_spec=t,e.is_spec_indeterminate=!1,e.spec_check=t&&e.children&&e.children.length?e.children.map(t=>t.id):[]}),this.is_spec_indeterminate=!1},checkUnitSpecChange(t,e){const a=this.$_common.deepClone(this.spec_check_list);a[e].spec_check=t&&a[e].children&&a[e].children.length?a[e].children.map(t=>t.id):[],a[e].is_spec_indeterminate=!1,this.spec_check_list=a,this.check_all_spec=this.spec_check_list.every(t=>t.check_unit_spec)},selGoods(t){console.log(t),this.$emit(\"selGoods\",t)}}},u=c,i=(a(\"1ccb\"),a(\"2877\")),l=Object(i[\"a\"])(u,o,n,!1,null,\"410451b4\",null);e[\"default\"]=l.exports},edb3:function(t,e,a){\"use strict\";a(\"a5bb\")},fd6f:function(t,e,a){\"use strict\";a.r(e);var o=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"ContainerTit\",{staticClass:\"AddMerchantPurchase\"},[a(\"div\",{staticStyle:{position:\"relative\"}},[a(\"div\",{staticClass:\"btn-top-div\"},[\"PurchaseOrderLook\"!==t.look_path?a(\"el-button\",{attrs:{loading:t.loading,disabled:!!t.$route.params.id},on:{click:function(e){return t.delPauseSave(1)}}},[t._v(\" 清除暂存 \")]):t._e(),\"PurchaseOrderLook\"!==t.look_path?a(\"el-button\",{attrs:{loading:t.loading,disabled:!!t.$route.params.id},on:{click:t.addPauseSave}},[t._v(\" 暂存 \")]):t._e(),\"PurchaseOrderLook\"!==t.look_path?a(\"el-button\",{attrs:{type:\"primary\",loading:t.loading},on:{click:t.addPurchaseOrder}},[t._v(\" 保存 \")]):t._e(),\"PurchaseOrderLook\"===t.look_path?a(\"el-button\",{attrs:{type:\"primary\",disabled:2===t.auditStatus,loading:t.loading},on:{click:t.updatePurchase}},[t._v(\" 审核 \")]):t._e()],1)]),a(\"div\",[a(\"el-form\",{ref:\"form\",attrs:{inline:!0,rules:t.purchase_rules,model:t.form,size:\"small\",disabled:\"PurchaseOrderLook\"===t.look_path}},[a(\"el-tabs\",{model:{value:t.activeName,callback:function(e){t.activeName=e},expression:\"activeName\"}},[a(\"el-tab-pane\",{attrs:{label:\"付款单详情\",name:\"one\"}},[a(\"el-row\",{staticStyle:{\"padding-bottom\":\"13px\"}},[a(\"el-col\",{attrs:{span:24}},[a(\"p\",{staticClass:\"order_midden_left_text el-icon-arrow-right\",staticStyle:{\"padding-left\":\"20px\"}},[t._v(\" 付款单信息 \")])]),t.$route.params.id?a(\"el-col\",{staticClass:\"form\",staticStyle:{\"margin-bottom\":\"0\"},attrs:{span:6}},[a(\"el-form-item\",{attrs:{label:\"采购单号:\",prop:\"code\"}},[t._v(\" \"+t._s(t.form.code)+\" \")])],1):t._e(),a(\"el-col\",{staticClass:\"form\",staticStyle:{\"margin-bottom\":\"0\"},attrs:{span:6}},[a(\"el-form-item\",{attrs:{label:\"采购仓库\",prop:\"warehouseName\"}},[\"PurchaseOrderLook\"!==t.look_path?a(\"div\",[a(\"el-input\",{attrs:{placeholder:\"采购仓库\",readonly:\"\"},model:{value:t.form.warehouseName,callback:function(e){t.$set(t.form,\"warehouseName\",e)},expression:\"form.warehouseName\"}},[a(\"i\",{staticClass:\"el-input__icon el-icon-search\",attrs:{slot:\"suffix\"},on:{click:function(e){return t.openWarehouse()}},slot:\"suffix\"})])],1):a(\"span\",[t._v(t._s(t.form.warehouseName))])])],1),a(\"el-col\",{staticClass:\"form\",staticStyle:{\"margin-bottom\":\"0\"},attrs:{span:6}},[a(\"el-form-item\",{staticStyle:{\"min-width\":\"400px\"},attrs:{label:\"采购人员:\",prop:\"buyerId\"}},[\"PurchaseOrderLook\"!==t.look_path?a(\"div\",[a(\"el-input\",{staticStyle:{width:\"210px\"},attrs:{placeholder:\"采购人员\",readonly:\"\"},model:{value:t.form.buyerName,callback:function(e){t.$set(t.form,\"buyerName\",e)},expression:\"form.buyerName\"}},[a(\"i\",{staticClass:\"el-input__icon el-icon-search\",attrs:{slot:\"suffix\"},on:{click:function(e){t.staff_show=!0}},slot:\"suffix\"})]),a(\"el-button\",{attrs:{type:\"text\",size:\"mini\"},on:{click:function(e){t.add_staff=!0}}},[t._v(\" 【新建人员】 \")])],1):a(\"span\",[t._v(t._s(t.form.buyerName))])])],1),a(\"el-col\",{staticClass:\"form\",staticStyle:{\"margin-bottom\":\"0\"},attrs:{span:6}},[3!==t.systemType?a(\"el-form-item\",{attrs:{label:\"商户:\",prop:\"name\"}},[\"PurchaseOrderLook\"!==t.look_path?a(\"div\",[a(\"el-input\",{staticStyle:{width:\"210px\"},attrs:{placeholder:\"请选择商户\",readonly:\"\"},model:{value:t.form.merchantName,callback:function(e){t.$set(t.form,\"merchantName\",e)},expression:\"form.merchantName\"}},[a(\"i\",{staticClass:\"el-input__icon el-icon-search\",attrs:{slot:\"suffix\"},on:{click:function(e){t.mearchant_show=!0}},slot:\"suffix\"})])],1):a(\"span\",[t._v(t._s(t.name))])]):t._e()],1),a(\"el-col\",{staticClass:\"form\",attrs:{span:6}},[a(\"el-form-item\",{attrs:{label:\"制单人员:\"}},[t._v(\" \"+t._s(t.form.operatorName)+\" \")])],1),a(\"el-col\",{staticClass:\"form\",attrs:{span:6}},[a(\"el-form-item\",{attrs:{label:\"制单时间:\"}},[a(\"span\",[t._v(t._s(t.$_common.formatDate(t.createTime)))])])],1),2===t.auditStatus?a(\"el-col\",{staticClass:\"form\",attrs:{span:6}},[a(\"el-form-item\",{attrs:{label:\"审核人员:\"}},[t._v(\" \"+t._s(t.auditName)+\" \")])],1):t._e(),2===t.auditStatus?a(\"el-col\",{staticClass:\"form\",attrs:{span:6}},[a(\"el-form-item\",{attrs:{label:\"审核时间:\"}},[a(\"span\",[t._v(t._s(t.$_common.formatDate(t.auditTime)))])])],1):t._e(),\"PurchaseOrderLook\"===t.look_path&&2===t.auditStatus?a(\"el-col\",{staticClass:\"form\",attrs:{span:6}},[a(\"el-form-item\",{attrs:{label:\"审核状态:\"}},[\"PurchaseOrderLook\"===t.look_path&&2===t.auditStatus?a(\"el-tag\",{attrs:{type:\"success\"}},[t._v(\" 已审核 \")]):t._e()],1)],1):t._e()],1),t.err_tip_list.length?a(\"el-alert\",{attrs:{title:\"采购数量换算提示\",type:\"error\",\"show-icon\":\"\",\"close-text\":\"知道了\"}},[a(\"ul\",t._l(t.err_tip_list,(function(e,o){return a(\"li\",{key:o},[t._v(\" 商品【\"+t._s(e.goodsName)+\"】,单位【\"+t._s(e.unitName)+\"】,编码【\"+t._s(e.goodsCode)+\"】,数量换算有误:\"+t._s(e.title)+\" \")])})),0)]):t._e()],1)],1),a(\"div\",{staticClass:\"order_bottom\"},[a(\"p\",{staticClass:\"text\"},[t._v(\"商品清单\")]),a(\"el-table\",{attrs:{data:t.goods_list,\"show-summary\":\"\",size:\"mini\",\"summary-method\":t.getSummaries}},[a(\"el-table-column\",{attrs:{label:\"#\",width:\"60\",type:\"index\"}}),a(\"el-table-column\",{attrs:{label:\"商品编码\",width:\"140\",prop:\"goodsCode\",\"show-overflow-tooltip\":\"\"}}),a(\"el-table-column\",{attrs:{prop:\"goodsName\",label:\"商品名称\",\"min-width\":\"180\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[\"MerchantPurchaseDetail\"!==t.look_path?a(\"span\",[a(\"ConditionSelGoods\",{attrs:{\"merchant-id\":t.form.merchantId,type:!0,\"is-reveal-sku\":4,\"enable-status\":5,\"is-add-goods\":5,\"spec-check\":t.spec_check},on:{selGoods:t.selGoods,goodsVisibleChange:function(a){return t.goodsVisibleChange(a,e.$index)},specSelConfirm:t.specSelConfirm},model:{value:e.row.goodsName,callback:function(a){t.$set(e.row,\"goodsName\",a)},expression:\"scope.row.goodsName\"}})],1):a(\"span\",[t._v(\" \"+t._s(e.row.goodsName)+\" \")])]}}])}),a(\"el-table-column\",{attrs:{prop:\"specGropName\",label:\"规格\",\"min-width\":\"120\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[e.row.unitName?a(\"span\",[t._v(t._s(e.row.unitName)+\";\")]):t._e(),a(\"span\",[t._v(t._s(e.row.specGropName))])]}}])}),a(\"el-table-column\",{attrs:{prop:\"buyerNum\",label:\"采购数量\",\"min-width\":\"100\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"el-input-number\",{staticStyle:{width:\"100%\"},attrs:{size:\"mini\",min:0,type:\"text\",placeholder:\"数量\",controls:!1},on:{blur:function(a){return t.editNumChange(e.$index,\"buyerNum\")}},model:{value:e.row.buyerNum,callback:function(a){t.$set(e.row,\"buyerNum\",a)},expression:\"scope.row.buyerNum\"}})]}}])}),a(\"el-table-column\",{attrs:{prop:\"buyerNum\",label:\"其他单位\",\"min-width\":\"100\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[5===e.row.isEq?a(\"el-input-number\",{staticStyle:{width:\"100%\"},attrs:{size:\"mini\",min:0,type:\"text\",placeholder:\"其他单位\",controls:!1},on:{blur:function(a){return t.editNumChange(e.$index,\"buyerNum\")}},model:{value:e.row.otherNum,callback:function(a){t.$set(e.row,\"otherNum\",a)},expression:\"scope.row.otherNum\"}}):a(\"span\",[t._v(\"--\")])]}}])}),a(\"el-table-column\",{attrs:{prop:\"skuValue\",label:\"换算比例数量\",\"min-width\":\"120\"}}),a(\"el-table-column\",{attrs:{prop:\"skuNum\",label:\"转换数量\",\"min-width\":\"80\"}}),a(\"el-table-column\",{attrs:{prop:\"buyerUnitPrice\",label:\"采购单价\",\"min-width\":\"100\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"el-input-number\",{staticStyle:{width:\"100%\"},attrs:{size:\"mini\",controls:!1,min:0,type:\"text\",placeholder:\"单价\"},on:{blur:function(a){return t.editNumChange(e.$index)}},model:{value:e.row.buyerUnitPrice,callback:function(a){t.$set(e.row,\"buyerUnitPrice\",a)},expression:\"scope.row.buyerUnitPrice\"}})]}}])}),a(\"el-table-column\",{attrs:{prop:\"subtotalPrice\",label:\"小计金额\",\"min-width\":\"100\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[t._v(\" \"+t._s(t.$_common.formattedNumber(e.row.subtotalPrice))+\" \")]}}])}),\"PurchaseOrderLook\"===t.look_path?a(\"el-table-column\",{attrs:{prop:\"storage\",label:\"货架编码\",\"min-width\":\"100\"}}):t._e(),\"PurchaseOrderLook\"===t.look_path?a(\"el-table-column\",{attrs:{prop:\"barCode\",label:\"商品条码\",\"min-width\":\"100\"}}):t._e(),\"PurchaseOrderLook\"!==t.look_path?a(\"el-table-column\",{attrs:{label:\"管理\",fixed:\"right\",width:\"160\",align:\"center\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"el-button\",{attrs:{type:\"text\",size:\"mini\",disabled:1===t.goods_list.length},on:{click:function(a){return t.delData(e.$index,e.row)}}},[t._v(\" 删除 \")]),a(\"el-button\",{attrs:{type:\"text\",size:\"mini\"},on:{click:function(a){return t.otherSet(e.$index,e.row)}}},[t._v(\" 同步 \")])]}}],null,!1,3535365623)}):t._e()],1),\"PurchaseOrderLook\"!==t.look_path?a(\"div\",{staticClass:\"table-b-div\"},[a(\"div\",{staticClass:\"table-b-div-cont\",on:{click:t.addListGoods}},[a(\"el-button\",{attrs:{type:\"text\",size:\"mini\"},on:{click:t.addListGoods}},[a(\"i\",{staticClass:\"el-icon-plus\"}),t._v(\" 新增 \")])],1)]):t._e(),a(\"div\",{staticClass:\"clearfix other-price-view\"},[a(\"div\",{staticClass:\"float_left\"},[a(\"el-form-item\",{attrs:{label:\"备注:\"}},[a(\"el-input\",{staticStyle:{width:\"360px\"},attrs:{size:\"small\",placeholder:\"备注\"},model:{value:t.form.remark,callback:function(e){t.$set(t.form,\"remark\",e)},expression:\"form.remark\"}})],1)],1),a(\"div\",{staticClass:\"float_right\"},[a(\"el-form-item\",{attrs:{label:\"其他金额:\"}},[a(\"el-input-number\",{staticStyle:{width:\"100px\"},attrs:{size:\"small\",controls:!1,min:0,placeholder:\"其他金额\"},model:{value:t.form.otherAmount,callback:function(e){t.$set(t.form,\"otherAmount\",e)},expression:\"form.otherAmount\"}})],1),a(\"el-form-item\",{attrs:{label:\"优惠金额:\"}},[a(\"el-input-number\",{staticStyle:{width:\"100px\"},attrs:{size:\"small\",controls:!1,min:0,max:t.purchaseAmount,placeholder:\"优惠金额\"},model:{value:t.form.couponAmount,callback:function(e){t.$set(t.form,\"couponAmount\",e)},expression:\"form.couponAmount\"}})],1),a(\"el-form-item\",{attrs:{label:\"采购金额:\"}},[a(\"el-input\",{staticStyle:{width:\"100px\"},attrs:{size:\"small\",placeholder:\"采购金额\"},model:{value:t.purchaseAmount,callback:function(e){t.purchaseAmount=e},expression:\"purchaseAmount\"}})],1)],1)])],1)],1)],1),t.add_staff?a(\"AddStaff\",{attrs:{visible:t.add_staff},on:{close:function(e){t.add_staff=!1}}}):t._e(),t.staff_show?a(\"StaffList\",{attrs:{\"is-show\":t.staff_show,\"is-check\":!1,isserch:!0},on:{cancel:function(e){t.staff_show=!1},confirm:t.staffSel}}):t._e(),t.warehouse_show?a(\"WarehouseModel\",{attrs:{\"is-check\":!1,\"is-show\":t.warehouse_show},on:{confirm:t.selWarehouse,cancel:function(e){t.warehouse_show=!1}}}):t._e(),t.mearchant_show?a(\"MearchantList\",{attrs:{\"is-show\":t.mearchant_show},on:{confirmMerchant:t.confirmMerchant,cancelMerchant:function(e){t.mearchant_show=!1}}}):t._e(),a(\"el-dialog\",{attrs:{\"close-on-press-escape\":!1,\"close-on-click-modal\":!1,title:\"选择属性\",visible:t.spec_model,width:\"40%\"},on:{\"update:visible\":function(e){t.spec_model=e}}},[a(\"el-checkbox\",{attrs:{indeterminate:t.is_spec_indeterminate},on:{change:t.checkAllSpecChange},model:{value:t.check_all_spec,callback:function(e){t.check_all_spec=e},expression:\"check_all_spec\"}},[t._v(\" 全选 \")]),a(\"div\",{staticStyle:{margin:\"15px 0\"}}),a(\"el-checkbox-group\",{on:{change:t.specCheckChange},model:{value:t.spec_check,callback:function(e){t.spec_check=e},expression:\"spec_check\"}},t._l(t.spec_check_list,(function(e,o){return a(\"el-checkbox\",{key:o,staticStyle:{\"padding-bottom\":\"5px\"},attrs:{label:e.id}},[t._v(\" \"+t._s(e.specGropName)+\" \")])})),1),a(\"span\",{staticClass:\"dialog-footer\",attrs:{slot:\"footer\"},slot:\"footer\"},[a(\"el-button\",{on:{click:function(e){t.spec_model=!1}}},[t._v(\"取 消\")]),a(\"el-button\",{attrs:{type:\"primary\"},on:{click:t.specSelConfirm}},[t._v(\"确 定\")])],1)],1)],1)},n=[],r=(a(\"caad\"),a(\"2f62\")),s=a(\"5600\"),c=a(\"4b63\"),u=a(\"55d15\"),i=a(\"7a21\"),l=a(\"d177\"),d=a(\"478b\"),h=a(\"1244\"),p=a(\"2934\");const f={basicGoodsId:\"\",goodsCode:\"\",goodsName:\"\",skuId:\"\",unitName:\"\",categoryId:\"\",categoryName:\"\",buyerNum:0,buyerUnitPrice:0,subtotalPrice:0,couponAmount:0,otherAmount:0};var m={name:\"PurchaseOrderAdd\",components:{WarehouseModel:c[\"default\"],MearchantList:s[\"default\"],ConditionSelGoods:l[\"default\"],AddStaff:u[\"default\"],StaffList:i[\"default\"]},data(){const t=(t,e,a)=>{e?a():a(new Error(\"请选择采购仓库\"))},e=(t,e,a)=>{e?a():a(new Error(\"请选择商户\"))};return{good_name:!0,add_merchant:!1,mearchant_show:!1,err_tip_list:[],now_goods_data:{},spec_check:[],auditTime:\"\",spec_check_list:[],show_goods:!1,select_loading:!1,check_all_spec:!1,is_spec_indeterminate:!1,spec_model:!1,add_staff:!1,loading:!1,createTime:(new Date).getTime(),auditName:\"\",auditId:\"\",auditStatus:\"\",look_path:\"\",goods_options:[],del_goods_id:[],warehouse_list:[],form:{code:\"\",shopId:\"\",shopName:\"\",supplierId:\"\",supplierName:\"\",buyerId:\"\",buyerName:\"\",operatorName:\"\",couponAmount:0,otherAmount:0,remark:\"\",goodsData:[],warehouseName:\"\",warehouseId:\"\",merchantId:\"\",merchantName:\"\",purchaseType:5},supplier_show:!1,purchase_list:[],purchase_rules:{warehouseName:[{required:!0,validator:t}],supplierName:[{required:!0,validator:e}],buyerId:[{required:!0,message:\"请选择采购人员\",trigger:\"change\"}]},goods_list:[],pusrchase_id:\"\",goods_index:0,warehouse_show:!1,staff_show:!1,options:[{value:1,label:\"按数量\"},{value:2,label:\"按金额\"}],options_value:\"\",contributions:\"\",apportionFlag:!1,activeName:\"one\"}},computed:{purchaseAmount(){let t=0;return this.goods_list.length>1?this.goods_list.forEach(e=>{t=this.$NP.plus(t,Number(e.subtotalPrice))}):t=1===this.goods_list.length?Number(this.goods_list[0].subtotalPrice):0,this.$NP.plus(t,this.$NP.minus(this.form.otherAmount,this.form.couponAmount))||0},...Object(r[\"c\"])({storeData:\"MUser/storeData\"})},created(){3===this.systemType&&(this.form.merchantId=this.storeData.merchantData.id,this.form.merchantName=this.storeData.merchantData.name),this.look_path=this.$route.name,this.$route.params.id?(this.pusrchase_id=this.$route.params.id,this.getPurchaseInfoById()):(this.form.operatorName=this.userName,[2,3].includes(this.systemType)&&(this.form.shopId=this.storeData.id,this.form.shopName=this.storeData.name),this.getPauseSave());for(let t=1;t<=1;t++)this.goods_list.push(this.$_common.deepClone(f))},methods:{confirmMerchant(t){this.pusrchase_id&&(this.del_goods_id=this.$_common.deepClone(this.goods_list).map(t=>t.id).filter(t=>!!t)),this.goods_list=[],this.goods_list.push(this.$_common.deepClone(f)),this.form.merchantId=t.id,this.form.merchantName=t.name,\"\"!==this.form.merchantId&&(this.good_name=!1)},openWarehouse(){this.warehouse_show=!0},selWarehouse(t){this.form.warehouseName=t[0].warehouseName,this.form.warehouseId=t[0].id},staffSel(t){this.form.buyerName=t[0].staffName,this.form.buyerId=t[0].id},shopDefault(t,e){this.form.shopId=t,this.form.shopName=e.name},async updatePurchase(t){const e={auditStatus:\"2\",auditName:this.userName};this.$confirm(\"确定审核该订单\",\"提示\",{confirmButtonText:\"确定\",cancelButtonText:\"取消\",type:\"warning\"}).then(async()=>{await Object(h[\"updatePurchaseStatus\"])(this.pusrchase_id,e);this.$message({type:\"success\",message:\"操作成功!\"}),await this.getPurchaseInfoById()})},specCheckChange(t){let e=t.length;this.check_all_spec=e===this.spec_check_list.length,this.is_spec_indeterminate=e>0&&e<this.spec_check_list.length},checkAllSpecChange(t){this.spec_check=t?this.spec_check_list.map(t=>t.id):[],this.is_spec_indeterminate=!1},goodsVisibleChange(t,e){t&&(this.goods_index=e)},async getSkuNum(){const t=this.goods_list.map(t=>({skuId:t.skuId,goodsBasicId:t.basicGoodsId,num:t.buyerNum||1})).filter(t=>t.skuId);if(!t.length)return;const{data:e}=await Object(d[\"getMasterSkuNum\"])(t);this.goods_list=this.goods_list.map(t=>{let a={};return e[t.skuId]&&(a={title:e[t.skuId].title||\"\",buyerNum:e[t.skuId].num,skuValue:e[t.skuId].skuValue,skuNum:e[t.skuId].masterNum+e[t.skuId].masterName}),{...t,...a}}),this.err_tip_list=this.goods_list.filter(t=>!!t.title),this.goods_list.find(t=>!t.skuId)||this.addListGoods()},selGoods(t){let e=this.$_common.deepClone(this.goods_list);const a=t.map(t=>{let e=t.specGroup.map(t=>t.specValueName).join(\"_\");return{spec_check_list:[],basicGoodsId:t.id,goodsCode:t.code,goodsName:t.title,skuId:t.skuId,specGropName:e,unitName:t.unitName,categoryId:t.categoryId,categoryName:t.categoryName,buyerNum:1,buyerUnitPrice:.1,subtotalPrice:.1,couponAmount:0,otherAmount:0,mearchantId:\"\"}}),o=e.some(t=>t.basicGoodsId);e=o?this.$_common.unique(e.concat(a),[\"basicGoodsId\",\"skuId\"]):a;const n=e.map(t=>t.skuId);this.pricePauseSave(n,e)},specSelConfirm(t){if(!t.goodsD[0].skuId)return void this.$message.warning(\"至少选择一项\");let e=this.$_common.deepClone(this.goods_list);const a=t.goodsD.map(e=>({basicGoodsId:t.now_goods_data.id,goodsCode:t.now_goods_data.code,goodsName:t.now_goods_data.title,skuId:e.skuId,specGropName:e.spec.specGropName,unitName:e.spec.unitName,categoryId:t.now_goods_data.categoryId,categoryName:t.now_goods_data.categoryTitle,buyerNum:1,buyerUnitPrice:.1,subtotalPrice:.1,couponAmount:0,otherAmount:0,mearchantId:this.mearchantId}));e[this.goods_index].skuId||e.splice(this.goods_index,1),a.forEach(t=>{const a=e.find(e=>e.skuId===t.skuId);a||e.push(t)});const o=this.$_common.unique(e,[\"basicGoodsId\",\"skuId\"]),n=o.map(t=>t.skuId);this.pricePauseSave(n,o),this.spec_model=!1},async pricePauseSave(t,e){e=e.filter(t=>t.skuId);const{data:a}=await Object(p[\"getMoneyPauseSave\"])({skuIds:t});this.goods_list=e.map(t=>({...t,buyerUnitPrice:t.buyerUnitPrice>.1?t.buyerUnitPrice:a[t.skuId]||.1,subtotalPrice:t.subtotalPrice>.1?t.subtotalPrice:a[t.skuId]||.1})),await this.getSkuNum()},async addMoneyPauseSave(t){await Object(p[\"addMoneyPauseSave\"])({data:t})},addListGoods(){this.goods_list.push(this.$_common.deepClone(f))},editNumChange(t,e){const a=this.$_common.deepClone(this.goods_list);a[t].subtotalPrice=this.$NP.times(a[t].buyerNum||1,a[t].buyerUnitPrice),this.goods_list=a,a[t].skuId&&\"buyerNum\"===e&&this.getSkuNum()},otherSet(t,e){const a=this.$_common.deepClone(this.goods_list);a.forEach(t=>{t.basicGoodsId===e.basicGoodsId&&t.unitName===e.unitName&&(t.buyerNum=e.buyerNum,t.subtotalPrice=e.subtotalPrice,t.buyerUnitPrice=e.buyerUnitPrice)}),this.goods_list=a,this.getSkuNum()},async addPauseSave(){const t={...this.form,goodsData:this.goods_list};this.loading=!0;await Object(p[\"addPauseSave\"])({key:this.look_path,data:t});this.loading=!1,this.$message({type:\"success\",message:\"暂存成功\"}),2===this.systemType?this.$closeCurrentGoEdit(\"/SingleStore/purchase/purchaseList\"):this.$closeCurrentGoEdit(\"/Purchase/ManageP/PurchaseOrder\")},async getPauseSave(){const{data:t}=await Object(p[\"getPauseSave\"])({key:this.look_path});\"{}\"!==JSON.stringify(t)&&(this.form=t,this.goods_list=t.goodsData,this.getSkuNum())},async getPurchaseInfoById(){const{data:t}=await Object(h[\"getPurchaseInfoById\"])(this.pusrchase_id);this.form.code=t.no,this.createTime=t.createTime,this.form.shopId=t.shopId,this.form.shopName=t.shopName,this.form.supplierId=t.supplierId,this.form.supplierName=t.supplierName,this.form.buyerId=t.buyerId,this.form.buyerName=t.buyerName,this.form.operatorName=t.operatorName,this.form.purchaseAmount=t.purchaseAmount,this.form.couponAmount=t.couponAmount,this.form.otherAmount=t.otherAmount,this.form.remark=t.remark,this.auditId=t.auditId,this.auditName=t.auditName,this.auditStatus=t.auditStatus,this.auditTime=t.auditTime,this.form.warehouseId=t.warehouseId,this.form.merchantId=t.merchantId,this.form.merchantName=t.merchantName,this.form.warehouseName=t.warehouseName,this.goods_list=t.details.map(t=>({...t,skuId:t.skuId,specGropName:t.skuName})),await this.getSkuNum()},async delPauseSave(t){Object(p[\"delPauseSave\"])({key:this.look_path});t&&(this.$message({type:\"success\",message:\"清除暂存成功\"}),this.$closeCurrentGoEdit(\"/Purchase/ManageP/PurchaseOrderAdd\"))},async addPurchaseOrder(){this.form.couponAmount>this.purchaseAmount?this.$message.warning(\"优惠金额不能大于采购金额 \"):(this.form.otherAmount||(this.form.otherAmount=0),this.form.couponAmount||(this.form.couponAmount=0),this.$refs[\"form\"].validate(async t=>{if(t){const t=this.$_common.deepClone(this.goods_list).filter(t=>t.skuId>0);if(!t.length)return void this.$message.warning(\"请选择商品\");const e=t.every(t=>t.buyerNum>0);if(!e)return void this.$message.warning(\"采购数量必须大于0\");const a=t.every(t=>t.buyerUnitPrice>0);if(!a)return void this.$message.warning(\"采购单价必须大于0\");let o=t.map(t=>{let e={basicGoodsId:t.basicGoodsId,goodsCode:t.goodsCode,goodsName:t.goodsName,skuId:t.skuId,unitName:t.unitName,skuName:t.specGropName,buyerNum:t.buyerNum,buyerUnitPrice:t.buyerUnitPrice,subtotalPrice:t.subtotalPrice,couponAmount:t.couponAmount-0,otherAmount:t.otherAmount-0,categoryId:t.categoryId,categoryName:t.categoryName,otherNum:t.otherNum};return t.id&&(e.id=t.id),e});const n={...this.form,goodsData:o};if(this.goods_list.length>0){this.loading=!0;try{let t={};this.pusrchase_id?(n.deleteArray=this.del_goods_id,t=await Object(h[\"editPurchase\"])(this.pusrchase_id,n)):t=await Object(h[\"addPurchase\"])(n);this.loading=!1,this.$message({type:\"success\",message:\"提交成功\"}),await this.delPauseSave(),2===this.systemType?this.$closeCurrentGoEdit(\"/SingleStore/purchase/purchaseList\"):this.$closeCurrentGoEdit(\"/Purchase/ManageP/Merchant\")}finally{this.loading=!1}}else this.$message(\"请选择商品\");const r=o.map(t=>({skuId:t.skuId,money:t.buyerUnitPrice}));await this.addMoneyPauseSave(r)}}))},delData(t,e){e.id&&this.del_goods_id.push(e.id),1!==this.goods_list.length?this.goods_list.splice(t,1):this.$message.warning(\"必须保留一条\")},selShop(t,e){this.form.shopName=e[0].name},mearchant(){this.mearchant_show=!0},getSummaries(t){return this.$_common.getSummaries(t,[\"小计金额\",\"采购数量\"])}}},g=m,b=(a(\"83cc\"),a(\"0d36\"),a(\"2877\")),_=Object(b[\"a\"])(g,o,n,!1,null,\"00d54f12\",null);e[\"default\"]=_.exports}}]);","extractedComments":[]}
|