1 line
6.7 KiB
JavaScript
1 line
6.7 KiB
JavaScript
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-286191ce"],{"0750":function(t,e,s){"use strict";s("70e7")},5944:function(t,e,s){"use strict";s.r(e);var a=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",[s("div",{staticClass:"i-layout-page-header"},[s("el-card",{staticClass:"product_tabs"},[s("div",[s("router-link",{attrs:{to:{path:"/admin/setting/sms/sms_config/index"}}},[s("el-button",{staticClass:"mr20",attrs:{icon:"el-icon-arrow-left",size:"mini"}},[t._v("返回")])],1),t._v(" "),s("span",{staticClass:"mr20",domProps:{textContent:t._s(t.$route.meta.title)}})],1)])],1),t._v(" "),s("el-card",{staticClass:"ivu-mt"},[s("el-tabs",{on:{"tab-click":t.onChangeType},model:{value:t.isChecked,callback:function(e){t.isChecked=e},expression:"isChecked"}},[s("el-tab-pane",{attrs:{label:"短信",name:"sms"}}),t._v(" "),s("el-tab-pane",{attrs:{label:"商品采集",name:"copy"}}),t._v(" "),s("el-tab-pane",{attrs:{label:"物流查询",name:"expr_query"}}),t._v(" "),s("el-tab-pane",{attrs:{label:"电子面单打印",name:"expr_dump"}})],1),t._v(" "),s("el-row",{directives:[{name:"loading",rawName:"v-loading",value:t.spinShow,expression:"spinShow"}],staticClass:"mt50",attrs:{gutter:16}},[s("el-col",{staticClass:"ivu-text-left mb20",attrs:{span:24}},[s("el-col",{staticClass:"mr20",attrs:{xs:12,sm:6,md:4,lg:2}},[s("span",{staticClass:"ivu-text-right ivu-block"},[t._v("当前剩余条数:")])]),t._v(" "),s("el-col",{attrs:{xs:11,sm:13,md:19,lg:20}},[s("span",[t._v(t._s(t.numbers))])])],1),t._v(" "),s("el-col",{staticClass:"ivu-text-left mb20",attrs:{span:24}},[s("el-col",{staticClass:"mr20",attrs:{xs:12,sm:6,md:4,lg:2}},[s("span",{staticClass:"ivu-text-right ivu-block"},[t._v("选择套餐:")])]),t._v(" "),s("el-col",{attrs:{xs:11,sm:13,md:19,lg:20}},[s("el-row",{attrs:{gutter:20}},t._l(t.list,(function(e,a){return s("el-col",{key:a,attrs:{xxl:4,xl:8,lg:8,md:12,sm:24,xs:24}},[s("div",{staticClass:"list-goods-list-item mb15",class:{active:a===t.current},on:{click:function(s){return t.check(e,a)}}},[s("div",{staticClass:"list-goods-list-item-title",class:{active:a===t.current}},[t._v("¥ "),s("i",[t._v(t._s(e.price))])]),t._v(" "),s("div",{staticClass:"list-goods-list-item-price",class:{active:a===t.current}},[s("span",[t._v(t._s(t.all[t.isChecked])+"条数: "+t._s(e.num))])])])])})),1)],1)],1),t._v(" "),t.checkList?s("el-col",{staticClass:"ivu-text-left mb20",attrs:{span:24}},[s("el-col",{staticClass:"mr20",attrs:{xs:12,sm:6,md:4,lg:2}},[s("span",{staticClass:"ivu-text-right ivu-block"},[t._v("充值条数:")])]),t._v(" "),s("el-col",{attrs:{xs:11,sm:13,md:19,lg:20}},[s("span",[t._v(t._s(t.checkList.num))])])],1):t._e(),t._v(" "),t.checkList?s("el-col",{staticClass:"ivu-text-left mb20",attrs:{span:24}},[s("el-col",{staticClass:"mr20",attrs:{xs:12,sm:6,md:4,lg:2}},[s("span",{staticClass:"ivu-text-right ivu-block"},[t._v("支付金额:")])]),t._v(" "),s("el-col",{attrs:{xs:11,sm:13,md:19,lg:20}},[s("span",{staticClass:"list-goods-list-item-number"},[t._v("¥"+t._s(t.checkList.price))])])],1):t._e(),t._v(" "),s("el-col",{staticClass:"ivu-text-left mb20",attrs:{span:24}},[s("el-col",{staticClass:"mr20",attrs:{xs:12,sm:6,md:4,lg:2}},[s("span",{staticClass:"ivu-text-right ivu-block"},[t._v("付款方式:")])]),t._v(" "),s("el-col",{attrs:{xs:11,sm:13,md:19,lg:20}},[s("span",{staticClass:"list-goods-list-item-pay"},[t._v("微信支付"),t.code.invalid?s("i",[t._v(t._s(" ( 支付码过期时间:"+t.code.invalid+" )"))]):t._e()])])],1),t._v(" "),s("el-col",{attrs:{span:24}},[s("el-col",{staticClass:"mr20",attrs:{xs:12,sm:6,md:4,lg:3}},[t._v(" ")]),t._v(" "),s("el-col",{attrs:{xs:11,sm:13,md:19,lg:20}},[s("div",{staticClass:"list-goods-list-item-code mr20"},[t.code.code_url?s("img",{directives:[{name:"lazy",rawName:"v-lazy",value:t.code.code_url,expression:"code.code_url"}]}):t._e()])])],1)],1)],1)],1)},i=[],c=s("c80c"),n=(s("96cf"),s("3b8d")),r=s("90e7"),l={name:"smsPay",data:function(){return{all:{sms:"短信",copy:"商品采集",expr_query:"物流查询",expr_dump:"电子面单打印"},isChecked:"sms",numbers:"",account:"",list:[],current:0,checkList:{},spinShow:!1,code:{}}},created:function(){this.isChecked=this.$route.query.type,this.onIsLogin()},activated:function(){this.isChecked=this.$route.query.type},methods:{onIsLogin:function(){var t=this;this.spinShow=!0,Object(r["B"])().then(function(){var e=Object(n["a"])(Object(c["a"])().mark((function e(s){var a;return Object(c["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:a=s.data,a.status?(t.getServeInfo(),t.getPrice()):(t.$message.warning("请先登录"),t.$router.push("/admin/setting/sms/sms_config/index?url="+t.$route.path));case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){t.$message.error(e.message)}))},getServeInfo:function(){var t=this;Object(r["X"])().then(function(){var e=Object(n["a"])(Object(c["a"])().mark((function e(s){var a;return Object(c["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:a=s.data,e.t0=t.isChecked,e.next="sms"===e.t0?4:"copy"===e.t0?6:"expr_dump"===e.t0?8:10;break;case 4:return t.numbers=a.sms.num,e.abrupt("break",12);case 6:return t.numbers=a.copy.num,e.abrupt("break",12);case 8:return t.numbers=a.dump.num,e.abrupt("break",12);case 10:return t.numbers=a.query.num,e.abrupt("break",12);case 12:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){t.$message.error(e.message)}))},onChangeType:function(t){this.current=0,this.getPrice(),this.getServeInfo()},getPrice:function(){var t=this;this.spinShow=!0,Object(r["eb"])(this.isChecked).then(function(){var e=Object(n["a"])(Object(c["a"])().mark((function e(s){var a;return Object(c["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:setTimeout((function(){t.spinShow=!1}),800),a=s.data,t.list=a.data,t.checkList=t.list[0],t.getCode(t.checkList);case 5:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){t.spinShow=!1,t.$message.error(e.message),t.list=[]}))},check:function(t,e){var s=this;this.spinShow=!0,this.current=e,setTimeout((function(){s.getCode(t),s.checkList=t,s.spinShow=!1}),800)},getCode:function(t){var e=this,s={pay_type:"weixin",meal_id:t.id,price:t.price,num:t.num,type:t.type};Object(r["L"])(s).then(function(){var t=Object(n["a"])(Object(c["a"])().mark((function t(s){return Object(c["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:e.code=s.data;case 1:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.code="",e.$message.error(t.message)}))}}},o=l,u=(s("0750"),s("2877")),m=Object(u["a"])(o,a,i,!1,null,"ff876088",null);e["default"]=m.exports},"70e7":function(t,e,s){}}]); |