hefei 1 anno fa
parent
commit
dfaca9b1ca
1 ha cambiato i file con 6 aggiunte e 6 eliminazioni
  1. 6 6
      app/controller/api/user/User.php

+ 6 - 6
app/controller/api/user/User.php

@@ -1664,12 +1664,12 @@ class User extends BaseController
1664
                         "nickname" => $v['nickname'],
1664
                         "nickname" => $v['nickname'],
1665
                         "avatar" => $v['avatar'],
1665
                         "avatar" => $v['avatar'],
1666
                         "pv" => $v['pv'],
1666
                         "pv" => $v['pv'],
1667
-                        "total_performance" => (int)$v['total_pv'],
1667
+                        "total_performance" => $v['total_pv'],
1668
                         "create_time" => $v['create_time'],
1668
                         "create_time" => $v['create_time'],
1669
                         'team_count' => $v['team_count'],
1669
                         'team_count' => $v['team_count'],
1670
                         'new_performance' => $new_performance_child
1670
                         'new_performance' => $new_performance_child
1671
                     ];
1671
                     ];
1672
-                    $person_nums_pv = bcadd($person_nums_pv, $v['total_pv']);
1672
+                    $person_nums_pv = bcadd($person_nums_pv, $v['total_pv'],2);
1673
                 } else {
1673
                 } else {
1674
                     $common_list[] = [
1674
                     $common_list[] = [
1675
                         "uid" => $v["uid"],
1675
                         "uid" => $v["uid"],
@@ -1678,12 +1678,12 @@ class User extends BaseController
1678
                         "nickname" => $v['nickname'],
1678
                         "nickname" => $v['nickname'],
1679
                         "avatar" => $v['avatar'],
1679
                         "avatar" => $v['avatar'],
1680
                         "pv" => $v['pv'],
1680
                         "pv" => $v['pv'],
1681
-                        "total_performance" => (int)$v['total_pv'],
1681
+                        "total_performance" => $v['total_pv'],
1682
                         "create_time" => $v['create_time'],
1682
                         "create_time" => $v['create_time'],
1683
                         'team_count' => $v['team_count'],
1683
                         'team_count' => $v['team_count'],
1684
                         'new_performance' => $new_performance_child
1684
                         'new_performance' => $new_performance_child
1685
                     ];
1685
                     ];
1686
-                    $common_nums_pv = bcadd($common_nums_pv, $v['total_pv']);
1686
+                    $common_nums_pv = bcadd($common_nums_pv, $v['total_pv'],2);
1687
                 }
1687
                 }
1688
                 // 我的直推 不是大小团队 加起来
1688
                 // 我的直推 不是大小团队 加起来
1689
                 // $aLL_list[] =  [
1689
                 // $aLL_list[] =  [
@@ -1753,7 +1753,7 @@ class User extends BaseController
1753
                         "nickname" => $v['nickname'],
1753
                         "nickname" => $v['nickname'],
1754
                         "avatar" => $v['avatar'],
1754
                         "avatar" => $v['avatar'],
1755
                         "pv" => $v['pv'],
1755
                         "pv" => $v['pv'],
1756
-                        "total_performance" => (int)$v['total_pv'],
1756
+                        "total_performance" => $v['total_pv'],
1757
                         "create_time" => $v['create_time'],
1757
                         "create_time" => $v['create_time'],
1758
                         'team_count'=> $v['team_count'],
1758
                         'team_count'=> $v['team_count'],
1759
                         'new_performance' => $new_performance_child
1759
                         'new_performance' => $new_performance_child
@@ -1774,7 +1774,7 @@ class User extends BaseController
1774
         $data['team_list'] = $data1;
1774
         $data['team_list'] = $data1;
1775
         $data['fans_num'] = $child_nums_Tree[0]['team_count'];//总人数
1775
         $data['fans_num'] = $child_nums_Tree[0]['team_count'];//总人数
1776
         $data['new_performance'] = $new_performance;//新增总业绩
1776
         $data['new_performance'] = $new_performance;//新增总业绩
1777
-        $data['total_performance'] = (int)bcadd($child_nums_Tree[0]['total_pv'] ?? 0, 0, 2);//总业绩
1777
+        $data['total_performance'] = bcadd($child_nums_Tree[0]['total_pv'] ?? 0, 0, 2);//总业绩
1778
         $data['person_nums'] = count($person_list);//大部门人数
1778
         $data['person_nums'] = count($person_list);//大部门人数
1779
         $data['common_nums'] = count($common_list);//小部门人数
1779
         $data['common_nums'] = count($common_list);//小部门人数
1780
         $data['common_nums_pv'] = $person_nums_pv;//大部门业绩
1780
         $data['common_nums_pv'] = $person_nums_pv;//大部门业绩