浏览代码

v1.2.6 up

openlockPPP 1 年之前
父节点
当前提交
dffe70385a

+ 12 - 4
JiaPeiManage.xcodeproj/project.pbxproj

@@ -59,6 +59,8 @@
 		908262052AA037C50034104C /* ETeachLogDataModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908262042AA037C50034104C /* ETeachLogDataModel.swift */; };
 		908262052AA037C50034104C /* ETeachLogDataModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908262042AA037C50034104C /* ETeachLogDataModel.swift */; };
 		908262072AA067C80034104C /* EstuLogListViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908262062AA067C80034104C /* EstuLogListViewModel.swift */; };
 		908262072AA067C80034104C /* EstuLogListViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908262062AA067C80034104C /* EstuLogListViewModel.swift */; };
 		908262092AA0955C0034104C /* ETeachLogPhotoDataModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908262082AA0955C0034104C /* ETeachLogPhotoDataModel.swift */; };
 		908262092AA0955C0034104C /* ETeachLogPhotoDataModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908262082AA0955C0034104C /* ETeachLogPhotoDataModel.swift */; };
+		9087CC532BBD30080029FD00 /* StatisticsStuListPageController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9087CC522BBD30080029FD00 /* StatisticsStuListPageController.swift */; };
+		9087CC552BBD5B440029FD00 /* StatisticsStuListViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9087CC542BBD5B440029FD00 /* StatisticsStuListViewModel.swift */; };
 		908FEE992A42A1D300BEB81C /* StuResultDataModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908FEE982A42A1D300BEB81C /* StuResultDataModel.swift */; };
 		908FEE992A42A1D300BEB81C /* StuResultDataModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908FEE982A42A1D300BEB81C /* StuResultDataModel.swift */; };
 		908FEE9B2A42CA1D00BEB81C /* MeTraineeDetails04HeaderView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908FEE9A2A42CA1D00BEB81C /* MeTraineeDetails04HeaderView.swift */; };
 		908FEE9B2A42CA1D00BEB81C /* MeTraineeDetails04HeaderView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 908FEE9A2A42CA1D00BEB81C /* MeTraineeDetails04HeaderView.swift */; };
 		908FEE9D2A42CA3F00BEB81C /* MeTraineeDetails04HeaderView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 908FEE9C2A42CA3F00BEB81C /* MeTraineeDetails04HeaderView.xib */; };
 		908FEE9D2A42CA3F00BEB81C /* MeTraineeDetails04HeaderView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 908FEE9C2A42CA3F00BEB81C /* MeTraineeDetails04HeaderView.xib */; };
@@ -271,6 +273,8 @@
 		908262042AA037C50034104C /* ETeachLogDataModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ETeachLogDataModel.swift; sourceTree = "<group>"; };
 		908262042AA037C50034104C /* ETeachLogDataModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ETeachLogDataModel.swift; sourceTree = "<group>"; };
 		908262062AA067C80034104C /* EstuLogListViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EstuLogListViewModel.swift; sourceTree = "<group>"; };
 		908262062AA067C80034104C /* EstuLogListViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EstuLogListViewModel.swift; sourceTree = "<group>"; };
 		908262082AA0955C0034104C /* ETeachLogPhotoDataModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ETeachLogPhotoDataModel.swift; sourceTree = "<group>"; };
 		908262082AA0955C0034104C /* ETeachLogPhotoDataModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ETeachLogPhotoDataModel.swift; sourceTree = "<group>"; };
+		9087CC522BBD30080029FD00 /* StatisticsStuListPageController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StatisticsStuListPageController.swift; sourceTree = "<group>"; };
+		9087CC542BBD5B440029FD00 /* StatisticsStuListViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StatisticsStuListViewModel.swift; sourceTree = "<group>"; };
 		908FEE982A42A1D300BEB81C /* StuResultDataModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StuResultDataModel.swift; sourceTree = "<group>"; };
 		908FEE982A42A1D300BEB81C /* StuResultDataModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StuResultDataModel.swift; sourceTree = "<group>"; };
 		908FEE9A2A42CA1D00BEB81C /* MeTraineeDetails04HeaderView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeTraineeDetails04HeaderView.swift; sourceTree = "<group>"; };
 		908FEE9A2A42CA1D00BEB81C /* MeTraineeDetails04HeaderView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeTraineeDetails04HeaderView.swift; sourceTree = "<group>"; };
 		908FEE9C2A42CA3F00BEB81C /* MeTraineeDetails04HeaderView.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = MeTraineeDetails04HeaderView.xib; sourceTree = "<group>"; };
 		908FEE9C2A42CA3F00BEB81C /* MeTraineeDetails04HeaderView.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = MeTraineeDetails04HeaderView.xib; sourceTree = "<group>"; };
@@ -675,6 +679,7 @@
 			isa = PBXGroup;
 			isa = PBXGroup;
 			children = (
 			children = (
 				90971E732A498C4C00267B7F /* StatisticsPageController.swift */,
 				90971E732A498C4C00267B7F /* StatisticsPageController.swift */,
+				9087CC522BBD30080029FD00 /* StatisticsStuListPageController.swift */,
 			);
 			);
 			path = Controllers;
 			path = Controllers;
 			sourceTree = "<group>";
 			sourceTree = "<group>";
@@ -716,6 +721,7 @@
 			isa = PBXGroup;
 			isa = PBXGroup;
 			children = (
 			children = (
 				90A8CD4A2A5F9EE000C02402 /* StatisticsPageViewModel.swift */,
 				90A8CD4A2A5F9EE000C02402 /* StatisticsPageViewModel.swift */,
+				9087CC542BBD5B440029FD00 /* StatisticsStuListViewModel.swift */,
 			);
 			);
 			path = ViewModel;
 			path = ViewModel;
 			sourceTree = "<group>";
 			sourceTree = "<group>";
@@ -1378,6 +1384,7 @@
 				90CE52332A36E4600033BD06 /* BaseViewController.swift in Sources */,
 				90CE52332A36E4600033BD06 /* BaseViewController.swift in Sources */,
 				9043ADB02A569309005F6F81 /* GTMBase64.m in Sources */,
 				9043ADB02A569309005F6F81 /* GTMBase64.m in Sources */,
 				90CE52A32A36E59A0033BD06 /* UIImageView+Kingfisher.swift in Sources */,
 				90CE52A32A36E59A0033BD06 /* UIImageView+Kingfisher.swift in Sources */,
+				9087CC552BBD5B440029FD00 /* StatisticsStuListViewModel.swift in Sources */,
 				903628C22A41768400F0AA6C /* MeTraineeDetails03Controller.swift in Sources */,
 				903628C22A41768400F0AA6C /* MeTraineeDetails03Controller.swift in Sources */,
 				90CE527D2A36E5460033BD06 /* Refreshable.swift in Sources */,
 				90CE527D2A36E5460033BD06 /* Refreshable.swift in Sources */,
 				908261FF2A9F31A00034104C /* BaseCollectionViewCell.swift in Sources */,
 				908261FF2A9F31A00034104C /* BaseCollectionViewCell.swift in Sources */,
@@ -1422,6 +1429,7 @@
 				908FEEA52A42D62A00BEB81C /* StuTmsSignDataModel.swift in Sources */,
 				908FEEA52A42D62A00BEB81C /* StuTmsSignDataModel.swift in Sources */,
 				90BC4BDE2A3C4691006FD683 /* MeTraineeDetailsPageViewController.swift in Sources */,
 				90BC4BDE2A3C4691006FD683 /* MeTraineeDetailsPageViewController.swift in Sources */,
 				908261EE2A9DD3ED0034104C /* EstuLogListCell.swift in Sources */,
 				908261EE2A9DD3ED0034104C /* EstuLogListCell.swift in Sources */,
+				9087CC532BBD30080029FD00 /* StatisticsStuListPageController.swift in Sources */,
 				90A8CD4B2A5F9EE000C02402 /* StatisticsPageViewModel.swift in Sources */,
 				90A8CD4B2A5F9EE000C02402 /* StatisticsPageViewModel.swift in Sources */,
 				90CE52CB2A36E5EC0033BD06 /* UILabel+Rx.swift in Sources */,
 				90CE52CB2A36E5EC0033BD06 /* UILabel+Rx.swift in Sources */,
 				903C04AA2A651B1200935764 /* NYIDFA.swift in Sources */,
 				903C04AA2A651B1200935764 /* NYIDFA.swift in Sources */,
@@ -1652,7 +1660,7 @@
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
 				CODE_SIGN_ENTITLEMENTS = JiaPeiManage/JiaPeiManage.entitlements;
 				CODE_SIGN_ENTITLEMENTS = JiaPeiManage/JiaPeiManage.entitlements;
 				CODE_SIGN_STYLE = Automatic;
 				CODE_SIGN_STYLE = Automatic;
-				CURRENT_PROJECT_VERSION = 1252024031201;
+				CURRENT_PROJECT_VERSION = 1262024040801;
 				DEVELOPMENT_TEAM = K7T6CU5SW5;
 				DEVELOPMENT_TEAM = K7T6CU5SW5;
 				GENERATE_INFOPLIST_FILE = YES;
 				GENERATE_INFOPLIST_FILE = YES;
 				INFOPLIST_FILE = JiaPeiManage/Info.plist;
 				INFOPLIST_FILE = JiaPeiManage/Info.plist;
@@ -1674,7 +1682,7 @@
 					"$(inherited)",
 					"$(inherited)",
 					"$(SDKROOT)/usr/lib/swift",
 					"$(SDKROOT)/usr/lib/swift",
 				);
 				);
-				MARKETING_VERSION = 1.2.5;
+				MARKETING_VERSION = 1.2.6;
 				PRODUCT_BUNDLE_IDENTIFIER = com.kestrel.JSJPCoach;
 				PRODUCT_BUNDLE_IDENTIFIER = com.kestrel.JSJPCoach;
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
 				SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
@@ -1695,7 +1703,7 @@
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
 				CODE_SIGN_ENTITLEMENTS = JiaPeiManage/JiaPeiManage.entitlements;
 				CODE_SIGN_ENTITLEMENTS = JiaPeiManage/JiaPeiManage.entitlements;
 				CODE_SIGN_STYLE = Automatic;
 				CODE_SIGN_STYLE = Automatic;
-				CURRENT_PROJECT_VERSION = 1252024031201;
+				CURRENT_PROJECT_VERSION = 1262024040801;
 				DEVELOPMENT_TEAM = K7T6CU5SW5;
 				DEVELOPMENT_TEAM = K7T6CU5SW5;
 				GENERATE_INFOPLIST_FILE = YES;
 				GENERATE_INFOPLIST_FILE = YES;
 				INFOPLIST_FILE = JiaPeiManage/Info.plist;
 				INFOPLIST_FILE = JiaPeiManage/Info.plist;
@@ -1717,7 +1725,7 @@
 					"$(inherited)",
 					"$(inherited)",
 					"$(SDKROOT)/usr/lib/swift",
 					"$(SDKROOT)/usr/lib/swift",
 				);
 				);
-				MARKETING_VERSION = 1.2.5;
+				MARKETING_VERSION = 1.2.6;
 				PRODUCT_BUNDLE_IDENTIFIER = com.kestrel.JSJPCoach;
 				PRODUCT_BUNDLE_IDENTIFIER = com.kestrel.JSJPCoach;
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
 				SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";

+ 19 - 25
JiaPeiManage/Sources/Constants/NYMacros.swift

