Commit 4fabf3528980763fef8c2c6d83b5d633b73198aa

Authored by liushiyu
1 parent 8dddf2b3

0.0.7

CNLiveCommuntyModule.podspec
@@ -8,7 +8,7 @@ @@ -8,7 +8,7 @@
8 8
9 Pod::Spec.new do |s| 9 Pod::Spec.new do |s|
10 s.name = 'CNLiveCommuntyModule' 10 s.name = 'CNLiveCommuntyModule'
11 - s.version = '0.0.6' 11 + s.version = '0.0.7'
12 s.summary = 'A short description of CNLiveCommuntyModule.' 12 s.summary = 'A short description of CNLiveCommuntyModule.'
13 13
14 # This description is used to generate tags and improve search results. 14 # This description is used to generate tags and improve search results.
CNLiveCommuntyModule/Classes/Model/CNLiveCommuntyHomeModel.m
@@ -28,14 +28,14 @@ MJCodingImplementation @@ -28,14 +28,14 @@ MJCodingImplementation
28 [self.titles addObject:[subDict stringValueForKey:@"columnName" default:@""]]; 28 [self.titles addObject:[subDict stringValueForKey:@"columnName" default:@""]];
29 } 29 }
30 } 30 }
31 -#ifdef DEBUG  
32 - if ([property.name isEqualToString:@"cmsPageUrl"]) {  
33 - if (oldValue == nil || [oldValue isKindOfClass:NSNull.class]) {  
34 - oldValue = @"https://www.baidu.com";  
35 - }  
36 - }  
37 -#else  
38 -#endif 31 +//#ifdef DEBUG
  32 +// if ([property.name isEqualToString:@"cmsPageUrl"]) {
  33 +// if (oldValue == nil || [oldValue isKindOfClass:NSNull.class]) {
  34 +// oldValue = @"https://www.baidu.com";
  35 +// }
  36 +// }
  37 +//#else
  38 +//#endif
