|
@@ -1691,7 +1691,7 @@ module.exports = app => {
|
|
const updateChangeList = [];
|
|
const updateChangeList = [];
|
|
for (const cl of changeList) {
|
|
for (const cl of changeList) {
|
|
const audit_amount = cl.audit_amount.split(',');
|
|
const audit_amount = cl.audit_amount.split(',');
|
|
- const last_amount = audit_amount[audit_amount.length - 1];
|
|
|
|
|
|
+ const last_amount = audit_amount[audit_amount.length - 1] ? audit_amount[audit_amount.length - 1] : 0;
|
|
audit_amount.splice(-1, 1);
|
|
audit_amount.splice(-1, 1);
|
|
const list_update = {
|
|
const list_update = {
|
|
id: cl.id,
|
|
id: cl.id,
|
|
@@ -1741,6 +1741,7 @@ module.exports = app => {
|
|
await this.ctx.helper.sendWechat(zsAudit.uid, smsTypeConst.const.BG, smsTypeConst.judge.approval.toString(), wxConst.template.change, wechatData);
|
|
await this.ctx.helper.sendWechat(zsAudit.uid, smsTypeConst.const.BG, smsTypeConst.judge.approval.toString(), wxConst.template.change, wechatData);
|
|
|
|
|
|
} catch (error) {
|
|
} catch (error) {
|
|
|
|
+ console.log(error);
|
|
await this.transaction.rollback();
|
|
await this.transaction.rollback();
|
|
result = false;
|
|
result = false;
|
|
}
|
|
}
|