/**
  * 公告基础资料
-*/
import { nologinRequest } from '@/utils/request'
import { getRequest, getRequestNoSort } from '@/utils/request'

export default {
  apiareainfolist: params => { // 区域 信息 不登录 临时接口
    return nologinRequest('https://api.honglouplus.com/api/area/info/list', params, 'loading')
  },
  admLogin: params => { // 登录
    return nologinRequest('/adm/login', params, 'loading')
  },
  admwechatuserloginlist: params => { // 小程序 登入日志
    return getRequest('/adm/wechat/user/login/list', params)
  },
  admapiloglist: params => { // 后台接口日志
    return getRequest('/adm/api/log/list', params)
  },
  admchangepwd: params => { // 修改密码
    return getRequest('/adm/change/pwd', params, 'loading')
  },
  admconfigcacheclear: params => { // 更新小程序首页 缓存
    return getRequest('/adm/config/cache/clear', params, 'loading')
  },
  admdicttypelist: params => { // 字典类型列表接口
    return getRequest('/adm/dict/type/list', params)
  },
  dicttypeadd: params => { // 字典类型添加接口
    return getRequestNoSort('/adm/dict/type/add', params, 'loading')
  },
  dicttypeedit: params => { // 字典类型编辑接口
    return getRequestNoSort('/adm/dict/type/edit', params, 'loading')
  },
  dicttypedel: params => { // 字典类型删除接口
    return getRequestNoSort('/adm/dict/type/del', params, 'loading')
  },
  admdictdatalist: params => { // 字典数据列表接口
    return getRequest('/adm/dict/data/list', params)
  },
  dictdataadd: params => { // 字典数据添加接口
    return getRequestNoSort('/adm/dict/data/add', params, 'loading')
  },
  dictdataedit: params => { // 字典数据编辑接口
    return getRequestNoSort('/adm/dict/data/edit', params, 'loading')
  },
  dictdatadel: params => { // 字典数据删除接口
    return getRequestNoSort('/adm/dict/data/del', params, 'loading')
  },
  admdicttree: params => { // 字典数据接口
    return getRequestNoSort('/adm/dict/tree', params, 'loading')
  },
  admuploadpicture: params => { // 上传图片 有水印
    return getRequestNoSort('/adm/upload/picture', params, 'loading')
  },
  admuploadcloudpub: params => { // 上传图片 无水印
    return getRequestNoSort('/adm/upload/cloudpub', params, 'loading')
  },
  admpermissionsadd: params => { // 菜单 - 添加
    return getRequestNoSort('/adm/permissions/add', params, 'loading')
  },
  admpermissionsedit: params => { // 菜单 - 编辑
    return getRequestNoSort('/adm/permissions/edit', params, 'loading')
  },
  admpermissionsdel: params => { // 菜单 - 删除
    return getRequestNoSort('/adm/permissions/del', params, 'loading')
  },
  admpermissionslist: params => { // 菜单 - 列表
    return getRequest('/adm/permissions/list', params)
  },
  admmenulist: params => { // 菜单 - 左侧菜单列表
    return getRequest('/adm/menu/list', params)
  },
  admroleslist: params => { // 角色 - 列表
    return getRequest('/adm/roles/list', params)
  },
  admrolesadd: params => { // 角色 - 添加
    return getRequestNoSort('/adm/roles/add', params, 'loading')
  },
  admrolesedit: params => { // 角色 - 编辑
    return getRequestNoSort('/adm/roles/edit', params, 'loading')
  },
  admrolesdel: params => { // 角色 - 删除
    return getRequestNoSort('/adm/roles/del', params, 'loading')
  },
  admtargetname: params => { // 目标名称 获取楼盘、学校名
    return getRequestNoSort('/adm/target/name', params, 'loading')
  },
  admnotifycount: params => { // 后台通知数量
    return getRequestNoSort('/adm/notify/count', params, 'loading')
  },
}