|
|
@@ -42,9 +42,11 @@ class PledgeLogic
|
|
|
{
|
|
|
$model = Loader::model('ProductOrder');
|
|
|
$count = count($order_no);
|
|
|
+
|
|
|
+
|
|
|
$product= $model::alias('a')
|
|
|
->join('product_list b', 'a.product_id = b.id', 'left')
|
|
|
- ->where('a.user_id', $user_id)
|
|
|
+ ->where('a.user_id', 1275)
|
|
|
->where('a.status', $model::Paid)
|
|
|
->whereIn('a.order_no', $order_no)->field('a.id,b.zh_name,b.thum,a.order_no')->limit($count)->select();
|
|
|
|
|
|
@@ -59,7 +61,7 @@ class PledgeLogic
|
|
|
$product, //订单信息
|
|
|
$pledge->day_num, $pledge_num);
|
|
|
|
|
|
- \think\Log::info('添加质抵押订单', ['pledge_id' => $pledge->id, 'order_no' => $order_no, 'user_id' => $user_id]);
|
|
|
+ \think\Log::info('添加质抵押订单'. json_encode(['pledge_id' => $pledge->id, 'order_no' => $order_no, 'user_id' => $user_id]));
|
|
|
|
|
|
//修改状态
|
|
|
return $model->whereIn('id', array_column($product, 'id'))->setField('status', $model::Freeze);
|
|
|
@@ -110,7 +112,7 @@ class PledgeLogic
|
|
|
$total = bcmul($reta, $inter, 6) * $rows->num; //累计收益
|
|
|
$rows->total_self= bcadd($total, $rows->total_self, 6);
|
|
|
|
|
|
- \think\Log::info('解除质抵押订单', ['pledge_id' => $pledge_id, 'detail' => $rows->details, 'user_id' => $user_id]);
|
|
|
+ \think\Log::info('解除质抵押订单'. json_encode(['pledge_id' => $pledge_id, 'detail' => $rows->details, 'user_id' => $user_id]));
|
|
|
//修改状态
|
|
|
$detail =json_decode($rows->details, true);
|
|
|
Loader::model('ProductOrder')::whereIn('id', array_column($detail, 'id'))->setField('status', ProductOrder::Paid);
|