@@ -155,33 +155,27 @@ struct NYDate {
     static func getDateYear()-> [String] {
     static func getDateYear()-> [String] {
         let calendar = Calendar.current
         let calendar = Calendar.current
         let currentDate = Date()
         let currentDate = Date()
-
-        // 获取当前年份
         let currentYear = calendar.component(.year, from: currentDate)
         let currentYear = calendar.component(.year, from: currentDate)
-
-        // 构建日期组件,设置年份为当前年份,月份和日份分别为1
-        var dateComponents = DateComponents()
-        dateComponents.year = currentYear
-        dateComponents.month = 1
-        dateComponents.day = 1
-
+        
+        // 获取本年第一天
+        var startDateComponents = DateComponents()
+        startDateComponents.year = currentYear
+        startDateComponents.month = 1
+        startDateComponents.day = 1
+        let startDate = calendar.date(from: startDateComponents)!
+        
+        // 获取本年最后一天
+        var endDateComponents = DateComponents()
+        endDateComponents.year = currentYear
+        endDateComponents.month = 12
+        endDateComponents.day = 31
+        let endDate = calendar.date(from: endDateComponents)!
+        
         let dateFormatter = DateFormatter()
         let dateFormatter = DateFormatter()
-        dateFormatter.dateFormat = "YYYY-MM-dd"
-
-        // 获取本年起始日期
-        var startDateString = ""
-        if let startDate = calendar.date(from: dateComponents) {
-            startDateString = dateFormatter.string(from: startDate)
-        }
-
-        // 获取本年结束日期
-        var endDateString = ""
-        dateComponents.year = currentYear + 1
-        dateComponents.day = -1
-        if let endDate = calendar.date(from: dateComponents) {
-            //calendar.date(byAdding: DateComponents(year: 1, day: -1), to: currentDate) {
-            endDateString = dateFormatter.string(from: endDate)
-        }
+        dateFormatter.dateFormat = "yyyy-MM-dd"
+        
+        let startDateString = dateFormatter.string(from: startDate)
+        let endDateString = dateFormatter.string(from: endDate)
 
 
         return [startDateString,endDateString]
         return [startDateString,endDateString]
     }
     }

+ 19 - 0
JiaPeiManage/Sources/Modulars/Statistics/Controllers/StatisticsPageController.swift

@@ -127,6 +127,14 @@ final class StatisticsPageController: BaseGroupTableViewController {
                 headerView.student_button.isSelected = !headerView.student_button.isSelected
                 headerView.student_button.isSelected = !headerView.student_button.isSelected
                 self.statisticsPageViewModel?.getStuCountdo()
                 self.statisticsPageViewModel?.getStuCountdo()
             }).disposed(by: disposeBag)
             }).disposed(by: disposeBag)
+            //预报名-点击
+            headerView.advanceday_btn.addTarget(self, action: #selector(ItemClickdo(_:)), for: .touchUpInside)
+            //今日-点击
+            headerView.today_btn.addTarget(self, action: #selector(ItemClickdo(_:)), for: .touchUpInside)
+            //月份-点击
+            headerView.thismonth_btn.addTarget(self, action: #selector(ItemClickdo(_:)), for: .touchUpInside)
+            //年份-点击
+            headerView.thisyear_btn.addTarget(self, action: #selector(ItemClickdo(_:)), for: .touchUpInside)
         }else{
         }else{
             //普通模式
             //普通模式
             //header - 事件
             //header - 事件
@@ -152,6 +160,12 @@ final class StatisticsPageController: BaseGroupTableViewController {
                 officialheaderView.student_button.isSelected = !officialheaderView.student_button.isSelected
                 officialheaderView.student_button.isSelected = !officialheaderView.student_button.isSelected
                 self.statisticsPageViewModel?.getStuCountdo()
                 self.statisticsPageViewModel?.getStuCountdo()
             }).disposed(by: disposeBag)
             }).disposed(by: disposeBag)
+            //今日-点击
+            officialheaderView.today_btn.addTarget(self, action: #selector(ItemClickdo(_:)), for: .touchUpInside)
+            //月份-点击
+            officialheaderView.thismonth_btn.addTarget(self, action: #selector(ItemClickdo(_:)), for: .touchUpInside)
+            //年份-点击
+            officialheaderView.thisyear_btn.addTarget(self, action: #selector(ItemClickdo(_:)), for: .touchUpInside)
         }
         }
         
         
         //hide showSelectDateView
         //hide showSelectDateView
@@ -213,4 +227,9 @@ final class StatisticsPageController: BaseGroupTableViewController {
         self.isEmptyDisplay = false
         self.isEmptyDisplay = false
     }
     }
     
     
+    //点击item cell
+    @objc func ItemClickdo(_ sender: UIButton) {
+        self.statisticsPageViewModel?.statisticsListItemCellClickdo(type: sender.tag)
+    }
+    
 }
 }

+ 154 - 0
JiaPeiManage/Sources/Modulars/Statistics/Controllers/StatisticsStuListPageController.swift

