import {
  get,
  post,
} from '@/common/utils/http-util.ts'

export default {
  paging(data: CustomerTypes.SearchCustomerParam) {
    return get<G.PageResult<CustomerTypes.SearchCustomerResult>>('/customer/paging', data)
  },
  detail(id: string) {
    return get<CustomerTypes.TableData>('/customer/detail', {id})
  },
  add(data: CustomerTypes.AddCustomerParam) {
    return post('/customer/add', data)
  },
  modify(data: CustomerTypes.ModifyCustomerParam) {
    return post('/customer/modify', data)
  },
  del(ids: string[]) {
    return post('/customer/del', ids)
  },
}
