123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393 |
- <template>
- <div class="app-container">
- <div v-if="showPage == 1">
- <el-radio-group v-model="category" size="">
- <el-radio-button label="全部"></el-radio-button>
- <el-radio-button label="待审核"></el-radio-button>
- <el-radio-button label="审核通过"></el-radio-button>
- <el-radio-button label="审核驳回"></el-radio-button>
- <el-radio-button label="复核通过"></el-radio-button>
- <el-radio-button label="待复核"></el-radio-button>
- <el-radio-button label="复核驳回"></el-radio-button>
- </el-radio-group>
- <br /><br />
- <!-- 筛选条件 -->
- <div>
- <el-form
- ref="searchForm"
- :model="searchForm"
- label-width="100px"
- size="small"
- label-position="left"
- >
- <el-row :gutter="20">
- <el-col :xs="24" :sm="12" :lg="6">
- <el-form-item label="返利互转单号" prop="id">
- <el-input
- v-model="searchForm.id"
- placeholder="请输入"
- ></el-input>
- </el-form-item>
- </el-col>
- <el-col :xs="24" :sm="12" :lg="6">
- <el-form-item label="返利类型" prop="walletName">
- <el-input
- v-model="searchForm.walletName"
- placeholder="请输入"
- ></el-input>
- </el-form-item>
- </el-col>
- <el-col :xs="24" :sm="12" :lg="6">
- <el-form-item label="申请日期" prop="startTime">
- <el-date-picker
- class="dateStyle"
- v-model="searchForm.startTime"
- placeholder="选择日期"
- type="datetime"
- value-format="yyyy-MM-dd HH:mm:ss"
- >
- </el-date-picker>
- </el-form-item>
- </el-col>
- <el-col :xs="24" :sm="12" :lg="6">
- <el-form-item label="" class="fr">
- <el-button size="small" @click="clearFn">清空</el-button>
- <el-button size="small" type="primary" @click="searchFn"
- >搜索</el-button
- >
- </el-form-item>
- </el-col>
- </el-row>
- </el-form>
- </div>
- <br />
- <strong>返利互转单列表</strong>
- <el-divider></el-divider>
- <!-- 列表 -->
- <div class="mymain-container">
- <div class="table">
- <el-table
- v-loading="listLoading"
- :data="dataList"
- element-loading-text="Loading"
- border
- fit
- highlight-current-row
- stripe
- >
- <el-table-column
- label="序号"
- align="center"
- width="100"
- type="index"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="返利转账单号"
- prop="id"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="申请日期"
- prop="applyTime"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="经销商编号"
- prop="customerNumber"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="经销商名称"
- prop="customerName"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="表体备注"
- prop="initiatorRemark"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="返利类型"
- prop=""
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="返利金额"
- prop="amount"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="备注"
- prop="remark"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="制单人"
- prop="createBy"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="审核人"
- prop="examineBy"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="审核日期"
- prop="examineTime"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="复核人"
- prop="secondExamineBy"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="复核日期"
- prop="secondExamineTime"
- min-width="160"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- align="center"
- label="状态"
- prop="examineStatus"
- min-width="160"
- show-overflow-tooltip
- >
- <template slot-scope="scope">
- <el-tag v-show="scope.row.examineStatus == 'SAVE'">保存</el-tag>
- <el-tag v-show="scope.row.examineStatus == 'WAIT'"
- >待审核</el-tag
- >
- <el-tag v-show="scope.row.examineStatus == 'OK_ONE'"
- >初审通过</el-tag
- >
- <el-tag v-show="scope.row.examineStatus == 'FAIL_ONE'"
- >初审不通过</el-tag
- >
- <el-tag v-show="scope.row.examineStatus == 'OK'"
- >复核通过</el-tag
- >
- <el-tag v-show="scope.row.examineStatus == 'FALL'"
- >不通过</el-tag
- >
- <el-tag v-show="scope.row.examineStatus == 'CLOSE'"
- >已关闭</el-tag
- >
- </template>
- </el-table-column>
- <el-table-column
- align="center"
- label="操作"
- min-width="200"
- show-overflow-tooltip
- fixed="right"
- >
- <template slot-scope="scope">
- <el-button
- @click="submitFn(scope.row.id)"
- type="text"
- class="textColor"
- slot="reference"
- >提审</el-button
- >
- <el-button
- v-if="
- scope.row.examineStatus == 'WAIT' ||
- scope.row.examineStatus == 'OK_ONE'
- "
- @click="examineFn(scope.row.id)"
- type="text"
- class="textColor"
- slot="reference"
- >审核</el-button
- >
- <el-button
- v-if="
- scope.row.examineStatus == 'WAIT' ||
- scope.row.examineStatus == 'SAVE'
- "
- type="text"
- class="textColor"
- slot="reference"
- @click="editFn(scope.row.id)"
- >修改</el-button
- >
- <el-button
- @click="detailFn(scope.row.id)"
- type="text"
- class="textColor"
- slot="reference"
- >详情</el-button
- >
- </template>
- </el-table-column>
- </el-table>
- </div>
- <!-- 分页 -->
- <div class="fr">
- <el-pagination
- @size-change="handleSizeChange"
- @current-change="handleCurrentChange"
- :current-page="currentPage"
- :page-sizes="[10, 20, 30, 50]"
- :page-size="10"
- layout="total, sizes, prev, pager, next, jumper"
- :total="listTotal"
- >
- </el-pagination>
- </div>
- </div>
- </div>
- <ChangeListDetail :detailList="detailList" v-else-if="showPage == 2" />
- <ChangeListExamine
- @refresh="refreshFn"
- :detailList="detailList"
- v-else-if="showPage == 3"
- />
- <ChangeListReview
- @refresh="refreshFn"
- :detailList="detailList"
- v-else-if="showPage == 4"
- />
- </div>
- </template>
- <script>
- import {
- getChangeList,
- getChangeListDetail,
- getTransferSubmit,
- } from "@/api/finance/change_list";
- import ChangeListDetail from "./components/change_list-detail";
- import ChangeListExamine from "./components/change_list-examine";
- import ChangeListReview from "./components/change_list-review";
- export default {
- components: {
- ChangeListDetail,
- ChangeListExamine,
- ChangeListReview,
- },
- data() {
- return {
- currentPage: 1, // 当前页码
- pageSize: 10, // 每页数量
- listTotal: 0, // 列表总数
- dataList: [], // 列表数据
- searchForm: {
- startTime: "",
- walletName: "",
- id: "",
- }, //搜索表单
- listLoading: false, // 列表加载loading
- category: "全部",
- showPage: 1,
- detailList: {},
- };
- },
- created() {
- this.getDataList({ pageSize: this.pageSize, pageNum: this.currentPage });
- },
- methods: {
- //刷新
- refreshFn() {
- this.getDataList({ pageSize: this.pageSize, pageNum: this.currentPage });
- },
- //提审
- async submitFn(id) {
- await getTransferSubmit({ id });
- this.$message.success("提审成功");
- this.getDataList({ pageSize: this.pageSize, pageNum: this.currentPage });
- },
- //清空
- clearFn() {
- console.log(this.$refs.searchForm);
- this.$refs.searchForm.resetFields();
- },
- //搜索
- searchFn() {
- this.getDataList({
- ...this.searchForm,
- pageNum: this.currentPage,
- pageSize: this.pageSize,
- });
- },
- //获取列表数据
- async getDataList(data) {
- const res = await getChangeList(data);
- console.log(res);
- this.dataList = res.data.records;
- this.listTotal = res.data.total;
- },
- //详情
- async detailFn(id) {
- const res = await getChangeListDetail({ id });
- console.log(res);
- this.detailList = res.data;
- this.showPage = 2;
- },
- //修改
- async editFn(id) {
- const res = await getChangeListDetail({ id });
- this.detailList = res.data;
- this.showPage = 4;
- },
- //审核
- async examineFn(id) {
- const res = await getChangeListDetail({ id });
- this.detailList = res.data;
- this.showPage = 3;
- },
- // 更改每页数量
- handleSizeChange(val) {
- this.pageSize = val;
- this.currentPage = 1;
- this.getDataList({ pageNum: 1, pageSize: this.pageSize });
- },
- // 更改当前页
- handleCurrentChange(val) {
- this.currentPage = val;
- this.getDataList({ pageNum: val, pageSize: 10 });
- },
- },
- };
- </script>
- <style lang="scss" scoped>
- .dateStyle {
- width: 100%;
- }
- </style>
|