thinkTankConsultation.js 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. import request from '@/utils/request'
  2. import qs from 'qs'
  3. export const getThinkTankConsultations = (params) => {
  4. return new request({
  5. url: './op/thinkTankConsultations/',
  6. method: 'get',
  7. params: params
  8. });
  9. }
  10. export const get = (id) => {
  11. return new request({
  12. url: './op/thinkTankConsultations/' + id,
  13. method: 'get',
  14. });
  15. }
  16. export function saveOrUpdate(thinkTankConsultation, token) {
  17. return new request({
  18. url: './op/thinkTankConsultations',
  19. method: (thinkTankConsultation.id ? 'put' : 'post'),
  20. headers: {
  21. token
  22. },
  23. data: {
  24. thinkTankConsultation
  25. }
  26. });
  27. }
  28. export function del(id) {
  29. return new request({
  30. url: './op/thinkTankConsultations/' + id,
  31. method: 'delete',
  32. });
  33. }
  34. export const commit = (id) => {
  35. return new request({
  36. url: './op/thinkTankConsultations/commit',
  37. method: 'get',
  38. params: {
  39. id:id
  40. }
  41. });
  42. }
  43. export const deleteTo = (id) => {
  44. return new request({
  45. url: './op/thinkTankConsultations/deleteTo',
  46. method: 'get',
  47. params: {
  48. id:id
  49. }
  50. });
  51. }