@@ -0,0 +1,154 @@
+//
+//  StatisticsStuListPageController.swift
+//  JiaPeiManage
+//
+//  Created by Ning.ge on 2024/4/3.
+//
+
+import UIKit
+import RxSwift
+import RxCocoa
+
+
+final class StatisticsStuListPageController: BaseTableViewController {
+    
+    let cellIdentifier:String = "_MeTraineeStuListCell"
+    //VM
+    let statisticsStuListViewModel = StatisticsStuListViewModel()
+    
+    // MARK: UI let
+    let statusBar = UIView().then {
+        $0.backgroundColor = UIColor.db_theme
+    }
+    
+    let navBar = MeTraineeNavBar.loadFromNib().then {
+        $0.title_label.text = "今日预报名"
+    }
+    
+    var s_type = 0
+    var title_str = ""
+    var dateTime_str = ""
+    init(type:Int,title:String,schoolId:Int,dateTime:String) {
+        super.init()
+        s_type = type
+        title_str = title
+        dateTime_str = dateTime
+        var startDate = ""
+        var endDate = ""
+        let date = NYDate.getThisDate() //今日
+        switch type {
+            case 0://今日预报名
+                startDate = date
+                endDate = date
+            case 1://今日
+                startDate = date
+                endDate = date
+            case 2://本月
+                let dates = NYDate.getDateMonth()//本月
+                startDate = dates[0]
+                endDate = dates[1]
+            case 3://本年
+                let dates = NYDate.getDateYear() //本年
+                startDate = dates[0]
+                endDate = dates[1]
+            case 4://日
+                startDate = dateTime_str
+                endDate = dateTime_str
+            case 5://月
+                startDate = dateTime_str + "-01"
+                endDate = dateTime_str + "-31"
+            case 6://年
+                startDate = dateTime_str + "-01-01"
+                endDate = dateTime_str + "-12-31"
+            default:
+                startDate = date
+                endDate = date
+        }
+        self.statisticsStuListViewModel.startDate = startDate
+        self.statisticsStuListViewModel.endDate = endDate
+        self.statisticsStuListViewModel.type = s_type == 0 ? .advancet : .official
+        self.statisticsStuListViewModel.state = ""
+        self.statisticsStuListViewModel.schoolId = schoolId
+    }
+    
+    required convenience init?(coder aDecoder: NSCoder) {
+        fatalError("init(coder:) has not been implemented")
+    }
+    
+    override func setupConstraints() {
+        
+        statusBar.snp.makeConstraints { (make) in
+            make.left.right.top.equalToSuperview()
+            make.height.equalTo(Metric.statusBarHeight)
+        }
+        
+        navBar.snp.remakeConstraints { (make) in
+            make.left.right.equalToSuperview()
+            make.height.equalTo(Metric.navBarHeight)
+            make.top.equalTo(statusBar.snp.bottom)
+        }
+        
+        tableView.snp.remakeConstraints { make in
+            make.top.equalTo(navBar.snp.bottom)
+            make.left.right.bottom.equalToSuperview()
+        }
+        
+    }
+    
+    override func viewDidLoad() {
+        super.viewDidLoad()
+        //绑定
+        setupUI()
+        biandView()
+        //获取list
+        self.statisticsStuListViewModel.getCoachInfoList(vc:self)
+    }
+    func setupUI(){
+        self.view.addSubview(navBar)
+        self.view.addSubview(statusBar)
+        self.view.backgroundColor = .db_theme
+        self.navBar.back_button.addTarget(self, action: #selector(actionBackdo), for: .touchUpInside)
+        self.navBar.search_button.isHidden = true
+    }
+    func biandView(){
+        navBar.title_label.text = title_str
+        tableView.delegate = self
+//        tableView.dataSource = self
+        tableView.separatorStyle = .none //去除分割线
+        tableView.register(UINib(nibName: "MeTraineeSubjectCell", bundle: nil), forCellReuseIdentifier: cellIdentifier)
+        tableView.rowHeight = 288.f
+        setupRefreshHeader(tableView) {[unowned self] in
+            self.statisticsStuListViewModel.getCoachInfoList(vc:self)
+        }
+        // 设置上拉加载更多
+        tableView.es.addInfiniteScrolling { [unowned self] in
+            if self.statisticsStuListViewModel != nil {
+                self.statisticsStuListViewModel.getLoadMore(vc:self)
+            }
+        }
+        self.isEmptyDisplay = false
+        
+        //RX 绑定
+        self.statisticsStuListViewModel.items
+            .bind(to: tableView.rx.items(cellIdentifier: cellIdentifier,cellType:MeTraineeSubjectCell.self)) { (row, model, cell) in
+                cell.index_button.setTitle("\(row+1)", for: .normal)
+                cell.setRowInfo(rowInfo:model as! RowInfo)
+            }
+            .disposed(by: disposeBag)
+        // tableView点击事件
+        tableView.rx.itemSelected.throttle(.seconds(1), scheduler: MainScheduler.instance)
+            .subscribe(onNext: { [weak self]indexPath in
+            print("点击\(indexPath)行")
+                let rowInfo:RowInfo = self!.statisticsStuListViewModel.rows[indexPath.row]
+            if rowInfo != nil { //rowInfo.bmType == "2"
+                NYSwRouter.push(NYSwPushType.trainee_info,context: rowInfo)
+            }
+            self?.tableView.deselectRow(at: indexPath, animated: false)
+        }).disposed(by: disposeBag)
+    }
+    
+}
+
+extension StatisticsStuListPageController:UITableViewDelegate {
+}
+

+ 69 - 2
JiaPeiManage/Sources/Modulars/Statistics/ViewModel/StatisticsPageViewModel.swift

@@ -24,7 +24,8 @@ class StatisticsPageViewModel: NSObject {
     var fieldType:Int = 1 //1:时间 2:学员数
     var fieldType:Int = 1 //1:时间 2:学员数
     var sortType:Int = 2 //1:正序 2:倒序
     var sortType:Int = 2 //1:正序 2:倒序
     var type:StatisticsType = .normal // 普通-预售
     var type:StatisticsType = .normal // 普通-预售
-    
+    var title_str = ""
+    var dateTime_str = ""
     init(vc:StatisticsPageController) {
     init(vc:StatisticsPageController) {
         super.init()
         super.init()
         self.vc = vc
         self.vc = vc
@@ -189,6 +190,52 @@ class StatisticsPageViewModel: NSObject {
         vc!.selectDateView.showCount = 0
         vc!.selectDateView.showCount = 0
         self.switchStatisticsStuCount()
         self.switchStatisticsStuCount()
     }
     }
+    //统计-点击
+    func statisticsListItemCellClickdo(type:Int){
+//        //今日
+//        today_num_label.text = String(stuTotalCountDataModel.day)
+//        //昨日
+//        yesterday_num_label.text = "昨日  " + String(stuTotalCountDataModel.yesterday)
+//        //当月
+//        thismonth_num_label.text = String(stuTotalCountDataModel.month)
+//        //上月
+//        lastmonth_num_label.text = "上月  " + String(stuTotalCountDataModel.lastMonth)
+//        //今年
+//        thisyear_num_label.text = String(stuTotalCountDataModel.year)
+//        //去年
+//        lastyear_num_label.text = "去年  " + String(stuTotalCountDataModel.lastYear)
+        
+        switch type {
+            case 0:
+                if let yday = stuTotalCountDataModel?.yday {
+                    title_str = "今日预报名" + String(yday)
+                } else {
+                    title_str = "今日预报名"
+                }
+            case 1:
+                if let day = stuTotalCountDataModel?.day {
+                    title_str = "今日报名" + String(day)
+                } else {
+                    title_str = "今日报名"
+                }
+            case 2:
+                if let month = stuTotalCountDataModel?.month {
+                    title_str = "本月报名" + String(month)
+                } else {
+                    title_str = "本月报名"
+                }
+            case 3:
+                if let year = stuTotalCountDataModel?.year {
+                    title_str = "本年报名" + String(year)
+                } else {
+                    title_str = "本年报名"
+                }
+            default:
+                let a = ""
+                
+        }
+        NYSwRouter.push(NYSwPushType.trainee_statistics_stulist,context: [type,title_str,dateTime_str])
+    }
     
     
     // MARK: selectDateView
     // MARK: selectDateView
     //显示selectDateView
     //显示selectDateView
@@ -333,8 +380,28 @@ extension StatisticsPageViewModel:UITableViewDataSource {
 
 
 //事件
 //事件
 extension StatisticsPageViewModel:UITableViewDelegate {
 extension StatisticsPageViewModel:UITableViewDelegate {
-
     
     
+    func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
+        // 根据 indexPath 获取选中的行
+        let selectedRow = indexPath.row - 1
+        // 根据选中的行执行相应的操作
+        print("Selected row: \(selectedRow)")
+        let rowInfo:StuCountInfoModel = (stuCountDataModel?.rows[selectedRow])!
+        var type = 4
+        title_str = rowInfo.dateTime+"("+String(rowInfo.stuCount)+")"
+        dateTime_str = rowInfo.dateTime
+        switch dateType {
+            case .day:
+                type = 4
+            case .month:
+                type = 5
+            case .year:
+                type = 6
+        }
+        statisticsListItemCellClickdo(type: type)
+        tableView.deselectRow(at: indexPath, animated: false)
+    }
+
 }
 }
 
 
 //PGDatePickerDelegate
 //PGDatePickerDelegate

+ 275 - 0
JiaPeiManage/Sources/Modulars/Statistics/ViewModel/StatisticsStuListViewModel.swift

@@ -0,0 +1,275 @@
+//
+//  StatisticsStuListViewModel.swift
+//  JiaPeiManage
+//
+//  Created by Ning.ge on 2024/4/3.
+//
+
+import UIKit
+import RxSwift
+
+class StatisticsStuListViewModel: NSObject {
+    
+    // MARK: 服务属性
+    private let cocahService: CoachServiceType = CoachService(networking: CoachNetworking())
+    
+    private let itemsSubject = BehaviorSubject<[RowInfo]>(value: [])
+        
+    var items: Observable<[RowInfo]> {
+        return itemsSubject.asObservable()
+    }
+    // MARK: 数据
+    var traineeDataModel:TraineeDataModel?
+    var rows:[RowInfo] = []
+    
+    var page:Int = 1
+    var pageSize:Int = 10
+    var state = "1"
+    var schoolId:Int = 0
+    var type:TraineeType?
+    var startDate = ""
+    var endDate = ""
+
+    override init() {
+        super.init()
+//        searchCoachInfoList()
+    }
+    
+    func getCoachInfoList(vc:StatisticsStuListPageController)
+    {
+        page = 1
+        let coachId = "\(LocalManager.userInfo.id)" //8-28 都传入coachId 都由服务端判断
+        if (self.type == .advancet){ //预报名
+            if state == "0" {
+                if (schoolId>0){//在校
+                    self.cocahService.coachTempListDateRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: "",startDate: startDate, endDate: endDate)
+                        .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                            self.rows.removeAll()
+                            self.traineeDataModel = traineeDataModel
+                            self.rows += traineeDataModel.rows!
+                            itemsSubject.onNext(self.rows)//消息rx
+                            print("coachInfoListRequest成功")
+                            vc.isEmptyDisplay = true
+                            vc.hideLoadAnimation()
+                            vc.tableView.reloadData()
+                            vc.stopRefresh()
+                        }, onError: { error in
+                            vc.stopRefresh()
+                        })
+                        .disposed(by: vc.disposeBag)
+                }else {//我的
+                    self.cocahService.mycoachTempListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: "")
+                        .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                            self.rows.removeAll()
+                            self.traineeDataModel = traineeDataModel
+                            self.rows += traineeDataModel.rows!
+                            itemsSubject.onNext(self.rows)//消息rx
+                            print("coachInfoListRequest成功")
+                            vc.isEmptyDisplay = true
+                            vc.hideLoadAnimation()
+                            vc.tableView.reloadData()
+                            vc.stopRefresh()
+                        }, onError: { error in
+                            vc.stopRefresh()
+                        })
+                        .disposed(by: vc.disposeBag)
+                }
+                
+            }else {
+                if (schoolId>0){//在校
+                    self.cocahService.coachInfoListDateRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: state,startDate: startDate, endDate: endDate)
+                        .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                            self.rows.removeAll()
+                            self.traineeDataModel = traineeDataModel
+                            self.rows += traineeDataModel.rows!
+                            itemsSubject.onNext(self.rows)//消息rx
+                            print("coachInfoListRequest成功")
+                            vc.isEmptyDisplay = true
+                            vc.hideLoadAnimation()
+                            vc.tableView.reloadData()
+                            vc.stopRefresh()
+                        }, onError: { error in
+                            vc.stopRefresh()
+                        })
+                        .disposed(by: vc.disposeBag)
+                }else{//我的
+                    self.cocahService.coachInfoMyListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: state)
+                        .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                            self.rows.removeAll()
+                            self.traineeDataModel = traineeDataModel
+                            self.rows += traineeDataModel.rows!
+                            itemsSubject.onNext(self.rows)//消息rx
+                            print("coachInfoListRequest成功")
+                            vc.isEmptyDisplay = true
+                            vc.hideLoadAnimation()
+                            vc.tableView.reloadData()
+                            vc.stopRefresh()
+                        }, onError: { error in
+                            vc.stopRefresh()
+                        })
+                        .disposed(by: vc.disposeBag)
+                }
+                
+            }
+            
+            
+            return
+        }
+        if schoolId>0 {//在校
+            self.cocahService.coachInfoListDateRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: state,startDate: startDate, endDate: endDate)
+                .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                    self.rows.removeAll()
+                    self.traineeDataModel = traineeDataModel
+                    self.rows += traineeDataModel.rows!
+                    itemsSubject.onNext(self.rows)//消息rx
+                    print("coachInfoListRequest成功")
+                    vc.isEmptyDisplay = true
+                    vc.hideLoadAnimation()
+                    vc.tableView.reloadData()
+                    vc.stopRefresh()
+                }, onError: { error in
+                    vc.stopRefresh()
+                })
+                .disposed(by: vc.disposeBag)
+        }else{//我的
+            //schoolId = LocalManager.userInfo.schoolId
+            self.cocahService.coachInfoMyListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: state)
+                .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                    self.rows.removeAll()
+                    self.traineeDataModel = traineeDataModel
+                    self.rows += traineeDataModel.rows!
+                    itemsSubject.onNext(self.rows)//消息rx
+                    print("coachInfoListRequest成功")
+                    vc.isEmptyDisplay = true
+                    vc.hideLoadAnimation()
+                    vc.tableView.reloadData()
+                    vc.stopRefresh()
+                }, onError: { error in
+                    vc.stopRefresh()
+                })
+                .disposed(by: vc.disposeBag)
+        }
+        
+    }
+    
+    
+    //更多
+    func getLoadMore(vc:StatisticsStuListPageController){
+        //计算-页数
+        if (traineeDataModel != nil){
+            let total = pageSize*self.page
+            if(total<(traineeDataModel?.total)!){
+                self.page+=1
+            }else{
+                vc.stopLoad()
+                return //已经显示完
+            }
+        }
+        let coachId = "\(LocalManager.userInfo.id)" //8-28 都传入coachId 都由服务端判断
+        if (self.type == .advancet){ //预报名
+            if state == "0" {
+                if (schoolId>0){//在校
+                    self.cocahService.coachTempListDateRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: "",startDate: startDate, endDate: endDate)
+                        .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                            self.traineeDataModel = traineeDataModel
+                            if(traineeDataModel.rows!.count>0){
+                                self.rows += traineeDataModel.rows!
+                            }
+                            itemsSubject.onNext(self.rows)//消息rx
+                            print("coachInfoListRequest成功")
+        //                    vc.tableView.reloadData()
+                            vc.stopLoad()
+                        }, onError: { error in
+                            vc.stopRefresh()
+                        })
+                        .disposed(by: vc.disposeBag)
+                }else {//我的
+                    self.cocahService.mycoachTempListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: "")
+                        .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                            self.traineeDataModel = traineeDataModel
+                            if(traineeDataModel.rows!.count>0){
+                                self.rows += traineeDataModel.rows!
+                            }
+                            itemsSubject.onNext(self.rows)//消息rx
+                            print("coachInfoListRequest成功")
+        //                    vc.tableView.reloadData()
+                            vc.stopLoad()
+                        }, onError: { error in
+                            vc.stopRefresh()
+                        })
+                        .disposed(by: vc.disposeBag)
+                    
+                }
+                
+            }else {
+                if (schoolId>0){//在校
+                    self.cocahService.coachInfoListDateRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: state,startDate: startDate, endDate: endDate)
+                        .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                            self.traineeDataModel = traineeDataModel
+                            if(traineeDataModel.rows!.count>0){
+                                self.rows += traineeDataModel.rows!
+                            }
+                            itemsSubject.onNext(self.rows)//消息rx
+                            print("coachInfoListRequest成功")
+            //                vc.tableView.reloadData()
+                            vc.stopLoad()
+                        }, onError: { error in
+                            vc.stopRefresh()
+                        })
+                        .disposed(by: vc.disposeBag)
+                }else {//我的
+                    self.cocahService.coachInfoMyListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: state)
+                        .subscribe(onSuccess: {[unowned self] traineeDataModel in
+                            self.traineeDataModel = traineeDataModel
+                            if(traineeDataModel.rows!.count>0){
+                                self.rows += traineeDataModel.rows!
+                            }
+                            itemsSubject.onNext(self.rows)//消息rx
+                            print("coachInfoListRequest成功")
+            //                vc.tableView.reloadData()
+                            vc.stopLoad()
+                        }, onError: { error in
+                            vc.stopRefresh()
+                        })
+                        .disposed(by: vc.disposeBag)
+                }
+                
+            }
+            return
+        }
+        if schoolId>0 {//在校
+            //请求网络-加载
+            self.cocahService.coachInfoListDateRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: state,startDate: startDate, endDate: endDate)
+                .subscribe(onSuccess: {[unowned self]  traineeDataModel in
+                    self.traineeDataModel = traineeDataModel
+                    if(traineeDataModel.rows!.count>0){
+                        self.rows += traineeDataModel.rows!
+                    }
+                    itemsSubject.onNext(self.rows)//消息rx
+                    print("coachInfoListRequest成功")
+    //                vc.tableView.reloadData()
+                    vc.stopLoad()
+                }, onError: { error in
+                    vc.stopLoad()
+                })
+                .disposed(by: vc.disposeBag)
+        }else{//我的
+            //请求网络-加载
+            self.cocahService.coachInfoMyListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: state)
+                .subscribe(onSuccess: {[unowned self]  traineeDataModel in
+                    self.traineeDataModel = traineeDataModel
+                    if(traineeDataModel.rows!.count>0){
+                        self.rows += traineeDataModel.rows!
+                    }
+                    itemsSubject.onNext(self.rows)//消息rx
+                    print("coachInfoListRequest成功")
+    //                vc.tableView.reloadData()
+                    vc.stopLoad()
+                }, onError: { error in
+                    vc.stopLoad()
+                })
+                .disposed(by: vc.disposeBag)
+        }
+        
+    }
+}

