@Controller(xpageName="shoppingcart",
pageTitleProperty="shoppingcart.myshoppingCart.pageTitle",
pagePathProperty="shoppingcart.myshoppingCart.pagePathLabel")
public class ShoppingCartApp
extends fr.paris.lutece.portal.util.mvc.xpage.MVCApplication
| Modifier and Type | Field and Description |
|---|---|
static String |
DATASTORE_KEY_URL_BACK
Datastore key of the URL to redirect the user to after the validation of
its shopping cart
|
static String |
DEFAULT_PAGE_PATH_LABEL
Default page path label
|
static String |
DEFAULT_PAGE_TITLE
Default page title
|
| Constructor and Description |
|---|
ShoppingCartApp() |
| Modifier and Type | Method and Description |
|---|---|
fr.paris.lutece.portal.web.xpages.XPage |
doEmptyShoppingCart(javax.servlet.http.HttpServletRequest request)
Do empty the shopping cart of the current user
|
fr.paris.lutece.portal.web.xpages.XPage |
doRemoveItem(javax.servlet.http.HttpServletRequest request)
Do remove a shopping cart item
|
fr.paris.lutece.portal.web.xpages.XPage |
doValidateShoppingCart(javax.servlet.http.HttpServletRequest request)
Do validate a shopping cart with a validator specified in a request
parameter
|
fr.paris.lutece.portal.web.xpages.XPage |
getConfirmEmptyShoppingCart(javax.servlet.http.HttpServletRequest request)
Get the confirmation message before removing every items of a shopping
cart
|
fr.paris.lutece.portal.web.xpages.XPage |
getConfirmRemoveItem(javax.servlet.http.HttpServletRequest request)
Get the confirmation message before removing an item from the shopping
cart of the user
|
static String |
getHtmlViewMyShoppingCart(javax.servlet.http.HttpServletRequest request,
boolean bUsePortletTemplate)
Get the HTML code to display the content of the shopping cart of a user
|
static String |
getHtmlViewMyShoppingCart(javax.servlet.http.HttpServletRequest request,
boolean bUsePortletTemplate,
Map<String,Object> modelPrefilled)
Get the HTML code to display the content of the shopping cart of a user
|
fr.paris.lutece.portal.web.xpages.XPage |
getValidateShoppingCart(javax.servlet.http.HttpServletRequest request)
Get the validation form of the next validator for the shopping cart of
the user.
|
fr.paris.lutece.portal.web.xpages.XPage |
getViewMyShoppingCart(javax.servlet.http.HttpServletRequest request)
Returns the content of the shopping cart page.
|
protected fr.paris.lutece.portal.web.xpages.XPage |
getXPage(String strTemplate,
Locale locale,
Map<String,Object> model) |
protected fr.paris.lutece.portal.web.xpages.XPage |
getXPage(String strTemplate,
Locale locale,
Map<String,Object> model,
String strPageTitleProperty,
String strPagePathLabelProperty)
Returns a new XPage object with the content filled by a template using a
given model and for a given locale
|
addError, addError, addInfo, addInfo, download, download, fillCommons, getActionFullUrl, getActionUrl, getDefaultPagePath, getDefaultPageTitle, getLocale, getModel, getPage, getViewFullUrl, getViewUrl, getXPage, getXPage, getXPage, getXPageName, populate, redirect, redirect, redirect, redirect, redirectMessageBox, redirectView, responseJSON, responseXML, validateBean, validateBeanpublic static final String DEFAULT_PAGE_TITLE
public static final String DEFAULT_PAGE_PATH_LABEL
public static final String DATASTORE_KEY_URL_BACK
@View(value="myShoppingCart",
defaultView=true)
public fr.paris.lutece.portal.web.xpages.XPage getViewMyShoppingCart(javax.servlet.http.HttpServletRequest request)
request - The HTTP request@View(value="confirmRemoveItem")
public fr.paris.lutece.portal.web.xpages.XPage getConfirmRemoveItem(javax.servlet.http.HttpServletRequest request)
throws fr.paris.lutece.portal.service.message.SiteMessageException
request - The requestfr.paris.lutece.portal.service.message.SiteMessageException - The message to display@Action(value="removeItem") public fr.paris.lutece.portal.web.xpages.XPage doRemoveItem(javax.servlet.http.HttpServletRequest request)
request - The request@View(value="confirmEmptyShoppingCart")
public fr.paris.lutece.portal.web.xpages.XPage getConfirmEmptyShoppingCart(javax.servlet.http.HttpServletRequest request)
throws fr.paris.lutece.portal.service.message.SiteMessageException
request - The requestfr.paris.lutece.portal.service.message.SiteMessageException - A site message exception to display a site
message@Action(value="emptyShoppingCart") public fr.paris.lutece.portal.web.xpages.XPage doEmptyShoppingCart(javax.servlet.http.HttpServletRequest request)
request - The request@View(value="validateShoppingCart")
public fr.paris.lutece.portal.web.xpages.XPage getValidateShoppingCart(javax.servlet.http.HttpServletRequest request)
throws fr.paris.lutece.portal.service.message.SiteMessageException
request - The requestfr.paris.lutece.portal.service.message.SiteMessageException - If a site message needs to be displayed@Action(value="doValidateShoppingCart")
public fr.paris.lutece.portal.web.xpages.XPage doValidateShoppingCart(javax.servlet.http.HttpServletRequest request)
throws fr.paris.lutece.portal.service.message.SiteMessageException
request - The requestfr.paris.lutece.portal.service.message.SiteMessageException - If an error occurs during the validationpublic static String getHtmlViewMyShoppingCart(javax.servlet.http.HttpServletRequest request, boolean bUsePortletTemplate)
request - The requestbUsePortletTemplate - True to use the template of the my shopping
cart portlet, false to use the XPage template. If the HTML
will be displayed in another page, then the portlet template
should be usedpublic static String getHtmlViewMyShoppingCart(javax.servlet.http.HttpServletRequest request, boolean bUsePortletTemplate, Map<String,Object> modelPrefilled)
request - The requestbUsePortletTemplate - True to use the template of the my shopping
cart portlet, false to use the XPage template. If the HTML
will be displayed in another page, then the portlet template
should be usedmodelPrefilled - prefilled model use before add own dataprotected fr.paris.lutece.portal.web.xpages.XPage getXPage(String strTemplate, Locale locale, Map<String,Object> model, String strPageTitleProperty, String strPagePathLabelProperty)
strTemplate - The template to displaylocale - The locale to usemodel - The model containing parameters of the templatestrPageTitleProperty - The i18n property of the title of the pagestrPagePathLabelProperty - The i18n property of the page path labelgetXPage(String, Locale, Map)Copyright © 2014 Mairie de Paris. All rights reserved.