|
@@ -24,11 +24,11 @@ class PayOrderService extends CrudService {
|
|
|
}
|
|
|
|
|
|
async beforeCreate(data) {
|
|
|
- console.log(data);
|
|
|
if (!_.get(data, 'order_no')) data.order_no = this.getOrderNo();
|
|
|
const { data: nd, next } = await this.checkSurplus(data);
|
|
|
if (!next) throw new BusinessError(0, '扣除余额成功', nd);
|
|
|
data = nd;
|
|
|
+ console.log(data);
|
|
|
return data;
|
|
|
}
|
|
|
// 检查是否扣除余额
|