فهرست منبع

feat: NG-71: 移除皇冠星级相关配置及代码

kevin 1 سال پیش
والد
کامیت
ebf98bb2dd

+ 1 - 256
backendApi/config/menu.php

@@ -1,15 +1,6 @@
 <?php
-/**
- * Created by PhpStorm.
- * User: Leo
- * Date: 2017/9/3
- * Time: 下午3:23
- */
+
 return [
-//    'navigation' => [
-//        'name'=>'导航',
-//        'class' => 'list-header',
-//    ],
     'dashboard'=>[
         'name'=>'Dashboard',//控制台
         'class' => '',
@@ -21,10 +12,6 @@ return [
         'wiki' => 'dashboard',
         'child'=>[
             ['name'=>'首页', 'class'=>'', 'icon'=>'', 'controller'=>'dashboard', 'action'=>'index', 'routePath'=>'dashboard/index', 'show'=>0,],
-//            ['name'=>'总累计', 'class'=>'', 'icon'=>'', 'controller'=>'dashboard', 'action'=>'total-item', 'routePath'=>'dashboard/total-item', 'show'=>0,],
-//            ['name'=>'会员月注册数量', 'class'=>'', 'icon'=>'', 'controller'=>'dashboard', 'action'=>'reg-num', 'routePath'=>'dashboard/reg-num', 'show'=>0,],
-//            ['name'=>'月奖金量', 'class'=>'', 'icon'=>'', 'controller'=>'dashboard', 'action'=>'bonus-num', 'routePath'=>'dashboard/bonus-num', 'show'=>0,],
-//            ['name'=>'月提现量', 'class'=>'', 'icon'=>'', 'controller'=>'dashboard', 'action'=>'withdraw-num', 'routePath'=>'dashboard/withdraw-num', 'show'=>0,],
         ]
     ],
     'shop'=>[
@@ -38,30 +25,16 @@ return [
         'wiki' => 'shoppingMall',
         'child'=>[
             ['name'=>'Products list', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'index', 'routePath'=>'shop/index', 'show'=>1, 'wiki' => 'productsList'],//商品列表
-            // 新添加的商品操作  --- stat
             ['name'=>'添加商品', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'goods-add', 'routePath'=>'shop/goods-add', 'show'=>0,],
             ['name'=>'编辑商品', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'goods-edit', 'routePath'=>'shop/goods-edit', 'show'=>0,],
             ['name'=>'商品上下架', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'goods-status', 'routePath'=>'shop/goods-status', 'show'=>0],
             ['name'=>'删除商品', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'goods-delete', 'routePath'=>'shop/goods-delete', 'show'=>0,],
-            // 新添加的商品操作 ---stop
             ['name'=>'商品列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'goods-list-export', 'routePath'=>'shop/goods-list-export', 'show'=>0,],
-//            ['name'=>' Kitting products manage', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'package', 'routePath'=>'shop/package', 'show'=>1,],//套餐管理
-
-            // ['name'=>'Welcome Pack Listing', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'dec-order-list', 'routePath'=>'shop/dec-order-list', 'show'=>1,],//报单列表
-            // ['name'=>'报单列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'dec-order-list-export', 'routePath'=>'shop/dec-order-list-export', 'show'=>0,],
             ['name'=>'Order list', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'order-list', 'routePath'=>'shop/order-list', 'show'=>1, 'wiki' => 'orderList'],//订单列表
             ['name'=>'订单列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'order-list-export', 'routePath'=>'shop/order-list-export', 'show'=>0,],
             ['name'=>'订单PDF导出', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'order-list-export-pdf', 'routePath'=>'shop/order-list-export-pdf', 'show'=>0,],
             ['name'=>'订单发货', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'order-delivery', 'routePath'=>'shop/order-delivery', 'show'=>0,],
-//            ['name'=>'Remain BV', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'remain-pv', 'routePath'=>'shop/remain-pv', 'show'=>1, 'wiki' => 'remainBV'], // 剩余BV
-//            ['name'=>'Remain BV Flow', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'flow-remain-pv', 'routePath'=>'shop/flow-remain-pv', 'show'=>1, 'wiki' => 'remainBVFlow'], // 剩余BV流水
-//            ['name'=>'External mall order list', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'order-shop-list', 'routePath'=>'shop/order-shop-list', 'show'=>1, 'wiki' => 'externalMallOrderList'], // 外部商城订单列表
-//            ['name'=>'External mall entry list', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'order-dec-list', 'routePath'=>'shop/order-dec-list', 'show'=>1, 'wiki' => 'externalMallEntryList'], // 外部商城报单列表
-            // ['name'=>'List of qualified orders of external mall', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'order-standard-list', 'routePath'=>'shop/order-standard-list', 'show'=>1,], // 外部商城达标订单列表
             ['name'=>'订单期数调整', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'order-period-adjust', 'routePath'=>'shop/order-period-adjust', 'show'=>1, 'wiki' => 'shopOrderPeriodAdjust'],
-//            ['name'=>'Brand Ambassador Order', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'ba-order-list', 'routePath'=>'shop/ba-order-list', 'show'=>1,], // 会员列表
-//            ['name'=>'Brand Ambassador Dec List', 'class'=>'', 'icon'=>'', 'controller'=>'shop', 'action'=>'ba-dec-order-list', 'routePath'=>'shop/ba-dec-order-list', 'show'=>1,], // 会员列表
-
         ]
     ],
     'user'=>[
@@ -75,19 +48,7 @@ return [
         'wiki' => 'memberManagement',
         'child'=>[
             ['name'=>'Member list', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'index', 'routePath'=>'user/index', 'show'=>1, 'wiki' => 'memberList'],//会员列表
-//            ['name'=>'Brand Ambassador List', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'ba-user-list', 'routePath'=>'user/ba-user-list', 'show'=>1,], // 会员列表
             ['name'=>'登录到前台', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'login-to-frontend', 'routePath'=>'user/login-to-frontend', 'show'=>0,],
-//            ['name'=>'指定会员管理登录管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'batch-close-login', 'routePath'=>'user/batch-close-login', 'show'=>0,],
-//            ['name'=>'按条件登录管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'close-login', 'routePath'=>'user/close-login', 'show'=>0,],
-//            ['name'=>'会员地区登录管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'close-area-login', 'routePath'=>'user/close-area-login', 'show'=>0,],
-            //['name'=>'会员运作管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'is-operating', 'routePath'=>'user/is-operating', 'show'=>0,],
-//            ['name'=>'会员团队领导人管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'is-group', 'routePath'=>'user/is-group', 'show'=>0,],
-//            ['name'=>'会员报单中心管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'is-dec', 'routePath'=>'user/is-dec', 'show'=>0,],
-//            ['name'=>'会员工作室管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'is-studio', 'routePath'=>'user/is-studio', 'show'=>0,],
-//            ['name'=>'会员转账比例修改', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'change-transfer-prop', 'routePath'=>'user/change-transfer-prop', 'show'=>0,],
-//            ['name'=>'指定会员管理报单管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'batch-close-dec', 'routePath'=>'user/batch-close-dec', 'show'=>0,],
-//            ['name'=>'按条件报单管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'close-dec', 'routePath'=>'user/close-dec', 'show'=>0,],
-//            ['name'=>'会员地区报单管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'close-area-dec', 'routePath'=>'user/close-area-dec', 'show'=>0,],
             ['name'=>'会员列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'index-export', 'routePath'=>'user/index-export', 'show'=>0,],
             ['name'=>'图谱管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'is-atlas', 'routePath'=>'user/is-atlas', 'show'=>0,],
             ['name'=>'充值管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'is-recharge', 'routePath'=>'user/is-recharge', 'show'=>0,],
@@ -96,60 +57,17 @@ return [
             ['name'=>'修改个人资料', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'modify-profile', 'routePath'=>'user/modify-profile', 'show'=>0,],
             ['name'=>'会员状态', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'modify-status', 'routePath'=>'user/modify-status', 'show'=>0,],
             ['name'=>'密码修改状态', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'is-modify-password-status', 'routePath'=>'user/is-modify-password-status', 'show'=>0,],
-//            ['name'=>'Empty order operation', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'user-add-opt', 'routePath'=>'user/user-add-opt', 'show'=>1, 'wiki' => 'emptyOrderOperation'],//空单操作
-//            ['name'=>'空单添加', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'user-add', 'routePath'=>'user/user-add', 'show'=>0,],
-//            ['name'=>'Empty list', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'empty-list', 'routePath'=>'user/empty-list', 'show'=>0,], // 空单列表
-//            ['name'=>'空单批量1导入', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'import-users-to-excel-table', 'routePath'=>'user/import-users-to-excel-table', 'show'=>0,],
-//            ['name'=>'空单批量2添加', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'import-users-add', 'routePath'=>'user/import-users-add', 'show'=>0,],
-//            ['name'=>'空单删除', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'user-del', 'routePath'=>'user/user-del', 'show'=>0,],
-            //['name'=>'点位绑定', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'bind', 'routePath'=>'user/bind', 'show'=>1,],
-            //['name'=>'点位绑定添加', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'bind-add', 'routePath'=>'user/bind-add', 'show'=>0,],
-            //['name'=>'点位绑定编辑', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'bind-edit', 'routePath'=>'user/bind-edit', 'show'=>0,],
-            //['name'=>'点位绑定撤销', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'bind-delete', 'routePath'=>'user/bind-delete', 'show'=>0,],
-            //['name'=>'点位绑定导出', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'bind-export', 'routePath'=>'user/bind-export', 'show'=>0,],
-            //['name'=>'点位合作', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'teamwork', 'routePath'=>'user/teamwork', 'show'=>1,],
-            //['name'=>'点位合作添加', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'teamwork-add', 'routePath'=>'user/teamwork-add', 'show'=>0,],
-            //['name'=>'点位合作编辑', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'teamwork-edit', 'routePath'=>'user/teamwork-edit', 'show'=>0,],
-            //['name'=>'点位合作导出', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'teamwork-export', 'routePath'=>'user/teamwork-export', 'show'=>0,],
-            //['name'=>'体系管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'system', 'routePath'=>'user/system', 'show'=>1,],
-            //['name'=>'体系添加', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'system-add', 'routePath'=>'user/system-add', 'show'=>0,],
-            //['name'=>'体系编辑', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'system-edit', 'routePath'=>'user/system-edit', 'show'=>0,],
-            //['name'=>'体系撤销', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'system-delete', 'routePath'=>'user/system-delete', 'show'=>0,],
-            //['name'=>'体系恢复', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'system-renew', 'routePath'=>'user/system-renew', 'show'=>0,],
-            //['name'=>'体系导出', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'system-export', 'routePath'=>'user/system-export', 'show'=>0,],
-            //['name'=>'团队领导人列表', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'group', 'routePath'=>'user/group', 'show'=>1,],
-            //['name'=>'团队领导人列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'group-export', 'routePath'=>'user/group-export', 'show'=>0,],
             ['name'=>'Move network management', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'move', 'routePath'=>'user/move', 'show'=>1, 'wiki' => 'moveNetworkManagement'], // 移网管理
             ['name'=>'Apply for moving network', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'move-add', 'routePath'=>'user/move-add', 'show'=>0,], // 申请移网
             ['name'=>'移网修改并审核', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'move-pass', 'routePath'=>'user/move-pass', 'show'=>0,],
             ['name'=>'移网审核', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'move-audit', 'routePath'=>'user/move-audit', 'show'=>0,],
             ['name'=>'移网导出', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'move-export', 'routePath'=>'user/move-export', 'show'=>0,],
             ['name'=>'移网审核删除', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'move-delete', 'routePath'=>'user/move-delete', 'show'=>0,],
-            //['name'=>'注册信息报表', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'reg-info', 'routePath'=>'user/reg-info', 'show'=>1,],
-            //['name'=>'修改注册信息', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'reg-info-edit', 'routePath'=>'user/reg-info-edit', 'show'=>0,],
-            //['name'=>'注册信息审核列表', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'reg-info-audit', 'routePath'=>'user/reg-info-audit', 'show'=>1,],
-            //['name'=>'注册信息添加操作', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'reg-info-audit-add-opt', 'routePath'=>'user/reg-info-audit-add-opt', 'show'=>0,],
-            //['name'=>'注册信息添加', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'reg-info-audit-add', 'routePath'=>'user/reg-info-audit-add', 'show'=>0,],
-            //['name'=>'注册信息批量1导入', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'import-reg-info-to-excel-table', 'routePath'=>'user/import-reg-info-to-excel-table', 'show'=>0,],
-            //['name'=>'注册信息批量2添加', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'import-reg-info', 'routePath'=>'user/import-reg-info', 'show'=>0,],
-            //['name'=>'审核注册信息', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'reg-info-audit-audit', 'routePath'=>'user/reg-info-audit-audit', 'show'=>0,],
-            //['name'=>'删除审核注册信息', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'reg-info-audit-delete', 'routePath'=>'user/reg-info-audit-delete', 'show'=>0,],
-            //['name'=>'会员状态管理', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'status-audit-list', 'routePath'=>'user/status-audit-list', 'show'=>1,],
-            //['name'=>'会员状态管理导出', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'user/status-audit-export', 'routePath'=>'user/user/status-audit-export', 'show'=>0,],
-            //['name'=>'申请修改会员状态', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'status-audit-add', 'routePath'=>'user/status-audit-add', 'show'=>0,],
-            //['name'=>'审核会员状态', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'status-audit', 'routePath'=>'user/status-audit', 'show'=>0,],
-            //['name'=>'删除审核会员状态', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'status-audit-delete', 'routePath'=>'user/status-audit-delete', 'show'=>0,],
             ['name'=>'Member level adjustment list', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'dec-level-list', 'routePath'=>'user/dec-level-list', 'show'=>1, 'wiki' => 'memberLevelAdjustmentList'],//会员级别调整列表
             ['name'=>'修改会员级别', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'change-user-dec-level', 'routePath'=>'user/change-user-dec-level', 'show'=>0,],
             ['name'=>'Modify Stockist level', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'change-user-dec-role', 'routePath'=>'user/change-user-dec-role', 'show'=>1, 'wiki' => 'modifyStockistLevel'],//修改报单中心级别
-            //['name'=>'清空关停会员钱包', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'clear-wallet', 'routePath'=>'user/clear-wallet', 'show'=>0,],
-//            ['name'=>'会员历史年度最高聘级表', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'year-highest-emp-lv', 'routePath'=>'user/year-highest-emp-lv', 'show'=>1,],
-//            ['name'=>'会员历史年度最高聘级表导出', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'user/year-highest-emp-lv-export', 'routePath'=>'user/user/year-highest-emp-lv-export', 'show'=>0,],
-            //['name'=>'修改会员前台显示聘级', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'change-show-emp-level', 'routePath'=>'user/change-show-emp-level', 'show'=>1,],
             ['name'=>'会员最高聘级调整', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'change-user-dec-level', 'routePath'=>'user/change-highest-emp-level-list', 'show'=>1, 'wiki' => 'memberHighestEmpLevelAdjustment'],
             ['name'=>'修改会员最高聘级', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'change-user-dec-level', 'routePath'=>'user/change-highest-emp-level', 'show'=>0,],
-//            ['name'=>'会员国家调整列表', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'immigrant-list', 'routePath'=>'user/immigrant-list', 'show'=>1, 'wiki' => 'memberCountryAdjustment'],
-//            ['name'=>'会员国家调整', 'class'=>'', 'icon'=>'', 'controller'=>'user', 'action'=>'immigrant', 'routePath'=>'user/immigrant', 'show'=>0,],
         ]
     ],
     'atlas'=>[
@@ -166,36 +84,9 @@ return [
             ['name'=>'开拓网络图', 'class'=>'', 'icon'=>'', 'controller'=>'atlas', 'action'=>'relation', 'routePath'=>'atlas/relation', 'show'=>0,],
             ['name'=>'开拓网络列表', 'class'=>'', 'icon'=>'', 'controller'=>'atlas', 'action'=>'relation-list', 'routePath'=>'atlas/relation-list', 'show'=>0,],
             ['name'=>'开拓网络列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'atlas', 'action'=>'relation-list-export', 'routePath'=>'atlas/relation-list-export', 'show'=>0,],
-//            ['name'=>'Placement network', 'class'=>'', 'icon'=>'', 'controller'=>'atlas', 'action'=>'network-opt', 'routePath'=>'atlas/network-opt', 'show'=>1, 'wiki' => 'placementNetwork'],//安置网络
-//            ['name'=>'安置网络图', 'class'=>'', 'icon'=>'', 'controller'=>'atlas', 'action'=>'network', 'routePath'=>'atlas/network', 'show'=>0,],
-//            ['name'=>'安置网络列表', 'class'=>'', 'icon'=>'', 'controller'=>'atlas', 'action'=>'network-list', 'routePath'=>'atlas/network-list', 'show'=>0,],
-//            ['name'=>'安置网络列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'atlas', 'action'=>'network-list-export', 'routePath'=>'atlas/network-list-export', 'show'=>0,],
-//            ['name'=>'Placement Network Ex', 'class'=>'', 'icon'=>'', 'controller'=>'atlas', 'action'=>'network-ex', 'routePath'=>'atlas/network-list', 'show'=>1, 'wiki' => 'placementNetworkEx',],//安置网络ex
             ['name'=>'Sponsor Network Ex', 'class'=>'', 'icon'=>'', 'controller'=>'atlas', 'action'=>'relation-ex', 'routePath'=>'atlas/relation-list', 'show'=>1, 'wiki' => 'sponsorNetworkEx',],//推荐网路ex
         ]
     ],
-//    'reconsume'=>[
-//        'name'=>'复销管理',
-//        'class' => '',
-//        'icon'=>'el-icon-shopping-bag-1',
-//        'controller'=>'reconsume',
-//        'action'=>'',
-//        'routePath'=>'reconsume',
-//        'show'=>1,
-//        'child'=>[
-//            ['name'=>'复销池余额列表', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'pool-list', 'routePath'=>'reconsume/pool-list', 'show'=>1,],
-////            ['name'=>'手动扣除月复销', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'deduct', 'routePath'=>'reconsume/deduct', 'show'=>1,],
-//            ['name'=>'复销余额调整审核', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'change-audit-list', 'routePath'=>'reconsume/change-audit-list', 'show'=>1,],
-//            ['name'=>'复销余额调整审核导出', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'change-audit-list-export', 'routePath'=>'reconsume/change-audit-list-export', 'show'=>0,],
-//            ['name'=>'修改并通过审核余额调整', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'change-audit-pass', 'routePath'=>'reconsume/change-audit-pass', 'show'=>0,],
-//            ['name'=>'审核余额调整', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'change-audit', 'routePath'=>'reconsume/change-audit', 'show'=>0,],
-//            ['name'=>'申请余额调整', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'change-audit-add', 'routePath'=>'reconsume/change-audit-add', 'show'=>0,],
-//            ['name'=>'删除余额调整', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'change-audit-delete', 'routePath'=>'reconsume/change-audit-delete', 'show'=>0,],
-//            //['name'=>'扣除复销审核', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'deduct-audit-list', 'routePath'=>'reconsume/deduct-audit-list', 'show'=>1,],
-//            ['name'=>'手动扣除月复销', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'deduct-audit-add', 'routePath'=>'reconsume/deduct-audit-add', 'show'=>0,],
-//            ['name'=>'复销流水', 'class'=>'', 'icon'=>'', 'controller'=>'reconsume', 'action'=>'flow-list', 'routePath'=>'reconsume/flow-list', 'show'=>1,],
-//        ]
-//    ],
     'bonus'=>[
         'name'=>'Bonus management',//奖金管理
         'class' => '',
@@ -214,104 +105,22 @@ return [
             ['name'=>'挂网操作', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'send-period', 'routePath'=>'bonus/send-period', 'show'=>0,],
             ['name'=>'Member bonus balance', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'balance-list', 'routePath'=>'bonus/balance-list', 'show'=>1, 'wiki' => 'memberBonusBalance'],//会员账户余额
             ['name'=>'会员奖金余额导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'balance-export', 'routePath'=>'bonus/balance-export', 'show'=>0,],
-//            ['name'=>'申请发放年度奖', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'cf-lx-apply', 'routePath'=>'bonus/cf-lx-apply', 'show'=>0,],
-//            ['name'=>'年度奖金发放审核', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'cf-lx-audit-list', 'routePath'=>'bonus/cf-lx-audit-list', 'show'=>1,],
-//            ['name'=>'年度奖发放审核操作', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'cf-lx-audit', 'routePath'=>'bonus/cf-lx-audit', 'show'=>0,],
-            //['name'=>'期奖金明细', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'period-detail', 'routePath'=>'bonus/period-detail', 'show'=>0,],
-//            ['name'=>'Latest bonus', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'new-period-bonus', 'routePath'=>'bonus/new-period-bonus', 'show'=>1,],//最新奖金
             ['name'=>'最新奖金导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'new-period-bonus-export', 'routePath'=>'bonus/new-period-bonus-export', 'show'=>0,],
             ['name'=>'Member bonus', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'other-period-bonus', 'routePath'=>'bonus/other-period-bonus', 'show'=>1, 'wiki' => 'memberBonus'],//往期奖金
             ['name'=>'往期奖金导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'other-period-bonus-export', 'routePath'=>'bonus/other-period-bonus-export', 'show'=>0,],
             ['name'=>'Bonus flow', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-bonus', 'routePath'=>'bonus/flow-bonus', 'show'=>1, 'wiki' => 'bonusFlow'],//奖金流水
             ['name'=>'奖金流水导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-bonus-export', 'routePath'=>'bonus/flow-bonus-export', 'show'=>0,],
-//            ['name'=>'车房养老奖流水', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-cf', 'routePath'=>'bonus/flow-cf', 'show'=>1,],
-//            ['name'=>'车房养老奖流水导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-cf-export', 'routePath'=>'bonus/flow-cf-export', 'show'=>0,],
-//            ['name'=>'领袖分红奖流水', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-lx', 'routePath'=>'bonus/flow-lx', 'show'=>1,],
-//            ['name'=>'领袖分红奖流水导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-lx-export', 'routePath'=>'bonus/flow-lx-export', 'show'=>0,],
-//            ['name'=>'复消积分流水', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-rp', 'routePath'=>'bonus/flow-rp', 'show'=>1,],
-//            ['name'=>'复消积分流水导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-rp-export', 'routePath'=>'bonus/flow-rp-export', 'show'=>0,],
-//            ['name'=>'兑换积分流水', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-exchange', 'routePath'=>'bonus/flow-exchange', 'show'=>1,],
             ['name'=>'兑换积分流水导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-exchange-export', 'routePath'=>'bonus/flow-exchange-export', 'show'=>0,],
-//            ['name'=>'会员余额流水', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-balance', 'routePath'=>'bonus/flow-balance', 'show'=>1,],
             ['name'=>'会员余额流水导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'flow-balance-export', 'routePath'=>'bonus/flow-balance-export', 'show'=>0,],
-//            ['name'=>'区域津贴核算', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'calc-qy', 'routePath'=>'bonus/calc-qy', 'show'=>1,],
-//            ['name'=>'区域津贴补发列表', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'resend-qy-list', 'routePath'=>'bonus/resend-qy-list', 'show'=>1,],
-//            ['name'=>'区域津贴补发列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'resend-qy-list-export', 'routePath'=>'bonus/resend-qy-list-export', 'show'=>0,],
-//            ['name'=>'申请补发区域津贴', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'resend-qy', 'routePath'=>'bonus/resend-qy', 'show'=>0,],
-//            ['name'=>'补发区域津贴审核列表', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'resend-qy-audit-list', 'routePath'=>'bonus/resend-qy-audit-list', 'show'=>1,],
-//            ['name'=>'补发区域津贴审核列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'resend-qy-audit-list-export', 'routePath'=>'bonus/resend-qy-audit-list-export', 'show'=>0,],
-//            ['name'=>'补发区域津贴审核操作', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'resend-qy-audit', 'routePath'=>'bonus/resend-qy-audit', 'show'=>0,],
-//            ['name'=>'补发区域津贴审核删除', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'resend-qy-audit-delete', 'routePath'=>'bonus/resend-qy-audit-delete', 'show'=>0,],
-//            ['name'=>'团队奖向下追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-qy', 'routePath'=>'bonus/trace-down-qy', 'show'=>1,],
-//            ['name'=>'团队奖下追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-qy-export', 'routePath'=>'bonus/trace-down-qy-export', 'show'=>0,],
-//            ['name'=>'团队奖向上追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-qy', 'routePath'=>'bonus/trace-up-qy', 'show'=>1,],
-//            ['name'=>'团队奖向上追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-qy-export', 'routePath'=>'bonus/trace-up-qy-export', 'show'=>0,],
-//            ['name'=>'荣衔奖向下追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-yc', 'routePath'=>'bonus/trace-down-yc', 'show'=>1,],
-//            ['name'=>'荣衔奖向下追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-yc-export', 'routePath'=>'bonus/trace-down-yc-export', 'show'=>0,],
-//            ['name'=>'荣衔奖贴向上追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-yc', 'routePath'=>'bonus/trace-up-yc', 'show'=>1,],
-//            ['name'=>'荣衔奖向上追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-yc-export', 'routePath'=>'bonus/trace-up-yc-export', 'show'=>0,],
-//            ['name'=>'服务奖向下追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-bd', 'routePath'=>'bonus/trace-down-bd', 'show'=>1,],
-//            ['name'=>'服务奖向下追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-bd-export', 'routePath'=>'bonus/trace-down-bd-export', 'show'=>0,],
-//            ['name'=>'服务奖贴向上追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-bd', 'routePath'=>'bonus/trace-up-bd', 'show'=>1,],
-//            ['name'=>'服务奖向上追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-bd-export', 'routePath'=>'bonus/trace-up-bd-export', 'show'=>0,],
-//            ['name'=>'推广奖向下追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-tg', 'routePath'=>'bonus/trace-down-tg', 'show'=>1,],
-//            ['name'=>'推广奖向下追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-tg-export', 'routePath'=>'bonus/trace-down-tg-export', 'show'=>0,],
-//            ['name'=>'推广奖贴向上追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-tg', 'routePath'=>'bonus/trace-up-tg', 'show'=>1,],
-//            ['name'=>'推广奖向上追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-tg-export', 'routePath'=>'bonus/trace-up-tg-export', 'show'=>0,],
-//            ['name'=>'消费奖向下追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-xf', 'routePath'=>'bonus/trace-down-xf', 'show'=>1,],
-//            ['name'=>'消费奖向下追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-xf-export', 'routePath'=>'bonus/trace-down-xf-export', 'show'=>0,],
-//            ['name'=>'消费奖贴向上追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-xf', 'routePath'=>'bonus/trace-up-xf', 'show'=>1,],
-//            ['name'=>'消费奖向上追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-xf-export', 'routePath'=>'bonus/trace-up-xf-export', 'show'=>0,],
-//            ['name'=>'业绩奖向下追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-yj', 'routePath'=>'bonus/trace-down-yj', 'show'=>1,],
-//            ['name'=>'业绩奖向下追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-yj-export', 'routePath'=>'bonus/trace-down-yj-export', 'show'=>0,],
-//            ['name'=>'业绩奖贴向上追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-yj', 'routePath'=>'bonus/trace-up-yj', 'show'=>1,],
-//            ['name'=>'业绩奖向上追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-yj-export', 'routePath'=>'bonus/trace-up-yj-export', 'show'=>0,],
-//            ['name'=>'共享奖向下追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-gx', 'routePath'=>'bonus/trace-down-gx', 'show'=>1,],
-//            ['name'=>'共享奖向下追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-gx-export', 'routePath'=>'bonus/trace-down-gx-export', 'show'=>0,],
-//            ['name'=>'共享奖贴向上追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-gx', 'routePath'=>'bonus/trace-up-gx', 'show'=>1,],
-//            ['name'=>'共享奖向上追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-gx-export', 'routePath'=>'bonus/trace-up-gx-export', 'show'=>0,],
-//            ['name'=>'管理奖向下追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-gl', 'routePath'=>'bonus/trace-down-gl', 'show'=>1,],
-//            ['name'=>'管理奖向下追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-gl-export', 'routePath'=>'bonus/trace-down-gl-export', 'show'=>0,],
-//            ['name'=>'管理奖贴向上追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-gl', 'routePath'=>'bonus/trace-up-gl', 'show'=>1,],
-//            ['name'=>'管理奖向上追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-gl-export', 'routePath'=>'bonus/trace-up-gl-export', 'show'=>0,],
             ['name'=>'Member performance', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'user-perf', 'routePath'=>'bonus/user-perf', 'show'=>1, 'wiki' => 'memberPerformance'],//用户业绩
-//            ['name'=>'荣衔业绩', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'yc-perf', 'routePath'=>'bonus/yc-perf', 'show'=>1,],
-//            ['name'=>'达标业绩', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'perf-standard', 'routePath'=>'bonus/perf-standard', 'show'=>1,],
-//            ['name'=>'达标业绩导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'perf-standard-export', 'routePath'=>'bonus/perf-standard-export', 'show'=>0,],
-//            ['name'=>'复销奖向下追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-fx', 'routePath'=>'bonus/trace-down-fx', 'show'=>1,],
-//            ['name'=>'复销奖向下追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-down-fx-export', 'routePath'=>'bonus/trace-down-fx-export', 'show'=>0,],
-//            ['name'=>'复销奖向上追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-fx', 'routePath'=>'bonus/trace-up-fx', 'show'=>1,],
-//            ['name'=>'复销奖向上追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-up-fx-export', 'routePath'=>'bonus/trace-up-fx-export', 'show'=>0,],
-//            ['name'=>'报单中心补贴追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-bt', 'routePath'=>'bonus/trace-bt', 'show'=>1,],
-//            ['name'=>'报单中心补贴追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-bt-export', 'routePath'=>'bonus/trace-bt-export', 'show'=>0,],
-//            ['name'=>'报单中心货补追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-fl', 'routePath'=>'bonus/trace-fl', 'show'=>1,],
-//            ['name'=>'报单中心货补追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-fl-export', 'routePath'=>'bonus/trace-fl-export', 'show'=>0,],
-//            ['name'=>'区域业绩提成追溯', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-fw', 'routePath'=>'bonus/trace-fw', 'show'=>1,],
-//            ['name'=>'区域业绩提成追溯导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'trace-fw-export', 'routePath'=>'bonus/trace-fw-export', 'show'=>0,],
             ['name'=>'Sales Record', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'perf-order', 'routePath'=>'bonus/perf-order', 'show'=>1, 'wiki' => 'salesRecord'],//业绩单
             ['name'=>'业绩单导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'perf-order-export', 'routePath'=>'bonus/perf-order-export', 'show'=>0,],
-//            ['name'=>'会员实时业绩', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'real-time-perf', 'routePath'=>'bonus/real-time-perf', 'show'=>1,],
-//            ['name'=>'Period performance', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'perf-period-list', 'routePath'=>'bonus/perf-period-list', 'show'=>1, 'wiki' => 'periodPerformance'],//期业绩
-//            ['name'=>'期业绩导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'perf-period-list-export', 'routePath'=>'bonus/perf-period-list-export', 'show'=>0,],
             ['name'=>'Monthly performance', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'perf-month', 'routePath'=>'bonus/perf-month', 'show'=>1, 'wiki' => 'monthlyPerformance'],//月业绩
             ['name'=>'月业绩导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'perf-month-export', 'routePath'=>'bonus/perf-month-export', 'show'=>0,],
-//            ['name'=>'Score-month', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'score-month', 'routePath'=>'bonus/score-month', 'show'=>1,],//月积分
             ['name'=>'月积分导出', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'score-month-export', 'routePath'=>'bonus/score-month-export', 'show'=>0,],
             ['name'=>'自动提现', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'auto-withdraw', 'routePath'=>'bonus/auto-withdraw', 'show'=>0,],
-//            ['name'=>'Adjust Performance', 'class'=>'', 'icon'=>'', 'controller'=>'bonus', 'action'=>'perf-adjustment', 'routePath'=>'bonus/perf-adjustment', 'show'=>1, 'wiki' => 'adjustPerformance'],//调整业绩
         ]
     ],
-    /*'report'=>[
-        'name'=>'报表管理',
-        'class' => '',
-        'icon'=>'el-icon-data-analysis',
-        'controller'=>'report',
-        'action'=>'',
-        'routePath'=>'report',
-        'show'=>1,
-        'child'=>[
-        ]
-    ],*/
     'finance'=>[
         'name'=>'Financial Management',
         'class' => '',
@@ -331,8 +140,6 @@ return [
             ['name'=>'申请调整会员余额', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'change-balance', 'routePath'=>'finance/change-balance', 'show'=>0,],
             ['name'=>'申请调整会员余额批量1导入', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'import-change-balance-to-excel-table', 'routePath'=>'finance/import-change-balance-to-excel-table', 'show'=>0,],
             ['name'=>'申请调整会员余额批量2添加', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'import-change-balance', 'routePath'=>'finance/import-change-balance', 'show'=>0,],
-//            ['name'=>'会员业绩调整列表', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'perf-audit-list', 'routePath'=>'finance/perf-audit-list', 'show'=>1,],
-//            ['name'=>'会员业绩调整列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'perf-audit-list-export', 'routePath'=>'finance/perf-audit-list-export', 'show'=>0,],
             ['name'=>'修改并通过审核业绩调整', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'perf-audit-pass', 'routePath'=>'finance/perf-audit-pass', 'show'=>0,],
             ['name'=>'审核会员业绩调整', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'perf-audit', 'routePath'=>'finance/perf-audit', 'show'=>0,],
             ['name'=>'删除审核调整会员业绩', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'perf-audit-delete', 'routePath'=>'finance/perf-audit-delete', 'show'=>0,],
@@ -340,40 +147,14 @@ return [
             ['name'=>'Transfer record list', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'transfer-list', 'routePath'=>'finance/transfer-list', 'show'=>1, 'wiki' => 'transferRecordList'],//转账记录列表
             ['name'=>'转账记录列表导出', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'transfer-list-export', 'routePath'=>'finance/transfer-list-export', 'show'=>0,],
             ['name'=>'Withdrawal management', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw', 'routePath'=>'finance/withdraw', 'show'=>1, 'wiki' => 'withdrawalManagement'], // 提现管理
-//            ['name'=>'提现管理-待传发票', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-0', 'routePath'=>'finance/withdraw-0', 'show'=>0,],
-//            ['name'=>'提现管理-提现待审核', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-0', 'routePath'=>'finance/withdraw-0', 'show'=>0,],
-//            ['name'=>'提现管理-提现已审核', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-2', 'routePath'=>'finance/withdraw-2', 'show'=>0,],
-//            ['name'=>'提现管理-提现待付款', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-3', 'routePath'=>'finance/withdraw-3', 'show'=>0,],
-//            ['name'=>'提现管理-提现已付款', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-6', 'routePath'=>'finance/withdraw-6', 'show'=>0,],
-//            ['name'=>'提现管理-付款失败', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-4', 'routePath'=>'finance/withdraw-4', 'show'=>0,],
-//            ['name'=>'提现管理-提现退回', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-7', 'routePath'=>'finance/withdraw-7', 'show'=>0,],
             ['name'=>'Review withdrawal info', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-status', 'routePath'=>'finance/withdraw-status', 'show'=>0,], // 审核提现信息
             ['name'=>'提现审核', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-status-audit', 'routePath'=>'finance/withdraw-status-audit', 'show'=>0,],
             ['name'=>'提现退回', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-status-return', 'routePath'=>'finance/withdraw-status-return', 'show'=>0,],
             ['name'=>'提现付款', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-status-pay', 'routePath'=>'finance/withdraw-status-pay', 'show'=>0,],
             ['name'=>'提现取消', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-status-cancel', 'routePath'=>'finance/withdraw-status-cancel', 'show'=>0,],
-            //['name'=>'发票信息添加', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'invoice-audit-add', 'routePath'=>'finance/invoice-audit-add', 'show'=>0,],
-            //['name'=>'发票信息编辑', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'invoice-audit-edit', 'routePath'=>'finance/invoice-audit-edit', 'show'=>0,],
-            //['name'=>'标记付款失败批量1导入', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'import-withdraws-to-excel-table', 'routePath'=>'finance/import-withdraws-to-excel-table', 'show'=>0,],
-            //['name'=>'标记付款失败批量2添加', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'import-withdraws-paid-false', 'routePath'=>'finance/import-withdraws-paid-false', 'show'=>0,],
-//            ['name'=>'发票管理', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'invoice-audit', 'routePath'=>'finance/invoice-audit', 'show'=>1,],
-//            ['name'=>'发票审核', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'invoice-audit-audit', 'routePath'=>'finance/invoice-audit-audit', 'show'=>0,],
-//            ['name'=>'发票删除', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'invoice-audit-delete', 'routePath'=>'finance/invoice-audit-delete', 'show'=>0,],
-            //['name'=>'填写发票', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'invoice-audit-add', 'routePath'=>'finance/invoice-audit-add', 'show'=>0,],
-            //['name'=>'发票流水', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'invoice-flow', 'routePath'=>'finance/invoice-flow', 'show'=>1,],
-            //['name'=>'发票调整管理', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'invoice-balance-audit', 'routePath'=>'finance/invoice-balance-audit', 'show'=>1,],
-            //['name'=>'发票调整添加', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'invoice-balance-audit-add', 'routePath'=>'finance/invoice-balance-audit-add', 'show'=>0,],
             ['name'=>'提现导出', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'withdraw-export', 'routePath'=>'finance/withdraw-export', 'show'=>0,],
-            // ['name'=>'交易类型管理', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'deal-type', 'routePath'=>'finance/deal-type', 'show'=>1, 'wiki' => 'dealTypeManagement'],
-            // ['name'=>'交易类型添加', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'deal-type-add', 'routePath'=>'finance/deal-type-add', 'show'=>0,],
-            // ['name'=>'交易类型修改', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'deal-type-edit', 'routePath'=>'finance/deal-type-edit', 'show'=>0,],
-            // ['name'=>'Historical bonus balance', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'history-bonus', 'routePath'=>'finance/history-bonus', 'show'=>1, 'wiki' => 'historicalBonusBalance'],// 历史奖金余额
-            // ['name'=>'历史奖金余额导出', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'history-bonus-export', 'routePath'=>'finance/history-bonus-export', 'show'=>0,],
             ['name'=>'Recharge management', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'recharge', 'routePath'=>'finance/recharge', 'show'=>1, 'wiki' => 'rechargeManagement'], // 充值管理
             ['name'=>'充值导出', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'recharge-export', 'routePath'=>'finance/recharge-export', 'show'=>0,],
-            //['name'=>'充值管理-充值待审核', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'recharge-0', 'routePath'=>'finance/recharge-0', 'show'=>0,],
-            //['name'=>'充值管理-充值已审核', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'recharge-1', 'routePath'=>'finance/recharge-1', 'show'=>0,],
-            //['name'=>'充值管理-充值已驳回', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'recharge-2', 'routePath'=>'finance/recharge-2', 'show'=>0,],
             ['name'=>'审核充值信息', 'class'=>'', 'icon'=>'', 'controller'=>'finance', 'action'=>'recharge-status', 'routePath'=>'finance/recharge-status', 'show'=>0,],
         ]
     ],
@@ -387,10 +168,6 @@ return [
         'show'=>1,
         'wiki' => 'articleManagement',
         'child'=>[
-//            ['name'=>'Category Management', 'class'=>'', 'icon'=>'', 'controller'=>'article', 'action'=>'category', 'routePath'=>'article/category', 'show'=>1, 'wiki' => 'categoryManagement'],//分类管理
-//            ['name'=>'添加分类', 'class'=>'', 'icon'=>'', 'controller'=>'article', 'action'=>'category-add', 'routePath'=>'article/category-add', 'show'=>0,],
-//            ['name'=>'删除分类', 'class'=>'', 'icon'=>'', 'controller'=>'article', 'action'=>'category-delete', 'routePath'=>'article/category-delete', 'show'=>0,],
-//            ['name'=>'分类排序', 'class'=>'', 'icon'=>'', 'controller'=>'article', 'action'=>'category-sort', 'routePath'=>'article/category-sort', 'show'=>0,],
             ['name'=>'Article Management', 'class'=>'', 'icon'=>'', 'controller'=>'article', 'action'=>'index', 'routePath'=>'article/index', 'show'=>1, 'wiki' => 'articleManagement'],//文章列表
             ['name'=>'添加文章', 'class'=>'', 'icon'=>'', 'controller'=>'article', 'action'=>'add', 'routePath'=>'article/add', 'show'=>0,],
             ['name'=>'编辑文章', 'class'=>'', 'icon'=>'', 'controller'=>'article', 'action'=>'edit', 'routePath'=>'article/edit', 'show'=>0,],
@@ -421,20 +198,6 @@ return [
             ['name'=>'Un-Hide', 'class'=>'', 'icon'=>'', 'controller'=>'ad', 'action'=>'ad-un-hide', 'routePath'=>'ad/ad-un-hide', 'show'=>0,],
         ]
     ],
-//    'message'=>[
-//        'name'=>'站内信管理',
-//        'class' => '',
-//        'icon'=>'fa fa-envelope-o',
-//        'controller'=>'message',
-//        'action'=>'',
-//        'routePath'=>'message',
-//        'show'=>1,
-//        'child'=>[
-//            ['name'=>'站内信列表', 'class'=>'', 'icon'=>'', 'controller'=>'message', 'action'=>'list', 'routePath'=>'message/list', 'show'=>1,],
-//            ['name'=>'添加站内信', 'class'=>'', 'icon'=>'', 'controller'=>'message', 'action'=>'add', 'routePath'=>'message/add', 'show'=>0,],
-//            ['name'=>'删除站内信', 'class'=>'', 'icon'=>'', 'controller'=>'message', 'action'=>'delete', 'routePath'=>'message/delete', 'show'=>0,],
-//        ]
-//    ],
     'file'=>[
         'name'=>'File management',//文件管理
         'class' => '',
@@ -446,14 +209,8 @@ return [
         'wiki' => 'fileManagement',
         'child'=>[
             ['name'=>'Export file', 'class'=>'', 'icon'=>'', 'controller'=>'file', 'action'=>'export', 'routePath'=>'file/export', 'show'=>1, 'wiki' => 'exportFile'],//导出文件
-//            ['name'=>'删除文件', 'class'=>'', 'icon'=>'', 'controller'=>'file', 'action'=>'export-delete', 'routePath'=>'file/export-delete', 'show'=>0,],
-
         ]
     ],
-//    'sys' => [
-//        'name'=>'系统相关',
-//        'class' => 'list-header',
-//    ],
     'admin'=>[
         'name'=>'Administrator',//管理员管理
         'class' => '',
@@ -511,23 +268,11 @@ return [
             ['name'=>'皇冠星级配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'bonus-dec-level', 'routePath'=>'config/bonus-crown-level', 'show'=>0,],
             ['name'=>'级别配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'bonus-dec-level', 'routePath'=>'config/bonus-dec-level', 'show'=>0,],
             ['name'=>'管理星级配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'bonus-emp-level', 'routePath'=>'config/bonus-emp-level', 'show'=>0,],
-//            ['name'=>'期数配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'period', 'routePath'=>'config/period', 'show'=>1,],
-//            ['name'=>'会员注册类型配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'reg-type', 'routePath'=>'config/reg-type', 'show'=>1,],
-//            ['name'=>'会员注册类型编辑', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'reg-type-edit', 'routePath'=>'config/reg-type-edit', 'show'=>0,],
-//            ['name'=>'维护注册协议', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'pact-edit', 'routePath'=>'config/pact-edit', 'show'=>0,],
-//            ['name'=>'第三方接口', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'api-opt', 'routePath'=>'config/api-opt', 'show'=>1,],
-//            ['name'=>'OCR接口编辑', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'ocr-api-edit', 'routePath'=>'config/ocr-api-edit', 'show'=>0,],
-//            ['name'=>'短信接口编辑', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'ocr-api-edit', 'routePath'=>'config/ocr-api-edit', 'show'=>0,],
-//            ['name'=>'短信管理', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'sms', 'routePath'=>'config/sms', 'show'=>1,],
-//            ['name'=>'积分配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'score', 'routePath'=>'config/score', 'show'=>1, 'wiki' => 'scoreConfig'],
             ['name'=>'转账配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'transfer', 'routePath'=>'config/transfer', 'show'=>1, 'wiki' => 'transferConfig'],
             ['name'=>'其他配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'other', 'routePath'=>'config/other', 'show'=>1, 'wiki' => 'otherConfig'],
             ['name'=>'会员级别配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'dec-level', 'routePath'=>'config/dec-level', 'show'=>1, 'wiki' => 'decLevelConfig'],
             ['name'=>'添加会员级别', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'dec-level-add', 'routePath'=>'config/dec-level-add', 'show'=>0,],
             ['name'=>'编辑会员级别', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'dec-level-edit', 'routePath'=>'config/dec-level-edit', 'show'=>0,],
-//            ['name'=>'会员聘级配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'emp-level', 'routePath'=>'config/emp-level', 'show'=>1, 'wiki' => 'empLevelConfig'],
-//            ['name'=>'添加会员聘级', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'emp-level-add', 'routePath'=>'config/emp-level-add', 'show'=>0,],
-//            ['name'=>'编辑会员聘级', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'emp-level-edit', 'routePath'=>'config/emp-level-edit', 'show'=>0,],
             ['name'=>'报单中心级别配置', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'dec-role', 'routePath'=>'config/dec-role', 'show'=>1, 'wiki' => 'decRoleConfig'],
             ['name'=>'编辑报单中心级别', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'dec-role-edit', 'routePath'=>'config/dec-role-edit', 'show'=>0,],
             ['name'=>'汇率列表', 'class'=>'', 'icon'=>'', 'controller'=>'config', 'action'=>'currencies-conversions', 'routePath'=>'currency/currencies-conversions', 'show'=>1,  'wiki' => 'exchangeRateConfig'],

+ 0 - 7
backendApi/modules/v1/controllers/AtlasController.php

@@ -67,22 +67,16 @@ class AtlasController extends BaseController {
     public function actionMainUserInfo() {
         $userName = Yii::$app->request->get('userName', '');
         $periodNum = Yii::$app->request->get('periodNum', null);
-        $period = Period::instance();
-        $yearMonth = $period->getYearMonth($periodNum);
         if ($userName !== '') {
-            //$oneUser = Info::getUserByUserNameFromUserInfoTable($userName);
             if (!$userId = Info::getUserIdByUserName($userName)) {
-                
                 return static::notice(Yii::t('ctx', 'memberDoesNotExist'), 400); // 会员不存在
             }
         } else {
             $userId = Yii::$app->params['mainUserId'];
         }
         $baseInfo = Info::baseInfo($userId, $periodNum);
-//        print_r($baseInfo);exit;
         $decLevelConfig = Cache::getDecLevelConfig();
         $empLevelConfig = Cache::getEmpLevelConfig();
-        $crownLevelConfig = Cache::getStarCrownLevelConfig();
         return static::notice([
             [
                 'TOP_RELATION_DEEP' => $baseInfo['RELATION_DEEP'],
@@ -93,7 +87,6 @@ class AtlasController extends BaseController {
                 'PERIOD_AT' => $baseInfo['PERIOD_AT'],
                 'DEC_LV_NAME' => $decLevelConfig[$baseInfo['DEC_LV']]['LEVEL_NAME'],
                 'EMP_LV_NAME' => isset($empLevelConfig[$baseInfo['EMP_LV']])?$empLevelConfig[$baseInfo['EMP_LV']]['LEVEL_NAME']:'0-Star Director',
-                'CROWN_LV_NAME' => isset($crownLevelConfig[$baseInfo['CROWN_LV']])?$crownLevelConfig[$baseInfo['CROWN_LV']]['LEVEL_NAME']:'0-Star Crown',
                 'leaf' => false,
                 'icon' => 'el-icon-user-solid',
                 'children' => null,

+ 2 - 50
backendApi/modules/v1/controllers/BonusController.php

@@ -74,9 +74,7 @@ class BonusController extends BaseController {
     public $modelClass = FlowBonus::class;
 
     public function behaviors() {
-        $behaviors = parent::behaviors();
-        //$behaviors['contentNegotiator']['formats']['text/html'] = Response::FORMAT_JSON;
-        return $behaviors;
+        return parent::behaviors();
     }
 
     /**
@@ -109,10 +107,6 @@ class BonusController extends BaseController {
         $params[':PERIOD_NUM'] = $nowPeriodNum;
         $data = Period::lists($condition, $params, ['orderBy' => 'PERIOD_NUM DESC']);
         foreach ($data['list'] as $key => $value) {
-            // 是否可封期
-            $data['list'][$key]['IS_CAN_CLOSE'] = $periodObj->isCanClose($value['PERIOD_NUM']);
-            // 是否可生成业绩单
-            $data['list'][$key]['IS_CAN_PERF'] = $periodObj->isCanPerf($value['PERIOD_NUM']);
             // 是否可结算
             $data['list'][$key]['IS_CAN_CALC'] = $periodObj->isCanCalc($value['PERIOD_NUM']);
             // 是否可挂网
@@ -124,47 +118,7 @@ class BonusController extends BaseController {
     }
 
     /**
-     * 封期
-     * @return mixed
-     * @throws \yii\db\Exception
-     * @throws HttpException
-     */
-    public function actionClosePeriod() {
-        $periodNum = \Yii::$app->request->get('periodNum');
-        if (!$periodNum) {
-            return static::notice('期数不存在', 400);
-        }
-        $formModel = new PeriodForm();
-        if ($formModel->load(Yii::$app->request->get(), '') && $formModel->closePeriod()) {
-            // Log::adminHandle('第' . $periodNum . '期封期成功');
-            return static::notice('封期成功');
-        } else {
-            return static::notice(Form::formatErrorsForApi($formModel->getErrors()), 400);
-        }
-    }
-
-    /**
-     * 计算业绩并生成业绩单
-     * @return mixed
-     * @throws HttpException
-     */
-    public function actionPerfPeriod() {
-        $periodNum = \Yii::$app->request->get('periodNum');
-        if (!$periodNum) {
-            return static::notice('期数不存在', 400);
-        }
-        $formModel = new PeriodForm();
-        $formModel->scenario = 'perf';
-        if ($formModel->load(Yii::$app->request->get(), '') && $formModel->perfWebToAsync()) {
-            // Log::adminHandle('第' . $periodNum . '期封生成业绩单');
-            return static::notice('生成业绩单已开始处理,请等待');
-        } else {
-            return static::notice(Form::formatErrorsForApi($formModel->getErrors()), 400);
-        }
-    }
-
-    /**
-     * 结算封期
+     * 结算
      * @return mixed
      * @throws HttpException
      */
@@ -176,7 +130,6 @@ class BonusController extends BaseController {
         $formModel = new PeriodForm();
         $formModel->scenario = 'calc';
         if ($formModel->load(Yii::$app->request->get(), '') && $formModel->calcWebToAsync()) {
-            // Log::adminHandle('第' . $periodNum . '期结算');
             return static::notice('结算已开始处理,请等待');
         } else {
             return static::notice(Form::formatErrorsForApi($formModel->getErrors()), 400);
@@ -248,7 +201,6 @@ class BonusController extends BaseController {
             'DEAL_TYPE_NAME' => 'DEAL_TYPE_ID',
             'LAST_DEC_LV_NAME' => 'LAST_DEC_LV',
             'LAST_EMP_LV_NAME' => 'LAST_EMP_LV',
-//            'LAST_STATUS_NAME' => 'LAST_STATUS',
             'AMOUNT' => 'AMOUNT',
             'TOTAL' => 'TOTAL',
             'ADMIN_NAME' => 'ADMIN_NAME',

+ 0 - 3
backendApi/modules/v1/controllers/ConfigController.php

@@ -120,13 +120,10 @@ class ConfigController extends BaseController {
         $decLevel = Cache::getDecLevelConfig();
         // 获取会员聘级相关参数
         $empLevel = Cache::getEmpLevelConfig();
-        // 获取会员星级相关参数
-        $crownLevel = Cache::getStarCrownLevelConfig();
         $result = [
             'config' => $configs,
             'decLevel' => $decLevel,
             'empLevel' => $empLevel,
-            'crownLevel' => $crownLevel,
         ];
         return static::notice($result);
     }

+ 0 - 4
backendApi/modules/v1/controllers/SiteController.php

@@ -71,15 +71,12 @@ class SiteController extends BaseController
         $decLevels = Cache::getDecLevelConfig();
         // 管理星级
         $empLevels = Cache::getEmpLevelConfig();
-        // 皇冠星级
-        $crownLevels = Cache::getStarCrownLevelConfig();
         // 注册类型
         $regTypes = Cache::getRegType();
         // 交易类型
         $dealTypes = Cache::getDealType();
         // 体系
         $systems = [];
-//        $systems = UserSystem::getAllSystems();
         // 菜单
         $menu = require Yii::getAlias('@backendApi/config/menu.php');
         $menu = $this->_childMenu($menu);
@@ -109,7 +106,6 @@ class SiteController extends BaseController
         return [
             'decLevels' => $decLevels,
             'empLevels' => $empLevels,
-            'crownLevels' => $crownLevels,
             'regTypes' => $regTypes,
             'dealTypes' => $dealTypes,
             'systems' => $systems,

+ 0 - 3
backendApi/modules/v1/models/lists/atlas/NetworkList.php

@@ -44,7 +44,6 @@ class NetworkList extends \common\libs\dataList\DataList implements DataListInte
         $mainUserInfo = Info::baseInfo($userId, $periodNum);
         $decLevelConfig = Cache::getDecLevelConfig();
         $empLevelConfig = Cache::getEmpLevelConfig();
-        $crownLevelConfig = Cache::getStarCrownLevelConfig();
         $param = [];
         if ( $this->pageSize ) $param['pageSize'] = $this->pageSize;
         if ( $this->page !== null ) $param['page'] = $this->page;
@@ -52,7 +51,6 @@ class NetworkList extends \common\libs\dataList\DataList implements DataListInte
         foreach($this->listData['list'] as $key=>$value){
             $userBaseInfo = Info::baseInfo($value['USER_ID'], $periodNum);
             $this->listData['list'][$key]['LIST_PERIOD_NUM'] = $periodNum?$periodNum:$period->getNowPeriodNum();
-//            $this->listData['list'][$key]['COUNT_DEEP'] = (int)($userBaseInfo['NETWORK_DEEP']-$mainUserInfo['NETWORK_DEEP']);
             $this->listData['list'][$key]['COUNT_DEEP'] = (int)($userBaseInfo['NETWORK_DEEP']);
             $this->listData['list'][$key]['USER_NAME'] = $userBaseInfo['USER_NAME'];
             $this->listData['list'][$key]['SEE_USER_NAME'] = $userBaseInfo['USER_NAME'];
@@ -60,7 +58,6 @@ class NetworkList extends \common\libs\dataList\DataList implements DataListInte
             $this->listData['list'][$key]['PERIOD_AT'] = $userBaseInfo['PERIOD_AT'];
             $this->listData['list'][$key]['DEC_LV_NAME'] = $decLevelConfig[$userBaseInfo['DEC_LV']]['LEVEL_NAME'];
             $this->listData['list'][$key]['EMP_LV_NAME'] = isset($empLevelConfig[$userBaseInfo['EMP_LV']])?$empLevelConfig[$userBaseInfo['EMP_LV']]['LEVEL_NAME']:$empLevelConfig[EmployLevel::getDefaultLevelId()]['LEVEL_NAME'];
-            $this->listData['list'][$key]['CROWN_LV_NAME'] = isset($crownLevelConfig[$userBaseInfo['CROWN_LV']]) ? $crownLevelConfig[$userBaseInfo['CROWN_LV']]['LEVEL_NAME'] : $crownLevelConfig[StarCrownLevel::getDefaultLevelId()]['LEVEL_NAME'];
         }
         $this->listData['periodNum'] = $periodNum;
         $this->listData['listTopDeep'] = $mainUserInfo['NETWORK_DEEP'];

+ 0 - 2
backendApi/modules/v1/models/lists/atlas/RelationList.php

@@ -42,7 +42,6 @@ class RelationList extends \common\libs\dataList\DataList implements DataListInt
         $mainUserInfo = Info::baseInfo($userId, $periodNum);
         $decLevelConfig = Cache::getDecLevelConfig();
         $empLevelConfig = Cache::getEmpLevelConfig();
-        $crownLevelConfig = Cache::getStarCrownLevelConfig();
         $param = [];
         if ( $this->pageSize ) $param['pageSize'] = $this->pageSize;
         if ( $this->page !== null ) $param['page'] = $this->page;
@@ -57,7 +56,6 @@ class RelationList extends \common\libs\dataList\DataList implements DataListInt
             $this->listData['list'][$key]['PERIOD_AT'] = $userBaseInfo['PERIOD_AT'];
             $this->listData['list'][$key]['DEC_LV_NAME'] = $decLevelConfig[$userBaseInfo['DEC_LV']]['LEVEL_NAME'];
             $this->listData['list'][$key]['EMP_LV_NAME'] = isset($empLevelConfig[$userBaseInfo['EMP_LV']]) ? $empLevelConfig[$userBaseInfo['EMP_LV']]['LEVEL_NAME'] : $empLevelConfig[EmployLevel::getDefaultLevelId()]['LEVEL_NAME'];
-            $this->listData['list'][$key]['CROWN_LV_NAME'] = isset($crownLevelConfig[$userBaseInfo['CROWN_LV']]) ? $crownLevelConfig[$userBaseInfo['CROWN_LV']]['LEVEL_NAME'] : $crownLevelConfig[StarCrownLevel::getDefaultLevelId()]['LEVEL_NAME'];
         }
         $this->listData['periodNum'] = $periodNum;
         $this->listData['listTopDeep'] = $mainUserInfo['RELATION_DEEP'];

+ 0 - 4
backendApi/modules/v1/models/lists/bonus/PeriodBonusList.php

@@ -40,11 +40,9 @@ class PeriodBonusList extends \common\libs\dataList\DataList implements DataList
     {
         $yearMonth = $this->others['yearMonth'];
         $this->listData = CalcBonus::lists($this->condition, $this->params, [
-//            'select'=>'CB.*, UP.SURPLUS_1L AS UP_SURPLUS_1L, UP.SURPLUS_2L AS UP_SURPLUS_2L, UP.SURPLUS_3L AS UP_SURPLUS_3L,UI.CON_UID,UI.REC_UID',
             'select'=>'CB.*,UI.CON_UID,UI.REC_UID',
             'from' => CalcBonus::tableName().' AS CB',
             'join' => [
-//                ['LEFT JOIN', UserPerf::tableName() . ' AS UP', 'CB.USER_ID=UP.USER_ID'],
                 ['LEFT JOIN', UserInfo::tableName() . ' AS UI', 'CB.USER_ID=UI.USER_ID'],
             ],
             'yearMonth' => $yearMonth,
@@ -57,9 +55,7 @@ class PeriodBonusList extends \common\libs\dataList\DataList implements DataList
             foreach ($this->listData['list'] as $key => $value) {
                 $this->listData['list'][$key]['LAST_DEC_LV_NAME'] = Cache::getDecLevelConfig()[$value['LAST_DEC_LV']]['LEVEL_NAME'];
                 $this->listData['list'][$key]['LAST_EMP_LV_NAME'] = Cache::getEmpLevelConfig()[$value['LAST_EMP_LV']]['LEVEL_NAME'];
-                $this->listData['list'][$key]['LAST_CROWN_LV_NAME'] = Cache::getStarCrownLevelConfig()[$value['LAST_CROWN_LV']]['LEVEL_NAME'] ?? $value['LAST_CROWN_LV'];
                 $this->listData['list'][$key]['LAST_STATUS_NAME'] = Tool::paramConvert(Yii::$app->params['userStatus'])[$value['LAST_STATUS']]['label'];
-
                 $this->listData['list'][$key]['LAST_REC_USER_NAME'] = Info::getUserNameByUserId($value['REC_UID']);
                 $this->listData['list'][$key]['LAST_REC_REAL_NAME'] = Info::getUserRealNameByUserId($value['REC_UID']);
                 $this->listData['list'][$key]['LAST_CON_USER_NAME'] = Info::getUserNameByUserId($value['CON_UID']);

+ 1 - 53
backendApi/modules/v1/models/lists/user/IndexList.php

@@ -94,9 +94,7 @@ class IndexList extends \common\libs\dataList\DataList implements DataListInterf
     public function getColumn(){
         $decLevelConfig = Cache::getDecLevelConfig();
         $empLevelConfig = Cache::getEmpLevelConfig();
-        $crownLevelConfig = Cache::getStarCrownLevelConfig();
         $decRoleConfig = DecRole::getAllData();
-        $systemConfig = UserSystem::getAllSystems();
         $openBankConfig = OpenBank::getAllOpenBank();
         $regionConfig = Cache::getRegionConfig();
         if(!$this->columns){
@@ -134,12 +132,6 @@ class IndexList extends \common\libs\dataList\DataList implements DataListInterf
                     'header' => Yii::t('ctx', 'country'),
                     'headerOther' => ['width' => '110'],
                 ],
-//                'ALLOW_LOGIN' => [
-//                    'header' => Yii::t('ctx', 'filterAllowLogin'),
-//                    'value' => function($row) {
-//                        return $row['ALLOW_LOGIN'] == 1 ? Yii::t('ctx', 'allowLogin') : Yii::t('ctx', 'prohibitLogin');
-//                    },
-//                    ],
                 'CREATED_AT' => [
                     'header' => Yii::t('ctx', 'joiningDate'),
                     'value' => function($row) {
@@ -212,30 +204,6 @@ class IndexList extends \common\libs\dataList\DataList implements DataListInterf
                         'tag'=>['type'=>'warning', 'size' => 'small', 'class'=>'no-border']
                     ],
                 ],
-                'CROWN_LV_NAME' => [
-                    'header' => Yii::t('ctx', 'highestCrown'),
-                    'headerOther' => [
-                        'width' => '180',
-                    ],
-                    'value' => function($row) use($crownLevelConfig) {
-                        return isset($crownLevelConfig[$row['CROWN_LV']]) ? $crownLevelConfig[$row['CROWN_LV']]['LEVEL_NAME'] : $crownLevelConfig[StarCrownLevel::getDefaultLevelId()]['LEVEL_NAME'];
-                    },
-                    'valueOther' => [
-                        'tag'=>['type'=>'warning', 'size' => 'small', 'class'=>'no-border']
-                    ],
-                ],
-                'LAST_CROWN_LV_NAME' => [
-                    'header' => Yii::t('ctx', 'latestCrown'),
-                    'headerOther' => [
-                        'width' => '180',
-                    ],
-                    'value' => function($row) use($crownLevelConfig) {
-                        return isset($crownLevelConfig[$row['LAST_CROWN_LV']]) ? $crownLevelConfig[$row['LAST_CROWN_LV']]['LEVEL_NAME'] : $crownLevelConfig[StarCrownLevel::getDefaultLevelId()]['LEVEL_NAME'];
-                    },
-                    'valueOther' => [
-                        'tag'=>['type'=>'warning', 'size' => 'small', 'class'=>'no-border']
-                    ],
-                ],
                 'REC_USER_NAME_ACTUAL' => [
                     'header' => Yii::t('ctx', 'recommendationNo'),
                     'headerOther' => ['width' => '140'],
@@ -252,18 +220,7 @@ class IndexList extends \common\libs\dataList\DataList implements DataListInterf
                     'header' => Yii::t('ctx', 'placementName'),
                     'headerOther' => ['width' => '190'],
                 ],
-//                'CON_USER_NAME' => [
-//                    'header' => Yii::t('ctx', 'placementNo'),
-//                    'headerOther' => ['width' => '140'],
-//                ],
-//                'CON_REAL_NAME' => [
-//                    'header' => Yii::t('ctx', 'placementName'),
-//                    'headerOther' => ['width' => '140'],
-//                ],
-//                'RELATIVE_LOCATION' => [
-//                    'header' => Yii::t('ctx', 'resettlementArea'),
-//                    'headerOther' => ['width' => '140'],
-//                ],
+//                '
                 'MOBILE' => [
                     'header' => Yii::t('ctx', 'phoneNumber'),
                     'value' => function($row) {
@@ -271,13 +228,6 @@ class IndexList extends \common\libs\dataList\DataList implements DataListInterf
                     },
                     'headerOther' => ['width' => '120'],
                 ],
-//                'TEL' => [
-//                    'header' => Yii::t('ctx', 'alternatePhoneNumber'),
-//                    'value' => function($row) {
-//                        return "\t".$row['TEL'];
-//                    },
-//                    'headerOther' => ['width' => '180'],
-//                ],
                 'DEC_USER_NAME' => [
                     'header' => Yii::t('ctx', 'stockistCode'),
                     'headerOther' => ['width' => '150'],
@@ -411,8 +361,6 @@ class IndexList extends \common\libs\dataList\DataList implements DataListInterf
                 'LAST_EMP_LV_NAME'=> ['name'=> Yii::t('ctx', 'latestDirector'), 'other'=> 'empLevel'],
                 'CROWN_LV_NAME'=> ['name'=> Yii::t('ctx', 'highestCrown'), 'other'=> 'crownLevel'],
                 'LAST_CROWN_LV_NAME'=> ['name'=> Yii::t('ctx', 'latestCrown'), 'other'=> 'crownLevel'],
-//                'REC_USER_NAME'=> ['name'=> Yii::t('ctx', 'recommendationNo')],
-//                'CON_USER_NAME'=> ['name'=> Yii::t('ctx', 'placementNo')],
                 'MOBILE'=> ['name'=> Yii::t('ctx', 'phoneNumber')],
                 'DEC_USER_NAME'=> ['name'=> Yii::t('ctx', 'stockistCode')],
                 'IS_DEC'=> ['name'=> Yii::t('ctx', 'stockistOrNot'), 'other'=> 'yesOrNo'],

+ 2 - 4
common/components/ActiveRecord.php

@@ -284,9 +284,8 @@ class ActiveRecord extends \yii\db\ActiveRecord {
         self::prepare($condition, $params, $argv, true);
         unset($condition, $params, $argv);
         $countQuery = clone self::$query;
-        // self::$rawSql = self::$query->createCommand()->getRawSql();
-        // var_dump(self::$rawSql);exit;
         $count = $countQuery->count(self::$argv['count']); // 得到总数
+
         $pagination = new Pagination(['totalCount' => $count]);
         $pagination->setPageSize(self::$argv['pageSize']);
         if(self::$argv['page'] !== null){
@@ -302,9 +301,8 @@ class ActiveRecord extends \yii\db\ActiveRecord {
         unset($countQuery);
         $startNum = $pagination->page * $pagination->pageSize + 1;
         return [
-            'list' => $lists ? $lists : [],
+            'list' => $lists ?: [],
             'pagination' => $pagination,
-            // 'sql'=self::$rawSql,
             'currentPage'=>$pagination->page,
             'totalPages'=>$pagination->pageCount,
             'startNum' => $startNum,

+ 0 - 73
common/helpers/Cache.php

@@ -194,14 +194,6 @@ class Cache
         return DealType::getFromCache();
     }
 
-    /**
-     *  更新报单级别
-     * @return array|\yii\db\ActiveRecord[]
-     */
-    public static function updateDealType(){
-        return DealType::updateToCache();
-    }
-
     /**
      * 获取地区
      * @return array|mixed|\yii\db\ActiveRecord[]
@@ -210,14 +202,6 @@ class Cache
         return Region::getFromCache();
     }
 
-    /**
-     *  更新地区
-     * @return array|\yii\db\ActiveRecord[]
-     */
-    public static function updateRegionConfig(){
-        return Region::updateToCache();
-    }
-
     /**
      * 获取聘级
      * @return array|mixed|\yii\db\ActiveRecord[]
@@ -226,14 +210,6 @@ class Cache
         return EmployLevel::getFromCache();
     }
 
-    /**
-     * 获取星级
-     * @return array|mixed|\yii\db\ActiveRecord[]
-     */
-    public static function getStarCrownLevelConfig(){
-        return StarCrownLevel::getFromCache();
-    }
-
     /**
      *  更新管理员角色
      * @return array|\yii\db\ActiveRecord[]
@@ -242,7 +218,6 @@ class Cache
         return AdminRole::updateToCache();
     }
 
-
     /**
      * 获取管理员角色
      * @return array|mixed|\yii\db\ActiveRecord[]
@@ -267,14 +242,6 @@ class Cache
         return RegType::getFromCache();
     }
 
-    /**
-     *  更新报单级别
-     * @return array|\yii\db\ActiveRecord[]
-     */
-    public static function updateRegType(){
-        return RegType::updateToCache();
-    }
-
     /**
      * 获取用户基本信息
      * @param $userId
@@ -340,30 +307,6 @@ class Cache
         return $prefix.$key;
     }
 
-    /**
-     * 获取短信模板通过报单级别
-     * @return array|mixed
-     */
-    public static function getSmsTemplateByDec(){
-        return SmsTemplate::getDecFromCache();
-    }
-
-    /**
-     * 获取短信模板通过聘级
-     * @return array|mixed
-     */
-    public static function getSmsTemplateByEmp(){
-        return SmsTemplate::getEmpFromCache();
-    }
-
-    /**
-     * 获取提现等级
-     * @return array|mixed|\yii\db\ActiveRecord[]
-     */
-    public static function getWithdrawLevel(){
-        return WithdrawLevel::getFromCache();
-    }
-
     /**
      * 获取报单级别
      * @return array|mixed|\yii\db\ActiveRecord[]
@@ -372,14 +315,6 @@ class Cache
         return OcrApi::getFromCache();
     }
 
-    /**
-     *  更新报单级别
-     * @return array|\yii\db\ActiveRecord[]
-     */
-    public static function updateOcrApiConfig(){
-        return OcrApi::updateToCache();
-    }
-
     /**
      * 获取短信接口设置
      * @return array|mixed|\yii\db\ActiveRecord[]
@@ -388,14 +323,6 @@ class Cache
         return SmsApi::getFromCache();
     }
 
-    /**
-     *  更新短信接口设置
-     * @return array|\yii\db\ActiveRecord[]
-     */
-    public static function updateSmsApiConfig(){
-        return SmsApi::updateToCache();
-    }
-
     /**
      * 设置上传token
      * @return string

+ 20 - 226
common/helpers/bonus/BonusCalc.php

@@ -78,7 +78,6 @@ class BonusCalc extends BaseObject {
     private $_sysConfig = [];
     private $_decLevelConfig = [];
     private $_empLevelConfig = [];
-    private $_starCrownLevelConfig = [];
     private $_decRoleConfig = [];
     private $_errors = [];
     private $_periodNum = 0;
@@ -168,6 +167,26 @@ class BonusCalc extends BaseObject {
         return $this->_errors;
     }
 
+    public function calculateBonus($periodNum, $handleUserId = null)
+    {
+        try {
+            // 调用存储过程生成业绩单、计算奖金
+            \Yii::$app->db->createCommand("CALL AUTO_CALC_BONUS(:periodNum)")
+                ->bindValue(':periodNum' , $periodNum)
+                ->execute();
+
+            LoggerTool::info('calculateBonus. running.');
+        } catch (\Exception $e) {
+            // 更新结算状态
+            $this->setCalcStatus('fail');
+            LoggerTool::error('calculateBonus. error.' . sprintf('File【%s】, Line【%s】, Msg【%s】', $e->getFile(), $e->getLine(), $e->getMessage()));
+            $this->addError('calculateBonus', sprintf('%s',$e->getMessage()));
+            return false;
+        }
+
+        return true;
+    }
+
     /**
      * 开始执行结算步骤
      * @param $periodNum
@@ -304,16 +323,6 @@ class BonusCalc extends BaseObject {
             echo('计算蓝星奖'.($this->_sysConfig['openGL']['VALUE']?'完成':'关闭').',耗时:' . round($t20 - $t19, 3) . ',内存使用:' . (round(memory_get_usage() / 1024 / 1024, 3)) . 'MB' . PHP_EOL);
             $this->_updatePercent(67);
 
-//            $this->calcBonusTourism($this->_sysConfig['openTourism']);
-            $t21 = microtime(true);
-//            echo('计算旅游奖' . ($this->_sysConfig['openTourism']['VALUE'] ? '完成' : '关闭') . ',耗时:' . round($t21 - $t20, 3) . ',内存使用:' . (round(memory_get_usage() / 1024 / 1024, 3)) . 'MB' . PHP_EOL);
-//            $this->_updatePercent(68);
-
-            $this->calcBonusVilla();
-            $t22 = microtime(true);
-            echo('计算房奖' . ($this->_sysConfig['openVilla']['VALUE'] ? '完成' : '关闭').',耗时:' . round($t22 - $t21, 3) . ',内存使用:' . (round(memory_get_usage() / 1024 / 1024, 3)) . 'MB' . PHP_EOL);
-            $this->_updatePercent(69);
-
             $this->calcBonusGarage();
             $t23 = microtime(true);
             echo('计算车奖' . ($this->_sysConfig['openGarage']['VALUE'] ? '完成' : '关闭').',耗时:' . round($t23 - $t22, 3) . ',内存使用:' . (round(memory_get_usage() / 1024 / 1024, 3)) . 'MB' . PHP_EOL);
@@ -397,7 +406,6 @@ class BonusCalc extends BaseObject {
         $this->_sysConfig = Cache::getSystemConfig();
         $this->_decLevelConfig = Cache::getDecLevelConfig();
         $this->_empLevelConfig = Cache::getEmpLevelConfig();
-        $this->_starCrownLevelConfig = Cache::getStarCrownLevelConfig();
         $this->_decRoleConfig = CalcCache::getDecRoleConfig($this->_periodNum);
         $periodNum = $this->_periodNum;
         // 获取本年月和上年月
@@ -1709,220 +1717,6 @@ class BonusCalc extends BaseObject {
         return $result;
     }
 
-    // 执行旅游奖的计算
-    public function calcBonusTourism() {
-        // 月结,如果不是月结点,则直接退出
-        if (!$this->_isCalcMonth) {
-            return true;
-        }
-
-        $bonusConfig = $this->_sysConfig['openTourism'];
-        // 达标条件:聘级、级别、奖项比例
-        $config = json_decode($bonusConfig['OPTIONS'], true);
-        // 奖金总比例
-        $mate = $bonusConfig['VALUE'] / 100;
-        // 会员级别
-        $minDecLevel = $config['OPTIONS']['declarationLevel'] ?? [];
-        // 月度公司总PV
-        $monthTotalPV = PerfMonth::find()
-            ->yearMonth($this->_calcYearMonth)
-            ->where('CALC_MONTH=:CALC_MONTH', [':CALC_MONTH' => $this->_calcYearMonth])
-            ->sum('PV_PCS');
-        // 用于分发的奖金总数
-        $transferAmount = $monthTotalPV * $mate;
-
-        // 基于蓝星奖结果计算符合获奖条件的会员StarDirector
-        $userStarDirector = CalcBonusBS::find()
-            ->yearMonth($this->_calcYearMonth)
-            ->where('CALC_MONTH=:CALC_MONTH', [':CALC_MONTH' => $this->_calcYearMonth])
-            ->select('USER_ID,LEVEL_ID,LAST_DEC_LV,LAST_EMP_LV,LAST_STATUS')
-            ->groupBy('USER_ID')
-            ->asArray()
-            ->all();
-        $userStarDirectorObj = array_column($userStarDirector, NULL, 'USER_ID');
-
-        // 基于团队奖/绩效奖结果计算会员的StarCrown
-        $userStarCrown = CalcBonusQY::find()
-            ->yearMonth($this->_calcYearMonth)
-            ->where('CALC_MONTH=:CALC_MONTH', [':CALC_MONTH' => $this->_calcYearMonth])
-            ->select('USER_ID,LAST_CROWN_LV')
-            ->groupBy('USER_ID')
-            ->asArray()
-            ->all();
-        $userStarCrownObj = array_column($userStarCrown, NULL, 'USER_ID');
-
-        // 合并用户ID,去重
-        $bonusUsers = array_unique(array_merge(array_keys($userStarDirectorObj), array_keys($userStarCrownObj)));
-
-        // 奖金点数综合
-        $bonusPointComplex = 0;
-        $insertBonusData = [];
-        foreach($bonusUsers as $userId) {
-            // 计算奖金:取starDirectorPoint和starCrownPoint的大个值
-            $starDirectorPoint = $this->_empLevelConfig[$userStarDirectorObj[$userId]['LEVEL_ID']]['TOURISM_PERCENT'] ?? 0;
-            $starCrownPoint = $this->_starCrownLevelConfig[$userStarCrownObj[$userId]['LAST_CROWN_LV']]['TOURISM_PERCENT'] ?? 0;
-            // 奖金比例:
-            $bonusPoint = max($starDirectorPoint, $starCrownPoint);
-            if ($bonusPoint <= 0) {
-                continue;
-            }
-            
-            $insertBonusData[] = [
-                'ID' => SnowFake::instance()->generateId(),
-                'USER_ID' => $userId,
-                'LAST_DEC_LV' => $userStarDirectorObj[$userId]['LAST_DEC_LV'],
-                'LAST_EMP_LV' => $userStarDirectorObj[$userId]['LAST_EMP_LV'],
-                'LAST_STATUS' => $userStarDirectorObj[$userId]['LAST_STATUS'],
-                'LAST_CROWN_LV' => $userStarCrownObj[$userId]['LAST_CROWN_LV'],
-                'AMOUNT_STANDARD' => 0,
-                'POINT' => $bonusPoint,
-                'PERIOD_NUM' => $this->_periodNum,
-                'CALC_YEAR' => $this->_calcYear,
-                'CALC_MONTH' => $this->_calcYearMonth,
-                'P_CALC_MONTH' => Date::ociToDate($this->_calcYearMonth, Date::OCI_TIME_FORMAT_SHORT_MONTH),
-                'CREATED_AT' => Date::nowTime(),
-                'PERF' => $monthTotalPV,
-                'TRANSFER_RATE' => $mate,
-                'TRANSFER_AMOUNT' => Tool::formatPrice($transferAmount),
-                'CAP_AMOUNT' => 0,
-                'POINT_COMPLEX' => 0,
-            ];
-
-            $bonusPointComplex += $bonusPoint;
-        }
-
-        // 数据写入总表
-        if ($insertBonusData) {
-            foreach ($insertBonusData as &$bonusData) {
-                // 计算奖金
-                $amount = Tool::formatPrice($transferAmount * ($bonusData['POINT'] / $bonusPointComplex));
-                if ($amount <= 0) {
-                    continue;
-                }
-
-                // 会员级别达到要求才会发放奖金
-                if ($bonusData['LAST_DEC_LV'] == $minDecLevel) {
-                    // 放入缓存
-                    CalcCache::tourismBonus($bonusData['USER_ID'], $this->_periodNum, $amount);
-                    // 加入月奖的会员
-                    CalcCache::addHasMonthBonusUsers($bonusData['USER_ID'], $this->_periodNum);
-                }
-
-                $bonusData['AMOUNT'] = $amount;
-                $bonusData['POINT_COMPLEX'] = $bonusPointComplex;
-            }
-
-            CalcBonusTourism::batchInsert($insertBonusData);
-        }
-
-        return true;
-    }
-
-    // 执行房奖的计算
-    public function calcBonusVilla() {
-        // 月结,如果不是月结点,则直接退出
-        if (!$this->_isCalcMonth) {
-            return true;
-        }
-
-        $bonusConfig = $this->_sysConfig['openVilla'];
-        // 达标条件:聘级、级别、奖项比例
-        $config = json_decode($bonusConfig['OPTIONS'], true);
-        // 奖金总比例
-        $mate = $bonusConfig['VALUE'] / 100;
-        // 个人奖金封顶
-        $capBonus = intval($this->_sysConfig['openVillaCap']['VALUE'] ?? 0);
-        // 会员级别
-        $minDecLevel = $config['declarationLevel'] ?? [];
-
-        // 月度公司总PV
-        $monthTotalPV = PerfMonth::find()
-            ->yearMonth($this->_calcYearMonth)
-            ->where('CALC_MONTH=:CALC_MONTH', [':CALC_MONTH' => $this->_calcYearMonth])
-            ->sum('PV_PCS');
-        // 用于分发的奖金总数
-        $transferAmount = $monthTotalPV * $mate;
-
-        // 基于团队奖/绩效奖结果计算会员的StarCrown.StarCrown基于周期计算,一个月会产生多次,取月周期中的最高星级
-        $subQuery = CalcBonusQY::find()
-            ->yearMonth($this->_calcYearMonth)
-            ->where('CALC_MONTH = :CALC_MONTH AND LAST_CROWN_LV <> :NO_CROWN_LV', [':CALC_MONTH' => $this->_calcYearMonth, ':NO_CROWN_LV' => StarCrownLevel::NO_LEVEL_ID])
-            ->select('USER_ID,LAST_DEC_LV,LAST_CROWN_LV,LAST_EMP_LV,LAST_STATUS,LEVEL_NAME,SORT')
-            ->joinWith(['starCrown' => function($query) {
-                $query->select(['LEVEL_NAME', 'SORT']);
-            }])
-            ->having(1)
-            ->orderBy('USER_ID ASC, SORT DESC');
-        $userStarCrownObj = (new Query())->from(['u' => $subQuery])->select('USER_ID,LAST_DEC_LV,LAST_CROWN_LV,LAST_EMP_LV,LAST_STATUS,LEVEL_NAME,SORT')->groupBy('USER_ID')->indexBy('USER_ID')->all();
-
-        // 奖金点数综合
-        $bonusPointComplex = 0;
-        $insertBonusData = [];
-        foreach($userStarCrownObj as $item) {
-            // 奖金比例
-            $bonusPoint = $this->_starCrownLevelConfig[$item['LAST_CROWN_LV']]['VILLA_PERCENT'] ?? 0;
-            if (!$bonusPoint) {
-                continue;
-            }
-
-            // 会员级别达到要求才会发放奖金
-            if ($item['LAST_DEC_LV'] != $minDecLevel) {
-                continue;
-            }
-
-            $insertBonusData[] = [
-                'ID' => SnowFake::instance()->generateId(),
-                'USER_ID' => $item['USER_ID'],
-                'LAST_DEC_LV' => $item['LAST_DEC_LV'] ?? '',
-                'LAST_EMP_LV' => $item['LAST_EMP_LV'] ?? '',
-                'LAST_STATUS' => $item['LAST_STATUS'] ?? 0,
-                'LAST_CROWN_LV' => $item['LAST_CROWN_LV'] ?? '',
-                'AMOUNT' => 0,
-                'POINT' => $bonusPoint,
-                'PERIOD_NUM' => $this->_periodNum,
-                'CALC_YEAR' => $this->_calcYear,
-                'CALC_MONTH' => $this->_calcYearMonth,
-                'P_CALC_MONTH' => Date::ociToDate($this->_calcYearMonth, Date::OCI_TIME_FORMAT_SHORT_MONTH),
-                'CREATED_AT' => Date::nowTime(),
-                'PERF' => $monthTotalPV,
-                'TRANSFER_RATE' => $mate,
-                'TRANSFER_AMOUNT' => Tool::formatPrice($transferAmount),
-                'CAP_AMOUNT' => 0,
-                'POINT_COMPLEX' => 0,
-            ];
-
-            $bonusPointComplex += $bonusPoint;
-        }
-
-        // 数据写入总表
-        if ($insertBonusData) {
-            // 计算个人奖金
-            foreach ($insertBonusData as &$bonusData) {
-                // 计算奖金
-                $amount = Tool::formatPrice($transferAmount * ($bonusData['POINT'] / $bonusPointComplex));
-                if ($amount <= 0) {
-                    continue;
-                }
-                // 封顶前奖金数
-                $capAmount = $amount;
-                // 奖金数不能大于封顶值
-                $amount = ($amount > $capBonus) ? $capBonus : $amount;
-
-                $bonusData['AMOUNT'] = $amount;
-                $bonusData['CAP_AMOUNT'] = $capAmount;
-                $bonusData['POINT_COMPLEX'] = $bonusPointComplex;
-
-                // 放入缓存
-                CalcCache::villaBonus($bonusData['USER_ID'], $this->_periodNum, $amount);
-                // 加入月奖的会员
-                CalcCache::addHasMonthBonusUsers($bonusData['USER_ID'], $this->_periodNum);
-            }
-
-            CalcBonusVilla::batchInsert($insertBonusData);
-        }
-
-        return true;
-    }
 
     // 执行车奖的计算
     public function calcBonusGarage() {

+ 0 - 1
common/helpers/user/Info.php

@@ -274,7 +274,6 @@ class Info {
         $baseInfo['LAST_DEC_LV_NAME'] = Cache::getDecLevelConfig()[$baseInfo['LAST_DEC_LV']]['LEVEL_NAME'];
         $baseInfo['EMP_LV_NAME'] = Cache::getEmpLevelConfig()[$baseInfo['EMP_LV']]['LEVEL_NAME'];
         $baseInfo['HIGHEST_EMP_LV_NAME'] = '';
-        $baseInfo['CROWN_LV_NAME'] = Cache::getStarCrownLevelConfig()[$baseInfo['CROWN_LV']]['LEVEL_NAME'];
         // 获取会员报单级别
         $baseInfo['DEC_ROLE_NAME'] = '无';
         //民族

+ 0 - 9
common/messages/en-US/ctx.php

@@ -712,15 +712,6 @@ return [
     'dbEliteLevelElite' => 'Elite',
     'dbEliteLevelProElite' => 'Pro Elite',
     'dbEliteLevelSuperElite' => 'Supper Elite',
-    # 皇冠星级
-    'dbCrownLevel0StarCrown' => '0-Star Crown',
-    'dbCrownLevel1StarCrown' => '1-Star Crown',
-    'dbCrownLevel2StarCrown' => '2-Star Crown',
-    'dbCrownLevel3StarCrown' => '3-Star Crown',
-    'dbCrownLevel4StarCrown' => '4-Star Crown',
-    'dbCrownLevel5StarCrown' => '5-Star Crown',
-    'dbCrownLevel6StarCrown' => '6-Star Crown',
-    'dbCrownLevel7StarCrown' => '7-Star Crown',
     # 报单中心级别
     'dbDecRole1stLevelStockist'	=> '1st Level Stockist',
     'dbDecRole2ndLevelStockist'	=> '2nd Level Stockist',

+ 0 - 9
common/messages/zh-CN/ctx.php

@@ -716,15 +716,6 @@ return [
     'dbEliteLevelElite' => 'Elite',
     'dbEliteLevelProElite' => 'Pro Elite',
     'dbEliteLevelSuperElite' => 'Supper Elite',
-    # 皇冠星级
-    'dbCrownLevel0StarCrown'	=> '无',
-    'dbCrownLevel1StarCrown'	=> '1星皇冠',
-    'dbCrownLevel2StarCrown'	=> '2星皇冠',
-    'dbCrownLevel3StarCrown'	=> '3星皇冠',
-    'dbCrownLevel4StarCrown'	=> '4星皇冠',
-    'dbCrownLevel5StarCrown'	=> '5星皇冠',
-    'dbCrownLevel6StarCrown'	=> '6星皇冠',
-    'dbCrownLevel7StarCrown'	=> '7星皇冠',
     # 报单中心级别
     'dbDecRole1stLevelStockist'	=> '一级报单中心',
     'dbDecRole2ndLevelStockist'	=> '二级报单中心',

+ 0 - 18
common/models/DealType.php

@@ -28,21 +28,9 @@ class DealType extends \common\components\ActiveRecord
     //系统预置类型id
     CONST BONUS_SEND = '141E52002AAE43B7AC304F4BAEFDA268';//奖金发放
     CONST WITHDRAW = '6626ED606DB34A11B6CCEA768B6E36C2';//奖金提现
-//    CONST DEDUCT = '7E3255C33BD6457B8F7155F2A86FFF73';//责任业绩扣除
     CONST WITHDRAW_RETURN = '01A753D2548F44FA99B847133C1B5F79';//提现退回
     CONST TRANSFER_OUT = 'DAA0FB1465F748908680D941D589326E';//转出
     CONST TRANSFER_IN = 'DB62879E6C6B4B2F8591FAD920A2822C';//转入
-//    CONST BIND_TRANSFER_OUT = 'E57A779B2E064081B335C5D6B9E4B59B';//点位绑定转出
-//    CONST BIND_TRANSFER_IN = '082485287F3148B7A44DC62D5D17473A';//点位绑定转入
-//    CONST TEAMWORK_TRANSFER_OUT = '38EB53BCAAF24BA38B2E5FDA313EC928';//点位合作转出
-//    CONST TEAMWORK_TRANSFER_IN = '64198F701D374D2996AA8EF1D37769AB';//点位合作转入
-    CONST RECONSUME_POINTS_SEND = 'A6BDF8A2E5F7450B80CBF3B28D8010D2';//复消积分发放
-    CONST EXCHANGE_POINTS_SEND = '316868755701501952';//兑换积分发放
-//    CONST LX_SEND = '12840830348E456696834E0624FE2331';//领袖分红发放
-    CONST RECONSUME_POINTS_OUT = '01C2916A2ECA4D1B9C29AA333C6D13E7';//复消积分转出
-//    CONST LX_TRANSFER_OUT = '3CD904D1D0764A3FA3E9114DA1D930BD';//领袖分红转出
-    CONST RECONSUME_POINTS_TRANSFER_IN = 'F6AA8D767E654D86917BBF1A5C24F439';//复消积分转入
-//    CONST LX_TRANSFER_IN = '0C092D8D6D804F4B84134DBAB5BBE05C';//领袖分红转入
     CONST RESEND = '37B81A45F38646A0A16499AB27B51923';//补发
     CONST SMS = '1145D8ABA7A7471FB59B6760BDB19019';//短信服务费
     CONST DEDUCT_CLOSE = '37EFF25E5E3F46A6BB84B8C55997F276';//永久关停扣除
@@ -52,12 +40,6 @@ class DealType extends \common\components\ActiveRecord
     CONST TOURISM_SEND = '364305038266470400';// 旅游奖奖金发放
     CONST GARAGE_SEND = '364305160249413632';// 车奖奖金发放
     CONST VILLA_SEND = '390992293622059008';// 房奖奖金发放
-    CONST TOURISM_POINTS_EXCHANGE = '365343018452127744'; // 旅游积分兑换
-    CONST GARAGE_POINTS_EXCHANGE = '365343060634243072'; // 车奖积分兑换
-    CONST VILLA_POINTS_EXCHANGE = '390992212424527872'; // 房奖积分兑换
-    CONST TOURISM_POINTS_ADJUST = '365753533326299136'; // 旅游积分余额调整
-    CONST GARAGE_POINTS_ADJUST = '365753643942678528'; // 车奖积分余额调整
-    CONST VILLA_POINTS_ADJUST = '390990784847024128'; // 房奖积分余额调整
 
     /**
      * {@inheritdoc}

+ 19 - 7
common/models/Period.php

@@ -103,8 +103,8 @@ class Period extends \common\components\ActiveRecord
         return [
             'ID' => 'ID',
             'PERIOD_NUM' => '期数',
-            'CALC_MONTH' => '所在结算月',
-            'CALC_YEAR' => '所在结算年',
+            'CALC_MONTH' => '结算月',
+            'CALC_YEAR' => '结算年',
             'START_TIME' => '期数开始时间戳',
             'END_TIME' => '期数结束时间戳',
             'IS_MONTH' => '是否结算月节点',
@@ -140,9 +140,10 @@ class Period extends \common\components\ActiveRecord
      */
     public function setPeriodNum($periodNum = null){
         if($periodNum === 0 || $periodNum === null || $periodNum === ''){
-            //if($this->nowPeriodArr === null){
-                $this->nowPeriodArr = static::find()->where('IS_CLOSED=0')->orderBy('PERIOD_NUM ASC')->asArray()->one();
-            //}
+            if($this->nowPeriodArr === null){
+//                $this->nowPeriodArr = static::find()->where('IS_CLOSED=0')->orderBy('PERIOD_NUM ASC')->asArray()->one();
+                $this->nowPeriodArr = $this->getNowPeriod();
+            }
             $this->periodArr = $this->nowPeriodArr;
             $periodNum = $this->nowPeriodArr['PERIOD_NUM'];
         } else {
@@ -184,7 +185,8 @@ class Period extends \common\components\ActiveRecord
 
     public function getTeamsPeriodNum(){
 //        $this->nowPeriodArr = static::find()->where('IS_CLOSED=1 AND IS_SENT=0')->orderBy('PERIOD_NUM ASC')->asArray()->one();
-        $this->nowPeriodArr = static::find()->where('IS_SENT=0')->orderBy('PERIOD_NUM ASC')->asArray()->one();
+//        $this->nowPeriodArr = static::find()->where('IS_SENT=0')->orderBy('PERIOD_NUM ASC')->asArray()->one();
+        $this->nowPeriodArr = $this->getNowPeriod();
         if($this->nowPeriodArr){
             $this->setPeriodNum($this->nowPeriodArr['PERIOD_NUM']);
             return $this->nowPeriodArr['PERIOD_NUM'];
@@ -193,6 +195,16 @@ class Period extends \common\components\ActiveRecord
         }
     }
 
+    public function getNowPeriod()
+    {
+        $nowYear = date('Y');
+        $nowMonth = date('m');
+        return static::find()
+            ->where('CALC_MONTH=:CALC_MONTH AND CALC_YEAR=:CALC_YEAR', [':CALC_MONTH' => $nowMonth, ':CALC_YEAR' => $nowYear])
+            ->asArray()
+            ->one();
+    }
+
     /**
      * 获取当前期的开始时间
      * @return int
@@ -992,7 +1004,7 @@ class Period extends \common\components\ActiveRecord
      */
     public static function getPeriodList($periodNum = null, $limit = 10) {
         if ($periodNum) {
-            $periodList = static::find()->where('PERIOD_NUM >= :PERIOD_NUM', [':PERIOD_NUM' => $periodNum])->select('PERIOD_NUM,IS_SENT,IS_CLOSED')->limit($limit)->asArray()->all();
+            $periodList = static::find()->where('PERIOD_NUM >= :PERIOD_NUM', [':PERIOD_NUM' => $periodNum])->select('PERIOD_NUM,IS_SENT')->limit($limit)->asArray()->all();
         } else {
             $periodList = static::find()->select('PERIOD_NUM,IS_SENT,IS_CLOSED')->limit($limit)->column();
         }

+ 0 - 249
common/models/StarCrownLevel.php

@@ -1,249 +0,0 @@
-<?php
-
-namespace common\models;
-
-use common\helpers\Cache;
-use common\helpers\LoggerTool;
-use Yii;
-
-/**
- * This is the model class for table "{{%CROWN_LEVEL}}".
- *
- * @property string $ID
- * @property string $LEVEL_NAME 级别名称
- * @property int $ICON_TYPE 图标类型
- * @property int $ICON_NUM 图标个数
- * @property int $RX_PERCENT 图标个数
- * @property string $MIN_LEVEL_ID 上级ID
- * @property string $LEVEL_SCORE 级别分数
- * @property string $UPGRADE_SCORE 升级分数
- * @property string $TOURISM_PERCENT 旅游奖比例
- * @property string $GARAGE_PERCENT 车房奖比例
- * @property int $SORT 排序
- * @property int $CREATED_AT 创建时间
- * @property int $UPDATED_AT 更新时间
- * @property string $CREATE_ADMIN 创建人
- * @property string $UPDATE_ADMIN 更新人
- */
-class StarCrownLevel extends \common\components\ActiveRecord
-{
-    const NO_LEVEL_ID = 'DCBEDD8E0EAD3DF59D81CCC0C2ACAEFF';
-
-    /**
-     * @inheritdoc
-     */
-    public static function tableName()
-    {
-        return '{{%CROWN_LEVEL}}';
-    }
-
-    /**
-     * @inheritdoc
-     */
-    public function rules()
-    {
-        return [
-            [['LEVEL_NAME', 'CREATED_AT', 'CREATE_ADMIN'], 'required'],
-            [['SORT', 'CREATED_AT', 'UPDATED_AT', 'ICON_TYPE', 'ICON_NUM'], 'integer'],
-            [['LEVEL_SCORE', 'UPGRADE_SCORE', 'TOURISM_PERCENT', 'GARAGE_PERCENT'], 'number'],
-            [['ID', 'MIN_LEVEL_ID', 'CREATE_ADMIN', 'UPDATE_ADMIN'], 'string', 'max' => 32],
-            [['LEVEL_NAME'], 'string', 'max' => 20],
-            [['LEVEL_NAME'], 'unique'],
-            [['ID'], 'unique'],
-        ];
-    }
-
-    /**
-     * @inheritdoc
-     */
-    public function attributeLabels()
-    {
-        return [
-            'ID' => 'ID',
-            'LEVEL_NAME' => '级别名称',
-            'SORT' => '排序',
-            'CREATED_AT' => '创建时间',
-            'UPDATED_AT' => '更新时间',
-            'CREATE_ADMIN' => '创建人',
-            'UPDATE_ADMIN' => '更新人',
-            'ICON_TYPE' => '图标类型',
-            'ICON_NUM' => '图标个数',
-            'MIN_LEVEL_ID' => '上级ID',
-            'LEVEL_SCORE' => '级别分数',
-            'UPGRADE_SCORE' => '升级分数',
-            'TOURISM_PERCENT' => '旅游奖比例',
-            'GARAGE_PERCENT' => '车房奖比例',
-        ];
-    }
-
-    /**
-     * 获取全部级别以数字索引的方式展现
-     * @return array|\yii\db\ActiveRecord[]
-     */
-    public static function getAllDataWithNumIndex()
-    {
-        return static::find()->where('1=1')->orderBy('SORT ASC, CREATED_AT ASC')->indexBy('SORT')->asArray()->all();
-    }
-
-    /**
-     * 获取全部配置
-     * @return array|\yii\db\ActiveRecord[]
-     */
-    public static function getAllData()
-    {
-        return static::find()->where('1=1')->orderBy('SORT ASC, CREATED_AT ASC')->indexBy('ID')->asArray()->all();
-    }
-
-    // 获取级别配置一维度数组,id为键,级别等级为值
-    public static function getIdConvertLevelSort()
-    {
-        $ret = [];
-        $allData = static::find()->where('1=1')->orderBy('SORT ASC, CREATED_AT ASC')->indexBy('ID')->asArray()->all();
-        foreach($allData as $data) {
-            $ret[$data['ID']] = $data['SORT'];
-        }
-        return $ret;
-    }
-
-    /**
-     * 从缓存获取信息
-     * @return array|mixed|\yii\db\ActiveRecord[]
-     */
-    public static function getIdConvertLevelSortCache()
-    {
-        $key = Cache::CROWN_LEVEL_CONFIG_KEY . ':idsort';
-        $data = Yii::$app->cache->get($key);
-        if(!$data){
-            // 获取信息
-            $data = self::getIdConvertLevelSort();
-            Yii::$app->cache->set($key, $data);
-        }
-
-        return $data;
-    }
-
-    /**
-     * 从缓存获取信息
-     * @return array|mixed|\yii\db\ActiveRecord[]
-     */
-    public static function getFromCache()
-    {
-        $data = Yii::$app->cache->get(Cache::CROWN_LEVEL_CONFIG_KEY);
-        if(!$data){
-            // 获取信息
-            $data = self::getAllData();
-            Yii::$app->cache->set(Cache::CROWN_LEVEL_CONFIG_KEY, $data);
-        }
-        // i18n转换
-        foreach ($data as &$item) {
-            $item['LEVEL_NAME'] = Yii::t('ctx', $item['LANGUAGE_KEY']);
-        }
-        return $data;
-    }
-
-    /**
-     *  更新缓存
-     * @return array|\yii\db\ActiveRecord[]
-     */
-    public static function updateToCache()
-    {
-        // 获取配置
-        $data = self::getAllData();
-        Yii::$app->cache->set(Cache::CROWN_LEVEL_CONFIG_KEY, $data);
-        return $data;
-    }
-
-    /**
-     * 通过排序获取级别
-     * @param int $sort
-     * @return mixed
-     */
-    public static function getLevelFromSort(int $sort)
-    {
-        static $crownLevels;
-        if(!$crownLevels){
-            $crownLevels = self::getFromCache();
-            $crownLevels = array_column($crownLevels, null, 'sort');
-        }
-        return $crownLevels[$sort];
-    }
-
-    /**
-     * 通过排序获取ID
-     * @param int $sort
-     * @return mixed
-     */
-    public static function getIdFromSort(int $sort)
-    {
-        $level = self::getLevelFromSort($sort);
-        return $level['ID'];
-    }
-
-    /**
-     * 获取默认级别
-     * @return mixed
-     */
-    public static function getDefaultLevelId()
-    {
-        return self::NO_LEVEL_ID;
-    }
-
-    /**
-     * 获取星级的排序
-     * @param $id
-     * @return mixed
-     */
-    public static function getSortById($id)
-    {
-        $crownLevels = self::getFromCache();
-        return $crownLevels[$id]['SORT'] ?? 0;
-    }
-
-    /**
-     * 通过ID获取星级名称
-     * @param $levelId
-     * @return mixed'
-     */
-    public static function getNameById($levelId)
-    {
-        return self::findOneAsArray('ID = :ID', [':ID' => $levelId])['LEVEL_NAME'] ?? '';
-    }
-
-    /**
-     * 奖金参数
-     */
-    public static function getBonusConfig(){
-        $allData = self::getAllData();
-        $data = [];
-        foreach ($allData as $value) {
-            $data[$value['ID']]['label'] = $value['LEVEL_NAME'];
-            $data[$value['ID']]['value'] = '【旅游奖】拿奖比例' . $value['TOURISM_PERCENT'] . '%,' . '【车房奖】拿奖比例' . $value['GARAGE_PERCENT'] . '%';
-        }
-        return $data;
-    }
-
-    /**
-     * 根据业绩计算星级
-     * @param $payLeg
-     * @return array|mixed|\yii\db\ActiveRecord
-     */
-    public static function getStarCrown($payLeg)
-    {
-        $starCrown = [];
-        $allData = self::getAllData();
-        // 最大边界值
-        $maxData = end($allData);
-        if ($payLeg >= $maxData) {
-            return $maxData;
-        }
-
-        foreach ($allData as $item) {
-            if (($payLeg >= $item['LEVEL_SCORE']) && ($payLeg < $item['UPGRADE_SCORE'])) {
-                $starCrown = $item;
-                break;
-            }
-        }
-
-        return $starCrown ?: $allData[self::NO_LEVEL_ID];
-    }
-}

+ 0 - 3
common/models/UserNetwork.php

@@ -283,7 +283,6 @@ class UserNetwork extends \common\components\ActiveRecord
         if($allData){
             $decLevelConfig = Cache::getDecLevelConfig();
             $empLevelConfig = Cache::getEmpLevelConfig();
-            $crownLevelConfig = Cache::getStarCrownLevelConfig();
             foreach($allData as $key=>$data){
                 // 获取用户的基本信息
                 $baseInfo = Info::baseInfo($data['USER_ID'], $periodNum);
@@ -294,8 +293,6 @@ class UserNetwork extends \common\components\ActiveRecord
                     'REAL_NAME' => $baseInfo['REAL_NAME'],
                     'DEC_LV_NAME' => $decLevelConfig[$baseInfo['DEC_LV']]['LEVEL_NAME'],
                     'EMP_LV_NAME' => isset($empLevelConfig[$baseInfo['EMP_LV']])?$empLevelConfig[$baseInfo['EMP_LV']]['LEVEL_NAME']:'0-Star Director',
-                    'CROWN_LV_NAME' => isset($crownLevelConfig[$baseInfo['CROWN_LV']])?$crownLevelConfig[$baseInfo['CROWN_LV']]['LEVEL_NAME']:'0-Star Crown',
-//                    'MOBILE' => $baseInfo['MOBILE'],
                     'PERIOD_AT' => $baseInfo['PERIOD_AT'],
                 ]);
                 // 获取字节点数量

+ 0 - 2
common/models/UserRelation.php

@@ -205,7 +205,6 @@ class UserRelation extends \common\components\ActiveRecord
         if($allData){
             $decLevelConfig = Cache::getDecLevelConfig();
             $empLevelConfig = Cache::getEmpLevelConfig();
-            $crownLevelConfig = Cache::getStarCrownLevelConfig();
             foreach($allData as $key=>$data){
                 // 获取用户的基本信息
                 $baseInfo = Info::baseInfo($data['USER_ID'], $periodNum);
@@ -215,7 +214,6 @@ class UserRelation extends \common\components\ActiveRecord
                     'REAL_NAME' => $baseInfo['REAL_NAME'],
                     'DEC_LV_NAME' => $decLevelConfig[$baseInfo['DEC_LV']]['LEVEL_NAME'],
                     'EMP_LV_NAME' => isset($empLevelConfig[$baseInfo['EMP_LV']])?$empLevelConfig[$baseInfo['EMP_LV']]['LEVEL_NAME']:'0-Star Director',
-                    'CROWN_LV_NAME' => isset($crownLevelConfig[$baseInfo['CROWN_LV']])?$crownLevelConfig[$baseInfo['CROWN_LV']]['LEVEL_NAME']:'0-Star Crown',
                     'PERIOD_AT' => $baseInfo['PERIOD_AT'],
                 ]);
                 // 获取字节点数量

+ 2 - 3
common/models/forms/PeriodForm.php

@@ -233,9 +233,8 @@ class PeriodForm extends Model
             return null;
         }
         $bonusCalc = BonusCalc::instance();
-        //$bonusCalc->init($this->periodNum, $handleUserId);
-        //$bonusCalc->setPeriodNum($this->periodNum);
-        $asyncResult = $bonusCalc->calcStep($this->periodNum, $handleUserId);
+//        $asyncResult = $bonusCalc->calcStep($this->periodNum, $handleUserId);
+        $asyncResult = $bonusCalc->calculateBonus($this->periodNum, $handleUserId);
         if($asyncResult){
             $bonusCalc->endCalcTask();
         } else {

+ 0 - 2
frontendApi/modules/v1/controllers/AtlasController.php

@@ -60,7 +60,6 @@ class AtlasController extends BaseController {
         $baseInfo = Info::baseInfo($userId, $periodNum);
         $decLevelConfig = Cache::getDecLevelConfig();
         $empLevelConfig = Cache::getEmpLevelConfig();
-        $crownLevelConfig = Cache::getStarCrownLevelConfig();
         return static::notice([
             [
                 'TOP_RELATION_DEEP' => $baseInfo['RELATION_DEEP'],
@@ -71,7 +70,6 @@ class AtlasController extends BaseController {
                 'PERIOD_AT' => $baseInfo['PERIOD_AT'],
                 'DEC_LV_NAME' => $decLevelConfig[$baseInfo['DEC_LV']]['LEVEL_NAME'] ?? $decLevelConfig[DeclarationLevel::getDefaultLevelId()]['LEVEL_NAME'],
                 'EMP_LV_NAME' => $empLevelConfig[$baseInfo['EMP_LV']]['LEVEL_NAME'] ?? $empLevelConfig[EmployLevel::getDefaultLevelId()]['LEVEL_NAME'],
-                'CROWN_LV_NAME' => $crownLevelConfig[$baseInfo['CROWN_LV']]['LEVEL_NAME'] ?? $crownLevelConfig[StarCrownLevel::getDefaultLevelId()]['LEVEL_NAME'],
                 'leaf' => false,
                 'icon' => 'el-icon-user-solid',
                 'children' => null,

+ 0 - 61
frontendApi/modules/v1/controllers/BonusController.php

@@ -347,7 +347,6 @@ class BonusController extends BaseController {
             $data['PERIOD_NUM'] = ['name' => '期数', 'value' => $periodNum];
             $data['LAST_DEC_LV'] = ['name' => '级别', 'value' => Cache::getDecLevelConfig()[$calcBonus['LAST_DEC_LV']]['LEVEL_NAME']];
             $data['LAST_EMP_LV'] = ['name' => '管理星级', 'value' => Cache::getEmpLevelConfig()[$calcBonus['LAST_EMP_LV']]['LEVEL_NAME']];
-            $data['LAST_CROWN_LV'] = ['name' => '皇冠星级', 'value' => Cache::getStarCrownLevelConfig()[$calcBonus['LAST_CROWN_LV']]['LEVEL_NAME']];
             if ($sysConfig['openTG']['VALUE']) {
                 // 销售奖金 就是 原来的推广奖
                 $data['ORI_BONUS_TG'] = ['name' => '销售奖金', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_TG'])];
@@ -368,32 +367,17 @@ class BonusController extends BaseController {
             $data['BONUS_BD_SWITCH'] = intval($sysConfig['openFW']['VALUE']);
 
             // 管理奖金 就是新的蓝星奖
-//            $data[] = ['name' => '管理奖金', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_BS'])];
-//            if ($sysConfig['openGX']['VALUE']) {
-//                $data[] = ['name' => '共享奖金', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_GX'])];
-//            }
-//            if ($sysConfig['openFW']['VALUE']) {
-//                $data[] = ['name' => '服务奖金', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_BD'])];
-//            }
-            // 管理奖金 就是新的蓝星奖
             $data['ORI_BONUS_BS'] = ['name' => '管理奖金', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_BS'])];
             $data['ORI_BONUS_BS_MNT'] = ['name' => '管理奖金', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_BS_MNT'])];
             $data['ORI_BONUS_BS_ABBR'] = ['name' => '绩效奖金', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_BS_ABBR'])];
 
             $data['ORI_BONUS_QUARTER'] = ['name' => '季度奖金', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_QUARTER'] ?? 0.00)];
-//            $data['BONUS_TOURISM'] = ['name' => '旅游奖', 'value' => Tool::formatPrice($calcBonus['BONUS_TOURISM'])];
-//            $data['BONUS_GARAGE'] = ['name' => '车房奖', 'value' => Tool::formatPrice($calcBonus['BONUS_GARAGE'])];
             $data['BONUS_TOTAL'] = ['name' => '合计', 'value' => Tool::formatPrice($calcBonus['BONUS_TOTAL'])];
-//            $data[] = ['name' => '管理费', 'value' => Tool::formatPrice($calcBonus['MANAGE_TAX'])];
             $data['BONUS_REAL'] = ['name' => '实发奖金', 'value' => Tool::formatPrice($calcBonus['BONUS_REAL'])];
-//            $data[] = ['name' => '复消积分', 'value' => Tool::formatPrice($calcBonus['RECONSUME_POINTS'])];
-//            $data[] = ['name' => '兑换积分', 'value' => Tool::formatPrice($calcBonus['EXCHANGE_POINTS'])];
             $data['PV_1L'] = ['name' => '一市场新增业绩', 'value' => Tool::formatFrontPerf($calcBonus['PV_1L'])];
             $data['PV_2L'] = ['name' => '二市场新增业绩', 'value' => Tool::formatFrontPerf($calcBonus['PV_2L'])];
-//            $data['PV_3L'] = ['name' => '三市场新增业绩', 'value' => Tool::formatFrontPerf($calcBonus['PV_3L'])];
             $data['SURPLUS_1L'] = ['name' => '一市场结余业绩', 'value' => Tool::formatFrontPerf($calcBonus['SURPLUS_1L'])];
             $data['SURPLUS_2L'] = ['name' => '二市场结余业绩', 'value' => Tool::formatFrontPerf($calcBonus['SURPLUS_2L'])];
-//            $data['SURPLUS_3L'] = ['name' => '三市场结余业绩', 'value' => Tool::formatFrontPerf($calcBonus['SURPLUS_3L'])];
 
             // 是否活跃
             $perfPeriod = PerfPeriod::find()->where('USER_ID=:USER_ID AND PERIOD_NUM = :PERIOD_NUM', [':USER_ID' => \Yii::$app->user->id, ':PERIOD_NUM' => $periodNum])->asArray()->one();
@@ -401,51 +385,6 @@ class BonusController extends BaseController {
             // 管理奖个人小组业绩
             $calcBonusBS = CalcBonusBSDefault::findOneAsArray('USER_ID=:USER_ID AND PERIOD_NUM=:PERIOD_NUM', [':USER_ID' => \Yii::$app->user->id, ':PERIOD_NUM' => $periodNum], 'GPV10');
             $data['DIRECTOR_BONUS_PGS'] = ['name' => '个人小组业绩', 'value' => ($calcBonusBS['GPV10'] ?? 0)];
-
-            // if ($sysConfig['openYC']['VALUE']) {
-            //     $data[] = ['name' => '荣衔奖', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_YC'])];
-            // }
-            // if ($sysConfig['openVIP']['VALUE']) {
-            //     $data[] = ['name' => 'VIP奖', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_VIP'])];
-            // }
-
-
-            // if ($sysConfig['openXF']['VALUE']) {
-            //     $data[] = ['name' => '消费奖', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_XF'])];
-            // }
-            // if ($sysConfig['openYJ']['VALUE']) {
-            //     $data[] = ['name' => '业绩奖', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_YJ'])];
-            // }
-
-            // if ($sysConfig['openGL']['VALUE']) {
-            //     $data[] = ['name' => '管理奖', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_GL'])];
-            // }
-
-            // if ($sysConfig['openJXS']['VALUE']) {
-            //     $data[] = ['name' => '团队成长奖', 'value' => Tool::formatPrice($calcBonus['ORI_BONUS_STANDARD'])];
-            // }
-//        if($sysConfig['openLS']['VALUE']) {
-//            $data[] = ['name' => '零售奖', 'value' => Tool::formatPrice($calcBonus['BONUS_LS'])];
-//        }
-//        $data[]=['name'=>'责任业绩扣除','value'=>Tool::formatPrice($calcBonus['DEDUCT_ZR'])];
-
-
-//        $data[]=['name'=>'总奖金','value'=>Tool::formatPrice($calcBonus['BONUS_TOTAL'])];
-
-//        if($sysConfig['openLX']['VALUE']) {
-//            $data[] = ['name' => '福利积分二', 'value' => Tool::formatPrice($calcBonus['BONUS_LX'])];
-//        }
-
-//        $data[]=['name'=>'四市场新增业绩','value'=>Tool::formatFrontPerf($calcBonus['PV_4L'])];
-//        $data[]=['name'=>'五市场新增业绩','value'=>Tool::formatFrontPerf($calcBonus['PV_5L'])];
-//        $data[]=['name'=>'虚拟市场新增业绩','value'=>Tool::formatFrontPerf($calcBonus['PV_LS_TOUCH'])];
-            //查看剩余区域是哪个区
-//        $surplusArr=[$calcBonus['SURPLUS_1L'],$calcBonus['SURPLUS_2L'],$calcBonus['SURPLUS_3L']];
-//        $bigLocation = array_search(max($surplusArr), $surplusArr);
-//        $bigLocationName = ['一市场','二市场','三市场'][$bigLocation];
-//        $data[]=['name'=>'剩余业绩市场','value'=>$bigLocationName];
-//        $data[]=['name'=>'剩余业绩','value'=>Tool::formatFrontPerf($surplusArr[$bigLocation])];
-
         }else{
             $data[] = ['name' => '总奖金', 'value' => Tool::formatPrice($calcBonus['BONUS_TOTAL'])];
         }

+ 0 - 4
frontendApi/modules/v1/controllers/SiteController.php

@@ -117,8 +117,6 @@ class SiteController extends BaseController
         $decLevels = Cache::getDecLevelConfig();
         // 聘级
         $empLevels = Cache::getEmpLevelConfig();
-        // 皇冠星级
-        $crownLevels = Cache::getStarCrownLevelConfig();
         // 菜单
         $menu = require Yii::getAlias('@frontendApi/config/menu.php');
         $menu = $this->_childMenu($menu);
@@ -132,7 +130,6 @@ class SiteController extends BaseController
         $periodNum = Period::instance()->getNowPeriodNum();
         $curYM = Period::find()->select("CALC_YEAR,CALC_MONTH")->where('PERIOD_NUM=:PERIOD_NUM', [':PERIOD_NUM' => $periodNum])->asArray()->one();
         $plist = Period::find()->select("PERIOD_NUM")->where('CALC_YEAR=:CALC_YEAR AND CALC_MONTH=:CALC_MONTH', [':CALC_YEAR' => $curYM['CALC_YEAR'],':CALC_MONTH'=>$curYM['CALC_MONTH']])->orderBy('PERIOD_NUM ASC')->asArray()->all();
-        $weeks = count($plist);
         $wkrd = '';
         foreach ($plist as $k=>$v){
             if($v['PERIOD_NUM']==$periodNum){
@@ -163,7 +160,6 @@ class SiteController extends BaseController
         return [
             'decLevels' => $decLevels,
             'empLevels' => $empLevels,
-            'crownLevels' => $crownLevels,
             'menu' => $menu,
             'daysDiff' => $daysDiff,
             'periodNum' => $periodNum . ',' . $wkrd . ' PC of ' . $monthArray[$curYM['CALC_MONTH']],