|
|
@ -60,8 +60,10 @@ |
|
|
|
} |
|
|
|
} |
|
|
|
//比较2个时间段 结束时间需大于开始时间 |
|
|
|
//比较2个时间段 结束时间需大于开始时间 |
|
|
|
|
|
|
|
|
|
|
|
self.zx_navRightBtn.enabled = NO; |
|
|
|
|
|
|
|
NSDateFormatter * df = [[NSDateFormatter alloc]init]; |
|
|
|
NSDateFormatter * df = [[NSDateFormatter alloc]init]; |
|
|
|
|
|
|
|
NSLocale *zh_CNLocale = [[NSLocale alloc] initWithLocaleIdentifier:@"zh_CN"]; |
|
|
|
|
|
|
|
df.locale = zh_CNLocale; |
|
|
|
|
|
|
|
df.calendar = [[NSCalendar alloc]initWithCalendarIdentifier:NSCalendarIdentifierISO8601]; |
|
|
|
[df setDateFormat:@"HH:mm"]; |
|
|
|
[df setDateFormat:@"HH:mm"]; |
|
|
|
double startTime = [df dateFromString:self.tfStartTime.text].timeIntervalSince1970; |
|
|
|
double startTime = [df dateFromString:self.tfStartTime.text].timeIntervalSince1970; |
|
|
|
double endTime =[df dateFromString:self.tfEndTime.text].timeIntervalSince1970; |
|
|
|
double endTime =[df dateFromString:self.tfEndTime.text].timeIntervalSince1970; |
|
|
@ -73,6 +75,7 @@ |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
self.zx_navRightBtn.enabled = NO; |
|
|
|
|
|
|
|
|
|
|
|
CourseModel *model = [CourseModel courseWithName:_tfCourseName.text dayIndex:_curWeek startCourseIndex:_curLession endCourseIndex:_curLession]; |
|
|
|
CourseModel *model = [CourseModel courseWithName:_tfCourseName.text dayIndex:_curWeek startCourseIndex:_curLession endCourseIndex:_curLession]; |
|
|
|
NSString *time = [NSString stringWithFormat:@"%@%@",_tfStartTime.text, _tfEndTime.text]; |
|
|
|
NSString *time = [NSString stringWithFormat:@"%@%@",_tfStartTime.text, _tfEndTime.text]; |
|
|
@ -157,6 +160,8 @@ |
|
|
|
label.layer.masksToBounds = YES; |
|
|
|
label.layer.masksToBounds = YES; |
|
|
|
|
|
|
|
|
|
|
|
UIDatePicker *datePicker = [[UIDatePicker alloc] init]; |
|
|
|
UIDatePicker *datePicker = [[UIDatePicker alloc] init]; |
|
|
|
|
|
|
|
NSLocale *locale = [[NSLocale alloc] initWithLocaleIdentifier:@"NL"]; |
|
|
|
|
|
|
|
[datePicker setLocale:locale]; |
|
|
|
datePicker.datePickerMode = UIDatePickerModeTime; |
|
|
|
datePicker.datePickerMode = UIDatePickerModeTime; |
|
|
|
datePicker.date = [NSDate new]; |
|
|
|
datePicker.date = [NSDate new]; |
|
|
|
|
|
|
|
|
|
|
@ -178,6 +183,8 @@ |
|
|
|
label.layer.masksToBounds = YES; |
|
|
|
label.layer.masksToBounds = YES; |
|
|
|
|
|
|
|
|
|
|
|
UIDatePicker *datePicker = [[UIDatePicker alloc] init]; |
|
|
|
UIDatePicker *datePicker = [[UIDatePicker alloc] init]; |
|
|
|
|
|
|
|
NSLocale *locale = [[NSLocale alloc] initWithLocaleIdentifier:@"NL"]; |
|
|
|
|
|
|
|
[datePicker setLocale:locale]; |
|
|
|
datePicker.datePickerMode = UIDatePickerModeTime; |
|
|
|
datePicker.datePickerMode = UIDatePickerModeTime; |
|
|
|
datePicker.date = [NSDate new]; |
|
|
|
datePicker.date = [NSDate new]; |
|
|
|
|
|
|
|
|
|
|
|