From 470bd526f3e62ad331409a542638d836fea20665 Mon Sep 17 00:00:00 2001 From: renkang <8417338+k94314517@user.noreply.gitee.com> Date: 星期六, 23 十一月 2024 17:37:16 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- admin/src/views/client/staffList.vue | 77 +++++++++++++++++++------------------- 1 files changed, 38 insertions(+), 39 deletions(-) diff --git a/admin/src/views/client/staffList.vue b/admin/src/views/client/staffList.vue index 3012931..6117255 100644 --- a/admin/src/views/client/staffList.vue +++ b/admin/src/views/client/staffList.vue @@ -2,8 +2,10 @@ <TableLayout :permissions="['business:ywcustomer:query']"> <!-- 鎼滅储琛ㄥ崟 --> <el-form ref="searchForm" slot="search-form" :model="searchForm" label-width="100px" inline> - <el-form-item label="瀹㈡埛鍚嶇О" prop="name"> - <el-input v-model="searchForm.name" placeholder="璇疯緭鍏ュ鎴峰悕绉�" @keypress.enter.native="search"></el-input> + <el-form-item label="瀹㈡埛鍚嶇О" prop="customerId"> + <el-select v-model="searchForm.customerId" clearable filterable> + <el-option v-for="item in clientList" :value="item.id" :label="item.name" /> + </el-select> </el-form-item> <el-form-item prop="name"> <el-input v-model="searchForm.name" placeholder="璇疯緭鍏ヤ汉鍛樺鍚�/鎵嬫満鍙�" @keypress.enter.native="search"></el-input> @@ -18,21 +20,31 @@ <!-- 琛ㄦ牸鍜屽垎椤� --> <template v-slot:table-wrap> <ul class="toolbar" v-permissions="['business:ywcustomer:create', 'business:ywcustomer:delete']"> - <li><el-button type="primary" @click="$refs.operaYwCustomerWindow.open('鏂板缓瀹㈡埛')" icon="el-icon-plus" + <li><el-button type="primary" @click="$refs.operaYwCustomerWindow.open('鏂板缓浜哄憳')" icon="el-icon-plus" v-permissions="['business:ywcustomer:create']">鏂板缓</el-button></li> <li><el-button @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:ywcustomer:delete']">鍒犻櫎</el-button></li> </ul> <el-table v-loading="isWorking.search" :data="tableData.list" stripe @selection-change="handleSelectionChange"> - <el-table-column prop="name" label="瀹㈡埛鍚嶇О" min-width="100px"></el-table-column> - <el-table-column prop="memberName" label="鑱旂郴浜�" min-width="100px"></el-table-column> + <el-table-column prop="customerName" label="瀹㈡埛鍚嶇О" min-width="100px"></el-table-column> + <el-table-column prop="name" label="鑱旂郴浜�" min-width="100px"></el-table-column> <el-table-column prop="phone" label="鑱旂郴鐢佃瘽" min-width="100px"></el-table-column> - <el-table-column prop="" label="韬唤" min-width="100px"></el-table-column> - <el-table-column prop="" label="鐘舵��" min-width="100px"></el-table-column> + <el-table-column prop="" label="韬唤" min-width="100px"> + <template slot-scope="{row}"> + <span v-if="row.highCheckor == 0">鑰佹澘/瓒呯骇绠$悊鍛�</span> + <span v-if="row.highCheckor == 1">浜轰簨/绠$悊鍛�</span> + <span v-if="row.highCheckor == 2">鍛樺伐/鏅�氬憳宸�</span> + </template> + </el-table-column> + <el-table-column prop="status" label="鐘舵��" min-width="100px"> + <template slot-scope="{row}"> + <span :class="{ red: row.status == 1 }">{{ row.status == '0' ? '姝e父' : '绂佺敤' }}</span> + </template> + </el-table-column> <el-table-column v-if="containPermissions(['business:ywcustomer:update', 'business:ywcustomer:delete'])" label="鎿嶄綔" min-width="120" fixed="right"> <template slot-scope="{row}"> - <el-button type="text" @click="$refs.operaYwCustomerWindow.open('缂栬緫瀹㈡埛', row)" icon="el-icon-edit" + <el-button type="text" @click="$refs.operaYwCustomerWindow.open('缂栬緫浜哄憳', row)" icon="el-icon-edit" v-permissions="['business:ywcustomer:update']">缂栬緫</el-button> <el-button type="text" @click="deleteById(row)" icon="el-icon-delete" v-permissions="['business:ywcustomer:delete']">鍒犻櫎</el-button> @@ -51,7 +63,8 @@ import BaseTable from '@/components/base/BaseTable' import TableLayout from '@/layouts/TableLayout' import Pagination from '@/components/common/Pagination' -import OperaYwCustomerWindow from './components/OperaYwCustomerWindow' +import OperaYwCustomerWindow from './components/staffEdit.vue' +import { fetchList } from '@/api/client/ywCustomer' export default { name: 'YwCustomer', extends: BaseTable, @@ -60,46 +73,32 @@ return { // 鎼滅储 searchForm: { - id: '', - creator: '', - createDate: '', - editor: '', - editDate: '', - isdeleted: '', - remark: '', - industryId: '', - type: '', + customerId: '', name: '', - phone: '', - idcardNo: '', - idcardDecode: '', - code: '', - status: '', - highCheckor: '', - lastLoginDate: '', - loginNum: '', - userId: '', - idcardType: '', - accountBank: '', - accountNo: '', - accountPhone: '', - creditCard: '', - fpType: '', - accountAddr: '', - identityType: '', - email: '', - memberId: '' - } + }, + clientList: [] } }, created() { this.config({ module: '杩愮淮瀹㈡埛淇℃伅琛�', - api: '/client/ywCustomer', + api: '/client/staff', 'field.id': 'id', 'field.main': 'id' }) this.search() + this.initData() + }, + methods: { + initData() { + fetchList({ + capacity: 9000, + model: {}, + page: 1 + }).then(res => { + this.clientList = res.records || [] + }) + }, } } </script> -- Gitblit v1.9.3