完成投诉管理
This commit is contained in:
63
src/api/system/Activity/index.ts
Normal file
63
src/api/system/Activity/index.ts
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
import request from '@/utils/request';
|
||||||
|
import { AxiosPromise } from 'axios';
|
||||||
|
import { ActivityVO, ActivityForm, ActivityQuery } from '@/api/system/Activity/type';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询活动管理列表
|
||||||
|
* @param query
|
||||||
|
* @returns {*}
|
||||||
|
*/
|
||||||
|
|
||||||
|
export const listActivity = (query?: ActivityQuery): AxiosPromise<ActivityVO[]> => {
|
||||||
|
return request({
|
||||||
|
url: '/activity/list',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询活动管理详细
|
||||||
|
* @param id
|
||||||
|
*/
|
||||||
|
export const getActivity = (id: string | number): AxiosPromise<ActivityVO> => {
|
||||||
|
return request({
|
||||||
|
url: '/activity/' + id,
|
||||||
|
method: 'get'
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增活动管理
|
||||||
|
* @param data
|
||||||
|
*/
|
||||||
|
export const addActivity = (data: ActivityForm) => {
|
||||||
|
return request({
|
||||||
|
url: '/activity',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改活动管理
|
||||||
|
* @param data
|
||||||
|
*/
|
||||||
|
export const updateActivity = (data: ActivityForm) => {
|
||||||
|
return request({
|
||||||
|
url: '/activity',
|
||||||
|
method: 'put',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除活动管理
|
||||||
|
* @param id
|
||||||
|
*/
|
||||||
|
export const delActivity = (id: string | number | Array<string | number>) => {
|
||||||
|
return request({
|
||||||
|
url: '/activity/' + id,
|
||||||
|
method: 'delete'
|
||||||
|
});
|
||||||
|
};
|
||||||
110
src/api/system/Activity/type.ts
Normal file
110
src/api/system/Activity/type.ts
Normal file
@@ -0,0 +1,110 @@
|
|||||||
|
export interface ActivityVO {
|
||||||
|
/**
|
||||||
|
* 活动管理表id
|
||||||
|
*/
|
||||||
|
id: string | number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 标题
|
||||||
|
*/
|
||||||
|
titile: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 作者
|
||||||
|
*/
|
||||||
|
author: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 内容
|
||||||
|
*/
|
||||||
|
content: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 发布状态 0未发布 1已发布
|
||||||
|
*/
|
||||||
|
status: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 浏览量
|
||||||
|
*/
|
||||||
|
pageViews: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建者姓名
|
||||||
|
*/
|
||||||
|
createName: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ActivityForm extends BaseEntity {
|
||||||
|
/**
|
||||||
|
* 活动管理表id
|
||||||
|
*/
|
||||||
|
id?: string | number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 标题
|
||||||
|
*/
|
||||||
|
titile?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 作者
|
||||||
|
*/
|
||||||
|
author?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 内容
|
||||||
|
*/
|
||||||
|
content?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 发布状态 0未发布 1已发布
|
||||||
|
*/
|
||||||
|
status?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 浏览量
|
||||||
|
*/
|
||||||
|
pageViews?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建者姓名
|
||||||
|
*/
|
||||||
|
createName?: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ActivityQuery extends PageQuery {
|
||||||
|
/**
|
||||||
|
* 标题
|
||||||
|
*/
|
||||||
|
titile?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 作者
|
||||||
|
*/
|
||||||
|
author?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 内容
|
||||||
|
*/
|
||||||
|
content?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 发布状态 0未发布 1已发布
|
||||||
|
*/
|
||||||
|
status?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 浏览量
|
||||||
|
*/
|
||||||
|
pageViews?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建者姓名
|
||||||
|
*/
|
||||||
|
createName?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 日期范围参数
|
||||||
|
*/
|
||||||
|
params?: any;
|
||||||
|
}
|
||||||
63
src/api/system/ComplainType/index.ts
Normal file
63
src/api/system/ComplainType/index.ts
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
import request from '@/utils/request';
|
||||||
|
import { AxiosPromise } from 'axios';
|
||||||
|
import { ComplaintTypeVO, ComplaintTypeForm, ComplaintTypeQuery } from '@/api/system/ComplainType/type';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询投诉类型管理列表
|
||||||
|
* @param query
|
||||||
|
* @returns {*}
|
||||||
|
*/
|
||||||
|
|
||||||
|
export const listComplaintType = (query?: ComplaintTypeQuery): AxiosPromise<ComplaintTypeVO[]> => {
|
||||||
|
return request({
|
||||||
|
url: '/complaintType/list',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询投诉类型管理详细
|
||||||
|
* @param id
|
||||||
|
*/
|
||||||
|
export const getComplaintType = (id: string | number): AxiosPromise<ComplaintTypeVO> => {
|
||||||
|
return request({
|
||||||
|
url: '/complaintType/' + id,
|
||||||
|
method: 'get'
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增投诉类型管理
|
||||||
|
* @param data
|
||||||
|
*/
|
||||||
|
export const addComplaintType = (data: ComplaintTypeForm) => {
|
||||||
|
return request({
|
||||||
|
url: '/complaintType',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改投诉类型管理
|
||||||
|
* @param data
|
||||||
|
*/
|
||||||
|
export const updateComplaintType = (data: ComplaintTypeForm) => {
|
||||||
|
return request({
|
||||||
|
url: '/complaintType',
|
||||||
|
method: 'put',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除投诉类型管理
|
||||||
|
* @param id
|
||||||
|
*/
|
||||||
|
export const delComplaintType = (id: string | number | Array<string | number>) => {
|
||||||
|
return request({
|
||||||
|
url: '/complaintType/' + id,
|
||||||
|
method: 'delete'
|
||||||
|
});
|
||||||
|
};
|
||||||
80
src/api/system/ComplainType/type.ts
Normal file
80
src/api/system/ComplainType/type.ts
Normal file
@@ -0,0 +1,80 @@
|
|||||||
|
export interface ComplaintTypeVO {
|
||||||
|
/**
|
||||||
|
* 投诉类型管理表id
|
||||||
|
*/
|
||||||
|
id: string | number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉类型名称
|
||||||
|
*/
|
||||||
|
name: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 状态 0 启用 1停用
|
||||||
|
*/
|
||||||
|
status: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建人名称
|
||||||
|
*/
|
||||||
|
createNam: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建时间
|
||||||
|
*/
|
||||||
|
creaateTime: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ComplaintTypeForm extends BaseEntity {
|
||||||
|
/**
|
||||||
|
* 投诉类型管理表id
|
||||||
|
*/
|
||||||
|
id?: string | number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉类型名称
|
||||||
|
*/
|
||||||
|
name?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 状态 0 启用 1停用
|
||||||
|
*/
|
||||||
|
status?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建人名称
|
||||||
|
*/
|
||||||
|
createNam?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建时间
|
||||||
|
*/
|
||||||
|
creaateTime?: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ComplaintTypeQuery extends PageQuery {
|
||||||
|
/**
|
||||||
|
* 投诉类型名称
|
||||||
|
*/
|
||||||
|
name?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 状态 0 启用 1停用
|
||||||
|
*/
|
||||||
|
status?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建人名称
|
||||||
|
*/
|
||||||
|
createNam?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建时间
|
||||||
|
*/
|
||||||
|
creaateTime?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 日期范围参数
|
||||||
|
*/
|
||||||
|
params?: any;
|
||||||
|
}
|
||||||
63
src/api/system/Complaint/index.ts
Normal file
63
src/api/system/Complaint/index.ts
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
import request from '@/utils/request';
|
||||||
|
import { AxiosPromise } from 'axios';
|
||||||
|
import { ComplaintVO, ComplaintForm, ComplaintQuery } from '@/api/system/Complaint/type';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询投诉管理列表
|
||||||
|
* @param query
|
||||||
|
* @returns {*}
|
||||||
|
*/
|
||||||
|
|
||||||
|
export const listComplaint = (query?: ComplaintQuery): AxiosPromise<ComplaintVO[]> => {
|
||||||
|
return request({
|
||||||
|
url: '/complaint/list',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询投诉管理详细
|
||||||
|
* @param id
|
||||||
|
*/
|
||||||
|
export const getComplaint = (id: string | number): AxiosPromise<ComplaintVO> => {
|
||||||
|
return request({
|
||||||
|
url: '/complaint/' + id,
|
||||||
|
method: 'get'
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增投诉管理
|
||||||
|
* @param data
|
||||||
|
*/
|
||||||
|
export const addComplaint = (data: ComplaintForm) => {
|
||||||
|
return request({
|
||||||
|
url: '/complaint',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改投诉管理
|
||||||
|
* @param data
|
||||||
|
*/
|
||||||
|
export const updateComplaint = (data: ComplaintForm) => {
|
||||||
|
return request({
|
||||||
|
url: '/complaint',
|
||||||
|
method: 'put',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除投诉管理
|
||||||
|
* @param id
|
||||||
|
*/
|
||||||
|
export const delComplaint = (id: string | number | Array<string | number>) => {
|
||||||
|
return request({
|
||||||
|
url: '/complaint/' + id,
|
||||||
|
method: 'delete'
|
||||||
|
});
|
||||||
|
};
|
||||||
155
src/api/system/Complaint/type.ts
Normal file
155
src/api/system/Complaint/type.ts
Normal file
@@ -0,0 +1,155 @@
|
|||||||
|
export interface ComplaintVO {
|
||||||
|
/**
|
||||||
|
* 投诉管理表id
|
||||||
|
*/
|
||||||
|
id: string | number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉类型id
|
||||||
|
*/
|
||||||
|
typeId: string | number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题描述
|
||||||
|
*/
|
||||||
|
problemDes: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉人姓名
|
||||||
|
*/
|
||||||
|
complaintName: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 手机号
|
||||||
|
*/
|
||||||
|
phone: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题照片url
|
||||||
|
*/
|
||||||
|
problemIamgeUrl: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉状态 0待处理 1处理中 2已处理
|
||||||
|
*/
|
||||||
|
status: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理人员id
|
||||||
|
*/
|
||||||
|
handleId: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理人员姓名
|
||||||
|
*/
|
||||||
|
handleName: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理描述
|
||||||
|
*/
|
||||||
|
handleContent: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ComplaintForm extends BaseEntity {
|
||||||
|
/**
|
||||||
|
* 投诉管理表id
|
||||||
|
*/
|
||||||
|
id?: string | number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉类型id
|
||||||
|
*/
|
||||||
|
typeId?: string | number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题描述
|
||||||
|
*/
|
||||||
|
problemDes?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉人姓名
|
||||||
|
*/
|
||||||
|
complaintName?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 手机号
|
||||||
|
*/
|
||||||
|
phone?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题照片url
|
||||||
|
*/
|
||||||
|
problemIamgeUrl?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉状态 0待处理 1处理中 2已处理
|
||||||
|
*/
|
||||||
|
status?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理人员id
|
||||||
|
*/
|
||||||
|
handleId?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理人员姓名
|
||||||
|
*/
|
||||||
|
handleName?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理描述
|
||||||
|
*/
|
||||||
|
handleContent?: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ComplaintQuery extends PageQuery {
|
||||||
|
/**
|
||||||
|
* 投诉类型id
|
||||||
|
*/
|
||||||
|
typeId?: string | number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题描述
|
||||||
|
*/
|
||||||
|
problemDes?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉人姓名
|
||||||
|
*/
|
||||||
|
complaintName?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 手机号
|
||||||
|
*/
|
||||||
|
phone?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题照片url
|
||||||
|
*/
|
||||||
|
problemIamgeUrl?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 投诉状态 0待处理 1处理中 2已处理
|
||||||
|
*/
|
||||||
|
status?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理人员id
|
||||||
|
*/
|
||||||
|
handleId?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理人员姓名
|
||||||
|
*/
|
||||||
|
handleName?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理描述
|
||||||
|
*/
|
||||||
|
handleContent?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 日期范围参数
|
||||||
|
*/
|
||||||
|
params?: any;
|
||||||
|
}
|
||||||
@@ -2,7 +2,7 @@ export interface ResidentVO {
|
|||||||
/**
|
/**
|
||||||
* 主键 住户管理id
|
* 主键 住户管理id
|
||||||
*/
|
*/
|
||||||
id: string | number;
|
userId: string | number;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 住户编号
|
* 住户编号
|
||||||
@@ -77,7 +77,7 @@ export interface ResidentForm extends BaseEntity {
|
|||||||
/**
|
/**
|
||||||
* 主键 住户管理id
|
* 主键 住户管理id
|
||||||
*/
|
*/
|
||||||
id?: string | number;
|
userId?: string | number;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 住户编号
|
* 住户编号
|
||||||
|
|||||||
@@ -179,7 +179,10 @@
|
|||||||
.el-input-number__decrease,
|
.el-input-number__decrease,
|
||||||
.el-input-number__increase {
|
.el-input-number__increase {
|
||||||
border-radius: var(--app-radius-md);
|
border-radius: var(--app-radius-md);
|
||||||
transition: box-shadow 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
|
transition:
|
||||||
|
box-shadow 0.2s ease,
|
||||||
|
border-color 0.2s ease,
|
||||||
|
background-color 0.2s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-input__wrapper.is-focus,
|
.el-input__wrapper.is-focus,
|
||||||
@@ -192,8 +195,14 @@
|
|||||||
|
|
||||||
// Buttons
|
// Buttons
|
||||||
.el-button {
|
.el-button {
|
||||||
|
width: 80px;
|
||||||
|
height: 35px;
|
||||||
border-radius: var(--app-radius-md);
|
border-radius: var(--app-radius-md);
|
||||||
transition: transform 0.15s ease, box-shadow 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
|
transition:
|
||||||
|
transform 0.15s ease,
|
||||||
|
box-shadow 0.2s ease,
|
||||||
|
background-color 0.2s ease,
|
||||||
|
border-color 0.2s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-button:not(.is-text):not(.is-link):hover {
|
.el-button:not(.is-text):not(.is-link):hover {
|
||||||
@@ -261,7 +270,10 @@
|
|||||||
.el-pagination .btn-next,
|
.el-pagination .btn-next,
|
||||||
.el-pagination .el-pager li {
|
.el-pagination .el-pager li {
|
||||||
border-radius: var(--app-radius-sm);
|
border-radius: var(--app-radius-sm);
|
||||||
transition: background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
|
transition:
|
||||||
|
background-color 0.2s ease,
|
||||||
|
color 0.2s ease,
|
||||||
|
box-shadow 0.2s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-pagination .el-pager li.is-active {
|
.el-pagination .el-pager li.is-active {
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div v-else class="overflow-auto overflow-hidden w-full text-ellipsis text-nowrap">
|
<div v-else class="overflow-auto overflow-hidden w-full text-ellipsis text-nowrap">
|
||||||
<span>姓名:{{ multipleSelection[0] && multipleSelection[0].nickName }}</span>
|
<span>姓名:{{ multipleSelection[0] && multipleSelection[0].nickName }}</span>
|
||||||
<span class="ml-20px">联系方式:{{ multipleSelection[0] && multipleSelection[0].phonenumber }}</span>
|
<span v-show="multipleSelection[0] && multipleSelection[0].phonenumber" class="ml-20px">联系方式:{{ multipleSelection[0].phonenumber }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -67,9 +67,16 @@ interface tableType extends ResidentVO {
|
|||||||
housePath?: string;
|
housePath?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
const props = defineProps<{
|
const props = defineProps({
|
||||||
userid: string | number;
|
userid: {
|
||||||
}>();
|
type: String || Number
|
||||||
|
},
|
||||||
|
returnvalue: {
|
||||||
|
type: String,
|
||||||
|
default: 'id',
|
||||||
|
required: true
|
||||||
|
}
|
||||||
|
});
|
||||||
const { userid } = toRefs(props);
|
const { userid } = toRefs(props);
|
||||||
const emit = defineEmits<{
|
const emit = defineEmits<{
|
||||||
change: [value: string | number];
|
change: [value: string | number];
|
||||||
@@ -113,8 +120,9 @@ const handleRowClick = (row) => {
|
|||||||
// 统一回显 userid 选中(安全版)
|
// 统一回显 userid 选中(安全版)
|
||||||
const handleUserSelection = () => {
|
const handleUserSelection = () => {
|
||||||
if (!userid.value || !tableData.value.length) return;
|
if (!userid.value || !tableData.value.length) return;
|
||||||
|
console.log('user', userid, tableData.value);
|
||||||
|
|
||||||
const target = tableData.value.find((item) => item.id == userid.value);
|
const target = tableData.value.find((item) => item.userId == userid.value);
|
||||||
if (target) {
|
if (target) {
|
||||||
multipleSelection.value = [target];
|
multipleSelection.value = [target];
|
||||||
nextTick(() => {
|
nextTick(() => {
|
||||||
@@ -172,7 +180,11 @@ function conback() {
|
|||||||
function confim() {
|
function confim() {
|
||||||
dialog.value.dialogVisible = false;
|
dialog.value.dialogVisible = false;
|
||||||
if (multipleSelection.value.length > 0) {
|
if (multipleSelection.value.length > 0) {
|
||||||
emit('change', multipleSelection.value[0].id);
|
if (props.returnvalue === 'id') {
|
||||||
|
emit('change', multipleSelection.value[0].id);
|
||||||
|
} else if (props.returnvalue === 'value') {
|
||||||
|
emit('change', multipleSelection.value[0]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
125
src/views/system/Activity/addActivity.vue
Normal file
125
src/views/system/Activity/addActivity.vue
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
<template>
|
||||||
|
<div class="ResidentMainBox p-2 w-full">
|
||||||
|
<PageHeader title="投诉类型"></PageHeader>
|
||||||
|
<div class="ResidentMainBody">
|
||||||
|
<el-card>
|
||||||
|
<template #header>
|
||||||
|
<div class="title">基本信息</div>
|
||||||
|
</template>
|
||||||
|
<div class="addBuildingFormBody">
|
||||||
|
<div class="formbox">
|
||||||
|
<el-form ref="formRef" :model="form" :rules="rules" label-width="120px">
|
||||||
|
<el-form-item label="投诉类型名称" prop="name">
|
||||||
|
<el-input v-model.trim="form.name" placeholder="请输入投诉类型名称" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="投诉类型状态" prop="status">
|
||||||
|
<el-radio-group v-model="form.status">
|
||||||
|
<el-radio v-for="(item, index) in com_repair_project_status" :key="index" :value="item.value">{{ item.label }}</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" @click="submitForm">提交</el-button>
|
||||||
|
<el-button @click="handleBack">返回</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { ref } from 'vue';
|
||||||
|
import PageHeader from '@/components/Pageheader/index.vue';
|
||||||
|
import { addComplaintType, getComplaintType, updateComplaintType } from '@/api/system/ComplainType';
|
||||||
|
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||||
|
const { com_repair_project_status } = toRefs<any>(proxy?.useDict('com_repair_project_status'));
|
||||||
|
|
||||||
|
const route = useRoute();
|
||||||
|
const router = useRouter();
|
||||||
|
const formRef = ref();
|
||||||
|
const form = ref({
|
||||||
|
'id': null,
|
||||||
|
'name': '',
|
||||||
|
'status': '0'
|
||||||
|
});
|
||||||
|
const rules = {
|
||||||
|
name: [{ required: true, message: '请输入投诉类型名称', trigger: 'blur' }]
|
||||||
|
};
|
||||||
|
const userid = ref();
|
||||||
|
|
||||||
|
// ! 投诉 ====================================================================================================
|
||||||
|
function init() {
|
||||||
|
getComplaintType(userid.value).then((res) => {
|
||||||
|
form.value = {
|
||||||
|
...form.value,
|
||||||
|
...res.data
|
||||||
|
};
|
||||||
|
console.log(form.value);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
if (route.query.id) {
|
||||||
|
userid.value = route.query.id;
|
||||||
|
init();
|
||||||
|
}
|
||||||
|
|
||||||
|
// 提交
|
||||||
|
const submitForm = () => {
|
||||||
|
formRef.value?.validate(async (valid: boolean) => {
|
||||||
|
if (valid) {
|
||||||
|
if (userid.value) {
|
||||||
|
updateComplaintType(form.value).then(() => {
|
||||||
|
ElMessage.success('编辑成功');
|
||||||
|
handleBack();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
addComplaintType(form.value).then(() => {
|
||||||
|
ElMessage.success('添加成功');
|
||||||
|
handleBack();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
// 返回
|
||||||
|
function handleBack() {
|
||||||
|
router.push({
|
||||||
|
path: '/repair/complaintType'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped lang="scss">
|
||||||
|
.ResidentMainBox {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
.ResidentMainBody {
|
||||||
|
margin-top: 20px;
|
||||||
|
flex: 1;
|
||||||
|
|
||||||
|
.formbox {
|
||||||
|
width: 500px;
|
||||||
|
margin: 0 auto;
|
||||||
|
}
|
||||||
|
&:deep(div.el-step__head.is-process) {
|
||||||
|
& > div.el-step__line {
|
||||||
|
width: 0;
|
||||||
|
border: 1px dashed gray;
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
&:deep(.el-step.is-vertical .el-step__line) {
|
||||||
|
top: 20px;
|
||||||
|
}
|
||||||
|
&:deep(div.el-step__head.is-finish) {
|
||||||
|
& > div.el-step__line {
|
||||||
|
width: 0;
|
||||||
|
border: 1px solid var(--el-color-primary);
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
217
src/views/system/Activity/index.vue
Normal file
217
src/views/system/Activity/index.vue
Normal file
@@ -0,0 +1,217 @@
|
|||||||
|
<template>
|
||||||
|
<div class="flex flex-col h-full p-2">
|
||||||
|
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||||
|
<div v-show="showSearch" class="mb-[10px]">
|
||||||
|
<el-card shadow="hover">
|
||||||
|
<el-form ref="queryFormRef" :model="queryParams" :inline="true">
|
||||||
|
<el-form-item label="标题" prop="titile">
|
||||||
|
<el-input v-model="queryParams.titile" placeholder="请输入标题" clearable @keyup.enter="handleQuery" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
|
||||||
|
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</transition>
|
||||||
|
|
||||||
|
<el-card class="flex-1" shadow="never">
|
||||||
|
<template #header>
|
||||||
|
<el-row :gutter="10" class="mb8">
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button type="primary" plain icon="Plus" @click="handleAdd" v-hasPermi="['activity:activity:add']">新增</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button type="success" plain icon="Edit" :disabled="single" @click="handleUpdate()" v-hasPermi="['activity:activity:edit']"
|
||||||
|
>修改</el-button
|
||||||
|
>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button type="danger" plain icon="Delete" :disabled="multiple" @click="handleDelete()" v-hasPermi="['activity:activity:remove']"
|
||||||
|
>删除</el-button
|
||||||
|
>
|
||||||
|
</el-col>
|
||||||
|
<right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
|
||||||
|
</el-row>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<el-table v-loading="loading" border :data="activityList" @selection-change="handleSelectionChange">
|
||||||
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
|
<el-table-column label="标题" align="center" prop="titile" />
|
||||||
|
<el-table-column label="作者" align="center" prop="author" />
|
||||||
|
<el-table-column label="发布状态 0未发布 1已发布" align="center" prop="status" />
|
||||||
|
<el-table-column label="浏览量" align="center" prop="pageViews" />
|
||||||
|
<el-table-column label="发布人" align="center" prop="createName" />
|
||||||
|
<el-table-column label="操作" align="center" fixed="right" class-name="small-padding fixed-width">
|
||||||
|
<template #default="scope">
|
||||||
|
<el-tooltip content="修改" placement="top">
|
||||||
|
<el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['activity:activity:edit']"></el-button>
|
||||||
|
</el-tooltip>
|
||||||
|
<el-tooltip content="删除" placement="top">
|
||||||
|
<el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['activity:activity:remove']"></el-button>
|
||||||
|
</el-tooltip>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
|
||||||
|
<pagination v-show="total > 0" :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize" @pagination="getList" />
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup name="Activity" lang="ts">
|
||||||
|
import { listActivity, getActivity, delActivity, addActivity, updateActivity } from '@/api/system/Activity/index';
|
||||||
|
import { ActivityVO, ActivityQuery, ActivityForm } from '@/api/system/Activity/type';
|
||||||
|
|
||||||
|
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||||
|
|
||||||
|
const activityList = ref<ActivityVO[]>([]);
|
||||||
|
const buttonLoading = ref(false);
|
||||||
|
const loading = ref(true);
|
||||||
|
const showSearch = ref(true);
|
||||||
|
const ids = ref<Array<string | number>>([]);
|
||||||
|
const single = ref(true);
|
||||||
|
const multiple = ref(true);
|
||||||
|
const total = ref(0);
|
||||||
|
|
||||||
|
const queryFormRef = ref<ElFormInstance>();
|
||||||
|
const activityFormRef = ref<ElFormInstance>();
|
||||||
|
|
||||||
|
const dialog = reactive<DialogOption>({
|
||||||
|
visible: false,
|
||||||
|
title: ''
|
||||||
|
});
|
||||||
|
|
||||||
|
const initFormData: ActivityForm = {
|
||||||
|
id: undefined,
|
||||||
|
titile: undefined,
|
||||||
|
author: undefined,
|
||||||
|
content: undefined,
|
||||||
|
status: undefined,
|
||||||
|
pageViews: undefined,
|
||||||
|
createName: undefined
|
||||||
|
};
|
||||||
|
const data = reactive<PageData<ActivityForm, ActivityQuery>>({
|
||||||
|
form: { ...initFormData },
|
||||||
|
queryParams: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
titile: undefined,
|
||||||
|
author: undefined,
|
||||||
|
content: undefined,
|
||||||
|
status: undefined,
|
||||||
|
pageViews: undefined,
|
||||||
|
createName: undefined,
|
||||||
|
params: {}
|
||||||
|
},
|
||||||
|
rules: {
|
||||||
|
id: [{ required: true, message: '活动管理表id不能为空', trigger: 'blur' }]
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const { queryParams, form, rules } = toRefs(data);
|
||||||
|
|
||||||
|
/** 查询活动管理列表 */
|
||||||
|
const getList = async () => {
|
||||||
|
loading.value = true;
|
||||||
|
const res = await listActivity(queryParams.value);
|
||||||
|
activityList.value = res.rows;
|
||||||
|
total.value = res.total;
|
||||||
|
loading.value = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 取消按钮 */
|
||||||
|
const cancel = () => {
|
||||||
|
reset();
|
||||||
|
dialog.visible = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 表单重置 */
|
||||||
|
const reset = () => {
|
||||||
|
form.value = { ...initFormData };
|
||||||
|
activityFormRef.value?.resetFields();
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
const handleQuery = () => {
|
||||||
|
queryParams.value.pageNum = 1;
|
||||||
|
getList();
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 重置按钮操作 */
|
||||||
|
const resetQuery = () => {
|
||||||
|
queryFormRef.value?.resetFields();
|
||||||
|
handleQuery();
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 多选框选中数据 */
|
||||||
|
const handleSelectionChange = (selection: ActivityVO[]) => {
|
||||||
|
ids.value = selection.map((item) => item.id);
|
||||||
|
single.value = selection.length != 1;
|
||||||
|
multiple.value = !selection.length;
|
||||||
|
};
|
||||||
|
const router = useRouter();
|
||||||
|
/** 新增按钮操作 */
|
||||||
|
const handleAdd = () => {
|
||||||
|
router.push({
|
||||||
|
path: '/repair/addActivity'
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 修改按钮操作 */
|
||||||
|
const handleUpdate = async (row?: ActivityVO) => {
|
||||||
|
router.push({
|
||||||
|
path: '/repair/addActivity',
|
||||||
|
query: {
|
||||||
|
id: row.id
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 提交按钮 */
|
||||||
|
const submitForm = () => {
|
||||||
|
activityFormRef.value?.validate(async (valid: boolean) => {
|
||||||
|
if (valid) {
|
||||||
|
buttonLoading.value = true;
|
||||||
|
if (form.value.id) {
|
||||||
|
await updateActivity(form.value).finally(() => (buttonLoading.value = false));
|
||||||
|
} else {
|
||||||
|
await addActivity(form.value).finally(() => (buttonLoading.value = false));
|
||||||
|
}
|
||||||
|
proxy?.$modal.msgSuccess('操作成功');
|
||||||
|
dialog.visible = false;
|
||||||
|
await getList();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 删除按钮操作 */
|
||||||
|
const handleDelete = async (row?: ActivityVO) => {
|
||||||
|
const _ids = row?.id || ids.value;
|
||||||
|
await proxy?.$modal.confirm('是否确认删除活动管理编号为"' + _ids + '"的数据项?').finally(() => (loading.value = false));
|
||||||
|
await delActivity(_ids);
|
||||||
|
proxy?.$modal.msgSuccess('删除成功');
|
||||||
|
await getList();
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 导出按钮操作 */
|
||||||
|
const handleExport = () => {
|
||||||
|
proxy?.download(
|
||||||
|
'activity/activity/export',
|
||||||
|
{
|
||||||
|
...queryParams.value
|
||||||
|
},
|
||||||
|
`activity_${new Date().getTime()}.xlsx`
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
getList();
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.el-table {
|
||||||
|
height: calc(100% - 80px);
|
||||||
|
}
|
||||||
|
</style>
|
||||||
206
src/views/system/Complaint/complainMain.vue
Normal file
206
src/views/system/Complaint/complainMain.vue
Normal file
@@ -0,0 +1,206 @@
|
|||||||
|
<template>
|
||||||
|
<div class="ResidentMainBox p-2 w-full">
|
||||||
|
<PageHeader title="投诉详情"></PageHeader>
|
||||||
|
<div class="ResidentMainBody">
|
||||||
|
<!-- 投诉信息 -->
|
||||||
|
<div class="mb-10">
|
||||||
|
<el-card>
|
||||||
|
<template #header>
|
||||||
|
<div class="card-header">
|
||||||
|
<span>投诉信息</span>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<div class="w-full h-full CarinfoBox">
|
||||||
|
<div class="carinfo_item">
|
||||||
|
<div class="label">投诉类型</div>
|
||||||
|
<div class="main">{{ form.type }}</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="carinfo_item">
|
||||||
|
<div class="label">问题描述</div>
|
||||||
|
<div class="main">{{ form.problemDes }}</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="carinfo_item">
|
||||||
|
<div class="label">投诉人姓名</div>
|
||||||
|
<div class="main">{{ form.complaintName }}</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="carinfo_item">
|
||||||
|
<div class="label">手机号码</div>
|
||||||
|
<div class="main">{{ form.phone }}</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="carinfo_item">
|
||||||
|
<div class="label">投诉时间</div>
|
||||||
|
<div class="main">{{ form.orderDate }}</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="carinfo_item">
|
||||||
|
<div class="label">处理状态</div>
|
||||||
|
<div class="main">
|
||||||
|
<DictTag :options="com_complaint_status" :value="form.status"></DictTag>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
<!-- 处理情况 -->
|
||||||
|
<div class="mb-10">
|
||||||
|
<el-card>
|
||||||
|
<template #header>
|
||||||
|
<div class="card-header">
|
||||||
|
<span>处理情况</span>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<div class="formbox">
|
||||||
|
<el-form ref="formRef" :rules="rules" class="m-auto" :inline="false" label-width="100px" :model="form">
|
||||||
|
<el-form-item label="处理状态" prop="status">
|
||||||
|
<el-radio-group v-model="form.status">
|
||||||
|
<el-radio v-for="(item, index) in com_complaint_status" :key="index" :value="item.value">{{ item.label }}</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="处理人员" prop="handleId">
|
||||||
|
<repairUser :userid="form.handleId" returnvalue="value" @change="handleChange"></repairUser>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="处理描述" prop="handleContent">
|
||||||
|
<el-input type="textarea" :rows="5" v-model="form.handleContent"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" @click="submitForm">提交</el-button>
|
||||||
|
<el-button @click="handleBack">返回</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { ref } from 'vue';
|
||||||
|
import repairUser from '@/components/Holder/repairUser.vue';
|
||||||
|
import PageHeader from '@/components/Pageheader/index.vue';
|
||||||
|
import { getComplaint, updateComplaint } from '@/api/system/Complaint';
|
||||||
|
import { listComplaintType } from '@/api/system/ComplainType';
|
||||||
|
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||||
|
const { com_complaint_status } = toRefs<any>(proxy?.useDict('com_complaint_status'));
|
||||||
|
|
||||||
|
const route = useRoute();
|
||||||
|
const router = useRouter();
|
||||||
|
|
||||||
|
const form = ref({
|
||||||
|
'id': null,
|
||||||
|
'type': '',
|
||||||
|
'typeId': null,
|
||||||
|
'problemDes': '',
|
||||||
|
'complaintName': '',
|
||||||
|
'phone': '',
|
||||||
|
'problemIamgeUrl': '',
|
||||||
|
'status': '1', // 投诉状态 0待处理 1已处理
|
||||||
|
'handleId': '',
|
||||||
|
'handleName': '',
|
||||||
|
'handleContent': ''
|
||||||
|
});
|
||||||
|
const rules = {
|
||||||
|
status: [{ required: true, message: '选择投诉处理状态', trigger: 'blur' }]
|
||||||
|
};
|
||||||
|
const userid = ref();
|
||||||
|
const complaintyTyplist = ref([]);
|
||||||
|
// ! 投诉 ====================================================================================================
|
||||||
|
async function init() {
|
||||||
|
const res2 = await listComplaintType();
|
||||||
|
getComplaint(userid.value).then((res) => {
|
||||||
|
form.value = {
|
||||||
|
...form.value,
|
||||||
|
...res.data
|
||||||
|
};
|
||||||
|
console.log(form.value);
|
||||||
|
const find = res2.rows.find((item) => item.id === form.value.typeId);
|
||||||
|
if (find) {
|
||||||
|
form.value.type = find.name;
|
||||||
|
}
|
||||||
|
console.log(form.value);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
if (route.query.id) {
|
||||||
|
userid.value = route.query.id;
|
||||||
|
init();
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleChange(pop) {
|
||||||
|
form.value.handleId = pop.userId;
|
||||||
|
form.value.handleName = pop.nickName;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 提交
|
||||||
|
|
||||||
|
const formRef = ref();
|
||||||
|
const submitForm = () => {
|
||||||
|
formRef.value?.validate(async (valid: boolean) => {
|
||||||
|
if (valid) {
|
||||||
|
if (userid.value) {
|
||||||
|
updateComplaint(form.value).then(() => {
|
||||||
|
ElMessage.success('编辑成功');
|
||||||
|
handleBack();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
// 返回
|
||||||
|
function handleBack() {
|
||||||
|
router.push({
|
||||||
|
path: '/repair/complaint'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped lang="scss">
|
||||||
|
.ResidentMainBox {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
.ResidentMainBody {
|
||||||
|
margin-top: 20px;
|
||||||
|
flex: 1;
|
||||||
|
|
||||||
|
.CarinfoBox {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(3, 1fr);
|
||||||
|
grid-template-rows: repeat(2, 1fr);
|
||||||
|
gap: 20px;
|
||||||
|
.carinfo_item {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
.label {
|
||||||
|
margin-right: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.formbox {
|
||||||
|
width: 500px;
|
||||||
|
margin: 0 auto;
|
||||||
|
}
|
||||||
|
&:deep(div.el-step__head.is-process) {
|
||||||
|
& > div.el-step__line {
|
||||||
|
width: 0;
|
||||||
|
border: 1px dashed gray;
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
&:deep(.el-step.is-vertical .el-step__line) {
|
||||||
|
top: 20px;
|
||||||
|
}
|
||||||
|
&:deep(div.el-step__head.is-finish) {
|
||||||
|
& > div.el-step__line {
|
||||||
|
width: 0;
|
||||||
|
border: 1px solid var(--el-color-primary);
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
196
src/views/system/Complaint/index.vue
Normal file
196
src/views/system/Complaint/index.vue
Normal file
@@ -0,0 +1,196 @@
|
|||||||
|
<template>
|
||||||
|
<div class="h-full p-2 flex flex-col">
|
||||||
|
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||||
|
<div v-show="showSearch" class="mb-[10px]">
|
||||||
|
<el-card shadow="hover">
|
||||||
|
<el-form ref="queryFormRef" label-width="120px" :model="queryParams" :inline="true">
|
||||||
|
<el-form-item label="投诉类型" prop="typeId">
|
||||||
|
<el-select v-model="queryParams.typeId" placeholder="请选择投诉类型" style="width: 240px">
|
||||||
|
<el-option :disabled="item.status === '1'" v-for="item in complaintyTyplist" :key="item.id" :label="item.name" :value="item.id" />
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="投诉人姓名" prop="complaintName">
|
||||||
|
<el-input v-model="queryParams.complaintName" placeholder="请输入投诉人姓名" clearable @keyup.enter="handleQuery" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
|
||||||
|
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</transition>
|
||||||
|
|
||||||
|
<el-card class="flex-1" shadow="never">
|
||||||
|
<el-table v-loading="loading" border :data="complaintList" @selection-change="handleSelectionChange">
|
||||||
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
|
<el-table-column label="投诉类型" align="center" prop="typeId" />
|
||||||
|
<el-table-column label="投诉状态" align="center" prop="status">
|
||||||
|
<template #default="scope">
|
||||||
|
<dict-tag :options="com_complaint_status" :value="scope.row.status"></dict-tag>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="问题描述" align="center" prop="problemDes" />
|
||||||
|
<el-table-column label="投诉人姓名" align="center" prop="complaintName" />
|
||||||
|
<el-table-column label="手机号" align="center" prop="phone" />
|
||||||
|
<el-table-column label="操作" align="center" fixed="right" class-name="small-padding fixed-width">
|
||||||
|
<template #default="scope">
|
||||||
|
<el-button link type="primary" @click="handleUpdate(scope.row)" v-hasPermi="['complaint:complaint:edit']">查看详情</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
|
||||||
|
<pagination v-show="total > 0" :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize" @pagination="getList" />
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<!-- complaint -->
|
||||||
|
<script setup name="Complaint" lang="ts">
|
||||||
|
import { listComplaint, getComplaint, delComplaint, addComplaint, updateComplaint } from '@/api/system/Complaint/index';
|
||||||
|
import { ComplaintVO, ComplaintQuery, ComplaintForm } from '@/api/system/Complaint/type';
|
||||||
|
import { listComplaintType } from '@/api/system/ComplainType';
|
||||||
|
|
||||||
|
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||||
|
const { com_complaint_status } = toRefs<any>(proxy?.useDict('com_complaint_status'));
|
||||||
|
|
||||||
|
const complaintList = ref<ComplaintVO[]>([]);
|
||||||
|
const buttonLoading = ref(false);
|
||||||
|
const loading = ref(true);
|
||||||
|
const showSearch = ref(true);
|
||||||
|
const ids = ref<Array<string | number>>([]);
|
||||||
|
const single = ref(true);
|
||||||
|
const multiple = ref(true);
|
||||||
|
const total = ref(0);
|
||||||
|
|
||||||
|
const queryFormRef = ref<ElFormInstance>();
|
||||||
|
const complaintFormRef = ref<ElFormInstance>();
|
||||||
|
|
||||||
|
const dialog = reactive<DialogOption>({
|
||||||
|
visible: false,
|
||||||
|
title: ''
|
||||||
|
});
|
||||||
|
|
||||||
|
const initFormData: ComplaintForm = {
|
||||||
|
id: undefined,
|
||||||
|
typeId: undefined,
|
||||||
|
problemDes: undefined,
|
||||||
|
complaintName: undefined,
|
||||||
|
phone: undefined,
|
||||||
|
problemIamgeUrl: undefined,
|
||||||
|
status: undefined,
|
||||||
|
handleId: undefined,
|
||||||
|
handleName: undefined,
|
||||||
|
handleContent: undefined
|
||||||
|
};
|
||||||
|
const data = reactive<PageData<ComplaintForm, ComplaintQuery>>({
|
||||||
|
form: { ...initFormData },
|
||||||
|
queryParams: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
typeId: undefined,
|
||||||
|
problemDes: undefined,
|
||||||
|
complaintName: undefined,
|
||||||
|
phone: undefined,
|
||||||
|
problemIamgeUrl: undefined,
|
||||||
|
status: undefined,
|
||||||
|
handleId: undefined,
|
||||||
|
handleName: undefined,
|
||||||
|
handleContent: undefined,
|
||||||
|
params: {}
|
||||||
|
},
|
||||||
|
rules: {
|
||||||
|
id: [{ required: true, message: '投诉管理表id不能为空', trigger: 'blur' }]
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const { queryParams, form, rules } = toRefs(data);
|
||||||
|
|
||||||
|
const complaintyTyplist = ref([]);
|
||||||
|
/** 查询投诉管理列表 */
|
||||||
|
const getList = async () => {
|
||||||
|
loading.value = true;
|
||||||
|
const res2 = await listComplaintType();
|
||||||
|
complaintyTyplist.value = res2.rows;
|
||||||
|
const res = await listComplaint(queryParams.value);
|
||||||
|
complaintList.value = res.rows;
|
||||||
|
total.value = res.total;
|
||||||
|
loading.value = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
const handleQuery = () => {
|
||||||
|
queryParams.value.pageNum = 1;
|
||||||
|
getList();
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 重置按钮操作 */
|
||||||
|
const resetQuery = () => {
|
||||||
|
queryFormRef.value?.resetFields();
|
||||||
|
handleQuery();
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 多选框选中数据 */
|
||||||
|
const handleSelectionChange = (selection: ComplaintVO[]) => {
|
||||||
|
ids.value = selection.map((item) => item.id);
|
||||||
|
single.value = selection.length != 1;
|
||||||
|
multiple.value = !selection.length;
|
||||||
|
};
|
||||||
|
|
||||||
|
const router = useRouter();
|
||||||
|
/** 详情按钮操作 */
|
||||||
|
const handleUpdate = async (row?: ComplaintVO) => {
|
||||||
|
router.push({
|
||||||
|
path: '/repair/complainMain',
|
||||||
|
query: {
|
||||||
|
id: row.id
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 提交按钮 */
|
||||||
|
const submitForm = () => {
|
||||||
|
complaintFormRef.value?.validate(async (valid: boolean) => {
|
||||||
|
if (valid) {
|
||||||
|
buttonLoading.value = true;
|
||||||
|
if (form.value.id) {
|
||||||
|
await updateComplaint(form.value).finally(() => (buttonLoading.value = false));
|
||||||
|
} else {
|
||||||
|
await addComplaint(form.value).finally(() => (buttonLoading.value = false));
|
||||||
|
}
|
||||||
|
proxy?.$modal.msgSuccess('操作成功');
|
||||||
|
dialog.visible = false;
|
||||||
|
await getList();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 删除按钮操作 */
|
||||||
|
const handleDelete = async (row?: ComplaintVO) => {
|
||||||
|
const _ids = row?.id || ids.value;
|
||||||
|
await proxy?.$modal.confirm('是否确认删除投诉管理编号为"' + _ids + '"的数据项?').finally(() => (loading.value = false));
|
||||||
|
await delComplaint(_ids);
|
||||||
|
proxy?.$modal.msgSuccess('删除成功');
|
||||||
|
await getList();
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 导出按钮操作 */
|
||||||
|
const handleExport = () => {
|
||||||
|
proxy?.download(
|
||||||
|
'complaint/complaint/export',
|
||||||
|
{
|
||||||
|
...queryParams.value
|
||||||
|
},
|
||||||
|
`complaint_${new Date().getTime()}.xlsx`
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
getList();
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.el-table {
|
||||||
|
height: calc(100% - 80px);
|
||||||
|
}
|
||||||
|
</style>
|
||||||
125
src/views/system/ComplaintType/addComplaintType.vue
Normal file
125
src/views/system/ComplaintType/addComplaintType.vue
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
<template>
|
||||||
|
<div class="ResidentMainBox p-2 w-full">
|
||||||
|
<PageHeader title="投诉类型"></PageHeader>
|
||||||
|
<div class="ResidentMainBody">
|
||||||
|
<el-card>
|
||||||
|
<template #header>
|
||||||
|
<div class="title">基本信息</div>
|
||||||
|
</template>
|
||||||
|
<div class="addBuildingFormBody">
|
||||||
|
<div class="formbox">
|
||||||
|
<el-form ref="formRef" :model="form" :rules="rules" label-width="120px">
|
||||||
|
<el-form-item label="投诉类型名称" prop="name">
|
||||||
|
<el-input v-model.trim="form.name" placeholder="请输入投诉类型名称" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="投诉类型状态" prop="status">
|
||||||
|
<el-radio-group v-model="form.status">
|
||||||
|
<el-radio v-for="(item, index) in com_repair_project_status" :key="index" :value="item.value">{{ item.label }}</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" @click="submitForm">提交</el-button>
|
||||||
|
<el-button @click="handleBack">返回</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { ref } from 'vue';
|
||||||
|
import PageHeader from '@/components/Pageheader/index.vue';
|
||||||
|
import { addComplaintType, getComplaintType, updateComplaintType } from '@/api/system/ComplainType';
|
||||||
|
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||||
|
const { com_repair_project_status } = toRefs<any>(proxy?.useDict('com_repair_project_status'));
|
||||||
|
|
||||||
|
const route = useRoute();
|
||||||
|
const router = useRouter();
|
||||||
|
const formRef = ref();
|
||||||
|
const form = ref({
|
||||||
|
'id': null,
|
||||||
|
'name': '',
|
||||||
|
'status': '0'
|
||||||
|
});
|
||||||
|
const rules = {
|
||||||
|
name: [{ required: true, message: '请输入投诉类型名称', trigger: 'blur' }]
|
||||||
|
};
|
||||||
|
const userid = ref();
|
||||||
|
|
||||||
|
// ! 投诉 ====================================================================================================
|
||||||
|
function init() {
|
||||||
|
getComplaintType(userid.value).then((res) => {
|
||||||
|
form.value = {
|
||||||
|
...form.value,
|
||||||
|
...res.data
|
||||||
|
};
|
||||||
|
console.log(form.value);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
if (route.query.id) {
|
||||||
|
userid.value = route.query.id;
|
||||||
|
init();
|
||||||
|
}
|
||||||
|
|
||||||
|
// 提交
|
||||||
|
const submitForm = () => {
|
||||||
|
formRef.value?.validate(async (valid: boolean) => {
|
||||||
|
if (valid) {
|
||||||
|
if (userid.value) {
|
||||||
|
updateComplaintType(form.value).then(() => {
|
||||||
|
ElMessage.success('编辑成功');
|
||||||
|
handleBack();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
addComplaintType(form.value).then(() => {
|
||||||
|
ElMessage.success('添加成功');
|
||||||
|
handleBack();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
// 返回
|
||||||
|
function handleBack() {
|
||||||
|
router.push({
|
||||||
|
path: '/repair/complaintType'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped lang="scss">
|
||||||
|
.ResidentMainBox {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
.ResidentMainBody {
|
||||||
|
margin-top: 20px;
|
||||||
|
flex: 1;
|
||||||
|
|
||||||
|
.formbox {
|
||||||
|
width: 500px;
|
||||||
|
margin: 0 auto;
|
||||||
|
}
|
||||||
|
&:deep(div.el-step__head.is-process) {
|
||||||
|
& > div.el-step__line {
|
||||||
|
width: 0;
|
||||||
|
border: 1px dashed gray;
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
&:deep(.el-step.is-vertical .el-step__line) {
|
||||||
|
top: 20px;
|
||||||
|
}
|
||||||
|
&:deep(div.el-step__head.is-finish) {
|
||||||
|
& > div.el-step__line {
|
||||||
|
width: 0;
|
||||||
|
border: 1px solid var(--el-color-primary);
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
172
src/views/system/ComplaintType/index.vue
Normal file
172
src/views/system/ComplaintType/index.vue
Normal file
@@ -0,0 +1,172 @@
|
|||||||
|
<template>
|
||||||
|
<div class="p-2">
|
||||||
|
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||||
|
<div v-show="showSearch" class="mb-[10px]">
|
||||||
|
<el-card shadow="hover">
|
||||||
|
<el-form ref="queryFormRef" label-width="100px" :model="queryParams" :inline="true">
|
||||||
|
<el-form-item label="投诉类型名称" prop="name">
|
||||||
|
<el-input v-model="queryParams.name" placeholder="请输入投诉类型名称" clearable @keyup.enter="handleQuery" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
|
||||||
|
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</transition>
|
||||||
|
|
||||||
|
<el-card shadow="never">
|
||||||
|
<template #header>
|
||||||
|
<el-row :gutter="10" class="mb8">
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button type="primary" plain icon="Plus" @click="handleAdd" v-hasPermi="['complaintType:complaintType:add']">新增</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button type="success" plain icon="Edit" :disabled="single" @click="handleUpdate()" v-hasPermi="['complaintType:complaintType:edit']"
|
||||||
|
>修改</el-button
|
||||||
|
>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="danger"
|
||||||
|
plain
|
||||||
|
icon="Delete"
|
||||||
|
:disabled="multiple"
|
||||||
|
@click="handleDelete()"
|
||||||
|
v-hasPermi="['complaintType:complaintType:remove']"
|
||||||
|
>删除</el-button
|
||||||
|
>
|
||||||
|
</el-col>
|
||||||
|
<right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
|
||||||
|
</el-row>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<el-table v-loading="loading" border :data="complaintTypeList" @selection-change="handleSelectionChange">
|
||||||
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
|
<el-table-column label="投诉类型名称" align="center" prop="name" />
|
||||||
|
<el-table-column label="状态" align="center" prop="status">
|
||||||
|
<template #default="scope">
|
||||||
|
<dict-tag :options="com_repair_project_status" :value="scope.row.status"></dict-tag>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="创建时间" align="center" prop="creaateTime" width="180">
|
||||||
|
<template #default="scope">
|
||||||
|
<span>{{ parseTime(scope.row.creaateTime, '{y}-{m}-{d}') }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="操作" align="center" fixed="right" class-name="small-padding fixed-width">
|
||||||
|
<template #default="scope">
|
||||||
|
<el-button link type="primary" @click="handleUpdate(scope.row)" v-hasPermi="['complaintType:complaintType:edit']">修改</el-button>
|
||||||
|
<el-button link type="primary" @click="handleDelete(scope.row)" v-hasPermi="['complaintType:complaintType:remove']">删除</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
|
||||||
|
<pagination v-show="total > 0" :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize" @pagination="getList" />
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup name="ComplaintType" lang="ts">
|
||||||
|
import { listComplaintType, getComplaintType, delComplaintType, addComplaintType, updateComplaintType } from '@/api/system/ComplainType/index';
|
||||||
|
import { ComplaintTypeVO, ComplaintTypeQuery, ComplaintTypeForm } from '@/api/system/ComplainType/type';
|
||||||
|
|
||||||
|
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||||
|
const { com_repair_project_status } = toRefs<any>(proxy?.useDict('com_repair_project_status'));
|
||||||
|
|
||||||
|
const complaintTypeList = ref<ComplaintTypeVO[]>([]);
|
||||||
|
const buttonLoading = ref(false);
|
||||||
|
const loading = ref(true);
|
||||||
|
const showSearch = ref(true);
|
||||||
|
const ids = ref<Array<string | number>>([]);
|
||||||
|
const single = ref(true);
|
||||||
|
const multiple = ref(true);
|
||||||
|
const total = ref(0);
|
||||||
|
|
||||||
|
const queryFormRef = ref<ElFormInstance>();
|
||||||
|
|
||||||
|
const initFormData: ComplaintTypeForm = {
|
||||||
|
id: undefined,
|
||||||
|
name: undefined,
|
||||||
|
status: undefined,
|
||||||
|
createNam: undefined,
|
||||||
|
creaateTime: undefined
|
||||||
|
};
|
||||||
|
const data = reactive<PageData<ComplaintTypeForm, ComplaintTypeQuery>>({
|
||||||
|
form: { ...initFormData },
|
||||||
|
queryParams: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
name: undefined,
|
||||||
|
status: undefined,
|
||||||
|
createNam: undefined,
|
||||||
|
creaateTime: undefined,
|
||||||
|
params: {}
|
||||||
|
},
|
||||||
|
rules: {
|
||||||
|
id: [{ required: true, message: '投诉类型管理表id不能为空', trigger: 'blur' }]
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const { queryParams, form, rules } = toRefs(data);
|
||||||
|
|
||||||
|
/** 查询投诉类型管理列表 */
|
||||||
|
const getList = async () => {
|
||||||
|
loading.value = true;
|
||||||
|
const res = await listComplaintType(queryParams.value);
|
||||||
|
complaintTypeList.value = res.rows;
|
||||||
|
total.value = res.total;
|
||||||
|
loading.value = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
const handleQuery = () => {
|
||||||
|
queryParams.value.pageNum = 1;
|
||||||
|
getList();
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 重置按钮操作 */
|
||||||
|
const resetQuery = () => {
|
||||||
|
queryFormRef.value?.resetFields();
|
||||||
|
handleQuery();
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 多选框选中数据 */
|
||||||
|
const handleSelectionChange = (selection: ComplaintTypeVO[]) => {
|
||||||
|
ids.value = selection.map((item) => item.id);
|
||||||
|
single.value = selection.length != 1;
|
||||||
|
multiple.value = !selection.length;
|
||||||
|
};
|
||||||
|
const router = useRouter();
|
||||||
|
|
||||||
|
/** 新增按钮操作 */
|
||||||
|
const handleAdd = () => {
|
||||||
|
router.push({
|
||||||
|
path: '/repair/addComplantType'
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 修改按钮操作 */
|
||||||
|
const handleUpdate = async (row?: ComplaintTypeVO) => {
|
||||||
|
router.push({
|
||||||
|
path: '/repair/addComplantType',
|
||||||
|
query: {
|
||||||
|
id: row.id
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
/** 删除按钮操作 */
|
||||||
|
const handleDelete = async (row?: ComplaintTypeVO) => {
|
||||||
|
const _ids = row?.id || ids.value;
|
||||||
|
await proxy?.$modal.confirm('是否确认删除投诉类型管理编号为"' + _ids + '"的数据项?').finally(() => (loading.value = false));
|
||||||
|
await delComplaintType(_ids);
|
||||||
|
proxy?.$modal.msgSuccess('删除成功');
|
||||||
|
await getList();
|
||||||
|
};
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
getList();
|
||||||
|
});
|
||||||
|
</script>
|
||||||
@@ -65,11 +65,11 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="数据源" align="center" prop="dataName" :show-overflow-tooltip="true" />
|
<el-table-column label="数据源" align="center" prop="dataName" :show-overflow-tooltip="true" />
|
||||||
<el-table-column label="表名称" align="center" prop="tableName" :show-overflow-tooltip="true" />
|
<el-table-column label="表名称" align="center" prop="tableName" :show-overflow-tooltip="true" />
|
||||||
<el-table-column label="表描述" align="center" prop="tableComment" :show-overflow-tooltip="true" />
|
<el-table-column label="表描述" width="150" align="center" prop="tableComment" :show-overflow-tooltip="true" />
|
||||||
<el-table-column label="实体" align="center" prop="className" :show-overflow-tooltip="true" />
|
<el-table-column label="实体" width="150" align="center" prop="className" :show-overflow-tooltip="true" />
|
||||||
<el-table-column label="创建时间" align="center" prop="createTime" width="160" />
|
<el-table-column label="创建时间" align="center" prop="createTime" />
|
||||||
<el-table-column label="更新时间" align="center" prop="updateTime" width="160" />
|
<el-table-column label="更新时间" align="center" prop="updateTime" />
|
||||||
<el-table-column label="操作" align="center" width="330" class-name="small-padding fixed-width">
|
<el-table-column label="操作" align="center" width="400" class-name="small-padding fixed-width">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tooltip content="预览" placement="top">
|
<el-tooltip content="预览" placement="top">
|
||||||
<el-button v-hasPermi="['tool:gen:preview']" link type="primary" icon="View" @click="handlePreview(scope.row)"></el-button>
|
<el-button v-hasPermi="['tool:gen:preview']" link type="primary" icon="View" @click="handlePreview(scope.row)"></el-button>
|
||||||
|
|||||||
Reference in New Issue
Block a user