diff --git a/src/views/merchant/application/index.vue b/src/views/merchant/application/index.vue index a8599ed..e77f8a5 100644 --- a/src/views/merchant/application/index.vue +++ b/src/views/merchant/application/index.vue @@ -4,29 +4,32 @@ - - - - + + + + + value-format="yyyy/MM/dd" :picker-options="pickerOptions" @change="onchangeTime" + style="width: 280px"/> - - + + - + - + 搜索 @@ -36,18 +39,18 @@ - - - - - - - + + + + + + + @@ -59,11 +62,12 @@
原因:{{ scope.row.fail_msg }}
- + @@ -308,9 +312,10 @@ import { getMerCateApi, updateStatus } from "@/api/merchant"; -import { fromList, statusList } from "@/libs/constants.js"; -import { roterPre } from "@/settings"; +import {fromList, statusList} from "@/libs/constants.js"; +import {roterPre} from "@/settings"; import timeOptions from '@/utils/timeOptions'; + export default { name: "MerchantApplication", data() { @@ -384,11 +389,7 @@ export default { this.$refs.searchForm.resetFields() this.getList(1) }, - // statusChange(tab) { - // this.tableFrom.status = tab; - // this.tableFrom.page = 1; - // this.getList(""); - // }, + // 具体日期 onchangeTime(e) { this.timeVal = e; @@ -396,6 +397,7 @@ export default { this.tableFrom.page = 1; this.getList(""); }, + // 商户分类; getMerCategory() { getMerCateApi().then(res => { @@ -404,6 +406,7 @@ export default { this.$message.error(res.message) }) }, + /**获取店铺类型 */ getStoreType() { getstoreTypeApi().then(res => { @@ -412,25 +415,26 @@ export default { this.$message.error(res.message) }) }, + // 列表 getList(num) { this.listLoading = true; this.tableFrom.page = num ? num : this.tableFrom.page; - intentionLstApi(this.tableFrom) - .then((res) => { - this.tableData.data = res.data.list; - this.tableData.total = res.data.count; - this.listLoading = false; - }) - .catch((res) => { - this.listLoading = false; - this.$message.error(res.message); - }); + intentionLstApi(this.tableFrom).then((res) => { + this.tableData.data = res.data.list; + this.tableData.total = res.data.count; + this.listLoading = false; + }).catch((res) => { + this.listLoading = false; + this.$message.error(res.message); + }); }, + pageChange(page) { this.tableFrom.page = page; this.getList(""); }, + handleSizeChange(val) { this.tableFrom.limit = val; this.getList(1); @@ -439,13 +443,12 @@ export default { // 修改状态 onchangeIsShow(item) { this.statusAuditVisible = true; - this.statusAuditForm = Object.assign(this.statusAuditForm,item) + this.statusAuditForm = JSON.parse(JSON.stringify(item)); this.$set(this.statusAuditForm, 'state', 1); this.$set(this.statusAuditForm, 'create_mer', 1); + this.$set(this.statusAuditForm, 'mark', ''); }, - // 添加 - // 提交状态修改 handleSubmit() { if (this.statusAuditForm.state == 2 && !this.statusAuditForm.fail_msg) { @@ -455,12 +458,13 @@ export default { updateStatus(this.statusAuditForm.mer_intention_id, { status: this.statusAuditForm.state, create_mer: this.statusAuditForm.create_mer, - fail_msg: this.statusAuditForm.fail_msg + fail_msg: this.statusAuditForm.fail_msg, + mark: this.statusAuditForm.mark }).then(res => { this.statusAuditVisible = false; this.$message.success(res.message); this.getList(""); - }).catch(({ message }) => { + }).catch(({message}) => { this.$message.error(message); }); }, @@ -480,17 +484,15 @@ export default { // 删除 handleDelete(id) { this.$deleteSure().then(() => { - intentionDelte(id) - .then(({ message }) => { - this.$message.success(message); - this.getList(""); - }) - .catch(({ message }) => { - this.$message.error(message); - }); + intentionDelte(id).then(({message}) => { + this.$message.success(message); + this.getList(""); + }).catch(({message}) => { + this.$message.error(message); + }); }); - }, - }, + } + } };