import request from '@/utils/request';

/*
 * 分页查询
 */
export const getSysRole = (params) => request('/sysRole', { params });

/*
 * 新增数据
 */
export const postSysRole = (data) => request('/sysRole', { data, method: 'post' });

/*
 * 通过ID查询单条数据
 */
export const getSysRoleById = (id) => request(`/sysRole/${id}`);

/*
 * 更新数据
 */
export const putSysRole = (id, data) => request(`/sysRole/${id}`, { data, method: 'put' });

/*
 * 通过主键删除数据
 */
export const deleteSysRole = (id) => request(`/sysRole/${id}`, { method: 'delete' });
