index.ts 1.1 KB

1234567891011121314151617181920212223242526272829303132333435
  1. import request from '@/config/axios'
  2. export interface CustomerLimitConfigVO {
  3. id?: number
  4. type?: number
  5. userIds?: string
  6. deptIds?: string
  7. maxCount?: number
  8. dealCountEnabled?: boolean
  9. }
  10. // 查询客户限制配置列表
  11. export const getCustomerLimitConfigPage = async (params) => {
  12. return await request.get({ url: `/crm/customer-limit-config/page`, params })
  13. }
  14. // 查询客户限制配置详情
  15. export const getCustomerLimitConfig = async (id: number) => {
  16. return await request.get({ url: `/crm/customer-limit-config/get?id=` + id })
  17. }
  18. // 新增客户限制配置
  19. export const createCustomerLimitConfig = async (data: CustomerLimitConfigVO) => {
  20. return await request.post({ url: `/crm/customer-limit-config/create`, data })
  21. }
  22. // 修改客户限制配置
  23. export const updateCustomerLimitConfig = async (data: CustomerLimitConfigVO) => {
  24. return await request.put({ url: `/crm/customer-limit-config/update`, data })
  25. }
  26. // 删除客户限制配置
  27. export const deleteCustomerLimitConfig = async (id: number) => {
  28. return await request.delete({ url: `/crm/customer-limit-config/delete?id=` + id })
  29. }