+ 7 - 1
JiaPeiManage/Sources/Modulars/Statistics/Views/StatisticsOfficialPageHeaderView.swift

@@ -7,6 +7,12 @@
 
 
 final class StatisticsOfficialPageHeaderView: UIView,NibLoadable {
 final class StatisticsOfficialPageHeaderView: UIView,NibLoadable {
     
     
+    //今日报名
+    @IBOutlet weak var today_btn: UIButton!
+    //本月报名
+    @IBOutlet weak var thismonth_btn: UIButton!
+    //本年报名
+    @IBOutlet weak var thisyear_btn: UIButton!
     //今日
     //今日
     @IBOutlet weak var today_num_label: UILabel!
     @IBOutlet weak var today_num_label: UILabel!
     //昨日
     //昨日
@@ -79,5 +85,5 @@ final class StatisticsOfficialPageHeaderView: UIView,NibLoadable {
         }
         }
     }
     }
 
 
-    
+
 }
 }

+ 44 - 2
JiaPeiManage/Sources/Modulars/Statistics/Views/StatisticsOfficialPageHeaderView.xib

@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="22505" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
     <device id="retina5_9" orientation="portrait" appearance="light"/>
     <device id="retina5_9" orientation="portrait" appearance="light"/>
     <dependencies>
     <dependencies>
         <deployment identifier="iOS"/>
         <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21678"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22504"/>
         <capability name="Safe area layout guides" minToolsVersion="9.0"/>
         <capability name="Safe area layout guides" minToolsVersion="9.0"/>
         <capability name="System colors in document resources" minToolsVersion="11.0"/>
         <capability name="System colors in document resources" minToolsVersion="11.0"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -85,14 +85,27 @@
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <nil key="highlightedColor"/>
                             <nil key="highlightedColor"/>
                         </label>
                         </label>
+                        <button opaque="NO" tag="1" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="b9t-oa-34Q">
+                            <rect key="frame" x="0.0" y="0.0" width="107.33333333333333" height="100"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <userDefinedRuntimeAttributes>
+                                <userDefinedRuntimeAttribute type="color" keyPath="borderColor">
+                                    <color key="value" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                </userDefinedRuntimeAttribute>
+                            </userDefinedRuntimeAttributes>
+                        </button>
                     </subviews>
                     </subviews>
                     <color key="backgroundColor" red="0.047058823530000002" green="0.21960784310000001" blue="0.23137254900000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <color key="backgroundColor" red="0.047058823530000002" green="0.21960784310000001" blue="0.23137254900000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <constraints>
                     <constraints>
+                        <constraint firstAttribute="trailing" secondItem="b9t-oa-34Q" secondAttribute="trailing" id="3X7-oO-eVD"/>
                         <constraint firstItem="9F7-sa-1Ow" firstAttribute="leading" secondItem="UC2-tt-gIX" secondAttribute="leading" id="7Rb-il-eZl"/>
                         <constraint firstItem="9F7-sa-1Ow" firstAttribute="leading" secondItem="UC2-tt-gIX" secondAttribute="leading" id="7Rb-il-eZl"/>
+                        <constraint firstItem="b9t-oa-34Q" firstAttribute="top" secondItem="UC2-tt-gIX" secondAttribute="top" id="8Vj-C9-Kqp"/>
                         <constraint firstAttribute="height" constant="100" id="AAE-SG-R9G"/>
                         <constraint firstAttribute="height" constant="100" id="AAE-SG-R9G"/>
+                        <constraint firstAttribute="bottom" secondItem="b9t-oa-34Q" secondAttribute="bottom" id="HXe-Ze-VwL"/>
                         <constraint firstAttribute="trailing" secondItem="J2F-Wf-N8Q" secondAttribute="trailing" id="Rlm-Ye-WKS"/>
                         <constraint firstAttribute="trailing" secondItem="J2F-Wf-N8Q" secondAttribute="trailing" id="Rlm-Ye-WKS"/>
                         <constraint firstAttribute="trailing" secondItem="9F7-sa-1Ow" secondAttribute="trailing" id="hhO-LQ-pbH"/>
                         <constraint firstAttribute="trailing" secondItem="9F7-sa-1Ow" secondAttribute="trailing" id="hhO-LQ-pbH"/>
                         <constraint firstItem="9F7-sa-1Ow" firstAttribute="top" secondItem="J2F-Wf-N8Q" secondAttribute="bottom" id="i6c-tf-DFA"/>
                         <constraint firstItem="9F7-sa-1Ow" firstAttribute="top" secondItem="J2F-Wf-N8Q" secondAttribute="bottom" id="i6c-tf-DFA"/>
+                        <constraint firstItem="b9t-oa-34Q" firstAttribute="leading" secondItem="UC2-tt-gIX" secondAttribute="leading" id="mq2-k4-L3A"/>
                         <constraint firstItem="J2F-Wf-N8Q" firstAttribute="leading" secondItem="UC2-tt-gIX" secondAttribute="leading" id="oF1-Zi-Bi0"/>
                         <constraint firstItem="J2F-Wf-N8Q" firstAttribute="leading" secondItem="UC2-tt-gIX" secondAttribute="leading" id="oF1-Zi-Bi0"/>
                         <constraint firstItem="0kL-oA-wsz" firstAttribute="top" secondItem="UC2-tt-gIX" secondAttribute="top" constant="11" id="oYF-AB-ALd"/>
                         <constraint firstItem="0kL-oA-wsz" firstAttribute="top" secondItem="UC2-tt-gIX" secondAttribute="top" constant="11" id="oYF-AB-ALd"/>
                         <constraint firstItem="J2F-Wf-N8Q" firstAttribute="top" secondItem="0kL-oA-wsz" secondAttribute="bottom" id="puu-On-4JS"/>
                         <constraint firstItem="J2F-Wf-N8Q" firstAttribute="top" secondItem="0kL-oA-wsz" secondAttribute="bottom" id="puu-On-4JS"/>
@@ -135,14 +148,27 @@
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <nil key="highlightedColor"/>
                             <nil key="highlightedColor"/>
                         </label>
                         </label>
+                        <button opaque="NO" tag="2" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="WjR-fe-3tF">
+                            <rect key="frame" x="0.0" y="0.0" width="107.66666666666667" height="100"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <userDefinedRuntimeAttributes>
+                                <userDefinedRuntimeAttribute type="color" keyPath="borderColor">
+                                    <color key="value" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                </userDefinedRuntimeAttribute>
+                            </userDefinedRuntimeAttributes>
+                        </button>
                     </subviews>
                     </subviews>
                     <color key="backgroundColor" red="0.20392156859999999" green="0.20392156859999999" blue="0.1450980392" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <color key="backgroundColor" red="0.20392156859999999" green="0.20392156859999999" blue="0.1450980392" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <constraints>
                     <constraints>
+                        <constraint firstAttribute="bottom" secondItem="WjR-fe-3tF" secondAttribute="bottom" id="1zp-yR-PGQ"/>
                         <constraint firstItem="kWS-ie-oMx" firstAttribute="top" secondItem="qsN-aN-JsK" secondAttribute="top" constant="11" id="AbY-9G-Xdb"/>
                         <constraint firstItem="kWS-ie-oMx" firstAttribute="top" secondItem="qsN-aN-JsK" secondAttribute="top" constant="11" id="AbY-9G-Xdb"/>
                         <constraint firstItem="AqZ-zf-Ce4" firstAttribute="top" secondItem="CZf-ir-TXF" secondAttribute="bottom" id="BGh-Gk-cHl"/>
                         <constraint firstItem="AqZ-zf-Ce4" firstAttribute="top" secondItem="CZf-ir-TXF" secondAttribute="bottom" id="BGh-Gk-cHl"/>
                         <constraint firstAttribute="trailing" secondItem="CZf-ir-TXF" secondAttribute="trailing" id="BuR-7b-PsU"/>
                         <constraint firstAttribute="trailing" secondItem="CZf-ir-TXF" secondAttribute="trailing" id="BuR-7b-PsU"/>
                         <constraint firstItem="CZf-ir-TXF" firstAttribute="top" secondItem="kWS-ie-oMx" secondAttribute="bottom" id="DdP-EW-VSd"/>
                         <constraint firstItem="CZf-ir-TXF" firstAttribute="top" secondItem="kWS-ie-oMx" secondAttribute="bottom" id="DdP-EW-VSd"/>
+                        <constraint firstItem="WjR-fe-3tF" firstAttribute="top" secondItem="qsN-aN-JsK" secondAttribute="top" id="Ggn-sT-Xg1"/>
+                        <constraint firstAttribute="trailing" secondItem="WjR-fe-3tF" secondAttribute="trailing" id="JLE-sc-ZEc"/>
                         <constraint firstItem="AqZ-zf-Ce4" firstAttribute="leading" secondItem="qsN-aN-JsK" secondAttribute="leading" id="OfA-aW-1la"/>
                         <constraint firstItem="AqZ-zf-Ce4" firstAttribute="leading" secondItem="qsN-aN-JsK" secondAttribute="leading" id="OfA-aW-1la"/>
+                        <constraint firstItem="WjR-fe-3tF" firstAttribute="leading" secondItem="qsN-aN-JsK" secondAttribute="leading" id="TWw-VZ-XzQ"/>
                         <constraint firstItem="kWS-ie-oMx" firstAttribute="centerX" secondItem="qsN-aN-JsK" secondAttribute="centerX" id="VX9-pY-UOR"/>
                         <constraint firstItem="kWS-ie-oMx" firstAttribute="centerX" secondItem="qsN-aN-JsK" secondAttribute="centerX" id="VX9-pY-UOR"/>
                         <constraint firstAttribute="height" constant="100" id="fHi-uF-dze"/>
                         <constraint firstAttribute="height" constant="100" id="fHi-uF-dze"/>
                         <constraint firstItem="CZf-ir-TXF" firstAttribute="leading" secondItem="qsN-aN-JsK" secondAttribute="leading" id="gbq-R9-7dB"/>
                         <constraint firstItem="CZf-ir-TXF" firstAttribute="leading" secondItem="qsN-aN-JsK" secondAttribute="leading" id="gbq-R9-7dB"/>
@@ -185,15 +211,28 @@
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <nil key="highlightedColor"/>
                             <nil key="highlightedColor"/>
                         </label>
                         </label>
