1 |
- (window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-c5353d52","chunk-27547546"],{"479f":function(t,e,r){"use strict";r.r(e);var n=r("a34a"),i=r.n(n),a=r("2f62"),o=r("c276"),s=r("d708"),u=r("a6b9");function c(t,e,r,n,i,a,o){try{var s=t[a](o),u=s.value}catch(t){return void r(t)}s.done?e(u):Promise.resolve(u).then(n,i)}function p(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var a=t.apply(e,r);function o(t){c(a,n,i,o,s,"next",t)}function s(t){c(a,n,i,o,s,"throw",t)}o(void 0)}))}}function l(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function d(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var f={name:"",components:{Template:r("6112").default},props:{},data:function(){return{roterPre:s.a.roterPre,keywords:"",BaseURL:"",formValidate:{status:"",extract_type:"",nireid:"",data:"thirtyday",page:1,limit:20},loading:!1,page:{total:0,pageNum:1,pageSize:15},columns:[{title:"ID",key:"id",minWidth:80},{title:"供应商",minWidth:100,key:"supplier_name"},{title:"联系人姓名",key:"name",minWidth:100},{title:"联系方式",key:"phone",minWidth:100},{title:"供应商状态",slot:"is_show",minWidth:100},{title:"创建时间",key:"_add_time",minWidth:100},{title:"备注",key:"mark",minWidth:100},{title:"排序",key:"sort",minWidth:100},{title:"操作",slot:"action",minWidth:150}],tabList:[]}},computed:function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?l(r,!0).forEach((function(e){d(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):l(r).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({},Object(a.e)("admin/layout",["isMobile"]),{labelWidth:function(){return this.isMobile?void 0:80},labelPosition:function(){return this.isMobile?"top":"right"}}),watch:{},created:function(){this.getSupplier()},mounted:function(){},methods:{addSupplier:function(){this.$router.push({path:this.roterPre+"/supplier/supplierAdd"})},pageChange:function(t){this.page.pageNum=t,this.getSupplier()},limitChange:function(t){this.page.pageSize=t,this.getSupplier()},getSupplier:function(){var t=this,e={keywords:this.keywords,page:this.page.pageNum,limit:this.page.pageSize};Object(u.J)(e).then(function(){var e=p(i.a.mark((function e(r){return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.tabList=r.data.list,r.data.status,t.page.total=r.data.count;case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){t.$Message.error(e.msg)}))},edit:function(t){this.$router.push({path:this.roterPre+"/supplier/supplierAdd/"+t.id})},onchangeIsShow:function(t){var e=this;Object(u.z)(t.id,t.is_show).then(function(){var t=p(i.a.mark((function t(r){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e.$Message.success(r.msg);case 1:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.$$Message.error(t.msg)}))},goSupplier:function(t){var e=this;Object(u.K)(t.id).then(function(){var r=p(i.a.mark((function r(n){var a,u,c,p;return i.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:a=n.data,u=a.expires_time,o.a.cookies.setSupplier("token",a.token,{expires:u}),o.a.cookies.setSupplier("uuid",a.user_info.id,{expires:u}),o.a.cookies.setSupplier("expires_time",u,{expires:u}),o.a.makeMenu("/".concat(a.prefix),a.menus),(c=window.localStorage).setItem("menuListSupplier",JSON.stringify(a.menus)),c.setItem("uniqueAuthSupplier",JSON.stringify(a.unique_auth)),p={account:a.user_info.account,head_pic:a.user_info.avatar,logo:a.logo,logoSmall:a.logo_square,version:a.version},c.setItem("userInfoSupplier",JSON.stringify(p)),e.BaseURL=s.a.apiBaseURL.replace(/adminapi/,"".concat(t.prefix,"/home/")),window.open(e.BaseURL);case 13:case"end":return r.stop()}}),r)})));return function(t){return r.apply(this,arguments)}}()).catch((function(t){e.$Message.error(t.msg)}))},del:function(t,e,r){var n=this,i={ids:t.id},a={title:e,num:0,url:"/supplier/supplier/".concat(i.ids),method:"DELETE",ids:i};this.$modalSure(a).then((function(t){n.$Message.success(t.msg),n.tabList.splice(r,1),n.tabList.length||(n.page.pageNum=1==n.page.pageNum?1:n.page.pageNum-1),n.getSupplier()})).catch((function(t){n.$Message.error(t.msg)}))}}},h=(r("83b7"),r("2877")),m=Object(h.a)(f,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",[r("Card",{staticClass:"ivu-mt",attrs:{bordered:!1,"dis-hover":"",padding:0}},[r("Form",{staticClass:"formValidate mt20",attrs:{inline:"","label-width":80},nativeOn:{submit:function(t){t.preventDefault()}}},[r("FormItem",{attrs:{label:"搜索:","label-for":"store_name"}},[r("Input",{staticClass:"input-add",attrs:{placeholder:"请输入供应商名称"},model:{value:t.keywords,callback:function(e){t.keywords=e},expression:"keywords"}}),r("Button",{attrs:{type:"primary"},on:{click:function(e){return t.getSupplier()}}},[t._v("查询")])],1)],1)],1),r("Card",{staticClass:"ivu-mt",attrs:{bordered:!1,"dis-hover":""}},[r("Button",{staticClass:"btn",attrs:{type:"primary"},on:{click:t.addSupplier}},[t._v("添加供应商")]),r("Table",{ref:"table",staticClass:"orderData ivu-mt",attrs:{columns:t.columns,data:t.tabList,"highlight-row":"","no-data-text":"暂无数据","no-filtered-data-text":"暂无筛选结果"},scopedSlots:t._u([{key:"is_show",fn:function(e){var n=e.row;return e.index,[r("i-switch",{attrs:{"true-value":1,"false-value":0,size:"large"},on:{"on-change":function(e){return t.onchangeIsShow(n)}},model:{value:n.is_show,callback:function(e){t.$set(n,"is_show",e)},expression:"row.is_show"}},[r("span",{attrs:{slot:"open"},slot:"open"},[t._v("开启")]),r("span",{attrs:{slot:"close"},slot:"close"},[t._v("关闭")])])]}},{key:"action",fn:function(e){var n=e.row,i=e.index;return[r("a",{on:{click:function(e){return t.goSupplier(n)}}},[t._v("进入")]),r("Divider",{attrs:{type:"vertical"}}),r("a",{on:{click:function(e){return t.edit(n)}}},[t._v("编辑")]),r("Divider",{attrs:{type:"vertical"}}),r("a",{staticClass:"del",on:{click:function(e){return t.del(n,"删除供应商(同步删除商品)",i)}}},[t._v("删除")])]}}])}),r("div",[r("div",{staticClass:"acea-row row-right page"},[r("Page",{attrs:{total:t.page.total,current:t.page.pageNum,"show-elevator":"","show-total":"","page-size":t.page.pageSize,"show-sizer":""},on:{"on-change":t.pageChange,"on-page-size-change":t.limitChange}})],1)])],1)],1)}),[],!1,null,"ee8790f6",null);e.default=m.exports},"4f1e":function(t,e,r){},6112:function(t,e,r){"use strict";r.r(e);var n=r("f478");function i(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function a(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}r("2f62");var o={name:"rightConfig",components:function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?i(r,!0).forEach((function(e){a(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):i(r).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({},r("2542").a),props:{name:{type:null,default:""},pageId:{type:Number,default:0}},computed:{defultArr:function(){this.$store.dispatch("admin/user/getPageName");var t=this.$store.state.admin.user.pageName;return this.$store.state.admin[t].component}},watch:{name:{handler:function(t,e){this.rCom=[];var r=this.$store.state.admin.user.pageName;if(this.configData=this.$store.state.admin[r].defaultConfig[t],this.rCom=this.$store.state.admin[r].component[t].list,this.configData.selectConfig){var n=this.configData.selectConfig.type?this.configData.selectConfig.type:"";this.configData.selectConfig.list=this.categoryList,n?this.getByCategory():this.getCategory()}},deep:!0},defultArr:{handler:function(t,e){this.rCom=[],this.objToArray(t),this.rCom=t[this.name].list},deep:!0}},data:function(){return{rCom:[],configData:{},isShow:!0,categoryList:[],status:0}},mounted:function(){this.storeStatus()},methods:{storeStatus:function(){var t=this;Object(n.v)().then((function(e){t.status=parseInt(e.data.store_status)}))},getCategory:function(){var t=this;Object(n.g)().then((function(e){var r=[];e.data.map((function(t){r.push({title:t.title,pid:t.pid,activeValue:t.id.toString()})})),t.categoryList=r,t.bus.$emit("upData",r)}))},getByCategory:function(){var t=this;Object(n.f)().then((function(e){var r=[];e.data.map((function(t){r.push({title:t.cate_name,pid:t.pid,activeValue:t.id.toString()})})),t.categoryList=r,t.bus.$emit("upData",r)}))},saveConfig:function(){var t=this,e=this.$store.state.admin.user.pageName,r=this.$store.state.admin[e].defaultConfig,i=this.$store.state.admin[e].periphery;if("z_tabBar"==this.name){if(!i||!this.status)for(var a=r.z_tabBar.tabBarList.list,o=0;o<a.length;o++)if("/pages/storeList/index"==a[o].link||"pages/storeList/index"==a[o].link)return this.$Message.error("请先开启您的周边功能(/pages/storeList/index)");if(r.z_tabBar.tabBarList.list.length<2)return this.$Message.error("您最少应添加2个导航")}Object(n.e)(this.pageId,{value:r}).then((function(e){t.$Message.success("保存成功")}))},objToArray:function(t){var e=[];for(var r in t)e.push(t[r]);return e}}},s=(r("ac64"),r("2877")),u={name:"index",components:{rightConfig:Object(s.a)(o,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return t.rCom.length?r("div",{staticClass:"right-box"},[r("div",{staticClass:"title-bar"},[t._v("模块配置")]),t.rCom.length?r("div",{staticClass:"mobile-config"},[t._l(t.rCom,(function(e,n){return r("div",{key:n},[r(e.components.name,{tag:"component",attrs:{name:e.configNme,configData:t.configData}})],1)})),t.rCom.length?r("div",{staticStyle:{"text-align":"center"}},[r("Button",{staticStyle:{width:"100%",margin:"0 auto",height:"40px"},attrs:{type:"primary"},on:{click:t.saveConfig}},[t._v("保存")])],1):t._e()],2):t._e()]):t._e()}),[],!1,null,"1ba31462",null).exports,links:r("2250").default},data:function(){return{configName:"",iframeUrl:"",setConfig:"",updataConfig:"",pageId:0}},created:function(){var t=this,e=this.$route.query.id,r=this.$route.query.name;this.setConfig="admin/"+r+"/setConfig",this.updataConfig="admin/"+r+"/updataConfig",this.pageId=parseInt(e),this.iframeUrl="".concat(location.origin,"?type=iframeMakkMinkkJuan"),Object(n.c)(parseInt(e)).then((function(e){var r=e.data.info.value;t.upData(r)}))},mounted:function(){window.addEventListener("message",this.handleMessage,!1)},methods:{handleMessage:function(t){t.data.name&&(this.configName=t.data.name,this.add(t.data.name))},add:function(t){this.$store.commit(this.setConfig,t)},upData:function(t){this.$store.commit(this.updataConfig,t)}}},c=(r("f369"),Object(s.a)(u,(function(){var t=this.$createElement,e=this._self._c||t;return e("div",[e("div",{staticClass:"i-layout-page-header"},[e("PageHeader",{staticClass:"product_tabs",attrs:{"hidden-breadcrumb":""}},[e("div",{attrs:{slot:"title"},slot:"title"},[e("router-link",{attrs:{to:{path:this.roterPre+"/setting/pages/devise"}}},[e("Button",{staticClass:"mr20",attrs:{icon:"ios-arrow-back",size:"small"}},[this._v("返回")])],1),e("span",{staticClass:"mr20",domProps:{textContent:this._s("页面设计")}})],1)])],1),e("Card",{staticClass:"ivu-mt",attrs:{bordered:!1,"dis-hover":""}},[e("div",{staticClass:"flex-wrapper"},[e("iframe",{ref:"iframe",staticClass:"iframe-box",attrs:{src:this.iframeUrl,frameborder:"0"}}),e("div",[e("div",{staticClass:"content"},[e("rightConfig",{attrs:{name:this.configName,pageId:this.pageId}})],1)]),e("links")],1)])],1)}),[],!1,null,"46bbd42e",null));e.default=c.exports},"634a":function(t,e,r){},7999:function(t,e,r){},"83b7":function(t,e,r){"use strict";var n=r("7999");r.n(n).a},a6b9:function(t,e,r){"use strict";r.d(e,"J",(function(){return i})),r.d(e,"n",(function(){return a})),r.d(e,"a",(function(){return o})),r.d(e,"y",(function(){return s})),r.d(e,"z",(function(){return u})),r.d(e,"o",(function(){return c})),r.d(e,"h",(function(){return p})),r.d(e,"b",(function(){return l})),r.d(e,"v",(function(){return d})),r.d(e,"c",(function(){return f})),r.d(e,"B",(function(){return h})),r.d(e,"j",(function(){return m})),r.d(e,"l",(function(){return g})),r.d(e,"w",(function(){return b})),r.d(e,"r",(function(){return v})),r.d(e,"s",(function(){return y})),r.d(e,"u",(function(){return O})),r.d(e,"x",(function(){return w})),r.d(e,"K",(function(){return j})),r.d(e,"t",(function(){return _})),r.d(e,"k",(function(){return C})),r.d(e,"m",(function(){return k})),r.d(e,"q",(function(){return S})),r.d(e,"A",(function(){return x})),r.d(e,"g",(function(){return $})),r.d(e,"f",(function(){return P})),r.d(e,"p",(function(){return D})),r.d(e,"i",(function(){return L})),r.d(e,"F",(function(){return I})),r.d(e,"G",(function(){return N})),r.d(e,"I",(function(){return M})),r.d(e,"d",(function(){return B})),r.d(e,"H",(function(){return z})),r.d(e,"e",(function(){return E})),r.d(e,"C",(function(){return W})),r.d(e,"E",(function(){return A})),r.d(e,"L",(function(){return J})),r.d(e,"D",(function(){return U}));var n=r("b6bd");function i(t){return Object(n.a)({url:"supplier/supplier",method:"get",params:t})}function a(t){return Object(n.a)({url:"/supplier/supplier/".concat(t),method:"get"})}function o(t){return Object(n.a)({url:"supplier/supplier",method:"post",data:t})}function s(t,e){return Object(n.a)({url:"supplier/supplier/".concat(t),method:"put",data:e})}function u(t,e){return Object(n.a)({url:"/supplier/supplier/set_status/".concat(t,"/").concat(e),method:"put"})}function c(t){return Object(n.a)({url:"/supplier/list",method:"get",params:t})}function p(t){return Object(n.a)({url:"/supplier/order/list",method:"get",params:t})}function l(t){return Object(n.a)({url:"/supplier/order/deliver_remind/".concat(t.supplier_id,"/").concat(t.id),method:"put"})}function d(t){return Object(n.a)({url:"/supplier/order/info/".concat(t),method:"get"})}function f(t){return Object(n.a)({url:"/supplier/order/distribution_info",method:"get",params:{ids:t}})}function h(t,e){return Object(n.a)({url:"/supplier/order/split_order/"+t,method:"get",params:e})}function m(t){return Object(n.a)({url:"/supplier/order/status/".concat(t.id),method:"get",params:t.datas})}function g(t){return Object(n.a)({url:"/supplier/order/refund/".concat(t),method:"get"})}function b(t){return Object(n.a)({url:"/supplier/refund/list",method:"get",params:t})}function v(t){return Object(n.a)({url:"/supplier/home/header",method:"get",params:t})}function y(t){return Object(n.a)({url:"/supplier/home/order",method:"get",params:t})}function O(t){return Object(n.a)({url:"/supplier/home/order_channel",method:"get",params:t})}function w(t){return Object(n.a)({url:"/supplier/home/order_type",method:"get",params:t})}function j(t){return Object(n.a)({url:"/supplier/supplier/login/".concat(t),method:"get"})}function _(t){return Object(n.a)({url:"/supplier/home/supplier",method:"get",params:t})}function C(t){return Object(n.a)({url:"/supplier/refund/detail/".concat(t),method:"get"})}function k(t){return Object(n.a)({url:"/supplier/refund/refund/".concat(t),method:"get"})}function S(t){return Object(n.a)({url:"/supplier/order/no_refund/".concat(t),method:"get"})}function x(t){return Object(n.a)({url:"/supplier/order/refund_integral/".concat(t),method:"get"})}function $(t){return Object(n.a)({url:"/supplier/order/distribution/".concat(t),method:"get"})}function P(t){return Object(n.a)({url:"/supplier/apply/list",method:"get",params:t})}function D(t){return Object(n.a)({url:"/supplier/apply/verify/form/".concat(t),method:"get"})}function L(t){return Object(n.a)({url:"/supplier/apply/mark/form/".concat(t),method:"get"})}function I(t){return Object(n.a)({url:"/supplier/flowing_water/fund_record_info",method:"get",params:t})}function N(t){return Object(n.a)({url:"/supplier/flowing_water/list",method:"get",params:t})}function M(t,e){return Object(n.a)({url:"/supplier/flowing_water/mark/".concat(t),method:"put",params:e})}function B(t){return Object(n.a)({url:"/export/supplierWaterExport",method:"get",params:t})}function z(t){return Object(n.a)({url:"/supplier/flowing_water/fund_record",method:"get",params:t})}function E(t){return Object(n.a)({url:"/export/supplierWaterRecord",method:"get",params:t})}function W(t){return Object(n.a)({url:"/supplier/extract/list",method:"get",params:t})}function A(t,e){return Object(n.a)({url:"/supplier/extract/verify/".concat(t),method:"post",data:e})}function J(t){return Object(n.a)({url:"/supplier/extract/transfer/".concat(t),method:"get"})}function U(t,e){return Object(n.a)({url:"/supplier/extract/mark/".concat(t),method:"post",data:e})}},ac64:function(t,e,r){"use strict";var n=r("4f1e");r.n(n).a},f369:function(t,e,r){"use strict";var n=r("634a");r.n(n).a}}]);
|