|
@@ -35,10 +35,7 @@ class Index extends Api
|
|
|
$day = 86400;
|
|
$day = 86400;
|
|
|
foreach ($list as $item) {
|
|
foreach ($list as $item) {
|
|
|
|
|
|
|
|
- if($item->status == 2) {
|
|
|
|
|
- //解除收益
|
|
|
|
|
- $total = $item->total_self;
|
|
|
|
|
- }else{
|
|
|
|
|
|
|
+ if($item->status == 1) {
|
|
|
//未接触收益
|
|
//未接触收益
|
|
|
$reta = bcdiv($item->day_num, $day, 6); //天数
|
|
$reta = bcdiv($item->day_num, $day, 6); //天数
|
|
|
$inter = ($item->last_time == 0) ? $time - $item->create_time: $time - $item->last_time; //最后收取时间
|
|
$inter = ($item->last_time == 0) ? $time - $item->create_time: $time - $item->last_time; //最后收取时间
|
|
@@ -49,9 +46,10 @@ class Index extends Api
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-
|
|
|
|
|
- //更新用户资产
|
|
|
|
|
- $ledgerWalletModel->changeWalletAccount($item->user_id, Asset::TEAC, $total, LedgerTeacChangeModel::Pledge, 0);
|
|
|
|
|
|
|
+ if($total > 0){
|
|
|
|
|
+ //更新用户资产
|
|
|
|
|
+ $ledgerWalletModel->changeWalletAccount($item->user_id, Asset::TEAC, $total, LedgerTeacChangeModel::Pledge, 0);
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
//修改详情订单状态
|
|
//修改详情订单状态
|
|
|
$detail = json_decode($item['details'], true);
|
|
$detail = json_decode($item['details'], true);
|