+                        <button opaque="NO" tag="3" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="eyG-cn-oQe">
+                            <rect key="frame" x="0.0" y="0.0" width="108" height="100"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <userDefinedRuntimeAttributes>
+                                <userDefinedRuntimeAttribute type="color" keyPath="borderColor">
+                                    <color key="value" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                </userDefinedRuntimeAttribute>
+                            </userDefinedRuntimeAttributes>
+                        </button>
                     </subviews>
                     </subviews>
                     <color key="backgroundColor" red="0.043137254899999998" green="0.16862745100000001" blue="0.30196078430000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <color key="backgroundColor" red="0.043137254899999998" green="0.16862745100000001" blue="0.30196078430000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <constraints>
                     <constraints>
+                        <constraint firstItem="eyG-cn-oQe" firstAttribute="leading" secondItem="XWr-2B-n6N" secondAttribute="leading" id="CQR-93-m2v"/>
                         <constraint firstAttribute="trailing" secondItem="AvZ-e5-p2v" secondAttribute="trailing" id="KaA-Og-X9T"/>
                         <constraint firstAttribute="trailing" secondItem="AvZ-e5-p2v" secondAttribute="trailing" id="KaA-Og-X9T"/>
                         <constraint firstItem="qJg-Bt-e1p" firstAttribute="centerX" secondItem="XWr-2B-n6N" secondAttribute="centerX" id="NQd-1u-2DC"/>
                         <constraint firstItem="qJg-Bt-e1p" firstAttribute="centerX" secondItem="XWr-2B-n6N" secondAttribute="centerX" id="NQd-1u-2DC"/>
+                        <constraint firstItem="eyG-cn-oQe" firstAttribute="top" secondItem="XWr-2B-n6N" secondAttribute="top" id="TUk-yf-JSz"/>
                         <constraint firstAttribute="trailing" secondItem="tIH-fY-Sjl" secondAttribute="trailing" id="duP-jW-aTJ"/>
                         <constraint firstAttribute="trailing" secondItem="tIH-fY-Sjl" secondAttribute="trailing" id="duP-jW-aTJ"/>
+                        <constraint firstAttribute="trailing" secondItem="eyG-cn-oQe" secondAttribute="trailing" id="fO5-Cw-1ni"/>
                         <constraint firstItem="tIH-fY-Sjl" firstAttribute="leading" secondItem="XWr-2B-n6N" secondAttribute="leading" id="j4T-fd-Osw"/>
                         <constraint firstItem="tIH-fY-Sjl" firstAttribute="leading" secondItem="XWr-2B-n6N" secondAttribute="leading" id="j4T-fd-Osw"/>
                         <constraint firstItem="tIH-fY-Sjl" firstAttribute="top" secondItem="AvZ-e5-p2v" secondAttribute="bottom" id="pzx-Ot-k3k"/>
                         <constraint firstItem="tIH-fY-Sjl" firstAttribute="top" secondItem="AvZ-e5-p2v" secondAttribute="bottom" id="pzx-Ot-k3k"/>
                         <constraint firstAttribute="height" constant="100" id="qkC-hV-YWr"/>
                         <constraint firstAttribute="height" constant="100" id="qkC-hV-YWr"/>
+                        <constraint firstAttribute="bottom" secondItem="eyG-cn-oQe" secondAttribute="bottom" id="uiQ-dp-JIl"/>
                         <constraint firstItem="qJg-Bt-e1p" firstAttribute="top" secondItem="XWr-2B-n6N" secondAttribute="top" constant="11" id="y5p-iJ-Mtq"/>
                         <constraint firstItem="qJg-Bt-e1p" firstAttribute="top" secondItem="XWr-2B-n6N" secondAttribute="top" constant="11" id="y5p-iJ-Mtq"/>
                         <constraint firstItem="AvZ-e5-p2v" firstAttribute="leading" secondItem="XWr-2B-n6N" secondAttribute="leading" id="z4B-J4-qyT"/>
                         <constraint firstItem="AvZ-e5-p2v" firstAttribute="leading" secondItem="XWr-2B-n6N" secondAttribute="leading" id="z4B-J4-qyT"/>
                         <constraint firstItem="AvZ-e5-p2v" firstAttribute="top" secondItem="qJg-Bt-e1p" secondAttribute="bottom" id="zpk-yK-xiv"/>
                         <constraint firstItem="AvZ-e5-p2v" firstAttribute="top" secondItem="qJg-Bt-e1p" secondAttribute="bottom" id="zpk-yK-xiv"/>
@@ -259,9 +298,12 @@
                 <outlet property="lastmonth_num_label" destination="AqZ-zf-Ce4" id="41a-MM-tgy"/>
                 <outlet property="lastmonth_num_label" destination="AqZ-zf-Ce4" id="41a-MM-tgy"/>
                 <outlet property="lastyear_num_label" destination="tIH-fY-Sjl" id="LjN-Z2-fcz"/>
                 <outlet property="lastyear_num_label" destination="tIH-fY-Sjl" id="LjN-Z2-fcz"/>
                 <outlet property="student_button" destination="GHt-Dr-GJj" id="99o-AD-MyV"/>
                 <outlet property="student_button" destination="GHt-Dr-GJj" id="99o-AD-MyV"/>
+                <outlet property="thismonth_btn" destination="WjR-fe-3tF" id="uNt-xg-ZEp"/>
                 <outlet property="thismonth_num_label" destination="CZf-ir-TXF" id="t2X-9y-K1S"/>
                 <outlet property="thismonth_num_label" destination="CZf-ir-TXF" id="t2X-9y-K1S"/>
+                <outlet property="thisyear_btn" destination="eyG-cn-oQe" id="tnD-A8-wyw"/>
                 <outlet property="thisyear_num_label" destination="AvZ-e5-p2v" id="sGB-B6-Ro6"/>
                 <outlet property="thisyear_num_label" destination="AvZ-e5-p2v" id="sGB-B6-Ro6"/>
                 <outlet property="time_button" destination="05o-oH-t2c" id="pr9-Sz-xTk"/>
                 <outlet property="time_button" destination="05o-oH-t2c" id="pr9-Sz-xTk"/>
+                <outlet property="today_btn" destination="b9t-oa-34Q" id="qKg-0u-UwI"/>
                 <outlet property="today_num_label" destination="J2F-Wf-N8Q" id="POe-ZF-P7N"/>
                 <outlet property="today_num_label" destination="J2F-Wf-N8Q" id="POe-ZF-P7N"/>
                 <outlet property="yesterday_num_label" destination="9F7-sa-1Ow" id="x9J-0w-qmi"/>
                 <outlet property="yesterday_num_label" destination="9F7-sa-1Ow" id="x9J-0w-qmi"/>
             </connections>
             </connections>

+ 9 - 1
JiaPeiManage/Sources/Modulars/Statistics/Views/StatisticsPageHeaderView.swift

@@ -15,6 +15,14 @@ final class StatisticsPageHeaderView: UIView,NibLoadable {
     
     
     //预报名
     //预报名
     @IBOutlet weak var advanceday_num_label: UILabel!
     @IBOutlet weak var advanceday_num_label: UILabel!
+    //预报名
+    @IBOutlet weak var advanceday_btn: UIButton!
+    //今日报名
+    @IBOutlet weak var today_btn: UIButton!
+    //本月报名
+    @IBOutlet weak var thismonth_btn: UIButton!
+    //本年报名
+    @IBOutlet weak var thisyear_btn: UIButton!
     //今日
     //今日
     @IBOutlet weak var today_num_label: UILabel!
     @IBOutlet weak var today_num_label: UILabel!
     //昨日
     //昨日
@@ -88,7 +96,7 @@ final class StatisticsPageHeaderView: UIView,NibLoadable {
             lastyear_num_label.text = "去年  " + String(stuTotalCountDataModel.lastYear)
             lastyear_num_label.text = "去年  " + String(stuTotalCountDataModel.lastYear)
         }
         }
     }
     }
-
+    
     
     
 }
 }
 
 

+ 58 - 2
JiaPeiManage/Sources/Modulars/Statistics/Views/StatisticsPageHeaderView.xib

@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="22505" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
     <device id="retina5_9" orientation="portrait" appearance="light"/>
     <device id="retina5_9" orientation="portrait" appearance="light"/>
     <dependencies>
     <dependencies>
         <deployment identifier="iOS"/>
         <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21678"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22504"/>
         <capability name="Safe area layout guides" minToolsVersion="9.0"/>
         <capability name="Safe area layout guides" minToolsVersion="9.0"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
     </dependencies>
     </dependencies>
@@ -36,15 +36,28 @@
                             <color key="textColor" red="0.83137254901960778" green="0.8666666666666667" blue="0.90196078431372551" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <color key="textColor" red="0.83137254901960778" green="0.8666666666666667" blue="0.90196078431372551" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <nil key="highlightedColor"/>
                             <nil key="highlightedColor"/>
                         </label>
                         </label>
+                        <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="J2U-PQ-lhP">
+                            <rect key="frame" x="0.0" y="0.0" width="168" height="100"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <userDefinedRuntimeAttributes>
+                                <userDefinedRuntimeAttribute type="color" keyPath="borderColor">
+                                    <color key="value" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                </userDefinedRuntimeAttribute>
+                            </userDefinedRuntimeAttributes>
+                        </button>
                     </subviews>
                     </subviews>
                     <color key="backgroundColor" red="0.21176470588235294" green="0.19215686274509802" blue="0.1803921568627451" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <color key="backgroundColor" red="0.21176470588235294" green="0.19215686274509802" blue="0.1803921568627451" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <constraints>
                     <constraints>
                         <constraint firstItem="YQ6-YH-McP" firstAttribute="top" secondItem="aft-wT-xvr" secondAttribute="top" constant="20" id="CLG-mx-QD7"/>
                         <constraint firstItem="YQ6-YH-McP" firstAttribute="top" secondItem="aft-wT-xvr" secondAttribute="top" constant="20" id="CLG-mx-QD7"/>
                         <constraint firstAttribute="height" constant="100" id="L9s-oW-D8c"/>
                         <constraint firstAttribute="height" constant="100" id="L9s-oW-D8c"/>
                         <constraint firstItem="Uue-U7-tVN" firstAttribute="leading" secondItem="aft-wT-xvr" secondAttribute="leading" id="Re7-cG-6pY"/>
                         <constraint firstItem="Uue-U7-tVN" firstAttribute="leading" secondItem="aft-wT-xvr" secondAttribute="leading" id="Re7-cG-6pY"/>
+                        <constraint firstAttribute="trailing" secondItem="J2U-PQ-lhP" secondAttribute="trailing" id="Xwu-KY-eVS"/>
                         <constraint firstAttribute="trailing" secondItem="Uue-U7-tVN" secondAttribute="trailing" id="Z1K-Y3-y2B"/>
                         <constraint firstAttribute="trailing" secondItem="Uue-U7-tVN" secondAttribute="trailing" id="Z1K-Y3-y2B"/>
                         <constraint firstItem="YQ6-YH-McP" firstAttribute="centerX" secondItem="aft-wT-xvr" secondAttribute="centerX" id="b7h-MC-UQI"/>
                         <constraint firstItem="YQ6-YH-McP" firstAttribute="centerX" secondItem="aft-wT-xvr" secondAttribute="centerX" id="b7h-MC-UQI"/>
                         <constraint firstItem="Uue-U7-tVN" firstAttribute="top" secondItem="YQ6-YH-McP" secondAttribute="bottom" id="eMK-PW-2Wg"/>
                         <constraint firstItem="Uue-U7-tVN" firstAttribute="top" secondItem="YQ6-YH-McP" secondAttribute="bottom" id="eMK-PW-2Wg"/>
