Skip to content

Instantly share code, notes, and snippets.

🎖
Never Quit

Arun Jacob jakes2255

🎖
Never Quit
Block or report user

Report or block jakes2255

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View callback.js
function first(temp,callBack){
setTimeout(function(){
console.log(temp);
callBack();
},500);
//callBack();
}
function second(){
console.log(2);
}
View test.py
if(itemNumber == 0):
mailSubject = itemDetails
View test.py
sign_content ="<br/>"+"Thanks,"+"<br/>"+"Jakes"
View test.py
#Open the file and pass data to be written.
file1 = open(completeName, "w")
toFile = "SCN: Questions of the Day!"+\
"\n"+"**************************""\n"
file1.write(toFile)
View test.py
# loop for retrieving div tags
for eachDiv in divs:
hrefS = re.findall(r'title=(.*?)>', str(eachDiv))
for hRef in hrefS: # loop for retrieving only titles in the relevent divs
print(hRef)
View model.js
onPressAdd: function () {
//retrive model using helper function in base class
var oJsonModel = this.getMyModel("Results");
//create an additional node to be added to the model
var additional_props = {
"organization": "SAP",
"place": "Bangalore"
};
//add the new node to the current model
oJsonModel.setProperty("/address",additional_props);
@jakes2255
jakes2255 / controller.js
Created Aug 22, 2019
Custom Controller
View controller.js
sap.ui.define([
"sap/ui/core/mvc/Controller"
], function (Controller) {
"use strict";
return Controller.extend("com.demo.ZDemo_CustomPath.controller.Display", {
onInit: function () {
}
});
View index.html
<!DOCTYPE html>
<html>
<head>
<script
src="https://openui5.hana.ondemand.com/resources/sap-ui-core.js"
id="sap-ui-bootstrap"
data-sap-ui-theme="sap_bluecrystal"
data-sap-ui-libs="sap.m"
data-sap-ui-xx-bindingSyntax="complex">
</script>
@jakes2255
jakes2255 / index.js
Created Jul 25, 2019
My Custom NPM package
View index.js
module.exports = function(string) {
if(typeof string !== "string") throw new TypeError("Plesae enter a string value!");
return string.replace(/\s/g,"");
};
@jakes2255
jakes2255 / router.html
Created Jul 22, 2019 — forked from joakimbeng/router.html
A really simple Javascript router
View router.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Building a router</title>
<script>
// Put John's template engine code here...
(function () {
// A hash to store our routes:
You can’t perform that action at this time.