commodity.d90d8118.js 22 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["commodity"],{"129f":function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e===1/t:e!=e&&t!=t}},1848:function(e,t,n){},"4e7b":function(e,t,n){"use strict";n("1848")},5153:function(e,t,n){"use strict";var a=n("c7eb"),r=n("1da1"),o=n("d4ec"),i=n("bee2"),s=n("262e"),c=n("2caf"),l=n("ff2d"),u=n("bc3a"),p=n.n(u),d=n("f121"),m=n.n(d),h=function(e){Object(s["a"])(n,e);var t=Object(c["a"])(n);function n(){var e;return Object(o["a"])(this,n),e=t.call(this),p.a.defaults.baseURL=m.a.Host85,e}return Object(i["a"])(n,[{key:"commodityTypeAll",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/type/list",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commodityTypeList",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/type/search/list",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commodityTypeSingle",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/type/search/single",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commodityTypeAdd",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/type/add",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commodityTypeUpdate",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/type/update",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commodityTypeDelete",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/type/delete",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commodityList",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/search/list",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commoditySingle",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/search/single",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commodityAdd",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/add",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commodityUpdate",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/update",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"commodityDelete",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/commodity/delete",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"customFeedbackList",value:function(){var e=Object(r["a"])(Object(a["a"])().mark((function e(){var t,n,r=arguments;return Object(a["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=r.length>0&&void 0!==r[0]?r[0]:{},e.next=3,this.post("/custom/feedback/search/list",t);case 3:return n=e.sent,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()}]),n}(l["a"]);t["a"]=new h},"841c":function(e,t,n){"use strict";var a=n("c65b"),r=n("d784"),o=n("825a"),i=n("7234"),s=n("1d80"),c=n("129f"),l=n("577e"),u=n("dc4a"),p=n("14c3");r("search",(function(e,t,n){return[function(t){var n=s(this),r=i(t)?void 0:u(t,e);return r?a(r,t,n):new RegExp(t)[e](l(n))},function(e){var a=o(this),r=l(e),i=n(t,a,r);if(i.done)return i.value;var s=a.lastIndex;c(s,0)||(a.lastIndex=0);var u=p(a,r);return c(a.lastIndex,s)||(a.lastIndex=s),null===u?-1:u.index}]}))},b99d:function(e,t,n){"use strict";n.r(t);n("ac1f"),n("841c"),n("b0c0"),n("498a");var a=function(){var e=this,t=e._self._c;return t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.pictLoading,expression:"pictLoading"}],staticClass:"view",attrs:{id:"CommodityList","element-loading-background":"rgba(43, 48, 67, 0.65)","element-loading-spinner":"el-icon-loading"}},[t("div",{staticClass:"crm_search"},[t("el-form",{ref:"form",attrs:{"label-position":"",model:e.search,"label-width":""}},[t("el-row",[t("el-col",{attrs:{span:24,md:24,lg:24}},[t("el-form-item",{staticStyle:{"margin-right":"10px"}},[t("el-select",{staticClass:"crm_search_down_special crm-border-radius-no",attrs:{size:"small",placeholder:e.$t("Order_info.CommodityTypeName")},model:{value:e.search.typeId,callback:function(t){e.$set(e.search,"typeId",t)},expression:"search.typeId"}},[t("el-option",{attrs:{label:e.$t("Commodity_info.All"),value:""},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}}),e._l(e.commodityTypeAll,(function(n,a){return t("el-option",{key:a,attrs:{label:"cn"==e.lang?n.name:n.nameEn,value:n.id},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}})}))],2)],1),t("el-form-item",{staticStyle:{"margin-right":"10px"}},[t("el-select",{staticClass:"crm_search_down_special crm-border-radius-no",attrs:{size:"small",placeholder:e.$t("Order_info.CommodityLevel")},model:{value:e.search.level,callback:function(t){e.$set(e.search,"level",t)},expression:"search.level"}},[t("el-option",{attrs:{label:e.$t("Commodity_info.All"),value:""},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}}),t("el-option",{attrs:{label:1,value:1},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}}),t("el-option",{attrs:{label:2,value:2},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}})],1)],1),t("el-form-item",{staticStyle:{"margin-right":"10px"}},[t("el-select",{staticClass:"crm_search_down_special crm-border-radius-no",attrs:{size:"small",placeholder:e.$t("Commodity_info.Recommenders")},model:{value:e.search.recommender,callback:function(t){e.$set(e.search,"recommender",t)},expression:"search.recommender"}},[t("el-option",{attrs:{label:e.$t("Commodity_info.Recommenders"),value:""},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}}),t("el-option",{attrs:{label:e.$t("Commodity_info.Recommenders2"),value:0},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}}),t("el-option",{attrs:{label:e.$t("Commodity_info.Recommenders1"),value:1},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}})],1)],1),t("el-form-item",{staticStyle:{"margin-right":"10px"}},[t("el-select",{staticClass:"crm_search_down_special crm-border-radius-no",attrs:{size:"small",placeholder:e.$t("Commodity_info.Show")},model:{value:e.search.show,callback:function(t){e.$set(e.search,"show",t)},expression:"search.show"}},[t("el-option",{attrs:{label:e.$t("Commodity_info.All"),value:""},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}}),t("el-option",{attrs:{label:e.$t("Btn.No"),value:0},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}}),t("el-option",{attrs:{label:e.$t("Btn.Yes"),value:1},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}})],1)],1),t("el-form-item",{staticStyle:{"margin-right":"10px"}},[t("el-select",{staticClass:"crm_search_down_special crm-border-radius-no",attrs:{size:"small",placeholder:e.$t("Commodity_info.Lang")},model:{value:e.search.lang,callback:function(t){e.$set(e.search,"lang",t)},expression:"search.lang"}},[t("el-option",{attrs:{label:e.$t("Commodity_info.All"),value:""},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}}),t("el-option",{attrs:{label:e.$t("Label.CN"),value:"cn"},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}}),t("el-option",{attrs:{label:e.$t("Label.EN"),value:"en"},nativeOn:{click:function(t){return e.toSearch.apply(null,arguments)}}})],1)],1),t("el-form-item",{staticStyle:{"margin-right":"15px"}},[t("el-input",{staticClass:"crm-border-radius-no",staticStyle:{"margin-top":"5px"},attrs:{clearable:"",size:"small",placeholder:e.$t("Placeholder.Input")},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.toSearch.apply(null,arguments)}},model:{value:e.search.name,callback:function(t){e.$set(e.search,"name","string"===typeof t?t.trim():t)},expression:"search.name"}},[t("template",{slot:"prepend"},[t("span",{directives:[{name:"t",rawName:"v-t",value:"Commodity_info.Name",expression:"'Commodity_info.Name'"}],staticClass:"crm-cursor"})])],2)],1),t("el-form-item",[t("el-date-picker",{staticClass:"crm_date_pick crm-border-radius-no",attrs:{type:"daterange",align:"right","unlink-panels":"","value-format":"yyyy-MM-dd","range-separator":"-",size:"small","start-placeholder":e.$t("Placeholder.Start"),"end-placeholder":e.$t("Placeholder.End")},on:{input:e.getSearchDate},model:{value:e.search.date,callback:function(t){e.$set(e.search,"date",t)},expression:"search.date"}}),t("el-button",{staticClass:"crm-border-radius-no crm-border-left-no",attrs:{size:"small",icon:"el-icon-search"},on:{click:e.toSearch}})],1)],1)],1),t("el-form-item",[t("div",{staticClass:"search_action_btn"},[t("span",{staticClass:"crm-cursor",on:{click:e.toNew}},[t("i",{staticClass:"el-icon-plus"}),e.display["R-Shop-Commodity-List-Add"].show?t("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.Add",expression:"'Btn.Add'"}]}):e._e()]),e.display["R-Shop-Commodity-List-Delete"].show?t("span",{staticClass:"crm-cursor delete",class:{active:this.multipleSelection.length},on:{click:e.toDeleteBatch}},[t("i",{staticClass:"el-icon-minus"}),t("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.Delete",expression:"'Btn.Delete'"}]})]):e._e()])])],1)],1),t("el-table",{staticStyle:{width:"100%"},attrs:{data:e.mock_tableData,stripe:""},on:{"sort-change":e.toSort,"selection-change":e.handleSelectionChange}},[t("el-table-column",{attrs:{align:"center",type:"selection",width:"55"}}),t("el-table-column",{attrs:{prop:"",label:e.$i18n.t("Commodity_info.Name")},scopedSlots:e._u([{key:"default",fn:function(n){return[n.row.name?t("span",{staticClass:"crm-text-underline crm-cursor crm-one-font",on:{click:function(t){return e.accountOpen(n.row.id)}}},[t("i",{staticClass:"el-icon-caret-right"}),e._v(e._s(n.row.name||"--"))]):t("span",[e._v(e._s("--"))])]}}])}),t("el-table-column",{attrs:{prop:"",align:"left",label:e.$i18n.t("Commodity_info.Lang")},scopedSlots:e._u([{key:"default",fn:function(n){return["cn"==n.row.lang?t("span",{directives:[{name:"t",rawName:"v-t",value:"Label.CN",expression:"'Label.CN'"}]}):e._e(),"en"==n.row.lang?t("span",{directives:[{name:"t",rawName:"v-t",value:"Label.EN",expression:"'Label.EN'"}]}):e._e()]}}])}),t("el-table-column",{attrs:{prop:"",align:"left",label:e.$i18n.t("Commodity_info.Subindex")},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(t.row.subIndex)+" ")]}}])}),t("el-table-column",{attrs:{prop:"",align:"left",label:e.$i18n.t("Commodity_info.Type")},scopedSlots:e._u([{key:"default",fn:function(n){return e._l(e.commodityTypeAll,(function(a){return t("div",{key:a.id},[n.row.typeId==a.id?t("span",[e._v(e._s("cn"==e.lang?a.name:a.nameEn))]):e._e()])}))}}])}),t("el-table-column",{attrs:{prop:"",align:"left",label:e.$i18n.t("Commodity_info.Level")},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(t.row.level)+" ")]}}])}),t("el-table-column",{attrs:{prop:"integral",align:"left",sortable:"custom",label:e.$i18n.t("Commodity_info.Point")},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(e._f("NumberFormat")(t.row.integral))+" ")]}}])}),t("el-table-column",{attrs:{prop:"price",align:"left",sortable:"custom",label:e.$i18n.t("Commodity_info.Price")},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(e._f("NumberFormat")(t.row.price))+" ")]}}])}),t("el-table-column",{attrs:{prop:"number",align:"left",sortable:"custom",label:e.$i18n.t("Commodity_info.Number")},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(t.row.number)+" ")]}}])}),t("el-table-column",{attrs:{prop:"recommender",align:"left",sortable:"custom",label:e.$i18n.t("Commodity_info.Recommender")},scopedSlots:e._u([{key:"default",fn:function(n){return["0"==n.row.recommender?t("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.No",expression:"'Btn.No'"}]}):e._e(),"1"==n.row.recommender?t("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.Yes",expression:"'Btn.Yes'"}]}):e._e()]}}])}),t("el-table-column",{attrs:{prop:"",align:"left",label:e.$i18n.t("Commodity_info.Show")},scopedSlots:e._u([{key:"default",fn:function(n){return["0"==n.row.show?t("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.No",expression:"'Btn.No'"}]}):e._e(),"1"==n.row.show?t("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.Yes",expression:"'Btn.Yes'"}]}):e._e()]}}])}),t("el-table-column",{attrs:{prop:"",align:"left",label:e.$i18n.t("Commodity_info.AddTime")},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(t.row.addTime||"--")+" ")]}}])}),t("el-table-column",{attrs:{prop:"",align:"left",label:e.$i18n.t("Commodity_info.StartTime")},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(t.row.startTime||"--")+" ")]}}])}),t("el-table-column",{attrs:{prop:"",align:"left",label:e.$i18n.t("Commodity_info.ExpirationTime")},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(t.row.endTime||"--")+" ")]}}])}),t("el-table-column",{attrs:{prop:"",align:"center",label:e.$i18n.t("Label.Action")},scopedSlots:e._u([{key:"default",fn:function(n){return[t("el-dropdown",{attrs:{trigger:"click"},on:{command:e.handleCommand}},[t("span",{staticClass:"el-dropdown-link crm-cursor"},[t("i",{staticClass:"iconfont iconcaidan",staticStyle:{"font-weight":"bold","font-size":"20px"}})]),t("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},[e.display["R-Shop-Commodity-List-Update"].show?t("el-dropdown-item",{attrs:{command:{type:"editor",id:n.row.id}}},[t("i",{staticClass:"iconfont iconbianji3"}),t("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.Editor",expression:"'Btn.Editor'"}]})]):e._e(),e.display["R-Shop-Commodity-List-Delete"].show?t("el-dropdown-item",{attrs:{command:{type:"delete",id:n.row.id}}},[t("i",{staticClass:"iconfont iconshanchu"}),t("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.Delete",expression:"'Btn.Delete'"}]})]):e._e()],1)],1)]}}])})],1),e.pagerInfo.rowTotal?t("div",{staticClass:"crm_pagination"},[t("div",{staticClass:"crm_page_total"},[t("span",{directives:[{name:"t",rawName:"v-t",value:"Page.total.item1",expression:"'Page.total.item1'"}]}),t("span",[e._v(e._s(e.pagerInfo.rowTotal))]),t("span",{directives:[{name:"t",rawName:"v-t",value:"Page.total.item2",expression:"'Page.total.item2'"}]})]),t("el-pagination",{staticClass:"page",attrs:{background:"",layout:"sizes, prev, pager, next","page-sizes":[10,20,50,100],"page-size":e.pagerInfo.row,total:e.pagerInfo.rowTotal},on:{"current-change":e.handleCurrentChange,"size-change":e.handleSizeChange}})],1):e._e()],1)},r=[],o=n("c7eb"),i=n("5530"),s=n("1da1"),c=(n("d3b7"),n("159b"),n("5153")),l=n("f121"),u=n.n(l),p=u.a.Code,d={name:"CommodityList",data:function(){return{pictLoading:!1,mock_tableData:[],search:{name:"",level:null,typeId:null,recommender:null,show:null,sortName:"",sortType:null,lang:null,date:[],startDate:"",endDate:""},commodityTypeAll:[],multipleSelection:[],pagerInfo:{row:10,current:1,pageTotal:0,rowTotal:0}}},computed:{display:function(){return JSON.parse(this.Session.Get("display",!0))},lang:function(){return this.Session.Get("lang")}},methods:{toSort:function(e){this.search.sortName=e.prop,this.search.sortType="descending"==e.order?1:2,this.toSearch()},handleCommand:function(e){"delete"==e.type?this.toDelete(e.id):"editor"==e.type&&this.toUpdate(e.id)},searchFunc:function(){var e=this;return Object(s["a"])(Object(o["a"])().mark((function t(){var n;return Object(o["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(e.pictLoading=!0,e.display["R-Shop-Commodity-List-Search"].show){t.next=5;break}return e.$pigeon.MessageWarning(e.$i18n.t("Msg.NotDisplay")),e.pictLoading=!1,t.abrupt("return");case 5:return null==e.search.date||0==e.search.date.length?(e.search.startDate="",e.search.endDate=""):(e.search.startDate=e.search.date[0],e.search.endDate=e.search.date[1]),t.next=8,c["a"].commodityList(Object(i["a"])(Object(i["a"])({},e.search),{},{page:{current:e.pagerInfo.current,row:e.pagerInfo.row}}));case 8:n=t.sent,n.code==p.StatusOK?(e.mock_tableData=n.data,null!=n.page?(e.pagerInfo.rowTotal=n.page.rowTotal,e.pagerInfo.pageTotal=n.page.pageTotal):e.pagerInfo.rowTotal=0,e.$pigeon.MessageOK(e.$i18n.t("Msg.SearchSuccess")),e.pictLoading=!1):(e.$pigeon.MessageError(n.msg),e.pictLoading=!1);case 10:case"end":return t.stop()}}),t)})))()},getSearchDate:function(e){this.search.date=e},toSearch:function(){this.pagerInfo.current=1,this.searchFunc()},toNew:function(){this.$router.push({path:"/shop/commodity/list/add",query:{type:"add"}}).catch((function(e){return e}))},toUpdate:function(e){this.$router.push({path:"/shop/commodity/list/add",query:{id:e,type:"update"}}).catch((function(e){return e}))},accountOpen:function(e){this.$router.push({path:"/shop/commodity/list/single",query:{id:e}}).catch((function(e){return e}))},toDelete:function(){var e=Object(s["a"])(Object(o["a"])().mark((function e(t){var n;return Object(o["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:n=this,this.$pigeon.MessageConfirm(this.$i18n.t("Msg.Delete"),this.$i18n.t("Msg.SystemPrompt"),this.$i18n.t("Btn.Confirm"),this.$i18n.t("Btn.Cancel"),Object(s["a"])(Object(o["a"])().mark((function e(){var a,r;return Object(o["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return a=[],a.push(t),e.next=4,c["a"].commodityDelete({ids:a});case 4:r=e.sent,r.code==p.StatusOK?(n.$pigeon.MessageOK(n.$i18n.t("Msg.DeleteSuccess")),n.searchFunc()):n.$pigeon.MessageError(r.msg);case 6:case"end":return e.stop()}}),e)}))),(function(){}));case 2:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}(),toDeleteBatch:function(){var e=Object(s["a"])(Object(o["a"])().mark((function e(){var t;return Object(o["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.multipleSelection.length){e.next=2;break}return e.abrupt("return");case 2:t=this,this.$pigeon.MessageConfirm(this.$i18n.t("Msg.Delete"),this.$i18n.t("Msg.SystemPrompt"),this.$i18n.t("Btn.Confirm"),this.$i18n.t("Btn.Cancel"),Object(s["a"])(Object(o["a"])().mark((function e(){var n;return Object(o["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,c["a"].commodityDelete({ids:t.multipleSelection});case 2:n=e.sent,n.code==p.StatusOK?(t.$pigeon.MessageOK(t.$i18n.t("Msg.DeleteSuccess")),t.searchFunc()):t.$pigeon.MessageError(n.msg);case 4:case"end":return e.stop()}}),e)}))),(function(){}));case 4:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}(),handleSelectionChange:function(e){var t=this;this.multipleSelection=[],e.forEach((function(e){t.multipleSelection.push(e.id)}))},searchType:function(){var e=this;return Object(s["a"])(Object(o["a"])().mark((function t(){var n;return Object(o["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,c["a"].commodityTypeAll({});case 2:n=t.sent,n.code==p.StatusOK?e.commodityTypeAll=n.data:e.$pigeon.MessageError(n.msg);case 4:case"end":return t.stop()}}),t)})))()},handleSizeChange:function(e){this.pagerInfo.row=e,this.searchFunc()},handleCurrentChange:function(e){this.pagerInfo.current=e,this.searchFunc()}},mounted:function(){this.searchType(),this.searchFunc()}},m=d,h=(n("4e7b"),n("2877")),f=Object(h["a"])(m,a,r,!1,null,"f36304e2",null);t["default"]=f.exports}}]);