|
@@ -123,14 +123,18 @@
|
|
|
// 老师布置过作业且没有点评 可以点击
|
|
|
if (self.homeworkModel.reviewHomework == 1 || self.homeworkModel.decorateHomework == 0) {
|
|
|
self.canModify = NO;
|
|
|
- self.bottomView.actionButton.userInteractionEnabled = NO;
|
|
|
- self.bottomView.actionButton.backgroundColor = HexRGB(0xe5e5e5);
|
|
|
- [self.bottomView.actionButton setTitleColor:HexRGB(0x666666) forState:UIControlStateNormal];
|
|
|
}
|
|
|
else {
|
|
|
self.canModify = YES;
|
|
|
+ }
|
|
|
+ if ([self.homeworkModel.courseStatus isEqualToString:@"COMPLETE"]) {
|
|
|
+ self.tableView.tableFooterView = [UIView new];
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ self.tableView.tableFooterView = self.bottomView;
|
|
|
self.bottomView.actionButton.userInteractionEnabled = YES;
|
|
|
- self.bottomView.actionButton.backgroundColor = THEMECOLOR;
|
|
|
+ [self.bottomView.actionButton setTitle:@"进入教室" forState:UIControlStateNormal];
|
|
|
+ [self.bottomView.actionButton setBackgroundColor:THEMECOLOR];
|
|
|
[self.bottomView.actionButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
|
|
|
}
|
|
|
}
|
|
@@ -164,40 +168,14 @@
|
|
|
if ([self.homeworkModel.courseStatus isEqualToString:@"COMPLETE"]) {
|
|
|
statusLabel.text = @"已结束";
|
|
|
statusLabel.textColor = HexRGB(0x999999);
|
|
|
-
|
|
|
- self.bottomView.actionButton.userInteractionEnabled = NO;
|
|
|
- [self.bottomView.actionButton setTitle:@"已结束" forState:UIControlStateNormal];
|
|
|
- [self.bottomView.actionButton setBackgroundColor:HexRGB(0xe5e5e5)];
|
|
|
- [self.bottomView.actionButton setTitleColor:HexRGB(0x666666) forState:UIControlStateNormal];
|
|
|
-// // 老师已点评作业 或者老师未布置作业
|
|
|
-// if (self.homeworkModel.reviewHomework == 1 || self.homeworkModel.decorateHomework == 0) {
|
|
|
-// self.bottomView.actionButton.userInteractionEnabled = NO;
|
|
|
-// [self.bottomView.actionButton setTitle:@"确认提交" forState:UIControlStateNormal];
|
|
|
-// [self.bottomView.actionButton setBackgroundColor:HexRGB(0xe5e5e5)];
|
|
|
-// [self.bottomView.actionButton setTitleColor:HexRGB(0x666666) forState:UIControlStateNormal];
|
|
|
-// }
|
|
|
-// else {
|
|
|
-// self.bottomView.actionButton.userInteractionEnabled = YES;
|
|
|
-// [self.bottomView.actionButton setTitle:@"确认提交" forState:UIControlStateNormal];
|
|
|
-// [self.bottomView.actionButton setBackgroundColor:THEMECOLOR];
|
|
|
-// [self.bottomView.actionButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
|
|
|
-// }
|
|
|
}
|
|
|
else if ([self.homeworkModel.courseStatus isEqualToString:@"ING"]) {
|
|
|
statusLabel.text = @"进行中";
|
|
|
statusLabel.textColor = THEMECOLOR;
|
|
|
- self.bottomView.actionButton.userInteractionEnabled = YES;
|
|
|
- [self.bottomView.actionButton setTitle:@"进入教室" forState:UIControlStateNormal];
|
|
|
- [self.bottomView.actionButton setBackgroundColor:THEMECOLOR];
|
|
|
- [self.bottomView.actionButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
|
|
|
}
|
|
|
else {
|
|
|
statusLabel.text = @"未开始";
|
|
|
statusLabel.textColor = HexRGB(0xff802c);
|
|
|
- self.bottomView.actionButton.userInteractionEnabled = YES;
|
|
|
- [self.bottomView.actionButton setTitle:@"进入教室" forState:UIControlStateNormal];
|
|
|
- [self.bottomView.actionButton setBackgroundColor:THEMECOLOR];
|
|
|
- [self.bottomView.actionButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
|
|
|
}
|
|
|
}
|
|
|
|