You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
crmeb_php/public/static/js/pages-product-addGoods-spec...

1 line
24 KiB

12 months ago
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-product-addGoods-specificationProperties"],{"0c29":function(t,e,n){"use strict";n.r(e);var a=n("0c78"),i=n("7b7a");for(var o in i)["default"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(o);n("0dea");var c=n("f0c5"),r=Object(c["a"])(i["default"],a["b"],a["c"],!1,null,"2ce5583c",null,!1,a["a"],void 0);e["default"]=r.exports},"0c78":function(t,e,n){"use strict";n.d(e,"b",(function(){return a})),n.d(e,"c",(function(){return i})),n.d(e,"a",(function(){}));var a=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-uni-view",{staticClass:"container"},[n("v-uni-view",{staticClass:"content_input"},[n("v-uni-view",[t._v("规格名称")]),n("v-uni-view",[n("v-uni-input",{attrs:{type:"text",placeholder:"填写规格名称","placeholder-class":"placeholderClass"},model:{value:t.formData.template_name,callback:function(e){t.$set(t.formData,"template_name",e)},expression:"formData.template_name"}})],1)],1),n("v-uni-view",{staticClass:"content_add",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.addSingleSpecification.apply(void 0,arguments)}}},[n("v-uni-text",{staticClass:"iconfont icon-tianjia1"}),n("span",[t._v("添加规格属性")])],1),t.formData.template_value.length>0?n("v-uni-view",t._l(t.formData.template_value,(function(e,a){return n("v-uni-view",{key:a,staticClass:"content_message"},[n("v-uni-view",{staticClass:"content_message_title"},[n("v-uni-view",{staticClass:"title line1"},[t._v(t._s(e.value))]),n("v-uni-view",[n("span",{staticClass:"btn btn_del",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.formData.template_value.splice(a,1)}}},[t._v("删除")]),n("span",{staticClass:"btn btn_edit",on:{click:function(n){arguments[0]=n=t.$handleEvent(n),t.editAttr(e,a)}}},[t._v("编辑")])])],1),n("v-uni-view",{staticClass:"content_message_content"},t._l(e.detail,(function(e,a){return n("v-uni-view",{key:a},[t._v(t._s(e))])})),1)],1)})),1):t._e(),n("v-uni-view",{staticClass:"handle"},[n("v-uni-view",{staticClass:"handle_button",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.submit.apply(void 0,arguments)}}},[t._v("保存")])],1),n("specification-attr",{ref:"increaseSpec",attrs:{specData:t.specData},on:{changeClose:function(e){arguments[0]=e=t.$handleEvent(e),t.close.apply(void 0,arguments)},getData:function(e){arguments[0]=e=t.$handleEvent(e),t.getAttr.apply(void 0,arguments)}}})],1)},i=[]},"0c81":function(t,e,n){"use strict";n.r(e);var a=n("d15c"),i=n.n(a);for(var o in a)["default"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(o);e["default"]=i.a},"0dea":function(t,e,n){"use strict";var a=n("60df"),i=n.n(a);i.a},"307c":function(t,e,n){var a=n("5083");a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var i=n("4f06").default;i("a58b696e",a,!0,{sourceMap:!1,shadowMode:!1})},3300:function(t,e,n){"use strict";n("7a82");var a=n("4ea4").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,n("14d9");n("a5eb");var i=a(n("4a99")),o=n("fdb9"),c={components:{specificationAttr:i.default},data:function(){return{mer_id:"",template_id:"",specData:{showpopup:!1,name:"",detail:""},formData:{template_name:"",template_value:[]},index:""}},onLoad:function(t){this.mer_id=t.mer_id,this.template_id=t.template_id,this.template_id&&this.getSpecData()},methods:{addSingleSpecification:function(){this.$set(this,"index",""),this.$set(this.specData,"showpopup",!0),this.$refs.increaseSpec.resetData()},getAttr:function(t){""==this.index?this.formData.template_value.push(t):this.$set(this.formData.template_value,this.index-1,t),this.$set(this.specData,"showpopup",!1)},close:function(){this.$set(this.specData,"showpopup",!1)},getSpecData:function(){var t=this;uni.showLoading({title:"",mask:!0}),(0,o.specificationDetail)(t.mer_id,t.template_id).then((function(e){uni.hideLoading(),t.formData=e.data})).catch((function(e){return t.$util.Tips({title:e})}))},submit:function(){var t=this;return t.formData.template_name?0==t.formData.template_value.length?t.$util.