完成投诉管理
This commit is contained in:
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;
|
||||
}
|
||||
Reference in New Issue
Block a user