- 手机号:
-
+
@@ -29,13 +28,14 @@
style="width: 100%"
@selection-change="handleSelectionChange"
>
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
启用
禁用
@@ -126,6 +126,9 @@ import { Delete, Download, Plus, ZoomIn } from '@element-plus/icons-vue'
import type { ComponentSize, FormInstance, FormRules, UploadFile, UploadProps, UploadUserFile } from 'element-plus'
import { baseUrlHost } from '../../api/baseUrlHost';
import { clientsApi } from '/@/api/clients';
+import { userApi } from '/@/api/user';
+
+const userapi = userApi();
const options = [
{
@@ -147,7 +150,8 @@ const state = reactive({
total: 0,
loading: false,
param: {
- phone:'',
+ username:'',
+ usertype:2,
current: 1,
size: 10,
},
@@ -181,10 +185,17 @@ const clientApi = clientsApi();
const getTableData = async() => {
try {
state.tableData.loading = true;
- let res = await clientApi.getClientsList(state.tableData.param);
- console.log(res);
+ let res = await userapi.getUserList(state.tableData.param);
+ // console.log(res);
if(res?.success){
- state.tableData.data = res.data.records;
+ state.tableData.data = res.data.records.map((item:any) => {
+ return {
+ ...item,
+ nickName:item.nickName || '暂无',
+ phone: item.phone || '暂无',
+ mail: item.mail || '暂无',
+ }
+ });
state.tableData.total = res.data.total;
}else{
ElMessage.error('客户列表获取失败!');
@@ -221,7 +232,8 @@ const switchState = (scope,staus) => {
// 重置
const reset = () =>{
state.tableData.param = {
- name: '',
+ username: '',
+ usertype:2,
current: 1,
size: 10,
}