import { default as BaseController } from "../baseController";
|
import { Post } from "egg-shell-decorators";
|
import { FinanceBankAccount } from "../../entity/finance/base/financeBankAccount";
|
|
export default class AccountCheckController extends BaseController {
|
//#region 获取当前金额
|
/**
|
* 获取当前金额
|
*/
|
@Post()
|
public async onChange() {
|
let { ctx } = this;
|
let body = this.body; // 接收前端发来的数据
|
let userInfo = await ctx.helper.userInfo(); // 权限
|
try {
|
let dataList = await this.dbRead.findOne(FinanceBankAccount, {
|
where: {
|
userProduct_Id: userInfo.userProduct_Id,
|
bankAccount_Id: body.bankAccount_Id
|
}
|
});
|
this.info.result = true;
|
this.info.data = dataList;
|
this.info.msg;
|
} catch (error) {
|
this.info.result = false;
|
this.info.msg = "错误信息:" + error.message;
|
}
|
ctx.body = this.info;
|
}
|
//#endregion
|
}
|