import request from '@/router/axios';

export const getPage = (current, size, params) => {
    return request({
        url: '/api/galaxy-business/notice/page',
        method: 'get',
        params: {
            ...params,
            current,
            size,
        }
    })
}

export const getList = (current, size, params) => {
    return request({
        url: '/api/galaxy-business/notice/list',
        method: 'get',
        params: {
            ...params,
            current,
            size,
        }
    })
}

export const remove = (ids) => {
    return request({
        url: '/api/galaxy-business/notice/remove',
        method: 'post',
        params: {
            ids,
        }
    })
}

export const add = (row) => {
    return request({
        url: '/api/galaxy-business/notice/save',
        method: 'post',
        data: row
    })
}

export const update = (row) => {
    return request({
        url: '/api/galaxy-business/notice/submit',
        method: 'post',
        data: row
    })
}

export const getNotice = (id) => {
    return request({
        url: '/api/galaxy-business/notice/detail',
        method: 'get',
        params: {
            id
        }
    })
}

export const getLastList = (limit) => {
    return request({
        url: '/api/galaxy-business/notice/last/list?limit=' + limit,
        method: 'get',
    })
}

export const getTodayList = () => {
    return request({
        url: '/api/galaxy-business/notice/today/list',
        method: 'get',
    })
}


