|
@ -11,15 +11,39 @@ |
|
|
<div class="flex"> |
|
|
<div class="flex"> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
<div class="mt24" v-if="totalType == '1'"> |
|
|
<div class="mt24 payoff-set" v-if="totalType == '1'"> |
|
|
<el-form class="el-row demo-ruleForm" ref="formRef"> |
|
|
<el-form> |
|
|
ddd |
|
|
<div class="flex gap12 mb24"> |
|
|
</el-form> |
|
|
<img src="@/assets/pay/pay_3.svg" alt=""> |
|
|
|
|
|
<span>支付宝收款</span> |
|
|
|
|
|
<GuipSwitch float="right" :active-value="1" :inactive-value="0" activeText="开启" inactiveText="关闭" @change="onSwitchChange"></GuipSwitch> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="payoff-area flex-between" v-if="payoffInfo"> |
|
|
|
|
|
<div class="payoff-info"> |
|
|
|
|
|
<div class="payoff-acc">收款支付宝账号:{{payoffInfo.openid}}</div> |
|
|
|
|
|
<div class="payoff-name">收款人真实姓名:{{payoffInfo.realname}}</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="flex gap12"> |
|
|
|
|
|
<span class="payoff-has">已配置</span> |
|
|
|
|
|
<GuipButton type="system" @click="handlePayoffInfo()" :btnstyle="{'color':'#006AFF','background':'#FFFFFF','broder-color':'#006AFF'}">修改账号</GuipButton> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<div class="payoff-area flex-between" v-else> |
|
|
|
|
|
<div class="payoff-info"> |
|
|
|
|
|
<div class="payoff-acc">设置收款账号,开启平台代收款,平台收取5%服务费</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="flex gap12"> |
|
|
|
|
|
<span class="payoff-no">未设置</span> |
|
|
|
|
|
<GuipButton type="danger" @click="handlePayoffInfo()" :btnstyle="{'color':'#fff','background':'#FF4D4F','broder-color':'#FF4D4F'}">立即设置</GuipButton> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</el-form> |
|
|
</div> |
|
|
</div> |
|
|
<el-form class="mt24" v-else> |
|
|
<div class="mt24" v-if="totalType == '2'"> |
|
|
<PromptText v-if="totalType == '2'" text="温馨提示:满200元自动结算,次日凌晨打款;通过微信收到的货款,有7天账期(例如:周一的收入,下周一才能结算提现)。" :type="1" class="mb32"/> |
|
|
<el-form> |
|
|
<GuipTable :tableData="tableList" :key="tableKey" ref="multipleTable" autoColumn="true" :loading="tableLoading" style="flex:1"> |
|
|
<PromptText text="温馨提示:满200元自动结算,次日凌晨打款;通过微信收到的货款,有7天账期(例如:周一的收入,下周一才能结算提现)。" :type="1" class="mb32"/> |
|
|
<template v-if="totalType == '2'"> |
|
|
<GuipTable :tableData="tableList" :key="tableKey" ref="multipleTable" autoColumn="true" :loading="tableLoading" style="flex:1"> |
|
|
<el-table-column fixed="left" prop="tid" label="订单号" min-width="200px"> |
|
|
<el-table-column fixed="left" prop="tid" label="订单号" min-width="200px"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<span v-if="scope.row.tid">{{scope.row.tid}}</span> |
|
|
<span v-if="scope.row.tid">{{scope.row.tid}}</span> |
|
@ -53,8 +77,13 @@ |
|
|
</div> |
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
</template> |
|
|
</GuipTable> |
|
|
<template v-else> |
|
|
</el-form> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="mt24" v-if="totalType == '3'"> |
|
|
|
|
|
<el-form> |
|
|
|
|
|
<PromptText text="每天凌晨出具前一天已完成的订单账单" :type="1" class="mb32"/> |
|
|
|
|
|
<GuipTable :tableData="tableList" :key="tableKey" ref="multipleTable" autoColumn="true" :loading="tableLoading" style="flex:1"> |
|
|
<el-table-column prop="short_name" label="账号"></el-table-column> |
|
|
<el-table-column prop="short_name" label="账号"></el-table-column> |
|
|
<el-table-column prop="bill_date" label="账单日期"></el-table-column> |
|
|
<el-table-column prop="bill_date" label="账单日期"></el-table-column> |
|
|
<el-table-column prop="pay_type" label="支付类型"> |
|
|
<el-table-column prop="pay_type" label="支付类型"> |
|
@ -72,17 +101,28 @@ |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
<el-table-column prop="money" label="操作"> |
|
|
<el-table-column prop="money" label="操作"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<GuipButton type="text" @click="handleShowInfo(scope.row.tid)">查看核算账单</GuipButton> |
|
|
<GuipButton type="text" @click="handleShowInfo(scope.row.id,scope.row.uid,scope.row.pay_type)">查看核算账单</GuipButton> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
|
|
|
</GuipTable> |
|
|
|
|
|
</el-form> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
<GuipDialog :dialogVisible="dialogVisible" title="修改支付宝收款方式" :show-close-button="false" :show-cancel-button="true" @confirm="handleSavePayoffInfo()" @cancel="handleHidePayoffInfo()"> |
|
|
|
|
|
<el-form :model="formData" :rules="formRules" ref="formRef" class="payoff-form"> |
|
|
|
|
|
<PromptText text="须知" :type="1"> |
|
|
|
|
|
<template #desc> |
|
|
|
|
|
<div class="mt12">使用平台“支付宝支付”,平台收取5%的服务费</div> |
|
|
|
|
|
<div class="mt12">使用平台“支付宝支付”,真实姓名必须和支付宝账号实名认证姓名统一</div> |
|
|
</template> |
|
|
</template> |
|
|
</GuipTable> |
|
|
</PromptText> |
|
|
<el-pagination background @size-change='handleSizeChange' @current-change='handleCurrentChange' |
|
|
<GuipInput label="1. 收款人姓名" class="column" ref="GuipInput" prop="realname" |
|
|
:current-page="currentPage" :page-size=pageSize layout="prev, pager, next,jumper" |
|
|
desc="请输入支付宝绑定的银行卡的持卡人姓名" :rules="formRules.realname" v-model="formData.realname"/> |
|
|
:total="parseInt(total)"> |
|
|
|
|
|
</el-pagination> |
|
|
<GuipInput label="2. 收款支付宝账号" class="column" ref="GuipInput" prop="openid" |
|
|
|
|
|
desc="请输入有效账号" :rules="formRules.openid" v-model="formData.openid"/> |
|
|
</el-form> |
|
|
</el-form> |
|
|
</div> |
|
|
</GuipDialog> |
|
|
</div> |
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
|
<script> |
|
|
<script> |
|
@ -91,67 +131,88 @@ import GuipButton from "@/components/GuipButton.vue"; |
|
|
import GuipTable from "@/components/GuipTable.vue"; |
|
|
import GuipTable from "@/components/GuipTable.vue"; |
|
|
import GuipToolTip from "@/components/GuipToolTip.vue"; |
|
|
import GuipToolTip from "@/components/GuipToolTip.vue"; |
|
|
import PromptText from "@/components/PromptText.vue"; |
|
|
import PromptText from "@/components/PromptText.vue"; |
|
|
|
|
|
import GuipSwitch from "@/components/GuipSwitch.vue"; |
|
|
|
|
|
import GuipDialog from "@/components/GuipDialog.vue"; |
|
|
|
|
|
import GuipInput from "@/components/GuipInput.vue"; |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
components: { |
|
|
components: { |
|
|
|
|
|
GuipInput, |
|
|
|
|
|
GuipDialog, |
|
|
|
|
|
GuipSwitch, |
|
|
PromptText, |
|
|
PromptText, |
|
|
GuipToolTip, |
|
|
GuipToolTip, |
|
|
GuipTable, |
|
|
GuipTable, |
|
|
GuipButton, |
|
|
GuipButton, |
|
|
}, |
|
|
}, |
|
|
props: { |
|
|
|
|
|
total_type: { |
|
|
|
|
|
type: String, |
|
|
|
|
|
default: '1' |
|
|
|
|
|
}, |
|
|
|
|
|
}, |
|
|
|
|
|
data() { |
|
|
data() { |
|
|
return { |
|
|
return { |
|
|
totalType:'1', |
|
|
totalType:'1', |
|
|
tableLoading:false, |
|
|
tableLoading:false, |
|
|
|
|
|
|
|
|
walletType: '', |
|
|
payoffInfo:[], |
|
|
walletList:[], |
|
|
dialogVisible: false, |
|
|
|
|
|
formData: { |
|
|
prompt:'', |
|
|
openid: '', |
|
|
prompt_link:'', |
|
|
realname: '', |
|
|
bonus:[], |
|
|
}, |
|
|
buy_price_type: '', |
|
|
formRules: { |
|
|
buy_price_types: {}, |
|
|
openid: [ |
|
|
buy_price_link: '', |
|
|
{ required: true, message: '请输入收款人姓名', trigger: 'blur' } |
|
|
buy_price_links: {}, |
|
|
], |
|
|
links_desc: '', |
|
|
realname: [ |
|
|
|
|
|
{ required: true, message: '请输入收款支付宝账号', trigger: 'blur' } |
|
|
ordernum:'', |
|
|
], |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
tableKey: '', |
|
|
tableKey: '', |
|
|
tableList:[], |
|
|
tableList:[], |
|
|
currentPage: 1, //当前页 |
|
|
|
|
|
pageSize: 20, //每页的容量 |
|
|
|
|
|
total: 0, //列表总数 |
|
|
|
|
|
total_money: 0, //列表总数 |
|
|
|
|
|
tid2refunds: [], //列表总数 |
|
|
|
|
|
dialogVisible: false, |
|
|
|
|
|
refund_detail: [], |
|
|
|
|
|
|
|
|
|
|
|
confirmBtnStyle: { |
|
|
|
|
|
'background':'#FF4D4F', |
|
|
|
|
|
'color':'#FFFFFF', |
|
|
|
|
|
'border':'1px solid #FF4D4F', |
|
|
|
|
|
'border-radius':'4px', |
|
|
|
|
|
'width': '88px', |
|
|
|
|
|
'height': '33px', |
|
|
|
|
|
'font-size': '12px', |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
mounted() { |
|
|
mounted() { |
|
|
this.$nextTick(()=>{ |
|
|
this.$nextTick(()=>{ |
|
|
this.totalType = this.total_type; |
|
|
if(this.$route.query.total_type)this.totalType = this.$route.query.total_type; |
|
|
this.handleClick() |
|
|
this.handleClick() |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
onSwitchChange(){ |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
handlePayoffInfo(){ |
|
|
|
|
|
this.dialogVisible = true |
|
|
|
|
|
this.formData.openid = this.payoffInfo.openid |
|
|
|
|
|
this.formData.realname = this.payoffInfo.realname |
|
|
|
|
|
}, |
|
|
|
|
|
handleSavePayoffInfo(){ |
|
|
|
|
|
this.dialogVisible = false |
|
|
|
|
|
this.$refs.formRef.validate((valid) => { |
|
|
|
|
|
if(valid){ |
|
|
|
|
|
try { |
|
|
|
|
|
this.$http('POST', '/agentnew/ajax_set_payoff_info', { |
|
|
|
|
|
pay_type: this.payoffInfo.pay_type, |
|
|
|
|
|
zfb_acct: this.formData.openid, |
|
|
|
|
|
realname: this.formData.realname |
|
|
|
|
|
}).then(response => { |
|
|
|
|
|
if (response.status) { |
|
|
|
|
|
this.$message.success('设置成功'); |
|
|
|
|
|
this.payoffInfo.openid = this.formData.openid |
|
|
|
|
|
this.payoffInfo.realname = this.formData.realname |
|
|
|
|
|
return true; |
|
|
|
|
|
} |
|
|
|
|
|
this.$message.error(response.info); |
|
|
|
|
|
}).catch(error => { |
|
|
|
|
|
console.error(error, 'error') |
|
|
|
|
|
}) |
|
|
|
|
|
} catch (error) { |
|
|
|
|
|
console.error('数据加载失败:', error) |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
}, |
|
|
|
|
|
handleHidePayoffInfo(){ |
|
|
|
|
|
this.dialogVisible = false |
|
|
|
|
|
}, |
|
|
payoffStatusClass(status){ |
|
|
payoffStatusClass(status){ |
|
|
if(status == '异常') return 'status-info warning'; |
|
|
if(status == '异常') return 'status-info warning'; |
|
|
if(status == '成功') return 'status-info success'; |
|
|
if(status == '成功') return 'status-info success'; |
|
@ -163,16 +224,15 @@ export default { |
|
|
}, |
|
|
}, |
|
|
handleClick(){ |
|
|
handleClick(){ |
|
|
this.tableList = [] |
|
|
this.tableList = [] |
|
|
this.total_money = 0 |
|
|
if(this.totalType == 1) this.getPayoffData() |
|
|
if(this.totalType == 1) this.getRechargeData() |
|
|
|
|
|
if(this.totalType == 2) this.getPayoffList() |
|
|
if(this.totalType == 2) this.getPayoffList() |
|
|
if(this.totalType == 3) this.getBillList() |
|
|
if(this.totalType == 3) this.getBillList() |
|
|
}, |
|
|
}, |
|
|
getRechargeData() { |
|
|
getPayoffData() { |
|
|
try { |
|
|
try { |
|
|
this.$http('POST', '/agentnew/ajax_get_recharge_data', {date: this.date}).then(response => { |
|
|
this.$http('POST', '/agentnew/ajax_get_payoff_info', {date: this.date}).then(response => { |
|
|
this.$nextTick(() => { |
|
|
this.$nextTick(() => { |
|
|
this.walletList = response.data |
|
|
this.payoffInfo = response.data |
|
|
}) |
|
|
}) |
|
|
}).catch(error => { |
|
|
}).catch(error => { |
|
|
console.error(error, 'error') |
|
|
console.error(error, 'error') |
|
@ -184,11 +244,7 @@ export default { |
|
|
getPayoffList() { |
|
|
getPayoffList() { |
|
|
this.tableLoading = true |
|
|
this.tableLoading = true |
|
|
try { |
|
|
try { |
|
|
this.$http('POST', '/agentnew/ajax_get_payoff_list', { |
|
|
this.$http('POST', '/agentnew/ajax_get_payoff_list', {}).then(response => { |
|
|
type: this.walletType, |
|
|
|
|
|
cur_page: this.currentPage, |
|
|
|
|
|
page_size: this.pageSize |
|
|
|
|
|
}).then(response => { |
|
|
|
|
|
this.tableLoading = false |
|
|
this.tableLoading = false |
|
|
this.$nextTick(() => { |
|
|
this.$nextTick(() => { |
|
|
this.tableList = response.data.list |
|
|
this.tableList = response.data.list |
|
@ -205,7 +261,7 @@ export default { |
|
|
getBillList() { |
|
|
getBillList() { |
|
|
this.tableLoading = true |
|
|
this.tableLoading = true |
|
|
try { |
|
|
try { |
|
|
this.$http('POST', '/agentnew/ajax_get_bill_list', {date: this.date}).then(response => { |
|
|
this.$http('POST', '/agentnew/ajax_get_bill_list', {}).then(response => { |
|
|
this.tableLoading = false |
|
|
this.tableLoading = false |
|
|
this.$nextTick(() => { |
|
|
this.$nextTick(() => { |
|
|
this.tableList = response.data.list |
|
|
this.tableList = response.data.list |
|
@ -219,56 +275,34 @@ export default { |
|
|
this.tableLoading = false |
|
|
this.tableLoading = false |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
doRecharge(){ |
|
|
handleShowInfo(id,uid,pay_type){ |
|
|
try { |
|
|
this.$router.push(`/agent/payoffDetails?id=${id}&uid=${uid}&pay_type=${pay_type}&total_type=${this.totalType}`) |
|
|
this.$http('POST', '/agentnew/ajax_do_recharge', {orderId: this.ordernum,type: this.walletType}).then(response => { |
|
|
|
|
|
if (response.status) { |
|
|
|
|
|
this.$message.success('充值成功'); |
|
|
|
|
|
return true; |
|
|
|
|
|
} |
|
|
|
|
|
this.$message.error(response.info); |
|
|
|
|
|
}).catch(error => { |
|
|
|
|
|
console.error(error, 'error') |
|
|
|
|
|
}) |
|
|
|
|
|
} catch (error) { |
|
|
|
|
|
console.error('数据加载失败:', error) |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
confirmRecharge(id, tid){ |
|
|
|
|
|
try { |
|
|
|
|
|
this.$http('POST', '/agentnew/ajax_confirm_recharge', {orderId: tid,type: this.walletType,recharge_id: id}).then(response => { |
|
|
|
|
|
if (response.status) { |
|
|
|
|
|
this.$message.success('充值成功'); |
|
|
|
|
|
return true; |
|
|
|
|
|
} |
|
|
|
|
|
this.$message.error(response.info); |
|
|
|
|
|
}).catch(error => { |
|
|
|
|
|
console.error(error, 'error') |
|
|
|
|
|
}) |
|
|
|
|
|
} catch (error) { |
|
|
|
|
|
console.error('数据加载失败:', error) |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
handleSizeChange(val) { |
|
|
|
|
|
this.pageSize = val |
|
|
|
|
|
this.getRechargeList() |
|
|
|
|
|
}, |
|
|
|
|
|
handleCurrentChange(val) { |
|
|
|
|
|
this.currentPage = val |
|
|
|
|
|
this.getRechargeList() |
|
|
|
|
|
}, |
|
|
|
|
|
handleShowInfo(){ |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
</script> |
|
|
</script> |
|
|
<style lang="scss" scoped> |
|
|
<style lang="scss" scoped> |
|
|
|
|
|
.payoff-form{ |
|
|
|
|
|
::v-deep .prompt-text{ |
|
|
|
|
|
padding: 20px 14px; |
|
|
|
|
|
} |
|
|
|
|
|
::v-deep .prompt-desc{ |
|
|
|
|
|
font-weight: bold; |
|
|
|
|
|
} |
|
|
|
|
|
.column{ |
|
|
|
|
|
margin-bottom: 0; |
|
|
|
|
|
margin-top: 24px; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
.payoff-wrap{ |
|
|
.payoff-wrap{ |
|
|
::v-deep .el-tabs__header{ |
|
|
::v-deep .el-tabs__header{ |
|
|
margin: 0; |
|
|
margin: 0; |
|
|
} |
|
|
} |
|
|
|
|
|
::v-deep .el-form-item { |
|
|
|
|
|
margin-bottom: 0; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
.pagetitle { |
|
|
.pagetitle { |
|
|
text-align: left; |
|
|
text-align: left; |
|
|
font-size: 16px; |
|
|
font-size: 16px; |
|
@ -281,6 +315,37 @@ export default { |
|
|
.w16{ |
|
|
.w16{ |
|
|
width: 16px; |
|
|
width: 16px; |
|
|
} |
|
|
} |
|
|
|
|
|
.payoff-set{ |
|
|
|
|
|
background: #FAFAFA; |
|
|
|
|
|
padding: 24px 14px; |
|
|
|
|
|
} |
|
|
|
|
|
.payoff-area{ |
|
|
|
|
|
padding: 24px 16px; |
|
|
|
|
|
border-radius: 8px; |
|
|
|
|
|
background: #FFFFFF; |
|
|
|
|
|
letter-spacing: 0.08em; |
|
|
|
|
|
font-size: 14px; |
|
|
|
|
|
text-align: left; |
|
|
|
|
|
.payoff-info{ |
|
|
|
|
|
display: flex; |
|
|
|
|
|
flex-direction: column; |
|
|
|
|
|
gap: 10px; |
|
|
|
|
|
.payoff-acc{ |
|
|
|
|
|
color: #1E2226; |
|
|
|
|
|
} |
|
|
|
|
|
.payoff-name{ |
|
|
|
|
|
color: #6B7280; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.payoff-has{ |
|
|
|
|
|
color: #00C261; |
|
|
|
|
|
} |
|
|
|
|
|
.payoff-no{ |
|
|
|
|
|
color: #FF4D4F; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
.status-info{ |
|
|
.status-info{ |
|
|
display: inline-block; |
|
|
display: inline-block; |
|
|
padding: 2px 10px; |
|
|
padding: 2px 10px; |
|
|