import request from "./../utils/request.js";
/**
 * 消息相关接口
 */

/**
 * 获取列表
 */
export function getMessages(page, limit = 30) {
    return request.get("user/messages", {
        page: page,
        limit: limit
    });
}

/**
 * 已读/未读 标记 0 未读 1已读
 */
export function readMessages(ids) {
    return request.post("user/messages", {
        ids: ids,
        read: 1
    });
}

/**
 * 删除
 */
export function delMessages(ids) {
    return request.post("user/messages/del", {
        ids: ids
    });
}