File tree Expand file tree Collapse file tree 1 file changed +26
-1
lines changed Expand file tree Collapse file tree 1 file changed +26
-1
lines changed Original file line number Diff line number Diff line change 451
451
452
452
}
453
453
) ;
454
+ if ( ! z2ui5 . Dirty ) { sap . ui . define ( "z2ui5/Dirty" , [ "sap/ui/core/Control" ] , ( Control ) => {
455
+ "use strict" ;
456
+ return Control . extend ( "z2ui5.Dirty" , {
457
+ metadata : {
458
+ properties : {
459
+ isDirty : {
460
+ type : "string"
461
+ } ,
462
+ }
463
+ } ,
464
+ setIsDirty ( val ) {
465
+ // var dirty = !!sap.z2ui5.oResponse.PARAMS?.DIRTY;
466
+ if ( sap . ushell ?. Container ) {
467
+ sap . ushell . Container . setDirtyFlag ( val ) ;
468
+ } else {
469
+ window . onbeforeunload = function ( e ) {
470
+ if ( val ) {
471
+ e . preventDefault ( ) ;
472
+ }
473
+ }
474
+ }
475
+ } ,
476
+ renderer ( oRm , oControl ) { }
477
+ } ) ;
478
+ } ) ; }
454
479
sap . ui . define ( "z2ui5/Timer" , [
455
480
"sap/ui/core/Control"
456
481
] , ( Control ) => {
1229
1254
} ) ;
1230
1255
}
1231
1256
</ script >
1232
- < abc /> </ body > </ html >
1257
+ < abc /> </ body > </ html >
You can’t perform that action at this time.
0 commit comments