|
@@ -1,462 +1,412 @@
|
|
|
<template>
|
|
|
- <div>
|
|
|
- <Card :bordered="false" dis-hover class="ivu-mb-16">
|
|
|
- <Form
|
|
|
- ref="formValidate"
|
|
|
- :model="formValidate"
|
|
|
- :label-width="labelWidth"
|
|
|
- :label-position="labelPosition"
|
|
|
- class="tabform"
|
|
|
- @submit.native.prevent
|
|
|
- >
|
|
|
- <Row :gutter="24" type="flex">
|
|
|
- <Col span="24">
|
|
|
- <FormItem label="时间选择:">
|
|
|
- <RadioGroup
|
|
|
- v-model="formValidate.data"
|
|
|
- type="button"
|
|
|
- @on-change="selectChange(formValidate.data)"
|
|
|
- class="mr"
|
|
|
- >
|
|
|
- <Radio :label="item.val" v-for="(item, i) in fromList.fromTxt" :key="i">{{ item.text }}</Radio>
|
|
|
- </RadioGroup>
|
|
|
- <DatePicker
|
|
|
- :editable="false"
|
|
|
- @on-change="onchangeTime"
|
|
|
- :value="timeVal"
|
|
|
- format="yyyy/MM/dd"
|
|
|
- type="daterange"
|
|
|
- placement="bottom-end"
|
|
|
- placeholder="请选择时间"
|
|
|
- style="width: 200px"
|
|
|
- ></DatePicker>
|
|
|
- </FormItem>
|
|
|
- </Col>
|
|
|
- <Col span="24">
|
|
|
- <FormItem label="提现状态:">
|
|
|
- <RadioGroup type="button" v-model="formValidate.status" class="mr15" @on-change="selChange">
|
|
|
- <Radio :label="itemn.value" v-for="(itemn, indexn) in treeData.withdrawal" :key="indexn">{{
|
|
|
- itemn.title
|
|
|
- }}</Radio>
|
|
|
- </RadioGroup>
|
|
|
- </FormItem>
|
|
|
- </Col>
|
|
|
- <Col span="24">
|
|
|
- <FormItem label="提现方式:">
|
|
|
- <RadioGroup type="button" v-model="formValidate.extract_type" class="mr15" @on-change="selChange">
|
|
|
- <Radio :label="itemn.value" v-for="(itemn, indexn) in treeData.payment" :key="indexn">{{
|
|
|
- itemn.title
|
|
|
- }}</Radio>
|
|
|
- </RadioGroup>
|
|
|
- </FormItem>
|
|
|
- </Col>
|
|
|
- <Col span="24">
|
|
|
- <FormItem label="搜索:">
|
|
|
- <div class="acea-row row-middle">
|
|
|
- <Input
|
|
|
- search
|
|
|
- enter-button
|
|
|
- @on-search="selChange"
|
|
|
- placeholder="微信昵称/姓名/支付宝账号/银行卡号"
|
|
|
- element-id="name"
|
|
|
- v-model="formValidate.nireid"
|
|
|
- style="width: 30%"
|
|
|
- />
|
|
|
- <router-link :to="$routeProStr + '/finance/finance/commission'" class="ml20">佣金记录</router-link>
|
|
|
- </div>
|
|
|
- </FormItem>
|
|
|
- </Col>
|
|
|
- </Row>
|
|
|
- </Form>
|
|
|
- </Card>
|
|
|
- <cards-data :cardLists="cardLists" v-if="extractStatistics"></cards-data>
|
|
|
- <Card :bordered="false" dis-hover>
|
|
|
- <Table
|
|
|
- ref="table"
|
|
|
- :columns="columns"
|
|
|
- :data="tabList"
|
|
|
- class="ivu-mt"
|
|
|
- :loading="loading"
|
|
|
- no-data-text="暂无数据"
|
|
|
- no-filtered-data-text="暂无筛选结果"
|
|
|
- >
|
|
|
- <template slot-scope="{ row }" slot="nickname">
|
|
|
- <div>
|
|
|
- 用户昵称: {{ row.nickname }} <br />
|
|
|
- 用户id:{{ row.uid }}
|
|
|
- </div>
|
|
|
- </template>
|
|
|
- <template slot-scope="{ row }" slot="extract_price">
|
|
|
- <div>{{ row.extract_price }}</div>
|
|
|
- </template>
|
|
|
- <template slot-scope="{ row, index }" slot="add_time">
|
|
|
- <span> {{ row.add_time | formatDate }}</span>
|
|
|
- </template>
|
|
|
- <template slot-scope="{ row }" slot="extract_type">
|
|
|
- <div class="type" v-if="row.extract_type === 'bank'">
|
|
|
- <div class="item">姓名:{{ row.real_name }}</div>
|
|
|
- <div class="item">银行卡号:{{ row.bank_code }}</div>
|
|
|
- <div class="item">银行开户地址:{{ row.bank_address }}</div>
|
|
|
- </div>
|
|
|
- <div class="type" v-if="row.extract_type === 'weixin'">
|
|
|
- <div class="item">昵称:{{ row.nickname }}</div>
|
|
|
- <div class="item">微信号:{{ row.wechat }}</div>
|
|
|
- </div>
|
|
|
- <div class="type" v-if="row.extract_type === 'alipay'">
|
|
|
- <div class="item">姓名:{{ row.real_name }}</div>
|
|
|
- <div class="item">支付宝号:{{ row.alipay_code }}</div>
|
|
|
- </div>
|
|
|
- <div class="type" v-if="row.extract_type === 'balance'">
|
|
|
- <div class="item">姓名:{{ row.real_name }}</div>
|
|
|
- <div class="item">提现方式:佣金转入余额</div>
|
|
|
- </div>
|
|
|
- </template>
|
|
|
- <template slot-scope="{ row, index }" slot="qrcode_url">
|
|
|
- <div class="tabBox_img" v-viewer v-if="row.extract_type === 'weixin' || row.extract_type === 'alipay'">
|
|
|
- <img v-lazy="row.qrcode_url" />
|
|
|
- </div>
|
|
|
- </template>
|
|
|
- <template slot-scope="{ row, index }" slot="status">
|
|
|
- <div class="status" v-if="row.status === 0">
|
|
|
- <div class="statusVal">申请中</div>
|
|
|
- <div>
|
|
|
- <Button type="error" icon="md-close" size="small" class="item" @click="invalid(row)">驳回</Button>
|
|
|
- <Button type="info" icon="md-checkmark" size="small" class="item" @click="adopt(row, '审核通过', index)"
|
|
|
- >通过</Button
|
|
|
- >
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="statusVal" v-if="row.status === 1">提现通过</div>
|
|
|
- <div class="statusVal" v-if="row.status === -1">提现未通过<br />未通过原因:{{ row.fail_msg }}</div>
|
|
|
- </template>
|
|
|
- <template slot-scope="{ row }" slot="createModalFrame">
|
|
|
- <a href="javascript:void(0);" @click="edit(row)">编辑</a>
|
|
|
- </template>
|
|
|
- </Table>
|
|
|
- <div class="acea-row row-right page">
|
|
|
- <Page
|
|
|
- :total="total"
|
|
|
- :current="formValidate.page"
|
|
|
- show-elevator
|
|
|
- show-total
|
|
|
- @on-change="pageChange"
|
|
|
- :page-size="formValidate.limit"
|
|
|
- />
|
|
|
- </div>
|
|
|
- </Card>
|
|
|
-
|
|
|
- <!-- 编辑表单-->
|
|
|
- <edit-from ref="edits" :FromData="FromData" @submitFail="submitFail"></edit-from>
|
|
|
- <!-- 拒绝通过-->
|
|
|
- <Modal v-model="modals" scrollable closable title="未通过原因" :mask-closable="false">
|
|
|
- <Input v-model="fail_msg.message" type="textarea" :rows="4" placeholder="请输入未通过原因" />
|
|
|
- <div slot="footer">
|
|
|
- <Button type="primary" size="large" long :loading="modal_loading" @click="oks">确定</Button>
|
|
|
- </div>
|
|
|
- </Modal>
|
|
|
- </div>
|
|
|
+ <div class="article-manager">
|
|
|
+ <Card :bordered="false" dis-hover class="ivu-mt">
|
|
|
+ <Form ref="artFrom" :model="artFrom" :label-width="75" label-position="right" @submit.native.prevent>
|
|
|
+ <Row type="flex" :gutter="24">
|
|
|
+ <Col v-bind="grid">
|
|
|
+ <FormItem label="提现类型:" >
|
|
|
+ <Select v-model="artFrom.extract_type" @on-change="userSearchs" clearable placeholder="请选择提现类型">
|
|
|
+ <Option
|
|
|
+ label="全部"
|
|
|
+ value="">
|
|
|
+ </Option>
|
|
|
+ <Option
|
|
|
+ label="银行"
|
|
|
+ value="bank">
|
|
|
+ </Option>
|
|
|
+ <Option
|
|
|
+ label="支付宝"
|
|
|
+ value="ali">
|
|
|
+ </Option>
|
|
|
+ </Select>
|
|
|
+ </FormItem>
|
|
|
+ </Col>
|
|
|
+ <Col v-bind="grid">
|
|
|
+ <FormItem label="审核状态:" >
|
|
|
+ <Select v-model="artFrom.status" @on-change="userSearchs" clearable placeholder="请选择提现类型">
|
|
|
+ <Option
|
|
|
+ label="全部"
|
|
|
+ value="">
|
|
|
+ </Option>
|
|
|
+ <Option
|
|
|
+ label="审核中"
|
|
|
+ :value="0">
|
|
|
+ </Option>
|
|
|
+ <Option
|
|
|
+ label="通过"
|
|
|
+ :value="1">
|
|
|
+ </Option>
|
|
|
+ <Option
|
|
|
+ label="未通过"
|
|
|
+ :value="-1">
|
|
|
+ </Option>
|
|
|
+ </Select>
|
|
|
+ </FormItem>
|
|
|
+ </Col>
|
|
|
+ <Col v-bind="grid">
|
|
|
+ <FormItem label="商户搜索:">
|
|
|
+ <Input search enter-button placeholder="请输入支付宝号/银行卡号" v-model="artFrom.field_key"
|
|
|
+ @on-search="userSearchs" />
|
|
|
+ </FormItem>
|
|
|
+ </Col>
|
|
|
+ </Row>
|
|
|
+ </Form>
|
|
|
+ <div class="Button">
|
|
|
+ <Button type="primary" @click="add('添加')" class="bnt mr15" icon="md-add">申请提现</Button>
|
|
|
+ </div>
|
|
|
+ <Table ref="table" :columns="columns"
|
|
|
+ :data="tableList" class="ivu-mt mt25" :loading="loading" highlight-row no-data-text="暂无数据"
|
|
|
+ no-filtered-data-text="暂无筛选结果">
|
|
|
+ <template slot-scope="{ row }" slot="extract_type">
|
|
|
+ <div v-if="row.extract_type=='ali'">
|
|
|
+ 支付宝
|
|
|
+ </div>
|
|
|
+ <div v-else-if="row.extract_type=='bank'">
|
|
|
+ 银行
|
|
|
+ </div>
|
|
|
+ <div v-else>
|
|
|
+ 其他
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ <template slot-scope="{ row }" slot="extract_detail">
|
|
|
+ <div v-if="row.extract_type=='ali'">
|
|
|
+ 支付宝账号:{{row.alipay_code}}
|
|
|
+ </div>
|
|
|
+ <div v-else-if="row.extract_type=='bank'">
|
|
|
+ 开户行:{{row.bank_address}}<br />
|
|
|
+ 银行卡:{{row.bank_code}}<br />
|
|
|
+ 用户名:{{row.real_name}}<br />
|
|
|
+ </div>
|
|
|
+ <div v-else>
|
|
|
+ 其他
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ <template slot-scope="{ row }" slot="action">
|
|
|
+ <div v-if="row.status==0">
|
|
|
+ 审核中
|
|
|
+ </div>
|
|
|
+ <div v-else-if="row.status==1">
|
|
|
+ 通过
|
|
|
+ </div>
|
|
|
+ <div v-else-if="row.status==-1">
|
|
|
+ 拒绝
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </Table>
|
|
|
+ <div class="acea-row row-right page">
|
|
|
+ <Page :total="total" :current="artFrom.page" show-elevator show-total @on-change="pageChange"
|
|
|
+ :page-size="artFrom.limit" />
|
|
|
+ </div>
|
|
|
+ </Card>
|
|
|
+ <!-- 新增编辑-->
|
|
|
+ <Modal v-model="modals" @on-cancel="onCancel" scrollable footer-hide closable title="申请提现"
|
|
|
+ :mask-closable="false" width="700">
|
|
|
+ <Form ref="formInline" :model="formInline" :rules="ruleValidate" :label-width="150"
|
|
|
+ :label-position="labelPosition2" @submit.native.prevent>
|
|
|
+ <FormItem label="提现类型:" label-for="extract_type" prop="extract_type">
|
|
|
+ <Select v-model="formInline.extract_type" placeholder="请选择提现类型">
|
|
|
+ <Option
|
|
|
+ label="银行"
|
|
|
+ value="bank">
|
|
|
+ </Option>
|
|
|
+ <Option
|
|
|
+ label="支付宝"
|
|
|
+ value="ali">
|
|
|
+ </Option>
|
|
|
+ </Select>
|
|
|
+ </FormItem>
|
|
|
+ <FormItem label="姓名:" label-for="real_name" prop="real_name">
|
|
|
+ <Input placeholder="请输入提现人员姓名" v-model="formInline.real_name" />
|
|
|
+ </FormItem>
|
|
|
+ <FormItem v-if="formInline.extract_type=='bank'" label="银行卡号:" prop='bank_code'>
|
|
|
+ <Input placeholder="请输入银行卡号" v-model="formInline.bank_code" />
|
|
|
+ </FormItem>
|
|
|
+ <FormItem v-if="formInline.extract_type=='bank'" label="开户行:" label-for="account" prop="account">
|
|
|
+ <Input placeholder="请输入开户行" v-model="formInline.bank_address" />
|
|
|
+ </FormItem>
|
|
|
+ <FormItem v-if="formInline.extract_type=='ali'" label="支付宝:" label-for="alipay_code" prop="alipay_code">
|
|
|
+ <Input placeholder="请输入支付宝账号" v-model="formInline.alipay_code" />
|
|
|
+ </FormItem>
|
|
|
+ <FormItem label="提现金额:" label-for="extract_price" prop="extract_price">
|
|
|
+ <Input type="number" placeholder="请输入提现金额" v-model="formInline.extract_price" />
|
|
|
+ </FormItem>
|
|
|
+ <Button type="primary" size="large" long @click="handleSubmit('formInline')">提交</Button>
|
|
|
+ </Form>
|
|
|
+ </Modal>
|
|
|
+ </div>
|
|
|
</template>
|
|
|
+
|
|
|
<script>
|
|
|
-import cardsData from '@/components/cards/cards';
|
|
|
-import searchFrom from '@/components/publicSearchFrom';
|
|
|
-import { mapState } from 'vuex';
|
|
|
-import { cashListApi, cashEditApi, refuseApi } from '@/api/finance';
|
|
|
-import { formatDate } from '@/utils/validate';
|
|
|
-import editFrom from '@/components/from/from';
|
|
|
-export default {
|
|
|
- name: 'cashApply',
|
|
|
- components: { cardsData, searchFrom, editFrom },
|
|
|
- filters: {
|
|
|
- formatDate(time) {
|
|
|
- if (time !== 0) {
|
|
|
- let date = new Date(time * 1000);
|
|
|
- return formatDate(date, 'yyyy-MM-dd hh:mm');
|
|
|
- }
|
|
|
- },
|
|
|
- },
|
|
|
- data() {
|
|
|
- return {
|
|
|
- images: ['1.jpg', '2.jpg'],
|
|
|
- modal_loading: false,
|
|
|
- fail_msg: {
|
|
|
- message: '输入信息不完整或有误!',
|
|
|
- },
|
|
|
- modals: false,
|
|
|
- total: 0,
|
|
|
- cardLists: [],
|
|
|
- loading: false,
|
|
|
- columns: [
|
|
|
- {
|
|
|
- title: 'ID',
|
|
|
- key: 'id',
|
|
|
- width: 80,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '用户信息',
|
|
|
- slot: 'nickname',
|
|
|
- minWidth: 180,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '提现金额',
|
|
|
- slot: 'extract_price',
|
|
|
- minWidth: 90,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '提现方式',
|
|
|
- slot: 'extract_type',
|
|
|
- minWidth: 150,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '收款码',
|
|
|
- slot: 'qrcode_url',
|
|
|
- minWidth: 150,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '添加时间',
|
|
|
- slot: 'add_time',
|
|
|
- minWidth: 100,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '备注',
|
|
|
- key: 'mark',
|
|
|
- minWidth: 100,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '审核状态',
|
|
|
- slot: 'status',
|
|
|
- minWidth: 180,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '操作',
|
|
|
- slot: 'createModalFrame',
|
|
|
- fixed: 'right',
|
|
|
- width: 100,
|
|
|
- },
|
|
|
- ],
|
|
|
- tabList: [],
|
|
|
- fromList: {
|
|
|
- title: '选择时间',
|
|
|
- custom: true,
|
|
|
- fromTxt: [
|
|
|
- { text: '全部', val: '' },
|
|
|
- { text: '今天', val: 'today' },
|
|
|
- { text: '昨天', val: 'yesterday' },
|
|
|
- { text: '本周', val: 'week' },
|
|
|
- { text: '本月', val: 'month' },
|
|
|
- { text: '本季度', val: 'quarter' },
|
|
|
- { text: '本年', val: 'year' },
|
|
|
- ],
|
|
|
- },
|
|
|
- treeData: {
|
|
|
- withdrawal: [
|
|
|
- {
|
|
|
- title: '全部',
|
|
|
- value: '',
|
|
|
- },
|
|
|
- {
|
|
|
- title: '未通过',
|
|
|
- value: -1,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '申请中',
|
|
|
- value: 0,
|
|
|
- },
|
|
|
- {
|
|
|
- title: '已通过',
|
|
|
- value: 1,
|
|
|
- },
|
|
|
- ],
|
|
|
- payment: [
|
|
|
- {
|
|
|
- title: '全部',
|
|
|
- value: '',
|
|
|
- },
|
|
|
- {
|
|
|
- title: '微信',
|
|
|
- value: 'wx',
|
|
|
- },
|
|
|
- {
|
|
|
- title: '支付宝',
|
|
|
- value: 'alipay',
|
|
|
- },
|
|
|
- {
|
|
|
- title: '银行卡',
|
|
|
- value: 'bank',
|
|
|
- },
|
|
|
- ],
|
|
|
- },
|
|
|
- formValidate: {
|
|
|
- status: '',
|
|
|
- extract_type: '',
|
|
|
- nireid: '',
|
|
|
- data: '',
|
|
|
- page: 1,
|
|
|
- limit: 20,
|
|
|
- },
|
|
|
- extractStatistics: {},
|
|
|
- timeVal: [],
|
|
|
- FromData: null,
|
|
|
- extractId: 0,
|
|
|
- };
|
|
|
- },
|
|
|
- watch: {
|
|
|
- $route() {
|
|
|
- if (this.$route.fullPath === this.$routeProStr + '/finance/user_extract/index?status=0') {
|
|
|
- this.getPath();
|
|
|
- }
|
|
|
- },
|
|
|
- },
|
|
|
- computed: {
|
|
|
- ...mapState('media', ['isMobile']),
|
|
|
- labelWidth() {
|
|
|
- return this.isMobile ? undefined : 80;
|
|
|
- },
|
|
|
- labelPosition() {
|
|
|
- return this.isMobile ? 'top' : 'left';
|
|
|
- },
|
|
|
- },
|
|
|
- mounted() {
|
|
|
- if (this.$route.fullPath === this.$routeProStr + '/finance/user_extract/index?status=0') {
|
|
|
- this.getPath();
|
|
|
- } else {
|
|
|
- this.getList();
|
|
|
- }
|
|
|
- },
|
|
|
- methods: {
|
|
|
- getPath() {
|
|
|
- this.formValidate.page = 1;
|
|
|
- this.formValidate.status = parseInt(this.$route.query.status);
|
|
|
- this.getList();
|
|
|
- },
|
|
|
- // 无效
|
|
|
- invalid(row) {
|
|
|
- this.extractId = row.id;
|
|
|
- this.modals = true;
|
|
|
- },
|
|
|
- // 确定
|
|
|
- oks() {
|
|
|
- this.modal_loading = true;
|
|
|
- refuseApi(this.extractId, this.fail_msg)
|
|
|
- .then(async (res) => {
|
|
|
- this.$Message.success(res.msg);
|
|
|
- this.modal_loading = false;
|
|
|
- this.modals = false;
|
|
|
- this.getList();
|
|
|
- })
|
|
|
- .catch((res) => {
|
|
|
- this.$Message.error(res.msg);
|
|
|
- });
|
|
|
- },
|
|
|
- // 通过
|
|
|
- adopt(row, tit, num) {
|
|
|
- let delfromData = {
|
|
|
- title: tit,
|
|
|
- num: num,
|
|
|
- url: `finance/extract/adopt/${row.id}`,
|
|
|
- method: 'put',
|
|
|
- ids: '',
|
|
|
- };
|
|
|
- this.$modalSure(delfromData)
|
|
|
- .then((res) => {
|
|
|
- this.$Message.success(res.msg);
|
|
|
- this.getList();
|
|
|
- })
|
|
|
- .catch((res) => {
|
|
|
- this.$Message.error(res.msg);
|
|
|
- });
|
|
|
- },
|
|
|
- // 具体日期
|
|
|
- onchangeTime(e) {
|
|
|
- this.timeVal = e;
|
|
|
- this.formValidate.data = this.timeVal.join('-');
|
|
|
- this.formValidate.page = 1;
|
|
|
- this.getList();
|
|
|
- },
|
|
|
- // 选择时间
|
|
|
- selectChange(tab) {
|
|
|
- this.formValidate.page = 1;
|
|
|
- this.formValidate.data = tab;
|
|
|
- this.timeVal = [];
|
|
|
- this.getList();
|
|
|
- },
|
|
|
- // 选择
|
|
|
- selChange() {
|
|
|
- this.formValidate.page = 1;
|
|
|
- this.getList();
|
|
|
- },
|
|
|
- // 列表
|
|
|
- getList() {
|
|
|
- this.loading = true;
|
|
|
- cashListApi(this.formValidate)
|
|
|
- .then(async (res) => {
|
|
|
- let data = res.data;
|
|
|
- this.tabList = data.list.list;
|
|
|
- this.total = data.list.count;
|
|
|
- this.extractStatistics = data.extract_statistics;
|
|
|
- this.cardLists = [
|
|
|
- { col: 6, count: this.extractStatistics.price, name: '待提现金额', className: 'md-basket' },
|
|
|
- { col: 6, count: this.extractStatistics.brokerage_count, name: '佣金总金额', className: 'md-pricetags' },
|
|
|
- { col: 6, count: this.extractStatistics.priced, name: '已提现金额', className: 'md-cash' },
|
|
|
- { col: 6, count: this.extractStatistics.brokerage_not, name: '未提现金额', className: 'ios-cash' },
|
|
|
- ];
|
|
|
- this.loading = false;
|
|
|
- })
|
|
|
- .catch((res) => {
|
|
|
- this.loading = false;
|
|
|
- this.$Message.error(res.msg);
|
|
|
- });
|
|
|
- },
|
|
|
- pageChange(index) {
|
|
|
- this.formValidate.page = index;
|
|
|
- this.getList();
|
|
|
- },
|
|
|
- // 编辑
|
|
|
- edit(row) {
|
|
|
- cashEditApi(row.id)
|
|
|
- .then(async (res) => {
|
|
|
- if (res.data.status === false) {
|
|
|
- return this.$authLapse(res.data);
|
|
|
- }
|
|
|
- this.FromData = res.data;
|
|
|
- this.$refs.edits.modals = true;
|
|
|
- })
|
|
|
- .catch((res) => {
|
|
|
- this.$Message.error(res.msg);
|
|
|
- });
|
|
|
- },
|
|
|
- // 编辑提交成功
|
|
|
- submitFail() {
|
|
|
- this.getList();
|
|
|
- },
|
|
|
- },
|
|
|
-};
|
|
|
+ import {
|
|
|
+ mapState
|
|
|
+ } from 'vuex';
|
|
|
+ import {
|
|
|
+ getExtractList,
|
|
|
+ shopExtract
|
|
|
+ } from '@/api/shopOrder';
|
|
|
+ import {
|
|
|
+ addadmin,
|
|
|
+ } from '@/api/shop';
|
|
|
+ export default {
|
|
|
+ name: 'shop_extract',
|
|
|
+ computed: {
|
|
|
+ labelPosition2() {
|
|
|
+ return this.isMobile ? 'top' : 'right';
|
|
|
+ },
|
|
|
+ },
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ template: false,
|
|
|
+ grid: {
|
|
|
+ xl: 7,
|
|
|
+ lg: 7,
|
|
|
+ md: 12,
|
|
|
+ sm: 24,
|
|
|
+ xs: 24,
|
|
|
+ },
|
|
|
+ artFrom: {
|
|
|
+ page: 1,
|
|
|
+ limit: 10,
|
|
|
+ status: '',
|
|
|
+ extract_type: '',
|
|
|
+ field_key:''
|
|
|
+ },
|
|
|
+ tableList: [],
|
|
|
+ loading: false,
|
|
|
+ columns: [{
|
|
|
+ title: 'ID',
|
|
|
+ key: 'id',
|
|
|
+ width: 80,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '提现方式',
|
|
|
+ slot: 'extract_type',
|
|
|
+ minWidth: 80,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '提现信息',
|
|
|
+ slot: 'extract_detail',
|
|
|
+ minWidth: 200,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '提现金额',
|
|
|
+ key: 'extract_price',
|
|
|
+ minWidth: 100,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '审核状态',
|
|
|
+ slot: 'action',
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ data: [],
|
|
|
+ total: 0,
|
|
|
+ modals: false,
|
|
|
+ formInline: {
|
|
|
+ extract_type: 'bank',
|
|
|
+ real_name: '',
|
|
|
+ bank_code: '',
|
|
|
+ bank_address: '',
|
|
|
+ alipay_code: '',
|
|
|
+ extract_price: '',
|
|
|
+ },
|
|
|
+ ruleValidate: {
|
|
|
+ real_name: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入用户名称',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ extract_type: [{
|
|
|
+ required: true,
|
|
|
+ message: '请选择提现类型',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ extract_price: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入提现金额',
|
|
|
+ trigger: 'blur'
|
|
|
+ }],
|
|
|
+ },
|
|
|
+ };
|
|
|
+ },
|
|
|
+ // watch: {
|
|
|
+ // $route() {
|
|
|
+ // if (this.$route.fullPath === this.$routeProStr + '/product/product_list?type=5') {
|
|
|
+ // this.getPath();
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ // },
|
|
|
+ created() {
|
|
|
+ // this.gettype();
|
|
|
+ // this.getclassify();
|
|
|
+ this.getDataList();
|
|
|
+ },
|
|
|
+ activated() {
|
|
|
+ // this.goodHeade();
|
|
|
+ // this.goodsCategory();
|
|
|
+ // if (this.$route.fullPath === this.$routeProStr + '/product/product_list?type=5') {
|
|
|
+ // this.getPath();
|
|
|
+ // } else {
|
|
|
+ // this.getDataList();
|
|
|
+ // }
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ // 商户列表
|
|
|
+ getDataList() {
|
|
|
+ this.loading = true;
|
|
|
+ getExtractList(this.artFrom)
|
|
|
+ .then((res) => {
|
|
|
+ let data = res.data;
|
|
|
+ this.tableList = data.list;
|
|
|
+ this.total = data.count;
|
|
|
+ // this.$nextTick(() => {
|
|
|
+ // //确保dom加载完毕
|
|
|
+ // this.setChecked();
|
|
|
+ // });
|
|
|
+ this.loading = false;
|
|
|
+ })
|
|
|
+ .catch((res) => {
|
|
|
+ this.loading = false;
|
|
|
+ this.$Message.error(res.msg);
|
|
|
+ });
|
|
|
+ },
|
|
|
+ pageChange(status) {
|
|
|
+ this.artFrom.page = status;
|
|
|
+ this.getDataList();
|
|
|
+ },
|
|
|
+ // 表格搜索
|
|
|
+ userSearchs() {
|
|
|
+ this.artFrom.page = 1;
|
|
|
+ this.getDataList();
|
|
|
+ },
|
|
|
+ // 添加
|
|
|
+ add(name) {
|
|
|
+ this.modals = true;
|
|
|
+ },
|
|
|
+ handleSubmit(name) {
|
|
|
+ const that = this;
|
|
|
+ that.$refs[name].validate((valid) => {
|
|
|
+ if (valid) {
|
|
|
+ if(that.formInline.extract_type=='bank'){
|
|
|
+ if(!that.formInline.bank_code){
|
|
|
+ return this.$Message.warning('请输入银行卡号')
|
|
|
+ }
|
|
|
+ if(!that.formInline.bank_address){
|
|
|
+ return this.$Message.warning('请输入开户行')
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if(that.formInline.extract_type=='ali'){
|
|
|
+ if(!that.formInline.alipay_code){
|
|
|
+ return this.$Message.warning('请输入支付宝账号')
|
|
|
+ }
|
|
|
+ }
|
|
|
+ shopExtract(that.formInline)
|
|
|
+ .then(async (res) => {
|
|
|
+ that.$Message.success(res.msg);
|
|
|
+ that.modals = false;
|
|
|
+ that.getDataList();
|
|
|
+ that.$refs[name].resetFields();
|
|
|
+ })
|
|
|
+ .catch((res) => {
|
|
|
+ that.$Message.error(res.msg);
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ onCancel() {
|
|
|
+ this.$refs['formInline'].resetFields();
|
|
|
+ },
|
|
|
+ },
|
|
|
+ };
|
|
|
</script>
|
|
|
<style scoped lang="stylus">
|
|
|
-.ivu-mt .type .item
|
|
|
- margin:3px 0;
|
|
|
-.tabform
|
|
|
- margin-bottom 10px
|
|
|
-.Refresh
|
|
|
- font-size 12px
|
|
|
- color #1890FF
|
|
|
- cursor pointer
|
|
|
-.ivu-form-item
|
|
|
- margin-bottom 10px
|
|
|
-.status >>> .item~.item
|
|
|
- margin-left 6px
|
|
|
-.status >>> .statusVal
|
|
|
- margin-bottom 7px
|
|
|
-/*.ivu-mt >>> .ivu-table-header*/
|
|
|
-/* border-top:1px dashed #ddd!important*/
|
|
|
-.type
|
|
|
- padding 3px 0
|
|
|
- box-sizing border-box
|
|
|
-.tabBox_img
|
|
|
- width 36px
|
|
|
- height 36px
|
|
|
- border-radius:4px
|
|
|
- cursor pointer
|
|
|
- img
|
|
|
- width 100%
|
|
|
- height 100%
|
|
|
-</style>
|
|
|
+ /deep/.ivu-modal-mask {
|
|
|
+ z-index: 999 !important;
|
|
|
+ }
|
|
|
+
|
|
|
+ /deep/.ivu-modal-wrap {
|
|
|
+ z-index: 999 !important;
|
|
|
+ }
|
|
|
+
|
|
|
+ .Box {
|
|
|
+ >>>.ivu-modal-body {
|
|
|
+ height: 700px;
|
|
|
+ overflow: auto;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .batch-box {
|
|
|
+ >>>.ivu-modal-body {
|
|
|
+ overflow: auto;
|
|
|
+ min-height: 350px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .tabBox_img {
|
|
|
+ width: 36px;
|
|
|
+ height: 36px;
|
|
|
+ border-radius: 4px;
|
|
|
+ cursor: pointer;
|
|
|
+
|
|
|
+ img {
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .bg {
|
|
|
+ position: fixed;
|
|
|
+ left: 0;
|
|
|
+ top: 0;
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+ background: rgba(0, 0, 0, 0.5);
|
|
|
+ z-index: 11;
|
|
|
+ }
|
|
|
+
|
|
|
+ /deep/.happy-scroll-content {
|
|
|
+ width: 100%;
|
|
|
+
|
|
|
+ .demo-spin-icon-load {
|
|
|
+ animation: ani-demo-spin 1s linear infinite;
|
|
|
+ }
|
|
|
+
|
|
|
+ @keyframes ani-demo-spin {
|
|
|
+ from {
|
|
|
+ transform: rotate(0deg);
|
|
|
+ }
|
|
|
+
|
|
|
+ 50% {
|
|
|
+ transform: rotate(180deg);
|
|
|
+ }
|
|
|
+
|
|
|
+ to {
|
|
|
+ transform: rotate(360deg);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .demo-spin-col {
|
|
|
+ height: 100px;
|
|
|
+ position: relative;
|
|
|
+ border: 1px solid #eee;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .labelInput {
|
|
|
+ border: 1px solid #dcdee2;
|
|
|
+ width: 20%;
|
|
|
+ padding: 0 5px;
|
|
|
+ border-radius: 5px;
|
|
|
+ min-height: 30px;
|
|
|
+ cursor: pointer;
|
|
|
+
|
|
|
+ .span {
|
|
|
+ color: #c5c8ce;
|
|
|
+ }
|
|
|
+
|
|
|
+ .iconxiayi {
|
|
|
+ font-size: 12px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+</style>
|