| | |
| | | import { ALL, Body, Get, Inject, Post, Provide, Query } from '@midwayjs/decorator'; |
| | | import { CoolController, BaseController } from '@cool-midway/core'; |
| | | import { Execrecord } from '../../entity/execrecord'; |
| | | import { ExecrecordService } from '../../service/execrecord'; |
| | | // import { ExecrecordService } from '../../service/execrecord'; |
| | | import { DataController } from '../../../base/controller/dataController'; |
| | | /** |
| | | * 任务执行记录 |
| | | */ |
| | | * 任务执行记录 |
| | | */ |
| | | @Provide() |
| | | @CoolController({ |
| | | api: ['add', 'delete', 'update', 'list','page','info'], |
| | | entity: Execrecord, |
| | | service: ExecrecordService, |
| | | @CoolController({ |
| | | api: ['add', 'delete', 'update', 'list', 'page', 'info'], |
| | | entity: Execrecord, |
| | | // service: ExecrecordService, |
| | | }) |
| | | export class ExecrecordController extends DataController { |
| | | @Inject() |
| | | execrecordService: ExecrecordService; |
| | | |
| | | // @Inject() |
| | | // execrecordService: ExecrecordService; |
| | | |
| | | /** |
| | | * 获得数据 |
| | | */ |
| | | @Get('/getdata', { summary: '数据接口' }) |
| | | async getData(@Query(ALL) params: any) { |
| | | return this.ok(await this.dataService.getData(params)); |
| | | } |
| | | @Get('/getdata', { summary: '数据接口' }) |
| | | async getData(@Query(ALL) params: any) { |
| | | return this.ok(await this.dataService.getData(params)); |
| | | } |
| | | /** |
| | | * 获得数据 |
| | | */ |
| | | @Get('/postdata', { summary: '数据接口' }) |
| | | async postData(@Query(ALL) params: any) { |
| | | return this.ok(await this.dataService.getData(params)); |
| | | } |
| | | @Get('/postdata', { summary: '数据接口' }) |
| | | async postData(@Query(ALL) params: any) { |
| | | return this.ok(await this.dataService.getData(params)); |
| | | } |
| | | } |