server.js 695 B

12345678910111213141516171819202122232425262728293031
  1. import { creatRequest } from '../../utils/request.js';
  2. const requestList = {
  3. // 一键查核
  4. oneKeyCheck: {
  5. method: 'POST',
  6. url: 'checkTask/saveBatchCheckTaskDetail'
  7. },
  8. // 列表一键不适用
  9. oneKeyNotApplicable: {
  10. method: 'POST',
  11. url: 'checkTask/notApplicable'
  12. },
  13. // 当situationType=2时,获取访查对象列表
  14. getInvestigationUsers: {
  15. method: 'GET',
  16. url: 'checkTask/getInvestigationUsers'
  17. },
  18. };
  19. export const commServer = (key, data) => {
  20. let obj = requestList[key];
  21. if(key=='oneKeyNotApplicable'){
  22. return creatRequest({
  23. ...obj,
  24. url:`checkTask/notApplicable?checkDetailId=${data}`
  25. });
  26. }
  27. return creatRequest(obj, data);
  28. }