王总上门按摩后台代码
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
12 KiB

webpackJsonp([82],{"h3/b":function(t,e,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=a("mvHQ"),l=a.n(s),r=a("Xxa5"),n=a.n(r),i=a("exGp"),o=a.n(i),c=a("PJh5"),u=a.n(c),p={data:function(){return{total_cash:0,unrecorded_cash:0,wallet_cash:0,total_wallet_cash:0,showDialog:!1,statusTypeList:[{label:"全部",value:0},{label:"未入账",value:1},{label:"已入账",value:2}],cashTypeList:[{label:"全部",value:0},{label:"分销合伙人",value:1},{label:"代理商",value:2},{label:this.$t("action.attendantName")+"",value:3},{label:"车费",value:8},{label:"经纪人",value:9},{label:"渠道商",value:10},{label:"业务员",value:12}],statusType:{1:"未入账",2:"已入账"},cityType:{1:"城市",2:"区县",3:"省"},loading:!1,searchForm:{page:1,limit:10,order_code:"",top_name:"",status:0,type:0},tableData:[],total:0,subForm:{apply_price:"",text:""},subFormRules:{apply_price:{required:!0,validator:this.$reg.isMoney,text:"提现金额",trigger:"blur"}}}},created:function(){this.getTableDataList()},methods:{resetForm:function(t){this.$refs[t].resetFields(),this.searchForm.type=0,this.getTableDataList(1)},handleSizeChange:function(t){this.searchForm.limit=t,this.handleCurrentChange(1)},handleCurrentChange:function(t){this.searchForm.page=t,this.getTableDataList()},getTableDataList:function(t){var e=this;return o()(n.a.mark(function a(){var s,l,r,i;return n.a.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return t&&(e.searchForm.page=1),e.tableData=[],e.loading=!0,s=e.searchForm,a.next=6,e.$api.agent.cashList(s);case 6:if(l=a.sent,r=l.code,i=l.data,e.loading=!1,200===r){a.next=12;break}return a.abrupt("return");case 12:e.tableData=i.data,e.total=i.total,["total_cash","unrecorded_cash","wallet_cash"].map(function(t){e[t]=i[t]}),e.total_wallet_cash=(1*i.total_cash+1*i.wallet_cash).toFixed(2),e.subForm.apply_price=e.total_cash;case 18:case"end":return a.stop()}},a,e)}))()},confirmCashOut:function(t){var e=this;this.$confirm("点击按钮之后,表示该笔提成已经结算给线下"+this.$t("action.attendantName")+",确认已结算了吗?",this.$t("tips.reminder"),{confirmButtonText:this.$t("action.comfirm"),cancelButtonText:this.$t("action.cancel"),type:"warning"}).then(function(){e.updateItem(t)}).catch(function(){})},updateItem:function(t){var e=this;return o()(n.a.mark(function a(){return n.a.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:e.$api.shop.adminUpdateCoachCommisson({id:t}).then(function(t){200===t.code&&e.$message.success(e.$t("tips.successOper")),e.getTableDataList()});case 1:case"end":return a.stop()}},a,e)}))()},submitFormInfo:function(){var t=this;return o()(n.a.mark(function e(){var a,s,r;return n.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(a=!0,t.$refs.subForm.validate(function(t){t||(a=!1)}),!a){e.next=13;break}return s=JSON.parse(l()(t.subForm)),e.next=6,t.$api.agent.applyWallet(s);case 6:if(r=e.sent,200===r.code){e.next=10;break}return e.abrupt("return");case 10:t.$message.success(t.$t("tips.successSub")),t.showDialog=!1,t.getTableDataList();case 13:case"end":return e.stop()}},e,t)}))()}},filters:{handleTime:function(t,e){return 1===e?u()(1e3*t).format("YYYY-MM-DD"):2===e?u()(1e3*t).format("HH:mm:ss"):u()(1e3*t).format("YYYY-MM-DD HH:mm:ss")},handleCashTypeText:function(t,e){var a=e.filter(function(e){return e.value===t});return a&&a.length>0?a[0].label:""}}},d={render:function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"lb-finance-list2"},[a("top-nav"),t._v(" "),a("div",{staticClass:"page-main"},[a("lb-tips",[t._v("代理商在提现时,会将线下"+t._s(t.$t("action.attendantName"))+"的提成以及自己的分成一并提现出来\n "),a("div",{staticClass:"mt-sm"},[t._v("\n 平台统一处理后,代理商再将提现出来的费用私下结算给线下"+t._s(t.$t("action.attendantName"))+",可通过操作栏的“"+t._s(t.$t("action.attendantName"))+"转账”按钮来记录是否已转账\n ")])]),t._v(" "),a("el-row",{staticClass:"page-search-form"},[a("div",{staticClass:"flex-center pt-sm pb-lg c-title"},[a("div",[a("div",[t._v("\n 可用余额(包含线下"+t._s(t.$t("action.attendantName"))+"的提成)\n ")]),t._v(" "),a("div",{staticClass:"f-lg-title mt-md flex-y-center cursor-pointer"},[a("div",{staticClass:"c-link mr-md"},[t._v(t._s(t.total_cash||0))]),t._v(" "),a("el-button",{attrs:{type:"primary",size:"mini",plain:""},on:{click:function(e){t.showDialog=!0}}},[t._v("提现")]),t._v(" "),a("div",{staticClass:"f-title c-link ml-md",on:{click:function(e){return t.$router.push("/finance/record")}}},[t._v("\n 提现记录\n ")])],1)]),t._v(" "),a("div",{staticClass:"flex-1 flex-center"},[a("div",[a("div",[t._v("总金额(元)")]),t._v(" "),a("div",{staticClass:"f-lg-title mt-md"},[t._v("\n "+t._s(t.total_wallet_cash||0)+"\n ")])])]),t._v(" "),a("div",[a("div",[t._v("\n 未入账(元)"),a("lb-tool-tips",{attrs:{padding:0}},[t._v("\n 平台未到账的服务订单金额\n ")])],1),t._v(" "),a("div",{staticClass:"f-lg-title mt-md"},[t._v("\n "+t._s(t.unrecorded_cash||0)+"\n ")])])])]),t._v(" "),a("el-row",{staticClass:"page-search-form"},[a("el-form",{ref:"searchForm",attrs:{inline:!0,model:t.searchForm},nativeOn:{submit:function(t){t.preventDefault()}}},[a("el-form-item",{attrs:{label:"佣金获得者",prop:"top_name"}},[a("el-input",{attrs:{placeholder:"请输入佣金获得者姓名"},model:{value:t.searchForm.top_name,callback:function(e){t.$set(t.searchForm,"top_name",e)},expression:"searchForm.top_name"}})],1),t._v(" "),a("el-form-item",{attrs:{label:"系统订单号",prop:"order_code"}},[a("el-input",{attrs:{placeholder:"请输入系统订单号"},model:{value:t.searchForm.order_code,callback:function(e){t.$set(t.searchForm,"order_code",e)},expression:"searchForm.order_code"}})],1),t._v(" "),a("el-form-item",{attrs:{label:"佣金类型",prop:"status"}},[a("el-select",{attrs:{placeholder:"请选择"},on:{change:function(e){return t.getTableDataList(1)}},model:{value:t.searchForm.type,callback:function(e){t.$set(t.searchForm,"type",e)},expression:"searchForm.type"}},t._l(t.cashTypeList,function(t){return a("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})}),1)],1),t._v(" "),a("el-form-item",{attrs:{label:"状态",prop:"status"}},[a("el-select",{attrs:{placeholder:"请选择"},on:{change:function(e){return t.getTableDataList(1)}},model:{value:t.searchForm.status,callback:function(e){t.$set(t.searchForm,"status",e)},expression:"searchForm.status"}},t._l(t.statusTypeList,function(t){return a("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})}),1)],1),t._v(" "),a("el-form-item",[a("lb-button",{staticStyle:{"margin-right":"5px"},attrs:{size:"medium",type:"primary",icon:"el-icon-search"},on:{click:function(e){return t.getTableDataList(1)}}},[t._v(t._s(t.$t("action.search")))]),t._v(" "),a("lb-button",{staticStyle:{"margin-right":"5px"},attrs:{size:"medium",icon:"el-icon-refresh-left"},on:{click:function(e){return t.resetForm("searchForm")}}},[t._v(t._s(t.$t("action.reset")))])],1)],1)],1),t._v(" "),a("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticStyle:{width:"100%"},attrs:{data:t.tableData,"header-cell-style":{background:"#f5f7fa",color:"#606266"}}},[a("el-table-column",{attrs:{prop:"id",label:"ID","min-width":"80",fixed:""}}),t._v(" "),a("el-table-column",{attrs:{prop:"top_name",label:"佣金获得者","min-width":"120"}}),t._v(" "),a("el-table-column",{attrs:{prop:"nickName",label:"来源","min-width":"120"}}),t._v(" "),a("el-table-column",{attrs:{prop:"order_code",width:"150",label:"系统订单号"}}),t._v(" "),a("el-table-column",{attrs:{prop:"transaction_id",width:"150",label:"商户订单号"}}),t._v(" "),a("el-table-column",{attrs:{prop:"type",label:"佣金类型","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("div",{staticClass:"flex-y-center"},[a("div",[t._v("\n "+t._s([2,5,6].includes(e.row.type)?t.cityType[e.row.city_type]:"")+"\n ")]),t._v(" "),a("div",[t._v("\n "+t._s(t._f("handleCashTypeText")(e.row.type,t.cashTypeList))+"\n ")])])]}}])}),t._v(" "),a("el-table-column",{attrs:{prop:"status",label:"状态"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t.statusType[e.row.status])+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{prop:"pay_price",label:"订单总金额","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" ¥"+t._s(e.row.pay_price))]}}])}),t._v(" "),a("el-table-column",{attrs:{prop:"order_goods",label:"提成比例","min-width":"300"},scopedSlots:t._u([{key:"default",fn:function(e){return[1===e.row.type?a("div",t._l(e.row.order_goods,function(e,s){return a("div",{key:s,staticClass:"pb-sm",staticStyle:{width:"250px"}},[a("div",{staticClass:"flex-center pt-md"},[a("lb-image",{staticClass:"avatar radius-5",attrs:{src:e.goods_cover}}),t._v(" "),a("div",{staticClass:"flex-1 f-caption c-caption ml-md",staticStyle:{width:"180px"}},[a("div",{staticClass:"flex-between"},[a("div",{staticClass:"f-paragraph c-title ellipsis",staticStyle:{"line-height":"1.2","margin-bottom":"4px"}},[t._v("\n "+t._s(e.goods_name)+"\n ")])]),t._v(" "),a("div",{staticClass:"flex-y-center"},[t._v("\n 提成比例\n "),a("div",{staticClass:"c-warning ml-sm"},[t._v(t._s(e.balance)+"%")])]),t._v(" "),a("div",{staticClass:"flex-between f-caption"},[a("div",{staticClass:"c-warning"},[t._v("¥"+t._s(e.true_price))]),t._v(" "),a("div",[t._v("x"+t._s(e.num))])])])],1)])}),0):8===e.row.type?a("div",[t._v("-")]):a("div",[t._v(t._s(e.row.balance)+"%")])]}}])}),t._v(" "),a("el-table-column",{attrs:{prop:"cash",label:"此单提成金额","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" ¥"+t._s(e.row.cash))]}}])}),t._v(" "),a("el-table-column",{attrs:{prop:"create_time","min-width":"120",label:"时间"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("div",[t._v(t._s(t._f("handleTime")(e.row.create_time,1)))]),t._v(" "),a("div",[t._v(t._s(t._f("handleTime")(e.row.create_time,2)))])]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"操作","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("div",{staticClass:"table-operate"},[1===e.row.coach_cash_control?a("lb-button",{attrs:{disabled:1===e.row.cash_status,size:"mini",plain:"",type:0===e.row.cash_status?"primary":"info"},on:{click:function(a){0===e.row.cash_status&&t.confirmCashOut(e.row.id)}}},[t._v(t._s(0===e.row.cash_status?t.$t("action.attendantName")+"转账":"已转账"))]):t._e()],1)]}}])})],1),t._v(" "),a("lb-page",{attrs:{batch:!1,page:t.searchForm.page,pageSize:t.searchForm.limit,total:t.total},on:{handleSizeChange:t.handleSizeChange,handleCurrentChange:t.handleCurrentChange}})],1),t._v(" "),a("el-dialog",{attrs:{title:"提现信息核对",visible:t.showDialog,width:"600px",center:""},on:{"update:visible":function(e){t.showDialog=e}}},[a("el-form",{ref:"subForm",staticClass:"dialog-form",attrs:{model:t.subForm,rules:t.subFormRules,"label-width":"120px"}},[a("el-form-item",{attrs:{label:"提现金额",prop:"apply_price"}},[a("el-input",{attrs:{placeholder:"请输入提现金额"},model:{value:t.subForm.apply_price,callback:function(e){t.$set(t.subForm,"apply_price",e)},expression:"subForm.apply_price"}},[a("template",{slot:"append"},[t._v("元")])],2)],1),t._v(" "),a("el-form-item",{attrs:{label:"备注信息",prop:"text"}},[a("el-input",{attrs:{type:"textarea",rows:10,maxlength:"300","show-word-limit":"",resize:"none",placeholder:"请输入备注信息"},model:{value:t.subForm.text,callback:function(e){t.$set(t.subForm,"text",e)},expression:"subForm.text"}})],1)],1),t._v(" "),a("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{on:{click:function(e){t.showDialog=!1}}},[t._v("取 消")]),t._v(" "),a("el-button",{directives:[{name:"preventReClick",rawName:"v-preventReClick"}],attrs:{type:"primary"},on:{click:function(e){return t.submitFormInfo("sub")}}},[t._v("确 定")])],1)],1)],1)},staticRenderFns:[]};var m=a("VU/8")(p,d,!1,function(t){a("pocR")},"data-v-3796caaf",null);e.default=m.exports},pocR:function(t,e){}});