water-mall/unpackage/dist/dev/mp-weixin/pagesA/addCard/addCard.js

2 lines
4.4 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pagesA/addCard/addCard"],{270:function(e,n,t){"use strict";(function(e,n){var o=t(4);t(26);o(t(25));var r=o(t(271));e.__webpack_require_UNI_MP_PLUGIN__=t,n(r.default)}).call(this,t(1)["default"],t(2)["createPage"])},271:function(e,n,t){"use strict";t.r(n);var o=t(272),r=t(274);for(var i in r)["default"].indexOf(i)<0&&function(e){t.d(n,e,(function(){return r[e]}))}(i);t(276);var s,c=t(35),a=Object(c["default"])(r["default"],o["render"],o["staticRenderFns"],!1,null,"370657e2",null,!1,o["components"],s);a.options.__file="pagesA/addCard/addCard.vue",n["default"]=a.exports},272:function(e,n,t){"use strict";t.r(n);var o=t(273);t.d(n,"render",(function(){return o["render"]})),t.d(n,"staticRenderFns",(function(){return o["staticRenderFns"]})),t.d(n,"recyclableRender",(function(){return o["recyclableRender"]})),t.d(n,"components",(function(){return o["components"]}))},273:function(e,n,t){"use strict";var o;t.r(n),t.d(n,"render",(function(){return r})),t.d(n,"staticRenderFns",(function(){return s})),t.d(n,"recyclableRender",(function(){return i})),t.d(n,"components",(function(){return o}));try{o={statusNav:function(){return t.e("components/status-nav/status-nav").then(t.bind(null,347))},uIcon:function(){return Promise.all([t.e("common/vendor"),t.e("components/uview-ui/components/u-icon/u-icon")]).then(t.bind(null,361))},uButton:function(){return Promise.all([t.e("common/vendor"),t.e("components/uview-ui/components/u-button/u-button")]).then(t.bind(null,486))},uPicker:function(){return Promise.all([t.e("common/vendor"),t.e("components/uview-ui/components/u-picker/u-picker")]).then(t.bind(null,504))}}}catch(c){if(-1===c.message.indexOf("Cannot find module")||-1===c.message.indexOf(".vue"))throw c;console.error(c.message),console.error("1. 排查组件名称拼写是否正确"),console.error("2. 排查组件是否符合 easycom 规范文档https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"),console.error("3. 若组件不符合 easycom 规范,需手动引入,并在 components 中注册该组件")}var r=function(){var e=this,n=e.$createElement;e._self._c;e._isMounted||(e.e0=function(n){e.showPicker=!0},e.e1=function(n){e.showPicker=!1},e.e2=function(n){e.showPicker=!1})},i=!1,s=[];r._withStripped=!0},274:function(e,n,t){"use strict";t.r(n);var o=t(275),r=t.n(o);for(var i in o)["default"].indexOf(i)<0&&function(e){t.d(n,e,(function(){return o[e]}))}(i);n["default"]=r.a},275:function(e,n,t){"use strict";(function(e){Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var o=t(31),r=t(266),i={data:function(){return{backgroudColor:"none",service:[],serviceIndex:"",serviceUser:"",serviceAppid:"",cardNum:"",showPicker:!1,disabled:!1}},onLoad:function(){this.getSalerList()},methods:{onConfirm:function(e){this.serviceIndex=e.indexs[0],this.serviceUser=this.service[0][this.serviceIndex].username,this.serviceAppid=this.service[0][this.serviceIndex].appid,this.showPicker=!1},goPage:function(n){e.navigateTo({url:n})},getSalerList:function(){var e=this;(0,o.getSaler)().then((function(n){e.service=[n.data]}))},submitForm:function(){var n=this;if(console.log(this.serviceIndex),""==this.serviceUser)return this.$toolAll.tools.showToast("请先选择服务商");this.disabled=!0,setTimeout((function(){n.disabled=!1}),2500);var t={appid:this.serviceAppid,user:this.serviceUser,card:this.cardNum};(0,r.getCardinfo)(t).then((function(t){if(0==t.error)switch(t.data.status){case"normal":var r={saler:n.serviceUser,number:n.cardNum};(0,o.postCardAdd)(r).then((function(t){0==t.code?(n.$toolAll.tools.showToast("添加成功"),setTimeout((function(){e.redirectTo({url:"/pagesA/waterCard/waterCard"})}),1200)):n.$toolAll.tools.showToast(t.msg)}));break;case"lost":n.$toolAll.tools.showToast("该卡号已被挂失");break;case"cancel":n.$toolAll.tools.showToast("该卡号已被注销");break}else n.$toolAll.tools.showToast("添加失败,请检查您的卡号与服务商是否匹配")}))},getCardData:function(){var e={saler:"13992800508",page:1};(0,r.getCardList)(e).then((function(e){}))}}};n.default=i}).call(this,t(2)["default"])},276:function(e,n,t){"use strict";t.r(n);var o=t(277),r=t.n(o);for(var i in o)["default"].indexOf(i)<0&&function(e){t.d(n,e,(function(){return o[e]}))}(i);n["default"]=r.a},277:function(e,n,t){}},[[270,"common/runtime","common/vendor"]]]);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pagesA/addCard/addCard.js.map