|
@@ -375,15 +375,16 @@ public class UserStudyRecordServiceImpl extends ServiceImpl<UserStudyRecordMappe
|
|
|
if(Validator.isNotEmpty(add.getStatus())&&add.getStatus()==1){
|
|
|
lastVo.setStatus(1);
|
|
|
}
|
|
|
- lastVo.setStudyDuration(lastVo.getStudyDuration().longValue()+add.getStudyDuration().longValue());
|
|
|
+ /* lastVo.setStudyDuration(lastVo.getStudyDuration().longValue()+add.getStudyDuration().longValue());
|
|
|
if(lastVo.getStudyDuration().longValue()>add.getVideoCurrentTime().longValue()){
|
|
|
lastVo.setStudyDuration(add.getVideoCurrentTime());
|
|
|
- }
|
|
|
- /*if(lastVo.getVideoCurrentTime().longValue()<=add.getVideoCurrentTime().longValue()){
|
|
|
- lastVo.setStudyDuration(lastVo.getStudyDuration().longValue()+(add.getVideoCurrentTime().longValue()-lastVo.getVideoCurrentTime().longValue()));
|
|
|
- }else{
|
|
|
- lastVo.setStudyDuration(lastVo.getStudyDuration().longValue()+add.getStudyDuration().longValue());
|
|
|
}*/
|
|
|
+ if(lastVo.getVideoCurrentTime().longValue()<=add.getVideoCurrentTime().longValue()){
|
|
|
+ lastVo.setStudyDuration(lastVo.getStudyDuration().longValue()+(add.getVideoCurrentTime().longValue()-lastVo.getVideoCurrentTime().longValue()));
|
|
|
+ }
|
|
|
+ if(lastVo.getStudyDuration().longValue()>add.getVideoCurrentTime().longValue()){
|
|
|
+ lastVo.setStudyDuration(add.getVideoCurrentTime());
|
|
|
+ }
|
|
|
lastVo.setVideoCurrentTime(add.getVideoCurrentTime());
|
|
|
lastVo.setEndTime(add.getEndTime());
|
|
|
|