Commit 8ecc9762 by huluobin

战术更新

parent 22e307c7
...@@ -23,14 +23,14 @@ public class BeautyExpoQuestionnaireServiceImpl extends ServiceImpl<BeautyExpoQu ...@@ -23,14 +23,14 @@ public class BeautyExpoQuestionnaireServiceImpl extends ServiceImpl<BeautyExpoQu
@Override @Override
public void submitQuestionnaire(BeautyExpoQuestionnaire beautyExpoQuestionnaire) { public void submitQuestionnaire(BeautyExpoQuestionnaire beautyExpoQuestionnaire) {
if (hasSubmitted(beautyExpoQuestionnaire.getCustomerId())) { if (hasSubmitted(beautyExpoQuestionnaire.getCustomerId())) {
throw new RRException(ErrorCode.CS_2003) throw new RRException(ErrorCode.CS_2003);
} }
this.save(beautyExpoQuestionnaire); this.save(beautyExpoQuestionnaire);
} }
@Override @Override
public Boolean hasSubmitted(Integer customerId) { public Boolean hasSubmitted(Integer customerId) {
BeautyExpoQuestionnaire questionnaire = this.getOne(new LambdaQueryWrapper<BeautyExpoQuestionnaire>().eq(BeautyExpoQuestionnaire::getCustomerId, customerId); BeautyExpoQuestionnaire questionnaire = this.getOne(new LambdaQueryWrapper<BeautyExpoQuestionnaire>().eq(BeautyExpoQuestionnaire::getCustomerId, customerId));
return questionnaire != null; return questionnaire != null;
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment