Skip to content

Instantly share code, notes, and snippets.

View sodogan's full-sized avatar
💭
I am waiting for contributions for SAPUI5

Solen Dogan sodogan

💭
I am waiting for contributions for SAPUI5
View GitHub Profile
//declare a function type
type inbound = (val1:number,val2:number)=>number;
//function with callback
function operation(val1:number,val2:number,callback:(num1:number,num2:number)=>number):number{
return callback(val1,val2);
}
let multiplication = operation(15,3,(value1,value2)=>value1*value2);
CLASS lhc_buffer DEFINITION.
* 1) define the data buffer
PUBLIC SECTION.
TYPES: BEGIN OF ty_buffer.
INCLUDE TYPE ztbooking_xxx AS data.
TYPES: flag TYPE c LENGTH 1,
END OF ty_buffer.
TYPES tt_bookings TYPE SORTED TABLE OF ty_buffer WITH UNIQUE KEY booking.
const characters = [
{
name: "Luke Skywalker",
height: 172,
mass: 77,
eye_color: "blue",
gender: "male",
},
{
name: "Darth Vader",
class zcl_test_bobf_query definition
public
final
create public .
public section.
interfaces if_oo_adt_classrun .
class-methods:class_contructor.
methods:constructor.
protected section.
CLASS zcl_sodogan_data_generator DEFINITION
PUBLIC
FINAL
CREATE PUBLIC .
PUBLIC SECTION.
TYPES: tt_atrav TYPE STANDARD TABLE OF zrap_atrav_1507 WITH EMPTY KEY.
INTERFACES if_oo_adt_classrun .
PROTECTED SECTION.
PRIVATE SECTION.
sap.ui.define([
"sap/ui/core/Control",
"sap/m/InputBase",
"sap/m/Button",
"sap/m/ButtonRenderer"
], function (Control, InputBase, Button) {
"use strict";
return Button.extend("com.sodogan.manage_products.control.CustomButton", {
sap.ui.define([
"sap/ui/core/Control",
"sap/m/RatingIndicator",
"sap/m/Button"
], function (Control, RatingIndicator, Button) {
"use strict";
return Control.extend("com.sodogan.manage_products.control.ProductRate", {
/*
* Copyright (C) 2009-2019 SAP SE or an SAP affiliate company. All rights reserved.
*/
sap.ui.define([
"sap/m/MessageBox",
"sap/m/MessageToast",
"sap/m/BusyDialog",
"sap/ui/core/message/Message",
"sap/m/MessagePopover",
"sap/m/MessagePopoverItem"
//learning Qunit testing in here!
sap.ui.define([
"com/sodogan/manage_products/test/unit/helper/FakeI18nModel",
"sap/ui/model/resource/ResourceModel",
"sap/ui/base/ManagedObject",
"com/sodogan/manage_products/model/formatter",
"sap/ui/thirdparty/sinon",
"sap/ui/thirdparty/sinon-qunit"
], function (FakeI18nModel, ResourceModel,ManagedObject, formatter) {
"use strict";
sap.ui.define(
[
"sap/ui/base/ManagedObject",
"sap/ui/core/mvc/Controller",
"sap/ui/demo/todo/controller/App.controller",
"sap/ui/model/json/JSONModel",
"sap/base/Log",
],
function (ManagedObject, Controller, AppController, JSONModel, Log) {
"use strict";