Advertisement
ignatov

Untitled

May 25th, 2020
422
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.         var oRenderer = sap.ushell.Container.getRenderer("fiori2");
  2.             oRenderer.setHeaderTitle("SID[client] of ABAP System");
  3.  
  4.             sap.ushell.Container.getRenderer("fiori2").addActionButton("sap.m.Button", {
  5.                 id: "tstBtn",
  6.                 text: "Push the Button",
  7.                 icon: "sap-icon://BusinessSuiteInAppSymbols/icon-face-very-happy",
  8.                 press: function(oEvent) {
  9.                     MessageToast.show(oEvent.getSource().getId() + " pressed");
  10.                 }
  11.             }, true, true);
  12.  
  13.             var oRenderer = sap.ushell.Container.getRenderer("fiori2");
  14.             var oEntry = {
  15.                 title: "Customer Customizing Options",
  16.                 icon: "sap-icon://BusinessSuiteInAppSymbols/icon-face-astonished",
  17.                 value: function() {
  18.                     return jQuery.Deferred().resolve("current Settings state");
  19.                 },
  20.                 content: function() {
  21.                     return jQuery.Deferred().resolve(new sap.m.Button("userPrefEntryButton", {
  22.                         text: "Button"
  23.                     }));
  24.                 },
  25.                 onSave: function() {
  26.                     return jQuery.Deferred().resolve();
  27.                 }
  28.             };
  29.             oRenderer.addUserPreferencesEntry(oEntry);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement