Authored by jiran.zhao

Merge branch 'feature/shop/zjr-demo' of http://git.yoho.cn/fe/yoho-shop-manage into release/6.9.24

... ... @@ -2,7 +2,7 @@
<layout-body>
<div class="detail">
<div class="detail-header">
<p class="bold-title">状态:{{ data.status }}</p>
<p class="bold-title">状态:{{ data.statusDesc }}</p>
<p class="no-title">提现发起后,正常xx-xx工作日到款</p>
</div>
<div class="detail-list">
... ... @@ -59,6 +59,12 @@
<script>
import FinanceService from 'services/finance/finance-service';
const withdrawStatus = {
0: '提现中',
1: '提现成功',
2: '提现失败',
};
export default {
name: 'Detail',
props: ['id'],
... ... @@ -81,6 +87,7 @@ export default {
return this.financeService.shopWithdrawApplyById(this.$route.params).then(result => {
if (result.code === 200) {
this.data = result.data;
this.data.statusDesc = result.data.status ? withdrawStatus[result.data.status] : '';
this.$emit('on-change', this.data);
}
});
... ...
... ... @@ -57,20 +57,20 @@
<div class="select-container">
<Input v-model.trim="filters.orderCode.model" :placeholder="filters.orderCode.label" />
</div>
<div class="select-container">
<Select v-model.trim="filters.clearingType.model" :placeholder="filters.clearingType.label">
<Option v-for="option in filters.clearingType.options" :key="option.value" :value="option.value">{{
option.label
}}</Option>
</Select>
</div>
<div class="select-container">
<Select v-model.trim="filters.subClearingType.model" :placeholder="filters.subClearingType.label">
<Option v-for="option in filters.subClearingType.options" :key="option.value" :value="option.value">{{
option.label
}}</Option>
</Select>
</div>
<!-- <div class="select-container">-->
<!-- <Select v-model.trim="filters.clearingType.model" :placeholder="filters.clearingType.label">-->
<!-- <Option v-for="option in filters.clearingType.options" :key="option.value" :value="option.value">{{-->
<!-- option.label-->
<!-- }}</Option>-->
<!-- </Select>-->
<!-- </div>-->
<!-- <div class="select-container">-->
<!-- <Select v-model.trim="filters.subClearingType.model" :placeholder="filters.subClearingType.label">-->
<!-- <Option v-for="option in filters.subClearingType.options" :key="option.value" :value="option.value">{{-->
<!-- option.label-->
<!-- }}</Option>-->
<!-- </Select>-->
<!-- </div>-->
<div class="select-container">
<Select v-model.trim="filters.withdrawStatus.model" :placeholder="filters.withdrawStatus.label">
<Option v-for="option in filters.withdrawStatus.options" :key="option.value" :value="option.value">{{
... ... @@ -81,7 +81,6 @@
<div class="select-container">
<Button type="primary" @click="search">查询</Button>
<Button type="primary" @click="reset">全部</Button>
<Button>导出</Button>
</div>
</filter-item>
</layout-filter>
... ...
... ... @@ -50,11 +50,11 @@
>
</div>
<div class="select-container">
<Input v-model.trim="filters.sku.model" :placeholder="filters.sku.label" />
<Input v-model.trim="filters.productSku.model" :placeholder="filters.productSku.label" />
</div>
<div class="select-container">
<Select v-model.trim="filters.withdrawStatus.model" :placeholder="filters.withdrawStatus.label">
<Option v-for="option in filters.withdrawStatus.options" :key="option.value" :value="option.value">{{
<Select v-model.trim="filters.status.model" :placeholder="filters.status.label">
<Option v-for="option in filters.status.options" :key="option.value" :value="option.value">{{
option.label
}}</Option>
</Select>
... ... @@ -64,27 +64,27 @@
<div class="select-container">
<Input v-model.trim="filters.targetAccount.model" :placeholder="filters.targetAccount.label" />
</div>
<div class="select-container">
<Select v-model.trim="filters.clearingType.model" :placeholder="filters.clearingType.label">
<Option v-for="option in filters.clearingType.options" :key="option.value" :value="option.value">{{
option.label
}}</Option>
</Select>
</div>
<div class="select-container">
<Select v-model.trim="filters.subClearingType.model" :placeholder="filters.subClearingType.label">
<Option v-for="option in filters.subClearingType.options" :key="option.value" :value="option.value">{{
option.label
}}</Option>
</Select>
</div>
<!-- <div class="select-container">-->
<!-- <Select v-model.trim="filters.clearingType.model" :placeholder="filters.clearingType.label">-->
<!-- <Option v-for="option in filters.clearingType.options" :key="option.value" :value="option.value">{{-->
<!-- option.label-->
<!-- }}</Option>-->
<!-- </Select>-->
<!-- </div>-->
<!-- <div class="select-container">-->
<!-- <Select v-model.trim="filters.subClearingType.model" :placeholder="filters.subClearingType.label">-->
<!-- <Option v-for="option in filters.subClearingType.options" :key="option.value" :value="option.value">{{-->
<!-- option.label-->
<!-- }}</Option>-->
<!-- </Select>-->
<!-- </div>-->
<div class="select-container">
<Input v-model.trim="filters.orderCode.model" :placeholder="filters.orderCode.label" />
</div>
<div class="select-container">
<Button type="primary" @click="search">查询</Button>
<Button type="primary" @click="reset">全部</Button>
<Button>导出</Button>
<!-- <Button>导出</Button>-->
</div>
</filter-item>
</layout-filter>
... ... @@ -127,13 +127,13 @@ export default {
beginTime: 'beginTime',
endTime: 'endTime',
timeFlag: 'timeFlag',
withdrawStatus: 'withdrawStatus',
status: 'status',
orderCode: 'orderCode',
sku: 'sku',
productSku: 'productSku',
targetAccount: 'targetAccount',
clearingType: 'clearingType',
subClearingType: 'subClearingType',
statementSn: 'statementSn',
// statementSn: 'statementSn',
};
if (this.enableFilter) {
... ...
... ... @@ -99,10 +99,10 @@ export default function() {
},
{
title: '结算时间',
key: 'createTime',
key: 'clearingTime',
align: 'center',
render(h, params) {
const time = moment.unix(params.row.createTime);
const time = moment.unix(params.row.clearingTime);
return (
<div>
<div>{time.format('YYYY/MM/DD')}</div>
... ... @@ -125,68 +125,74 @@ export default function() {
},
{
title: '商家实收(元)',
key: 'amount',
key: 'realIncome',
},
{
title: '提现状态',
key: 'status',
align: 'center',
render: (h, params) => {
const row = params.row;
const as = row.status;
const asText = as === 2 ? `${withdrawStatus[row.status]}(${row.rejectReason})` : withdrawStatus[as];
row.lineIndex = params.index;
return <p class={{ 'high-light': as === 2 }}>{asText}</p>;
if (!params.row.status) {
return '';
}
const withdrawStatusText = withdrawStatus[params.row.status] ? withdrawStatus[params.row.status] : '';
return <div>{withdrawStatusText}</div>;
},
className: 'status-column',
},
{
title: '提现申请日期',
key: 'applyTime',
key: 'withdrawTime',
align: 'center',
render(h, params) {
const applyTime = moment.unix(params.row.applyTime);
if (!params.row.withdrawTime) {
return '';
}
const withdrawTime = moment.unix(params.row.withdrawTime);
return (
<div>
<div>{applyTime.format('YYYY/MM/DD')}</div>
<div>{applyTime.format('HH:mm:ss')}</div>
<div>{withdrawTime.format('YYYY/MM/DD')}</div>
<div>{withdrawTime.format('HH:mm:ss')}</div>
</div>
);
},
},
{
title: '提现成功日期',
key: 'applySuccessTime',
key: 'withdrawSuccessTime',
align: 'center',
render(h, params) {
const appSuTime = moment.unix(params.row.applySuccessTime);
if (!params.row.withdrawSuccessTime) {
return '';
}
const withdrawSuccessTime = moment.unix(params.row.withdrawSuccessTime);
return (
<div>
<div>{appSuTime.format('YYYY/MM/DD')}</div>
<div>{appSuTime.format('HH:mm:ss')}</div>
<div>{withdrawSuccessTime.format('YYYY/MM/DD')}</div>
<div>{withdrawSuccessTime.format('HH:mm:ss')}</div>
</div>
);
},
},
{
title: '操作',
key: 'action',
width: 180,
align: 'center',
render: (h, params) => {
const row = params.row;
return (
<div>
<div class="cell-action-row">
<i-button type="primary" size="small" onClick={() => this.getDetailById(row.id)}>
查看明细
</i-button>
</div>
</div>
);
},
className: 'action-column',
},
// {
// title: '操作',
// key: 'action',
// width: 180,
// align: 'center',
// render: (h, params) => {
// const row = params.row;
// return (
// <div>
// <div class="cell-action-row">
// <i-button type="primary" size="small" onClick={() => this.getDetailById(row.id)}>
// 查看明细
// </i-button>
// </div>
// </div>
// );
// },
// className: 'action-column',
// },
],
tableData: [],
pageData: {
... ...
... ... @@ -23,11 +23,11 @@ export default function() {
label: '时间标志',
model: '',
},
sku: {
productSku: {
label: 'SKU',
model: '',
},
withdrawStatus: {
status: {
label: '提现状态',
model: '',
options: [
... ... @@ -100,11 +100,6 @@ export default function() {
align: 'center',
},
{
title: '商家名称',
key: 'supplierName',
align: 'center',
},
{
title: '商家收款账户',
key: 'targetAccount',
align: 'center',
... ... @@ -124,11 +119,11 @@ export default function() {
key: 'productName',
align: 'center',
},
{
title: '业务单据号',
key: 'statementSn',
align: 'center',
},
// {
// title: '业务单据号',
// key: 'statementSn',
// align: 'center',
// },
{
title: '账务类型',
key: 'clearingType',
... ... @@ -149,11 +144,8 @@ export default function() {
key: 'status',
align: 'center',
render: (h, params) => {
const row = params.row;
const as = row.status;
const asText = as === 2 ? `${withdrawStatus[row.status]}(${row.rejectReason})` : withdrawStatus[as];
row.lineIndex = params.index;
return <p class={{ 'high-light': as === 2 }}>{asText}</p>;
const withdrawStatusText = withdrawStatus[params.row.status] ? withdrawStatus[params.row.status] : '';
return <div>{withdrawStatusText}</div>;
},
className: 'status-column',
},
... ...
... ... @@ -24,7 +24,7 @@ export default function() {
label: '时间标志',
model: '',
},
withdrawStatus: {
status: {
label: '提现状态',
model: '',
options: [
... ... @@ -50,7 +50,7 @@ export default function() {
label: '订单号',
model: '',
},
sku: {
productSku: {
label: 'SKU',
model: '',
},
... ... @@ -113,37 +113,62 @@ export default function() {
{
title: '订单号',
key: 'orderCode',
align: 'center',
},
{
title: 'SKU',
key: 'productSku',
align: 'center',
},
{
title: '商品名称',
key: 'productName',
align: 'center',
},
{
title: '账务类型',
key: 'clearingType',
align: 'center',
},
{
title: '子账务类型',
key: 'subClearingTypes',
key: '',
align: 'center',
render: (h, params) => {
return (
<span class="table-header-req">
<poptip trigger="hover" placement="right-start">
<a>全部</a>
<div class="example-pop" slot="content">
<p>成交金额:{params.row.subShopAccount.lastPrice}</p>
<p>交易服务费:{params.row.subShopAccount.tradeServiceAmount}</p>
<p>优惠券结算:{params.row.subShopAccount.couponAmount}</p>
<p>红包结算:{params.row.subShopAccount.redPackageAmount}</p>
<p>VIP折扣:{params.row.subShopAccount.vipAmount}</p>
<p>交易实收:{params.row.subShopAccount.tradeRealIncome}</p>
<p>提现服务费:{params.row.subShopAccount.withdrawServiceAmount}</p>
<p>商家实收:{params.row.subShopAccount.shopRealIncome}</p>
</div>
</poptip>
</span>
);
},
},
{
title: '商家实收(元)',
key: 'amount',
align: 'center',
},
{
title: '提现状态',
key: 'status',
align: 'center',
render: (h, params) => {
const row = params.row;
const as = row.status;
const asText = as === 2 ? `${withdrawStatus[row.status]}(${row.rejectReason})` : withdrawStatus[as];
row.lineIndex = params.index;
return <p class={{ 'high-light': as === 2 }}>{asText}</p>;
if (!params.row.status) {
return '';
}
const withdrawStatusText = withdrawStatus[params.row.status] ? withdrawStatus[params.row.status] : '';
return <div>{withdrawStatusText}</div>;
},
className: 'status-column',
},
... ... @@ -152,6 +177,9 @@ export default function() {
key: 'applyTime',
align: 'center',
render(h, params) {
if (!params.row.applyTime) {
return '';
}
const applyTime = moment.unix(params.row.applyTime);
return (
<div>
... ... @@ -163,10 +191,13 @@ export default function() {
},
{
title: '提现成功日期',
key: 'applySuccessTime',
key: 'successTime',
align: 'center',
render(h, params) {
const appSuTime = moment.unix(params.row.applySuccessTime);
if (!params.row.successTime) {
return '';
}
const appSuTime = moment.unix(params.row.successTime);
return (
<div>
<div>{appSuTime.format('YYYY/MM/DD')}</div>
... ... @@ -175,25 +206,25 @@ export default function() {
);
},
},
{
title: '操作',
key: 'action',
width: 180,
align: 'center',
render: (h, params) => {
const row = params.row;
return (
<div>
<div class="cell-action-row">
<i-button type="primary" size="small" onClick={() => this.getDetailById(row.id)}>
查看明细
</i-button>
</div>
</div>
);
},
className: 'action-column',
},
// {
// title: '操作',
// key: 'action',
// width: 180,
// align: 'center',
// render: (h, params) => {
// const row = params.row;
// return (
// <div>
// <div class="cell-action-row">
// <i-button type="primary" size="small" onClick={() => this.getDetailById(row.id)}>
// 查看明细
// </i-button>
// </div>
// </div>
// );
// },
// className: 'action-column',
// },
],
tableData: [],
pageData: {
... ...
export default function() {
return {
form: '',
showLoading: true,
data: {
seasons: '',
productIntro: '',
applyType: 0,
},
beginStr: '',
endStr: '',
beginTimeStr: '',
endTimeStr: '',
ruleValidate: {
productName: [{ required: true, message: '商品名不能为空', trigger: 'blur' }],
},
apply: {
shopId: '',
applyPid: '',
applyAmount: '',
applyType: 0,
beginTime: '',
endTime: '',
applyPhone: '15210803601',
targetAccount: '',
token: '',
timestamp: '',
salt: 'fd4ad5fcsa0de589af23234ks1923ks',
},
};
}
... ...
... ... @@ -63,6 +63,9 @@ export default function() {
key: 'createTime',
align: 'center',
render(h, params) {
if (!params.row.createTime) {
return '';
}
const time = moment.unix(params.row.createTime);
return (
<div>
... ... @@ -89,17 +92,19 @@ export default function() {
},
{
title: '成功金额(元)',
key: 'successAmount',
align: 'center',
},
{
title: '提现状态',
key: 'status',
align: 'center',
render: (h, params) => {
const row = params.row;
const as = row.status;
const asText = as === 2 ? `${withdrawStatus[row.status]}(${row.rejectReason})` : withdrawStatus[as];
row.lineIndex = params.index;
return <p class={{ 'high-light': as === 2 }}>{asText}</p>;
if (!params.row.status) {
return '';
}
const withdrawStatusText = withdrawStatus[params.row.status] ? withdrawStatus[params.row.status] : '';
return <div>{withdrawStatusText}</div>;
},
className: 'status-column',
},
... ... @@ -109,7 +114,7 @@ export default function() {
},
{
title: '操作人',
key: 'applyPid',
key: 'applyAccount',
align: 'center',
},
{
... ...
... ... @@ -50,8 +50,8 @@
>
</div>
<div class="select-container">
<Select v-model.trim="filters.withdrawStatus.model" :placeholder="filters.withdrawStatus.label">
<Option v-for="option in filters.withdrawStatus.options" :key="option.value" :value="option.value">{{
<Select v-model.trim="filters.status.model" :placeholder="filters.status.label">
<Option v-for="option in filters.status.options" :key="option.value" :value="option.value">{{
option.label
}}</Option>
</Select>
... ... @@ -65,29 +65,28 @@
<Input v-model.trim="filters.orderCode.model" :placeholder="filters.orderCode.label" />
</div>
<div class="select-container">
<Input v-model.trim="filters.sku.model" :placeholder="filters.sku.label" />
<Input v-model.trim="filters.productSku.model" :placeholder="filters.productSku.label" />
</div>
<div class="select-container">
<Input v-model.trim="filters.productName.model" :placeholder="filters.productName.label" />
</div>
<div class="select-container">
<Select v-model.trim="filters.clearingType.model" :placeholder="filters.clearingType.label">
<Option v-for="option in filters.clearingType.options" :key="option.value" :value="option.value">{{
option.label
}}</Option>
</Select>
</div>
<div class="select-container">
<Select v-model.trim="filters.subClearingType.model" :placeholder="filters.subClearingType.label">
<Option v-for="option in filters.subClearingType.options" :key="option.value" :value="option.value">{{
option.label
}}</Option>
</Select>
</div>
<!-- <div class="select-container">-->
<!-- <Select v-model.trim="filters.clearingType.model" :placeholder="filters.clearingType.label">-->
<!-- <Option v-for="option in filters.clearingType.options" :key="option.value" :value="option.value">{{-->
<!-- option.label-->
<!-- }}</Option>-->
<!-- </Select>-->
<!-- </div>-->
<!-- <div class="select-container">-->
<!-- <Select v-model.trim="filters.subClearingType.model" :placeholder="filters.subClearingType.label">-->
<!-- <Option v-for="option in filters.subClearingType.options" :key="option.value" :value="option.value">{{-->
<!-- option.label-->
<!-- }}</Option>-->
<!-- </Select>-->
<!-- </div>-->
<div class="select-container">
<Button type="primary" @click="search">查询</Button>
<Button type="primary" @click="reset">全部</Button>
<Button>导出</Button>
</div>
</filter-item>
</layout-filter>
... ... @@ -135,6 +134,11 @@ export default {
return `支出`;
},
},
watch: {
$route() {
this.setActiveTab();
},
},
created() {
this.financeService = new FinanceService();
this.setActiveTab();
... ... @@ -150,10 +154,10 @@ export default {
beginTime: 'beginTime',
endTime: 'endTime',
timeFlag: 'timeFlag',
withdrawStatus: 'withdrawStatus',
status: 'status',
targetAccount: 'targetAccount',
orderCode: 'orderCode',
sku: 'sku',
productSku: 'productSku',
productName: 'productName',
clearingType: 'clearingType',
subClearingType: 'subClearingType',
... ... @@ -224,7 +228,7 @@ export default {
this.financeService.shopWithdrawAccountList(params).then(ret => {
this.tableData = _.get(ret, 'data.records', []);
this.pageData.total = _.get(ret, 'data.totalCount', 0);
this.pageData.current = _.get(ret, 'data.pageNo', 0) + 1;
this.pageData.current = _.get(ret, 'data.pageNo', 1);
});
},
getDetailById(id) {
... ...
<template>
<layout-body>
<Form ref="withdraw" :model="data" class="detail" :label-width="100" :rules="ruleValidate">
<Form v-if="showLoading" ref="withdraw" :model="data" class="detail" :label-width="100" :rules="ruleValidate">
<Form-item label="店铺名称">
<span>{{ data.shopName }}</span>
</Form-item>
... ... @@ -10,21 +10,16 @@
<span class="red">*支付宝每日转账最高限额10万元人民币,单日超过10万人民币限额的,请联系平台客服</span>
</Form-item>
<Form-item label="提现方式">
<span>最大可提现</span><span>{{ formatDate(data.billBeginTime) }}</span>
<span>最大可提现</span><span>{{ beginTimeStr }}</span>
~
<span>{{ formatDate(data.billEndTime) }}</span>
<span>{{ endTimeStr }}</span>
<br />
<span>请选择账单日期</span>
<Date-picker
:value="data.range"
type="datetimerange"
format="yyyy-MM-dd"
placeholder="选择日期时间"
@on-change="clickAvailableDate"
/>
<Date-picker v-model="beginStr" type="date" placeholder="选择日期时间" @on-change="changeBeginStr" />
<Date-picker v-model="endStr" type="date" placeholder="选择日期时间" @on-change="changeEndStr" />
</Form-item>
<Form-item label="提现金额">
<input :value="data.availableAmount" placeholder="请输入..." />
<input v-model="data.withdrawAmount" disabled placeholder="请选择日期时间" />
</Form-item>
<Form-item label="提现到帐号">
<span>{{ data.withdrawAccount }}</span>
... ... @@ -37,16 +32,16 @@
</Form-item>
<Form-item>
<Button id="btnSubmit" type="primary" size="large" @click="save">确认提现</Button>
<Button type="primary" size="large">联系客服</Button>
<Button id="cancel" type="primary" size="large">联系客服</Button>
<Button id="cancel" type="primary" size="large" @click="backList">取消</Button>
</Form-item>
</Form>
<Spin v-else-if="showLoading" size="large" fix></Spin>
</layout-body>
</template>
<script>
import _ from 'lodash';
import moment from 'moment';
import crypto from 'util/crypto';
import FinanceService from 'services/finance/finance-service';
import { WithdrawApply } from './store';
... ... @@ -60,15 +55,26 @@ export default {
timestamps: Math.round(new Date().getTime() / 1000),
};
this.financeService = new FinanceService();
this.financeService.shopWithdrawApplyInit(params).then(result => {
if (result.code === 200) {
Object.assign(this.data, result.data);
}
});
},
mounted() {
this.getInfo();
this.financeService
.shopWithdrawApplyInit(params)
.then(result => {
if (result.code === 200) {
this.data = result.data;
this.beginStr = this.formatDate(result.data.billBeginTime);
this.endStr = this.formatDate(result.data.billEndTime);
this.beginTimeStr = this.formatDate(result.data.billBeginTime);
this.endTimeStr = this.formatDate(result.data.billEndTime);
this.data.beginTime = result.data.billBeginTime;
this.data.endTime = result.data.billEndTime;
this.data.withdrawAmount = result.data.withdrawAmount ? result.data.withdrawAmount : 0;
}
})
.catch(() => {
this.$Message.error('请求出错');
this.showLoading = false;
});
},
mounted() {},
methods: {
backList() {
this.$router.push({ name: 'finance.withdraw.withdrawlist' });
... ... @@ -93,30 +99,36 @@ export default {
});
},
beforeSave() {
const newApply = {};
newApply.availableAmount = this.data.availableAmount;
newApply.applyType = this.data.applyType;
newApply.beginTime = this.data.beginTime;
newApply.endTime = this.data.endTime;
newApply.applyAmount = this.data.applyAmount;
newApply.targetAccount = this.data.targetAccount;
newApply.remarks = this.data.remarks;
newApply.timestamp = this.data.timestamp;
newApply.token = this.data.token;
newApply.sign = this.data.sign;
return newApply;
const params = {};
params.shopId = this.$user.currentShop.shopsId;
params.applyPid = this.$user.pid;
params.applyAmount = this.data.withdrawAmount ? this.data.withdrawAmount : 0;
params.applyType = this.apply.applyType;
params.beginTime = this.data.beginTime;
params.endTime = this.data.endTime;
params.applyPhone = this.apply.applyPhone;
params.targetAccount = this.data.withdrawAccount;
params.token = this.$user.token;
params.timestamp = Math.round(new Date().getTime() / 1000);
params.salt = this.apply.salt;
const arrParams = Object.keys(params).map(key => {
return params[key];
});
params.sign = crypto.md5(arrParams.join('|'));
params.account = this.$user.name;
return params;
},
save() {
const newApply = this.beforeSave();
const applyParams = this.beforeSave();
this.$Loading.start();
return this.financeService.shopWithdrawApply(newApply).then(result => {
return this.financeService.shopWithdrawApply(applyParams).then(result => {
if (result.code === 200) {
this.$Loading.finish();
this.$Notice.success({
title: '提交成功',
desc: '确认提现成功!',
});
this.go(this.from);
this.backList();
} else {
this.$Loading.error();
this.$Notice.error({
... ... @@ -147,38 +159,14 @@ export default {
return moment.unix(date).format('YYYY-MM-DD');
}
},
clickAvailableDate(time) {
if (!_.isArray(time)) {
time = time.split(' - ');
}
if ((time[0] + '').length) {
const billBeginStr = moment.unix(this.data.billBeginTime).format('YYYY-MM-DD');
const billEndStr = moment.unix(this.data.billEndTime).format('YYYY-MM-DD');
if (time[0] < billBeginStr || time[1] > billEndStr) {
this.data.beginTime = '';
this.data.endTime = '';
this.$Notice.error({
title: '时间选择错误',
desc: '请选择范围内时间',
});
}
this.data.beginTime = time[0];
this.data.endTime = time[1];
this.getAvailableAmount();
} else {
this.data.beginTime = '';
this.data.endTime = '';
}
},
getAvailableAmount() {
const params = {};
params.beginTime = this.data.beginTime;
params.endTime = this.data.endTime;
params.beginTime = this.beginStr;
params.endTime = this.endStr;
this.financeService.shopGetAvailableAmount(params).then(result => {
if (result.code === 200) {
this.data.availableAmount = result.availableAmount;
this.data.withdrawAmount = result.data.availableAmount;
} else {
this.$Loading.error();
this.$Notice.error({
title: '查询错误',
desc: result.message,
... ... @@ -186,6 +174,13 @@ export default {
}
});
},
changeBeginStr(value) {
this.beginStr = value;
},
changeEndStr(value) {
this.endStr = value;
this.getAvailableAmount();
},
},
};
</script>
... ...
... ... @@ -67,7 +67,7 @@
<div class="select-container">
<Button type="primary" @click="search">查询</Button>
<Button type="primary" @click="reset">全部</Button>
<Button>导出</Button>
<!-- <Button>导出</Button>-->
</div>
</filter-item>
</layout-filter>
... ...
... ... @@ -134,7 +134,7 @@ class FinanceService extends Service {
* @returns {Promise<unknown>}
*/
shopGetAvailableAmount(params) {
return this.post(apiUrl.shopWithdrawApply, params);
return this.post(apiUrl.shopGetAvailableAmount, params);
}
/**
... ...
... ... @@ -203,7 +203,7 @@ const domains = {
/* erp: 'http://192.168.103.82:9098',
platform: 'http://192.168.102.202:8088/platform',
shop: 'http://192.168.102.211:30016'*/
erp: 'http://192.168.102.47:9098',
erp: 'http://192.168.103.48:9098',
platform: 'http://java-yoho-platform.test3.ingress.dev.yohocorp.com/platform',
shop: 'http://192.168.102.211:30016',
};
... ...
... ... @@ -65,6 +65,7 @@ class UserController extends Context {
pwdComplexRateDesc: user.pwdComplexRateDesc,
needUpdate,
token: user.token,
pid: user.pid,
},
});
});
... ...