+                        <constraint firstItem="J2U-PQ-lhP" firstAttribute="leading" secondItem="aft-wT-xvr" secondAttribute="leading" id="gyZ-Vk-HXl"/>
+                        <constraint firstAttribute="bottom" secondItem="J2U-PQ-lhP" secondAttribute="bottom" id="oXG-AG-Qra"/>
+                        <constraint firstItem="J2U-PQ-lhP" firstAttribute="top" secondItem="aft-wT-xvr" secondAttribute="top" id="yfk-Pg-kLk"/>
                     </constraints>
                     </constraints>
                     <userDefinedRuntimeAttributes>
                     <userDefinedRuntimeAttributes>
                         <userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
                         <userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
@@ -83,14 +96,27 @@
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <nil key="highlightedColor"/>
                             <nil key="highlightedColor"/>
                         </label>
                         </label>
+                        <button opaque="NO" tag="1" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Gtd-6z-acZ">
+                            <rect key="frame" x="0.0" y="0.0" width="168" height="100"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <userDefinedRuntimeAttributes>
+                                <userDefinedRuntimeAttribute type="color" keyPath="borderColor">
+                                    <color key="value" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                </userDefinedRuntimeAttribute>
+                            </userDefinedRuntimeAttributes>
+                        </button>
                     </subviews>
                     </subviews>
                     <color key="backgroundColor" red="0.047058823529411764" green="0.2196078431372549" blue="0.23137254901960785" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <color key="backgroundColor" red="0.047058823529411764" green="0.2196078431372549" blue="0.23137254901960785" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <constraints>
                     <constraints>
+                        <constraint firstItem="Gtd-6z-acZ" firstAttribute="leading" secondItem="GKf-cU-ITH" secondAttribute="leading" id="DkV-kV-SVL"/>
+                        <constraint firstAttribute="bottom" secondItem="Gtd-6z-acZ" secondAttribute="bottom" id="HHA-2v-V7p"/>
                         <constraint firstItem="hl6-VS-paV" firstAttribute="top" secondItem="y0U-dj-4K9" secondAttribute="bottom" id="PmV-Zo-DY5"/>
                         <constraint firstItem="hl6-VS-paV" firstAttribute="top" secondItem="y0U-dj-4K9" secondAttribute="bottom" id="PmV-Zo-DY5"/>
                         <constraint firstAttribute="height" constant="100" id="SZn-R5-Og1"/>
                         <constraint firstAttribute="height" constant="100" id="SZn-R5-Og1"/>
                         <constraint firstItem="vv4-S5-9uc" firstAttribute="centerX" secondItem="GKf-cU-ITH" secondAttribute="centerX" id="bde-Yx-H31"/>
                         <constraint firstItem="vv4-S5-9uc" firstAttribute="centerX" secondItem="GKf-cU-ITH" secondAttribute="centerX" id="bde-Yx-H31"/>
                         <constraint firstItem="hl6-VS-paV" firstAttribute="leading" secondItem="GKf-cU-ITH" secondAttribute="leading" id="ihk-e2-gKA"/>
                         <constraint firstItem="hl6-VS-paV" firstAttribute="leading" secondItem="GKf-cU-ITH" secondAttribute="leading" id="ihk-e2-gKA"/>
+                        <constraint firstAttribute="trailing" secondItem="Gtd-6z-acZ" secondAttribute="trailing" id="jtc-iK-NRi"/>
                         <constraint firstItem="y0U-dj-4K9" firstAttribute="leading" secondItem="GKf-cU-ITH" secondAttribute="leading" id="k7n-58-f9g"/>
                         <constraint firstItem="y0U-dj-4K9" firstAttribute="leading" secondItem="GKf-cU-ITH" secondAttribute="leading" id="k7n-58-f9g"/>
+                        <constraint firstItem="Gtd-6z-acZ" firstAttribute="top" secondItem="GKf-cU-ITH" secondAttribute="top" id="mWB-2A-Aev"/>
                         <constraint firstAttribute="trailing" secondItem="hl6-VS-paV" secondAttribute="trailing" id="nKU-p0-zhG"/>
                         <constraint firstAttribute="trailing" secondItem="hl6-VS-paV" secondAttribute="trailing" id="nKU-p0-zhG"/>
                         <constraint firstItem="y0U-dj-4K9" firstAttribute="top" secondItem="vv4-S5-9uc" secondAttribute="bottom" id="qy7-af-RRs"/>
                         <constraint firstItem="y0U-dj-4K9" firstAttribute="top" secondItem="vv4-S5-9uc" secondAttribute="bottom" id="qy7-af-RRs"/>
                         <constraint firstAttribute="trailing" secondItem="y0U-dj-4K9" secondAttribute="trailing" id="u8l-C0-bbu"/>
                         <constraint firstAttribute="trailing" secondItem="y0U-dj-4K9" secondAttribute="trailing" id="u8l-C0-bbu"/>
@@ -133,6 +159,15 @@
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <nil key="highlightedColor"/>
                             <nil key="highlightedColor"/>
                         </label>
                         </label>
+                        <button opaque="NO" tag="2" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="iOu-fp-6fo">
+                            <rect key="frame" x="0.0" y="0.0" width="168" height="100"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <userDefinedRuntimeAttributes>
+                                <userDefinedRuntimeAttribute type="color" keyPath="borderColor">
+                                    <color key="value" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                </userDefinedRuntimeAttribute>
+                            </userDefinedRuntimeAttributes>
+                        </button>
                     </subviews>
                     </subviews>
                     <color key="backgroundColor" red="0.20392156862745098" green="0.20392156862745098" blue="0.14509803921568626" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <color key="backgroundColor" red="0.20392156862745098" green="0.20392156862745098" blue="0.14509803921568626" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <constraints>
                     <constraints>
@@ -142,7 +177,11 @@
                         <constraint firstItem="Sq4-g5-kNa" firstAttribute="top" secondItem="3ul-T9-cgr" secondAttribute="top" constant="11" id="Li2-DO-0uB"/>
                         <constraint firstItem="Sq4-g5-kNa" firstAttribute="top" secondItem="3ul-T9-cgr" secondAttribute="top" constant="11" id="Li2-DO-0uB"/>
                         <constraint firstItem="qTY-Ph-Ewx" firstAttribute="top" secondItem="Sq4-g5-kNa" secondAttribute="bottom" id="VfA-vX-4gi"/>
                         <constraint firstItem="qTY-Ph-Ewx" firstAttribute="top" secondItem="Sq4-g5-kNa" secondAttribute="bottom" id="VfA-vX-4gi"/>
                         <constraint firstItem="qTY-Ph-Ewx" firstAttribute="leading" secondItem="3ul-T9-cgr" secondAttribute="leading" id="XBO-1c-dop"/>
                         <constraint firstItem="qTY-Ph-Ewx" firstAttribute="leading" secondItem="3ul-T9-cgr" secondAttribute="leading" id="XBO-1c-dop"/>
+                        <constraint firstAttribute="trailing" secondItem="iOu-fp-6fo" secondAttribute="trailing" id="aqB-q1-sLl"/>
                         <constraint firstAttribute="height" constant="100" id="d0g-NW-ZcM"/>
                         <constraint firstAttribute="height" constant="100" id="d0g-NW-ZcM"/>
+                        <constraint firstItem="iOu-fp-6fo" firstAttribute="leading" secondItem="3ul-T9-cgr" secondAttribute="leading" id="fcm-XH-O8Q"/>
+                        <constraint firstAttribute="bottom" secondItem="iOu-fp-6fo" secondAttribute="bottom" id="nRi-Zc-viu"/>
+                        <constraint firstItem="iOu-fp-6fo" firstAttribute="top" secondItem="3ul-T9-cgr" secondAttribute="top" id="pEM-zR-aBJ"/>
                         <constraint firstItem="2On-dl-pRp" firstAttribute="top" secondItem="qTY-Ph-Ewx" secondAttribute="bottom" id="s4z-0n-b6z"/>
                         <constraint firstItem="2On-dl-pRp" firstAttribute="top" secondItem="qTY-Ph-Ewx" secondAttribute="bottom" id="s4z-0n-b6z"/>
                         <constraint firstAttribute="trailing" secondItem="2On-dl-pRp" secondAttribute="trailing" id="sRe-jf-dJv"/>
                         <constraint firstAttribute="trailing" secondItem="2On-dl-pRp" secondAttribute="trailing" id="sRe-jf-dJv"/>
                     </constraints>
                     </constraints>
@@ -183,12 +222,25 @@
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <color key="textColor" red="0.53725490200000003" green="0.56862745100000001" blue="0.59999999999999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                             <nil key="highlightedColor"/>
                             <nil key="highlightedColor"/>
                         </label>
                         </label>
+                        <button opaque="NO" tag="3" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="kab-kt-FZ9">
+                            <rect key="frame" x="0.0" y="0.0" width="168" height="100"/>
+                            <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
+                            <userDefinedRuntimeAttributes>
+                                <userDefinedRuntimeAttribute type="color" keyPath="borderColor">
+                                    <color key="value" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                </userDefinedRuntimeAttribute>
+                            </userDefinedRuntimeAttributes>
+                        </button>
                     </subviews>
                     </subviews>
                     <color key="backgroundColor" red="0.043137254901960784" green="0.16862745098039217" blue="0.30196078431372547" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <color key="backgroundColor" red="0.043137254901960784" green="0.16862745098039217" blue="0.30196078431372547" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     <constraints>
                     <constraints>
                         <constraint firstAttribute="height" constant="100" id="7Lc-Qg-bal"/>
                         <constraint firstAttribute="height" constant="100" id="7Lc-Qg-bal"/>
+                        <constraint firstAttribute="bottom" secondItem="kab-kt-FZ9" secondAttribute="bottom" id="7wp-pw-1Bg"/>
+                        <constraint firstItem="kab-kt-FZ9" firstAttribute="leading" secondItem="Ix6-7h-s2x" secondAttribute="leading" id="GTb-Pu-c7r"/>
+                        <constraint firstAttribute="trailing" secondItem="kab-kt-FZ9" secondAttribute="trailing" id="Id5-q8-Ed9"/>
                         <constraint firstItem="zlG-tz-bh1" firstAttribute="centerX" secondItem="Ix6-7h-s2x" secondAttribute="centerX" id="Q1i-nB-jr3"/>
                         <constraint firstItem="zlG-tz-bh1" firstAttribute="centerX" secondItem="Ix6-7h-s2x" secondAttribute="centerX" id="Q1i-nB-jr3"/>
                         <constraint firstItem="Bfy-od-tkR" firstAttribute="leading" secondItem="Ix6-7h-s2x" secondAttribute="leading" id="RaH-ci-4zj"/>
                         <constraint firstItem="Bfy-od-tkR" firstAttribute="leading" secondItem="Ix6-7h-s2x" secondAttribute="leading" id="RaH-ci-4zj"/>
