import { baseRequest } from '@/utils/request'

const request = (url, ...arg) => baseRequest(`/biz/rebaterecord/` + url, ...arg)

/**
 * 返利记录Api接口管理器
 *
 * @author wulei
 * @date  2025/02/06 17:39
 **/
export default {
	// 获取返利记录分页
	bizRebateRecordPage(data) {
		return request('page', data, 'get')
	},
	// 提交返利记录表单 edit为true时为编辑，默认为新增
	bizRebateRecordSubmitForm(data, edit = false) {
		return request(edit ? 'edit' : 'add', data)
	},
	// 删除返利记录
	bizRebateRecordDelete(data) {
		return request('delete', data)
	},
	// 获取返利记录详情
	bizRebateRecordDetail(data) {
		return request('detail', data, 'get')
	}
}
