Merge pull request #94 from Kitzanos/feature/GEPAFINBE-95-removed-validation-published-call
GEPAFINBE-95(Removed published call validation )
This commit is contained in:
@@ -442,7 +442,7 @@ public class CallDao {
|
||||
|
||||
|
||||
public CallResponse createCallStep2(CallEntity callEntity, CreateCallRequestStep2 createCallRequest, UserEntity user) {
|
||||
validateUpdate(callEntity);
|
||||
// validateUpdate(callEntity);
|
||||
setIfUpdated(callEntity::getThreshold, callEntity::setThreshold, createCallRequest.getThreshold());
|
||||
callRepository.save(callEntity);
|
||||
convertToEvaluationCriteriaEntities(createCallRequest.getCriteria(), callEntity, LookUpDataTypeEnum.EVALUATION_CRITERIA);
|
||||
@@ -502,13 +502,6 @@ public class CallDao {
|
||||
}
|
||||
|
||||
public CallResponse updateCallStep1(CallEntity callEntity, UpdateCallRequestStep1 updateCallRequest, UserEntity userEntity) {
|
||||
if(Boolean.TRUE.equals(callEntity.getStatus().equals(CallStatusEnum.PUBLISH.getValue()))) {
|
||||
try {
|
||||
Utils.retainOnlySpecificFields(updateCallRequest, Collections.singletonList("faq"));
|
||||
} catch (IllegalAccessException e) {
|
||||
throw new CustomValidationException(Status.BAD_REQUEST,Translator.toLocale(GepafinConstant.FAILED_RETAIN_FIELD));
|
||||
}
|
||||
}
|
||||
isValidDateRange(updateCallRequest, callEntity);
|
||||
setIfUpdated(callEntity::getName, callEntity::setName, updateCallRequest.getName());
|
||||
setIfUpdated(callEntity::getDescriptionShort, callEntity::setDescriptionShort,
|
||||
|
||||
@@ -97,7 +97,7 @@ public class DocumentDao {
|
||||
private Long resolveSourceId(Long sourceId, DocumentSourceTypeEnum sourceType) {
|
||||
if (sourceType == DocumentSourceTypeEnum.CALL) {
|
||||
CallEntity callEntity = callService.validateCall(sourceId);
|
||||
callDao.validateUpdate(callEntity);
|
||||
// callDao.validateUpdate(callEntity);
|
||||
return callEntity.getId();
|
||||
}
|
||||
// else if (sourceType == SourceTypeEnum.APPLICATION) {
|
||||
|
||||
@@ -72,7 +72,7 @@ public class FlowDao {
|
||||
}
|
||||
|
||||
public void checkIfFlowExits(CallEntity call) {
|
||||
callDao.validateUpdate(call);
|
||||
// callDao.validateUpdate(call);
|
||||
List<FlowDataEntity> flowDataEntities = flowDataRepository.findByCallId(call.getId());
|
||||
List<FlowEdgesEntity> flowEdgesEntities = flowEdgesRepository.findByCallId(call.getId());
|
||||
if (Boolean.FALSE.equals(flowDataEntities.isEmpty()) || Boolean.FALSE.equals(flowEdgesEntities.isEmpty())) {
|
||||
|
||||
@@ -173,7 +173,7 @@ public class FormDao {
|
||||
String choosenField=null;
|
||||
FormEntity formEntity = validateForm(formId);
|
||||
validator.validateUserWithCall(user, formEntity.getCall().getId());
|
||||
callDao.validateUpdate(formEntity.getCall());
|
||||
// callDao.validateUpdate(formEntity.getCall());
|
||||
List<ContentRequestBean> contentRequestBean = Utils.convertJsonStringToList(formEntity.getContent(), ContentRequestBean.class);
|
||||
for (ContentRequestBean contentRequestBean1 : contentRequestBean) {
|
||||
FlowDataEntity flowDataEntity = flowDataRepository.findByFormIdAndChoosenField(formEntity.getId(), contentRequestBean1.getId());
|
||||
|
||||
Reference in New Issue
Block a user