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 lines
19 KiB
1 lines
19 KiB
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["agent-pages-income-commission"],{"252e":function(t,e,i){"use strict";i("6a54");var a=i("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,i("c223");var n=a(i("9b1b")),s=a(i("2634")),o=a(i("2fdc")),c=i("8f59"),r=a(i("cd23")),l=a(i("13f3")),u={components:{wPicker:l.default},data:function(){return{isLoad:!1,popupHeight:"",curDay:"",curMonth:"",startYear:"",showKey:"",showDate:!1,time_text:"",prev_time:{activeIndex:0,month:"",start_time:"",end_time:""},check_time:{activeIndex:0,month:"",start_time:"",end_time:""},activeIndex:0,tabList:[{id:1,title:"月份选择"},{id:2,title:"自定义时间"}],typeIndex:0,typeList:[{title:"全部",id:-1},{title:"未到账",id:0},{title:"已到账",id:1}],statusType:{0:"未到账",1:"已到账"},cityType:["","城市","区县","省"],param:{page:1,start_time:"",end_time:""},list:{data:[]},loading:!0}},computed:(0,c.mapState)({primaryColor:function(t){return t.config.configInfo.primaryColor},subColor:function(t){return t.config.configInfo.subColor}}),onLoad:function(){var t=this;return(0,o.default)((0,s.default)().mark((function e(){var i;return(0,s.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t.$util.showLoading(),i=new Date(Math.ceil((new Date).getTime())),t.curDay=t.$util.formatTime(i,"YY-M-D"),t.curMonth=t.$util.formatTime(i,"YY-M"),t.startYear=t.$util.formatTime(i,"YY"),e.next=7,t.initIndex();case 7:t.isLoad=!0;case 8:case"end":return e.stop()}}),e)})))()},onPullDownRefresh:function(){uni.showNavigationBarLoading(),this.initRefresh(),uni.stopPullDownRefresh()},onReachBottom:function(){this.list.current_page>=this.list.last_page||this.loading||(this.param.page=this.param.page+1,this.loading=!0,this.getList())},methods:(0,n.default)((0,n.default)({},(0,c.mapMutations)([])),{},{initIndex:function(){var t=arguments,e=this;return(0,o.default)((0,s.default)().mark((function i(){var a;return(0,s.default)().wrap((function(i){while(1)switch(i.prev=i.next){case 0:if(a=t.length>0&&void 0!==t[0]&&t[0],a||!e.$jweixin.isWechat()){i.next=5;break}return i.next=4,e.$jweixin.initJssdk();case 4:e.$jweixin.wxReady((function(){e.$jweixin.hideOptionMenu()}));case 5:return i.next=7,e.getList();case 7:e.$util.setNavigationBarColor({bg:e.primaryColor});case 8:case"end":return i.stop()}}),i)})))()},initRefresh:function(){this.param.page=1,this.initIndex(!0)},getList:function(t){var e=this;return(0,o.default)((0,s.default)().mark((function i(){var a,n,o,c,r,l,u,m,v,d,p;return(0,s.default)().wrap((function(i){while(1)switch(i.prev=i.next){case 0:return t&&(e.param.page=1,e.list.data=[],uni.pageScrollTo({scrollTop:0})),a=e.list,n=e.param,o=e.activeIndex,c=e.typeIndex,r=e.typeList,l=r[c].id,-1!=l&&(n.have_tx=l),u=e.$util.deepCopy(e.check_time),m=u.month,v=u.start_time,d=u.end_time,0==o&&(n.month=m?e.$util.DateToUnix("".concat(m,"-01")):""),1==o&&(n.start_time=v&&d?e.$util.DateToUnix(v):"",n.end_time=v&&d?e.$util.DateToUnix(d)+86400-1:""),i.next=9,e.$api.agent.commList(n);case 9:p=i.sent,1==e.param.page||(p.data=a.data.concat(p.data)),e.list=p,e.loading=!1,e.$util.hideAll();case 13:case"end":return i.stop()}}),i)})))()},initFixHeight:function(t){this.popupHeight=t},handerTabChange:function(t){this.activeIndex=t,this.check_time.activeIndex=t},handerTypeChange:function(t){this.typeIndex=t,this.getList(1),this.$refs.show_status_item.close()},toChangeType:function(t){this.active=t},toShowTimePopup:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;this.check_time=this.$util.deepCopy(this.prev_time),e&&0!=e&&(this.activeIndex=0,this.curMonth=e,this.check_time.month=e),this.activeIndex=this.check_time.activeIndex,this.$refs.show_choose_time.open()},toReset:function(){var t=this.activeIndex;0!=t?(this.check_time.start_time="",this.check_time.end_time="",this.getList(1)):this.check_time.month=""},toClose:function(){var t=this;return(0,o.default)((0,s.default)().mark((function e(){var i,a,n,o,c;return(0,s.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:i=t.activeIndex,a=t.check_time,n=a.month,o=a.start_time,c=a.end_time,(0!=i||n)&&(1!=i||o&&c)||(1!=i||o&&c||(t.activeIndex=0,t.check_time.activeIndex=0,t.check_time.month=""),t.prev_time=t.$util.deepCopy(t.check_time)),(0==i&&n||1==i&&o&&c)&&(t.check_time=t.$util.deepCopy(t.prev_time)),t.$refs.show_choose_time.close(),t.getList(1);case 6:case"end":return e.stop()}}),e)})))()},toShowTime:function(t){var e=this.activeIndex;if(1!=e||"end_time"!=t||this.check_time.start_time){var i=this.check_time[t];i&&("month"==t?this.curMonth=i:this.curDay=i),this.showKey=t,this.showDate=!0}else this.$util.showToast({title:"请选择开始时间"})},onConfirm:function(t){var e=this;return(0,o.default)((0,s.default)().mark((function i(){var a,n,o,c,r,l,u,m,v,d,p,h;return(0,s.default)().wrap((function(i){while(1)switch(i.prev=i.next){case 0:if(a=e.check_time,n=a.start_time,o=a.end_time,c=e.showKey,r=e.activeIndex,l=void 0===r?0:r,u=e.$util.DateToUnix("month"==c?"".concat(t.result,"-01"):t.result),m=n?e.$util.DateToUnix(n):0,v=o?e.$util.DateToUnix(o):0,d=e.$util.formatTime(new Date(Math.ceil((new Date).getTime())),"YY-M-D"),p=e.$util.DateToUnix(d)+1,h={month:"开始月份",start_time:"开始时间",end_time:"结束时间"},!(u>p)){i.next=11;break}return e.$util.showToast({title:"".concat(h[c],"不能选择未来时间哦")}),i.abrupt("return");case 11:if(1!=l||!("start_time"==c&&v&&v<e.$util.DateToUnix(t.result)||"end_time"==c&&m&&m>e.$util.DateToUnix(t.result))){i.next=14;break}return e.$util.showToast({title:"结束时间不能小于开始时间"}),i.abrupt("return");case 14:e.check_time[c]=t.result;case 15:case"end":return i.stop()}}),i)})))()},toConfirm:function(){var t=this;return(0,o.default)((0,s.default)().mark((function e(){var i,a,n,o,c,r,l,u,m,v,d;return(0,s.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(i=t.check_time,a=i.month,n=void 0===a?"":a,o=i.start_time,c=void 0===o?"":o,r=i.end_time,l=void 0===r?"":r,u=t.activeIndex,m=void 0===u?0:u,v=1e3*t.$util.DateToUnix(c),d=1e3*t.$util.DateToUnix(l),0!=m||n){e.next=7;break}return t.$util.showToast({title:"请选择开始月份"}),e.abrupt("return");case 7:if(1!=m||c&&l&&!(d-v>31536e6)){e.next=10;break}return t.$util.showToast({title:c?l?"查询时间跨度最长为一年哦":"请选择结束时间":"请选择开始时间"}),e.abrupt("return");case 10:if(t.check_time.activeIndex=m,t.prev_time=t.$util.deepCopy(t.check_time),t.$refs.show_choose_time.close(),1!=m){e.next=16;break}return e.next=16,t.getCount();case 16:t.getList(1);case 17:case"end":return e.stop()}}),e)})))()}}),filters:{handleTimeText:function(t,e){var i="请选择",a=t.activeIndex,n=t.month,s=t.start_time,o=t.end_time;0==a&&n&&(i=r.default.formatTime(1e3*r.default.DateToUnix("".concat(n,"-01")),"YY年M月"));var c=1==e?"YY.M.D":"YY年M月D日";return 1==a&&s&&o&&(i=r.default.formatTime(1e3*r.default.DateToUnix(s),c)+" - "+r.default.formatTime(1e3*r.default.DateToUnix(o),c)),i}}};e.default=u},"2ba4":function(t,e,i){"use strict";var a=i("40ed"),n=i.n(a);n.a},"40ed":function(t,e,i){var a=i("85dc");a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var n=i("967d").default;n("41ba8f02",a,!0,{sourceMap:!1,shadowMode:!1})},4831:function(t,e,i){"use strict";i.r(e);var a=i("6b65"),n=i("f183");for(var s in n)["default"].indexOf(s)<0&&function(t){i.d(e,t,(function(){return n[t]}))}(s);i("2ba4");var o=i("828b"),c=Object(o["a"])(n["default"],a["b"],a["c"],!1,null,"41c25e3b",null,!1,a["a"],void 0);e["default"]=c.exports},"6b65":function(t,e,i){"use strict";i.d(e,"b",(function(){return n})),i.d(e,"c",(function(){return s})),i.d(e,"a",(function(){return a}));var a={wPicker:i("13f3").default},n=function(){var t=this,e=t.$createElement,i=t._self._c||e;return t.isLoad?i("v-uni-view",{staticClass:"agent-income-commission"},[i("fixed",{attrs:{zIndex:"997"},on:{height:function(e){arguments[0]=e=t.$handleEvent(e),t.initFixHeight.apply(void 0,arguments)}}},[i("v-uni-view",{staticClass:"record-search-info fill-body pt-md pl-md c-base"},[i("v-uni-view",{staticClass:"record-info radius-32",style:{background:t.primaryColor}},[i("v-uni-view",{staticClass:"search-item flex-between ml-lg mr-lg f-desc b-1px-b"},[i("v-uni-view",[t._v("查询时间")]),i("v-uni-view",{staticClass:"flex-y-center",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.toShowTimePopup(e)}}},[t._v(t._s(t._f("handleTimeText")(t.prev_time,1))),i("i",{staticClass:"iconfont icon-right"})])],1),i("v-uni-view",{staticClass:"search-item flex-between ml-lg mr-lg f-desc"},[i("v-uni-view",[t._v("入账状态")]),i("v-uni-view",{staticClass:"flex-y-center",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.$refs.show_status_item.open()}}},[t._v(t._s(t.typeList[t.typeIndex].title)),i("i",{staticClass:"iconfont icon-right"})])],1)],1)],1)],1),t._l(t.list.data,(function(e,a){return[0==t.prev_time.activeIndex&&(0==a||a>0&&e.month!=t.list.data[a-1].month)?i("v-uni-view",{key:a+"_0",staticClass:"count-item fill-body pl-md pr-md",on:{click:function(i){i.stopPropagation(),arguments[0]=i=t.$handleEvent(i),t.toShowTimePopup(i,e.month)}}},[i("veiw",{staticClass:"title flex-y-center"},[i("v-uni-view",{staticClass:"f-title c-title text-bold"},[t._v(t._s(e.month))]),i("i",{staticClass:"iconfont iconxia"})],1),i("v-uni-view",{staticClass:"f-caption c-caption"},[t._v("获得总提成¥"+t._s(e.total_cash)+"("+t._s(t.cityType[e.my_city_type])+"代理)")])],1):t._e(),1==t.prev_time.activeIndex&&0==a?i("v-uni-view",{key:a+"_1",staticClass:"count-item fill-body pl-md pr-md",on:{click:function(i){i.stopPropagation(),arguments[0]=i=t.$handleEvent(i),t.toShowTimePopup(i,e.month)}}},[i("veiw",{staticClass:"title flex-y-center"},[i("v-uni-view",{staticClass:"f-title c-title text-bold"},[t._v(t._s(t._f("handleTimeText")(t.prev_time,2)))]),i("i",{staticClass:"iconfont iconxia"})],1),i("v-uni-view",{staticClass:"f-caption c-caption"},[t._v("获得总提成¥"+t._s(e.total_cash)+"("+t._s(t.cityType[e.my_city_type])+"代理)")])],1):t._e(),i("v-uni-view",{key:a+"_2",staticClass:"list-item ml-md mr-md fill-base radius-16",class:[{"mt-md":0!==a}]},[i("v-uni-view",{staticClass:"flex-between pt-lg pb-lg ml-lg mr-lg b-1px-b"},[i("v-uni-view",{staticClass:"flex-y-center f-caption c-caption"},[t._v(t._s(t.$t("action.attendantName"))),i("v-uni-view",{staticClass:"f-paragraph c-title text-bold ml-md max-380 ellipsis"},[t._v(t._s(e.coach_info.coach_name))])],1),i("v-uni-view",{staticClass:"f-paragraph text-bold",style:{color:1==e.status?t.subColor:t.primaryColor}},[t._v(t._s(t.statusType[e.have_tx]))])],1),i("v-uni-view",{staticClass:"pd-lg f-caption"},[i("v-uni-view",{staticClass:"flex-warp"},[i("v-uni-view",{staticClass:"item-text c-paragraph"},[t._v("创建时间:")]),i("v-uni-view",{staticClass:"c-title"},[t._v(t._s(e.create_time))])],1),i("v-uni-view",{staticClass:"flex-warp mt-md"},[i("v-uni-view",{staticClass:"item-text c-paragraph"},[t._v("服务时间:")]),i("v-uni-view",{staticClass:"c-title"},[t._v(t._s(e.start_time))])],1),i("v-uni-view",{staticClass:"flex-warp mt-md"},[i("v-uni-view",{staticClass:"item-text c-paragraph"},[t._v("项目:")]),i("v-uni-view",{staticClass:"c-title",staticStyle:{"max-width":"410rpx"}},t._l(e.order_goods,(function(e,a){return i("v-uni-view",{key:a,class:[{"mt-md":0!=a}]},[t._v(t._s(e.goods_name))])})),1)],1),i("v-uni-view",{staticClass:"flex-warp mt-md"},[i("v-uni-view",{staticClass:"item-text c-paragraph"},[t._v("订单实际支付价格:")]),i("v-uni-view",{staticClass:"flex-y-center c-title"},[i("v-uni-view",{staticClass:"mr-sm"},[t._v("¥"+t._s(e.pay_price))]),1*e.true_car_price>0?[t._v("(含车费¥"+t._s(e.true_car_price)+")")]:t._e()],2)],1),i("v-uni-view",{staticClass:"flex-warp mt-lg pt-md"},[i("v-uni-view",{staticClass:"item-text c-paragraph"},[t._v(t._s(t.$t("action.attendantName"))+"分成:")]),i("v-uni-view",{staticClass:"c-title",style:{color:t.primaryColor}},[t._v("¥"+t._s(e.coach_cash))])],1),t._l(e.admin_cash_list,(function(e,a){return i("v-uni-view",{key:a,staticClass:"flex-warp mt-md"},[i("v-uni-view",{staticClass:"item-text c-paragraph"},[t._v(t._s(t.cityType[e.city_type])+"代理分成:")]),i("v-uni-view",{staticClass:"c-title",style:{color:t.primaryColor}},[t._v("¥"+t._s(e.cash))])],1)}))],2)],1)]})),t.loading?i("load-more",{attrs:{noMore:t.list.current_page>=t.list.last_page&&t.list.data.length>0,loading:t.loading}}):t._e(),!t.loading&&t.list.data.length<=0&&1==t.list.current_page?i("abnor"):t._e(),i("v-uni-view",{staticClass:"space-footer"}),i("uni-popup",{ref:"show_choose_time",attrs:{type:"bottom"}},[i("v-uni-view",{staticClass:"popup-choose-time fill-base"},[i("v-uni-view",{staticClass:"pl-lg pr-lg"},[i("v-uni-view",{staticClass:"flex-between b-1px-b"},[i("tab",{attrs:{list:t.tabList,activeIndex:1*t.activeIndex,activeColor:t.primaryColor,height:"100rpx"},on:{change:function(e){arguments[0]=e=t.$handleEvent(e),t.handerTabChange.apply(void 0,arguments)}}}),i("i",{staticClass:"iconfont icon-close",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.toClose.apply(void 0,arguments)}}})],1),i("v-uni-view",{staticClass:"flex-center mt-md pt-lg pb-lg"},[i("v-uni-view",{staticClass:"flex-1 flex-y-baseline"},[i("v-uni-view",{staticClass:"f-paragraph c-title text-bold"},[t._v(t._s(0==t.activeIndex?"选择月份":"自定义时间"))]),1==t.activeIndex?i("v-uni-view",{staticClass:"f-caption c-warning ml-sm"},[t._v("最长可查找时间跨度一年的交易")]):t._e()],1),0==t.activeIndex&&t.check_time.month||1==t.activeIndex&&(t.check_time.start_time||t.check_time.end_time)?i("v-uni-view",{staticClass:"f-paragraph",staticStyle:{color:"#5A677E"},on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.toReset.apply(void 0,arguments)}}},[t._v("清除")]):t._e()],1),0==t.activeIndex?i("v-uni-view",{staticClass:"flex-center pb-lg"},[i("v-uni-view",{staticClass:"item-child flex-center flex-column",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.toShowTime("month")}}},[i("v-uni-view",[t._v("开始月份")]),i("v-uni-view",{staticClass:"mt-sm",style:{color:t.check_time.month?t.primaryColor:"#999"}},[t._v(t._s(t.check_time.month||"选择月份"))])],1)],1):t._e(),1==t.activeIndex?i("v-uni-view",{staticClass:"flex-center pb-lg"},[i("v-uni-view",{staticClass:"item-child flex-center flex-column",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.toShowTime("start_time")}}},[i("v-uni-view",[t._v("开始时间")]),i("v-uni-view",{staticClass:"mt-sm",style:{color:t.check_time.start_time?t.primaryColor:"#999"}},[t._v(t._s(t.check_time.start_time||"选择时间"))])],1),i("v-uni-view",{staticClass:"item-child flex-center flex-column b-1px-l",on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.toShowTime("end_time")}}},[i("v-uni-view",[t._v("结束时间")]),i("v-uni-view",{staticClass:"mt-sm",style:{color:t.check_time.end_time?t.primaryColor:"#999"}},[t._v(t._s(t.check_time.end_time||"选择时间"))])],1)],1):t._e()],1),i("v-uni-view",{staticClass:"flex-center flex-column fill-body"},[i("v-uni-view",{staticClass:"space-lg"}),i("v-uni-view",{staticClass:"confirm-btn flex-center f-title c-base radius-16",style:{background:t.primaryColor},on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.toConfirm.apply(void 0,arguments)}}},[t._v("确定")]),i("v-uni-view",{staticClass:"space-lg"}),i("v-uni-view",{staticClass:"space-safe"})],1)],1)],1),i("w-picker",{ref:"day",attrs:{mode:"date",startYear:1*t.startYear-10,endYear:t.startYear,value:0==t.activeIndex?t.curMonth:t.curDay,current:!1,fields:0==t.activeIndex?"month":"day","disabled-after":!1,themeColor:t.primaryColor,visible:t.showDate},on:{confirm:function(e){arguments[0]=e=t.$handleEvent(e),t.onConfirm(e)},"update:visible":function(e){arguments[0]=e=t.$handleEvent(e),t.showDate=e}}}),i("uni-popup",{ref:"show_status_item",attrs:{type:"bottom",custom:!0}},[i("v-uni-view",{staticClass:"popup-status pd-lg fill-base"},t._l(t.typeList,(function(e,a){return i("v-uni-view",{key:a,staticClass:"flex-center f-paragraph mb-lg",class:[{"mt-lg":0==a}],style:{color:t.typeIndex==a?t.primaryColor:""},on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e),t.handerTypeChange(a)}}},[t._v(t._s(e.title))])})),1)],1)],2):t._e()},s=[]},"85dc":function(t,e,i){var a=i("c86c");e=a(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 这里是uni-app内置的常用样式变量\n *\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\n *\n */\n/**\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\n *\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\n */\n/* 颜色变量 */\n/* 行为相关颜色 */\n/* 文字基本颜色 */\n/* 背景颜色 */\n/* 边框颜色 */\n/* 尺寸变量 */\n/* 文字尺寸 */\n/* 图片尺寸 */\n/* Border Radius */\n/* 水平间距 */\n/* 垂直间距 */\n/* 透明度 */\n/* 文章场景相关 */.agent-income-commission .record-search-info[data-v-41c25e3b]{width:%?750?%}.agent-income-commission .record-search-info .record-info[data-v-41c25e3b]{width:%?710?%}.agent-income-commission .record-search-info .record-info .search-item[data-v-41c25e3b]{height:%?100?%}.agent-income-commission .record-search-info .record-info .search-item .text[data-v-41c25e3b]{color:#3d2c1b}.agent-income-commission .record-search-info .record-info .search-item .iconfont[data-v-41c25e3b]{font-size:%?26?%}.agent-income-commission .count-item[data-v-41c25e3b]{height:%?120?%}.agent-income-commission .count-item .title[data-v-41c25e3b]{padding-top:%?18?%}.agent-income-commission .count-item .title .iconfont[data-v-41c25e3b]{font-size:%?16?%}.agent-income-commission .list-item .item-text[data-v-41c25e3b]{width:%?240?%}.agent-income-commission .popup-choose-time[data-v-41c25e3b]{width:%?750?%;border-radius:%?30?% %?30?% 0 0}.agent-income-commission .popup-choose-time .icon-close[data-v-41c25e3b]{color:#a8aeb8;font-size:%?40?%}.agent-income-commission .popup-choose-time .item-child[data-v-41c25e3b]{width:50%}.agent-income-commission .popup-choose-time .confirm-btn[data-v-41c25e3b]{width:%?670?%;height:%?100?%}.agent-income-commission .popup-status[data-v-41c25e3b]{width:%?750?%;height:%?360?%;border-radius:%?30?% %?30?% 0 0}',""]),t.exports=e},f183:function(t,e,i){"use strict";i.r(e);var a=i("252e"),n=i.n(a);for(var s in a)["default"].indexOf(s)<0&&function(t){i.d(e,t,(function(){return a[t]}))}(s);e["default"]=n.a}}]); |