1 line
3.8 KiB
JavaScript
1 line
3.8 KiB
JavaScript
![]() |
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["yb_shd/my/storeset/spgl/fbsp-gg"],{"004d":function(t,e,s){},"03a8":function(t,e,s){"use strict";var n=s("004d"),i=s.n(n);i.a},1812:function(t,e,s){"use strict";s.r(e);var n=s("d047"),i=s("807a");for(var r in i)"default"!==r&&function(t){s.d(e,t,(function(){return i[t]}))}(r);s("03a8");var c,a=s("f0c5"),o=Object(a["a"])(i["default"],n["b"],n["c"],!1,null,"6673f6c6",null,!1,n["a"],c);e["default"]=o.exports},"2dbc":function(t,e,s){"use strict";(function(t){s("29af");n(s("66fd"));var e=n(s("1812"));function n(t){return t&&t.__esModule?t:{default:t}}t(e.default)}).call(this,s("543d")["createPage"])},"807a":function(t,e,s){"use strict";s.r(e);var n=s("b313"),i=s.n(n);for(var r in n)"default"!==r&&function(t){s.d(e,t,(function(){return n[t]}))}(r);e["default"]=i.a},b313:function(t,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=i(s("a34a"));s("2f62");function i(t){return t&&t.__esModule?t:{default:t}}function r(t,e,s,n,i,r,c){try{var a=t[r](c),o=a.value}catch(u){return void s(u)}a.done?e(o):Promise.resolve(o).then(n,i)}function c(t){return function(){var e=this,s=arguments;return new Promise((function(n,i){var c=t.apply(e,s);function a(t){r(c,n,i,a,o,"next",t)}function o(t){r(c,n,i,a,o,"throw",t)}a(void 0)}))}}var a=function(){s.e("components/form/mg-tcxz").then(function(){return resolve(s("1795"))}.bind(null,s)).catch(s.oe)},o={name:"fbsp-gg",components:{mgTcxz:a},data:function(){return{show:!1,radiov:"",ggarr:[],showdx:!1,checkv:[],ggzarr:[],spec:[],parentGroup:[],tbwsj:"",tbwyj:"",tbwkc:"",tbtsj:"",tbtyj:"",tbtkc:"",wsj:"",wyj:"",wkc:"",tsj:"",tyj:"",tkc:"",loading:!1}},onLoad:function(t){var e=this;return c(n.default.mark((function s(){return n.default.wrap((function(s){while(1)switch(s.prev=s.next){case 0:e.util.setNT("设置规格"),e.ggarr=getApp().globalData.spflsj.specsData.map((function(t){return{name:t.name,value:t.id}})),e.spec=JSON.parse(t.arr)||[];case 3:case"end":return s.stop()}}),s)})))()},computed:{},methods:{tjgg:function(){if(this.hqggtype=1,this.spec.length>9)return this.util.message("最多添加10个规格",3);this.$set(this.spec,this.spec.length,{specName:"规格"+(this.spec.length+1),price:"",boxMoney:"",stock:"",fillType:2,crossedPrice:"",costPrice:"",goodCode:""})},xggg:function(t){this.xgggIdx=t,this.hqggtype=2,this.show=!0},rconfirm:function(t){var e=this;if(t)if(1==this.hqggtype){if(this.spec.find((function(s){return s.specName==e.ggarr[t.i].name})))return this.util.message("此规格已添加",3);var s=t.i;this.$set(this.spec,this.spec.length,{specName:this.ggarr[s].name,price:"",boxMoney:"",stock:"",fillType:2,crossedPrice:"",costPrice:"",goodCode:""})}else this.$set(this.spec[this.xgggIdx],"specName",this.ggarr[t.i].name)},scgg:function(t){this.$delete(this.spec,t)},qdgg:function(){for(var t in this.spec)if(!this.spec[t].specName.trim())return this.util.message("规格名称不能为空",3);for(var e in this.spec){if(""===this.spec[e].price||""===this.spec[e].boxMoney||""===this.spec[e].stock)return this.util.message("规格的价格,包装费,库存不能为空",3);if(isNaN(parseInt(this.spec[e].price))||isNaN(parseInt(this.spec[e].boxMoney))||isNaN(parseInt(this.spec[e].stock)))return this.util.message("规格的价格,包装费,库存填写错误",3)}this.loading=!0;var s=this.util.getPage();s.$vm.params.spec=this.spec,this.go({t:4})},cconfirm:function(t){var e=this.ggzarr.filter((function(e){return t.v.includes(e.value)}));this.$set(this.spec[this.specIdx],"son",e)},changeFillType:function(t){t.fillType=1==t.fillType?2:1}}};e.default=o},d047:function(t,e,s){"use strict";var n;s.d(e,"b",(function(){return i})),s.d(e,"c",(function(){return r})),s.d(e,"a",(function(){return n}));var i=function(){var t=this,e=t.$createElement;t._self._c},r=[]}},[["2dbc","common/runtime","common/vendor"]]]);
|