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.

1 line
11 KiB

(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["package1/index/addTemplate"],{"55d0":function(t,i,e){"use strict";e.d(i,"b",(function(){return s})),e.d(i,"c",(function(){return o})),e.d(i,"a",(function(){return n}));var n={uniEasyinput:function(){return e.e("uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput").then(e.bind(null,"5fa6"))},uniIcons:function(){return Promise.all([e.e("common/vendor"),e.e("uni_modules/uni-icons/components/uni-icons/uni-icons")]).then(e.bind(null,"6bbb6"))},uqrcode:function(){return Promise.all([e.e("common/vendor"),e.e("uni_modules/Sansnn-uQRCode/components/uqrcode/uqrcode")]).then(e.bind(null,"532c"))},uniPopup:function(){return e.e("uni_modules/uni-popup/components/uni-popup/uni-popup").then(e.bind(null,"2864"))}},s=function(){var t=this,i=t.$createElement;t._self._c;t._isMounted||(t.e0=function(i){return t.$refs.printPopup.open()},t.e1=function(i){return t.$refs.showIconPopup.close()},t.e2=function(i){return t.$refs.showIconPopup.close()})},o=[]},"610f":function(t,i,e){"use strict";var n=e("71d6"),s=e.n(n);s.a},"6a92":function(t,i,e){"use strict";e.r(i);var n=e("9a12"),s=e.n(n);for(var o in n)["default"].indexOf(o)<0&&function(t){e.d(i,t,(function(){return n[t]}))}(o);i["default"]=s.a},7012:function(t,i,e){"use strict";(function(t,i){var n=e("47a9");e("7859");n(e("3240"));var s=n(e("e023"));t.__webpack_require_UNI_MP_PLUGIN__=e,i(s.default)}).call(this,e("3223")["default"],e("df3c")["createPage"])},"71d6":function(t,i,e){},"9a12":function(t,i,e){"use strict";(function(t){var n=e("47a9"),s=e("3b2d");Object.defineProperty(i,"__esModule",{value:!0}),i.default=void 0;var o=e("072a"),a=(n(e("60b9")),function(t,i){if(!i&&t&&t.__esModule)return t;if(null===t||"object"!==s(t)&&"function"!==typeof t)return{default:t};var e=h(i);if(e&&e.has(t))return e.get(t);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in t)if("default"!==a&&Object.prototype.hasOwnProperty.call(t,a)){var r=o?Object.getOwnPropertyDescriptor(t,a):null;r&&(r.get||r.set)?Object.defineProperty(n,a,r):n[a]=t[a]}n.default=t,e&&e.set(t,n);return n}(e("769c")));n(e("b9aa"));function h(t){if("function"!==typeof WeakMap)return null;var i=new WeakMap,e=new WeakMap;return(h=function(t){return t?e:i})(t)}var r={data:function(){return{QrUrl:"1212",QrList1:{name:"",path:"",imgUrl:""},number:"",shippList:[],bufferData:[],categoryId:"",printName:"",shopId:t.getStorageSync("shopId"),shipId:"",discountCurrent:"left",items:[{value:"left",name:"靠左"},{value:"right",name:"居中"}],discountCurrent2:"blod",items2:[{value:"blod",name:"加粗"},{value:"notblod",name:"不加粗"}],iconList:[]}},components:{kkPrinter:function(){Promise.all([e.e("common/vendor"),e.e("components/kk-printer/index")]).then(function(){return resolve(e("4af3"))}.bind(null,e)).catch(e.oe)}},onLoad:function(i){if(this.iconList=(0,o.washingInstructions)(),t.getStorageSync("qrcode")&&(this.QrList1=t.getStorageSync("qrcode"),t.removeStorageSync("qrcode")),i){var e=JSON.parse(i.item);this.shipId=e.id,this.printName=e.printName,this.shippList=e.content;for(var n=0;n<this.shippList.length;n++)void 0==this.shippList[n].leftIcon&&(this.shippList[n].leftIcon=[]),void 0==this.shippList[n].rightIcon&&(this.shippList[n].rightIcon=[]);this.$forceUpdate()}},methods:{addItemName:function(i,e){if(i.detail.value.length>6)return t.showToast({title:"最多输入6个字符",icon:"none"}),void(this.QrList1.name="");this.QrList1.name=i.detail.value},scanCodeAdd:function(i){var e=this;t.scanCode({success:function(n){if(""!=n.result){if(-1==n.result.indexOf("u.wechat.com")&&-1==n.result.indexOf("qr.alipay.com")&&-1==n.result.indexOf("wxp://")&&n.result.length>80){var s=t.getStorageSync("shopId").substring("10","12")+(0,o.generateUUID)().substring("0","7"),a=[];a.push({id:s,longUrl:n.result}),e.tui.request("/app/urlMapping/saveOrUpdateUrlMapping","post",a,!1,!1).then((function(t){200==t.code&&(e.QrList1.path=e.tui.interfaceUrl()+"/app/urlMapping/redirect?id="+s)}))}else e.QrList1.path=n.result;e.QrUrl=e.QrList1.path,e.canUpdate=!1,e.$forceUpdate(),