| 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-24f20cfa\",\"chunk-5785e062\",\"chunk-94bd7228\"],{\"1a08\":function(t,e,a){\"use strict\";a(\"2427\")},2427:function(t,e,a){},\"2cb5\":function(t,e,a){\"use strict\";a(\"6611\")},\"3eaa\":function(t,e,a){\"use strict\";a(\"ce9d\")},\"423f\":function(t,e,a){\"use strict\";a(\"5bd6\")},\"478b\":function(t,e,a){\"use strict\";a.r(e),a.d(e,\"getWarehouseInfo\",(function(){return o})),a.d(e,\"getAllWarehouse\",(function(){return r})),a.d(e,\"enableWarehouse\",(function(){return i})),a.d(e,\"updateWarehouse\",(function(){return l})),a.d(e,\"deleteWarehouse\",(function(){return s})),a.d(e,\"addWarehouse\",(function(){return c})),a.d(e,\"addWarehouseBeginning\",(function(){return d})),a.d(e,\"stockaddLogistics\",(function(){return u})),a.d(e,\"getAllSaleOut\",(function(){return f})),a.d(e,\"exportGetAllSaleOut\",(function(){return p})),a.d(e,\"getSaleOutInfo\",(function(){return m})),a.d(e,\"getSaleOutInfoT\",(function(){return h})),a.d(e,\"searchAllSaleOut\",(function(){return g})),a.d(e,\"updateSaleOutStatus\",(function(){return b})),a.d(e,\"saveOutInventory\",(function(){return y})),a.d(e,\"statisticsAllSaleOut\",(function(){return v})),a.d(e,\"rejectInventory\",(function(){return S})),a.d(e,\"deleteDetailByInventoryInId\",(function(){return _})),a.d(e,\"searchAllPurchaseIn\",(function(){return k})),a.d(e,\"getPurchaseInInfo\",(function(){return I})),a.d(e,\"getPurchaseInInfoT\",(function(){return A})),a.d(e,\"getAllPurchaseIn\",(function(){return C})),a.d(e,\"exportsGetAllPurchaseIn\",(function(){return O})),a.d(e,\"updatePurchaseInStatus\",(function(){return w})),a.d(e,\"statisticsAllPurchaseIn\",(function(){return j})),a.d(e,\"getInventoryAll\",(function(){return x})),a.d(e,\"exportGetInventoryAll\",(function(){return R})),a.d(e,\"getInventoryDetailsAll\",(function(){return P})),a.d(e,\"exportGetInventoryDetailsAll\",(function(){return F})),a.d(e,\"searchAllInventoryDetails\",(function(){return T})),a.d(e,\"exportSearchAllInventoryDetails\",(function(){return $})),a.d(e,\"getAllBatch\",(function(){return N})),a.d(e,\"searchAllInventoryBatch\",(function(){return D})),a.d(e,\"getStocktakingInfo\",(function(){return B})),a.d(e,\"updateStocktaking\",(function(){return q})),a.d(e,\"auditStocktaking\",(function(){return z})),a.d(e,\"getAllStocktaking\",(function(){return L})),a.d(e,\"exportGetAllStocktaking\",(function(){return E})),a.d(e,\"searchAllStocktaking\",(function(){return M})),a.d(e,\"exportSearchAllStocktaking\",(function(){return W})),a.d(e,\"addStocktaking\",(function(){return G})),a.d(e,\"inventoryStatistics\",(function(){return U})),a.d(e,\"exportsInventoryStatistics\",(function(){return J})),a.d(e,\"searchInventoryStatistics\",(function(){return V})),a.d(e,\"StockGetAllPurchase\",(function(){return H})),a.d(e,\"PurchaseInGetAllPurchaseOut\",(function(){return Q})),a.d(e,\"getWarehouseInventory\",(function(){return K})),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 nt})),a.d(e,\"searchAllocate\",(function(){return ot})),a.d(e,\"getBatchByIds\",(function(){return rt})),a.d(e,\"getSkuNum\",(function(){return it})),a.d(e,\"getMasterSkuNum\",(function(){return lt})),a.d(e,\"addReservoir\",(function(){return st})),a.d(e,\"getReservoirInfo\",(function(){return ct})),a.d(e,\"getAllReservoir\",(function(){return dt})),a.d(e,\"getListReservoir\",(function(){return ut})),a.d(e,\"enableReservoir\",(function(){return ft})),a.d(e,\"updateReservoir\",(function(){return pt})),a.d(e,\"deleteReservoir\",(function(){return mt})),a.d(e,\"getAllStorageLocation\",(function(){return ht})),a.d(e,\"addStorageLocation\",(function(){return gt})),a.d(e,\"getStorageLocationInfo\",(function(){return bt})),a.d(e,\"enableStorageLocation\",(function(){return yt})),a.d(e,\"updateStorageLocation\",(function(){return vt})),a.d(e,\"getAreaDateBySkuId\",(function(){return St})),a.d(e,\"addReportLoss\",(function(){return _t})),a.d(e,\"getAllReportLoss\",(function(){return kt})),a.d(e,\"getReportLossInfo\",(function(){return It})),a.d(e,\"auditReportLoss\",(function(){return At})),a.d(e,\"deleteReportLoss\",(function(){return Ct})),a.d(e,\"countPurchaseCost\",(function(){return Ot})),a.d(e,\"exportgetInventoryByWarehouseId\",(function(){return wt})),a.d(e,\"exportgetAllAllocate\",(function(){return jt})),a.d(e,\"getPickingInfo\",(function(){return xt})),a.d(e,\"addPicking\",(function(){return Rt})),a.d(e,\"getAllPicking\",(function(){return Pt})),a.d(e,\"getAllPickingGoodsDetail\",(function(){return Ft}));var n=a(\"b775\");function o(t,e){return Object(n[\"default\"])({url:\"/Stock/Warehouse/getWarehouseInfo/\"+t,method:\"get\",data:e})}function r(t){return Object(n[\"default\"])({url:\"/Stock/Warehouse/getAllWarehouse\",method:\"post\",data:t})}function i(t){return Object(n[\"default\"])({url:\"/Stock/Warehouse/enableWarehouse\",method:\"post\",data:t})}function l(t,e){return Object(n[\"default\"])({url:\"/Stock/Warehouse/updateWarehouse/\"+t,method:\"put\",data:e})}function s(t,e){return Object(n[\"default\"])({url:\"/Stock/Warehouse/deleteWarehouse/\"+t,method:\"delete\",data:e})}function c(t){return Object(n[\"default\"])({url:\"/Stock/Warehouse/addWarehouse\",method:\"post\",data:t})}function d(t){return Object(n[\"default\"])({url:\"/Stock/Warehouse/addWarehouseBeginning\",method:\"post\",data:t})}function u(t){return Object(n[\"default\"])({url:\"/Stock/InventoryOut/addLogistics\",method:\"post\",data:t})}function f(t){return Object(n[\"default\"])({url:\"/Stock/InventoryOut/getAllInventoryOut\",method:\"post\",data:t})}function p(t){return Object(n[\"default\"])({url:\"/Stock/InventoryOut/getAllInventoryOut\",method:\"post\",responseType:\"blob\",data:t})}function m(t,e){return Object(n[\"default\"])({url:\"/Stock/InventoryOut/getInventoryOutInfo/\"+t,method:\"get\",data:e})}function h(t){return Object(n[\"default\"])({url:\"/Stock/InventoryOut/getInventoryOutInfo\",method:\"post\",data:t})}function g(t){return Object(n[\"default\"])({url:\"/Stock/InventoryOut/searchAllInventoryOut\",method:\"post\",data:t})}function b(t){return Object(n[\"default\"])({url:\"/Stock/InventoryOut/updateInventoryOutStatus\",method:\"post\",data:t})}function y(t,e){return Object(n[\"default\"])({url:\"/Stock/InventoryOut/saveOutInventory/\"+t,method:\"put\",data:e})}function v(t){return Object(n[\"default\"])({url:\"/Stock/InventoryOut/statisticsAllInventoryOut\",method:\"post\",data:t})}function S(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/rejectInventory\",method:\"post\",data:t})}function _(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/deleteDetailByInventoryInId\",method:\"post\",data:t})}function k(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/searchAllInventoryIn\",method:\"post\",data:t})}function I(t,e){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/getInventoryInInfo/\"+t,method:\"put\",data:e})}function A(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/getInventoryInInfo\",method:\"put\",data:t})}function C(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/getAllInventoryIn\",method:\"post\",data:t})}function O(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/getAllInventoryIn\",method:\"post\",responseType:\"blob\",data:t})}function w(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/updateInventoryInStatus\",method:\"post\",data:t})}function j(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/statisticsAllInventoryIn\",method:\"post\",data:t})}function x(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/getInventoryAll\",method:\"post\",data:t})}function R(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/getInventoryAll\",responseType:\"blob\",method:\"post\",data:t})}function P(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/getInventoryDetailsAll\",method:\"post\",data:t})}function F(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/getInventoryDetailsAll\",responseType:\"blob\",method:\"post\",data:t})}function T(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/searchAllInventoryDetails\",method:\"post\",data:t})}function $(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/searchAllInventoryDetails\",responseType:\"blob\",method:\"post\",data:t})}function N(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/getAllBatch\",method:\"post\",data:t})}function D(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/searchAllInventoryBatch\",method:\"post\",data:t})}function B(t,e){return Object(n[\"default\"])({url:\"/Stock/Stocktaking/getStocktakingInfo/\"+t,method:\"get\",data:e})}function q(t,e){return Object(n[\"default\"])({url:\"/Stock/Stocktaking/updateStocktaking/\"+t,method:\"put\",data:e})}function z(t,e){return Object(n[\"default\"])({url:\"/Stock/Stocktaking/auditStocktaking/\"+t,method:\"put\",data:e})}function L(t){return Object(n[\"default\"])({url:\"/Stock/Stocktaking/getAllStocktaking\",method:\"post\",data:t})}function E(t){return Object(n[\"default\"])({url:\"/Stock/Stocktaking/getAllStocktaking\",responseType:\"blob\",method:\"post\",data:t})}function M(t){return Object(n[\"default\"])({url:\"/Stock/Stocktaking/searchAllStocktaking\",method:\"post\",data:t})}function W(t){return Object(n[\"default\"])({url:\"/Stock/Stocktaking/searchAllStocktaking\",method:\"post\",responseType:\"blob\",data:t})}function G(t){return Object(n[\"default\"])({url:\"/Stock/Stocktaking/addStocktaking\",method:\"post\",data:t})}function U(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/inventoryStatistics\",method:\"post\",data:t})}function J(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/inventoryStatistics\",method:\"post\",responseType:\"blob\",data:t})}function V(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/searchInventoryStatistics\",method:\"post\",data:t})}function H(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/getAllPurchaseIn\",method:\"post\",data:t})}function Q(t){return Object(n[\"default\"])({url:\"/Stock/InventoryIn/getAllInventoryInByAudit\",method:\"post\",data:t})}function K(t,e){return Object(n[\"default\"])({url:\"/Stock/Inventory/getWarehouseInventory/\"+t,method:\"get\",data:e})}function X(t){return Object(n[\"default\"])({url:\"/Stock/Allocate/addAllocate\",method:\"post\",data:t})}function Y(t){return Object(n[\"default\"])({url:\"/stock/Inventory/getInventoryByWarehouseId\",method:\"post\",data:t})}function Z(t){return Object(n[\"default\"])({url:\"/Stock/Allocate/getAllAllocate\",method:\"post\",data:t})}function tt(t,e){return Object(n[\"default\"])({url:\"/Stock/Allocate/deleteAllocate/\"+t,method:\"delete\",data:e})}function et(t,e){return Object(n[\"default\"])({url:\"/Stock/Allocate/getAllocateInfo/\"+t,method:\"get\",data:e})}function at(t,e){return Object(n[\"default\"])({url:\"/Stock/Allocate/updateAllocate/\"+t,method:\"post\",data:e})}function nt(t,e){return Object(n[\"default\"])({url:\"/Stock/Allocate/auditAllocate/\"+t,method:\"put\",data:e})}function ot(t){return Object(n[\"default\"])({url:\"/Stock/Allocate/searchAllocate\",method:\"post\",data:t})}function rt(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/getBatchByIds\",method:\"post\",data:t})}function it(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/getSkuNum\",method:\"post\",data:t})}function lt(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/getMasterSkuNum\",method:\"post\",data:t})}function st(t){return Object(n[\"default\"])({url:\"/Stock/ReservoirArea/addReservoir\",method:\"post\",data:t})}function ct(t,e){return Object(n[\"default\"])({url:\"/Stock/ReservoirArea/getReservoirInfo/\"+t,method:\"get\",data:e})}function dt(t){return Object(n[\"default\"])({url:\"/Stock/ReservoirArea/getAllReservoir\",method:\"post\",data:t})}function ut(t){return Object(n[\"default\"])({url:\"/Stock/ReservoirArea/getListReservoir\",method:\"post\",data:t})}function ft(t,e){return Object(n[\"default\"])({url:\"/Stock/ReservoirArea/enableReservoir/\"+t,method:\"put\",data:e})}function pt(t,e){return Object(n[\"default\"])({url:\"/Stock/ReservoirArea/updateReservoir/\"+t,method:\"put\",data:e})}function mt(t,e){return Object(n[\"default\"])({url:\"/Stock/ReservoirArea/deleteReservoir/\"+t,method:\"get\",data:e})}function ht(t){return Object(n[\"default\"])({url:\"/Stock/StorageLocation/getAllStorageLocation\",method:\"post\",data:t})}function gt(t){return Object(n[\"default\"])({url:\"/Stock/StorageLocation/addStorageLocation\",method:\"post\",data:t})}function bt(t,e){return Object(n[\"default\"])({url:\"/Stock/StorageLocation/getStorageLocationInfo/\"+t,method:\"post\",data:e})}function yt(t,e){return Object(n[\"default\"])({url:\"/Stock/StorageLocation/enableStorageLocation/\"+t,method:\"post\",data:e})}function vt(t,e){return Object(n[\"default\"])({url:\"/Stock/StorageLocation/updateStorageLocation/\"+t,method:\"post\",data:e})}function St(t){return Object(n[\"default\"])({url:\"/Stock/Inventory/getAreaDateBySkuId\",method:\"post\",data:t})}function _t(t){return Object(n[\"default\"])({url:\"/Stock/ReportLoss/addReportLoss\",method:\"post\",data:t})}function kt(t){return Object(n[\"default\"])({url:\"/Stock/ReportLoss/getAllReportLoss\",method:\"post\",data:t})}function It(t,e){return Object(n[\"default\"])({url:\"/Stock/ReportLoss/getReportLossInfo/\"+t,method:\"get\",data:e})}function At(t,e){return Object(n[\"default\"])({url:\"/Stock/ReportLoss/auditReportLoss/\"+t,method:\"put\",data:e})}function Ct(t,e){return Object(n[\"default\"])({url:\"/Stock/ReportLoss/deleteReportLoss/\"+t,method:\"delete\",data:e})}function Ot(t){return Object(n[\"default\"])({url:\"Stock/InventoryIn/countPurchaseCost\",method:\"post\",data:t})}function wt(t){return Object(n[\"default\"])({url:\"stock/Inventory/getInventoryByWarehouseId\",responseType:\"blob\",method:\"post\",data:t})}function jt(t){return Object(n[\"default\"])({url:\"Stock/Allocate/getAllAllocate\",responseType:\"blob\",method:\"post\",data:t})}function xt(t,e){return Object(n[\"default\"])({url:\"Stock/Picking/getPickingInfo/\"+t,method:\"post\",data:e})}function Rt(t){return Object(n[\"default\"])({url:\"Stock/Picking/addPicking\",method:\"post\",data:t})}function Pt(t){return Object(n[\"default\"])({url:\"Stock/Picking/getAllPicking\",method:\"post\",data:t})}function Ft(t){return Object(n[\"default\"])({url:\"Stock/Picking/getAllPickingGoodsDetail\",method:\"post\",data:t})}},\"55d15\":function(t,e,a){\"use strict\";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"div\",[a(\"el-drawer\",{staticClass:\"edit-drawer\",attrs:{title:t.isEdit?\"修改成员\":\"新增成员\",size:\"40%\",visible:t.visible,direction:\"rtl\",modal:t.modal,\"wrapper-closable\":!1},on:{\"update:visible\":function(e){t.visible=e},close:t.close}},[t.isEdit?t._e():a(\"div\",{staticClass:\"page-tip-div\",staticStyle:{\"margin-top\":\"0\"}},[a(\"span\",[t._v(\"温馨提示:\")]),a(\"span\",[t._v(\" 新员工初始密码为 \"),a(\"span\",{staticStyle:{color:\"#ff4400\",\"font-weight\":\"bold\"}},[t._v(\"88888888\")]),t._v(\" ,登录后可修改密码。 \")])]),a(\"el-form\",{ref:\"form\",attrs:{rules:t.rules,size:\"small\",model:t.form,\"label-width\":\"120px\"}},[a(\"el-form-item\",{attrs:{label:\"姓名\",prop:\"staffName\"}},[a(\"el-input\",{attrs:{placeholder:\"请输入姓名\"},model:{value:t.form.staffName,callback:function(e){t.$set(t.form,\"staffName\",e)},expression:\"form.staffName\"}})],1),a(\"el-form-item\",{attrs:{label:\"工号\",prop:\"staffCode\"}},[a(\"el-input\",{attrs:{disabled:\"\",placeholder:\"自动生成\"},model:{value:t.form.staffCode,callback:function(e){t.$set(t.form,\"staffCode\",e)},expression:\"form.staffCode\"}})],1),a(\"el-form-item\",{attrs:{label:\"手机\",prop:\"mobile\"}},[a(\"el-input\",{attrs:{placeholder:\"请输入手机号\",\"max-length\":\"11\",disabled:t.id},model:{value:t.form.mobile,callback:function(e){t.$set(t.form,\"mobile\",e)},expression:\"form.mobile\"}})],1),a(\"el-form-item\",{attrs:{label:\"性别\",prop:\"sex\"}},[a(\"el-select\",{attrs:{placeholder:\"性别\"},model:{value:t.form.sex,callback:function(e){t.$set(t.form,\"sex\",e)},expression:\"form.sex\"}},[a(\"el-option\",{attrs:{label:\"男\",value:5}}),a(\"el-option\",{attrs:{label:\"女\",value:4}})],1)],1),a(\"el-form-item\",{attrs:{label:\"生日\",prop:\"age\"}},[a(\"el-date-picker\",{attrs:{type:\"date\",placeholder:\"选择生日\",\"value-format\":\"timestamp\",\"default-value\":\"1990-01-01\"},model:{value:t.form.age,callback:function(e){t.$set(t.form,\"age\",e)},expression:\"form.age\"}})],1),a(\"el-form-item\",{attrs:{label:\"学历\",prop:\"education\"}},[a(\"el-select\",{attrs:{placeholder:\"学历\"},model:{value:t.form.education,callback:function(e){t.$set(t.form,\"education\",e)},expression:\"form.education\"}},t._l(t.education_list,(function(t,e){return a(\"el-option\",{key:e,attrs:{label:t.label,value:t.value}})})),1)],1),a(\"el-form-item\",{attrs:{label:\"部门\",prop:\"departmentId\"}},[a(\"span\",{staticStyle:{width:\"265px\",display:\"inline-block\"}},[a(\"DepartmentSel\",{attrs:{\"is-show-add\":!0},on:{change:t.departmentChange},model:{value:t.department,callback:function(e){t.department=e},expression:\"department\"}})],1),1===t.systemType?a(\"el-button\",{attrs:{size:\"mini\",type:\"text\"},on:{click:function(e){t.add_department=!0}}},[t._v(\" 【新建部门】 \")]):t._e()],1),a(\"el-form-item\",{attrs:{label:\"角色\",prop:\"roleId\"}},[a(\"span\",{staticStyle:{width:\"265px\",display:\"inline-block\"}},[a(\"RoleSelect\",{attrs:{\"is-show-add\":!0},on:{change:t.roleChange},model:{value:t.role,callback:function(e){t.role=e},expression:\"role\"}})],1),a(\"el-button\",{staticClass:\"add-role\",attrs:{size:\"mini\",type:\"text\"},on:{click:function(e){t.add_position=!0}}},[t._v(\" 【新增角色】 \")])],1),a(\"el-form-item\",{attrs:{label:\"邮箱\",prop:\"email\"}},[a(\"el-input\",{attrs:{placeholder:\"请输入邮箱\"},model:{value:t.form.email,callback:function(e){t.$set(t.form,\"email\",e)},expression:\"form.email\"}})],1),a(\"el-form-item\",{attrs:{label:\"数据域权限\"}},[a(\"el-radio-group\",{model:{value:t.form.dataField.dataField,callback:function(e){t.$set(t.form.dataField,\"dataField\",e)},expression:\"form.dataField.dataField\"}},[a(\"el-radio\",{attrs:{label:1}},[t._v(\"本人\")]),a(\"el-radio\",{attrs:{label:2}},[t._v(\"用户\")]),a(\"el-radio\",{attrs:{label:3}},[t._v(\"所有\")])],1),2===t.form.dataField.dataField?a(\"div\",[t._l(t.staffName_arr,(function(e,n){return a(\"el-tag\",{key:n,attrs:{closable:\"\"},on:{close:function(e){return t.delStaff(n)}}},[t._v(\" \"+t._s(e.staffName)+\" \")])})),a(\"el-button\",{attrs:{size:\"mini\",type:\"primary\",icon:\"el-icon-plus\"},on:{click:function(e){t.staff_show=!0}}},[t._v(\" 用户 \")])],2):t._e()],1),1===t.systemType?a(\"el-form-item\",{attrs:{label:\"店铺权限\"}},[t._l(t.shop_arr,(function(e,n){return a(\"el-tag\",{key:n,attrs:{type:\"primary\",closable:\"\"},on:{close:function(e){return t.delShop(n)}}},[t._v(\" \"+t._s(e.name)+\" \")])})),a(\"el-button\",{attrs:{size:\"small\",type:\"primary\"},on:{click:function(e){t.show_shop=!0}}},[t._v(\" 选择商铺 \")]),a(\"el-button\",{attrs:{size:\"mini\",type:\"text\"},on:{click:function(e){return t.goShop()}}},[t._v(\" 【新建商铺】 \")])],2):t._e(),a(\"el-form-item\",{staticStyle:{\"text-align\":\"right\",\"padding-right\":\"10px\"}},[a(\"el-button\",{attrs:{type:\"primary\"},on:{click:t.confirm}},[t._v(\"确 定\")]),a(\"el-button\",{on:{click:t.close}},[t._v(\"取 消\")])],1)],1)],1),t.show_shop?a(\"GoodsChooseShop\",{attrs:{\"dialog-visible\":t.show_shop,\"is-show-add\":!0,modal:!1},on:{close:function(e){t.show_shop=!1},confirm:t.selShop}}):t._e(),t.staff_show?a(\"staffListModal\",{attrs:{modal:!1,\"is-show\":t.staff_show},on:{cancel:function(e){t.staff_show=!1},confirm:t.staffSel}}):t._e(),t.add_department?a(\"AddDepartment\",{attrs:{modal:!1,visible:t.add_department},on:{close:function(e){t.add_department=!1}}}):t._e(),a(\"el-dialog\",{staticClass:\"edit-drawer\",attrs:{title:\"新增角色\",width:\"35%\",visible:t.add_position,direction:\"rtl\",modal:!1,\"close-on-press-escape\":!1,\"close-on-click-modal\":!1},on:{\"update:visible\":function(e){t.add_position=e},close:t.drawerClose}},[t.add_position?a(\"AddPosition\",{on:{confirm:function(e){t.add_position=!1}}}):t._e()],1)],1)},o=[],r=a(\"b53c\"),i=a(\"d8ab\"),l=a(\"d2bc\"),s=a(\"7a21\"),c=a(\"e75f\"),d=a(\"d4c8\"),u=a(\"64f1\"),f=a(\"2f62\"),p={name:\"AddStaff\",components:{DepartmentSel:r[\"default\"],RoleSelect:i[\"default\"],GoodsChooseShop:l[\"default\"],staffListModal:s[\"default\"],AddDepartment:c[\"default\"],AddPosition:d[\"default\"]},props:{visible:{type:Boolean,default:!1},isEdit:{type:Boolean,default:!1},id:{type:[Number,String],default:0},modal:{type:Boolean,default:!0}},data(){return{add_position:!1,shop_arr:[],staffName:\"\",staff_show:!1,show_shop:!1,add_department:!1,customer_id:\"\",role:[],department:[],form:{departmentId:\"\",staffName:\"\",roleId:\"\",staffIdArr:[],mobile:\"\",email:\"\",staffCode:\"\",sex:\"\",age:\"\",education:\"\",departmentPidPath:\"\",rolePidPath:\"\",dataField:{dataField:1,staffIds:[],shopIds:[]}},education_list:[{label:\"大专以下\",value:1},{label:\"大专\",value:2},{label:\"本科\",value:3},{label:\"研究生\",value:4},{label:\"硕士\",value:5},{label:\"博士\",value:6}],Department_data:[],staffName_arr:[],rules:{staffName:[{required:!0,message:\"请输入部门名称\",trigger:\"blur\"}],departmentId:[{required:!0,message:\"请选择部门\",trigger:\"change\"}],roleId:[{required:!0,message:\"请选择角色\",trigger:\"change\"}],mobile:[{required:!0,message:\"请输入手机\",trigger:\"blur\"}],email:[{type:\"email\",message:\"请输入正确的邮箱地址\",trigger:[\"blur\",\"change\"]}]}}},computed:{...Object(f[\"c\"])({storeData:\"MUser/storeData\"})},created(){this.id&&this.getStaffInfo()},methods:{goShop(){this.close(),this.$emit(\"goShop\"),this.$router.push(\"/SystemSettings/liansuoguanli/AddShop\")},drawerClose(){this.add_position=!1},selShop(t){const e=t.map(t=>({id:t.id,name:t.name}));this.shop_arr=this.$_common.unique(this.shop_arr.concat(e),[\"id\"])},delShop(t){this.shop_arr.splice(t,1)},staffSel(t){const e=t.map(t=>({id:t.id,staffName:t.staffName}));this.staffName_arr=this.$_common.unique(this.staffName_arr.concat(e),[\"id\"])},delStaff(t){this.staffName_arr.splice(t,1)},close(){this.$emit(\"close\")},departmentChange(t){this.form.departmentId=t.length?t[t.length-1]:\"\",this.form.departmentPidPath=t.join(\",\")},roleChange(t){this.form.roleId=t.length?t[t.length-1]:\"\",this.form.rolePidPath=t.join(\",\")},async getStaffInfo(){if(!this.id)return;const{data:t}=await Object(u[\"getStaffInfo\"])(this.id);this.form={...t,departmentPidPath:t.extend.departmentPidPath,rolePidPath:t.extend.rolePidPath,age:1e3*t.age},t.extend.rolePidPath&&(this.role=t.extend.rolePidPath.split(\",\").map(t=>parseInt(t))),this.department=t.extend.departmentPidPath.split(\",\").map(t=>parseInt(t));let e=[];t.dataField.shopIds.forEach((a,n)=>{e.push({id:a,name:t.dataField.shopNames[n]})}),this.shop_arr=e;let a=[];t.dataField.staffIds.forEach((e,n)=>{a.push({id:e,staffName:t.dataField.staffNames[n]})}),this.staffName_arr=a},async confirm(){this.form.staffName.trim()?this.$refs.form.validate(async t=>{if(t){let t={};this.form.dataField.staffIds=this.staffName_arr.map(t=>t.id),1===this.systemType?this.form.dataField.shopIds=this.shop_arr.map(t=>t.id):this.form.dataField.shopIds=[this.storeData.id];const e={departmentId:this.form.departmentId,staffName:this.form.staffName,roleId:this.form.roleId,mobile:this.form.mobile,email:this.form.email,staffCode:this.form.staffCode,sex:this.form.sex,age:this.form.age/1e3,education:this.form.education,departmentPidPath:this.form.departmentPidPath,rolePidPath:this.form.rolePidPath,dataField:this.form.dataField};t=this.id?await Object(u[\"updateStaff\"])(this.id,e):await Object(u[\"addStaff\"])(e);const a=t;this.id?this.$message({message:\"提交成功\",type:\"success\"}):this.$message({message:a.data,type:\"success\"}),this.close(),this.$emit(\"confirm\")}}):this.$message.warning(\"姓名不能为空\")}}},m=p,h=(a(\"3eaa\"),a(\"2877\")),g=Object(h[\"a\"])(m,n,o,!1,null,\"9ea90d02\",null);e[\"default\"]=g.exports},\"5bd6\":function(t,e,a){},6611:function(t,e,a){},6791:function(t,e,a){},\"7a21\":function(t,e,a){\"use strict\";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"el-dialog\",{attrs:{modal:t.modal,title:\"员工列表\",visible:t.isShow,width:\"50%\",\"close-on-press-escape\":!1,\"close-on-click-modal\":!1},on:{close:t.cancel}},[a(\"div\",{staticClass:\"search-wrp\"},[a(\"el-input\",{staticStyle:{width:\"240px\"},attrs:{size:\"small\",clearable:\"\",placeholder:\"请输入名称/手机号\"},on:{clear:t.searchClick},model:{value:t.keywords,callback:function(e){t.keywords=e},expression:\"keywords\"}},[a(\"el-button\",{attrs:{slot:\"append\",type:\"primary\",icon:\"el-icon-search\"},on:{click:t.searchClick},slot:\"append\"})],1),a(\"DepartmentSel\",{staticStyle:{width:\"240px\",display:\"inline-block\",\"margin-left\":\"10px\"},attrs:{clearable:\"\"},on:{change:t.departmentChange},model:{value:t.departmentPidPath,callback:function(e){t.departmentPidPath=e},expression:\"departmentPidPath\"}})],1),a(\"el-table\",{directives:[{name:\"loading\",rawName:\"v-loading\",value:t.loading,expression:\"loading\"}],ref:\"staffRef\",attrs:{data:t.tabelData},on:{\"row-dblclick\":t.dbSelect,\"selection-change\":t.handleSelectionChange}},[t.isCheck?a(\"el-table-column\",{attrs:{type:\"selection\",width:\"55\"}}):t._e(),a(\"el-table-column\",{attrs:{prop:\"staffName\",label:\"姓名\"}}),a(\"el-table-column\",{attrs:{prop:\"departmentName\",label:\"部门\"}}),a(\"el-table-column\",{attrs:{prop:\"mobile\",label:\"手机号\"}}),a(\"el-table-column\",{attrs:{label:\"选择\",width:\"100\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"el-button\",{attrs:{size:\"mini\",icon:\"el-icon-check\"},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)},o=[],r=a(\"3c48\"),i=a(\"b53c\"),l=a(\"64f1\"),s=(a(\"d099\"),{name:\"ClientListModal\",components:{FooterPage:r[\"default\"],DepartmentSel:i[\"default\"]},props:{isShow:{type:Boolean,default:!1},isCheck:{type:Boolean,default:!0},isserch:{type:Boolean,default:!0},modal:{type:Boolean,default:!0}},data(){return{search_data:[],choose_data:[],tabelData:[],pre_page:10,page:1,selectedIndex:null,keywords:\"\",departmentPidPath:[],departmentId:\"\",total:0,loading:!1,pageLayout:\"total, prev, pager, next\",selectedClient:{},row_id:{}}},created(){this.getList()},methods:{async getList(){this.loading=!0;const{data:t,pageTotal:e}=await Object(l[\"getAllStaff\"])({page:this.page,pageSize:this.pre_page,deleteStatus:5,keyword:this.keywords,departmentId:this.departmentId});this.loading=!1;for(let a=0;a<t.length;a++){const e=this.choose_data.find(e=>e.id===t[a].id);e&&this.$nextTick(()=>{t[a]=e,this.$refs.staffRef.toggleRowSelection(t[a],!0)})}this.tabelData=t,this.total=e},searchClick(){this.page=1,this.getList()},dbSelect(t){this.isserch&&(this.$emit(\"confirm\",[{...t}]),this.cancel()),this.row_id=t},departmentChange(t){this.departmentId=t[t.length-1],this.departmentPidPath=t.join(\",\"),this.pageChange(1)},confirm(){this.$emit(\"confirm\",this.choose_data,[{...this.row_id}]),this.cancel()},cancel(){this.$emit(\"cancel\")},pageChange(t){this.page=t,this.getList()},sizeChange(t){this.pre_page=t,this.pageChange(1)},handleSelectionChange(t){this.choose_data.length?this.choose_data=this.$_common.unique(this.choose_data.concat(t),[\"id\"]):this.choose_data=t}}}),c=s,d=(a(\"1a08\"),a(\"2877\")),u=Object(d[\"a\"])(c,n,o,!1,null,\"7909e540\",null);e[\"default\"]=u.exports},\"85a6\":function(t,e,a){\"use strict\";a(\"6791\")},\"876e\":function(t,e,a){\"use strict\";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"el-dialog\",{attrs:{title:(t.isEdit?\"编辑\":\"新增\")+\"客户类型\",visible:t.isShow,width:\"40%\",modal:t.modal,\"close-on-press-escape\":!1,\"close-on-click-modal\":!1},on:{\"update:visible\":function(e){t.isShow=e},close:t.cancel}},[a(\"el-form\",{ref:\"add_form\",attrs:{model:t.add_form,rules:t.rules,\"label-width\":\"100px\"}},[a(\"el-form-item\",{attrs:{label:\"客户类型:\",prop:\"name\"}},[a(\"el-input\",{attrs:{placeholder:\"请输入客户类型\"},model:{value:t.add_form.name,callback:function(e){t.$set(t.add_form,\"name\",e)},expression:\"add_form.name\"}})],1),a(\"el-form-item\",{attrs:{label:\"是否默认:\",prop:\"defaultStatus\"}},[a(\"el-switch\",{attrs:{\"active-value\":5,\"inactive-value\":4},model:{value:t.add_form.defaultStatus,callback:function(e){t.$set(t.add_form,\"defaultStatus\",e)},expression:\"add_form.defaultStatus\"}})],1),a(\"el-form-item\",{attrs:{label:\"是否禁用:\",prop:\"enableStatus\"}},[a(\"el-radio-group\",{model:{value:t.add_form.enableStatus,callback:function(e){t.$set(t.add_form,\"enableStatus\",e)},expression:\"add_form.enableStatus\"}},[a(\"el-radio\",{attrs:{label:4}},[t._v(\"是\")]),a(\"el-radio\",{attrs:{label:5}},[t._v(\"否\")])],1)],1),a(\"el-form-item\",{attrs:{label:\"业务模式:\",prop:\"modelType\"}},[a(\"el-checkbox-group\",{model:{value:t.add_form.modelType,callback:function(e){t.$set(t.add_form,\"modelType\",e)},expression:\"add_form.modelType\"}},[a(\"el-checkbox\",{attrs:{label:\"1\"}},[t._v(\"B2C模式\")]),a(\"el-checkbox\",{attrs:{label:\"2\"}},[t._v(\"B2B模式\")]),a(\"el-checkbox\",{attrs:{label:\"3\"}},[t._v(\"多商户模式\")])],1)],1)],1),a(\"span\",{staticClass:\"dialog-footer\",attrs:{slot:\"footer\"},slot:\"footer\"},[a(\"el-button\",{on:{click:t.cancel}},[t._v(\"取 消\")]),a(\"el-button\",{attrs:{type:\"primary\"},on:{click:t.addData}},[t._v(\"确 定\")])],1)],1)},o=[],r=a(\"d8dd\"),i={name:\"CutomerTypeAdd\",props:{isEdit:{type:Boolean,default:!1},isShow:{type:Boolean,default:!1},typeId:{type:[Number,String],default:\"\"},modal:{type:Boolean,default:!0},form:{type:Object,default:()=>({name:\"\",defaultStatus:4,enableStatus:5,modelType:[]})}},data(){return{rules:{name:[{required:!0,message:\"请输入客户类型\",trigger:\"blur\"}],modelType:[{type:\"array\",required:!0,message:\"请选择业务模式\",trigger:\"change\"}]},add_form:{name:\"\",defaultStatus:4,enableStatus:5,modelType:[]}}},watch:{form(t){this.add_form=t}},created(){this.add_form=this.form,console.log(this.form)},methods:{cancel(){this.$emit(\"cancel\")},async addData(){this.add_form.name.trim()?this.$refs.add_form.validate(async t=>{if(t){let t={};const e={...this.add_form,modelType:this.add_form.modelType.length?this.add_form.modelType.join(\",\"):\"\"};t=this.isEdit?await Object(r[\"editCustomerSource\"])(this.typeId,e):await Object(r[\"addCustomerSource\"])(e);this.cancel(),this.$emit(\"confirm\")}}):this.$message.warning(\"客户类型不能为空\")}}},l=i,s=a(\"2877\"),c=Object(s[\"a\"])(l,n,o,!1,null,\"6a8a9b40\",null);e[\"default\"]=c.exports},aff9:function(t,e,a){\"use strict\";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"Container\",[a(\"div\",{attrs:{slot:\"left\"},slot:\"left\"},[a(\"el-form\",{staticStyle:{\"margin-bottom\":\"0\"},attrs:{size:\"small\",inline:\"\"}},[a(\"el-form-item\",[a(\"el-input\",{staticStyle:{width:\"220px\"},attrs:{clearable:\"\",placeholder:\"客户姓名/手机号\"},on:{clear:function(e){return t.pageChange(1)}},nativeOn:{keyup:function(e){return!e.type.indexOf(\"key\")&&t._k(e.keyCode,\"enter\",13,e.key,\"Enter\")?null:t.pageChange(1)}},model:{value:t.query_form.keyword,callback:function(e){t.$set(t.query_form,\"keyword\",e)},expression:\"query_form.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-form-item\",[a(\"el-select\",{staticStyle:{width:\"150px\"},attrs:{clearable:\"\",placeholder:\"选择业务员\"},on:{change:function(e){return t.pageChange(1)}},model:{value:t.query_form.salesManId,callback:function(e){t.$set(t.query_form,\"salesManId\",e)},expression:\"query_form.salesManId\"}},t._l(t.staff_list,(function(t,e){return a(\"el-option\",{key:e,attrs:{label:t.staffName,value:t.id}})})),1)],1),a(\"el-form-item\",[a(\"SelectShop\",{attrs:{clearable:!0,placeholder:\"所属店铺\",width:\"150\"},on:{clear:t.delShop,change:t.selShop},model:{value:t.query_form.shopId,callback:function(e){t.$set(t.query_form,\"shopId\",e)},expression:\"query_form.shopId\"}})],1),a(\"el-form-item\",[a(\"RegionSelect\",{attrs:{placeholder:\"所属区域\",width:\"150\"},on:{change:t.regionChange},model:{value:t.region,callback:function(e){t.region=e},expression:\"region\"}})],1),a(\"el-form-item\",[a(\"el-select\",{staticStyle:{width:\"150px\"},attrs:{clearable:\"\",placeholder:\"客户状态\"},on:{change:function(e){return t.pageChange(1)}},model:{value:t.query_form.enableStatus,callback:function(e){t.$set(t.query_form,\"enableStatus\",e)},expression:\"query_form.enableStatus\"}},t._l(t.customerStatus,(function(t){return a(\"el-option\",{key:t.value,attrs:{label:t.label,value:t.value}})})),1)],1),a(\"el-form-item\",[a(\"el-select\",{staticStyle:{width:\"150px\"},attrs:{clearable:\"\",placeholder:\"注册来源\"},on:{change:function(e){return t.pageChange(1)}},model:{value:t.query_form.source,callback:function(e){t.$set(t.query_form,\"source\",e)},expression:\"query_form.source\"}},t._l(t.source_list,(function(t,e){return a(\"el-option\",{key:e,attrs:{label:t.label,value:t.value}})})),1)],1),a(\"el-form-item\",[a(\"el-input\",{staticStyle:{width:\"155px\"},attrs:{clearable:\"\",placeholder:\"客户标签\"},on:{clear:function(e){return t.pageChange(1)}},nativeOn:{keyup:function(e){return!e.type.indexOf(\"key\")&&t._k(e.keyCode,\"enter\",13,e.key,\"Enter\")?null:t.pageChange(1)}},model:{value:t.query_form.tag,callback:function(e){t.$set(t.query_form,\"tag\",e)},expression:\"query_form.tag\"}},[a(\"el-button\",{attrs:{slot:\"append\",icon:\"el-icon-search\"},on:{click:function(e){return t.pageChange(1)}},slot:\"append\"})],1)],1)],1)],1),a(\"el-table\",{attrs:{data:t.tableData,size:\"small\"}},[a(\"el-table-column\",{attrs:{prop:\"id\",label:\"ID\",fixed:\"left\",width:\"50\"}}),a(\"el-table-column\",{attrs:{prop:\"name\",label:\"客户\",\"min-width\":\"280\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"div\",{staticClass:\"clearfix\"},[a(\"div\",{staticClass:\"float_left customer-img-view\"},[a(\"el-image\",{attrs:{src:e.row.avatar,fit:\"cover\"}})],1),a(\"div\",{staticClass:\"float_left customer-name-view\"},[a(\"p\",{staticClass:\"customer-name\"},[t._v(\" \"+t._s(e.row.name)+\" \")]),a(\"p\",[t._v(t._s(e.row.code))])])])]}}])}),a(\"el-table-column\",{attrs:{label:\"联系信息\",\"min-width\":\"160\",prop:\"contact\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"div\",[e.row.contact[0]?a(\"p\",[a(\"span\",{staticClass:\"table-label\"},[t._v(\"联系人:\")]),a(\"span\",{staticClass:\"table-val\"},[t._v(\" \"+t._s(e.row.contact[0].name||\"--\")+\" \")])]):t._e(),a(\"p\",[a(\"span\",{staticClass:\"table-label\"},[t._v(\"账号/电话:\")]),a(\"span\",{staticClass:\"table-val\"},[t._v(t._s(e.row.mobile||\"--\"))])])])]}}])}),t.salesmanFlag?a(\"el-table-column\",{attrs:{prop:\"salesManName\",label:\"业务员\",\"min-width\":\"120\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"div\",[a(\"p\",[a(\"span\",{staticClass:\"table-label\"},[t._v(\"业务员:\")]),a(\"span\",{staticClass:\"table-val\"},[t._v(\" \"+t._s(e.row.salesManName||\"--\")+\" \")])]),a(\"p\",[a(\"span\",{staticClass:\"table-label\"},[t._v(\"销售部门:\")]),a(\"span\",{staticClass:\"table-val\"},[t._v(\" \"+t._s(e.row.departmentName||\"--\")+\" \")])])])]}}],null,!1,1604224539)}):t._e(),t.clientTypeFlag?a(\"el-table-column\",{attrs:{prop:\"customerType\",label:\"客户类型\",\"min-width\":\"100\"}}):t._e(),t.shopFlag?a(\"el-table-column\",{attrs:{prop:\"shopName\",label:\"商铺\",\"min-width\":\"120\",\"show-overflow-tooltip\":\"\"}}):t._e(),t.accountStatusFlag?a(\"el-table-column\",{attrs:{prop:\"inventory\",label:\"账号状态\",width:\"100\"},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(\"禁用\")])]}}],null,!1,2138394615)}):t._e(),t.timeFlag?a(\"el-table-column\",{attrs:{prop:\"createTime\",label:\"注册时间\",\"min-width\":\"160\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[t._v(\" \"+t._s(t.$_common.formatDate(e.row.createTime))+\" \")]}}],null,!1,754808738)}):t._e(),t.auditStatusFlag?a(\"el-table-column\",{attrs:{prop:\"status\",label:\"审核状态\",\"min-width\":\"100\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[2===e.row.status?a(\"span\",{staticClass:\"success-status\"},[t._v(\" 已审核 \")]):t._e(),1===e.row.status?a(\"span\",{staticClass:\"warning-status\"},[t._v(\" 待审核 \")]):t._e(),0===e.row.status?a(\"span\",{staticClass:\"info-status\"},[t._v(\" 待完善资料 \")]):t._e(),3===e.row.status?a(\"span\",{staticClass:\"success-status\"},[t._v(\" 已驳回 \")]):t._e()]}}],null,!1,4189384648)}):t._e(),a(\"el-table-column\",{attrs:{prop:\"tag\",label:\"操作\",width:\"160\",fixed:\"right\"},scopedSlots:t._u([{key:\"header\",fn:function(e){return[t._e(),a(\"span\",{staticClass:\"operation\"},[t._v(\"操作\")]),a(\"el-popover\",{attrs:{\"popper-class\":\"custom-table-checkbox\",trigger:\"click\"}},[a(\"el-checkbox-group\",{model:{value:t.checkList,callback:function(e){t.checkList=e},expression:\"checkList\"}},t._l(t.columns,(function(e,n){return a(\"el-checkbox\",{key:n,attrs:{label:e.label},on:{change:t.change}})})),1),a(\"el-button\",{attrs:{slot:\"reference\",icon:\"el-icon-setting\",type:\"text\"},slot:\"reference\"})],1)]}},{key:\"default\",fn:function(e){return[t.$accessCheck(t.$Access.CustomerListGetCustomerInfo)?a(\"el-button\",{attrs:{type:\"text\"},on:{click:function(a){return t.$router.push(\"/Customer/CustomerAdmin/CustomerDetail/\"+e.row.id)}}},[t._v(\" 查看 \")]):t._e(),t.$accessCheck(t.$Access.CustomerListEditCustomer)?a(\"el-button\",{attrs:{type:\"text\"},on:{click:function(a){return t.editData(e.row)}}},[t._v(\" 编辑 \")]):t._e()]}}])})],1),a(\"FooterPage\",{attrs:{\"page-size\":t.pageSize,\"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.show_shop?a(\"GoodsChooseShop\",{attrs:{\"is-check\":!1,\"dialog-visible\":t.show_shop},on:{close:function(e){t.show_shop=!1},confirm:t.selShop}}):t._e(),a(\"el-drawer\",{staticClass:\"edit-drawer\",attrs:{size:\"50%\",title:t.drawer_tit,visible:t.drawer},on:{\"update:visible\":function(e){t.drawer=e}}},[t.drawer?a(\"EditCustomer\",{attrs:{\"customer-id\":t.customer_id},on:{subSuccess:t.subSuccess}}):t._e()],1)],1)},o=[],r=a(\"3241\"),i=a(\"d2bc\"),l=a(\"bc7d\"),s=a(\"55bb\"),c=a(\"049b\"),d=a(\"64f1\"),u={name:\"BrandManage\",components:{RegionSelect:r[\"default\"],GoodsChooseShop:i[\"default\"],EditCustomer:l[\"default\"],SelectShop:s[\"default\"]},data(){return{customer_id:\"\",drawer:!1,drawer_tit:\"\",source_list:[{label:\"ios\",tag:\"ios\",value:1},{label:\"安卓APP\",tag:\"android\",value:2},{label:\"小程序\",tag:\"miniProgram\",value:3},{label:\"后台创建\",tag:\"manage\",value:4},{label:\"H5页面\",tag:\"H5\",value:5},{label:\"Pc页面\",tag:\"Pc\",value:6}],customerStatus:[{value:\"5\",label:\"已启用\"},{value:\"4\",label:\"已停用\"}],show_shop:!1,region:[],top_sel:\"all\",total:0,page:1,pageSize:10,interestCustomerNum:\"\",newCustomerNum:\"\",customerTotalNum:\"\",tableData:[],activeNames:[\"1\"],staff_list:[],shop:\"\",query_form:{keyword:\"\",birthday_start:\"\",birthday_end:\"\",provinceCode:\"\",cityCode:\"\",districtCode:\"\",enableStatus:\"\",shopId:\"\",salesManId:\"\",tag:\"\",source:\"\"},checkList:[\"业务员\",\"客户类型\",\"商铺\",\"帐号状态\",\"注册时间\",\"审核状态\"],columns:[{label:\"业务员\"},{label:\"客户类型\"},{label:\"商铺\"},{label:\"帐号状态\"},{label:\"注册时间\"},{label:\"审核状态\"}],salesmanFlag:!0,clientTypeFlag:!0,shopFlag:!0,accountStatusFlag:!0,timeFlag:!0,auditStatusFlag:!0}},computed:{type_on_color(){return{}},type_on_style(){return{}}},created(){this.getAllStaff(),this.query()},activated(){this.$_isInit()||this.query()},methods:{subSuccess(){this.pageChange(1),this.drawer=!1},editData(t){this.customer_id=t.id,this.drawer_tit=t.name,this.drawer=!0},async query(){const{data:t,pageTotal:e,customerTotalNum:a,newCustomerNum:n,interestCustomerNum:o}=await Object(c[\"query\"])({page:this.page,pageSize:this.pageSize,keyword:this.query_form.keyword,birthday_start:this.query_form.birthday_start,birthday_end:this.query_form.birthday_end,provinceCode:this.query_form.provinceCode,cityCode:this.query_form.cityCode,districtCode:this.query_form.districtCode,enableStatus:this.query_form.enableStatus,shopId:this.query_form.shopId,salesManId:this.query_form.salesManId,tag:this.query_form.tag,source:this.query_form.source});this.tableData=t,this.customerTotalNum=a,this.newCustomerNum=n,this.interestCustomerNum=o,this.total=e},timeChange(t){t&&t.length?(this.query_form.birthday_start=t[0]/1e3,this.query_form.birthday_end=t[1]/1e3+86399):(this.query_form.birthday_start=\"\",this.query_form.birthday_end=\"\"),this.pageChange(1)},async getAllStaff(){const t=await Object(d[\"getAllStaff\"])({page:1,pageSize:9999});this.staff_list=t.data},regionChange(t){this.query_form.provinceCode=t[0],this.query_form.cityCode=t[1],this.query_form.districtCode=t[2],this.pageChange(1)},selShop(t){this.pageChange(1)},delShop(){this.query_form.shopId=\"\",this.pageChange(1)},selTopType(t){this.top_sel=t},pageChange(t){this.page=t,this.query()},sizeChange(t){this.pageSize=t,this.pageChange(1)},searchData(t){this.page=1,this.pageChange(1)},delData(t){},change(){this.salesmanFlag=this.checkList.some(t=>\"业务员\"===t),this.clientTypeFlag=this.checkList.some(t=>\"客户类型\"===t),this.shopFlag=this.checkList.some(t=>\"商铺\"===t),this.accountStatusFlag=this.checkList.some(t=>\"帐号状态\"===t),this.timeFlag=this.checkList.some(t=>\"注册时间\"===t),this.auditStatusFlag=this.checkList.some(t=>\"审核状态\"===t)}}},f=u,p=(a(\"423f\"),a(\"2877\")),m=Object(p[\"a\"])(f,n,o,!1,null,\"6795cf58\",null);e[\"default\"]=m.exports},bc7d:function(t,e,a){\"use strict\";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"ContainerTit\",[t.customerId?a(\"span\",{attrs:{slot:\"pagetit\"},slot:\"pagetit\"},[t._v(\"编辑客户\")]):t._e(),a(\"div\",{attrs:{slot:\"headr\"},slot:\"headr\"},[t.customerId?t._e():a(\"el-button\",{attrs:{loading:t.sub_load},on:{click:function(e){return t.delPauseSave(1)}}},[t._v(\" 清除暂存 \")]),t.customerId?t._e():a(\"el-button\",{attrs:{loading:t.sub_load},on:{click:t.temData}},[t._v(\" 暂存 \")]),a(\"el-button\",{attrs:{loading:t.sub_load,type:\"primary\"},on:{click:t.submitBrand}},[t._v(\" 保存 \")])],1),a(\"div\",{staticClass:\"page-div\"},[a(\"el-form\",{ref:\"form\",attrs:{rules:t.base_rules,model:t.form,size:\"small\",\"label-width\":t.customerId?\"120px\":\"200px\"}},[a(\"el-form-item\",{attrs:{label:\"客户编码:\",prop:\"code\"}},[a(\"el-input\",{staticStyle:{width:\"350px\"},attrs:{disabled:\"\",placeholder:\"自动生成\"},model:{value:t.form.code,callback:function(e){t.$set(t.form,\"code\",e)},expression:\"form.code\"}})],1),a(\"el-form-item\",{attrs:{label:\"客户名称:\",prop:\"name\"}},[a(\"el-input\",{staticStyle:{width:\"350px\"},attrs:{placeholder:\"请填写客户真实姓名\"},model:{value:t.form.name,callback:function(e){t.$set(t.form,\"name\",e)},expression:\"form.name\"}})],1),a(\"el-form-item\",{attrs:{label:\"登录账号:\",prop:\"mobile\"}},[a(\"el-input\",{staticStyle:{width:\"350px\"},attrs:{disabled:!!t.customer_id&&!!t.form.openId,placeholder:\"请填写客户手机号\"},on:{blur:t.moblieChange},model:{value:t.form.mobile,callback:function(e){t.$set(t.form,\"mobile\",e)},expression:\"form.mobile\"}})],1),a(\"el-form-item\",{attrs:{label:\"推荐人:\",prop:\"currentUnit\"}},[a(\"el-select\",{staticStyle:{width:\"85px\"},attrs:{placeholder:\"请选择\"},on:{change:t.btypeChange},model:{value:t.form.recommenderType,callback:function(e){t.$set(t.form,\"recommenderType\",e)},expression:\"form.recommenderType\"}},t._l(t.options_list,(function(t){return a(\"el-option\",{key:t.value,attrs:{label:t.label,value:t.value}})})),1),3===t.form.recommenderType?a(\"SelectCustomer\",{attrs:{modal:!t.customerId,clearable:!1,width:\"235\"},on:{change:t.customerSel},model:{value:t.currentUnit,callback:function(e){t.currentUnit=e},expression:\"currentUnit\"}}):t._e(),2===t.form.recommenderType?a(\"el-input\",{staticStyle:{width:\"265px\"},attrs:{clearable:\"\",placeholder:\"请选择员工\"},on:{clear:function(e){t.staff=\"\"},blur:function(e){t.staff=\"\"}},model:{value:t.currentUnit,callback:function(e){t.currentUnit=e},expression:\"currentUnit\"}},[a(\"i\",{staticClass:\"el-input__icon el-icon-search\",attrs:{slot:\"suffix\"},on:{click:function(e){return t.saleFn(!0)}},slot:\"suffix\"})]):t._e()],1),a(\"el-form-item\",{attrs:{label:\"账号状态:\",prop:\"enableStatus\"}},[a(\"el-radio\",{attrs:{label:5},model:{value:t.form.enableStatus,callback:function(e){t.$set(t.form,\"enableStatus\",e)},expression:\"form.enableStatus\"}},[t._v(\"启用\")]),a(\"el-radio\",{attrs:{label:4},model:{value:t.form.enableStatus,callback:function(e){t.$set(t.form,\"enableStatus\",e)},expression:\"form.enableStatus\"}},[t._v(\"禁用\")])],1),a(\"el-form-item\",{attrs:{label:\"客户类型:\",prop:\"type\"}},[a(\"el-select\",{staticStyle:{width:\"350px\"},attrs:{placeholder:\"客户类型\"},on:{change:t.typeChange},model:{value:t.form.type,callback:function(e){t.$set(t.form,\"type\",e)},expression:\"form.type\"}},t._l(t.customerType,(function(t){return a(\"el-option\",{key:t.id,attrs:{label:t.name,value:t.id}})})),1),1===t.systemType?a(\"el-button\",{attrs:{type:\"text\",size:\"mini\"},on:{click:t.getAllCustomerSource}},[t._v(\" 【刷新】 \")]):t._e(),1===t.systemType?a(\"el-button\",{attrs:{type:\"text\",size:\"mini\"},on:{click:function(e){t.show_model=!0}}},[t._v(\" 【新建类型】 \")]):t._e()],1),a(\"el-form-item\",{staticStyle:{\"margin-bottom\":\"20px\"},attrs:{label:\"联系人:\",prop:\"contactName\"}},[a(\"el-input\",{staticStyle:{width:\"350px\"},attrs:{placeholder:\"请输入客户联系人\"},model:{value:t.form.contact.name,callback:function(e){t.$set(t.form.contact,\"name\",e)},expression:\"form.contact.name\"}})],1),a(\"el-form-item\",{staticStyle:{\"margin-bottom\":\"20px\"},attrs:{label:\"联系人电话:\",prop:\"contactMobile\"}},[a(\"el-input\",{staticStyle:{width:\"350px\"},attrs:{placeholder:\"请输入客户联系人电话\"},model:{value:t.form.contact.mobile,callback:function(e){t.$set(t.form.contact,\"mobile\",e)},expression:\"form.contact.mobile\"}})],1),a(\"el-form-item\",{staticStyle:{\"margin-bottom\":\"20px\"},attrs:{label:\"联系人地区:\",prop:\"contact\"}},[t.customer_id?a(\"span\",[t.region.length?a(\"RegionSelect\",{staticStyle:{\"margin-bottom\":\"10px\",width:\"350px\"},attrs:{size:\"medium\"},on:{change:t.contactChange},model:{value:t.region,callback:function(e){t.region=e},expression:\"region\"}}):t._e()],1):a(\"span\",[a(\"RegionSelect\",{staticStyle:{\"margin-bottom\":\"10px\",width:\"350px\"},attrs:{size:\"medium\"},on:{change:t.contactChange},model:{value:t.region,callback:function(e){t.region=e},expression:\"region\"}})],1)]),a(\"el-form-item\",{attrs:{label:\"详细地址:\",prop:\"contactAddress\"}},[a(\"el-input\",{staticStyle:{width:\"350px\"},attrs:{placeholder:\"例如楼牌,门号\"},model:{value:t.form.contact.address,callback:function(e){t.$set(t.form.contact,\"address\",e)},expression:\"form.contact.address\"}})],1),1===t.systemType?a(\"el-form-item\",{attrs:{label:\"商铺:\"}},[a(\"SelectShop\",{attrs:{width:350,clearable:!0,\"is-default\":!0},on:{clear:t.shopClear,default:t.shopDefault},model:{value:t.form.shopId,callback:function(e){t.$set(t.form,\"shopId\",e)},expression:\"form.shopId\"}}),a(\"el-button\",{attrs:{size:\"mini\",type:\"text\"},on:{click:function(e){return t.goShop(1)}}},[t._v(\" 【新建商铺】 \")])],1):t._e(),a(\"el-form-item\",{staticStyle:{\"margin-bottom\":\"20px\"},attrs:{label:\"销售部门:\"}},[t.department_name&&t.customerId?a(\"el-tag\",{attrs:{type:\"success\"}},[t._v(\" \"+t._s(t.department_name)+\" \")]):t._e(),a(\"span\",{staticStyle:{display:\"inline-block\"}},[a(\"DepartmentSel\",{attrs:{width:350,placeholder:t.department_name,size:\"small\",\"is-show-add\":!0},on:{change:t.selBranch},model:{value:t.departmentId,callback:function(e){t.departmentId=e},expression:\"departmentId\"}})],1),1===t.systemType?a(\"el-button\",{attrs:{size:\"mini\",type:\"text\"},on:{click:function(e){t.add_department=!0}}},[t._v(\" 【新建部门】 \")]):t._e()],1),a(\"el-form-item\",{staticStyle:{\"margin-bottom\":\"20px\"},attrs:{label:\"业务员:\",prop:\"salesManId\"}},[a(\"el-select\",{staticStyle:{width:\"350px\"},attrs:{filterable:\"\",placeholder:\"业务员\"},on:{change:t.staffChange},model:{value:t.form.salesManId,callback:function(e){t.$set(t.form,\"salesManId\",e)},expression:\"form.salesManId\"}},t._l(t.staff_list,(function(t,e){return a(\"el-option\",{key:e,attrs:{label:t.staffName,value:t.id}})})),1),a(\"el-button\",{attrs:{size:\"mini\",type:\"text\"},on:{click:t.getAllStaff}},[t._v(\" 【刷新】 \")]),a(\"el-button\",{attrs:{size:\"mini\",type:\"text\"},on:{click:function(e){t.add_staff=!0}}},[t._v(\" 【新建员工】 \")])],1),a(\"el-form-item\",{attrs:{label:\"营业执照:\"}},[a(\"UploadQiniu\",{attrs:{\"file-list\":t.img_list,modal:!t.customerId},on:{uploadSuccess:t.uploadSuccess,handleRemove:t.uploadRemove}})],1),a(\"el-form-item\",{staticStyle:{\"margin-bottom\":\"20px\"},attrs:{label:\"客户生日:\",prop:\"birthday\"}},[a(\"el-date-picker\",{staticStyle:{width:\"350px\"},attrs:{\"default-value\":\"1990-01-01\",type:\"date\",placeholder:\"选择日期\",format:\"yyyy-MM-dd\",\"value-format\":\"timestamp\"},model:{value:t.form.birthday,callback:function(e){t.$set(t.form,\"birthday\",e)},expression:\"form.birthday\"}})],1),a(\"el-form-item\",{staticStyle:{\"margin-bottom\":\"20px\"},attrs:{label:\"客户备注:\",prop:\"remark\"}},[a(\"el-input\",{staticStyle:{width:\"350px\"},attrs:{type:\"textarea\",rows:3,placeholder:\"请输入您需要的服务\"},model:{value:t.form.remark,callback:function(e){t.$set(t.form,\"remark\",e)},expression:\"form.remark\"}})],1)],1)],1),t.add_staff?a(\"AddStaff\",{attrs:{modal:!t.customerId,visible:t.add_staff},on:{close:function(e){t.add_staff=!1},goShop:t.goShop}}):t._e(),t.add_department?a(\"AddDepartment\",{attrs:{modal:!t.customerId,visible:t.add_department},on:{close:function(e){t.add_department=!1}}}):t._e(),a(\"CutomerTypeAdd\",{attrs:{modal:!t.customerId,\"is-show\":t.show_model},on:{cancel:function(e){t.show_model=!1}}}),t.staff_show?a(\"staffListModal\",{attrs:{modal:!t.customerId,\"is-show\":t.staff_show,\"is-check\":!1,isserch:t.isserch},on:{cancel:function(e){t.staff_show=!1},confirm:t.staffSel}}):t._e()],1)},o=[],r=(a(\"caad\"),a(\"3241\")),i=a(\"b53c\"),l=a(\"e75f\"),s=a(\"55d15\"),c=a(\"876e\"),d=a(\"5143\"),u=a(\"55bb\"),f=a(\"d8dd\"),p=a(\"049b\"),m=a(\"64f1\"),h=a(\"2934\"),g=a(\"2f62\"),b=(a(\"478b\"),a(\"8156\")),y=a(\"7a21\"),v={name:\"AddCustomer\",components:{CutomerTypeAdd:c[\"default\"],RegionSelect:r[\"default\"],SelectShop:u[\"default\"],DepartmentSel:i[\"default\"],UploadQiniu:d[\"default\"],AddDepartment:l[\"default\"],AddStaff:s[\"default\"],SelectCustomer:b[\"default\"],staffListModal:y[\"default\"]},props:{customerId:{type:[Number,String],default:0}},data(){const t=(t,e,a)=>{const n=/^1[3456789]\\d{9}$/;\"\"===e?a(new Error):n.test(e)?a():a(new Error(\"手机号格式有误,请重新输入!\"))};return{img_list:[],regionName:\"\",sub_load:!1,show_model:!1,add_department:!1,add_staff:!1,customer_id:\"\",department_name:\"请选择销售部门\",show_shop:!1,saleMan_list:[],region:[],customerRegion:[],base_rules:{mobile:[{required:!0,message:\"请填写客户手机号\",trigger:\"blur\"},{validator:t,trigger:\"blur\"}],name:[{required:!0,message:\"客户名称不能为空\",trigger:\"blur\"}]},customerType:[],department_list:[],departmentPidPath:[],staff_list:[],departmentId:[],contactName:[],checked:!1,contactregion:\"\",typeName:\"\",pageName:\"\",form:{tempSave:\"\",latitude:\"\",longitude:\"\",password:\"\",area:\"\",mobile:\"\",enableStatus:5,name:\"\",code:\"\",type:\"\",provinceCode:\"\",cityCode:\"\",districtCode:\"\",address:\"\",managerMobile:\"\",shopId:\"\",departmentId:\"\",salesManId:\"\",salesManCode:\"\",salesManName:\"\",birthday:\"\",remark:\"\",reservoirId:\"\",recommenderType:3,recommenderId:\"\",extend:{license:\"\"},contact:{area:\"\",name:\"\",mobile:\"\",provinceCode:\"\",cityCode:\"\",districtCode:\"\",address:\"\"}},isEvidence:4,brand:\"\",area_list:[],options_list:[{label:\"客户\",value:3},{label:\"员工\",value:2}],currentUnit:\"\",staff_show:!1,isserch:!0}},computed:{...Object(g[\"c\"])({systemType:\"MUser/systemType\",storeData:\"MUser/storeData\"})},async created(){this.pageName=this.$route.name,this.brand=this.$route.path.includes(\"brand\"),await this.getAllCustomerSource(),await this.getAllStaff(),this.$route.params.id||this.customerId?(this.customer_id=this.$route.params.id||this.customerId,await this.getCustomerInfo()):([2,3].includes(this.systemType)&&(this.form.shopId=this.storeData.id),await this.getTempCustomerData())},methods:{typeChange(t){const e=this.customerType.find(e=>e.id===t);e&&(this.isEvidence=e.isEvidence)},moblieChange(){this.form.contact.mobile=this.form.mobile},uploadSuccess(t,e,a,n){this.form.extend.license=t,this.img_list=n},uploadRemove(t,e){this.form.extend.license=\"\",this.img_list=e},shopClear(){this.form.shopId=\"\"},async addData(){this.$refs.add_form.validate(async t=>{if(t){let t={};t=this.is_edit?await Object(f[\"editCustomerSource\"])(this.type_id,{...this.add_form}):await Object(f[\"addCustomerSource\"])({...this.add_form});this.$message(\"客户类型创建成功\"),this.show_model=!1}})},async getAllCustomerSource(){const t=await Object(f[\"getCustomerSourceList\"])();if(t.data.length){this.customerType=t.data;const e=t.data.find(t=>5===t.defaultStatus);this.form.type=e?e.id:t.data[0].id}else this.customerType=[]},searchcomplete(t){if(!t||!t.Ir||!t.Ir[0])return;const e=t.Ir[0].point;this.form.latitude=e.lat,this.form.longitude=e.lng},mapClick({type:t,target:e,point:a,pixel:n,overlay:o}){this.form.latitude=a.lat,this.form.longitude=a.lng,o.z.title&&(this.form.address=o.z.title)},async getAllStaff(){const{data:t}=await Object(m[\"getAllStaff\"])({departmentId:this.form.departmentId,page:\"1\",pageSize:\"999\"});this.staff_list=t},staffChange(t){const e=this.staff_list.find(e=>e.id===t);this.form.salesManCode=e.staffCode,this.form.salesManName=e.staffName},selBranch(t){this.form.departmentId=t[t.length-1],this.departmentPidPath=t.join(\",\"),this.form.salesManId=\"\",this.form.salesManCode=\"\",this.form.salesManName=\"\",this.getAllStaff()},contactChange(t,e){const a=e[0].label,n=e[1]?e[1].label:\"\",o=e[2]?e[2].label:\"\";this.contactName={provinceName:a,cityName:n,districtName:o},this.contactregion=a+n+o,this.form.contact.provinceCode=t[0],this.form.contact.cityCode=t[1]||\"\",this.form.contact.districtCode=t[2]||\"\",this.form.provinceCode=t[0],this.form.cityCode=t[1],this.form.districtCode=t[2]},regionChange(t,e){const a=e[0].label,n=e[1]?e[1].label:\"\",o=e[2]?e[2].label:\"\";this.regionName=a+n+o+this.form.address,this.form.provinceCode=t[0],this.form.cityCode=t[1]||\"\",this.form.districtCode=t[2]||\"\"},getRegion(t,e,a){this.regionName=t.name+(e.name||\"\")+(a.name||\"\")+this.form.address},async temData(){const t={...this.form,birthday:parseInt(this.form.birthday/1e3)};this.form.contact.id&&(t.contact.id=this.form.contact.id),this.sub_load=!0;try{await Object(h[\"addPauseSave\"])({key:this.pageName,data:t});this.sub_load=!1,this.$message({message:\"暂存成功\",type:\"success\"}),2===this.systemType?this.$closeCurrentGoEdit(\"/SingleStore/Customer/StoreCustomer\"):this.$closeCurrentGoEdit(\"/Customer/CustomerAdmin/CustomerList\")}catch(e){this.sub_load=!1}},async delPauseSave(t){Object(h[\"delPauseSave\"])({key:this.pageName});t&&(this.$message({type:\"success\",message:\"清除暂存成功\"}),this.$closeCurrentGoEdit(\"/Customer/CustomerAdmin/AddCustomer\"))},async submitBrand(){this.form.name.trim()?this.form.type?5!==this.isEvidence||this.form.extend.license?this.$refs.form.validate(async t=>{if(t){const t={...this.form,managerMobile:this.form.contact.mobile,birthday:parseInt(this.form.birthday/1e3)};this.form.contact.id&&(t.contact.id=this.form.contact.id),this.sub_load=!0;try{let e={};e=this.customer_id?await Object(p[\"editCustomer\"])(this.customer_id,{...t}):await Object(p[\"addCustomer\"])(t),this.sub_load=!1,this.$message({message:\"提交成功\",type:\"success\"}),this.customer_id?this.$emit(\"subSuccess\"):(this.delPauseSave(),2===this.systemType?this.$closeCurrentGoEdit(\"/SingleStore/Customer/StoreCustomer\"):this.$closeCurrentGoEdit(\"/Customer/CustomerAdmin/CustomerList\"))}catch(e){this.sub_load=!1}}}):this.$message(\"由于您选择的客户类型是零售商或者是批发商,所以必须上传营业执照\"):this.$message.warning(\"客户类型不能为空\"):this.$message.warning(\"客户名称不能为空\")},shopDefault(t){this.customerId||(this.form.shopId=t)},async getCustomerInfo(){const{data:t}=await Object(p[\"getCustomerInfo\"])(this.customer_id),e=this.customerType.find(t=>5===t.defaultStatus),a=t.extend&&t.extend.license?t.extend:{license:\"\"};this.form={...t,type:t.type||(e?e.id:t.type),birthday:1e3*t.birthday,contact:t.contact[0],extend:a},this.customerRegion=[t.provinceCode||0,t.cityCode||0,t.districtCode||0].map(t=>parseInt(t)),this.region=[t.contact[0].provinceCode,t.contact[0].cityCode,t.contact[0].districtCode].map(t=>parseInt(t)),this.department_name=t.departmentName,t.extend&&t.extend.license&&(this.img_list=[{url:t.extend.license,name:\"\"}]),this.currentUnit=t.recommenderName},async getTempCustomerData(){const{data:t}=await Object(h[\"getPauseSave\"])({key:this.pageName});\"{}\"!==JSON.stringify(t)&&(this.form={...t,birthday:1e3*t.birthday,contact:t.contact},this.customerRegion=[t.provinceCode||0,t.cityCode||0,t.districtCode||0].map(t=>parseInt(t)),this.region=[t.contact.provinceCode,t.contact.cityCode,t.contact.districtCode].map(t=>parseInt(t)),this.department_name=t.departmentName)},goShop(t){1===t&&this.$router.push(\"/SystemSettings/liansuoguanli/AddShop\"),this.$emit(\"goShop\")},btypeChange(){this.currentUnit=\"\"},customerSel(t,e){this.form.recommenderId=e[0].id},saleFn(t){this.staff_show=!0,this.isserch=t},staffSel(t){const e=t[0];this.currentUnit=e.staffName,this.form.recommenderId=e.id}}},S=v,_=(a(\"85a6\"),a(\"2877\")),k=Object(_[\"a\"])(S,n,o,!1,null,\"7e16a010\",null);e[\"default\"]=k.exports},ce9d:function(t,e,a){},d099:function(t,e,a){\"use strict\";a.r(e),a.d(e,\"addFinanceType\",(function(){return o})),a.d(e,\"editFinanceType\",(function(){return r})),a.d(e,\"delFinanceType\",(function(){return i})),a.d(e,\"getAllFinanceType\",(function(){return l})),a.d(e,\"getAllFinanceTypeNoPage\",(function(){return s})),a.d(e,\"updateFinanceTypeStatus\",(function(){return c})),a.d(e,\"updateFinanceTypeDefaultStatus\",(function(){return d})),a.d(e,\"getAllReceive\",(function(){return u})),a.d(e,\"exportGetAllReceive\",(function(){return f})),a.d(e,\"searchAllReceive\",(function(){return p})),a.d(e,\"exportSearchAllReceive\",(function(){return m})),a.d(e,\"getReceiveInfo\",(function(){return h})),a.d(e,\"updateReceiveStatus\",(function(){return g})),a.d(e,\"getReceivedByOrder\",(function(){return b})),a.d(e,\"getAllPay\",(function(){return y})),a.d(e,\"exportGetAllPay\",(function(){return v})),a.d(e,\"searchPay\",(function(){return S})),a.d(e,\"exportSearchPay\",(function(){return _})),a.d(e,\"updatePayStatus\",(function(){return k})),a.d(e,\"getPayInfo\",(function(){return I})),a.d(e,\"addAccount\",(function(){return A})),a.d(e,\"getAllAccount\",(function(){return C})),a.d(e,\"editAccount\",(function(){return O})),a.d(e,\"delAccount\",(function(){return w})),a.d(e,\"updateAccountDefaultStatus\",(function(){return j})),a.d(e,\"updateAccountStatus\",(function(){return x})),a.d(e,\"getAccountInfo\",(function(){return R})),a.d(e,\"getAllAccountDetail\",(function(){return P})),a.d(e,\"addReceived\",(function(){return F})),a.d(e,\"deleteReceived\",(function(){return T})),a.d(e,\"exportsgetAllReceived\",(function(){return $})),a.d(e,\"getAllReceived\",(function(){return N})),a.d(e,\"getReceivedInfo\",(function(){return D})),a.d(e,\"updateReceivedStatus\",(function(){return B})),a.d(e,\"updateReceiptRequisitionStatus\",(function(){return q})),a.d(e,\"getTempReceivedData\",(function(){return z})),a.d(e,\"ReceivedSearch\",(function(){return L})),a.d(e,\"editReceived\",(function(){return E})),a.d(e,\"addPaid\",(function(){return M})),a.d(e,\"searchPaid\",(function(){return W})),a.d(e,\"getAllPaid\",(function(){return G})),a.d(e,\"exportsgetAllPaid\",(function(){return U})),a.d(e,\"getPaidInfo\",(function(){return J})),a.d(e,\"updatePaidStatus\",(function(){return V})),a.d(e,\"getTempPaidData\",(function(){return H})),a.d(e,\"editPaid\",(function(){return Q})),a.d(e,\"getAllCustomerBalance\",(function(){return K})),a.d(e,\"exportgetAllCustomerBalance\",(function(){return X})),a.d(e,\"getAllCustomerBalanceDetail\",(function(){return Y})),a.d(e,\"exportgetAllCustomerBalanceDetail\",(function(){return Z})),a.d(e,\"getAllSupplierBalance\",(function(){return tt})),a.d(e,\"exportGetAllSupplierBalance\",(function(){return et})),a.d(e,\"exportgetAllSupplierBalanceDetail\",(function(){return at})),a.d(e,\"getAllSupplierBalanceDetail\",(function(){return nt})),a.d(e,\"addAccountTransfer\",(function(){return ot})),a.d(e,\"getAccountTransferInfo\",(function(){return rt})),a.d(e,\"editAccountTransfer\",(function(){return it})),a.d(e,\"getAllAccountTransfer\",(function(){return lt})),a.d(e,\"updateAccountTransferStatus\",(function(){return st})),a.d(e,\"getTempAccountTransferData\",(function(){return ct})),a.d(e,\"getTodayStatistics\",(function(){return dt})),a.d(e,\"getAllReceiptRequisition\",(function(){return ut})),a.d(e,\"addReceiptRequisition\",(function(){return ft})),a.d(e,\"editReceiptRequisition\",(function(){return pt})),a.d(e,\"getReceiptRequisitionInfo\",(function(){return mt})),a.d(e,\"getAllAccountType\",(function(){return ht})),a.d(e,\"addAccountType\",(function(){return gt})),a.d(e,\"delAccountType\",(function(){return bt})),a.d(e,\"getAccountTypeInfo\",(function(){return yt})),a.d(e,\"editAccountType\",(function(){return vt})),a.d(e,\"getAllExpenseSingle\",(function(){return St})),a.d(e,\"addExpenseSingle\",(function(){return _t})),a.d(e,\"getExpenseSingleInfo\",(function(){return kt})),a.d(e,\"editExpenseSingle\",(function(){return It})),a.d(e,\"delExpenseSingle\",(function(){return At})),a.d(e,\"updateExpenseStatus\",(function(){return Ct})),a.d(e,\"getAllRefund\",(function(){return Ot})),a.d(e,\"addRefund\",(function(){return wt})),a.d(e,\"getRefundInfo\",(function(){return jt})),a.d(e,\"editRefund\",(function(){return xt})),a.d(e,\"updateRefundStatus\",(function(){return Rt})),a.d(e,\"getAllReceivedOffset\",(function(){return Pt})),a.d(e,\"getAllPaidOffset\",(function(){return Ft}));var n=a(\"b775\");function o(t){return Object(n[\"default\"])({url:\"/Finance/FinanceType/addFinanceType\",method:\"post\",data:t})}function r(t,e){return Object(n[\"default\"])({url:\"/Finance/FinanceType/editFinanceType/\"+t,method:\"put\",data:e})}function i(t,e){return Object(n[\"default\"])({url:\"/Finance/FinanceType/delFinanceType/\"+t,method:\"delete\",data:e})}function l(t){return Object(n[\"default\"])({url:\"/Finance/FinanceType/getAllFinanceType\",method:\"post\",data:t})}function s(t,e){return Object(n[\"default\"])({url:\"/Finance/FinanceType/getAllFinanceTypeNoPage/\"+t,method:\"post\",data:e})}function c(t){return Object(n[\"default\"])({url:\"/Finance/FinanceType/updateFinanceTypeStatus\",method:\"post\",data:t})}function d(t){return Object(n[\"default\"])({url:\"/Finance/FinanceType/updateFinanceTypeDefaultStatus\",method:\"post\",data:t})}function u(t){return Object(n[\"default\"])({url:\"/Finance/Receive/getAllReceive\",method:\"post\",data:t})}function f(t){return Object(n[\"default\"])({url:\"/Finance/Receive/getAllReceive\",responseType:\"blob\",method:\"post\",data:t})}function p(t){return Object(n[\"default\"])({url:\"/Finance/Receive/search\",method:\"post\",data:t})}function m(t){return Object(n[\"default\"])({url:\"/Finance/Receive/search\",responseType:\"blob\",method:\"post\",data:t})}function h(t){return Object(n[\"default\"])({url:\"/Finance/Receive/getReceiveInfo\",method:\"post\",data:t})}function g(t){return Object(n[\"default\"])({url:\"/Finance/Receive/updateReceiveStatus\",method:\"post\",data:t})}function b(t){return Object(n[\"default\"])({url:\"/Finance/Received/getReceivedByOrder\",method:\"post\",data:t})}function y(t){return Object(n[\"default\"])({url:\"/Finance/Pay/getAllPay\",method:\"post\",data:t})}function v(t){return Object(n[\"default\"])({url:\"/Finance/Pay/getAllPay\",responseType:\"blob\",method:\"post\",data:t})}function S(t){return Object(n[\"default\"])({url:\"/Finance/Pay/search\",method:\"post\",data:t})}function _(t){return Object(n[\"default\"])({url:\"/Finance/Pay/search\",responseType:\"blob\",method:\"post\",data:t})}function k(t){return Object(n[\"default\"])({url:\"/Finance/Pay/updatePayStatus\",method:\"post\",data:t})}function I(t){return Object(n[\"default\"])({url:\"/Finance/Pay/getPayInfo\",method:\"post\",data:t})}function A(t){return Object(n[\"default\"])({url:\"/Finance/Account/addAccount\",method:\"post\",data:t})}function C(t){return Object(n[\"default\"])({url:\"/Finance/Account/getAllAccount\",method:\"post\",data:t})}function O(t,e){return Object(n[\"default\"])({url:\"/Finance/Account/editAccount/\"+t,method:\"put\",data:e})}function w(t,e){return Object(n[\"default\"])({url:\"/Finance/Account/delAccount/\"+t,method:\"delete\",data:e})}function j(t){return Object(n[\"default\"])({url:\"/Finance/Account/updateAccountDefaultStatus\",method:\"post\",data:t})}function x(t){return Object(n[\"default\"])({url:\"/Finance/Account/updateAccountStatus\",method:\"post\",data:t})}function R(t,e){return Object(n[\"default\"])({url:\"/Finance/Account/getAccountInfo/\"+t,method:\"get\",data:e})}function P(t){return Object(n[\"default\"])({url:\"/Finance/AccountDetail/getAllAccountDetail\",method:\"post\",data:t})}function F(t){return Object(n[\"default\"])({url:\"/Finance/Received/addReceived\",method:\"post\",data:t})}function T(t,e){return Object(n[\"default\"])({url:\"/Finance/Received/deleteReceived/\"+t,method:\"delete\",data:e})}function $(t){return Object(n[\"default\"])({url:\"/Finance/Received/getAllReceived\",method:\"post\",responseType:\"blob\",data:t})}function N(t){return Object(n[\"default\"])({url:\"Finance/Received/getAllReceived\",method:\"post\",data:t})}function D(t){return Object(n[\"default\"])({url:\"/Finance/Received/getReceivedInfo\",method:\"post\",data:t})}function B(t){return Object(n[\"default\"])({url:\"/Finance/Received/updateReceivedStatus\",method:\"post\",data:t})}function q(t){return Object(n[\"default\"])({url:\"Finance/ReceiptRequisition/updateReceiptRequisitionStatus\",method:\"post\",data:t})}function z(t){return Object(n[\"default\"])({url:\"/Finance/Received/getTempReceivedData\",method:\"get\",data:t})}function L(t){return Object(n[\"default\"])({url:\"/Finance/Received/search\",method:\"post\",data:t})}function E(t,e){return Object(n[\"default\"])({url:\"/Finance/Received/editReceived/\"+t,method:\"post\",data:e})}function M(t){return Object(n[\"default\"])({url:\"/Finance/Paid/addPaid\",method:\"post\",data:t})}function W(t){return Object(n[\"default\"])({url:\"/Finance/Paid/search\",method:\"post\",data:t})}function G(t){return Object(n[\"default\"])({url:\"/Finance/Paid/getAllPaid\",method:\"post\",data:t})}function U(t){return Object(n[\"default\"])({url:\"/Finance/Paid/getAllPaid\",method:\"post\",responseType:\"blob\",data:t})}function J(t){return Object(n[\"default\"])({url:\"/Finance/Paid/getPaidInfo\",method:\"post\",data:t})}function V(t){return Object(n[\"default\"])({url:\"/Finance/Paid/updatePaidStatus\",method:\"post\",data:t})}function H(t){return Object(n[\"default\"])({url:\"/Finance/Paid/getTempPaidData\",method:\"get\",data:t})}function Q(t,e){return Object(n[\"default\"])({url:\"/Finance/Paid/editPaid/\"+t,method:\"post\",data:e})}function K(t){return Object(n[\"default\"])({url:\"/Finance/CustomerBalance/getAllCustomerBalance\",method:\"post\",data:t})}function X(t){return Object(n[\"default\"])({url:\"Finance/CustomerBalance/getAllCustomerBalance\",method:\"post\",responseType:\"blob\",data:t})}function Y(t){return Object(n[\"default\"])({url:\"/Finance/CustomerBalanceDetail/getAllCustomerBalanceDetail\",method:\"post\",data:t})}function Z(t){return Object(n[\"default\"])({url:\"/Finance/CustomerBalanceDetail/getAllCustomerBalanceDetail\",method:\"post\",responseType:\"blob\",data:t})}function tt(t){return Object(n[\"default\"])({url:\"/Finance/SupplierBalance/getAllSupplierBalance\",method:\"post\",data:t})}function et(t){return Object(n[\"default\"])({url:\"/Finance/SupplierBalance/getAllSupplierBalance\",method:\"post\",responseType:\"blob\",data:t})}function at(t){return Object(n[\"default\"])({url:\"/Finance/SupplierBalanceDetail/getAllSupplierBalanceDetail\",method:\"post\",responseType:\"blob\",data:t})}function nt(t){return Object(n[\"default\"])({url:\"/Finance/SupplierBalanceDetail/getAllSupplierBalanceDetail\",method:\"post\",data:t})}function ot(t){return Object(n[\"default\"])({url:\"/Finance/AccountTransfer/addAccountTransfer\",method:\"post\",data:t})}function rt(t,e){return Object(n[\"default\"])({url:\"/Finance/AccountTransfer/getAccountTransferInfo/\"+t,method:\"get\",data:e})}function it(t,e){return Object(n[\"default\"])({url:\"/Finance/AccountTransfer/editAccountTransfer/\"+t,method:\"put\",data:e})}function lt(t){return Object(n[\"default\"])({url:\"/Finance/AccountTransfer/getAllAccountTransfer\",method:\"post\",data:t})}function st(t,e){return Object(n[\"default\"])({url:\"/Finance/AccountTransfer/updateAccountTransferStatus/\"+t,method:\"put\",data:e})}function ct(t){return Object(n[\"default\"])({url:\"/Finance/AccountTransfer/getTempAccountTransferData\",method:\"post\",data:t})}function dt(t){return Object(n[\"default\"])({url:\"Finance/Account/getTodayStatistics\",method:\"post\",data:t})}function ut(t){return Object(n[\"default\"])({url:\"Finance/ReceiptRequisition/getAllReceiptRequisition\",method:\"post\",data:t})}function ft(t){return Object(n[\"default\"])({url:\"Finance/ReceiptRequisition/addReceiptRequisition\",method:\"post\",data:t})}function pt(t,e){return Object(n[\"default\"])({url:\"Finance/ReceiptRequisition/editReceiptRequisition/\"+t,method:\"post\",data:e})}function mt(t,e){return Object(n[\"default\"])({url:\"Finance/ReceiptRequisition/getReceiptRequisitionInfo/\"+t,method:\"get\",data:e})}function ht(t){return Object(n[\"default\"])({url:\"Finance/AccountType/getAllAccountType\",method:\"post\",data:t})}function gt(t){return Object(n[\"default\"])({url:\"Finance/AccountType/addAccountType\",method:\"post\",data:t})}function bt(t,e){return Object(n[\"default\"])({url:\"Finance/AccountType/delAccountType/\"+t,method:\"delete\",data:e})}function yt(t,e){return Object(n[\"default\"])({url:\"Finance/AccountType/getAccountTypeInfo/\"+t,method:\"post\",data:e})}function vt(t){return Object(n[\"default\"])({url:\"Finance/AccountType/editAccountType\",method:\"post\",data:t})}function St(t){return Object(n[\"default\"])({url:\"Finance/ExpenseSingle/getAllExpenseSingle\",method:\"post\",data:t})}function _t(t){return Object(n[\"default\"])({url:\"Finance/ExpenseSingle/addExpenseSingle\",method:\"post\",data:t})}function kt(t,e){return Object(n[\"default\"])({url:\"Finance/ExpenseSingle/getExpenseSingleInfo/\"+t,method:\"get\",data:e})}function It(t,e){return Object(n[\"default\"])({url:\"Finance/ExpenseSingle/editExpenseSingle/\"+t,method:\"post\",data:e})}function At(t,e){return Object(n[\"default\"])({url:\"Finance/ExpenseSingle/delExpenseSingle/\"+t,method:\"delete\",data:e})}function Ct(t){return Object(n[\"default\"])({url:\"Finance/ExpenseSingle/updateExpenseStatus\",method:\"post\",data:t})}function Ot(t){return Object(n[\"default\"])({url:\"Finance/Refund/getAllRefund\",method:\"post\",data:t})}function wt(t){return Object(n[\"default\"])({url:\"Finance/Refund/addRefund\",method:\"post\",data:t})}function jt(t){return Object(n[\"default\"])({url:\"Finance/Refund/getRefundInfo\",method:\"post\",data:t})}function xt(t,e){return Object(n[\"default\"])({url:\"Finance/Refund/editRefund/\"+t,method:\"post\",data:e})}function Rt(t){return Object(n[\"default\"])({url:\"Finance/Refund/updateRefundStatus\",method:\"post\",data:t})}function Pt(t){return Object(n[\"default\"])({url:\"Finance/Received/getAllReceivedOffset\",method:\"post\",data:t})}function Ft(t){return Object(n[\"default\"])({url:\"Finance/Paid/getAllPaidOffset\",method:\"post\",data:t})}},d2bc:function(t,e,a){\"use strict\";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"div\",{staticStyle:{\"text-align\":\"left\"}},[a(\"el-dialog\",{attrs:{title:\"商铺列表\",visible:t.dialogVisible,width:\"60%\",modal:t.modal,\"close-on-press-escape\":!1,\"close-on-click-modal\":!1},on:{\"update:visible\":function(e){t.dialogVisible=e},close:t.close}},[a(\"div\",[a(\"div\",{staticClass:\"clearfix\",staticStyle:{\"padding-bottom\":\"10px\"}},[a(\"div\",{staticClass:\"float_left\"},[a(\"el-input\",{staticStyle:{width:\"280px\"},attrs:{placeholder:\"请输入商铺名称\",size:\"small\",clearable:\"\"},on:{clear:function(e){return t.pageChange(1)}},nativeOn:{keyup:function(e){return!e.type.indexOf(\"key\")&&t._k(e.keyCode,\"enter\",13,e.key,\"Enter\")?null:t.pageChange(1)}},model:{value:t.search_key,callback:function(e){t.search_key=e},expression:\"search_key\"}},[a(\"el-button\",{attrs:{slot:\"append\",icon:\"el-icon-search\"},on:{click:function(e){return t.pageChange(1)}},slot:\"append\"})],1)],1),t.isShowAdd?a(\"el-button\",{staticClass:\"float_right\",attrs:{type:\"text\"},on:{click:t.getList}},[t._v(\" 【刷新】 \")]):t._e()],1),a(\"el-table\",{attrs:{size:\"mini\",data:t.table_data},on:{\"row-dblclick\":t.dblclick,\"selection-change\":t.handleSelectionChange}},[t.isCheck?a(\"el-table-column\",{attrs:{type:\"selection\",width:\"55\"}}):t._e(),a(\"el-table-column\",{attrs:{prop:\"name\",label:\"名称\",align:\"center\",\"show-overflow-tooltip\":!0}}),a(\"el-table-column\",{attrs:{label:\"营业时间\",align:\"center\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[1===e.row.openTime.isAllDay?a(\"span\",[t._v(\"全天\")]):a(\"span\",[t._v(\" \"+t._s(e.row.openTime.start)+\"--\"+t._s(e.row.openTime.end)+\" \")])]}}])}),a(\"el-table-column\",{attrs:{prop:\"area\",label:\"地址\",\"show-overflow-tooltip\":\"\",align:\"center\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[e.row.area?a(\"span\",[t._v(\" \"+t._s(e.row.area.provinceName||\"\")+\"-\"+t._s(e.row.area.districtName||\"\")+\"-\"+t._s(e.row.area.cityName||\"\")+\"-\"+t._s(e.row.area.address||\"\")+\" \")]):t._e()]}}])}),a(\"el-table-column\",{attrs:{prop:\"partnerName\",label:\"负责人\",align:\"center\"}}),a(\"el-table-column\",{attrs:{prop:\"mobile\",label:\"负责人电话\",align:\"center\"}}),a(\"el-table-column\",{attrs:{label:\"选择\",align:\"center\"},scopedSlots:t._u([{key:\"default\",fn:function(e){return[a(\"el-button\",{attrs:{size:\"mini\",icon:\"el-icon-check\"},on:{click:function(a){return t.dblclick(e.row)}}})]}}])})],1)],1),a(\"div\",{staticClass:\"footer clearfix\"},[t.isCheck?a(\"div\",{staticClass:\"float_left\",staticStyle:{\"padding-top\":\"20px\"}},[a(\"el-button\",{attrs:{size:\"small\",type:\"primary\"},on:{click:t.confirm}},[t._v(\" 确认 \")]),a(\"el-button\",{attrs:{size:\"small\"},on:{click:t.close}},[t._v(\"取消\")])],1):t._e(),a(\"div\",{staticClass:\"float_right\"},[a(\"FooterPage\",{attrs:{\"page-size\":t.pageSize,\"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}})],1)])])],1)},o=[],r=a(\"e1b7\"),i={name:\"GoodsChooseShop\",props:{dialogVisible:{type:Boolean,default:!1},isCheck:{type:Boolean,default:!0},isShowAdd:{type:Boolean,default:!1},enable:{type:Boolean,default:!1},modal:{type:Boolean,default:!0}},data(){return{search_key:\"\",pageSize:10,total:0,page:1,table_data:[],choose_data:[],enableStatus:\"\"}},created(){this.enable?this.enableStatus=5:this.enableStatus=\"\",this.getList()},methods:{async getList(){const t={page:this.page,pageSize:this.pageSize,enableStatus:this.enableStatus},e=await Object(r[\"getAllShop\"])(t);this.table_data=e.data,this.total=e.pageTotal,this.$emit(\"getAllShop\",e.data)},async searchList(){const t={page:this.page,pageSize:this.pageSize,name:this.search_key,shopPartnerId:\"\",shopType:\"\",enableStatus:this.enableStatus},e=await Object(r[\"search\"])(t);this.table_data=e.data,this.total=e.pageTotal},getData(){const t={name:this.search_key},e=this.$_common.isSerch(t);e?this.searchList():this.getList()},dblclick(t){this.close(),this.$emit(\"confirm\",[t])},pageChange(t){this.page=t,this.getData()},sizeChange(t){this.page=1,this.pageSize=t,this.getData()},close(){this.$emit(\"close\")},confirm(){this.$emit(\"confirm\",this.choose_data),this.close()},handleSelectionChange(t){this.choose_data=t}}},l=i,s=(a(\"2cb5\"),a(\"2877\")),c=Object(s[\"a\"])(l,n,o,!1,null,\"3e1b569c\",null);e[\"default\"]=c.exports},d4c8:function(t,e,a){\"use strict\";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"div\",[a(\"el-form\",{ref:\"form\",attrs:{rules:t.rules,size:\"small\",model:t.form,\"label-width\":\"120px\"}},[a(\"el-form-item\",{attrs:{label:\"角色名称\",prop:\"roleName\"}},[a(\"el-input\",{attrs:{placeholder:\"请输入角色名称\"},model:{value:t.form.roleName,callback:function(e){t.$set(t.form,\"roleName\",e)},expression:\"form.roleName\"}})],1),a(\"el-form-item\",{attrs:{label:\"分组到\"}},[a(\"el-select\",{attrs:{placeholder:\"请选择分组\",clearable:\"\"},model:{value:t.form.pid,callback:function(e){t.$set(t.form,\"pid\",e)},expression:\"form.pid\"}},t._l(t.position_data,(function(t){return a(\"el-option\",{key:t.id,attrs:{label:t.roleName,value:t.id}})})),1)],1),a(\"el-form-item\",{staticStyle:{\"text-align\":\"right\",\"padding-right\":\"20px\"}},[a(\"el-button\",{attrs:{type:\"primary\"},on:{click:t.confirm}},[t._v(\"确 定\")])],1)],1)],1)},o=[],r=a(\"64f1\"),i={name:\"AddPosition\",props:{visible:{type:Boolean,default:!1},isEdit:{type:Boolean,default:!1},id:{type:[Number,String],default:0}},data(){return{form:{roleName:\"\",pid:\"\"},position_data:[],rules:{roleName:[{required:!0,message:\"请输入角色名称\",trigger:\"blur\"}]}}},created(){this.id&&this.getRoleInfo(),this.getAllRole()},methods:{async getAllRole(){const t=await Object(r[\"getAllRole\"])({page:1,pageSize:999});this.position_data=t.data},async addRole(){this.$refs.form.validate(async t=>{if(t){await Object(r[\"addRole\"])(this.form);this.$message({message:\"创建成功\",type:\"success\"}),this.$emit(\"confirm\")}})},async updateRole(){this.$refs.form.validate(async t=>{if(t&&this.id){await Object(r[\"updateRole\"])(this.id,this.form);this.$message({message:\"修改成功\",type:\"success\"}),this.$emit(\"confirm\")}})},async getRoleInfo(){if(!this.id)return;const t=await Object(r[\"getRoleInfo\"])(this.id);this.form=t.data},close(){this.$emit(\"close\")},confirm(){this.form.roleName.trim()?(this.close(),this.id?this.updateRole():this.addRole()):this.$message.warning(\"角色名称不能为空\")}}},l=i,s=a(\"2877\"),c=Object(s[\"a\"])(l,n,o,!1,null,\"9780f136\",null);e[\"default\"]=c.exports},d8ab:function(t,e,a){\"use strict\";a.r(e);var n=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:\"请选择角色\",value:t.value,options:t.position_data,props:t.props,size:t.size},on:{\"expand-change\":t.expandChange,change:t.change}}),t.isShowAdd?a(\"el-button\",{attrs:{size:\"mini\",type:\"text\"},on:{click:t.getAllRole}},[t._v(\" 【刷新】 \")]):t._e()],1)},o=[],r=a(\"64f1\"),i={name:\"RegionSelect\",model:{prop:\"value\",event:\"change\"},props:{value:{type:Array,default:()=>[]},isShowAdd:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},filterable:{type:Boolean,default:!1},checkStrictly:{type:Boolean,default:!1},width:{type:[Number,String],default:200},size:{type:String,default:\"small\"}},data(){return{position_data:[],props:{label:\"roleName\",value:\"id\"}}},async created(){this.props.checkStrictly=this.checkStrictly,await this.getAllRole()},methods:{async getAllRole(){const t=await Object(r[\"getAllRole\"])();this.position_data=t.data},change(t){this.$emit(\"change\",t)},expandChange(t){this.$emit(\"expandChange\",t)}}},l=i,s=a(\"2877\"),c=Object(s[\"a\"])(l,n,o,!1,null,\"79b9e062\",null);e[\"default\"]=c.exports},e75f:function(t,e,a){\"use strict\";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a(\"div\",[a(\"el-dialog\",{attrs:{title:t.isEdit?\"修改部门\":\"新建部门\",visible:t.visible,modal:t.modal,width:\"35%\",\"close-on-press-escape\":!1,\"close-on-click-modal\":!1},on:{\"update:visible\":function(e){t.visible=e},close:t.close}},[a(\"el-form\",{ref:\"form\",attrs:{rules:t.rules,size:\"small\",model:t.form,\"label-width\":\"120px\"}},[a(\"el-form-item\",{attrs:{label:\"部门名称\",prop:\"departmentName\"}},[a(\"el-input\",{attrs:{placeholder:\"请输入部门名称\"},model:{value:t.form.departmentName,callback:function(e){t.$set(t.form,\"departmentName\",e)},expression:\"form.departmentName\"}})],1),a(\"el-form-item\",{attrs:{label:\"上级部门\"}},[a(\"el-cascader\",{attrs:{options:t.Department_data,props:{label:\"departmentName\",value:\"id\",checkStrictly:!0},clearable:\"\"},on:{change:t.departmentChange},scopedSlots:t._u([{key:\"default\",fn:function(e){return a(\"div\",{on:{click:t.clickChange}},[t._v(\" \"+t._s(e.data.departmentName)+\" \")])}}]),model:{value:t.department_position,callback:function(e){t.department_position=e},expression:\"department_position\"}})],1),a(\"el-form-item\",{staticStyle:{\"text-align\":\"right\",\"padding-right\":\"10px\"}},[a(\"el-button\",{attrs:{type:\"primary\"},on:{click:t.confirm}},[t._v(\"确 定\")]),a(\"el-button\",{on:{click:t.close}},[t._v(\"取 消\")])],1)],1)],1)],1)},o=[],r=a(\"64f1\"),i={name:\"AddDepartment\",props:{visible:{type:Boolean,default:!1},modal:{type:Boolean,default:!0},isEdit:{type:Boolean,default:!1},id:{type:[Number,String],default:0}},data(){return{department_position:[],form:{pid:\"0\",order:\"0\",departmentName:\"\",desc:\"\",departmentPidPath:\"\"},Department_data:[],rules:{departmentName:[{required:!0,message:\"请输入部门名称\",trigger:\"blur\"}],desc:[{required:!0,message:\"请选择上级部门\",trigger:\"change\"}]}}},created(){this.getAllDepartment(),this.isEdit&&this.getDepartmentInfo()},methods:{departmentChange(t){this.form.departmentPidPath=t.join(\",\")},async getAllDepartment(){const t=await Object(r[\"getAllDepartment\"])();this.Department_data=t.data},async getDepartmentInfo(){if(!this.isEdit)return;const t=await Object(r[\"getDepartmentInfo\"])(this.id);this.department_position=t.data.extend.departmentPidPath.split(\",\").map(t=>parseInt(t));const e=this.$_common.deepClone(t.data);delete e.extend,this.form={...e,departmentPidPath:t.data.extend.departmentPidPath}},close(){this.$emit(\"close\")},async confirm(){this.form.departmentName.trim()?this.$refs.form.validate(async t=>{if(t){let t={};const e={...this.form,pid:this.department_position.length?this.department_position[this.department_position.length-1]:\"\"};t=this.isEdit?await Object(r[\"updateDepartment\"])(this.id,e):await Object(r[\"addDepartment\"])(e);this.$message({message:\"提交成功\",type:\"success\"}),this.close(),this.$emit(\"confirm\")}}):this.$message.warning(\"部门名称不能为空\")}}},l=i,s=a(\"2877\"),c=Object(s[\"a\"])(l,n,o,!1,null,\"6a5d93c9\",null);e[\"default\"]=c.exports}}]);","extractedComments":[]}
|