增加消息通知接口
This commit is contained in:
71
ruoyi-ui/src/api/notify/notifications.js
Normal file
71
ruoyi-ui/src/api/notify/notifications.js
Normal file
@@ -0,0 +1,71 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 查询【请填写功能名称】列表
|
||||
export function listNotifications(query) {
|
||||
return request({
|
||||
url: '/back/notifications/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
// 查询【请填写功能名称】详细
|
||||
export function getNotifications(id) {
|
||||
return request({
|
||||
url: '/back/notifications/' + id,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 新增【请填写功能名称】
|
||||
export function addNotifications(data) {
|
||||
return request({
|
||||
url: '/back/notifications',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 修改【请填写功能名称】
|
||||
export function updateNotifications(data) {
|
||||
return request({
|
||||
url: '/back/notifications',
|
||||
method: 'put',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 删除【请填写功能名称】
|
||||
export function delNotifications(id) {
|
||||
return request({
|
||||
url: '/back/notifications/' + id,
|
||||
method: 'delete'
|
||||
})
|
||||
}
|
||||
|
||||
// 绑定用户
|
||||
export function bindUsers(id, data) {
|
||||
return request({
|
||||
url: '/back/notifications/bind',
|
||||
method: 'post',
|
||||
params: { id: id },
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 获取通知已绑定的用户列表
|
||||
export function getBindUsers(id) {
|
||||
return request({
|
||||
url: '/back/notifications/bindUsers/' + id,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 发布通知
|
||||
export function publishNotification(id) {
|
||||
return request({
|
||||
url: '/back/notifications/publish/' + id,
|
||||
method: 'post'
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user