import request from '@/utils/request';

//查询问答
export function queryAppQuestionAnswerPage(params:any){
    return request({
      url: '/app/question-answer/queryAppQuestionAnswerPage' ,
      method: 'get',
      params: params
    });
}
//问答问题
export function updateAppQuestionAnswer(data:any){
    return request({
      url: '/app/question-answer/updateAppQuestionAnswer' ,
      method: 'post',
      data: data
    });
}
//导出日志
export function exportUserLogData(params:any){
    return request({
      url: '/app/app-user-logs/exportUserLogData' ,
      method: 'get',
      params: params,
      responseType: 'arraybuffer'
    });
}

//查询日志
export function queryAppUserLogsPage(params:any){
  return request({
    url: '/app/app-user-logs/queryAppUserLogsPage' ,
    method: 'get',
    params: params
  });
}

//查询日志
export function queryAppUserHistoryLogsPage(params:any){
  return request({
    url: '/app/app-user-logs/queryAppUserHistoryLogsPage' ,
    method: 'get',
    params: params
  });
}
//查询资讯
export function queryAppNewsPage(params:any){
  return request({
    url: '/app/app-news/queryAppNewsPage' ,
    method: 'get',
    params: params
  });
}
//添加资讯
export function addAppNews(formData:any){
  return request({
    url: '/app/app-news/addAppNews' ,
    method: 'post',
    data: formData,
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  });
}
//修改资讯
export function updateAppNews(formData:any){
  return request({
    url: '/app/app-news/updateAppNews' ,
    method: 'post',
    data: formData,
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  });
}
//修改资讯状态
export function updateAppNewsStatus(data:any){
  return request({
    url: '/app/app-news/updateAppNewsStatus' ,
    method: 'post',
    data: data
  });
}
//删除资讯
export function delAppNews(queryParams:any){
  return request({
    url:'/app/app-news/delAppNews' ,
    method: 'post',
    params: queryParams
  });
}