Merge remote-tracking branch 'origin/feature/REQ-3581' into feature/REQ-3581

This commit is contained in:
yanglin 2025-02-20 13:46:17 +08:00
commit 5beef68686
3 changed files with 2 additions and 7 deletions

View File

@ -5,7 +5,6 @@ import lombok.AccessLevel;
import lombok.AllArgsConstructor;
import lombok.Getter;
import java.util.Arrays;
import java.util.Set;
/**
@ -30,10 +29,6 @@ public enum VisaTypeEnum {
private static final Set<VisaTypeEnum> changeApprovedSet = Sets.newHashSet(DESIGN_CHANGE, TECHNOLOGY_APPROVED);
private static final Set<VisaTypeEnum> projectVisaSet = Sets.newHashSet(PROJECT_VISA);
public static VisaTypeEnum valueOfCode(String code) {
return Arrays.stream(VisaTypeEnum.values()).filter(item -> item.getCode().equals(code)).findFirst().orElse(null);
}
/**
* 设计变更/技术核定
*/

View File

@ -88,7 +88,7 @@ public class ImGroupAddMembersEventHandler implements EventHandler, Initializing
notice.setBizCode(String.valueOf(visaId));
notice.setBizExtParams(new JSONObject(Maps.of(
"initiatorName", ownerProfile.getRealName(),
"visaType", StringUtils.isNotBlank(visaType) ? VisaTypeEnum.valueOfCode(visaType).getDesc() : "",
"visaType", StringUtils.isNotBlank(visaType) ? VisaTypeEnum.valueOf(visaType).getDesc() : "",
"topic", group.getName())));
noticeApi.send(notice);
}

View File

@ -133,7 +133,7 @@ public class ImGroupsCreatedEventHandler implements EventHandler, InitializingBe
"reason", visa.getReason(),
"initiatorName", profile.getRealName(),
"initiatorUnitName", unitInfo.getName(),
"visaType", StringUtils.isNotBlank(visaType) ? VisaTypeEnum.valueOfCode(visaType).getDesc() : "",
"visaType", StringUtils.isNotBlank(visaType) ? VisaTypeEnum.valueOf(visaType).getDesc() : "",
"amountChange", VisaHelper.buildChangeAmount(visa.getAmountChange())
)));
msgCenterGateway.sendCardToCroup(cardRequest);