helpCenterAssociation.js 823 B

12345678910111213141516171819202122232425262728293031323334353637
  1. import request from '@/utils/request'
  2. import qs from 'qs'
  3. export const getHelpCenterAssociations = (params) => {
  4. return new request({
  5. url: './op/helpCenterAssociations/',
  6. method: 'get',
  7. params: params
  8. });
  9. }
  10. export const get = (id) => {
  11. return new request({
  12. url: './op/helpCenterAssociations/' + id,
  13. method: 'get',
  14. });
  15. }
  16. export function saveOrUpdate(helpCenterAssociation, token) {
  17. return new request({
  18. url: './op/helpCenterAssociations',
  19. method: (helpCenterAssociation.id ? 'put' : 'post'),
  20. headers: {
  21. token
  22. },
  23. data: {
  24. helpCenterAssociation
  25. }
  26. });
  27. }
  28. export function del(id) {
  29. return new request({
  30. url: './op/helpCenterAssociations/' + id,
  31. method: 'delete',
  32. });
  33. }