'use strict'; const Controller = require('egg').Controller; class LogsController extends Controller { async listNormal(){ let {ctx, service} = this; let data = ctx.request.query; let ret = await service.logs.adminListLogs(data); ctx.adminOK( ret ); } async listFlyPosture() { let {ctx, service} = this; let data = ctx.request.query; let ret = await service.logs.adminListFlyPosture(data); ctx.adminOK( ret ); } async listMessage() { let {ctx, service} = this; let data = ctx.request.query; let ret = await service.logs.adminListMessage(data); ctx.adminOK( ret ); } async exportXls(){ const {ctx, service} = this; ctx.set("Content-Type", "application/vnd.openxmlformats"); ctx.set("Content-Disposition","attachment;filename*=UTF-8 xx.xlsx"); let ret = await service.logs.exportXls( ctx.request.query ); ctx.body = ret; } } module.exports = LogsController;