import api from '@/utils/request'

export const iGetList = params => api.post(`/admin/banner/page`, params)

export const iGetItem = ({ id, ...params }) => api.get(`/admin/banner/${id}`, params)

export const iGetShowNum = params => api.post(`/admin/banner/show/num`, params)

export const iUpdateItem = (id, params) => api.put(`/admin/banner/item/${id}`, params)

export const iAddItem = params => api.post(`/admin/banner/item`, params)

export const iDeleteBanner = ({ id, ...params }) => api.del(`/admin/banner/delete/${id}`, params)

export const iDeleteBanners = params => api.delData(`/admin/banner/list/delete`, params)

export const iChangeShowStatus = ({ id, ...params }) => api.post(`/admin/banner/item/${id}/show`, params)
