Browse Source

更新

master
j1ack 2 years ago
parent
commit
8e755a2e8e
  1. BIN
      bitcopay后台-开发环境.zip
  2. 82
      src/api/form.js
  3. 205
      src/views/otc/otcStore/index.vue

BIN
bitcopay后台-开发环境.zip

Binary file not shown.

82
src/api/form.js

@ -92,6 +92,14 @@ export const payMerchant = {
method: 'get', method: 'get',
}) })
}, },
// 申请提现
addTransferOrder(params) {
return request({
url: "/merchant/merchant/addTransferOrder",
method: "post",
params: params,
})
},
// 获取商户MD5 // 获取商户MD5
getmd5Key: (id) => { getmd5Key: (id) => {
return request({ return request({
@ -228,43 +236,43 @@ export const payRecordRecharge = {
/** /**
* 财务流水 * 财务流水
*/ */
export const merchantWalletLog = { export const merchantWalletLog = {
// 查询财务流水列表 // 查询财务流水列表
listInfo: (query) => { listInfo: (query) => {
return request({ return request({
url: '/merchant/MerchantWalletLog/list', url: '/merchant/MerchantWalletLog/list',
method: 'get', method: 'get',
params: query, params: query,
}) })
}, },
// 导出财务流水 // 导出财务流水
exportList: (query) => { exportList: (query) => {
return request({ return request({
url: '/merchant/MerchantWalletLog/export', url: '/merchant/MerchantWalletLog/export',
method: 'get', method: 'get',
params: query, params: query,
}) })
}, },
} }
/** /**
* 商户代付订单管理 * 商户代付订单管理
*/ */
export const paymentDaiFuRecord = { export const paymentDaiFuRecord = {
// 查询商户代付订单管理 // 查询商户代付订单管理
listInfo: (query) => { listInfo: (query) => {
return request({ return request({
url: '/order/PaymentRecord/list', url: '/order/PaymentRecord/list',
method: 'get', method: 'get',
params: query, params: query,
}) })
}, },
// 导出商户代付订单管理 // 导出商户代付订单管理
exportList: (query) => { exportList: (query) => {
return request({ return request({
url: '/order/PaymentRecord/export', url: '/order/PaymentRecord/export',
method: 'get', method: 'get',
params: query, params: query,
}) })
}, },
} }

205
src/views/otc/otcStore/index.vue

@ -34,22 +34,16 @@
<el-table stripe :data="infoList" v-loading="loading"> <el-table stripe :data="infoList" v-loading="loading">
<el-table-column label="商户名称" align="center" prop="username" /> <el-table-column label="商户名称" align="center" prop="username" />
<el-table-column label="商户编号" align="center" prop="merchantNo" /> <el-table-column label="商户编号" align="center" prop="merchantNo" />
<el-table-column :label="'余额'" align="center" prop="balance"> <el-table-column :label="'余额'" align="center" prop="balance">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.balance }} {{ scope.row.balance }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="'冻结金额'" align="center" prop="frozenAmount"> <el-table-column :label="'冻结金额'" align="center" prop="frozenAmount">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.frozenAmount }} {{ scope.row.frozenAmount }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="状态" align="center" prop="status" width="140px"> <el-table-column label="状态" align="center" prop="status" width="140px">
<template slot-scope="scope"> <template slot-scope="scope">
<el-switch v-model="scope.row.status" active-text="" inactive-text="" :active-value="1" <el-switch v-model="scope.row.status" active-text="" inactive-text="" :active-value="1"
@ -57,8 +51,6 @@
</el-switch> </el-switch>
</template> </template>
</el-table-column> </el-table-column>
<!-- <el-table-column label="手动提单审核开关" align="center" prop="whetherReview" width="140px"> <!-- <el-table-column label="手动提单审核开关" align="center" prop="whetherReview" width="140px">
<template slot-scope="scope"> <template slot-scope="scope">
<el-switch v-model="scope.row.whetherReview" active-text="" inactive-text="" active-value="Y" <el-switch v-model="scope.row.whetherReview" active-text="" inactive-text="" active-value="Y"
@ -85,7 +77,8 @@
style="color: #006eff">商户删除</el-button> style="color: #006eff">商户删除</el-button>
<!-- <el-button size="small" type="text" @click="handleView(scope.row)" style="color: #006eff" <!-- <el-button size="small" type="text" @click="handleView(scope.row)" style="color: #006eff"
v-hasPermi="['system:merchantChannel:getChannel']">通道</el-button> --> v-hasPermi="['system:merchantChannel:getChannel']">通道</el-button> -->
<!-- <el-button size="small" type="text" @click="handleWithdraw(scope.row)" style="color: #006eff">提现</el-button> --> <el-button size="small" type="text" @click="handleWithdraw(scope.row)"
style="color: #006eff">提现</el-button>
<el-button size="small" type="text" @click="handlePassword(scope.row, 'loginPassword')" <el-button size="small" type="text" @click="handlePassword(scope.row, 'loginPassword')"
style="color: #006eff">登录密码</el-button> style="color: #006eff">登录密码</el-button>
<el-button size="small" type="text" @click="handlePassword(scope.row, 'payPassword')" <el-button size="small" type="text" @click="handlePassword(scope.row, 'payPassword')"
@ -102,6 +95,7 @@
<el-button size="small" type="text" @click="handleUpdateRate(scope.row)" <el-button size="small" type="text" @click="handleUpdateRate(scope.row)"
style="color: #006eff">费率</el-button> style="color: #006eff">费率</el-button>
<el-button size="small" type="text" @click="handleAdd(scope.row, 'next')" <el-button size="small" type="text" @click="handleAdd(scope.row, 'next')"
style="color: #006eff">添加下级</el-button> style="color: #006eff">添加下级</el-button>
@ -250,34 +244,49 @@
</el-dialog> </el-dialog>
<!-- 提现 --> <!-- 提现 -->
<!-- <el-dialog :title="title" :visible.sync="openWithdraw" width="500px" append-to-body> <el-dialog :title="title" :visible.sync="openWithdraw" width="800px" append-to-body>
<el-form ref="formWithdraw" :model="form" :rules="rules" label-width="140px"> <el-form ref="formWithdraw" :model="form" :rules="rules" label-width="140px">
<el-form-item label="规则" prop="rateRuleType"> <el-form-item label="类型" prop="type">
<el-select v-model="form.rateRuleType" placeholder="请选择规则" clearable size="medium" @change="getValue"> <el-select v-model="form.type" placeholder="请选择类型" clearable @change="getValue">
<el-option v-for="(item, i) in withdrawRule" :key="i" :label="item.label" :value="item.value"></el-option> <el-option v-for="dict in withdrawRule" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select> </el-select>
</el-form-item>
<el-form-item label="单笔提款比例" prop="rate">
<el-input v-model="form.rate" placeholder="请输入单笔提款比例" style="width:300px" @input="change" :disabled="true" /> %
</el-form-item>
<el-form-item label="单笔提款收取" prop="singleFee">
<el-input v-model="form.singleFee" placeholder="请输入单笔提款收取" style="width:300px" @input="change"
:disabled="true" />
</el-form-item>
<el-form-item label="是否允许后台提现" prop="paymentManualStatus">
<el-switch v-model="form.paymentManualStatus" active-text="" inactive-text="" :active-value=true
:inactive-value=false></el-switch>
</el-form-item> </el-form-item>
<el-form-item label="是否API代付" prop="paymentInterfaceStatus"> <el-form-item label="卡号" prop="cardNumber">
<el-switch v-model="form.paymentInterfaceStatus" active-text="" inactive-text="" :active-value=true <el-input v-model="form.cardNumber" placeholder="请输入卡号" />
:inactive-value=false></el-switch> </el-form-item>
<el-form-item label="姓名" prop="accountName">
<el-input v-model="form.accountName" placeholder="请输入姓名" />
</el-form-item>
<el-form-item label="银行" prop="bankName">
<el-input v-model="form.bankName" placeholder="请输入银行" />
</el-form-item>
<el-form-item label="支行" prop="branchName">
<el-input v-model="form.branchName" placeholder="请输入支行" />
</el-form-item>
<div v-if="withdrawType == 'coin'">
<el-form-item label="地址" prop="address">
<el-input v-model="form.address" placeholder="请输入地址" />
</el-form-item>
</div>
<el-form-item label="提现金额" prop="reqAmount">
<el-input v-model="form.reqAmount" placeholder="请输入提现金额" type="number" />
<span style="display: block;">可用余额 CNY: {{ balance }}</span>
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" placeholder="请输入备注" />
</el-form-item>
<el-form-item label="支付密码" prop="payPwd">
<el-input v-model="form.payPwd" placeholder="请输入支付密码" type="password" />
</el-form-item>
<el-form-item label="谷歌验证码" prop="googleCode">
<el-input v-model="form.googleCode" placeholder="请输入谷歌验证码" type="password" />
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm('formWithdraw')"> </el-button> <el-button type="primary" @click="submitForm('formWithdraw')"> </el-button>
<el-button @click="cancel"> </el-button> <el-button @click="cancel"> </el-button>
</div> </div>
</el-dialog> --> </el-dialog>
<!-- 风控 --> <!-- 风控 -->
<el-dialog :title="title" :visible.sync="openControl" width="800px" append-to-body> <el-dialog :title="title" :visible.sync="openControl" width="800px" append-to-body>
@ -413,9 +422,23 @@ export default {
} }
}; };
return { return {
//
balance: null,
withdrawType: '',
pkCouponScopeRangeParkingStoreOpen: false, pkCouponScopeRangeParkingStoreOpen: false,
pkCouponStore: {}, pkCouponStore: {},
pkCouponStoreId: '', pkCouponStoreId: '',
//
withdrawRule: [
{
label: 'cny',
value: 'cny'
},
{
label: 'coin',
value: 'coin'
}
],
// //
type: [ type: [
{ {
@ -470,7 +493,9 @@ export default {
// //
detailData: {}, detailData: {},
// //
form: {}, form: {
},
// //
rules: { rules: {
whetherReviewApi: [{ required: true, message: "请选择是否api提单审核", trigger: "blur" }], whetherReviewApi: [{ required: true, message: "请选择是否api提单审核", trigger: "blur" }],
@ -506,6 +531,52 @@ export default {
password: [ password: [
{ required: true, message: "密码不能为空", trigger: "blur" }, { required: true, message: "密码不能为空", trigger: "blur" },
], ],
accountName: [
{ required: true, message: "姓名不能为空", trigger: "blur" }
],
cardNumber: [
{ required: true, message: "卡号不能为空", trigger: "blur" }
],
address: [
{ required: true, message: "地址不能为空", trigger: "blur" }
],
branchName: [
],
type: [
{ required: true, message: "类型不能为空", trigger: "blur" }
],
bankName: [
{ required: true, message: "银行不能为空", trigger: "blur" }
],
reqAmount: [
{ required: true, message: "提现金额不能为空", trigger: "blur" },
{
validator: (rule, value, callback) => {
if (value <= 0) {
callback(new Error("提现金额必须大于 0"));
} else {
callback();
}
}, trigger: "blur"
},
{
validator: (rule, value, callback) => {
if (value > (this.balance / 100)) {
callback(new Error("提现金额不能大于可用余额"));
} else {
callback();
}
}, trigger: "blur"
},
],
remark: [
],
payPwd: [
{ required: true, message: "支付密码不能为空", trigger: "blur" }
],
googleCode: [
{ required: true, message: "谷歌验证码不能为空", trigger: "blur" }
],
}, },
}; };
}, },
@ -559,21 +630,10 @@ export default {
change() { change() {
this.$forceUpdate() this.$forceUpdate()
}, },
// getValue(e) { //
// payMerchant.getWithdrawConfig(this.id).then((response) => { getValue(e) {
// if (e == 2) { this.withdrawType = e
// this.form.id = response.data.id },
// this.form.merchantId = response.data.merchantId
// this.form.singleFee = response.data.sysMerchantWithdrawConfig.singleFee
// this.form.rate = response.data.sysMerchantWithdrawConfig.rate
// } else {
// this.form.merchantId = response.data.merchantId
// this.form.singleFee = response.data.singleFee
// this.form.rate = response.data.rate
// }
// });
// this.$forceUpdate()
// },
// //
switchStatusChange(row, type) { switchStatusChange(row, type) {
this.reset() this.reset()
@ -644,25 +704,15 @@ export default {
t == 'next' ? this.form.parentId = row.id : '' t == 'next' ? this.form.parentId = row.id : ''
}, },
// //
// handleWithdraw(row) { handleWithdraw(row) {
// this.reset(); this.reset();
// this.id = row.id this.id = row.id
// payMerchant.getWithdrawConfig(this.id).then((response) => { this.form.merchantId = row.id
// this.form = response.data; this.form.type='cny'
// // this.balance = row.balance
// // if (this.form.rateRuleType == 2) { this.title = "提现";
// // this.form = response.data.sysMerchantWithdrawConfig this.openWithdraw = true;
// // this.form.rateRuleType = response.data.rateRuleType },
// // this.form.id = response.data.id
// // this.form.merchantId = response.data.merchantId
// // }
// // if (this.form.id == 0) {
// // this.form.id = null
// // }
// this.title = "";
// this.openWithdraw = true;
// });
// },
// //
handlePassword(row, type) { handlePassword(row, type) {
this.reset(); this.reset();
@ -695,7 +745,6 @@ export default {
this.id = row.id; this.id = row.id;
payMerchant.getmd5Key(this.id).then((response) => { payMerchant.getmd5Key(this.id).then((response) => {
this.form.md5Key = response.data.md5Key; this.form.md5Key = response.data.md5Key;
// console.log(this.form)
// this.title = "MD5"; // this.title = "MD5";
// this.openMd5 = true; // this.openMd5 = true;
}); });
@ -822,25 +871,13 @@ export default {
}); });
} }
// //
// if (type == "formWithdraw") { if (type == "formWithdraw") {
// let singleFee; payMerchant.addTransferOrder(this.form).then((response) => {
// if (this.form.singleFee) { this.msgSuccess("操作成功");
// singleFee = this.NumberMul(this.form.singleFee, 100) this.openWithdraw = false;
// } this.getList();
// payMerchant.upWithdrawConfig({ });
// id: this.form.id, }
// singleFee: singleFee,
// merchantId: this.form.merchantId,
// rate: this.form.rate,
// rateRuleType: this.form.rateRuleType,
// paymentManualStatus: this.form.paymentManualStatus,
// paymentInterfaceStatus: this.form.paymentInterfaceStatus
// }).then((response) => {
// this.msgSuccess("");
// this.openWithdraw = false;
// this.getList();
// });
// }
// //
if (type == "formPassword") { if (type == "formPassword") {
if (this.ipType == "loginPassword") { if (this.ipType == "loginPassword") {

Loading…
Cancel
Save