123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899 |
- //
- // ExamArrangeViewController.m
- // LN_School
- //
- // Created by 张嵘 on 2019/7/29.
- // Copyright © 2019 Danson. All rights reserved.
- //
- #import "ExamArrangeViewController.h"
- #import "ExamArrangeViewModel.h"
- @interface ExamArrangeViewController ()
- @property (nonatomic, readwrite, strong) ExamArrangeViewModel *examArrangeViewModel;
- @end
- @implementation ExamArrangeViewController
- #pragma mark - Life Cycle
- - (void)viewDidLoad {
- [super viewDidLoad];
- [self initUI];
- }
- #pragma mark - Private Functions
- - (void)initUI {
- self.title = @"考试安排";
- self.view.backgroundColor = KBackGroundColor;
- [self goBackByNavigation];
-
- [self.multipleSc mas_makeConstraints:^(MASConstraintMaker *make) {
- make.left.mas_equalTo(self.view.hd_mas_left);
- make.right.mas_equalTo(self.view.hd_mas_right);
- make.bottom.mas_equalTo(0);
- make.top.mas_equalTo(self.view.hd_mas_top);
- }];
-
- self.multipleSc.mainCollecitonV.backgroundColor = RQBackGroundColor;
-
- /// 初始化数据
- __weak typeof(self) weakS = self;
- [self.multipleSc configWithConfiger:^(HDMultipleScrollListConfiger * _Nonnull configer) {
- [weakS setWith:configer];
- }];
-
- /// 点击回调
- [self.multipleSc.mainCollecitonV hd_setAllEventCallBack:^(id backModel, HDCallBackType type) {
- if (type == HDCellCallBack) {
- [weakS clickCell:backModel];
- }else if (type == HDSectionHeaderCallBack){
- [weakS clickHeader:backModel];
- }
- }];
-
- /// 标签个性化设置
- [self jxCustomSetting];
- }
- /// 标签个性化设置
- - (void)jxCustomSetting {
- self.multipleSc.jxTitle.titleSelectedColor = RQSubColor;
- self.multipleSc.jxTitle.titleColorGradientEnabled = YES;
- self.multipleSc.jxTitle.titleFont = [UIFont systemFontOfSize:17];
- self.multipleSc.jxLineView.indicatorLineViewColor = RQSubColor;
- self.multipleSc.jxLineView.lineStyle = JXCategoryIndicatorLineStyle_IQIYI;
- self.multipleSc.jxLineView.indicatorWidth = kScreenWidth / 10.0;
- self.multipleSc.jxLineView.indicatorHeight = 3;
- self.multipleSc.jxLineView.indicatorCornerRadius = 3;
- }
- /// 初始化数据
- - (void)setWith:(HDMultipleScrollListConfiger*)configer {
- configer.isHeaderNeedStop = self.examArrangeViewModel.headerStop;
- configer.titleContentSize = self.examArrangeViewModel.titleSize;
- configer.controllers = self.examArrangeViewModel.controllers;
- configer.titles = self.examArrangeViewModel.titles;
- configer.diyHeaderClsStr = @"ExamArrangeSearchHeader";
- }
- - (void)clickCell:(HDCellModel*)cellM {
- NSLog(@"点击了%zd--%zd cell",cellM.indexP.section,cellM.indexP.item);
-
- }
- - (void)clickHeader:(HDSectionModel*)secM {
- NSLog(@"点击了段头");
- }
- #pragma mark - Lazy Load
- - (ExamArrangeViewModel *)examArrangeViewModel {
- if (!_examArrangeViewModel) {
- _examArrangeViewModel = [[ExamArrangeViewModel alloc] init];
- }
- return _examArrangeViewModel;
- }
- @end
|