|
@@ -100,9 +100,9 @@ public class PromotionActivityLogic {
|
|
|
throw new RemoteServiceException("客户地址不能为空");
|
|
|
}
|
|
|
|
|
|
-// if (CollectionUtil.isEmpty(bean.getItems())) {
|
|
|
-// throw new RemoteServiceException("报名信息不能为空");
|
|
|
-// }
|
|
|
+ if (CollectionUtil.isEmpty(bean.getItems())) {
|
|
|
+ throw new RemoteServiceException("报名信息不能为空");
|
|
|
+ }
|
|
|
|
|
|
final PromotionQuestionnaire questionnaire = promotionQuestionnaireService.getById(bean.getPromotionQuestionnaireId());
|
|
|
|
|
@@ -122,17 +122,17 @@ public class PromotionActivityLogic {
|
|
|
bean.setPromotionActivityId(id)
|
|
|
.insert();
|
|
|
|
|
|
- if (CollectionUtil.isNotEmpty(bean.getItems())) {
|
|
|
- for (PromotionActivityItem item : bean.getItems()) {
|
|
|
- if (StringUtils.isBlank(item.getId())) {
|
|
|
- throw new RemoteServiceException("活动答案源明细id不能为空");
|
|
|
- }
|
|
|
- item.setPromotionActivityItemId(null)
|
|
|
- .setPromotionActivityId(bean.getPromotionActivityId())
|
|
|
- .setPromotionQuestionnaireId(bean.getPromotionQuestionnaireId());
|
|
|
+
|
|
|
+ for (PromotionActivityItem item : bean.getItems()) {
|
|
|
+ if (StringUtils.isBlank(item.getId())) {
|
|
|
+ throw new RemoteServiceException("活动答案源明细id不能为空");
|
|
|
}
|
|
|
+ item.setPromotionActivityItemId(null)
|
|
|
+ .setPromotionActivityId(bean.getPromotionActivityId())
|
|
|
+ .setPromotionQuestionnaireId(bean.getPromotionQuestionnaireId());
|
|
|
}
|
|
|
|
|
|
+
|
|
|
promotionActivityItemService.saveBatch(bean.getItems());
|
|
|
}
|
|
|
|