+                        <constraint firstItem="kab-kt-FZ9" firstAttribute="top" secondItem="Ix6-7h-s2x" secondAttribute="top" id="WfE-uY-8UR"/>
                         <constraint firstAttribute="trailing" secondItem="jMJ-CH-Lpe" secondAttribute="trailing" id="WxD-Lf-2bf"/>
                         <constraint firstAttribute="trailing" secondItem="jMJ-CH-Lpe" secondAttribute="trailing" id="WxD-Lf-2bf"/>
                         <constraint firstItem="zlG-tz-bh1" firstAttribute="top" secondItem="Ix6-7h-s2x" secondAttribute="top" constant="11" id="Zh2-IX-a86"/>
                         <constraint firstItem="zlG-tz-bh1" firstAttribute="top" secondItem="Ix6-7h-s2x" secondAttribute="top" constant="11" id="Zh2-IX-a86"/>
                         <constraint firstAttribute="trailing" secondItem="Bfy-od-tkR" secondAttribute="trailing" id="cg0-QR-ULk"/>
                         <constraint firstAttribute="trailing" secondItem="Bfy-od-tkR" secondAttribute="trailing" id="cg0-QR-ULk"/>
@@ -297,15 +349,19 @@
                 <userDefinedRuntimeAttribute type="boolean" keyPath="aLRatio" value="YES"/>
                 <userDefinedRuntimeAttribute type="boolean" keyPath="aLRatio" value="YES"/>
             </userDefinedRuntimeAttributes>
             </userDefinedRuntimeAttributes>
             <connections>
             <connections>
+                <outlet property="advanceday_btn" destination="J2U-PQ-lhP" id="ZwB-mc-fYJ"/>
                 <outlet property="advanceday_num_label" destination="Uue-U7-tVN" id="eku-jh-yHm"/>
                 <outlet property="advanceday_num_label" destination="Uue-U7-tVN" id="eku-jh-yHm"/>
                 <outlet property="date_section_button" destination="LKE-qJ-bbU" id="SB0-Ej-kzG"/>
                 <outlet property="date_section_button" destination="LKE-qJ-bbU" id="SB0-Ej-kzG"/>
                 <outlet property="items_date_segmented" destination="VMX-s0-wJI" id="7ws-br-KwA"/>
                 <outlet property="items_date_segmented" destination="VMX-s0-wJI" id="7ws-br-KwA"/>
                 <outlet property="lastmonth_num_label" destination="2On-dl-pRp" id="kAc-cv-YFh"/>
                 <outlet property="lastmonth_num_label" destination="2On-dl-pRp" id="kAc-cv-YFh"/>
                 <outlet property="lastyear_num_label" destination="jMJ-CH-Lpe" id="Wia-K1-kl9"/>
                 <outlet property="lastyear_num_label" destination="jMJ-CH-Lpe" id="Wia-K1-kl9"/>
                 <outlet property="student_button" destination="ANm-wP-nuH" id="uuI-RX-EfN"/>
                 <outlet property="student_button" destination="ANm-wP-nuH" id="uuI-RX-EfN"/>
+                <outlet property="thismonth_btn" destination="iOu-fp-6fo" id="EpI-eK-vri"/>
                 <outlet property="thismonth_num_label" destination="qTY-Ph-Ewx" id="4TL-s4-BET"/>
                 <outlet property="thismonth_num_label" destination="qTY-Ph-Ewx" id="4TL-s4-BET"/>
+                <outlet property="thisyear_btn" destination="kab-kt-FZ9" id="lg7-3S-YiG"/>
                 <outlet property="thisyear_num_label" destination="Bfy-od-tkR" id="KR2-ng-1jO"/>
                 <outlet property="thisyear_num_label" destination="Bfy-od-tkR" id="KR2-ng-1jO"/>
                 <outlet property="time_button" destination="WPh-7j-9f7" id="UhX-fi-nWI"/>
                 <outlet property="time_button" destination="WPh-7j-9f7" id="UhX-fi-nWI"/>
+                <outlet property="today_btn" destination="Gtd-6z-acZ" id="VaP-ZS-4Ew"/>
                 <outlet property="today_num_label" destination="y0U-dj-4K9" id="ezX-4A-dDJ"/>
                 <outlet property="today_num_label" destination="y0U-dj-4K9" id="ezX-4A-dDJ"/>
                 <outlet property="yesterday_num_label" destination="hl6-VS-paV" id="paB-U7-LdU"/>
                 <outlet property="yesterday_num_label" destination="hl6-VS-paV" id="paB-U7-LdU"/>
             </connections>
             </connections>

+ 4 - 2
JiaPeiManage/Sources/Modulars/学员/ViewModel/MeTraineeSubjectViewModel.swift

