import { TRgeAuthModel, TRgeAuthQueryParam } from '@/types'
import request from '@/until/request'

/**
 * 获取注册授权列表
 * @param data TRgeAuthQueryParam
 */
const QueryTRgeAuthList = (data: TRgeAuthQueryParam) =>
    request({
        url: '/TRgeAuthAction/list',
        method: 'post',
        data: data
    })

/**
* 新增注册授权
* @param data TRgeAuthModel
*/
const AddTRgeAuth = (data: TRgeAuthModel) =>
    request({
        url: '/TRgeAuthAction/saveTRgeAuth',
        method: 'post',
        data: data
    })

/**
* 编辑注册授权
* @param data TRgeAuthModel
*/
const EditTRgeAuth = (data: TRgeAuthModel) =>
    request({
        url: '/TRgeAuthAction/updateTRgeAuth',
        method: 'post',
        data: data
    })

/**
* 删除注册授权
* @param  id number
*/
const DeleteTRgeAuth = (id: number) =>
    request({
        url: '/TRgeAuthAction/deleteTRgeAuth/' + id,
        method: 'get',
    })


export default {
    QueryTRgeAuthList,
    AddTRgeAuth,
    EditTRgeAuth,
    DeleteTRgeAuth,
}