import { appservice } from '@/utils/apiService'

const baseUrl = '/api/camera'

export function get(id) {
  return appservice({
    url: `${baseUrl}/${id}`,
    method: 'get'
  })
}

export function getList(params) {
  return appservice({
    url: `${baseUrl}`,
    method: 'get',
    params
  })
}

export function create(data) {
  return appservice({
    url: `${baseUrl}`,
    method: 'post',
    data
  })
}

export function update(id, data) {
  return appservice({
    url: `${baseUrl}/${id}`,
    method: 'put',
    data
  })
}

export function remove(id) {
  return appservice({
    url: `${baseUrl}/${id}`,
    method: 'delete'
  })
}