39 return oldValue; 39 return oldValue;
40 } 40 }
41 @end 41 @end
@@ -50,14 +50,14 @@ MJCodingImplementation @@ -50,14 +50,14 @@ MJCodingImplementation
50 } 50 }
51 - (id)mj_newValueFromOldValue:(id)oldValue property:(MJProperty *)property 51 - (id)mj_newValueFromOldValue:(id)oldValue property:(MJProperty *)property
52 { 52 {
53 -#ifdef DEBUG  
54 - if ([property.name isEqualToString:@"cmsPageUrl"]) {  
55 - if (oldValue == nil || [oldValue isKindOfClass:NSNull.class]) {  
56 - oldValue = @"https://www.baidu.com";  
57 - }  
58 - }  
59 -#else  
60 -#endif 53 +//#ifdef DEBUG
  54 +// if ([property.name isEqualToString:@"cmsPageUrl"]) {
  55 +// if (oldValue == nil || [oldValue isKindOfClass:NSNull.class]) {
  56 +// oldValue = @"https://www.baidu.com";
  57 +// }
  58 +// }
  59 +//#else
  60 +//#endif
61 return oldValue; 61 return oldValue;
62 } 62 }
63 @end 63 @end
CNLiveCommuntyModule/Classes/ViewController/CNLiveCommuntActiviViewController.m
@@ -41,12 +41,12 @@ @@ -41,12 +41,12 @@
41 } 41 }
42 } 42 }
43 } 43 }
44 -  
45 - (void)viewDidLoad { 44 - (void)viewDidLoad {
46 [super viewDidLoad]; 45 [super viewDidLoad];
47 // Do any additional setup after loading the view. 46 // Do any additional setup after loading the view.
48 self.view.backgroundColor = [UIColor whiteColor]; 47 self.view.backgroundColor = [UIColor whiteColor];
49 UIViewController *subVC = [[CNLiveCommuntyModule shareInstance].protocol pushWebViewWithMainProjectWithWebUrl:self.webUrl type:self.type]; 48 UIViewController *subVC = [[CNLiveCommuntyModule shareInstance].protocol pushWebViewWithMainProjectWithWebUrl:self.webUrl type:self.type];
  49 + subVC.view.backgroundColor = [UIColor whiteColor];
50 [self.view addSubview:subVC.view]; 50 [self.view addSubview:subVC.view];
51 [self addChildViewController:subVC]; 51 [self addChildViewController:subVC];
52 [subVC didMoveToParentViewController:self]; 52 [subVC didMoveToParentViewController:self];
CNLiveCommuntyModule/Classes/ViewController/CNLiveCommuntServiceViewController.m
@@ -65,6 +65,7 @@ @@ -65,6 +65,7 @@
65 NSString * cmsPageUrl = self.homeModel?self.homeModel.cmsPageUrl:self.homeSubModel.cmsPageUrl; 65 NSString * cmsPageUrl = self.homeModel?self.homeModel.cmsPageUrl:self.homeSubModel.cmsPageUrl;
66 66
67 UIViewController * subVC = [[CNLiveCommuntyModule shareInstance].protocol pushLiveViewWithMainProjectWithPageId:cmsPageId ChannelName:self.homeModel.cmsColumnName ChannelId:cmsColumnId WebUrl:cmsPageUrl]; 67 UIViewController * subVC = [[CNLiveCommuntyModule shareInstance].protocol pushLiveViewWithMainProjectWithPageId:cmsPageId ChannelName:self.homeModel.cmsColumnName ChannelId:cmsColumnId WebUrl:cmsPageUrl];
  68 + subVC.view.backgroundColor = [UIColor whiteColor];
68 [self.view addSubview:subVC.view]; 69 [self.view addSubview:subVC.view];
69 [self addChildViewController:subVC]; 70 [self addChildViewController:subVC];
70 [subVC didMoveToParentViewController:self]; 71 [subVC didMoveToParentViewController:self];
CNLiveCommuntyModule/Classes/ViewController/CNLiveCommuntyUserListViewController.m
@@ -22,7 +22,6 @@ @@ -22,7 +22,6 @@
22 [CNLiveCommuntViewModel requestWithCommuntySaveInfoUsersMentUserDict:@{} isSave:NO isNew:NO CompleterBlock:^(NSArray * _Nonnull userArray, BOOL isSave) { 22 [CNLiveCommuntViewModel requestWithCommuntySaveInfoUsersMentUserDict:@{} isSave:NO isNew:NO CompleterBlock:^(NSArray * _Nonnull userArray, BOOL isSave) {
23 weakSelf.userArray = [[NSMutableArray alloc] initWithArray:userArray]; 23 weakSelf.userArray = [[NSMutableArray alloc] initWithArray:userArray];
24 [weakSelf.tableView reloadData]; 24 [weakSelf.tableView reloadData];
25 - [weakSelf setupWithBottemView:weakSelf.userArray.count > 0];  
26 }]; 25 }];
27 } 26 }
28 27
@@ -59,39 +58,35 @@ @@ -59,39 +58,35 @@
59 } 58 }
60 -(void)setupWithBottemView:(BOOL)isShow 59 -(void)setupWithBottemView:(BOOL)isShow
61 { 60 {
62 - if (isShow) {  
63 - __weak typeof(self) weakSelf = self;  
64 - UIView * bottemView = [[UIView alloc] init];  
65 - bottemView.backgroundColor = [UIColor whiteColor];  
66 - [self.view addSubview:bottemView];  
67 - [bottemView mas_makeConstraints:^(MASConstraintMaker *make) {  
68 - make.left.right.bottom.mas_equalTo(weakSelf.view);  
69 - make.height.mas_equalTo(50+kVerticalBottomSafeHeight);  
70 - }];  
71 -  
72 - UIButton * payButton = [UIButton buttonWithType:UIButtonTypeCustom];  
73 - [payButton setTitle:@"确定" forState:UIControlStateNormal];  
74 - [payButton setTitle:@"确定" forState:UIControlStateHighlighted];  
75 - [payButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];  
76 - [payButton setTitleColor:[UIColor whiteColor] forState:UIControlStateHighlighted];  
77 - payButton.backgroundColor = UIColorHex(#CD0302);  
78 - payButton.layer.masksToBounds = YES;  
79 - payButton.layer.cornerRadius = 18;  
80 - payButton.titleLabel.font = [UIFont systemFontOfSize:16];  
81 - payButton.titleLabel.font = [UIFont boldSystemFontOfSize:16];  
82 - [payButton addTarget:self action:@selector(doneAction:) forControlEvents:UIControlEventTouchUpInside];  
83 - [bottemView addSubview:payButton];  
84 - [payButton mas_makeConstraints:^(MASConstraintMaker *make) {  
85 - make.top.mas_equalTo(bottemView.mas_top).offset(7);  
86 - make.right.mas_equalTo(bottemView.mas_right).offset(-10);  
87 - make.height.mas_equalTo(36);  
88 - make.width.mas_equalTo(kScreenWidth - 30);  
89 - }];  
90 - }else{  
91 - UIView * bottemView = [[UIView alloc] initWithFrame:CGRectZero];  
92 - bottemView.backgroundColor = [UIColor whiteColor];  
93 - [self.view addSubview:bottemView];  
94 - } 61 + __weak typeof(self) weakSelf = self;
  62 + UIView * bottemView = [[UIView alloc] init];
  63 + bottemView.hidden = !isShow;
  64 + bottemView.backgroundColor = [UIColor whiteColor];
  65 + [self.view addSubview:bottemView];
  66 + [bottemView mas_makeConstraints:^(MASConstraintMaker *make) {
  67 + make.left.right.bottom.mas_equalTo(weakSelf.view);
  68 + make.height.mas_equalTo(50+kVerticalBottomSafeHeight);
  69 + }];
  70 +
  71 + UIButton * payButton = [UIButton buttonWithType:UIButtonTypeCustom];
  72 + [payButton setTitle:@"确定" forState:UIControlStateNormal];
  73 + [payButton setTitle:@"确定" forState:UIControlStateHighlighted];
  74 + [payButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
  75 + [payButton setTitleColor:[UIColor whiteColor] forState:UIControlStateHighlighted];
  76 + payButton.backgroundColor = UIColorHex(#CD0302);
  77 + payButton.layer.masksToBounds = YES;
  78 + payButton.layer.cornerRadius = 18;
  79 + payButton.hidden = !isShow;
  80 + payButton.titleLabel.font = [UIFont systemFontOfSize:16];
  81 + payButton.titleLabel.font = [UIFont boldSystemFontOfSize:16];
  82 + [payButton addTarget:self action:@selector(doneAction:) forControlEvents:UIControlEventTouchUpInside];
  83 + [bottemView addSubview:payButton];
  84 + [payButton mas_makeConstraints:^(MASConstraintMaker *make) {
  85 + make.top.mas_equalTo(bottemView.mas_top).offset(7);
  86 + make.right.mas_equalTo(bottemView.mas_right).offset(-10);
  87 + make.height.mas_equalTo(36);
  88 + make.width.mas_equalTo(kScreenWidth - 30);
  89 + }];
95 } 90 }
96 -(void)doneAction:(UIButton *)button 91 -(void)doneAction:(UIButton *)button
97 { 92 {
@@ -137,6 +132,7 @@ @@ -137,6 +132,7 @@
137 }else{ 132 }else{
138 if ([self.selectArray containsObject:subDict]) [self.selectArray removeObject:subDict]; 133 if ([self.selectArray containsObject:subDict]) [self.selectArray removeObject:subDict];
139 } 134 }
  135 + [self setupWithBottemView:self.selectArray.count > 0];
140 } 136 }
141 #pragma mark - DZNEmptyDataSetSource Methods 137 #pragma mark - DZNEmptyDataSetSource Methods
142 - (NSAttributedString *)titleForEmptyDataSet:(UIScrollView *)scrollView 138 - (NSAttributedString *)titleForEmptyDataSet:(UIScrollView *)scrollView