Browse Source

收款列表

pull/59/head
rainbro 6 days ago
parent
commit
313341bd5b
  1. 187
      src/views/agent/payList.vue

187
src/views/agent/payList.vue

@ -43,7 +43,7 @@
<el-table-column label="操作" fixed="right" min-width="30px">
<template slot-scope="scope">
<div class="flex">
<el-button @click="handleClick(scope.row)" type="text">设置</el-button>
<el-button @click="handleClick2(scope.row)" type="text">设置</el-button>
</div>
</template>
</el-table-column>
@ -87,7 +87,7 @@
<el-table-column label="操作" fixed="right" min-width="30px">
<template slot-scope="scope">
<div class="flex">
<el-button @click="handleClick(scope.row)" type="text">设置</el-button>
<el-button @click="handleClick2(scope.row)" type="text">设置</el-button>
</div>
</template>
</el-table-column>
@ -128,7 +128,7 @@
<el-table-column label="操作" fixed="right" min-width="30px">
<template slot-scope="scope">
<div class="flex">
<el-button @click="handleClick(scope.row)" type="text">设置</el-button>
<el-button @click="handleClick2(scope.row)" type="text">设置</el-button>
</div>
</template>
</el-table-column>
@ -170,7 +170,7 @@
<el-table-column label="操作" fixed="right" min-width="30px">
<template slot-scope="scope">
<div class="flex">
<el-button @click="handleClick(scope.row)" type="text">设置</el-button>
<el-button @click="handleClick2(scope.row)" type="text">设置</el-button>
</div>
</template>
</el-table-column>
@ -211,7 +211,7 @@
<el-table-column label="操作" fixed="right" min-width="30px">
<template slot-scope="scope">
<div class="flex">
<el-button @click="handleClick(scope.row)" type="text">设置</el-button>
<el-button @click="handleClick2(scope.row)" type="text">设置</el-button>
</div>
</template>
</el-table-column>
@ -224,9 +224,10 @@
<GuipDialog :dialogVisible="addPayDialogVisible" :title="addPayTitle" :show-close-button="false"
:show-cancel-button="showCancelButton" @confirm="addPayment" @cancel="handleCancel"
@close="handleClose" @dialogVisibleChange="dialogVisibleChange" :confirmText="addPayconfirmText">
@close="handleClose" @dialogVisibleChange="dialogVisibleChange" :confirmText="addPayconfirmText" width="700px">
<!-- 自定义内容 -->
<div>
<!-- 淘宝 -->
<div class="taobaopay" v-if="addPayType==0">
<div class="beforeNotice">
<h4 class="flex"> <img src="@/assets/site/siteSemInfo_Icon.svg" alt=""> 前期准备事项</h4>
@ -238,7 +239,7 @@
</p>
</div>
</div>
<!-- 微信 -->
<div class="weixinpay" v-else-if="addPayType==2">
<div class="beforeNotice">
<h4 class="flex"> <img src="@/assets/site/siteSemInfo_Icon.svg" alt=""> 前期准备事项</h4>
@ -253,30 +254,75 @@
<el-form>
<GuipFormItem column="column" class="mb24" label="1. 公司简称">
<span class="desc" slot="formRight">请输入公司简称便于您区分账号所属公司</span>
<GuipInput slot="formDom" ref="GuipInput" column="column"
prop="visit_day" placeholder="6字以内">
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="company_short_name" prop="company_short_name" placeholder="6字以内">
</GuipInput>
</GuipFormItem>
<GuipFormItem column="column" class="mb24" label="2. 支付商户号(mch_id)">
<span class="desc" slot="formRight"><a href='https://pay.weixin.qq.com/' target='_blank'>微信支付平台</a>账户中心商户信息微信支付商户号</span>
<GuipInput slot="formDom" ref="GuipInput" column="column"
prop="visit_day" placeholder="请输入">
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="mch_id" prop="mch_id" placeholder="请输入商户号">
</GuipInput>
</GuipFormItem>
<GuipFormItem column="column" class="mb24" label="3. 微信支付秘钥">
<span class="desc" slot="formRight"><a href='https://pay.weixin.qq.com/' target='_blank'>微信支付平台</a>账号中心账户设置API安全APIv2密钥注意支付密钥不能设置为纯数字</span>
<GuipInput slot="formDom" ref="GuipInput" column="column"
prop="visit_day" placeholder="请输入">
<span class="desc" slot="formRight"><a href='https://pay.weixin.qq.com/' target='_blank'>微信支付平台</a>账号中心账户设置API安全APIv2密钥<p class="mt10">注意支付密钥不能设置为纯数字</p></span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="apiv2" prop="apiv2" placeholder="请输入微信支付秘钥">
</GuipInput>
</GuipFormItem>
<GuipFormItem column="column" class="mb24" label="4. 公众号APPID">
<span class="desc" slot="formRight"><a href='https://mp.weixin.qq.com/' target='_blank'>公众平台</a>设置与开发基本配置公众号开发信息开发者IDAPPID</span>
<GuipInput slot="formDom" ref="GuipInput" column="column"
prop="visit_day" placeholder="请输入">
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="appid" prop="appid" placeholder="请输入公众号APPID">
</GuipInput>
</GuipFormItem>
</el-form>
</div>
<!-- 支付宝 -->
<div class="alipay" v-if="addPayType==3">
<el-tabs v-model="isPayPublic" @tab-click="handleClick">
<el-tab-pane label="我有公司,使用本公司支付宝" name="0">
<el-form>
<GuipFormItem column="column" class="mb24" label="1. 公司简称">
<span class="desc" slot="formRight">请输入公司简称便于您区分账号所属公司</span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="company_short_name" prop="company_short_name" placeholder="6字以内"></GuipInput>
</GuipFormItem>
<GuipFormItem column="column" class="mb24" label="2. 公司支付宝账号">
<span class="desc" slot="formRight">仅支持已签约 当面付 功能的公司支付宝</span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="alipay_account" prop="mch_id" placeholder="请输入公司支付宝账号"></GuipInput>
</GuipFormItem>
</el-form>
</el-tab-pane>
<el-tab-pane label="我无公司,申请平台代收款" name="1" v-if="isExistSelfSupplys===false">
<div class="beforeNotice">
<h4 class="flex"> <img src="@/assets/site/siteSemInfo_Icon.svg" alt=""> 须知</h4>
<p class="mt12">使用平台支付宝支付平台收取5%的服务费</p>
<p class="mt12 flex">使用平台支付宝支付真实姓名必须和支付宝账号实名认证姓名统一</p>
</div>
<el-form>
<GuipFormItem column="column" class="mb24" label="1. 收款人姓名">
<span class="desc" slot="formRight">请输入支付宝绑定的银行卡的持卡人姓名</span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="receive_payment_name" prop="company_short_name" placeholder="6字以内"></GuipInput>
</GuipFormItem>
<GuipFormItem column="column" class="mb24" label="2. 收款支付宝账号">
<span class="desc" slot="formRight">请输入有效账号</span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="receive_payment_account" prop="mch_id" placeholder="请输入有效收款支付宝账号"></GuipInput>
</GuipFormItem>
</el-form>
</el-tab-pane>
</el-tabs>
</div>
<!-- 拼多多 -->
<div class="alipay" v-if="addPayType==11">
<div class="beforeNotice">
<h4 class="flex"> <img src="@/assets/site/siteSemInfo_Icon.svg" alt=""> 前期准备事项</h4>
<p class="mt12 flex">主账号登录并授权<a :href="pddAuthUrl" class="flex" target="_blank"><img src="@/assets/site/form_linkActive.svg" alt="">去授权</a></p>
<p class="mt12 flex gray">如未购买快乐帮手服务或已过期会跳转到购买服务页面</p>
<p class="mt5 flex gray">授权成功后会进入快乐帮手烽火台复制右上角名称填入下方保存</p>
</div>
<el-form>
<GuipFormItem column="column" class="mb24" label="账号名称">
<!-- <span class="desc" slot="formRight">账号名称</span> -->
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="pdd_shop_name" prop="company_short_name" placeholder="请输入账号名称"></GuipInput>
</GuipFormItem>
</el-form>
</div>
</div>
</GuipDialog>
</div>
@ -326,6 +372,20 @@ export default {
addPayType: '',
addPayconfirmText: '确定',
taobaoAuthUrl: '',
company_short_name: '',
mch_id: '',
apiv2: '',
appid: '',
alipay_account: '',
isExistSelfSupplys: false,
receive_payment_account: '',
receive_payment_name: '',
isPayPublic: '0',
pddAuthUrl: '',
pdd_shop_name: '',
}
},
computed: {
@ -349,6 +409,8 @@ export default {
this.$nextTick(() => {
this.addablePays = response.data
this.taobaoAuthUrl = response.data[0].authurl
this.isExistSelfSupplys = response.data[3].is_exist_self_supplys
this.pddAuthUrl = response.data[11].authurl
})
}).catch(error => {
console.error(error, 'error')
@ -429,7 +491,88 @@ export default {
addPayment() {
if (this.addPayType == 0) {
window.open(this.taobaoAuthUrl, '_blank');
} else if (this.addPayType == 2) {
this.$http('POST', '/agentnew/ajax_add_weixinpay', {
company_short_name: this.company_short_name,
mch_id: this.mch_id,
apiv2: this.apiv2,
appid: this.appid
}, {
headers: {
'Auth': this.token
}
}).then(response => {
this.$nextTick(() => {
if (response.status) {
this.$Message.success(response.info);
this.getPayList();
} else {
this.$Message.error(response.info);
}
})
}).catch(error => {
console.error(error, 'error')
})
} else if (this.addPayType == 3) {
this.$http('POST', '/agentnew/ajax_add_alipay', {
company_short_name: this.company_short_name,
alipay_account: this.alipay_account,
is_pay_public: this.isPayPublic,
receive_payment_account: this.receive_payment_account,
receive_payment_name: this.receive_payment_name
}, {
headers: {
'Auth': this.token
}
}).then(response => {
this.$nextTick(() => {
if (response.status) {
if (this.isPayPublic == 1) {
this.$Message.success(response.info);
this.getPayList();
this.receive_payment_account = ''
this.receive_payment_name = ''
} else {
window.open(response.data.authurl, '_blank');
}
} else {
this.$Message.error(response.info);
}
})
}).catch(error => {
console.error(error, 'error')
})
} else if (this.addPayType == 11) {
this.$http('POST', '/agentnew/ajax_add_pddpay', {
shop_name: this.pdd_shop_name,
}, {
headers: {
'Auth': this.token
}
}).then(response => {
this.$nextTick(() => {
if (response.status) {
if (this.isPayPublic == 1) {
this.$Message.success(response.info);
this.getPayList();
this.receive_payment_account = ''
this.receive_payment_name = ''
} else {
window.open(response.data.authurl, '_blank');
}
} else {
this.$Message.error(response.info);
}
})
}).catch(error => {
console.error(error, 'error')
})
}
this.addPayDialogVisible = false;
},
//
@ -445,6 +588,9 @@ export default {
console.log(data, 'data098908090');
},
// ---end
handleClick(tab, event) {
console.log(tab, event);
}
},
};
@ -483,6 +629,15 @@ export default {
color:#FF4D4F !important;
}
.gray {
color:#8A9099 !important;
}
a {
text-decoration: none;
color: #006AFF;
}
.el-table {
min-height: auto !important;
}

Loading…
Cancel
Save