lrf преди 2 години
родител
ревизия
220a92f8fa
променени са 1 файла, в които са добавени 1 реда и са изтрити 2 реда
  1. 1 2
      app/service/business/payOrder.js

+ 1 - 2
app/service/business/payOrder.js

@@ -21,8 +21,6 @@ class PayOrderService extends CrudService {
     this.rssModel = this.ctx.model.Relation.RelationStudentSchool;
     this.rssModel = this.ctx.model.Relation.RelationStudentSchool;
 
 
     this.billModel = this.ctx.model.Business.Bill;
     this.billModel = this.ctx.model.Business.Bill;
-    // this.costDetailModel = this.ctx.model.Business.CostDetail;
-    // this.chargeModel = this.ctx.model.Business.Charge;
   }
   }
 
 
   async beforeCreate(data) {
   async beforeCreate(data) {
@@ -134,6 +132,7 @@ class PayOrderService extends CrudService {
         await data.save();
         await data.save();
       } else {
       } else {
         const obj = _.pick(data, [ 'school_id', 'payer_id', 'payer_role' ]);
         const obj = _.pick(data, [ 'school_id', 'payer_id', 'payer_role' ]);
+        console.log({ ...obj, pay_for: 'Bill', pay_id, is_pay, time: moment().format('YYYY-MM-DD HH:mm:ss'), type: '1' });
         await this.billModel.create({ ...obj, pay_for: 'Bill', pay_id, is_pay, time: moment().format('YYYY-MM-DD HH:mm:ss'), type: '1' });
         await this.billModel.create({ ...obj, pay_for: 'Bill', pay_id, is_pay, time: moment().format('YYYY-MM-DD HH:mm:ss'), type: '1' });
       }
       }
     }
     }