X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=portal-BE%2Fsrc%2Fmain%2Fjava%2Forg%2Fonap%2Fportal%2Fdomain%2Fdb%2Fep%2FEpAppFunction.java;h=5cccdcbdbc3e60b156450340d7527b6ad5d27e07;hb=39fb119cdaea6bd8d801b22d195db39f6d8faaca;hp=533309dff1f7ce488f103e7d39ceb8dcc5a3ad1b;hpb=dd4c51e4349b596766f2fda555a7a0d3ba46e9fa;p=portal.git diff --git a/portal-BE/src/main/java/org/onap/portal/domain/db/ep/EpAppFunction.java b/portal-BE/src/main/java/org/onap/portal/domain/db/ep/EpAppFunction.java index 533309df..5cccdcbd 100644 --- a/portal-BE/src/main/java/org/onap/portal/domain/db/ep/EpAppFunction.java +++ b/portal-BE/src/main/java/org/onap/portal/domain/db/ep/EpAppFunction.java @@ -101,62 +101,64 @@ CREATE TABLE `ep_app_function` ( @IdClass(EpAppFunctionId.class) @NoArgsConstructor @AllArgsConstructor -public class EpAppFunction extends DomainVo implements Serializable{ - @Id - @ManyToOne(cascade = CascadeType.ALL, fetch = FetchType.LAZY) - @JoinColumn(name = "app_id") - @Valid - private FnApp appId; - @Id - @Column(name = "function_cd", length = 250, nullable = false) - @Size(max = 250) - @NotNull - @SafeHtml - private String functionCd; - @Column(name = "function_name", length = 250, nullable = false) - @Size(max = 250) - @NotNull - @SafeHtml - private String functionName; +public class EpAppFunction extends DomainVo implements Serializable { - private Long roleId; - private String type; - @SafeHtml - private String action; - @SafeHtml - private String editUrl; + @Id + @ManyToOne(cascade = CascadeType.ALL, fetch = FetchType.LAZY) + @JoinColumn(name = "app_id") + @Valid + private FnApp appId; + @Id + @Column(name = "function_cd", length = 250, nullable = false) + @Size(max = 250) + @NotNull + @SafeHtml + private String functionCd; + @Column(name = "function_name", length = 250, nullable = false) + @Size(max = 250) + @NotNull + @SafeHtml + private String functionName; - @OneToMany( - targetEntity = EpAppRoleFunction.class, - mappedBy = "epAppFunction", - cascade = CascadeType.ALL, - fetch = FetchType.LAZY - ) - private Set epAppRoleFunctions; + private Long roleId; + private String type; + @SafeHtml + private String action; + @SafeHtml + private String editUrl; - public EpAppFunction(Long id, String code, String name, FnApp appId, String type, String action,String editUrl) { - super(); - this.id = id; - this.functionCd = code; - this.functionName = name; - this.appId = appId; - this.type = type; - this.action = action; - this.editUrl = editUrl; - } + @OneToMany( + targetEntity = EpAppRoleFunction.class, + mappedBy = "epAppFunction", + cascade = CascadeType.ALL, + fetch = FetchType.LAZY + ) + private Set epAppRoleFunctions; - @Getter - @Setter - @EqualsAndHashCode - @NoArgsConstructor - @AllArgsConstructor - public static class EpAppFunctionId implements Serializable { - @Valid - private FnApp appId; - @Size(max = 250) - @NotNull - @SafeHtml - private String functionCd; - } + public EpAppFunction(Long id, String code, String name, FnApp appId, String type, String action, String editUrl) { + super(); + this.id = id; + this.functionCd = code; + this.functionName = name; + this.appId = appId; + this.type = type; + this.action = action; + this.editUrl = editUrl; + } + + @Getter + @Setter + @EqualsAndHashCode + @NoArgsConstructor + @AllArgsConstructor + public static class EpAppFunctionId implements Serializable { + + @Valid + private FnApp appId; + @Size(max = 250) + @NotNull + @SafeHtml + private String functionCd; + } }