PointRules.fb8d5296.js 9.0 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["PointRules"],{4969:function(e,t,a){},"8b0a":function(e,t,a){"use strict";a("8bdd")},"8bdd":function(e,t,a){},a543:function(e,t,a){"use strict";a.r(t);a("498a");var s=function(){var e,t=this,a=t._self._c;return a("div",{directives:[{name:"loading",rawName:"v-loading",value:t.pictLoading,expression:"pictLoading"}],staticClass:"view",attrs:{id:"PointRules","element-loading-background":"rgba(43, 48, 67, 0.65)","element-loading-spinner":"el-icon-loading"}},[a("el-row",{staticClass:"box"},[a("div",{staticClass:"title",staticStyle:{"margin-bottom":"0"}},[a("div",{staticClass:"label"},[a("span")]),null!==(e=t.display["R-Shop-Point-Rules-Update"])&&void 0!==e&&e.show?a("div",{staticClass:"btnTab"},[t.btnType?a("span",[a("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.Save",expression:"'Btn.Save'"}],staticClass:"btn crm_state_blue crm-cursor",on:{click:t.toSave}}),a("span",{directives:[{name:"t",rawName:"v-t",value:"Btn.Cancel",expression:"'Btn.Cancel'"}],staticClass:"btn crm_state_red crm-cursor",on:{click:t.cancelSave}})]):a("span",{staticClass:"icon",on:{click:function(e){t.btnType=!0}}},[a("i",{staticClass:"el-icon-edit-outline crm-cursor"})])]):t._e()]),a("el-col",{staticClass:"table",attrs:{span:24}},[a("table",{attrs:{width:"100%",border:"1px"}},[a("tr",{staticClass:"table-title"},[a("td",{directives:[{name:"t",rawName:"v-t",value:"system_info.Label.ShopSymbolType",expression:"'system_info.Label.ShopSymbolType'"}]}),a("td",{directives:[{name:"t",rawName:"v-t",value:"system_info.Label.ShopbelongType",expression:"'system_info.Label.ShopbelongType'"}]}),a("td",{directives:[{name:"t",rawName:"v-t",value:"system_info.Label.ShopTotal",expression:"'system_info.Label.ShopTotal'"}]}),a("td",{directives:[{name:"t",rawName:"v-t",value:"system_info.Label.ShopCustom",expression:"'system_info.Label.ShopCustom'"}]}),a("td",{directives:[{name:"t",rawName:"v-t",value:"system_info.Label.ShopLevelOne",expression:"'system_info.Label.ShopLevelOne'"}]}),a("td",{directives:[{name:"t",rawName:"v-t",value:"system_info.Label.ShopLevelTwo",expression:"'system_info.Label.ShopLevelTwo'"}]}),a("td",{directives:[{name:"t",rawName:"v-t",value:"system_info.Label.ShopLevelThree",expression:"'system_info.Label.ShopLevelThree'"}]}),a("td",{directives:[{name:"t",rawName:"v-t",value:"system_info.Label.ShopLevelFour",expression:"'system_info.Label.ShopLevelFour'"}]})]),t._l(t.mock_tableData.index,(function(e){return a("tr",{key:e.id,staticClass:"table-con"},[a("td",[a("el-select",{staticClass:"crm_search_down table-input",attrs:{disabled:"",size:"",placeholder:t.$t("Placeholder.Choose")},model:{value:e.symbolType,callback:function(a){t.$set(e,"symbolType",a)},expression:"item.symbolType"}},[a("el-option",{attrs:{label:t.$t("system_info.Label.ShopIndexSymbol"),value:3}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopOtherSymbol"),value:99}})],1)],1),a("td",[a("el-select",{staticClass:"crm_search_down table-input",attrs:{disabled:"",size:"",placeholder:t.$t("Placeholder.Choose")},model:{value:e.belongType,callback:function(a){t.$set(e,"belongType",a)},expression:"item.belongType"}},[a("el-option",{attrs:{label:t.$t("system_info.Label.ShopCompanyCus"),value:1}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopSaleCus"),value:2}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopLevelOneCus"),value:3}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopLevelTwoCus"),value:4}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopLevelThreeCus"),value:5}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopLevelFourCus"),value:6}})],1)],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.total,callback:function(a){t.$set(e,"total","string"===typeof a?a.trim():a)},expression:"item.total"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.custom,callback:function(a){t.$set(e,"custom","string"===typeof a?a.trim():a)},expression:"item.custom"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.levelOne,callback:function(a){t.$set(e,"levelOne","string"===typeof a?a.trim():a)},expression:"item.levelOne"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.levelTwo,callback:function(a){t.$set(e,"levelTwo","string"===typeof a?a.trim():a)},expression:"item.levelTwo"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.levelThree,callback:function(a){t.$set(e,"levelThree","string"===typeof a?a.trim():a)},expression:"item.levelThree"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.levelFour,callback:function(a){t.$set(e,"levelFour","string"===typeof a?a.trim():a)},expression:"item.levelFour"}})],1)])})),t._l(t.mock_tableData.other,(function(e){return a("tr",{key:e.id,staticClass:"table-con"},[a("td",[a("el-select",{staticClass:"crm_search_down table-input",attrs:{disabled:"",size:"",placeholder:t.$t("Placeholder.Choose")},model:{value:e.symbolType,callback:function(a){t.$set(e,"symbolType",a)},expression:"item.symbolType"}},[a("el-option",{attrs:{label:t.$t("system_info.Label.ShopIndexSymbol"),value:3}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopOtherSymbol"),value:99}})],1)],1),a("td",[a("el-select",{staticClass:"crm_search_down table-input",attrs:{disabled:"",size:"",placeholder:t.$t("Placeholder.Choose")},model:{value:e.belongType,callback:function(a){t.$set(e,"belongType",a)},expression:"item.belongType"}},[a("el-option",{attrs:{label:t.$t("system_info.Label.ShopCompanyCus"),value:1}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopSaleCus"),value:2}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopLevelOneCus"),value:3}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopLevelTwoCus"),value:4}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopLevelThreeCus"),value:5}}),a("el-option",{attrs:{label:t.$t("system_info.Label.ShopLevelFourCus"),value:6}})],1)],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.total,callback:function(a){t.$set(e,"total","string"===typeof a?a.trim():a)},expression:"item.total"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.custom,callback:function(a){t.$set(e,"custom","string"===typeof a?a.trim():a)},expression:"item.custom"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.levelOne,callback:function(a){t.$set(e,"levelOne","string"===typeof a?a.trim():a)},expression:"item.levelOne"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.levelTwo,callback:function(a){t.$set(e,"levelTwo","string"===typeof a?a.trim():a)},expression:"item.levelTwo"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.levelThree,callback:function(a){t.$set(e,"levelThree","string"===typeof a?a.trim():a)},expression:"item.levelThree"}})],1),a("td",[a("el-input",{staticClass:"table-input",attrs:{disabled:!t.btnType,type:"text"},model:{value:e.levelFour,callback:function(a){t.$set(e,"levelFour","string"===typeof a?a.trim():a)},expression:"item.levelFour"}})],1)])}))],2)])],1)],1)},l=[],n=a("c7eb"),o=a("5530"),i=a("1da1"),r=a("da7c"),c=a("f121"),p=a.n(c),u=p.a.Code,b={name:"PointRules",data:function(){return{pictLoading:!1,mock_tableData:{},btnType:!1}},computed:{display:function(){return this.Session.GetDisplay()},lang:function(){return this.Session.Get("lang")}},methods:{cancelSave:function(){this.btnType=!1,this.searchFunc()},toSave:function(){var e=this;return Object(i["a"])(Object(n["a"])().mark((function t(){var a;return Object(n["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:return e.pictLoading=!0,e.mock_tableData.id=1,t.next=4,r["a"].customPointRulesUpdate(Object(o["a"])({},e.mock_tableData));case 4:a=t.sent,a.code==u.StatusOK?(e.$pigeon.MessageOK(e.$i18n.t("Msg.Success")),e.pictLoading=!1,e.cancelSave()):(e.$pigeon.MessageError(a.msg),e.pictLoading=!1);case 6:case"end":return t.stop()}}),t)})))()},searchFunc:function(){var e=this;return Object(i["a"])(Object(n["a"])().mark((function t(){var a,s;return Object(n["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(e.pictLoading=!0,null!==(a=e.display["R-Shop-Point-Rules-Search"])&&void 0!==a&&a.show){t.next=5;break}return e.$pigeon.MessageWarning(e.$i18n.t("Msg.NotDisplay")),e.pictLoading=!1,t.abrupt("return");case 5:return t.next=7,r["a"].customPointRulesList({});case 7:s=t.sent,s.code==u.StatusOK?(e.mock_tableData=s.data,e.$pigeon.MessageOK(e.$i18n.t("Msg.SearchSuccess")),e.pictLoading=!1):(e.$pigeon.MessageError(s.msg),e.pictLoading=!1);case 9:case"end":return t.stop()}}),t)})))()}},mounted:function(){this.searchFunc()}},d=b,m=(a("d1b3"),a("8b0a"),a("2877")),v=Object(m["a"])(d,s,l,!1,null,"87494372",null);t["default"]=v.exports},d1b3:function(e,t,a){"use strict";a("4969")}}]);