@@ -191,7 +191,7 @@ class MeTraineeSubjectViewModel: NSObject {
         if (self.type == .advancet){ //预报名
         if (self.type == .advancet){ //预报名
             if state == "0" {
             if state == "0" {
                 if (schoolId>0){//在校
                 if (schoolId>0){//在校
-                    self.cocahService.mycoachTempListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: "")
+                    self.cocahService.coachTempListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: "")
                         .subscribe(onSuccess: {[unowned self] traineeDataModel in
                         .subscribe(onSuccess: {[unowned self] traineeDataModel in
                             self.traineeDataModel = traineeDataModel
                             self.traineeDataModel = traineeDataModel
                             if(traineeDataModel.rows!.count>0){
                             if(traineeDataModel.rows!.count>0){
@@ -205,8 +205,9 @@ class MeTraineeSubjectViewModel: NSObject {
                             vc.stopRefresh()
                             vc.stopRefresh()
                         })
                         })
                         .disposed(by: vc.disposeBag)
                         .disposed(by: vc.disposeBag)
+                    
                 }else {//我的
                 }else {//我的
-                    self.cocahService.coachTempListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: "")
+                    self.cocahService.mycoachTempListRequest(city: LocalManager.userInfo.city!, appCoachId: "", coachId: coachId, field: "", pageNum: page, pageSize: pageSize, schoolId: schoolId, state: "")
                         .subscribe(onSuccess: {[unowned self] traineeDataModel in
                         .subscribe(onSuccess: {[unowned self] traineeDataModel in
                             self.traineeDataModel = traineeDataModel
                             self.traineeDataModel = traineeDataModel
                             if(traineeDataModel.rows!.count>0){
                             if(traineeDataModel.rows!.count>0){
@@ -220,6 +221,7 @@ class MeTraineeSubjectViewModel: NSObject {
                             vc.stopRefresh()
                             vc.stopRefresh()
                         })
                         })
                         .disposed(by: vc.disposeBag)
                         .disposed(by: vc.disposeBag)
+                    
                 }
                 }
                 
                 
             }else {
             }else {

+ 34 - 2
JiaPeiManage/Sources/Services/CoachAPI.swift

@@ -16,6 +16,8 @@ enum CoachAPI {
     case coachQrInfo(id:String ,city:String)
     case coachQrInfo(id:String ,city:String)
     //获取教练的学员
     //获取教练的学员
     case coachInfoList(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String )
     case coachInfoList(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String )
+    case coachInfoListDate(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String ,startDate:String ,endDate:String )
+    
     //获取教练的学员-我的学员
     //获取教练的学员-我的学员
     case coachInfoMyList(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String )
     case coachInfoMyList(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String )
     //获取教练的学员-针对搜索专用-全局
     //获取教练的学员-针对搜索专用-全局
@@ -26,6 +28,8 @@ enum CoachAPI {
     case yallSchoolStudentInfoList(city:String,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int)
     case yallSchoolStudentInfoList(city:String,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int)
     //获取教练预报名的学员
     //获取教练预报名的学员
     case coachTempList(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String )
     case coachTempList(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String )
+    case coachTempListDate(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String ,startDate:String ,endDate:String )
+    
     //获取我的教练预报名的学员
     //获取我的教练预报名的学员
     case mycoachTempList(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String )
     case mycoachTempList(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String )
     //通过id获取学员详细
     //通过id获取学员详细
@@ -62,6 +66,8 @@ extension CoachAPI: TargetType {
             return "/jsjp-admin/open-api/tms/coachInfo/getCoachQrInfo"
             return "/jsjp-admin/open-api/tms/coachInfo/getCoachQrInfo"
         case .coachInfoList(_,_,_,_,_,_,_,_):
         case .coachInfoList(_,_,_,_,_,_,_,_):
             return "/jsjp-admin/open-api/tms/coachInfo/list"
             return "/jsjp-admin/open-api/tms/coachInfo/list"
+        case .coachInfoListDate(_,_,_,_,_,_,_,_,_,_):
+            return "/jsjp-admin/open-api/tms/coachInfo/list"
         case .coachInfoMyList(_,_,_,_,_,_,_,_):
         case .coachInfoMyList(_,_,_,_,_,_,_,_):
             return "/jsjp-admin/open-api/tms/coachInfo/myList"
             return "/jsjp-admin/open-api/tms/coachInfo/myList"
         case .allStudentInfoList(_, _, _, _, _, _):
         case .allStudentInfoList(_, _, _, _, _, _):
@@ -72,6 +78,8 @@ extension CoachAPI: TargetType {
             return "/jsjp-admin/open-api/tms/coachInfo/allSchoolStudentInfoList"
             return "/jsjp-admin/open-api/tms/coachInfo/allSchoolStudentInfoList"
         case .coachTempList(_,_,_,_,_,_,_,_):
         case .coachTempList(_,_,_,_,_,_,_,_):
             return "/jsjp-admin/open-api/tms/coachInfo/studentTempList"
             return "/jsjp-admin/open-api/tms/coachInfo/studentTempList"
+        case .coachTempListDate(_,_,_,_,_,_,_,_,_,_):
+            return "/jsjp-admin/open-api/tms/coachInfo/studentTempList"
         case .mycoachTempList(_,_,_,_,_,_,_,_):
         case .mycoachTempList(_,_,_,_,_,_,_,_):
             return "/jsjp-admin/open-api/tms/coachInfo/myStudentTempList"
             return "/jsjp-admin/open-api/tms/coachInfo/myStudentTempList"
         case .studentInfoApplyById(_,_,_):
         case .studentInfoApplyById(_,_,_):
@@ -93,7 +101,7 @@ extension CoachAPI: TargetType {
     
     
     var method: Moya.Method {
     var method: Moya.Method {
         switch self {
         switch self {
-        case .coachInfo,.coachQrInfo,.coachInfoList,.coachTempList,
+        case .coachInfo,.coachQrInfo,.coachInfoList,.coachTempList,.coachTempListDate,
                 .studentInfoById,.stuScoreByOutId,.stuTmsLogFaceListByStuId,
                 .studentInfoById,.stuScoreByOutId,.stuTmsLogFaceListByStuId,
                 .studentInfoTempById:
                 .studentInfoTempById:
             return .get
             return .get
@@ -108,7 +116,7 @@ extension CoachAPI: TargetType {
     
     
     var task: Moya.Task {
     var task: Moya.Task {
         switch self {
         switch self {
-        case .coachInfo(_,_),.coachQrInfo(_,_),.coachInfoList(_,_,_,_,_,_,_,_),.coachInfoMyList(_,_,_,_,_,_,_,_),.coachTempList(_,_,_,_,_,_,_,_),.studentInfoById(_,_),.studentInfoApplyById(_,_,_)
+        case .coachInfo(_,_),.coachQrInfo(_,_),.coachInfoList(_,_,_,_,_,_,_,_),.coachInfoListDate(_,_,_,_,_,_,_,_,_,_),.coachInfoMyList(_,_,_,_,_,_,_,_),.coachTempList(_,_,_,_,_,_,_,_),.coachTempListDate(_,_,_,_,_,_,_,_,_,_),.studentInfoById(_,_),.studentInfoApplyById(_,_,_)
             ,.stuScoreByOutId(_,_,_),.stuTmsSignListByStuId(_,_,_,_),.stuTmsLogFaceListByStuId(_,_,_,_),
             ,.stuScoreByOutId(_,_,_),.stuTmsSignListByStuId(_,_,_,_),.stuTmsLogFaceListByStuId(_,_,_,_),
                 .allStudentInfoList(_, _, _, _, _, _),.yallStudentInfoList(_, _, _, _, _, _),.yallSchoolStudentInfoList(_, _, _, _, _, _),.mycoachTempList(_,_,_,_,_,_,_,_),
                 .allStudentInfoList(_, _, _, _, _, _),.yallStudentInfoList(_, _, _, _, _, _),.yallSchoolStudentInfoList(_, _, _, _, _, _),.mycoachTempList(_,_,_,_,_,_,_,_),
                 .studentInfoTempById(_,_):
                 .studentInfoTempById(_,_):
@@ -153,6 +161,18 @@ extension CoachAPI: TargetType {
                     "pageSize": pageSize,
                     "pageSize": pageSize,
                     "schoolId": schoolId==0 ?"":"\(schoolId)",
                     "schoolId": schoolId==0 ?"":"\(schoolId)",
                     "state": state,]
                     "state": state,]
+        case let .coachTempListDate(city,appCoachId ,coachId ,field ,pageNum ,pageSize ,schoolId ,state, startDate ,endDate):
+            return ["city": city,
+                    "appCoachId": appCoachId,
+                    "coachId": coachId,
+                    "field": field,
+                    "pageNum": pageNum,
+                    "pageSize": pageSize,
+                    "schoolId": schoolId==0 ?"":"\(schoolId)",
+                    "state": state,
+                    "startDate": startDate,
+                    "endDate": endDate,
+                    ]
         case let .mycoachTempList(city,appCoachId ,coachId ,field ,pageNum ,pageSize ,schoolId ,state):
         case let .mycoachTempList(city,appCoachId ,coachId ,field ,pageNum ,pageSize ,schoolId ,state):
             return ["city": city,
             return ["city": city,
                     "appCoachId": appCoachId,
                     "appCoachId": appCoachId,
@@ -180,6 +200,18 @@ extension CoachAPI: TargetType {
                     "pageSize": pageSize,
                     "pageSize": pageSize,
                     "schoolId": schoolId==0 ?"":"\(schoolId)",
                     "schoolId": schoolId==0 ?"":"\(schoolId)",
                     "state": state,]
                     "state": state,]
+        case let .coachInfoListDate(city,appCoachId ,coachId ,field ,pageNum ,pageSize ,schoolId ,state, startDate,endDate):
+            return ["city": city,
+                    "appCoachId": appCoachId,
+                    "coachId": coachId,
+                    "field": field,
+                    "pageNum": pageNum,
+                    "pageSize": pageSize,
+                    "schoolId": schoolId==0 ?"":"\(schoolId)",
+                    "state": state,
+                    "startDate": startDate,
+                    "endDate": endDate,
+                    ]
         case let .allStudentInfoList(city, coachId, field, pageNum, pageSize, schoolId):
         case let .allStudentInfoList(city, coachId, field, pageNum, pageSize, schoolId):
             return ["city": city,
             return ["city": city,
                     "coachId": coachId,
                     "coachId": coachId,

+ 12 - 2
JiaPeiManage/Sources/Services/CoachService.swift

@@ -16,6 +16,7 @@ protocol CoachServiceType {
     func coachQrInfoRequest(id:String ,city:String) -> Single<CoachJsonInfo>
     func coachQrInfoRequest(id:String ,city:String) -> Single<CoachJsonInfo>
     //获取我的学员信息list
     //获取我的学员信息list
     func coachInfoListRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String) -> Single<TraineeDataModel>
     func coachInfoListRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String) -> Single<TraineeDataModel>
+    func coachInfoListDateRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String ,startDate:String ,endDate:String) -> Single<TraineeDataModel>
     func coachInfoMyListRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String) -> Single<TraineeDataModel>
     func coachInfoMyListRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String) -> Single<TraineeDataModel>
     
     
     //获取全局学员信息list
     //获取全局学员信息list
@@ -28,6 +29,7 @@ protocol CoachServiceType {
     func mycoachTempListRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String) -> Single<TraineeDataModel>
     func mycoachTempListRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String) -> Single<TraineeDataModel>
     //获取在校预报名学员信息list
     //获取在校预报名学员信息list
     func coachTempListRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String) -> Single<TraineeDataModel>
     func coachTempListRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String) -> Single<TraineeDataModel>
+    func coachTempListDateRequest(city:String,appCoachId:String ,coachId:String ,field:String ,pageNum:Int ,pageSize:Int ,schoolId:Int ,state:String, startDate:String ,endDate:String) -> Single<TraineeDataModel>
     //通过id获取学员详细
     //通过id获取学员详细
     func studentInfoByIdRequest(city:String,id:Int) -> Single<TraineeInfoModel>
     func studentInfoByIdRequest(city:String,id:Int) -> Single<TraineeInfoModel>
     //通过id获temp取学员详细
     //通过id获temp取学员详细
@@ -45,7 +47,7 @@ protocol CoachServiceType {
 
 
 final class CoachService: CoachServiceType {
 final class CoachService: CoachServiceType {
 
 
-    
+
     private let networking : CoachNetworking
     private let networking : CoachNetworking
     
     
     init(networking: CoachNetworking) {
     init(networking: CoachNetworking) {
@@ -67,6 +69,11 @@ final class CoachService: CoachServiceType {
         return networking.request(api).map(TraineeDataModel.self,isModel: true)
         return networking.request(api).map(TraineeDataModel.self,isModel: true)
     }
     }
     
     
+    func coachInfoListDateRequest(city: String, appCoachId: String, coachId: String, field: String, pageNum: Int, pageSize: Int, schoolId: Int, state: String, startDate: String, endDate: String) -> RxSwift.Single<TraineeDataModel> {
+        let api = CoachAPI.coachInfoListDate(city: city, appCoachId: appCoachId, coachId: coachId, field: field, pageNum: pageNum, pageSize: pageSize, schoolId: schoolId, state: state, startDate: startDate, endDate: endDate)
+        return networking.request(api).map(TraineeDataModel.self,isModel: true)
+    }
+    
     func coachInfoMyListRequest(city: String, appCoachId: String, coachId: String, field: String, pageNum: Int, pageSize: Int, schoolId: Int, state: String) -> RxSwift.Single<TraineeDataModel> {
     func coachInfoMyListRequest(city: String, appCoachId: String, coachId: String, field: String, pageNum: Int, pageSize: Int, schoolId: Int, state: String) -> RxSwift.Single<TraineeDataModel> {
         let api = CoachAPI.coachInfoMyList(city: city, appCoachId: appCoachId, coachId: coachId, field: field, pageNum: pageNum, pageSize: pageSize, schoolId: schoolId, state: state)
         let api = CoachAPI.coachInfoMyList(city: city, appCoachId: appCoachId, coachId: coachId, field: field, pageNum: pageNum, pageSize: pageSize, schoolId: schoolId, state: state)
         return networking.request(api).map(TraineeDataModel.self,isModel: true)
         return networking.request(api).map(TraineeDataModel.self,isModel: true)
@@ -90,7 +97,10 @@ final class CoachService: CoachServiceType {
         let api = CoachAPI.coachTempList(city: city, appCoachId: appCoachId, coachId: coachId, field: field, pageNum: pageNum, pageSize: pageSize, schoolId: schoolId, state: state)
         let api = CoachAPI.coachTempList(city: city, appCoachId: appCoachId, coachId: coachId, field: field, pageNum: pageNum, pageSize: pageSize, schoolId: schoolId, state: state)
         return networking.request(api).map(TraineeDataModel.self,isModel: true)
         return networking.request(api).map(TraineeDataModel.self,isModel: true)
     }
     }
-    
+    func coachTempListDateRequest(city: String, appCoachId: String, coachId: String, field: String, pageNum: Int, pageSize: Int, schoolId: Int, state: String, startDate: String, endDate: String) -> RxSwift.Single<TraineeDataModel> {
+        let api = CoachAPI.coachTempListDate(city: city, appCoachId: appCoachId, coachId: coachId, field: field, pageNum: pageNum, pageSize: pageSize, schoolId: schoolId, state: state, startDate: startDate, endDate: endDate)
+        return networking.request(api).map(TraineeDataModel.self,isModel: true)
+    }
     func mycoachTempListRequest(city: String, appCoachId: String, coachId: String, field: String, pageNum: Int, pageSize: Int, schoolId: Int, state: String) -> RxSwift.Single<TraineeDataModel> {
     func mycoachTempListRequest(city: String, appCoachId: String, coachId: String, field: String, pageNum: Int, pageSize: Int, schoolId: Int, state: String) -> RxSwift.Single<TraineeDataModel> {
         let api = CoachAPI.mycoachTempList(city: city, appCoachId: appCoachId, coachId: coachId, field: field, pageNum: pageNum, pageSize: pageSize, schoolId: schoolId, state: state)
         let api = CoachAPI.mycoachTempList(city: city, appCoachId: appCoachId, coachId: coachId, field: field, pageNum: pageNum, pageSize: pageSize, schoolId: schoolId, state: state)
         return networking.request(api).map(TraineeDataModel.self,isModel: true)
         return networking.request(api).map(TraineeDataModel.self,isModel: true)

+ 3 - 0
JiaPeiManage/Sources/Utils/NYSwRouter.swift

@@ -22,6 +22,7 @@ enum NYSwPushType {
     case trainee_list_school
     case trainee_list_school
     case trainee_statistics
     case trainee_statistics
     case trainee_statistics_official
     case trainee_statistics_official
+    case trainee_statistics_stulist
     case coach_qrcode
     case coach_qrcode
     case coach_qrcode_download
     case coach_qrcode_download
     case login_biand_wx
     case login_biand_wx
@@ -63,6 +64,8 @@ extension NYSwPushType {
             return "JiaPeiManage://me/trainee/statistics"
             return "JiaPeiManage://me/trainee/statistics"
         case .trainee_statistics_official:
         case .trainee_statistics_official:
             return "JiaPeiManage://me/trainee/statistics/official"
             return "JiaPeiManage://me/trainee/statistics/official"
+        case .trainee_statistics_stulist:
+            return "JiaPeiManage://me/trainee/statistics/stulist"
         case .coach_qrcode:
         case .coach_qrcode:
             return "JiaPeiManage://me/coach/qrcode"
             return "JiaPeiManage://me/coach/qrcode"
         case .coach_qrcode_download:
         case .coach_qrcode_download:

+ 10 - 0
JiaPeiManage/Sources/Utils/URLNavigationMap.swift

@@ -55,6 +55,16 @@ final class URLNavigationMap {
             return statisticsPageController
             return statisticsPageController
         }
         }
         
         
+        navigator.register(NYSwPushType.trainee_statistics_stulist.path) { (url, values, context) -> UIViewController? in
+            guard let context = context as? [Any]
+            else { return nil }
+            let type = context[0] as! Int
+            let title = String(describing: context[1])
+            let dateTime_str = String(describing: context[2])
+            let statisticsStuListPageController = StatisticsStuListPageController(type: type , title: title, schoolId: LocalManager.userInfo.schoolId,dateTime: dateTime_str)
+            return statisticsStuListPageController
+        }
+        
         navigator.register(NYSwPushType.trainee_list.path) { (url, values, context) -> UIViewController? in
         navigator.register(NYSwPushType.trainee_list.path) { (url, values, context) -> UIViewController? in
             
             
             if LocalManager.userInfo.cityPower == "1" && !LocalManager.isCheckAccount() {
             if LocalManager.userInfo.cityPower == "1" && !LocalManager.isCheckAccount() {