Browse Source

添加遗漏文件

柳建 9 months ago
parent
commit
2a48aaa52b
1 changed files with 6 additions and 4 deletions
  1. 6 4
      application/api/controller/Index.php

+ 6 - 4
application/api/controller/Index.php

@@ -75,11 +75,13 @@ class Index extends Api
                     'money'=>$vl['money']+$addincome[$val['uid']]
                 ];
             }
-            foreach ($linkincome[$val['uid']] as $key=>$val){
-                $upuserlink[$key]=$val;
-                $upuserlink[$key]['id']=$key;
-                $upuserlink[$key]['endtime']=$unixtime;
+            if(isset($linkincome[$vl['id']])){
+                foreach ($linkincome[$vl['id']] as $key=>$val){
+                    $upuserlink[$key]=$val;
+                    $upuserlink[$key]['id']=$key;
+                    $upuserlink[$key]['endtime']=$unixtime;
 
+                }
             }
             if($upincome){
                 $this->adminModel->saveAll($upincome);