|
@@ -1072,20 +1072,20 @@ public class UserSubscribeServiceImpl extends ServiceImpl<UserSubscribeMapper, U
|
|
|
userSubscribeImports.add(userSubscribeImport);
|
|
|
continue;
|
|
|
}
|
|
|
-// else {
|
|
|
-// List<UserSubscribe> userSubscribes = this.list(new LambdaQueryWrapper<UserSubscribe>().eq(UserSubscribe::getUserId, userId).eq(UserSubscribe::getSubscribeStatus, 1).last("limit 1"));
|
|
|
-// if (!userSubscribes.isEmpty()){
|
|
|
-// UserSubscribe userSubscribe = userSubscribes.get(0);
|
|
|
-// if (Validator.isNotEmpty(userSubscribeImport.getStudentType())){
|
|
|
-// String name = getName(userSubscribe.getStudentType().longValue());
|
|
|
-// if (!userSubscribeImport.getStudentType().equals(name)){
|
|
|
-// userSubscribeImport.setCause("学员类型错误");
|
|
|
-// userSubscribeImports.add(userSubscribeImport);
|
|
|
-// continue;
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
-// }
|
|
|
+ else {
|
|
|
+ List<UserSubscribe> userSubscribes = this.list(new LambdaQueryWrapper<UserSubscribe>().eq(UserSubscribe::getUserId, userId).eq(UserSubscribe::getSubscribeStatus, 1).last("limit 1"));
|
|
|
+ if (!userSubscribes.isEmpty()){
|
|
|
+ UserSubscribe userSubscribe = userSubscribes.get(0);
|
|
|
+ if (Validator.isNotEmpty(userSubscribeImport.getStudentType())){
|
|
|
+ String name = getName(userSubscribe.getStudentType().longValue());
|
|
|
+ if (!userSubscribeImport.getStudentType().equals(name)){
|
|
|
+ userSubscribeImport.setCause("学员类型错误");
|
|
|
+ userSubscribeImports.add(userSubscribeImport);
|
|
|
+ continue;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
userSubscribeAddBo.setUserId(userId);
|
|
|
//预约状态
|
|
|
userSubscribeAddBo.setSubscribeStatus(1);
|