import request from '@/config/axios'

export interface QuickGroupVO {
  id: number
  groupName: string
}

// 查询回复分组列表
export const getQuickGroupPage = async (params) => {
  return await request.get({ url: `/message/quick-group/page`, params })
}

// 查询回复分组详情
export const getQuickGroup = async (id: number) => {
  return await request.get({ url: `/message/quick-group/get?id=` + id })
}

// 新增回复分组
export const createQuickGroup = async (data: QuickGroupVO) => {
  return await request.post({ url: `/message/quick-group/create`, data })
}

// 修改回复分组
export const updateQuickGroup = async (data: QuickGroupVO) => {
  return await request.put({ url: `/message/quick-group/update`, data })
}

// 删除回复分组
export const deleteQuickGroup = async (id: number) => {
  return await request.delete({ url: `/message/quick-group/delete?id=` + id })
}

// 导出回复分组 Excel
export const exportQuickGroup = async (params) => {
  return await request.download({ url: `/message/quick-group/export-excel`, params })
}
