X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=portal-BE%2Fsrc%2Fmain%2Fjava%2Forg%2Fonap%2Fportal%2Fdomain%2Fdb%2Fep%2FEpAppRoleFunction.java;fp=portal-BE%2Fsrc%2Fmain%2Fjava%2Forg%2Fonap%2Fportal%2Fdomain%2Fdb%2Fep%2FEpAppRoleFunction.java;h=117167aaa6c3fffe78f158f7924fe164c335e3e1;hb=ca3d9f4b725774763f12488940033a294b778244;hp=3cb219a312c201f6cf34f73a873ffab1901cfc0b;hpb=4c6f6a443cb2e6effa995e77d56689c1c2dab4ad;p=portal.git diff --git a/portal-BE/src/main/java/org/onap/portal/domain/db/ep/EpAppRoleFunction.java b/portal-BE/src/main/java/org/onap/portal/domain/db/ep/EpAppRoleFunction.java index 3cb219a3..117167aa 100644 --- a/portal-BE/src/main/java/org/onap/portal/domain/db/ep/EpAppRoleFunction.java +++ b/portal-BE/src/main/java/org/onap/portal/domain/db/ep/EpAppRoleFunction.java @@ -53,6 +53,8 @@ import javax.persistence.Index; import javax.persistence.JoinColumn; import javax.persistence.JoinColumns; import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; import javax.persistence.Table; import javax.validation.Valid; import javax.validation.constraints.Digits; @@ -83,6 +85,13 @@ CREATE TABLE `ep_app_role_function` ( ) */ +@NamedQueries({ + @NamedQuery( + name = "EpAppRoleFunction.getAppRoleFunctionOnRoleIdAndAppId", + query = "from EpAppRoleFunction where appId.id = :appId and fnRole.id = :roleId" + ) +}) + @Table(name = "ep_app_role_function", indexes = { @Index(name = "fk_ep_app_role_function_ep_app_func_role_id", columnList = "app_id, role_id, function_cd", unique = true), @Index(name = "fk_ep_app_role_function_ep_app_func", columnList = "app_id, function_cd"),