import request from '@/common/system/request';


/**
 * 获取单个文章内容
 * @param {number} id 文章ID
 * @returns {Promise<any>}
 */
export const getArticleDetail = async (id) => {
    const res = await request.getOrCache("Article/GetArticleDetail", { id });
    if (res.code == 0) {
        return res.data;
    }
    return null;
}

/**
 * 获取通知列表
 * @param {Object} params 查询参数
 * @returns {Promise<any>}
 */
export const noticeList = async (params) => {
    const res = await request.post("Article/NoticeList", params);
    if (res.code == 0) {
        return res.data;
    }
    return null;
} 