import request from '@/utils/request'

export function create(data) {
  return request({
    url: '/mall-post/add',
    method: 'post',
    data
  })
}

export function update(query) {
  return request({
    url: '/mall-post/edit',
    method: 'post',
    data:query
  })
}

export function getList(query) {
  return request({
    url: '/mall-post/list',
    method: 'post',
    params:query
  })
}

export function changeState(query) {
  return request({
    url: '/mall-post/modify/status',
    method: 'post',
    params:query
  })
}

export function approvalList(query) {
  return request({
    url: '/system/dict/type/list',
    method: 'get',
    params:query
  })
}

export function complete(data) {
  return request({
    url: '/mall-train/admin/complete',
    method: 'post',
    data
  })
}



