refactor:基于 lint 处理排版
This commit is contained in:
@@ -4,7 +4,7 @@ import { requestClient } from '#/api/request';
|
||||
|
||||
export namespace SystemNotifyMessageApi {
|
||||
/** 站内信消息信息 */
|
||||
export interface SystemNotifyMessage {
|
||||
export interface NotifyMessage {
|
||||
id: number;
|
||||
userId: number;
|
||||
userType: number;
|
||||
@@ -22,7 +22,7 @@ export namespace SystemNotifyMessageApi {
|
||||
|
||||
/** 查询站内信消息列表 */
|
||||
export function getNotifyMessagePage(params: PageParam) {
|
||||
return requestClient.get<PageResult<SystemNotifyMessageApi.SystemNotifyMessage>>(
|
||||
return requestClient.get<PageResult<SystemNotifyMessageApi.NotifyMessage>>(
|
||||
'/system/notify-message/page',
|
||||
{ params },
|
||||
);
|
||||
@@ -30,7 +30,7 @@ export function getNotifyMessagePage(params: PageParam) {
|
||||
|
||||
/** 获得我的站内信分页 */
|
||||
export function getMyNotifyMessagePage(params: PageParam) {
|
||||
return requestClient.get<PageResult<SystemNotifyMessageApi.SystemNotifyMessage>>(
|
||||
return requestClient.get<PageResult<SystemNotifyMessageApi.NotifyMessage>>(
|
||||
'/system/notify-message/my-page',
|
||||
{ params },
|
||||
);
|
||||
@@ -38,9 +38,13 @@ export function getMyNotifyMessagePage(params: PageParam) {
|
||||
|
||||
/** 批量标记已读 */
|
||||
export function updateNotifyMessageRead(ids: number[]) {
|
||||
return requestClient.put('/system/notify-message/update-read', {}, {
|
||||
params: { ids },
|
||||
});
|
||||
return requestClient.put(
|
||||
'/system/notify-message/update-read',
|
||||
{},
|
||||
{
|
||||
params: { ids },
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
/** 标记所有站内信为已读 */
|
||||
@@ -50,7 +54,9 @@ export function updateAllNotifyMessageRead() {
|
||||
|
||||
/** 获取当前用户的最新站内信列表 */
|
||||
export function getUnreadNotifyMessageList() {
|
||||
return requestClient.get<SystemNotifyMessageApi.SystemNotifyMessage[]>('/system/notify-message/get-unread-list');
|
||||
return requestClient.get<SystemNotifyMessageApi.NotifyMessage[]>(
|
||||
'/system/notify-message/get-unread-list',
|
||||
);
|
||||
}
|
||||
|
||||
/** 获得当前用户的未读站内信数量 */
|
||||
|
||||
@@ -4,7 +4,7 @@ import { requestClient } from '#/api/request';
|
||||
|
||||
export namespace SystemNotifyTemplateApi {
|
||||
/** 站内信模板信息 */
|
||||
export interface SystemNotifyTemplate {
|
||||
export interface NotifyTemplate {
|
||||
id?: number;
|
||||
name: string;
|
||||
nickname: string;
|
||||
@@ -17,8 +17,9 @@ export namespace SystemNotifyTemplateApi {
|
||||
}
|
||||
|
||||
/** 发送站内信请求 */
|
||||
export interface SystemNotifySendReqVO {
|
||||
export interface NotifySendReqVO {
|
||||
userId: number;
|
||||
userType: number;
|
||||
templateCode: string;
|
||||
templateParams: Record<string, any>;
|
||||
}
|
||||
@@ -26,7 +27,7 @@ export namespace SystemNotifyTemplateApi {
|
||||
|
||||
/** 查询站内信模板列表 */
|
||||
export function getNotifyTemplatePage(params: PageParam) {
|
||||
return requestClient.get<PageResult<SystemNotifyTemplateApi.SystemNotifyTemplate>>(
|
||||
return requestClient.get<PageResult<SystemNotifyTemplateApi.NotifyTemplate>>(
|
||||
'/system/notify-template/page',
|
||||
{ params },
|
||||
);
|
||||
@@ -34,16 +35,22 @@ export function getNotifyTemplatePage(params: PageParam) {
|
||||
|
||||
/** 查询站内信模板详情 */
|
||||
export function getNotifyTemplate(id: number) {
|
||||
return requestClient.get<SystemNotifyTemplateApi.SystemNotifyTemplate>(`/system/notify-template/get?id=${id}`);
|
||||
return requestClient.get<SystemNotifyTemplateApi.NotifyTemplate>(
|
||||
`/system/notify-template/get?id=${id}`,
|
||||
);
|
||||
}
|
||||
|
||||
/** 新增站内信模板 */
|
||||
export function createNotifyTemplate(data: SystemNotifyTemplateApi.SystemNotifyTemplate) {
|
||||
export function createNotifyTemplate(
|
||||
data: SystemNotifyTemplateApi.NotifyTemplate,
|
||||
) {
|
||||
return requestClient.post('/system/notify-template/create', data);
|
||||
}
|
||||
|
||||
/** 修改站内信模板 */
|
||||
export function updateNotifyTemplate(data: SystemNotifyTemplateApi.SystemNotifyTemplate) {
|
||||
export function updateNotifyTemplate(
|
||||
data: SystemNotifyTemplateApi.NotifyTemplate,
|
||||
) {
|
||||
return requestClient.put('/system/notify-template/update', data);
|
||||
}
|
||||
|
||||
@@ -54,10 +61,12 @@ export function deleteNotifyTemplate(id: number) {
|
||||
|
||||
/** 导出站内信模板 */
|
||||
export function exportNotifyTemplate(params: any) {
|
||||
return requestClient.download('/system/notify-template/export-excel', { params });
|
||||
return requestClient.download('/system/notify-template/export-excel', {
|
||||
params,
|
||||
});
|
||||
}
|
||||
|
||||
/** 发送站内信 */
|
||||
export function sendNotify(data: SystemNotifyTemplateApi.SystemNotifySendReqVO) {
|
||||
export function sendNotify(data: SystemNotifyTemplateApi.NotifySendReqVO) {
|
||||
return requestClient.post('/system/notify-template/send-notify', data);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user