Package com.avoka.fc.core.dao
Class PortalDao
java.lang.Object
com.avoka.core.dao.BaseDao
com.avoka.fc.core.dao.AbstractDao
com.avoka.fc.core.dao.PortalDao
Provides a DAO for the Portal entity.
- See Also:
-
Field Summary
Fields inherited from class com.avoka.core.dao.BaseDao
FETCH_LIMIT, STATEMENT_MAX_NO_PARAMETERS
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
Deprecated.Return the Administration Console portalReturn the default portalReturn the Avoka Exchange portalThe list of portals that can be used to host formsReturn the Transact Insights portalReturn the Transact Maestro portalgetObjectForPK
(Object object) Return the portal with the specified OIDReturn the Transact Operations portalgetPortalByContextPath
(String contextPath) Return the portal matching the given context pathgetPortalByName
(String name) Return the portal with the specified namegetPortalForLocalhost
(String contextPath) Return the portal matching the given context path to localhostReturn the full list of portals, excluding the "Receipts" type portal, ordered by name.getPortalList
(String keyword, String clientId, Boolean formSpace) Return the list of portals matching the specified search criteriagetPortalList
(String keyword, String clientId, Boolean formSpace, Status status) Return the list of portals matching the specified search criteriagetPortalsByType
(String portalType) Return the list of portals of a specific type, ordered by namegetPortalsForClient
(String clientId) Return the list of portals that the given client has access togetPortalsForUser
(UserAccount userAccount) Return the set of portals associated with a user accountReturn all portals not explicitly associated with a security manager.Return the list of portals which have associated permissions.getRequestPortal
(jakarta.servlet.http.HttpServletRequest request) Return the SmartForm Manager portal associated with the specified request.Return the Transact Receipts portalvoid
Initialize the portal record for the administration console, if a portal namedPortal.PORTAL_ADMIN_CONSOLE
does not already existvoid
setDefaultPortal
(Portal newDefaultPortal) Set the default portal to a specific portal.void
unsetDefaultPortal
(Portal oldDefaultPortal) Unsets the default flag for a portal.Methods inherited from class com.avoka.fc.core.dao.AbstractDao
andFilterClientExcludeNull, andFilterClientIncludeNull, andFilterClientOnly, isClientAccessAllowed, performQueryConfigCached
Methods inherited from class com.avoka.core.dao.BaseDao
addOrdering, addOrderingCaseInsensitive, addOrderingCaseSensitive, andQueryBetween, andQueryInExp, andQueryInExp, andQueryLikeIgnoreCaseExp, andQueryMatchDbExp, andQueryMatchExp, andQueryMatchIsNotNull, andQueryMatchIsNull, andQueryNoMatchExp, andQueryNotTrue, deleteObject, deleteObjects, findObject, getDataContext, getFetchLimit, getLogger, getObjectForPK, newObject, orQueryLikeIgnoreCaseExp, orQueryMatchExp, performNamedQuery, performNamedQuery, performNamedQuery, performNamedQuery, performNonSelectingQuery, performNonSelectingQuery, performNonSelectingQuery, performNonSelectingQuery, performQuery, performQuery, performQuery, registerNewObject, setCacheStrategy, setFetchLimit, setLocalCacheStrategy, setLocalCacheStrategy, setSharedCacheStrategy, toMap, toMap
-
Constructor Details
-
PortalDao
public PortalDao()
-
-
Method Details
-
clearThreadLocalCache
Deprecated.Clear the thread local user account cache.- Since:
- 4.3.2
-
getObjectForPK
Return the portal with the specified OID- Parameters:
object
- the OID- Returns:
- the matching portal, or null if not found
-
getRequestPortal
Return the SmartForm Manager portal associated with the specified request. The portal is looked up by context path.- Parameters:
request
- the HTTP servlet request- Returns:
- the portal associated from the request, null if no portal matches the request context
- Since:
- 5.1.0
-
getPortalList
Return the list of portals matching the specified search criteria- Parameters:
keyword
- a search keyword (optional)clientId
- the client OID (optional). If set, only portals assigned to the client will be returned.formSpace
- specify whether a form space or not- Returns:
- the list of matching portals
-
getPortalList
public List<Portal> getPortalList(String keyword, String clientId, Boolean formSpace, Status status) Return the list of portals matching the specified search criteria- Parameters:
keyword
- a search keyword (optional). It can be on name, LastModifiedDate, CreatedAt and Version. Date format should be "dd MMM yyyy" like how It shows in UI.clientId
- the client OID (optional). If set, only portals assigned to the client will be returned.formSpace
- specify whether a form space or notstatus
- specify the status of space- Returns:
- the list of matching portals
- Since:
- 24.4.0
-
getPortalList
Return the full list of portals, excluding the "Receipts" type portal, ordered by name.- Returns:
- the list of portals
-
getPortalsWithPermissions
Return the list of portals which have associated permissions.- Returns:
- the list of portals which have associated permissions.
- Since:
- 4.2.0
-
getPortalsByType
Return the list of portals of a specific type, ordered by name- Parameters:
portalType
- the portal type (one ofPortal.PORTAL_TYPE_VALUES
- Returns:
- the list of portals
-
getFormPortalList
The list of portals that can be used to host forms- Returns:
- the list of portals with
_Portal.FORMS_FLAG_PROPERTY
set
-
getPortalByName
Return the portal with the specified name- Parameters:
name
- the non-null name- Returns:
- the matching portal
-
getPortalsForClient
Return the list of portals that the given client has access to- Parameters:
clientId
- the OID of an existing client- Returns:
- the list of forms portals that this client has access to
-
getAdminConsolePortal
Return the Administration Console portal- Returns:
- the portal with the name defined in
Portal.PORTAL_ADMIN_CONSOLE
-
getInsightsPortal
Return the Transact Insights portal- Returns:
- the portal with the name defined in
Portal.PORTAL_TRANSACT_INSIGHTS
- Since:
- 5.0
-
getMaestroPortal
Return the Transact Maestro portal- Returns:
- the portal with the name defined in
Portal.PORTAL_TRANSACT_MAESTRO
- Since:
- 5.0
-
getOperationsPortal
Return the Transact Operations portal- Returns:
- the portal with the name defined in
Portal.PORTAL_TRANSACT_OPERATIONS
- Since:
- 22.10.0
-
getExchangePortal
Return the Avoka Exchange portal- Returns:
- the portal with the name defined in
Portal.PORTAL_AVOKA_EXCHANGE
- Since:
- 17.10.0
-
getTransactReceiptsPortal
Return the Transact Receipts portal- Returns:
- the portal with the name defined in
Portal.PORTAL_TRANSACT_RECEIPTS
- Since:
- 5.1.0
-
getPortalByContextPath
Return the portal matching the given context path- Parameters:
contextPath
- the context path (leading protocol indicators such as "http://" will be ignored)- Returns:
- the portal with a context path matching the specified context path
-
getPortalForLocalhost
Return the portal matching the given context path to localhost- Parameters:
contextPath
- the context path containing localhost or 127.0.0.1- Returns:
- the portal whose context path contains the relative context path (e.g. "forms" for "http://localhost:9080/forms/index.htm")
-
getDefaultPortal
Return the default portal- Returns:
- the portal for which
_Portal.DEFAULT_FLAG_PROPERTY
is set
-
setDefaultPortal
Set the default portal to a specific portal. On successful completion, only one portal is marked as the default portal. This method executes a database commit.- Parameters:
newDefaultPortal
- the new default portal.
-
unsetDefaultPortal
Unsets the default flag for a portal. Another portal is set as the default portal. This method executes a database commit.- Parameters:
oldDefaultPortal
- the current default portal
-
getPortalsForUser
Return the set of portals associated with a user account- Parameters:
userAccount
- the non-null user account- Returns:
- the set of portals, sorted by name
-
loadAdminConsolePortal
public void loadAdminConsolePortal()Initialize the portal record for the administration console, if a portal namedPortal.PORTAL_ADMIN_CONSOLE
does not already exist -
getPortalsWithoutSecurityManager
Return all portals not explicitly associated with a security manager. TM uses the default security manager for these portals. Note: This does NOT return all portals using the default security manager. Notably, if a portal is explicitly associated with the default security manager, it is not included.- Returns:
- the set of portals for which no security manager is set
- Since:
- 4.3.0
-