feedback.ts 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. import { http } from '@/utils/http/axios';
  2. export enum STATUS {
  3. handled = 1,
  4. unhandled = 2,
  5. }
  6. export interface Records {
  7. id: number;
  8. nickname: string;
  9. username: string;
  10. tenantId: number;
  11. mobile: string;
  12. problemDescription: string;
  13. problemImage: Array<File>;
  14. problemStatus: STATUS;
  15. processor: string | null;
  16. processorTenant: string | null;
  17. dealMethod: string | null;
  18. createdAt: string;
  19. updatedAt: string;
  20. isDeleted: number;
  21. }
  22. export interface ReturnType {
  23. records: Records[];
  24. pageNumber: number;
  25. pageSize: number;
  26. totalPage: number;
  27. totalRow: number;
  28. }
  29. export interface QueryFeedback {
  30. pageNumber: number;
  31. pageSize: number;
  32. problemDescription?: string;
  33. problemStatus: STATUS;
  34. }
  35. //查询问题反馈列表
  36. export const getFeedbackList = (data: QueryFeedback) => {
  37. return http.request<ReturnType>({
  38. url: `/problemFeedback/getProblemPage`,
  39. method: 'post',
  40. data,
  41. });
  42. };
  43. export interface UpdateFeedbackType {
  44. id: number;
  45. problemStatus: STATUS;
  46. processor: string;
  47. dealMethod: string;
  48. }
  49. //更新问题反馈
  50. export const updateFeedback = (data: UpdateFeedbackType) => {
  51. return http.request({
  52. url: `/problemFeedback/updateProblem`,
  53. method: 'post',
  54. data,
  55. });
  56. };