...
EventToolbarGo: $akioma.osiv.saveRecordInDialogAndClose (self)
Info | ||
---|---|---|
| ||
New method added to generic-record-handling.js |
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
/*
* Used in EventToolbarGo Attribute for dialog Windows.
* Saves a record and closed the dialog
* Note: This is an alternative to SaveNewRecord which
* automatically saves the change, closes the dialog and
* opens the record in a new details window.
*/
akioma.osiv.saveRecordInDialogAndClose = function(self) {
console.log(self,'saveRecordInDialogAndClose');
var oBE = self.container.getLink('PRIMARYSDO:TARGET').controller;
//Find record and Save it
oBE.updateRecord({});
oBE.cleanSaveChangesOnceEvts();
oBE.addAfterSaveChangesOnceCallback(function(success){
// Close Dialogbox
if(success && self.container.controller && self.container.controller.close)
self.container.controller.close();
});
};
?? |