Class MyDBWebController
- java.lang.Object
-
- org.silverpeas.core.web.mvc.controller.AbstractComponentSessionController
-
- org.silverpeas.core.web.mvc.webcomponent.WebComponentController<MyDBWebRequestContext>
-
- org.silverpeas.components.mydb.web.MyDBWebController
-
- All Implemented Interfaces:
Serializable
,org.silverpeas.core.web.mvc.controller.ComponentSessionController
,org.silverpeas.core.web.session.SessionCloseable
@WebComponentController("myDB") public class MyDBWebController extends org.silverpeas.core.web.mvc.webcomponent.WebComponentController<MyDBWebRequestContext>
The web controller of the MyDB application. Like all of the web controllers in Silverpeas, it is both session-scoped and spawn per application instance.- Author:
- mmoquillon
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
ALL_COLUMNS
static String
ALL_TABLES
static String
COMPARING_COLUMN
static String
COMPARING_OPERATOR
static String
COMPARING_OPERATORS
static String
COMPARING_VALUE
static String
ERROR_MESSAGE
static String
FK_ARRAY_PANE_NAME
static String
FK_SELECTED
static String
MAIN_ARRAY_PANE_NAME
static String
ROW
static String
TABLE_VIEW
static String
UI_ROW_ID
static String
USE_LAST_LOADED_ROWS
-
Constructor Summary
Constructors Constructor Description MyDBWebController(org.silverpeas.core.web.mvc.controller.MainSessionController controller, org.silverpeas.core.web.mvc.controller.ComponentContext context)
Constructs a new Web controller for the specified context and with theMainSessionController
instance that is specific to the user behind the access to the underlying application instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addNewTableRow(MyDBWebRequestContext context)
void
deleteTableRow(MyDBWebRequestContext context)
void
editConnection(MyDBWebRequestContext context)
void
error(MyDBWebRequestContext context)
void
filterTableContent(MyDBWebRequestContext context)
void
getForeignKeyTableViewFrom(MyDBWebRequestContext context)
void
getNewTableRowForm(MyDBWebRequestContext context)
void
getTableRowForm(MyDBWebRequestContext context)
void
home(MyDBWebRequestContext context)
protected void
onInstantiation(MyDBWebRequestContext context)
void
saveConnection(MyDBWebRequestContext context)
void
selectTable(MyDBWebRequestContext context)
void
updateTableRow(MyDBWebRequestContext context)
void
viewTableContent(MyDBWebRequestContext context)
-
Methods inherited from class org.silverpeas.core.web.mvc.webcomponent.WebComponentController
beforeRequestProcessing
-
Methods inherited from class org.silverpeas.core.web.mvc.controller.AbstractComponentSessionController
addClipboardSelection, clipboardPasteDone, close, getClipboardErrorMessage, getClipboardExceptionError, getClipboardObjects, getClipboardSelectedObjects, getClipboardSize, getComponentAccessController, getComponentId, getComponentLabel, getComponentName, getComponentParameterValue, getComponentParameterValue, getComponentRootName, getComponentUrl, getHighestSilverpeasUserRole, getIcon, getLanguage, getLook, getMultilang, getOrganisationController, getPersonalization, getRSSUrl, getSelection, getSettings, getSilverpeasUserRoles, getSpaceId, getSpaceLabel, getString, getSubscriptionContext, getUrlEncodedParameter, getUserAccessLevel, getUserAvailComponentIds, getUserDetail, getUserDetail, getUserId, getUserManageableGroupIds, getUserManageableSpaceIds, getUserRoles, getZoneId, isAppInMaintenance, isGroupManager, isPasswordChangeAllowed, isSpaceInMaintenance, removeClipboardElement, setAppModeMaintenance, setClipboardSelectedElement, setComponentRootName, setSpaceModeMaintenance
-
-
-
-
Field Detail
-
MAIN_ARRAY_PANE_NAME
public static final String MAIN_ARRAY_PANE_NAME
- See Also:
- Constant Field Values
-
FK_ARRAY_PANE_NAME
public static final String FK_ARRAY_PANE_NAME
- See Also:
- Constant Field Values
-
FK_SELECTED
public static final String FK_SELECTED
- See Also:
- Constant Field Values
-
TABLE_VIEW
public static final String TABLE_VIEW
- See Also:
- Constant Field Values
-
USE_LAST_LOADED_ROWS
public static final String USE_LAST_LOADED_ROWS
- See Also:
- Constant Field Values
-
ALL_TABLES
public static final String ALL_TABLES
- See Also:
- Constant Field Values
-
COMPARING_COLUMN
public static final String COMPARING_COLUMN
- See Also:
- Constant Field Values
-
COMPARING_OPERATOR
public static final String COMPARING_OPERATOR
- See Also:
- Constant Field Values
-
COMPARING_VALUE
public static final String COMPARING_VALUE
- See Also:
- Constant Field Values
-
COMPARING_OPERATORS
public static final String COMPARING_OPERATORS
- See Also:
- Constant Field Values
-
ALL_COLUMNS
public static final String ALL_COLUMNS
- See Also:
- Constant Field Values
-
UI_ROW_ID
public static final String UI_ROW_ID
- See Also:
- Constant Field Values
-
ROW
public static final String ROW
- See Also:
- Constant Field Values
-
ERROR_MESSAGE
public static final String ERROR_MESSAGE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
MyDBWebController
public MyDBWebController(org.silverpeas.core.web.mvc.controller.MainSessionController controller, org.silverpeas.core.web.mvc.controller.ComponentContext context)
Constructs a new Web controller for the specified context and with theMainSessionController
instance that is specific to the user behind the access to the underlying application instance.- Parameters:
controller
- the main session controller for the current user.context
- the context identifying among others the targeted application instance.
-
-
Method Detail
-
onInstantiation
protected void onInstantiation(MyDBWebRequestContext context)
- Specified by:
onInstantiation
in classorg.silverpeas.core.web.mvc.webcomponent.WebComponentController<MyDBWebRequestContext>
-
home
@GET @Path("Main") @Homepage @RedirectToInternal("{nextView}") @LowestRoleAccess(READER) public void home(MyDBWebRequestContext context)
-
error
@GET @Path("Error") @RedirectToInternalJsp("error.jsp") @LowestRoleAccess(READER) public void error(MyDBWebRequestContext context)
-
viewTableContent
@GET @Path("ViewTable") @RedirectToInternalJsp("mydb.jsp") @LowestRoleAccess(READER) public void viewTableContent(MyDBWebRequestContext context)
-
getNewTableRowForm
@GET @Path("NewRow") @RedirectToInternalJsp("rowForm.jsp") @LowestRoleAccess(PUBLISHER) public void getNewTableRowForm(MyDBWebRequestContext context)
-
getTableRowForm
@GET @Path("GetRow") @RedirectToInternalJsp("rowForm.jsp") @LowestRoleAccess(PUBLISHER) public void getTableRowForm(MyDBWebRequestContext context)
-
getForeignKeyTableViewFrom
@GET @Path("ViewTargetTable") @RedirectToInternalJsp("fkTable.jsp") @LowestRoleAccess(PUBLISHER) public void getForeignKeyTableViewFrom(MyDBWebRequestContext context)
-
addNewTableRow
@POST @Path("AddRow") @RedirectToInternalJsp("mydb.jsp") @LowestRoleAccess(PUBLISHER) public void addNewTableRow(MyDBWebRequestContext context)
-
updateTableRow
@POST @Path("UpdateRow") @RedirectToInternalJsp("mydb.jsp") @LowestRoleAccess(PUBLISHER) public void updateTableRow(MyDBWebRequestContext context)
-
deleteTableRow
@POST @Path("DeleteRow") @RedirectToInternalJsp("mydb.jsp") @LowestRoleAccess(PUBLISHER) public void deleteTableRow(MyDBWebRequestContext context)
-
selectTable
@POST @Path("SetTable") @Produces("application/json") @LowestRoleAccess(READER) public void selectTable(MyDBWebRequestContext context)
-
filterTableContent
@POST @Path("FilterTable") @RedirectToInternalJsp("mydb.jsp") @LowestRoleAccess(READER) public void filterTableContent(MyDBWebRequestContext context)
-
editConnection
@GET @Path("ConnectionSetting") @RedirectToInternalJsp("connectionSettings.jsp") @LowestRoleAccess(value=ADMIN, onError=@RedirectTo("Main")) public void editConnection(MyDBWebRequestContext context)
-
saveConnection
@POST @Path("UpdateConnection") @RedirectToInternal("{nextView}") @LowestRoleAccess(value=PUBLISHER, onError=@RedirectTo("Main")) public void saveConnection(MyDBWebRequestContext context)
-
-