I have a page that takes ID as a URL parameter and uses it to get an object And displays data about it. On this page we got a model that contains the file upload component, so we can not use to save AJAX. Instead, we do this:
& lt; Rich: modalPanel domElementAttachment = "parent" id = "profilePanel" style class = "popup" resizeable = "false" moveable = "false" autosized = "true" Zindex = "200" top = "-10" & gt; & Lt; A4j: form enctype = "multipart / form-data" id = "profilePanelFormId" & gt; & Lt; Q: Box Title = "Edit Advocacy Profile" width = "width6x" wantFocus = "true" & gt; & Lt; S: div id = "profilePanelForm" & gt; & Lt; Rich: Messages provided = "# {messagesUtil.errorsExist}" /> & Lt; A4j: viewId = "/ panel / advocacy / advocateprofileEdit.xhtml" /> Include & lt; / S: div & gt; & Lt; H: Command button icon = "Cancel" instant = "true" value = "cancel" action = "# {advocateManager.cancelEditCommitment}" styleClass = "cancel button" tabindex = "100" /> & Lt; H: command button id = "save" value = "save" action = "# {advocateManager.saveCommitment}" styleClass = "submit" tabindex = "101" /> & Lt; / Q: box & gt; & Lt; / A4j: form & gt; & Lt; / Rich: modalPanel & gt; We populate parameters in such pages as:
& lt; Page view-id = "/ advocacy / advocateCommitmentView.xhtml" login-required = "true" & gt; & Lt; Param name = "confirmationCode" value = "# {advocateManager.commitmentId}" /> & Lt; / Page & gt; So far, the problem we are running is when a user is rewritten without the required ID parameter to cancel the click or URL. If the user again refreshes the page, then it throws errors because it does not have this key. Does anyone know how I can call my save method without having to use AJAX and then keep the URL parameter Or can I block the call and add the parameter back?
The at the end of the maintenance string? IncludeViewParams = true / P>
No comments:
Post a Comment