'use strict'; /** * * * @author Mai * @date * @version */ class reportMemoryFinancial { constructor(ctx) { this.ctx = ctx; } async pay(tid) { return await this.ctx.service.financialPay.getAllDataByCondition({ where: { tid }}); } async payContract(tid) { return await this.ctx.service.financialPayContract.getAllDataByCondition({ where: { tid } }); } async payTender(tid) { return await this.ctx.service.financialPayTender.getAllDataByCondition({ where: { tid } }); } async transfer(tid) { const tender = this.ctx.tender ? this.ctx.tender : await this.ctx.tender.getDataById(tid); return await this.ctx.service.financialTransfer.getAllDataByCondition({ where: { spid: tender.spid } }); } async transferTender(tid) { return await this.ctx.service.financialTransferTender.getAllDataByCondition({ where: { tid } }); } } module.exports = reportMemoryFinancial;