cash-detail.js 4.1 KB

1
  1. (global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["plugins/bonus/cash-detail/cash-detail"],{"0d55":function(t,n,e){"use strict";var o=e("1f26"),i=e.n(o);i.a},"1f26":function(t,n,e){},"3b68":function(t,n,e){"use strict";var o,i=function(){var t=this,n=t.$createElement;t._self._c},a=[];e.d(n,"b",(function(){return i})),e.d(n,"c",(function(){return a})),e.d(n,"a",(function(){return o}))},"623a":function(t,n,e){"use strict";(function(t){Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var o=e("2f62");function i(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);n&&(o=o.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,o)}return e}function a(t){for(var n=1;n<arguments.length;n++){var e=null!=arguments[n]?arguments[n]:{};n%2?i(Object(e),!0).forEach((function(n){c(t,n,e[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):i(Object(e)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}))}return t}function c(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}var r=function(){Promise.all([e.e("common/vendor"),e.e("components/basic-component/app-layout/app-layout")]).then(function(){return resolve(e("3dd6"))}.bind(null,e)).catch(e.oe)},u=function(){Promise.all([e.e("common/vendor"),e.e("components/basic-component/app-form-id/app-form-id")]).then(function(){return resolve(e("e583"))}.bind(null,e)).catch(e.oe)},s=function(){e.e("components/basic-component/app-tab-nav/app-tab-nav").then(function(){return resolve(e("5c8b"))}.bind(null,e)).catch(e.oe)},l={data:function(){return{tabList:[{id:-1,name:"全部"},{id:0,name:"待审核"},{id:1,name:"待打款"},{id:2,name:"已打款"},{id:3,name:"无效"}],loading:null,list:[],activeTab:-1,noBorder:!1,id:null,page:2}},components:{"app-layout":r,"app-form-id":u,"app-tab-nav":s},computed:a({},(0,o.mapState)({theme:function(t){return t.mallConfig.theme},mall:function(t){return t.mallConfig.mall},custom_setting:function(t){return t.mallConfig.share_setting_custom},share_setting:function(t){return t.mallConfig.share_setting}})),methods:{open:function(t){this.id=t},tabStatus:function(n){t.showLoading({title:"加载中..."}),this.list=[],this.page=2,this.activeTab=n.currentTarget.dataset.id,this.getList()},getList:function(){var n=this;n.$request({url:n.$api.bonus.detail,data:{status:n.activeTab}}).then((function(e){n.$hideLoading(),t.hideLoading(),0==e.code?n.list=e.data.list:t.showToast({title:e.msg,icon:"none",duration:1e3})})).catch((function(e){n.$hideLoading(),t.hideLoading(),n.$event.on(n.$const.EVENT_USER_LOGIN).then((function(){n.getSetting()}))}))},getMore:function(){var n=this;t.showLoading({title:"加载中..."}),n.$request({url:n.$api.bonus.detail,data:{status:n.activeTab,page:n.page}}).then((function(e){if(t.hideLoading(),0==e.code){n.loading=null;var o=e.data.list;o.length>0&&(n.list[n.list.length-1].date==o[0].date?(n.list[n.list.length-1].list=n.list[n.list.length-1].list.concat(o[0].list),o.shift(),n.list=n.list.concat(o)):n.list=n.list.concat(o),n.page++)}else t.showToast({title:e.msg,icon:"none",duration:1e3})})).catch((function(n){t.hideLoading()}))},toGoods:function(n){t.navigateTo({url:"/pages/goods/goods?id="+n})}},onLoad:function(t){var n=this;n.$showLoading({type:"global",text:"加载中..."}),n.getList()},onReachBottom:function(){this.getMore()}};n.default=l}).call(this,e("543d")["default"])},"63bc":function(t,n,e){"use strict";(function(t){e("8748");o(e("66fd"));var n=o(e("ce92"));function o(t){return t&&t.__esModule?t:{default:t}}t(n.default)}).call(this,e("543d")["createPage"])},a709:function(t,n,e){"use strict";e.r(n);var o=e("623a"),i=e.n(o);for(var a in o)"default"!==a&&function(t){e.d(n,t,(function(){return o[t]}))}(a);n["default"]=i.a},ce92:function(t,n,e){"use strict";e.r(n);var o=e("3b68"),i=e("a709");for(var a in i)"default"!==a&&function(t){e.d(n,t,(function(){return i[t]}))}(a);e("0d55");var c,r=e("f0c5"),u=Object(r["a"])(i["default"],o["b"],o["c"],!1,null,"d97e604a",null,!1,o["a"],c);n["default"]=u.exports}},[["63bc","common/runtime","common/vendor"]]]);