ItEr49S04ValidacionEProbasFuncionaisItEr48S04: [Bug #358] Added button "Save & Continue" to advance types edition.
This commit is contained in:
parent
e059129069
commit
2424bd5a8a
3 changed files with 18 additions and 5 deletions
|
|
@ -158,11 +158,10 @@ public class AdvanceTypeCRUDController extends GenericForwardComposer {
|
|||
return newConstraint;
|
||||
}
|
||||
|
||||
public void save() {
|
||||
private void save() {
|
||||
try {
|
||||
advanceTypeModel.save();
|
||||
messagesForUser.showMessage(Level.INFO, _("Advance type saved"));
|
||||
goToList();
|
||||
} catch (ValidationException e) {
|
||||
messagesForUser.showInvalidValues(e);
|
||||
}
|
||||
|
|
@ -252,4 +251,13 @@ public class AdvanceTypeCRUDController extends GenericForwardComposer {
|
|||
return advanceTypeModel.getPercentage();
|
||||
}
|
||||
|
||||
public void saveAndExit() {
|
||||
save();
|
||||
goToList();
|
||||
}
|
||||
|
||||
public void saveAndContinue() {
|
||||
save();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -65,9 +65,12 @@
|
|||
</tabpanels>
|
||||
</tabbox>
|
||||
|
||||
<button onClick="controller.save();"
|
||||
<button onClick="controller.saveAndExit();"
|
||||
label="${arg.save_button_label}"
|
||||
sclass="save-button global-action"/>
|
||||
<button onClick="controller.saveAndContinue();"
|
||||
label="${arg.save_and_continue_button_label}"
|
||||
sclass="save-button global-action"/>
|
||||
<button onClick="controller.cancel();"
|
||||
label="${arg.cancel_button_label}"
|
||||
sclass="cancel-button global-action" />
|
||||
|
|
|
|||
|
|
@ -34,9 +34,11 @@
|
|||
<vbox id="messagesContainer"></vbox>
|
||||
<list top_id="listWindow" />
|
||||
<edition top_id="createWindow" title="${i18n:_('Create new advance type')}"
|
||||
save_button_label="${i18n:_('Save')}" cancel_button_label="${i18n:_('Cancel')}" />
|
||||
save_button_label="${i18n:_('Save')}" cancel_button_label="${i18n:_('Cancel')}"
|
||||
save_and_continue_button_label="${i18n:_('Save & Continue')}" />
|
||||
<edition top_id="editWindow" title="${i18n:_('Edit advance type data')}"
|
||||
save_button_label="${i18n:_('Save')}" cancel_button_label="${i18n:_('Cancel')}" />
|
||||
save_button_label="${i18n:_('Save')}" cancel_button_label="${i18n:_('Cancel')}"
|
||||
save_and_continue_button_label="${i18n:_('Save & Continue')}" />
|
||||
<window visible="@{controller.confirmingRemove}"
|
||||
id="confirmRemove" title="${i18n:_('Confirm')}" sizable="true"
|
||||
position="center">
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue