query stringlengths 9 14.6k | document stringlengths 8 5.39M | metadata dict | negatives listlengths 0 30 | negative_scores listlengths 0 30 | document_score stringlengths 5 10 | document_rank stringclasses 2
values |
|---|---|---|---|---|---|---|
functions init check local storage for the key (cities) if present, dynamically create buttons with then button label as the city save the city the user searched to local storage, but check local storage for that city first, don't add if already there | function init() {
// check local storage for the key (cities) if present
let citiesStorage = localStorage.getItem('cities');
if (citiesStorage) {
// loop through local storage and create buttons with the button label as the city
cities = JSON.parse(citiesStorage);
console.log(cities)... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function getLocalStorage(){\n cities = []\n for (i=0;i<localStorage.length;i++){\n cities.push(localStorage.getItem(\"City\"+[i+1]))\n }\n returnButtons()\n \n function returnButtons(){\n for(i=0;i<cities.length;i++){\n //append past search... | [
"0.79447615",
"0.7874252",
"0.7800545",
"0.77743155",
"0.77700716",
"0.76506263",
"0.76311654",
"0.76215726",
"0.760226",
"0.757678",
"0.75574195",
"0.7534917",
"0.74403876",
"0.74380934",
"0.7426247",
"0.73998886",
"0.7335709",
"0.7330807",
"0.73015374",
"0.72965044",
"0.729... | 0.8208594 | 0 |
An XOR linked list is a more memory efficient doubly linked list. Instead of each node holding next and prev fields, it holds a field named both, which is an XOR of the next node and the previous node. Implement an XOR linked list; it has an add(element) which adds the element to the end, and a get(index) which returns... | function XOR_list() {
return false;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function nodeSwap(head) {\n const tempNode = new LinkedList(0);\n tempNode.next = head;\n\n let prevNode = tempNode;\n while(prevNode.next !== null && prevNode.next.next !== null) {\n const firstNode = prevNode.next;\n const secondNode = prevNode.next.next;\n // prevNode -> firstNode -> secondNode -> ... | [
"0.60324776",
"0.5936128",
"0.5837535",
"0.5762686",
"0.5714121",
"0.569852",
"0.5680875",
"0.56459355",
"0.5628223",
"0.562465",
"0.56217146",
"0.5605562",
"0.55997384",
"0.55946064",
"0.55750096",
"0.55684155",
"0.55535024",
"0.55512214",
"0.55458736",
"0.55336046",
"0.5530... | 0.67116845 | 0 |
This function is to padding to 32 bit address | function addressPadding(value) {
var padding=66;
var n = value.length;
if(n!==padding)
{
paddingLength =66 -(n)
var zeroes = "0";
for (var i = 0; i < paddingLength-1; i++) { zeroes += "0"; }
return ("0x" + zeroes + value.substring(2,n));
}
return value;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function addressToBytes32(address) {\n return '0x000000000000000000000000' + address.substr(2);\n}",
"padding() {\n const offset = this.bb.__offset(this.bb_pos, 28);\n return offset ? this.bb.readUint16(this.bb_pos + offset) : 0;\n }",
"function leftPad(n, _size) {\n if (_size === void 0) { _size = ... | [
"0.6293572",
"0.6128292",
"0.60378814",
"0.5959547",
"0.5953963",
"0.58597916",
"0.58083487",
"0.58028185",
"0.5795125",
"0.5756024",
"0.5746823",
"0.5740622",
"0.56570005",
"0.56264055",
"0.56227684",
"0.56059456",
"0.55568045",
"0.5514658",
"0.5514658",
"0.55066335",
"0.549... | 0.65659124 | 0 |
Get the transactions for the address(topic2) from event log api | function getTransactions(topic2)
{
var eventLogAPIURL = "https://api.etherscan.io/api?module=logs&action=getLogs&fromBlock=0&toBlock=latest&address=0xb64ef51c888972c908cfacf59b47c1afbc0ab8ac&topic0=0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef&topic2=";
eventLogAPIURL = eventLogAPIURL... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async getTransactions (addr) {\n try {\n // Get transaction history for the address.\n const transactions = await this.bchjs.Electrumx.transactions(addr)\n if (!transactions.success) {\n throw new Error(`No transaction history could be found for ${addr}`)\n }\n\n // Sort the tran... | [
"0.6046653",
"0.5857834",
"0.57740104",
"0.5732905",
"0.5693939",
"0.55545",
"0.5499575",
"0.5447113",
"0.53975606",
"0.53975606",
"0.53419834",
"0.53039896",
"0.53039896",
"0.52918434",
"0.5262085",
"0.523219",
"0.51951283",
"0.51922077",
"0.51717424",
"0.51690763",
"0.51353... | 0.7977932 | 0 |
TO update the ranking details in AddressRanking Table | function updateRanking(ranking)
{
params = {
TableName: 'AddressRanking',
Item: ranking
};
dynamoDB.put(params, function(err, data) {
if (err) {
context.fail('ERROR: Dynamo failed: ' + err);
} else {
console.log('Dynamo Success: ' + JSON.stringify(data, null, ' '));
context.succ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function updateUserRank(arr) {\n arr.forEach(element => {\n User.updateOne({display_name:element.display_name}, {$set:{rank:element.rank}}, function(err, result) { // Updating the user's rank according to the his/her user's score\n if (err)\n console.log('error: ',err)\n })\n })\n... | [
"0.6605057",
"0.6575109",
"0.6423553",
"0.6295766",
"0.6127662",
"0.59594524",
"0.5832274",
"0.57981616",
"0.57659835",
"0.5704799",
"0.5668884",
"0.55785197",
"0.5561593",
"0.55592704",
"0.554494",
"0.55266744",
"0.5482353",
"0.5476076",
"0.54545563",
"0.544026",
"0.53926235... | 0.79819995 | 0 |
funnction to save song id to sessions storage | function saveSessionStorage(data) {
sessionStorage.setItem("songID", data);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"idTosessionStorage() {\n sessionStorage.setItem('movieId', this.$props.movie.id)\n }",
"function stashId(inid) {\n sessionStorage.setItem('productid', inid)\n}",
"function setSessionID(id) {\n if (typeof Storage !== \"undefined\") {\n sessionStorage.setItem(\"sessionID\", id);\n } els... | [
"0.72627133",
"0.6916393",
"0.69093436",
"0.68807614",
"0.68199086",
"0.67608356",
"0.67396224",
"0.6652535",
"0.6599695",
"0.6599695",
"0.6572486",
"0.652296",
"0.65007424",
"0.64705944",
"0.6459114",
"0.64376265",
"0.64213747",
"0.6398144",
"0.63917106",
"0.6387268",
"0.638... | 0.84907037 | 0 |
Checks for a match, if the rule matches the action is run, and returns the match result, not the acton return value. | actionable(action) {
const self = this;
return (rule, normalizedRule, parent) => {
const ruleIsAMatch = self.test(rule, normalizedRule);
if (ruleIsAMatch) {
action(rule, parent);
}
return ruleIsAMatch;
};
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function Event_CompareToAction(action)\n{\n\t//by default: no match event\n\tvar result = new Event_EventResult();\n\n\t//do not bother processing anything if it should be ignored\n\tif (__DESIGNER_CONTROLLER && __DESIGNER_CONTROLLER.IsIgnoredSimlink && __DESIGNER_CONTROLLER.IsIgnoredSimlink(action.SimLinkId))\n\t... | [
"0.59655654",
"0.5837043",
"0.55807054",
"0.54134345",
"0.53363824",
"0.5278179",
"0.5222801",
"0.51842564",
"0.51508677",
"0.511857",
"0.5049101",
"0.5030679",
"0.50146455",
"0.5000922",
"0.4998931",
"0.4961407",
"0.49499148",
"0.49443465",
"0.4935436",
"0.490924",
"0.490771... | 0.59887475 | 0 |
function bc_itemImg( 'Document', 'webdoc/doc.gif', '2', '144', 0 ); | function bc_itemImg( itemName, itemImg, index, itemValue, indent, imgMapClassSmall )
{
var s;
var i;
var hide = false;
if ( "hide" == itemName )
{
hide = true;
s = bc_html_hide;
itemName = "show";
}
else if ( hiddenItem )
{
s = bc_html_hiddenMenuItemStart;
}
else
{
s = bc_html_... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function TB_image() {\n\tvar t = this.title || this.name ;\n\tTB_show(t,this.href,'image');\n\treturn false;\n}",
"function image_display() {\r\n\r\n}",
"function getImageInfo() {\n\n}",
"function img(ref, lang_dependant){ return (!lang_dependant ? pack_grafico + \"img/un/\" + ref : pack_grafico + \"img/\" +... | [
"0.644276",
"0.6290808",
"0.6048561",
"0.6020095",
"0.6020095",
"0.60116285",
"0.6010981",
"0.59926647",
"0.5950308",
"0.5908788",
"0.5907162",
"0.5904305",
"0.5892991",
"0.585544",
"0.58382094",
"0.58188206",
"0.58122534",
"0.5802176",
"0.5796154",
"0.57919765",
"0.5780312",... | 0.66928107 | 0 |
Utility function used by addPageToHistory that generates a history key using current state variables. | function makePageHistoryKey( pageNum )
{
var newKey;
if ( undefined !== pageNum )
{
newKey = pageNum;
}
else
{
newKey = currentPageNum;
}
newKey += "_";
newKey += currentViewType;
newKey += "_";
if ( "" !== objFilter )
{
newKey += objFilter;
}
newKey += "_... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function makeStateKey(key){return key;}",
"function makeStateKey(key) {\n return key;\n}",
"function makeStateKey(key) {\n return key;\n}",
"function makeStateKey(key) {\n return key;\n}",
"function makeStateKey(key) {\n return key;\n}",
"function makeStateKey(key) {\n return key;\n}",
"... | [
"0.67720866",
"0.6574495",
"0.6574495",
"0.6574495",
"0.6574495",
"0.6574495",
"0.6574495",
"0.6574495",
"0.6574495",
"0.6574495",
"0.65493494",
"0.65493494",
"0.654415",
"0.6373577",
"0.6121932",
"0.6043251",
"0.6011824",
"0.598979",
"0.5894863",
"0.5668548",
"0.5665743",
... | 0.7333555 | 0 |
Generates a URL that can be used to fetch the page data associated with the current state. | function makeurl()
{
var url = class_baseUrl + "?func=ll&objAction=page&objID=" + virtual_containerId + "&page=" + currentPageNum + "&sort=" + class_sortColumn;
// add on the optional pieces
if ( containerSubType !== "" )
{
url += "&objType=" + containerSubType;
}
if ( filterValue !== "" )
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"url() {\n const params = {};\n\n if (this.options.start !== undefined) {\n params.start = this.options.start;\n }\n\n if (this.options.branch !== undefined) {\n params.branch = this.options.branch;\n }\n\n return this.options.urlBase + '?' + $.param(p... | [
"0.6075522",
"0.59503645",
"0.5930237",
"0.590837",
"0.590837",
"0.5894218",
"0.5849631",
"0.58086604",
"0.58031017",
"0.5800935",
"0.57998985",
"0.5757899",
"0.5731419",
"0.5730118",
"0.5728265",
"0.5722134",
"0.5710978",
"0.57016563",
"0.5692841",
"0.56826985",
"0.5664226",... | 0.6296018 | 0 |
The "Indeterminate Progress" popup image and wrapping DIV is initialized onload | function initPopup()
{
var theProgressDivStyle;
theProgressDiv = document.getElementById("progressPopupDiv");
if ( null !== theProgressDiv )
{
theProgressDivStyle = theProgressDiv.style;
theProgressDivStyle.visibility="visible";
theProgressDivStyle.display="none";
// Load up the prog... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function startLoadingPopupViewerScreen()\n{\n\t$(\"#popupViewerTabs\").block({ \n\t\tmessage: '<h1>Loading Visualizations...</h1>', \n\t\tborder: 'none', \n\t\tpadding: '15px', \n\t\tbackgroundColor: '#000', \n\t\t'-webkit-border-radius': '10px', \n\t\t'-moz-border-radius': '10px', \n\t\topacity: .5, \n\t\tcolor: ... | [
"0.69605356",
"0.6874854",
"0.6748726",
"0.6724135",
"0.6684606",
"0.6672481",
"0.6642587",
"0.66024685",
"0.659994",
"0.65931344",
"0.65841115",
"0.6572444",
"0.6569158",
"0.6554685",
"0.6535052",
"0.64755857",
"0.6434206",
"0.638762",
"0.6361248",
"0.6323876",
"0.63133234",... | 0.8100609 | 0 |
setPageDropDownValues This function is going to try and use the value being sent in to fill the dropdown. The source file needs to send in a list something like the following: setPageDropDownValues( '[ "25", "50", "75", "100", "125" ]' ) Exception will be thrown on error | function class_setPageDropDownValues( pageDropdownList )
{
var localPageDropdownList;
try
{
// eval the string block into an array list
localPageDropdownList = eval( pageDropdownList );
pageSizeArray = localPageDropdownList;
if ( pageSizeArray.length > 0 )
{
// Since the list i... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function appendPage(val){\n for(let i=1;i<=100/val;i++){\n $('#myPageSelect').append(`<option class=\"dropdown-item\" value=${i}>${i}</option>`)\n }\n }",
"function setPagesList (data) {\n $pageDropdown.html('');\n\n for (var v in data)\n $pageDropdown.append(... | [
"0.57968706",
"0.57918704",
"0.57843834",
"0.5729991",
"0.5599501",
"0.5435091",
"0.5394282",
"0.5362982",
"0.5336461",
"0.5334533",
"0.531931",
"0.5302243",
"0.52795744",
"0.5260062",
"0.52528006",
"0.52207774",
"0.5198642",
"0.5187806",
"0.5180785",
"0.5176222",
"0.51676667... | 0.7648416 | 0 |
Updates mUrl with a new value only if it currently has no value. | function writeOnceUrl( url )
{
if ( mUrl.length < 1 )
{
mUrl = url ;
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function updateURL(url)\n{\n if (localStorage[url] === undefined){\n localStorage[url] = \"0\";\n }\n if (isNaN(parseInt(localStorage[url]))){\n localStorage[url] = \"0\";\n }\n localStorage[url] = (parseInt(localStorage[url]) + 1) + \"\";\n}",
"function updateUrl() {\n urlRouter.... | [
"0.6340136",
"0.62376666",
"0.61691487",
"0.61318946",
"0.6041421",
"0.59998065",
"0.5959045",
"0.5891421",
"0.5869479",
"0.5850169",
"0.5775613",
"0.57446355",
"0.5736806",
"0.573063",
"0.57166964",
"0.56326807",
"0.56081927",
"0.56058484",
"0.5602782",
"0.5515026",
"0.55036... | 0.63031065 | 1 |
This function is used to conditionally set the HREF of the configure button. If mUrl is set, then the configure button takes on that URL; if mUrl is not set, then mUrl is set to the configure button's current HREF and the configure button retains its current HREF. | function setConfigUrl( Size )
{
var editConfiglink = document.getElementById( "ConfigLink" );
if( null !== editConfiglink )
{
writeOnceUrl( editConfiglink.href );
editConfiglink.href = mUrl;
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function setUrl(nextAnchor) {\n status.currentUrl = status.nextUrl || window.location.href;\n status.nextUrl = nextAnchor ? nextAnchor.attr('href') : $(options.link).attr('href');\n }",
"function populateContinueHref() {\n $(\".btn-continue\").attr(\"href\", getQueryParam(\"ur... | [
"0.62471145",
"0.60267764",
"0.56400496",
"0.56149733",
"0.54876125",
"0.5464727",
"0.5463971",
"0.5460447",
"0.53782845",
"0.5347551",
"0.5306915",
"0.5266436",
"0.5195241",
"0.51592743",
"0.51464516",
"0.5141799",
"0.5112585",
"0.5083303",
"0.50801533",
"0.50773925",
"0.506... | 0.67790776 | 0 |
TABLE ROW DEFINITION Basically just a struct of data with no methods. object constructor | function tableRow( dataId, subTypeStr, nameStr, linkStr, sizeStr, dateStr, dateReal, imgStr )
{
this.dataId = dataId;
this.type = subTypeStr;
this.typeName = '';
this.name = nameStr;
this.link = linkStr;
this.size = sizeStr;
this.date = dateStr;
this.datesort = dateReal;
this.imgStr = imgSt... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function Table() {\n\t this.columns = null; // written with the first row\n\t this.rows = [];\n\t }",
"function Data_row(obj) {\r\n // defaults\r\n this.studyid = get_info.studyid();\r\n this.exp_start = get_info.start();\r\n this.exp_end = \"incomplete\";\r\n this.time_start = \"NA\"... | [
"0.7442806",
"0.71446043",
"0.71409196",
"0.6917929",
"0.6903597",
"0.688847",
"0.67106825",
"0.6651517",
"0.6626737",
"0.6604943",
"0.65792394",
"0.65680444",
"0.65397495",
"0.65332294",
"0.65332294",
"0.6498452",
"0.6490646",
"0.6485875",
"0.64521885",
"0.641966",
"0.639881... | 0.73694205 | 1 |
COLUMN OBJECT DEFINITIONS To be instantiated and used to define columns in the detail view BrowseViewColumn is essentially a superclass for: checkBoxColumn typeColumn nameWthPrmtdCmdsColumn ("name with promoted commands column") sizeColumn dataidColumn dateColumn arbitraryColumn columnWithURL userColumnWithURL | function BrowseViewColumn()
{
OTAddProperty( this, "boolean", "isEnabled", true );
OTAddProperty( this, "boolean", "sort", false );
OTAddProperty( this, "boolean", "sortDirectionDesc", false );
OTAddProperty( this, "string", "colName", "unDefinedValue");
OTAddProperty( this, "string", "headerName", "" ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function nameWthPrmtdCmdsColumn()\r\n\t{\r\n\t\tthis.identifier = \"nameWthPrmtdCmdsColumn\";\r\n\t\tthis.SortComparitor = function(a, b)\r\n\t\t{\r\n\t\t\t//localecompare returns lowercase first alway, so we cant use it.\r\n\t\t\tif (a.namesort < b.namesort) {return -1;}\r\n\t\t\tif (a.namesort > b.namesort) {ret... | [
"0.6652368",
"0.6609583",
"0.63569486",
"0.63008577",
"0.63008577",
"0.6185992",
"0.6164335",
"0.611242",
"0.60537",
"0.5996932",
"0.5996478",
"0.5978468",
"0.5876496",
"0.58662707",
"0.58650494",
"0.5804796",
"0.58013827",
"0.5801034",
"0.57651234",
"0.5749377",
"0.57257515"... | 0.7604188 | 0 |
The following are "subclasses" of BrowseViewColumn: checkbox column | function checkboxColumn ()
{
this.identifier = "checkboxColumn";
this.SetHeaderParams( "", "browseListHeaderCheck" );
this.SetCellParams( "browseItemCheck" );
this.SetCellWidth( "1%" );
this.SetIsEnabled( !class_noMultiSelectButtons );
this.AddCellHeader = function( rowStruct, contents, cellCount )
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function BrowseViewColumn()\r\n\t{\r\n\t\tOTAddProperty( this, \"boolean\", \"isEnabled\", true );\r\n\t\tOTAddProperty( this, \"boolean\", \"sort\", false );\r\n\t\tOTAddProperty( this, \"boolean\", \"sortDirectionDesc\", false );\r\n\t\tOTAddProperty( this, \"string\", \"colName\", \"unDefinedValue\");\r\n\t\tOT... | [
"0.66642386",
"0.6560313",
"0.61114806",
"0.59819704",
"0.5875475",
"0.5798362",
"0.5771507",
"0.5714683",
"0.56218135",
"0.56072825",
"0.56043106",
"0.5562818",
"0.55332464",
"0.5511519",
"0.55081576",
"0.54872495",
"0.5455891",
"0.54451466",
"0.5417142",
"0.5395898",
"0.537... | 0.7500905 | 0 |
name and promoted commands column | function nameWthPrmtdCmdsColumn()
{
this.identifier = "nameWthPrmtdCmdsColumn";
this.SortComparitor = function(a, b)
{
//localecompare returns lowercase first alway, so we cant use it.
if (a.namesort < b.namesort) {return -1;}
if (a.namesort > b.namesort) {return 1;}
return 0;
};
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"get commands() {\n let commands = this._commands.reduce((commands, command) => ({\n ...commands,\n [command.name]: new EditorCommandAdaptor(command, this)\n }), {});\n return commands;\n }",
"_emitCommandsd() {\n const commands = [];\n\n for (const [cmd, { description }] of this.command... | [
"0.5835093",
"0.57704645",
"0.5761507",
"0.57046086",
"0.5674089",
"0.56703997",
"0.5611018",
"0.559333",
"0.5560348",
"0.55205363",
"0.54959875",
"0.54959875",
"0.54959875",
"0.54959875",
"0.54959875",
"0.54959875",
"0.54959875",
"0.54959875",
"0.54959875",
"0.5465055",
"0.5... | 0.6510562 | 0 |
getOptionalParams only applies to containers returns an empty string if thisRow.container is not true. Otherwise, returns viewType and sort parameters to be added to the end of a URL query string. The return string begins with '&' Called by makeRowNameCell() below. Some things to consider &viewType=n needs to be append... | function getOptionalParams( thisRow )
{
var optionalParams = "";
// By getting the row number in, check to see if the object is a container.
// if not then dont add anything. Only containers need the page and view information
if ( undefined !== thisRow && true === thisRow.container )
{
if ( class... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"queryParams(params) {\n this.table = $('#searchtable');\n var options = this.table.bootstrapTable('getOptions');\n console.log('table opts', options);\n console.log('parmas', params);\n\n // this is necessary to ensure the backend has the validated API parameters it needs\n ... | [
"0.562684",
"0.5594378",
"0.5406748",
"0.5231544",
"0.51621234",
"0.5127407",
"0.5055903",
"0.4969173",
"0.49500215",
"0.49161226",
"0.48911667",
"0.4857744",
"0.47695974",
"0.47358537",
"0.4733167",
"0.47151548",
"0.47050583",
"0.46965462",
"0.46930566",
"0.46743816",
"0.467... | 0.81455946 | 0 |
Returns an string containing the HTML that should be inserted into the "Name" column for thisRow. It is an tag wrapped by a and includes the function menu by calling fn_MenuStr(). | function makeRowNameCell( thisRow, rowNo )
{
var outputStr = "";
if ( thisRow.link.length > 0 )
{
outputStr += "<A href=\"" + thisRow.link + getOptionalParams( thisRow ) + "\" class=\"browseItemNameContainer\">" + thisRow.name + "</a> " + fn_MenuStr( '', '', thisRow.dataId, '', imgSrc, LocString( 'Func... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"name() {\n if (arguments.length >= 1) {\n name = arguments[0];\n if (arguments.length === 2) {\n origName = arguments[1];\n } else {\n origName = name;\n }\n return column;\n }\n ... | [
"0.63283116",
"0.5977332",
"0.59613675",
"0.5764861",
"0.57417643",
"0.57411546",
"0.5695158",
"0.56709516",
"0.56546783",
"0.5643257",
"0.56248045",
"0.5548903",
"0.5521866",
"0.54408467",
"0.54356474",
"0.5428369",
"0.5398985",
"0.53989094",
"0.5390358",
"0.5380509",
"0.537... | 0.7613803 | 0 |
Returns a string containing HTML that creates a clickable small icon for the item. | function makeSmallIconLink( thisRow )
{
var status;
var outputStr = "";
var statusName = "";
var statusExists = false;
var ahref = "<A CLASS=\"browseViewIcon\" HREF=\"" + thisRow.link + getOptionalParams( thisRow ) + "\" TITLE=\"" + thisRow.typeName + "\">";
var ahrefClose = "</A>";
var imgCu... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function createHTMLString(item) {\r\n return `\r\n <li class=\"item\">\r\n <img src=\"${item.image}\" alt=\"${item.type}\" class=\"item__thumbnnail\">\r\n <span class=\"item__desctiption\">${item.gender}, ${item.size}</span>\r\n </li>\r\n `;\r\n}",
"_createIconHtml(iconName) {\n retu... | [
"0.64202464",
"0.6385812",
"0.6377125",
"0.63698465",
"0.62941575",
"0.60799587",
"0.60504425",
"0.60421616",
"0.60354",
"0.6001725",
"0.5979727",
"0.5973413",
"0.5968683",
"0.5952952",
"0.59432054",
"0.5939247",
"0.5934715",
"0.59058136",
"0.5880815",
"0.58747864",
"0.586906... | 0.6485954 | 0 |
Sets the innerHTML of the cell with ID ( 'browseCatalog_' + thisRow.dataId ) with a text link and function menu for the item. This executes only if thisRow.catalog == '1'. Whereas the above functions generate HTML strings, this function actually manipulates the DOM. | function updateFeaturedItemCell( thisRow )
{
if ( '1' === thisRow.catalog )
{
var theCell = document.getElementById('browseCatalog_' + thisRow.dataId );
if ( null !== theCell )
{
// populate the Cells
if ( thisRow.link.length > 0 )
{
theCell.innerHTML = "<A href='" + thisRow.lin... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function loadInformation() {\n \n var tdText =\n '<div class=\"container\"> <a href=\"' + item.link + '\" ><img class=\"img-food\" src=\"' + item.image + '\" class=\"image\" > <div class=\"overlay\"><div class=\"text\">' + item.name + ' <br> Price: $' + item.price + ' <br> Rating: ' + item.rating... | [
"0.5209135",
"0.518909",
"0.5156866",
"0.51112944",
"0.50999355",
"0.50565284",
"0.4968255",
"0.49150676",
"0.49142358",
"0.4903958",
"0.4902915",
"0.48971304",
"0.48960212",
"0.48619238",
"0.48318386",
"0.48296005",
"0.48260635",
"0.48033565",
"0.47981057",
"0.47815907",
"0.... | 0.7005974 | 0 |
Changes the current viewtype. newType must be of one of the following integer values: 1 Details View 2 Large Icon View 3 Small Icon View Also calls to the server to indicate that the view type has changed, and logs the change in the browser history via addPageToHistory(). The view change is done entirely clientside, th... | function class_updateViewType( newType )
{
var theDiv;
var theTopRow;
var theBottomRow;
var theViewIcon;
var theViewIconName;
var imgsrcsel;
var imgsrc;
var changed = false;
try
{
if ( newType !== currentViewType )
{
divSeg = 0;
// indictate that the ViewType change... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function changeView(type) {\r\n\t//var orient = \"orientPortrait\";\r\n\tvar nodes = {};\r\n\tnodes.mapPane = dijit.byId(\"mapPane\");\r\n\tnodes.mapBox = dojo.byId(\"objContents\");\r\n\tnodes.dateArea = dojo.byId(\"dateArea\");\r\n\tnodes.printSettings = dojo.byId(\"printSettings\");\r\n\t//nodes.settings = dojo... | [
"0.629349",
"0.6131795",
"0.6110932",
"0.5788629",
"0.5688",
"0.559692",
"0.5570604",
"0.55672276",
"0.55587065",
"0.5397464",
"0.5351956",
"0.53185743",
"0.53039724",
"0.5302019",
"0.5298951",
"0.52859706",
"0.52682364",
"0.5258074",
"0.5226087",
"0.5226087",
"0.5193677",
... | 0.7650541 | 0 |
Changes an image's SRC attribute and the CURSOR style of its wrapping element. Used in addPagingFooter below. obj should be the parent of the IMG tag described by idName. Ususally a imageName the path to the image relative to the variable imgSrc idName the ID of the image element to change usePointer boolean describing... | function imageCell( obj, imageName, idName, usePointer )
{
var imgRef = document.getElementById( idName );
if ( undefined !== imgRef )
{
imgRef.src = imgSrc + imageName;
}
if ( true === usePointer )
{
obj.style.cursor = "pointer";
}
else
{
obj.style.cursor = "default";
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function swapImageSrc(objectId, alternateSrc, width, left, top) {\n var image = document.getElementById(objectId); //get the image\n \n image.src = \"../Images/\" + alternateSrc; //swap image\n \n //Adjust image width and location\n image.style.width = width;\n image.style.left = left + \"%\";... | [
"0.62405336",
"0.5733069",
"0.567084",
"0.55044186",
"0.5497012",
"0.5483754",
"0.5395369",
"0.5379669",
"0.53702116",
"0.5346143",
"0.5342514",
"0.5258757",
"0.5233663",
"0.5194496",
"0.5169584",
"0.5148094",
"0.5139976",
"0.5138389",
"0.5129114",
"0.51051086",
"0.51051086",... | 0.7623834 | 0 |
Puts focus in the "Go to Page" UI's textbox. Put in a separate function so that we can set a timeout in flipPagePick()...see comments in that function for details. | function setPagePickFocus()
{
var theCell = document.getElementById( 'pagePickEdit' );
if ( undefined !== theCell )
{
theCell.focus();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function flipPagePick()\r\n\t{\r\n\t\tvar theDiv;\r\n\t\tvar theStyle;\r\n\r\n\t\tvar theCell=document.getElementById('PickPageCell' );\r\n\t\tvar theActPick=document.getElementById('activatePickDiv' );\r\n\t\tvar theBrowsePick=document.getElementById('browsePickDiv');\r\n\r\n\t\t// With the opening of the bottom ... | [
"0.6611368",
"0.66069317",
"0.648429",
"0.64809346",
"0.64191973",
"0.6395488",
"0.6265446",
"0.6252422",
"0.61585635",
"0.61084336",
"0.609761",
"0.6096053",
"0.6096053",
"0.6081546",
"0.60596544",
"0.6053956",
"0.60449123",
"0.60400957",
"0.60192704",
"0.60080075",
"0.60054... | 0.70927227 | 0 |
Returns an HTML string for the Sort Indicator image for this column determines if the column is being sorted ascending or descending, or not at all. | function SortIndicatorGet( columnName )
{
var alt;
var retval = '';
var gif = '';
// check to see if the column name is in the sortColumn parameter
// this will handle the case of "name" & "-name". Taken directly from LES
if ( undefined !== class_sortColumn.match( columnName ) )
{
if ( ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function renderSortOptions(col, status, colname) {\n str = \"\";\n if (status == -1) {\n\n if (col == \"ccode\" || col == \"class\" || col == \"credits\" || col == \"start_period\" || col == \"end_period\" || col == \"study_program\" || col == \"tallocated\") {\n str += \"<span onclick='myT... | [
"0.6588979",
"0.65505266",
"0.6379132",
"0.63359714",
"0.63359714",
"0.6332297",
"0.6309338",
"0.6290819",
"0.6211545",
"0.62101877",
"0.62098324",
"0.6201833",
"0.6197785",
"0.6184191",
"0.6184191",
"0.6147034",
"0.60377765",
"0.60361576",
"0.5983801",
"0.5921081",
"0.589359... | 0.73763937 | 0 |
In the BigImage view style, if we have any big images to show the user, we first warn them. If they accept the warning, this function gets called, which recalls buildTableBigImage() with renderBigImages = true. | function setRenderBigImages()
{
renderBigImages = true;
class_buildTableBigImage();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function class_buildTableBigImageResize()\r\n\t{\r\n\t\tif ( currentViewType === '2' )\r\n\t\t{\r\n\t\t\tclass_buildTableBigImage();\r\n\t\t}\r\n\t}",
"function class_buildTableBigImage()\r\n\t{\r\n\t\tvar\t\tcell;\r\n\t\tvar\t\thasViewChanged;\r\n\t\tvar\t\tinnerRow;\r\n\t\tvar\t\tinnertbl;\r\n\t\tvar\t\tinnert... | [
"0.6603095",
"0.59585285",
"0.58246046",
"0.57364404",
"0.5694364",
"0.5317807",
"0.5298371",
"0.5298371",
"0.5298371",
"0.52592474",
"0.5253314",
"0.5243649",
"0.5240751",
"0.5212304",
"0.51616883",
"0.5157374",
"0.5131854",
"0.5067546",
"0.5045819",
"0.5028326",
"0.5023194"... | 0.6616065 | 0 |
Called on resize so that we can reflow the table if the current view style is BigImage. The reflow is actually a regeneration of the entire table. | function class_buildTableBigImageResize()
{
if ( currentViewType === '2' )
{
class_buildTableBigImage();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"onResize() {\n clearTimeout(this._updateTimer);\n this._updateTimer = setTimeout(this.resizeTable, 16);\n }",
"function forceRecalculateTableSize() {\r\n $(\"body\").trigger(\"resize\");\r\n }",
"function resizeTable(){\n var containingWidth = $('.datagridcol').width();\n ... | [
"0.72442544",
"0.7061979",
"0.6948872",
"0.6611985",
"0.6609381",
"0.65162414",
"0.64479816",
"0.64054435",
"0.6404732",
"0.63660705",
"0.6352303",
"0.6322257",
"0.62771326",
"0.6276847",
"0.62456363",
"0.6231873",
"0.62225246",
"0.6209453",
"0.61902493",
"0.6173774",
"0.6151... | 0.7641356 | 0 |
Sets the browseview table's display style to "block" | function class_showTablesNow()
{
var tbl = document.getElementById( "browseTableDefn2" );
if ( tbl != null )
{
var arrayPageSize;
var tblStyle = tbl.style;
tblStyle.display = "block";
if ( flashTableRefresh )
{
if ( totalPages !== currentPageNum )
{
// Cur... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function show() {\n that.row.style.display = 'block';\n }",
"function showSettingTable(){\r\n document.getElementById(\"setting_table\").style.visibility = \"visible\";\r\n}",
"function showTable(){\n document.getElementById('eat-table').style.visibility = \"visible\";\n}",
"function renderTa... | [
"0.59287924",
"0.5818825",
"0.5692208",
"0.56456786",
"0.5569653",
"0.5553908",
"0.55326086",
"0.552047",
"0.551249",
"0.55077595",
"0.54557014",
"0.54508805",
"0.54332656",
"0.5397421",
"0.5378707",
"0.5356987",
"0.5351298",
"0.5343248",
"0.53400666",
"0.532221",
"0.53181744... | 0.58954036 | 1 |
Called onload. Creates browse view buttons for underneath the browse view. Note that the buttons at the top of the browse view are created in a way similar to the Global Menus the WebLingo inserts the surround DIVs and JS calls to fn_MultiButtonPosition(). The bottom button row is created from scratch by this function ... | function class_drawBottomMultiButton()
{
var buttonType;
var cell;
var innerHTMLStr;
var outerRow;
var row;
var tbl;
var innertbl;
var innertblBody;
var cellCount = 0;
if ( class_noMultiSelectButtons || ( class_bcMultiButtonArray.length === 0 ) )
{
layoutToolbar();
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function generateControlBar() {\n var result = doc.createElement(\"table\");\n result.setAttribute(\"class\", \"toolbar\");\n\n var tr = doc.createElement(\"tr\");\n \n/* @@ Add in later -- not debugged yet \n var sparqlButtonDiv = doc.createElement(\"td\");\n ... | [
"0.642934",
"0.62292355",
"0.60721475",
"0.6049798",
"0.6025534",
"0.59743243",
"0.5958246",
"0.59557295",
"0.5908331",
"0.58563906",
"0.58537066",
"0.58531743",
"0.5816766",
"0.5802",
"0.57849336",
"0.5772328",
"0.57693374",
"0.5735723",
"0.57330334",
"0.57318425",
"0.571390... | 0.6598159 | 0 |
Does a sort of the current browse view by finding the BrowseViewColumn object referred to by the global sortColumn and calling class_sortTableCol on that object. | function sortTable()
{
var j;
var column = 1;
var columnFound = false;
try
{
changeSort = false;
for ( j = 0; j < class_columnDefinitionArray.length; j++ )
{
if ( undefined !== class_sortColumn.match( class_columnDefinitionArray[j].GetColName() ) )
{
class_columnD... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function initializeColumnSort(tableColumn) {\n\n var sort = tableColumn.enhancedTable.sort;\n\n // Add the pointer style to the header element\n $(sort.element).css('cursor', 'pointer');\n\n $(sort.element).on(\"click\", function (e) {\n\n e.stopPropagatio... | [
"0.7216076",
"0.7062452",
"0.69837487",
"0.6814413",
"0.6725548",
"0.6654743",
"0.66487503",
"0.6562304",
"0.655248",
"0.64720446",
"0.6453648",
"0.6440767",
"0.6431312",
"0.6394125",
"0.6357813",
"0.6353519",
"0.63417923",
"0.632382",
"0.631724",
"0.62879646",
"0.62853146",
... | 0.7732587 | 0 |
This function is the onclick handler for the head for each row. colIdentifier is the variable name of the BrowseViewColumn object for which the header was clicked it is eval'ed to grab a reference to the column object, on which we call sortTableCol(). This function is basically a wrapper that allows us to call sortTabl... | function class_sortTableCol( headerClick, colIdentifier )
{
var i;
var obj = null;
try
{
for ( i = 0; i < class_columnDefinitionArray.length; i++ )
{
if ( class_columnDefinitionArray[i].identifier == colIdentifier )
{
obj = class_columnDefinitionArray[i];
}
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function onHeadigClick(that, cellIndex) {\n return function () {\n that.sortColumn(this, cellIndex);\n return false;\n };\n}",
"function createListenerCOL(rowid, col) {\n\tcol.onclick = function() {\n\t\tvar headerRow = document.getElementById(rowid);\n\t\tvar headerCols = headerRow.getElementsByTagName(... | [
"0.6916792",
"0.68050265",
"0.6780174",
"0.6560597",
"0.63495654",
"0.63341033",
"0.6288672",
"0.6185168",
"0.61412543",
"0.6124747",
"0.60478395",
"0.6038886",
"0.603865",
"0.60184234",
"0.60018057",
"0.5990597",
"0.591024",
"0.58684945",
"0.586214",
"0.5845117",
"0.5841679"... | 0.68315655 | 1 |
Puts focus in the cell currently being edited (see editRow below) | function setEditCellFocus()
{
var theCell = document.getElementById('editCell');
if ( null !== theCell )
{
theCell.focus();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function setCellFocus() {\n //[RC] - 2/27 - why we need this. Please discuss with me.\n //const colIndex = GridPreferencesHelper.getGridColumnIndex(grid, options.field);\n //const cell = grid.tbody.find(\"tr\").eq(rowIndex).find(\"td\").eq(colIndex);\n //... | [
"0.8515405",
"0.7238834",
"0.7238834",
"0.7238834",
"0.7238834",
"0.69965047",
"0.6983116",
"0.6939586",
"0.6873694",
"0.68563336",
"0.6776115",
"0.67500705",
"0.670614",
"0.670614",
"0.6646534",
"0.6633131",
"0.66130656",
"0.6603345",
"0.65788335",
"0.6561276",
"0.65121925",... | 0.8578871 | 0 |
Opens the given row for editing the name of the item. Creates a textbox with the current value and sets a timeout to setEditCellFocus(), which puts focus in the new textbox. The onkeypress handler for the textbox is set to cellEditEnter() to deal with finishing the edit. | function editRow(rowNo)
{
// Unused at the moment
var onKeyPressStr;
// if a row is currently being edited
if (rowEditing)
{
// cancel that change and then edit the new row
cancelChange();
editRow(rowNo);
}
// otherwise
else
{
killPopup();
// Only allow the edittin... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function editItem() {\r\n inputName.value = name;\r\n inputName.focus();\r\n isEditing = true;\r\n currentIndex = index;\r\n }",
"function enterEditState() {\n var row = $(this);\n var quantityCell = row.children('td.quantity');\n\n textInputField.val(quantityCell.text... | [
"0.6350514",
"0.63259614",
"0.61256254",
"0.6020142",
"0.5990644",
"0.5959359",
"0.5939869",
"0.5856706",
"0.5848935",
"0.5825223",
"0.58173305",
"0.5788566",
"0.5786358",
"0.57500523",
"0.57226384",
"0.57204473",
"0.5690873",
"0.5670495",
"0.5664975",
"0.5658393",
"0.5636290... | 0.6937385 | 0 |
Enables the cell with ID "filtercellid" for editing. | function filterRowCell()
{
// if a row is currently being edited
if (rowEditing)
{
// cancel that change and then edit the new row
cancelChange();
}
else
{
// Only allow the editting of the cell
// if it is marked as such
// set the flag
// get a reference to the Cell selec... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function updateFilter(){\n $(\"#visab-table\").tabulator(\"setFilter\", customFilter );\n }",
"toggleFilterRow() {\n if (this.settings.filterable) {\n this.element.find('.datagrid-filter-wrapper').hide();\n this.settings.filterable = false;\n this.filterRowRendered = false;\n this... | [
"0.5799012",
"0.5521076",
"0.5491287",
"0.5431627",
"0.5398675",
"0.5391495",
"0.5360168",
"0.5353642",
"0.53486395",
"0.53413844",
"0.530716",
"0.5287619",
"0.52829206",
"0.52378106",
"0.5210174",
"0.51607186",
"0.51607186",
"0.51328766",
"0.5121192",
"0.51050395",
"0.509841... | 0.68687737 | 0 |
Onkeypress handler for the cell currently being edited. If key pressed was enter, save the changes by calling saveChange(). If key pressed was escape, reset by calling resetRowContents(). Up arrow and down arrow can be used to edit an adjacent row. | function cellEditEnter( theForm, e )
{
// IE passes the char in event.keyCode, Mozilla in event.which
var c = ( e.charCode ) ? e.charCode : ( ( e.which ) ? e.which : e.keyCode );
c = (e.which) ? e.which : e.keyCode;
if ( c === 13 || c === 3 )
{
saveChange( editingRow );
return false;
}
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function editTextNum(e) {\n if (isFF) {\n // get the key code pressed\n var key = e.which;\n\n // if this is a backspace then process\n if (key == 8)\n return true;\n else if (key == 13) {\n //alert(\"You pressed the enter key\");\n editCurrent... | [
"0.70371854",
"0.701626",
"0.6984752",
"0.6787146",
"0.6787146",
"0.6787146",
"0.6787146",
"0.6787146",
"0.67609525",
"0.6753294",
"0.6723289",
"0.6723289",
"0.6723289",
"0.6723289",
"0.6722163",
"0.6644646",
"0.65853196",
"0.65825665",
"0.65631676",
"0.6479044",
"0.6428383",... | 0.7836966 | 0 |
function to save the changes made by an edit. Changes local data structures, calls resetRowContents() to put the new data in the field in a noneditable fashion, and calls UpdateNameOnObject() to tell the server about the change. | function saveChange(rowNo)
{
var updating = false;
if ( editingRow !== -1 && rowNo !== editingRow )
{
alert( "Unhandled problem: loc[1]" );
}
if ( rowEditing === true )
{
// get the updated value
var newValue = document.getElementById('editCell');
if ( class_myRows[rowNo].name ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function _saveLocalEdit() {\n\n // get changed vars\n var columnList = [];\n\n // changed names\n columnList.push({ column: \"playername\", value: firstname });\n columnList.push({ column: \"coachname\", value: coachname });\n columnList.push({ column: \"clubname\", value: clubname });\n\n // ... | [
"0.66587883",
"0.65027946",
"0.64121467",
"0.63927996",
"0.62866074",
"0.62269974",
"0.6184049",
"0.6159113",
"0.6129376",
"0.61290395",
"0.6077737",
"0.60431194",
"0.60404134",
"0.6018848",
"0.5978435",
"0.5976922",
"0.594006",
"0.59322655",
"0.5869879",
"0.58333194",
"0.580... | 0.6984798 | 0 |
If wantClickOffEdit is false (which is always the case unless a 3rd party changes it base Content Server installs never change it from its default false value) then we cancel the edit by calling resetRowContents(), othewise we save the change. | function cancelChange()
{
if ( editingRow !== -1 )
{
if ( wantClickOffEdit === true )
{
// get the updated value
var newValue = document.getElementById('editCell');
if ( null !== newValue )
{
if ( class_myRows[editingRow].name !== newValue.value )
{
saveChange(... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@action\n cancelEditRow() {\n set(this, 'isEditRow', false);\n }",
"cancelEdit() {\n this.handsontableData = JSON.parse(JSON.stringify(this.handsontableDataBackup));\n this.hot.loadData(this.handsontableData);\n this.hot.render();\n\n // Change edit mode on redux\n this.pr... | [
"0.7143148",
"0.67296106",
"0.66472507",
"0.6610502",
"0.65992266",
"0.65641755",
"0.6529059",
"0.6470326",
"0.64583284",
"0.64276946",
"0.64245087",
"0.6373139",
"0.6331048",
"0.63026553",
"0.6269964",
"0.6259657",
"0.6257431",
"0.6215729",
"0.62089384",
"0.62077343",
"0.618... | 0.7100793 | 1 |
This function notifies the server of a view type change, but does not supply a callback, since the server does not return any useful information. | function UpdateViewTypeToServer( newValue )
{
var url = class_baseUrl + "?func=ll.UpdateViewType&saveViewType=1&viewType=" + newValue + "&noGUI=true";
OTsendHTTPGetAjaxRequest( url );
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"_viewsChanged(newValue) {\n // ensure we have something and are not loading currently\n if (\n typeof newValue !== typeof undefined &&\n newValue !== \"\" &&\n !this.loading\n ) {\n // support going from a null element to a real one\n if (\n typeof this.viewsEndPoint === ty... | [
"0.6268495",
"0.60185224",
"0.59563565",
"0.58714336",
"0.584973",
"0.5840315",
"0.5830556",
"0.56974906",
"0.5607521",
"0.5589132",
"0.5571444",
"0.54821193",
"0.54521745",
"0.5410569",
"0.53940433",
"0.5391512",
"0.5387271",
"0.5375598",
"0.53453124",
"0.5343999",
"0.534168... | 0.6743239 | 0 |
This instantiable class represents the panels that can be added to the sidebar. ID is a required String parameter its value is used for the container's ID attribute. If it is not supplied, undefined is returned. Title is an optional string parameter that sets the text in the header of the panel. Imgsrc is an optional s... | function SidebarPanel(idOrExistingMarkup, title, imgsrc, contents)
{
var self = this;
if (typeof idOrExistingMarkup == "string")
{
var id = idOrExistingMarkup;
this.element = $(document.createElement("div"));
this.titleBar = $(document.createElement("div"));
this.titleDiv = $(document.createEl... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function PanelInstance(content, config) {\n\t\tthis.content = content;\n\n\t\tif( !config ) {\n\t\t\tconfig = {};\n\t\t}\n\n\t\t// Default any styles\n\t\tconfig.pos = config.pos || [0,0];\n\t\tconfig.width = config.width || (config.centered ? 400 : 'auto');\n\n\t\tthis.config = config;\n\t}",
"function DetailPa... | [
"0.6404198",
"0.6213882",
"0.6202711",
"0.60526454",
"0.59973073",
"0.5968227",
"0.5871079",
"0.5784443",
"0.57283163",
"0.5705608",
"0.568982",
"0.5646431",
"0.5636508",
"0.5630839",
"0.56258065",
"0.56069285",
"0.55731",
"0.5568577",
"0.556719",
"0.55669785",
"0.5534678",
... | 0.76005995 | 0 |
>> Crossfilter Logic >> Crossfilter printer for debugging | function print_filter(filter){
var f=eval(filter);
if (typeof(f.length) != "undefined") {}else{}
if (typeof(f.top) != "undefined") {f=f.top(Infinity);}else{}
if (typeof(f.dimension) != "undefined") {f=f.dimension(function(d) { return "";}).top(Infinity);}e... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function print_filter(filter){\n\t\t\tvar f=eval(filter);\n\t\t\tif (typeof(f.length) != \"undefined\") {}else{}\n\t\t\tif (typeof(f.top) != \"undefined\") {f=f.top(Infinity);}else{}\n\t\t\tif (typeof(f.dimension) != \"undefined\") {f=f.dimension(function(d) { return \"\";}).top(Infinity);}else{}\n\t\t\tconsole.lo... | [
"0.70327705",
"0.68215513",
"0.5937113",
"0.59257907",
"0.5925013",
"0.5925013",
"0.58322585",
"0.5569061",
"0.5477063",
"0.5379914",
"0.5297093",
"0.52824646",
"0.5275555",
"0.5255491",
"0.52483743",
"0.5219956",
"0.5197548",
"0.5194146",
"0.51921594",
"0.5174963",
"0.516697... | 0.70164186 | 1 |
Creates a new instance of the SharePointQueryable class | function SharePointQueryable(baseUrl, path) {
var _this = _super.call(this) || this;
_this._options = {};
_this._query = new collections_1.Dictionary();
_this._batch = null;
if (typeof baseUrl === "string") {
// we need to do some extra parsing to get the parent url c... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function _SharePointQueryable(baseUrl, path) {\n var _this = this;\n var url = \"\";\n var parentUrl = \"\";\n var query = new Map();\n if (typeof baseUrl === \"string\") {\n // we need to do some extra parsing to get the parent url correct if we are\n // be... | [
"0.64326257",
"0.6218993",
"0.57808465",
"0.56367373",
"0.56137246",
"0.5608897",
"0.56076777",
"0.56076777",
"0.56076777",
"0.5591193",
"0.55889815",
"0.5557843",
"0.55505526",
"0.5534098",
"0.5534098",
"0.55213207",
"0.5504591",
"0.5478337",
"0.5443368",
"0.5435827",
"0.542... | 0.6575886 | 0 |
Creates a new instance of the WebInfos class | function WebInfos(baseUrl, webPath) {
if (webPath === void 0) { webPath = "webinfos"; }
return _super.call(this, baseUrl, webPath) || this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"get webinfos() {\r\n return new WebInfos(this);\r\n }",
"get web() {\r\n return this.create(Web);\r\n }",
"get webs() {\r\n return new Webs(this);\r\n }",
"static fromUrl(url, path) {\r\n return new Web_1(extractWebUrl(url), path);\r\n }",
"function ciniki_web_info()... | [
"0.7942946",
"0.6452659",
"0.6108167",
"0.57453173",
"0.562998",
"0.5615555",
"0.5578061",
"0.5508114",
"0.54634273",
"0.543302",
"0.5422897",
"0.5314627",
"0.5290848",
"0.52850354",
"0.5224412",
"0.5178589",
"0.51457626",
"0.5125083",
"0.5117649",
"0.5110982",
"0.51008624",
... | 0.6935593 | 1 |
Creates a new instance of the PnPClientStorage class | function PnPClientStorage(_local, _session) {
if (_local === void 0) { _local = null; }
if (_session === void 0) { _session = null; }
this._local = _local;
this._session = _session;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function PnPClientStorage(_local, _session) {\r\n if (_local === void 0) { _local = null; }\r\n if (_session === void 0) { _session = null; }\r\n this._local = _local;\r\n this._session = _session;\r\n }",
"function PnPClientStorage(_local, _session) {\r\n if (_local === voi... | [
"0.69216794",
"0.69216794",
"0.63832617",
"0.6201285",
"0.6049282",
"0.60087544",
"0.60087544",
"0.6005423",
"0.5988013",
"0.59787744",
"0.59787744",
"0.59787744",
"0.59787744",
"0.59787744",
"0.5939852",
"0.5934521",
"0.5883685",
"0.58406794",
"0.58202183",
"0.5741915",
"0.5... | 0.69493884 | 0 |
Creates a new instance of the RoleAssignments class | function RoleAssignments(baseUrl, path) {
if (path === void 0) { path = "roleassignments"; }
return _super.call(this, baseUrl, path) || this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"get roleAssignments() {\r\n return new RoleAssignments(this);\r\n }",
"constructor() { \n BaseRole.initialize(this);RoleAssignmentAllOf.initialize(this);\n RoleAssignment.initialize(this);\n }",
"add(principalId, roleDefId) {\r\n return this.clone(RoleAssignments_1, `addroleas... | [
"0.741655",
"0.6364781",
"0.58618784",
"0.580683",
"0.56461024",
"0.5634322",
"0.54543155",
"0.53811747",
"0.5331818",
"0.5298858",
"0.5279987",
"0.5265486",
"0.5185404",
"0.51773727",
"0.5160013",
"0.5149943",
"0.5136383",
"0.51209545",
"0.5096087",
"0.49802607",
"0.4962354"... | 0.6733465 | 1 |
Creates a new instance of the RoleDefinitions class | function RoleDefinitions(baseUrl, path) {
if (path === void 0) { path = "roledefinitions"; }
return _super.call(this, baseUrl, path) || this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"get roleDefinitions() {\r\n return new RoleDefinitions(this);\r\n }",
"function createRoleManager(){\n\tvar baseUrl = getClientStore().baseURL;\n\tvar accessor = objCommon.initializeAccessor(baseUrl,cellName,\"\",\"\");\n\tvar objRoleManager = new _pc.RoleManager(accessor);\n\treturn objRoleManager;\n}... | [
"0.7236666",
"0.6150403",
"0.5910867",
"0.55451083",
"0.55272055",
"0.5380346",
"0.5283102",
"0.52576756",
"0.5246097",
"0.51892555",
"0.5184828",
"0.5177918",
"0.51350963",
"0.50461686",
"0.5039348",
"0.5033637",
"0.49726126",
"0.49543574",
"0.49535528",
"0.49306256",
"0.491... | 0.66299254 | 1 |
Creates a new instance of the RoleDefinitionBindings class | function RoleDefinitionBindings(baseUrl, path) {
if (path === void 0) { path = "roledefinitionbindings"; }
return _super.call(this, baseUrl, path) || this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"get bindings() {\r\n return new RoleDefinitionBindings(this);\r\n }",
"get bindings() {\n return SharePointQueryableCollection(this, \"roledefinitionbindings\");\n }",
"bind(key) {\n const binding = new binding_1.Binding(key.toString());\n this.add(binding);\n return bi... | [
"0.77303433",
"0.5745376",
"0.5211712",
"0.5184089",
"0.5167456",
"0.51456124",
"0.5099242",
"0.5099242",
"0.50607944",
"0.5035648",
"0.49394622",
"0.49225676",
"0.48653248",
"0.48626167",
"0.48509118",
"0.48050147",
"0.4797301",
"0.47697797",
"0.4749555",
"0.4749555",
"0.474... | 0.69437295 | 1 |
Gets the next order value 1 based for the provided collection | function getNextOrder(collection) {
if (collection.length < 1) {
return 1;
}
return Math.max.apply(null, collection.map(function (i) { return i.order; })) + 1;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function getNextOrder(collection) {\r\n if (collection.length < 1) {\r\n return 1;\r\n }\r\n return Math.max.apply(null, collection.map(i => i.order)) + 1;\r\n}",
"nextOrder() {\n if (!this.length) {\n return 1;\n }\n\n return this.last().get('order') + 1;\n }",
"nextOrder() {\n\... | [
"0.77062154",
"0.6876273",
"0.6717714",
"0.65896624",
"0.629472",
"0.58573484",
"0.5777078",
"0.56559396",
"0.5532856",
"0.55255085",
"0.5510567",
"0.5506925",
"0.55065376",
"0.55054736",
"0.5483466",
"0.5452782",
"0.5429851",
"0.5419601",
"0.53894323",
"0.53837657",
"0.53560... | 0.76262563 | 1 |
Gets an attribute value from an html string block | function getAttrValueFromString(html, attrName) {
var reg = new RegExp(attrName + "=\"([^\"]*?)\"", "i");
var match = reg.exec(html);
return match.length > 0 ? match[1] : null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function getAttrValueFromString(html, attrName) {\r\n // make the input safe for regex\r\n html = html.replace(/[.*+?^${}()|[\\]\\\\]/g, \"\\\\$&\");\r\n var reg = new RegExp(attrName + \"\\\\s*?=\\\\s*?(\\\"|')([^\\\\1]*?)\\\\1\", \"i\");\r\n var match = reg.exec(html);\r\n return match !== null &&... | [
"0.70985574",
"0.64837873",
"0.6445023",
"0.6357482",
"0.6357482",
"0.6357482",
"0.6357482",
"0.6357482",
"0.6357482",
"0.6357482",
"0.6357482",
"0.6357482",
"0.6357482",
"0.6293689",
"0.61813223",
"0.60481274",
"0.60481274",
"0.60426825",
"0.6042068",
"0.59861207",
"0.596141... | 0.71488154 | 0 |
Finds bounded blocks of markup bounded by divs, ensuring to match the ending div even with nested divs in the interstitial markup | function getBoundedDivMarkup(html, boundaryStartPattern, collector) {
var blocks = [];
if (typeof html === "undefined" || html === null) {
return blocks;
}
// remove some extra whitespace if present
var cleanedHtml = html.replace(/[\t\r\n]/g, "");
// find the first div
var startIndex... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"findFittable() {\n let startDepth = this.unplaced.openStart;\n for (let cur = this.unplaced.content, d = 0, openEnd = this.unplaced.openEnd; d < startDepth; d++) {\n let node = cur.firstChild;\n if (cur.childCount > 1)\n openEnd = 0;\n if (node.type.spec.isolating && openEnd <= d) {\n ... | [
"0.57636744",
"0.56653214",
"0.5498927",
"0.5392283",
"0.52820826",
"0.52603304",
"0.52392685",
"0.52274555",
"0.52274555",
"0.5195581",
"0.519206",
"0.51911616",
"0.515766",
"0.5153638",
"0.51056933",
"0.5087324",
"0.5054481",
"0.5050811",
"0.50450814",
"0.4967752",
"0.49543... | 0.6924325 | 0 |
Configure run mode of loadthemablestyles | function configureRunMode(mode) {
_themeState.runState.mode = mode;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"styles() { }",
"_LoadStyles() {\n // Loads a font and appends it to the head\n let AppendFont = (href) => {\n var elem = document.createElement('style');\n elem.setAttribute('type', 'text/css');\n elem.setAttribute('rel', 'stylesheet');\n elem.setAttribut... | [
"0.58580446",
"0.5848267",
"0.56579745",
"0.56579745",
"0.56579745",
"0.56579745",
"0.56579745",
"0.56259674",
"0.5572214",
"0.5571977",
"0.5571977",
"0.5567313",
"0.5500792",
"0.5500792",
"0.54895175",
"0.54567015",
"0.5440341",
"0.5397072",
"0.5375095",
"0.53091407",
"0.529... | 0.6506214 | 1 |
Creates a new instance of the SPRest class | function SPRest(options, baseUrl) {
if (options === void 0) { options = {}; }
if (baseUrl === void 0) { baseUrl = ""; }
this._options = options;
this._baseUrl = baseUrl;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function SPRest(_options, _baseUrl, _runtime) {\n if (_options === void 0) { _options = {}; }\n if (_baseUrl === void 0) { _baseUrl = \"\"; }\n if (_runtime === void 0) { _runtime = _pnp_common__WEBPACK_IMPORTED_MODULE_1__[\"DefaultRuntime\"]; }\n this._options = _options;\n this... | [
"0.7401785",
"0.7248397",
"0.7229489",
"0.6300881",
"0.62822783",
"0.6034671",
"0.58832735",
"0.57323605",
"0.5721972",
"0.56830895",
"0.5611553",
"0.5566649",
"0.54868907",
"0.5267443",
"0.51992166",
"0.5167938",
"0.5162993",
"0.51574117",
"0.51574117",
"0.5120503",
"0.50956... | 0.7316426 | 1 |
Creates a new instance of the RegionalSettings class | function RegionalSettings(baseUrl, path) {
if (path === void 0) { path = "regionalsettings"; }
return _super.call(this, baseUrl, path) || this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function Region() {\n this._init.apply(this, arguments);\n}",
"function createRegionTypes() {\n if (REGIONS == undefined) {\n REGIONS = {}\n }\n for (var rtype in REGIONS.metadata) {\n if (REGIONS.metadata.hasOwnProperty(rtype)) {\n var md = REGIONS.me... | [
"0.6363293",
"0.5530356",
"0.5489699",
"0.54692435",
"0.53871346",
"0.52916515",
"0.52916515",
"0.52916515",
"0.52916515",
"0.52916515",
"0.5278599",
"0.5276921",
"0.52632546",
"0.52632546",
"0.52632546",
"0.52632546",
"0.52632546",
"0.52433634",
"0.5235597",
"0.521875",
"0.5... | 0.6569711 | 0 |
Creates a new instance of the UserProfileQuery class | function UserProfileQuery(baseUrl, path) {
if (path === void 0) { path = "_api/sp.userprofiles.peoplemanager"; }
var _this = _super.call(this, baseUrl, path) || this;
_this.clientPeoplePickerQuery = new ClientPeoplePickerQuery(baseUrl);
_this.profileLoader = new ProfileLoader(baseUrl);
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"get profiles() {\r\n return this.create(UserProfileQuery);\r\n }",
"get myProperties() {\r\n return new UserProfileQuery(this, \"getmyproperties\");\r\n }",
"function createUserQuery(body) {\n return new User(body);\n}",
"function createUserProfile() {\n return {\n /* eslint-disable ... | [
"0.6732102",
"0.60904574",
"0.6078594",
"0.54412967",
"0.5340799",
"0.5313167",
"0.53048736",
"0.52398086",
"0.51973325",
"0.51543844",
"0.51493174",
"0.5140786",
"0.5137431",
"0.5135038",
"0.5096109",
"0.50631875",
"0.50228983",
"0.5021523",
"0.4987563",
"0.4956701",
"0.4948... | 0.7298012 | 0 |
Creates a new instance of the ProfileLoader class | function ProfileLoader(baseUrl, path) {
if (path === void 0) { path = "_api/sp.userprofiles.profileloader.getprofileloader"; }
return _super.call(this, baseUrl, path) || this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function Profile() {\n _classCallCheck(this, Profile);\n\n Profile.initialize(this);\n }",
"constructor () {\n this.hdrCubeLoader = new HDRCubeTextureLoader();\n this.gltfLoader = new GLTFLoader();\n this.fbxLoader = new FBXLoader();\n this.jsonLoader = new JSONLoader();\n this.textureLoade... | [
"0.7019549",
"0.58069575",
"0.5724528",
"0.5678891",
"0.5668394",
"0.5632968",
"0.5632968",
"0.5632968",
"0.5556073",
"0.5546573",
"0.55130506",
"0.5503387",
"0.5495357",
"0.5486726",
"0.545373",
"0.5390622",
"0.537907",
"0.53609115",
"0.53237516",
"0.5313334",
"0.5279012",
... | 0.664177 | 1 |
Reads a blob as text | function readBlobAsText(blob) {
return readBlobAs(blob, "string");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function readBlobAsText(blob) {\r\n return readBlobAs(blob, \"string\");\r\n}",
"function readAsBinaryString(blob, callback) {\n var reader = new FileReader();\n var hasBinaryString = typeof reader.readAsBinaryString === 'function';\n reader.onloadend = function (e) {\n var result = e.ta... | [
"0.83412355",
"0.7588424",
"0.74916136",
"0.7480161",
"0.7451944",
"0.7451944",
"0.7451944",
"0.7451944",
"0.73634356",
"0.73634356",
"0.73634356",
"0.73634356",
"0.73634356",
"0.73634356",
"0.73634356",
"0.73634356",
"0.73634356",
"0.73634356",
"0.73634356",
"0.73634356",
"0... | 0.8298969 | 1 |
Reads a blob into an array buffer | function readBlobAsArrayBuffer(blob) {
return readBlobAs(blob, "buffer");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function readBlobAsArrayBuffer(blob) {\r\n return readBlobAs(blob, \"buffer\");\r\n}",
"function blobToArrayBuffer(blob) {\n return new Promise(function (res, rej) {\n var reader = new FileReader();\n\n reader.onload = function (_event) {\n res(reader.result);\n };\n\n reader.onerror = funct... | [
"0.79952264",
"0.77507746",
"0.77484274",
"0.7665042",
"0.7665042",
"0.7665042",
"0.7665042",
"0.7462147",
"0.73800105",
"0.73800105",
"0.73800105",
"0.73800105",
"0.73800105",
"0.73800105",
"0.73800105",
"0.73800105",
"0.73800105",
"0.73800105",
"0.73800105",
"0.73800105",
"... | 0.79569554 | 1 |
helper function to get minimum weight edge with one end in visited and one end in unvisited | function minEdge(unvisited, visited, graph) {
let ret = null;
let min = Infinity;
// loop through each vertex in the visited set
visited.forEach((vertex) => {
let edges = graph[vertex]; // get the adjacent edges
// find the minimum among edges that go to an unvisited vertex
for(edge in edges) {
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"findMinSpanningTree() {\n let vertexCount = 0\n let weight = 0\n\n let current = this.g[0]\n current.visited = true\n vertexCount++\n\n while (vertexCount < this.g.length) {\n let smallest = null\n\n for (let i = 0; i < this.e.length; i++) {\n ... | [
"0.7541191",
"0.74046826",
"0.6935075",
"0.6641239",
"0.6590664",
"0.6590664",
"0.6590664",
"0.6590664",
"0.6590664",
"0.6572866",
"0.6416635",
"0.62008905",
"0.6195353",
"0.6188834",
"0.61759263",
"0.6121409",
"0.6092848",
"0.6044956",
"0.60388994",
"0.60388994",
"0.60388994... | 0.78219295 | 0 |
This function is related to init the Christchurch Map. | function initMap() {
map = new google.maps.Map(document.getElementById('map'), {
// Christchurch location
center: {lat: -43.532054, lng: 172.636225},
zoom: 12
});
infowindow = new google.maps.InfoWindow({});
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function initMap() {\n}",
"function init(){\n basemap();\n}",
"function initialize() {\n initMap();\n initMap2();\n initMap3();\n initMap4();\n initMap5();\n initMap6();\n initMap7();\n initMap8();\n initMap9();\n initMap10();\n initMap11();\n initMap12();\n initMap13();\n}",
"function initMa... | [
"0.6928473",
"0.6542874",
"0.6499196",
"0.6497174",
"0.635027",
"0.63050795",
"0.6272841",
"0.62409914",
"0.6197455",
"0.6164567",
"0.61560494",
"0.61277264",
"0.61194843",
"0.61006445",
"0.6086615",
"0.6085871",
"0.60826457",
"0.60742384",
"0.6051474",
"0.6033995",
"0.598049... | 0.727104 | 0 |
Update markers to visible if its title is in array. Otherwise remove visibility.google.maps.event.trigger(marker, 'click'); | function setVisible(array) {
markerList.forEach(function (marker) {
var title = marker.title;
if (array.indexOf(title) >= 0) {
marker.setVisible(true);
} else
marker.setVisible(false);
})
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function updateMapMarkers(locations) {\n hideMapMarkers();\n for (var i = 0; i < locations.length; i++) {\n for (var y = 0; y < markers.length; y++) {\n if (locations[i].title == markers[y].title) {\n markers[y].setVisible(true);\n\n }\n }\n }\n}",
"mar... | [
"0.7205811",
"0.69690216",
"0.6860217",
"0.68053836",
"0.6720447",
"0.67152685",
"0.67105174",
"0.6706383",
"0.6568867",
"0.6540329",
"0.6513864",
"0.6502676",
"0.6476988",
"0.64529866",
"0.64326644",
"0.63864034",
"0.63747984",
"0.6318816",
"0.6316307",
"0.6315263",
"0.62517... | 0.77880126 | 0 |
get single site sites/:site/continuation | getComscoreContinuation(site, continuationid, cb) {
let self = this;
dax.continuation(self.dax, site, continuationid, c, function(err, data) {
cb(null, data);
});
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"getComscoreSite(site, cb) {\n let self = this;\n dax.site(self.dax, site, c, function(err, data) {\n if (data === undefined) {\n cb(null, 'No continuation ids found');\n } else {\n cb(null, data);\n }\n });\n }",
"async functi... | [
"0.71582013",
"0.6068903",
"0.5778852",
"0.53430855",
"0.5241384",
"0.51203287",
"0.5104097",
"0.5001412",
"0.49336827",
"0.49314487",
"0.49293187",
"0.4901893",
"0.47909012",
"0.47908556",
"0.4755603",
"0.47497413",
"0.47356373",
"0.46989638",
"0.4691141",
"0.46845943",
"0.4... | 0.6543802 | 1 |
get the site config sites/:site/config | getSiteConfig(site, cb) {
let self = this;
let config = {
baseUrl: self.service,
uri: 'service.json',
json: true
};
request(config, (err, res, body) => {
if (err) cb(err);
for (let i = 0; i < body.services.length; i++) {
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function getWebsiteSettings(site){\n return websiteMap[site];\n}",
"function getConfig() {\n var currentHost = window.location.hostname;\n switch (currentHost) {\n case \"localhost\": return { apiBase: \"localhost:9000\", contentBase: currentHost, enviroment: Enviroment.Dev };\n //add addi... | [
"0.7235299",
"0.66286516",
"0.6551204",
"0.629516",
"0.62393904",
"0.61623514",
"0.61614287",
"0.6142153",
"0.59808356",
"0.58546495",
"0.57848793",
"0.57541597",
"0.5710808",
"0.56988657",
"0.569795",
"0.56853914",
"0.5670794",
"0.56532276",
"0.5628184",
"0.5624951",
"0.5618... | 0.7048045 | 1 |
Start the worker for the site selected /sites/:site/start | startSite(site, cb) {
let self = this;
if (self.workers[site]) {
cb(null, 'Already Running');
} else {
self.getSiteConfig(site, (err, options) => {
self.workers[site] = new Comscore(self.dax, self.s3, site, options, self.c);
self.workers[si... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function call_site_file( site ){\n\tpre_notif();\n\tchrome.tabs.executeScript( media.tab, { file: \"js/\"+ site +\".js\" }, function() {\n\t\tchrome.tabs.sendRequest( media.tab, { tab: media.tab, page_url: media.page_url, src_target: media.src_target }, function(response) {\n\t\t\tconsole.log( 'Call Site: Done' );... | [
"0.5739429",
"0.56833494",
"0.5568998",
"0.5549436",
"0.55349696",
"0.5472251",
"0.5453798",
"0.5383357",
"0.5336884",
"0.53168",
"0.52780354",
"0.5271351",
"0.52476317",
"0.52161115",
"0.5190269",
"0.51822674",
"0.51614594",
"0.5145599",
"0.51402897",
"0.51293963",
"0.510934... | 0.7420425 | 0 |
Restart the worker for the site selected /sites/:site/restart | resetSite(site, cb) {
let self = this;
//delete the remote file and create a new one
if (self.workers[site] !== undefined) {
self.workers[site].startNewDataStream();
cb(null, 'Restarted Worker');
} else {
self.getSiteConfig(site, (err, options) => {
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"restart() {}",
"function _restart() {\n process.nextTick(restart);\n}",
"Restart() {\n\n }",
"function restart (argv, cb) {\n var args = argv._;\n if (args.length === 0){\n return cb(restart.usage);\n }\n\n var appId = fhc.appId(args[0]);\n var deployTarget = ini.getEnvironment(argv);\n return... | [
"0.63829887",
"0.60351855",
"0.60175824",
"0.5949592",
"0.5943297",
"0.584849",
"0.5793957",
"0.5785055",
"0.57796586",
"0.57115054",
"0.5706225",
"0.5661688",
"0.5658581",
"0.5648178",
"0.56245303",
"0.5613019",
"0.5611042",
"0.5608118",
"0.5607491",
"0.5598778",
"0.55955625... | 0.6162866 | 1 |
Stop the worker for the site selected /sites/:site/stop | stopSite(site, cb) {
let self = this;
if (self.workers[site]) {
self.workers[site].stopTimer();
delete self.workers[site];
cb(null, 'Stopped');
} else {
cb(null, 'Already Stopped');
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"stopCurrentWork() {\n for (let i = 0; i < this._workers.length; i += 1) {\n const worker = this._workers[i];\n\n /** @type {MessageFromMasterToSlave} */\n const message = {\n type: \"stop\",\n };\n\n worker.postMessage(message);\n }\n }",
"function stopWorker(){\n\t\t\tw.te... | [
"0.68490803",
"0.68007916",
"0.6527371",
"0.6479791",
"0.64051145",
"0.62070966",
"0.6119101",
"0.6104073",
"0.6047033",
"0.60125995",
"0.6009729",
"0.5999078",
"0.59894484",
"0.5984279",
"0.5970672",
"0.59632504",
"0.5946299",
"0.59457886",
"0.5941555",
"0.5935847",
"0.58999... | 0.7865891 | 0 |
TASK : Move Css to pub, minify files | function cssTask(){
return src(files.cssPath)
.pipe(browserSync.stream())
.pipe(concatCss("css/main.css"))
.pipe(cleanCSS({compatibility: 'ie8'}))
.pipe(dest('pub')
);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function cssTask() {\n return src(files.cssPath)\n //conCat put the files togheter into a file with the name main.css\n .pipe(conCat('main.css'))\n .pipe(cssnano())\n .pipe(dest('pub/css'));\n}",
"function minсss() {\n // Folder with files to minify\n return src([... | [
"0.77431226",
"0.7326367",
"0.7233155",
"0.7097288",
"0.7088151",
"0.7013941",
"0.69441473",
"0.6926973",
"0.69224894",
"0.68811077",
"0.68790424",
"0.6840137",
"0.68320966",
"0.68312275",
"0.6821335",
"0.6801906",
"0.67899925",
"0.67713237",
"0.677023",
"0.6730273",
"0.67277... | 0.7761068 | 0 |
Sales.all=[]; let Seattle = new Sales('Seattle', 23, 65, 6.3); let Tokyo = new Sales('Tokyo', 3, 65, 1.2); let Dubai = new Sales('Dubai', 11, 38, 3.7); let paris = new Sales('paris', 20, 38, 2.3); let lima = new Sales('lima', 2, 16, 4.6); let place = [Seattle, Tokyo,Dubai,paris,lima]; | function Sales(shopName,min,max,avg){
this.shopName = shopName;
this.minCust = min;
this.maxCust = max ;
this.avgCookies= avg;
this.nOfCusts = [];
this.avgCookiesH = [];
this.total = 0;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function init_table_data(){\n var shop_1 = new Shop('1st and Pike', 23, 65, 6.3, '6am', '7pm');\n var shop_2 = new Shop('SeaTac Airport', 24, 33, 1.2, '6am', '8pm');\n var shop_3 = new Shop('Seattle Center', 11, 38, 3.7, '8am', '6pm');\n\n //create array to hold all shops\n shops = [shop_1, shop_2, shop_3];\n... | [
"0.63781327",
"0.63129026",
"0.6193676",
"0.6161187",
"0.61126834",
"0.60248405",
"0.6009896",
"0.6001267",
"0.59926635",
"0.5972702",
"0.5920986",
"0.59089196",
"0.59066343",
"0.5897488",
"0.5837804",
"0.5701586",
"0.5659777",
"0.56564415",
"0.5612207",
"0.5579741",
"0.55793... | 0.6391532 | 0 |
Quiz Intro Set interface according to user profile createUserProfile() | function createUserProfile() {
// Set question header text
$questionHeader.html($titles.introTitle);
// Disable form input autocomplete
$('form').attr('autocomplete', 'off');
// Hide all but first question
$userProfile.filter('h3').not(':first-child').hide();
$userAura.hide();
// Initialize birthday ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"makeIntroPage() {\n const { currentUser } = this.props;\n const isAdmin = !!currentUser && currentUser.userType === \"accountAdmin\";\n\n return (\n <div styleName=\"eval-portion-intro\" className=\"center\">\n <div>\n <div className=\"font24px\" st... | [
"0.6183369",
"0.616435",
"0.6050501",
"0.5996116",
"0.5993079",
"0.5976187",
"0.58662385",
"0.58507603",
"0.57573545",
"0.5672937",
"0.56528133",
"0.5649561",
"0.5628862",
"0.56280833",
"0.56078506",
"0.55985355",
"0.55936706",
"0.5578667",
"0.55570024",
"0.55443347",
"0.5540... | 0.732915 | 0 |
createDatePicker() Initialize and hide date picker widget | function createDatePicker() {
$datePicker = $('#datepicker');
$datePicker.datepicker({
changeMonth: true,
changeYear: true
});
$datePicker.hide();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function Datepicker() {}",
"function Datepicker() {}",
"function createDatePickerComponent() {\n $(\"#datepicker\").datepicker({\n format: \"yyyy-mm-dd\",\n language: \"fr\",\n autoclose: true,\n clearBtn: true,\n todayHighlight: true,\n todayBtn: \"linked\"\n })... | [
"0.7341121",
"0.7341121",
"0.7323593",
"0.7309629",
"0.715198",
"0.715198",
"0.6984682",
"0.68765634",
"0.683652",
"0.6798679",
"0.6706742",
"0.6703446",
"0.66760504",
"0.6651513",
"0.65807974",
"0.656199",
"0.656199",
"0.65563357",
"0.65520877",
"0.65520877",
"0.65520877",
... | 0.7864368 | 0 |
setUserZodiac() Display a profile picture based on user's zodiac sign | function setUserZodiac() {
// Process input from birthday date picker
$datePicker.change(function() {
// Retrieve selected date
let $date = $datePicker.datepicker('getDate');
// Set birthday according to date retrieved
$userBirthday = {
day: $date.getDate(),
month: $date.getMonth(),
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function showProfile(v){ \r\n //alert('showprofile: '+v);\r\n dispHeaderMode();\r\n document.getElementById('div_bar').style.display='block';\r\n var n = new Date().toLocaleTimeString('it-IT');\r\n var v_mphoto='main_gfx/avatar.png';\r\n \r\n if(DB_USER.length==0 || CURR_USER==null || CURR_USER==''){\r\n ... | [
"0.64617383",
"0.61364555",
"0.6083995",
"0.594888",
"0.58767164",
"0.5761531",
"0.5745288",
"0.57429343",
"0.57222563",
"0.5703659",
"0.5684892",
"0.56426895",
"0.56345886",
"0.5623876",
"0.5623876",
"0.5586302",
"0.55206674",
"0.5494893",
"0.5464418",
"0.5460701",
"0.544588... | 0.67028844 | 0 |
getZodiac() Determine zodiac sign according to user birthday and return result | function getZodiac() {
switch($userBirthday.month) {
case 0:
if ($userBirthday.day < 20) {
return 'capricorn';
} else {
return 'aquarius';
}
break;
case 1:
if ($userBirthday.day < 19) {
return 'aquarius';
} else {
return 'pisces';
}
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function displayZodiac() {\n // astrological sign variables:\n var aquarius = \"Aquarius <span class='unicodePad'>♒</span>\";\n var aries = \"Aries <span class='unicodePad'>♈</span>\";\n var cancer = \"Cancer <span class='unicodePad'>♋</span>\";\n var capricorn = \"Capric... | [
"0.73027545",
"0.68811786",
"0.674628",
"0.6594334",
"0.6054811",
"0.60126007",
"0.5819361",
"0.5539963",
"0.54667264",
"0.5438733",
"0.54133904",
"0.5410453",
"0.53173935",
"0.53043866",
"0.52764523",
"0.524246",
"0.52390885",
"0.5228353",
"0.5227396",
"0.5227396",
"0.516942... | 0.7460686 | 0 |
revealWelcome() Hide inspirational image and show sidebar with welcome message and user profile | function revealWelcome() {
// Keep progress bar hidden
$userProgress.hide();
// Hide welcome message initially
$welcomeText.hide();
$affirmation.hide();
$playButton.hide();
// Fade out inspirational image
setTimeout(function() {$introImage.fadeOut(function() {
// Then fade in sidebar displaying zod... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function showWelcome()\n {\n// switched off on client request\n//\tvar srcFile = \"../ModelPopup/WelcomeModal.aspx\";\t//COMDIFF: prepend \"../\"\n//\tvar cFrame = new Element('iframe').setProperties({id:\"yt-HelpContent\", height:'580px', width:'600px', frameborder:\"0\", scrolling:\"no\", src:srcFile}).injectIns... | [
"0.6748882",
"0.66798824",
"0.6608497",
"0.6552053",
"0.6537032",
"0.6500154",
"0.64689946",
"0.6404338",
"0.6394974",
"0.6370606",
"0.63615984",
"0.63416636",
"0.633558",
"0.63014114",
"0.62820125",
"0.62526995",
"0.61785144",
"0.6175896",
"0.6168825",
"0.61681116",
"0.61160... | 0.76988316 | 0 |
setUserStyle() Set quiz styling according to 'aura' colour picker value | function setUserStyle() {
// Update on color picker input
$userAura.change(function() {
// Save color picker value
let $theme = $userAura.val();
$appearSFX2.play();
// Set styling of question div and 'next' button according to color value
// (Class selector wasn't overriding default button styl... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function testChange () {\n if (rand_Q2.category === \"English\") {\n quotebox.style.color = \"blue\";\n } else if (rand_Q2.category === \"African\") {\n quotebox.style.color = \"red\";\n } else if (rand_Q2.category === \"Greek\") {\n quotebox.style.color ... | [
"0.6103294",
"0.6056322",
"0.6041576",
"0.5993751",
"0.59656864",
"0.58948976",
"0.5871813",
"0.58397996",
"0.5836116",
"0.5753231",
"0.5747138",
"0.5745384",
"0.5743674",
"0.5742055",
"0.574183",
"0.57357204",
"0.5714985",
"0.56902725",
"0.56844574",
"0.568351",
"0.5679693",... | 0.7222708 | 0 |
_onPressLogin: Login action, in which loginAction is called. | _onPressLogin(){
let signed = loginAction({
password:"correct"
})
if(signed){
this.props.navigation.navigate('Home')
}else{
this.props.navigation.navigate('Home')
}
Alert.alert('user'+ this.state.user);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function onLogin() {}",
"function login() {\n User.login(self.user, handleLogin);\n }",
"function handleLogin() {\n if (email === \"\" || password === \"\") {\n alert(\"Please fill out email and password\");\n return;\n }\n dispatch(loginUser(email, password));\n setLoginAttempts(logi... | [
"0.7320724",
"0.71969795",
"0.69157124",
"0.68803036",
"0.6877296",
"0.6837642",
"0.67843014",
"0.6765572",
"0.6633811",
"0.66336286",
"0.66333044",
"0.6627134",
"0.6615708",
"0.660129",
"0.65729266",
"0.65715694",
"0.6565759",
"0.65478826",
"0.65336525",
"0.65143216",
"0.651... | 0.72062844 | 1 |
Fetches boolean attributes by node | function boolHandler( elem, name, isXML ) {
var val;
return isXML ?
undefined :
(val = elem.getAttributeNode( name )) && val.specified ?
val.value :
elem[ name ] === true ? name.toLowerCase() : null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function getAttributes(node) {\n var attrs = node.attributes;\n if (node.checked) {\n attrs = Array.prototype.slice.call(attrs);\n attrs.push({name: 'checked', value: node.checked});\n }\n return attrs;\n}",
"function getForBoolean () {\n if (dataFrom === undefined) {\n from[att... | [
"0.6175611",
"0.61132973",
"0.6048159",
"0.5987227",
"0.58962107",
"0.5880348",
"0.58459496",
"0.5748146",
"0.5610331",
"0.55617064",
"0.5552113",
"0.5526053",
"0.5504091",
"0.5498329",
"0.5476878",
"0.5433037",
"0.54218024",
"0.5380183",
"0.53395337",
"0.53367996",
"0.531049... | 0.6115292 | 1 |
This function will load locale and then set the global locale. If no arguments are passed in, it will simply return the current global locale key. | function getSetGlobalLocale (key, values) {
var data;
if (key) {
if (isUndefined(values)) {
data = getLocale(key);
}
else {
data = defineLocale(key, values);
}
if (data) {
// moment.duration._locale = moment._locale = data;
globalLocale = data;
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function getSetGlobalLocale(key,values){var data;if(key){if(isUndefined(values)){data = getLocale(key);}else {data = defineLocale(key,values);}if(data){ // moment.duration._locale = moment._locale = data;\nglobalLocale = data;}else {if(typeof console !== 'undefined' && console.warn){ //warn user if arguments are p... | [
"0.7328238",
"0.7296561",
"0.725093",
"0.725093",
"0.725093",
"0.725093",
"0.725093",
"0.725093",
"0.72431237",
"0.72431237",
"0.7231825",
"0.7219627",
"0.72157764",
"0.7212002",
"0.7212002",
"0.7212002",
"0.7212002",
"0.7208171",
"0.7207731",
"0.7207568",
"0.7207568",
"0.7... | 0.7299787 | 1 |
src > lib in index | function src2libIdx(){
return src(["./index.js"])
.pipe(replace(/src/g,'lib'))
.pipe(dest('.'));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function packageIndex() {\n return gulp.src('package/index.js')\n .pipe(packageUMD('Blockly', [{\n name: 'Blockly',\n amd: './browser',\n cjs: './node',\n }]))\n .pipe(gulp.rename('index.js'))\n .pipe(gulp.dest(packageDistribution));\n}",
"async function getLibForBaseDir (base... | [
"0.5753473",
"0.5674191",
"0.5670588",
"0.54610866",
"0.5386182",
"0.53580934",
"0.52851796",
"0.5250025",
"0.5228389",
"0.5222627",
"0.5212039",
"0.51955825",
"0.5128155",
"0.5103105",
"0.50987697",
"0.50971913",
"0.50971913",
"0.50887597",
"0.50887597",
"0.5068733",
"0.5056... | 0.73253894 | 0 |
Get Transaction To Edit(in Modal) : _EditTransactionPartial | function editTransactionBtn(id) {
console.log("Edit Clicked, ID:" + id);
var dropdownElement = "#transactionDropdown-" + id;
$("#editModal-title").html('<div class="text-center"><h4>Edit Transaction</h4></div>');
$(dropdownElement).click();
$.ajax({
beforeSend: function () {
$("... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function editTransaction(id) {\n $.ajax({\n url: `/edit_transaction/${id}`\n }).done(function(response) {\n \n //Stringify to Json JavaScript object\n let data = JSON.parse(response);\n\n //Grab fields from Json data\n document.editForm.editTransition.value = data.transition;\n document.getE... | [
"0.6365813",
"0.63304",
"0.6233615",
"0.62171614",
"0.62171614",
"0.62171614",
"0.62171614",
"0.62171614",
"0.62171614",
"0.62171614",
"0.617074",
"0.60920084",
"0.59738123",
"0.59648067",
"0.59643525",
"0.59643525",
"0.5938493",
"0.59252006",
"0.5907202",
"0.58393997",
"0.58... | 0.64185834 | 0 |
GET : Transaction Header : _TransactionsManagerDropdownPartial | function UpdateTransactionManagerHead(){
$.ajax({
beforeSend: function () {
$("#transactions-head").html('<div class="" id="ajax-Accounts-loader1" style="text-align: center;"><div class="" style="display: inline-block;"><i class="fa fa-spinner fa-spin fa-3x fa-fw"></i></div></div>');
},
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function getTransactionList(code){\n\tload('get-transaction-list?id=' + code,function(xhr) {\n\t\tdocument.getElementById('trxtransactiondetails-transaction_id').innerHTML='';\n\n\t\tvar jsonData = JSON.parse(xhr.responseText);\n\t\tvar x = document.getElementById('trxtransactiondetails-transaction_id');\n\t\t//s... | [
"0.5890827",
"0.56451845",
"0.5643738",
"0.56056035",
"0.55383056",
"0.5528568",
"0.5523269",
"0.55177045",
"0.5479104",
"0.5477629",
"0.5451207",
"0.5426522",
"0.53331155",
"0.5310676",
"0.52933735",
"0.52762866",
"0.52744234",
"0.52402306",
"0.5232533",
"0.52286786",
"0.520... | 0.59054893 | 0 |
END Account Manage AJAX Start Budget Manage AJAX Get Budget Views | function GetBudgetViews() {
GetAddBudgetPartial();
GetActiveBudgetsPartial();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function GetAccountsView() {\n GetAddAccountPartial();\n GetAccountsListPartial();\n}",
"function activeTransactions(accountId) {\n var id = parseInt(accountId);\n $.ajax({\n type: \"Get\",\n url: \"/Saver/_DisplayTransactionsPartial\",\n data: { accounts: id },\n error: f... | [
"0.6467263",
"0.61511177",
"0.5933888",
"0.5857718",
"0.5782412",
"0.5745201",
"0.5716739",
"0.571514",
"0.5704529",
"0.5659585",
"0.56584793",
"0.56459016",
"0.56441694",
"0.564312",
"0.5640615",
"0.5616218",
"0.56021816",
"0.5585215",
"0.55601156",
"0.55552065",
"0.5533078"... | 0.6879215 | 0 |
Get Add Budget Partial | function GetAddBudgetPartial() {
$("#createFormPartialWrapper").html('<div class="" id="ajax-Accounts-loader1" style="text-align: center;"><div class="" style="display: inline-block;"><i class="fa fa-spinner fa-spin fa-3x fa-fw"></i></div></div>');
$("#createFormPartialWrapper").load("/Saver/_BudgetAddPartial")... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function addBudget(){\n return nicaragua.annualBudget +250000;\n}",
"function GetBudgetViews() {\n GetAddBudgetPartial();\n GetActiveBudgetsPartial();\n}",
"getBankingAdd(addBankInfo) {\n return this.http.post(this.url + '/cesco/addBankingInfo', addBankInfo);\n }",
"function addBudget(){\n... | [
"0.5961933",
"0.5919199",
"0.58285034",
"0.5764235",
"0.56720585",
"0.56069905",
"0.54093194",
"0.5379248",
"0.5361177",
"0.5334115",
"0.53306085",
"0.5297896",
"0.52927226",
"0.52912956",
"0.5285175",
"0.5258509",
"0.5193198",
"0.5139935",
"0.51373875",
"0.5130459",
"0.51258... | 0.59602666 | 1 |
Get Budget To Edit(in Modal) : _EditBudgetPartial | function editBudgetBtn(id) {
console.log("Edit Clicked, ID:" + id);
var dropdownElement = "#budgetDropdown-" + id;
$(dropdownElement).click();
$.ajax({
beforeSend: function () {
$("#editModal-Body").html('<div class="" id="ajax-Accounts-loader1" style="text-align: center;"><div class... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function get_edit() {\n $(\"#detailBiodata\").modal(\"hide\");\n var id = $(\"#get_id\").val();\n get_data_byid(id, 'edit');\n}",
"function editBudget(budgetId, newBudget) {\n\t\t\tvar data = $resource(\"budget/:id\", { id: \"@id\" }, {\n\t\t\t\tupdate: {\n\t\t\t\t\tmethod: \"PUT\"\n\t\t\t\t}\n\t\t\t});\n\... | [
"0.67842203",
"0.6312869",
"0.62818253",
"0.626524",
"0.626524",
"0.6226481",
"0.61185056",
"0.61126465",
"0.60848695",
"0.60209686",
"0.6019762",
"0.60104096",
"0.6005364",
"0.59790295",
"0.59790295",
"0.59790295",
"0.59790295",
"0.59790295",
"0.59790295",
"0.59790295",
"0.5... | 0.69315 | 0 |
Post Set Budget Active/InActive : _DisplayBudgetsPartial UI Reference Delete Transactions | function deleteBudgetBtn(id, isActiveAction) {
console.log("Clicked, ID:" + id);
var dropdownElement = "#budgetDropdown-" + id;
$(dropdownElement).click();
$.ajax({
type: "POST",
url: "/Saver/ActiveStatusToggleBudget",
data: { id: id, isActiveAction: isActiveAction },
da... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function deleteBudget(budgetId) {\n\t\t\treturn getRequest().remove({ id: budgetId }).$promise;\n\t\t}",
"function callBudgetAmountChange(values, fullyOptimized, totalOptimizationPending) {\n\t\t$.ajax({\n\t type: \"POST\",\n\t url: CUSTOM_DASHBOARD_CONSTANTS.budgetAPIUrl + CUSTOM_DASHBOARD_CON... | [
"0.5657614",
"0.5596555",
"0.55298585",
"0.5384145",
"0.53678954",
"0.5345832",
"0.53308254",
"0.5285747",
"0.52329034",
"0.52279896",
"0.5201631",
"0.5177206",
"0.5137883",
"0.5119357",
"0.5104219",
"0.5087696",
"0.50577754",
"0.50147307",
"0.49720883",
"0.49565512",
"0.4943... | 0.6060083 | 0 |
Post Account AJAX Start POST: Add Account Submit Form | function submitAddAccountForm() {
var form = $("#addAccountForm");
$.ajax({
beforeSend: function () {
form.hide();
form.after('<div class="" id="ajax-Accounts-loader1" style="text-align: center;"><div class="" style="display: inline-block;"><i class="fa fa-spinner fa-spin fa-3x f... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function addBankAccount() { \n\t\t\n\t\t\n\t\tvar url = $('#addBankAccountForm').attr('action');\n\t\t\n\t\tvar dataString = { \n\t\t\tbank_name : $(\"#bank_name\").val(),\n\t\t\tbank_location : $(\"#bank_location\").val(),\n\t\t\taccount_name : $(\"#account_name\").val(),\n\t\t\taccount_number : $(\"#account_numb... | [
"0.66765976",
"0.6581967",
"0.65558386",
"0.6513991",
"0.6436741",
"0.6416518",
"0.6355187",
"0.6310829",
"0.62960804",
"0.62401384",
"0.6205473",
"0.62041646",
"0.6188231",
"0.61735463",
"0.61627465",
"0.61180824",
"0.6076495",
"0.6063153",
"0.6048704",
"0.6031388",
"0.60313... | 0.72630936 | 0 |
Format list of team members to look nice TODO: mark who is team captain (if captains are even needed); | prettifyTeamMembers() {
return (
<ul>
{this.props.teamMembers.map((teamMember) => {
return (
<li key={teamMember}>{teamMember}
{teamMember===this.props.captain && <Icon tiny>start </Icon>}
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function formatTeamMembers (user) {\n\t if (user.loading) return 'Loading...';\n\n\t var markup = '<div>('+user.full_id+') '+user.name+'</div>';\n\n\t return markup;\n\t }",
"function createDreamTeam(members) {\n let nameDreamTeam = \"\";\n nameDreamTeam = members\n .filter((item) => typeof item ... | [
"0.7402388",
"0.6358512",
"0.6356395",
"0.62575585",
"0.61049736",
"0.6054199",
"0.6053137",
"0.5958288",
"0.5789603",
"0.57168144",
"0.5697969",
"0.5670436",
"0.5657251",
"0.56285596",
"0.5598278",
"0.55918026",
"0.5587004",
"0.55839247",
"0.55718184",
"0.5570786",
"0.557022... | 0.67338717 | 1 |
Get the flag for the team NOTE: "Germany" is a placeholder | getFlag() {
let countryName = getCode(this.props.teamName);
return (
<ReactCountryFlag code={countryName} svg flagProps={{fontSize: "4vw",}}/>
)
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function getTeam() {\n if (team.includes(\"Retired\") === true) {\n return \"Retired\";\n }\n if (team.includes(\"Free Agent\") === true) {\n return \"Free Agent\";\n } else {\n return team;\n }\n }",
"function getTeamName(team){\n var teamName = {\n 'ARI': 'Arizona Cardi... | [
"0.77576005",
"0.64663875",
"0.6220487",
"0.61646736",
"0.60542095",
"0.59838223",
"0.5981607",
"0.58730805",
"0.5861986",
"0.5856284",
"0.5855211",
"0.5823294",
"0.5808091",
"0.5728912",
"0.5686803",
"0.56783044",
"0.566933",
"0.56673265",
"0.56672287",
"0.5660693",
"0.56454... | 0.66606694 | 1 |
toggle balao ativa disabled e ativa inputFile | function inputDisabled () {
$('input').each(function(){
if($(this).is(':disabled')){
$(this).addClass('do-disabled');
}else{
$(this).removeClass('do-disabled');
}
});
$('.fileWrap').click(function() {
$('#myFile').click();
});
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function fileSelect() { //Controla si el input es la linea de comando o un archivo\n const selected = document.getElementById(\"cFile\").files.length > 0;\n fileSelected = selected\n document.getElementById(\"cmd\").disabled = selected\n}",
"disableUploadUi(disabled){this.uploadButton.prop('disabled',di... | [
"0.73003805",
"0.68551856",
"0.66768855",
"0.6669776",
"0.6663753",
"0.6552206",
"0.6536357",
"0.6402",
"0.6345224",
"0.6341644",
"0.6318045",
"0.6271386",
"0.626558",
"0.6214439",
"0.6206798",
"0.6150614",
"0.61476076",
"0.61161375",
"0.610626",
"0.60948056",
"0.6076586",
... | 0.712508 | 1 |
mouse moves, update focus | on_mouse_move() {
clearTimeout(this.focus_timeout);
this.focus_timeout = this.create_focus_timeout();
this.change_focus(true);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"mouseMove(prev, pt) {}",
"function mousemove() {\r\n var x0 = x.invert(d3.mouse(this)[0]),\r\n i = bisectDate(data, x0, 1),\r\n d0 = data[i - 1],\r\n d1 = data[i],\r\n d = x0 - d0.date > d1.date - x0 ? d1 : d0;\r\n focus.attr(\"tra... | [
"0.6937734",
"0.6917849",
"0.685474",
"0.6739816",
"0.6709551",
"0.6682303",
"0.6661074",
"0.66213787",
"0.65618247",
"0.6547612",
"0.6538924",
"0.65236634",
"0.65114045",
"0.6504013",
"0.64942795",
"0.6430899",
"0.6399848",
"0.63964987",
"0.63843966",
"0.63739985",
"0.634953... | 0.75743717 | 0 |
Adds a new tracking entry to the user | @POST("/create")
createTracking(req, res)
{
let tracking = req.body.tracking;
TrackingSites.create({type: tracking.type, user: req.user._id, target: tracking.target}).then( result => {
res.json({success: true, tracking: result});
}).catch( error => {
res.serverError(error);
});
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function addPoint(){\n trackingFB.push({\n latitud:localStorage.getItem(\"latitud\"),\n longitud:localStorage.getItem(\"longitud\")\n })\n }",
"function attachNewUserToIncident() {\n attachNewUser = true;\n $(\"#user_add_username\").val($(\"#user_name\")... | [
"0.61394686",
"0.60996735",
"0.5610276",
"0.5601489",
"0.55859554",
"0.5543968",
"0.55325496",
"0.552997",
"0.5527397",
"0.54890937",
"0.54890937",
"0.54876363",
"0.54875064",
"0.5473144",
"0.5458305",
"0.54208696",
"0.5420689",
"0.5414644",
"0.5395987",
"0.53827393",
"0.5380... | 0.61402076 | 0 |
Takes a page number and student list as arguments. Hides all student links currently displayed, then displays ten students within a range based on the page number parameter. | function showPage (pageNumber, studentList) {
hideList(studentList);
for(let i = 1; i <= studentList.length; i++) {
const li = studentList[i - 1];
if(i >= getLowerRange(pageNumber) &&
i <= getUpperRange(pageNumber))
li.style.display = '';
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function showPage(page, studentList) {\n for (let i = 0; i < studentList.length; i += 1) {\n studentList[i].style.display = \"none\";\n }\n for (let i = 0; i < studentList.length; i += 1) {\n if (i >= (page - 1) * 10 && i <= (page * 10) - 1) {\n studentList[i].style.display = \"block\";\n }\n }\n... | [
"0.796867",
"0.7910547",
"0.78174907",
"0.7787244",
"0.773965",
"0.77329886",
"0.76481664",
"0.7613543",
"0.7606913",
"0.75724864",
"0.7562922",
"0.75445366",
"0.7515648",
"0.75123215",
"0.7465804",
"0.7438641",
"0.7434801",
"0.7410575",
"0.7407549",
"0.73810357",
"0.73530334... | 0.79330236 | 1 |
Returns the lower range for students to be displayed based on the page number parameter. | function getLowerRange (pageNumber) {
return (pageNumber * 10) - 9;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"getPageRange(page, pageCount) {\n let minPage;\n let maxPage;\n if (pageCount < 5) {\n return {\n max: pageCount,\n min: 1,\n };\n }\n if (page < 3) {\n minPage = 1;\n maxPage = 5;\n }\n if (p... | [
"0.6401911",
"0.63454074",
"0.63368964",
"0.6144547",
"0.6017734",
"0.6014225",
"0.59727615",
"0.59350854",
"0.5841418",
"0.5808326",
"0.5788652",
"0.56909984",
"0.5687794",
"0.56774",
"0.56675965",
"0.56600535",
"0.56587154",
"0.565189",
"0.5648563",
"0.5620787",
"0.5595519"... | 0.7728489 | 0 |
Returns the upper range for students to be displayed based on the page number parameter. | function getUpperRange (pageNumber) {
return pageNumber * 10;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function getLowerRange (pageNumber) {\n return (pageNumber * 10) - 9;\n}",
"getPageRange(page, pageCount) {\n let minPage;\n let maxPage;\n if (pageCount < 5) {\n return {\n max: pageCount,\n min: 1,\n };\n }\n if (page < 3... | [
"0.6377158",
"0.62776196",
"0.6087398",
"0.5950733",
"0.5758873",
"0.57349104",
"0.5580019",
"0.5570712",
"0.55398375",
"0.5517673",
"0.5505255",
"0.550055",
"0.54877496",
"0.548095",
"0.54683113",
"0.5448062",
"0.54250365",
"0.5394027",
"0.5369022",
"0.5329555",
"0.531539",
... | 0.7967973 | 0 |
Takes a student list as an argument. Creates an empty array literal for student search matches. Assigns the search input value to inputValue. Calls hideList() and removeElement() to clear all student links and page numbers. Loops through students and determines if student names or emails contain the search input. Adds ... | function searchList (studentList) {
const matchedStudents = [];
const $paginationDiv = $('.pagination');
const paginationDivElem = $paginationDiv[0];
$inputValue = $('input').val();
if($inputValue !== '') {
hideList(studentList);
//both of these work for some reason
removeElement($paginati... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function search(searchInput, list) {\n const filteredList = [];\n\n // this loop is to go through the list of students\n for (let i = 0; i < list.length; i++) {\n const student = list[i];\n const studentName = `${student.name.first} ${student.name.last}`.toLowerCase();\n\n // the conditiona... | [
"0.7657688",
"0.75372046",
"0.75199336",
"0.74531746",
"0.74436957",
"0.743013",
"0.7422089",
"0.71527374",
"0.7147723",
"0.7141637",
"0.71213174",
"0.70586866",
"0.6987113",
"0.6908251",
"0.6865109",
"0.66677755",
"0.6662191",
"0.66263014",
"0.6615109",
"0.6582029",
"0.65802... | 0.79739034 | 0 |
Takes a matchedInputArray as an argument. Removes the exit search div(and link), and the search results messages, if they exist. Calls createExitDiv() and appends the div to the page, allowing the user to exit search mode. Creates and displays messages based on the number of search results. If the array is not empty an... | function evaluateSearchMatches(matchedInputArray) {
removeElements($('.exit-div')[0],
$('.no-match')[0],
$('.under-eleven')[0],
$('.over-ten')[0]);
const $exitDiv = createExitDiv();
$($pageDiv).append($exitDiv);
if(matchedInputArray.length === 0) {
const $p... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function search(e) {\n let searchResult = []\n for (i = 0; i < list.length; i++) {\n if (list[i].firstElementChild.firstElementChild.nextElementSibling.innerText.toUpperCase().split(\" \").join(\"\").indexOf(search_box.value.toUpperCase()) > -1) {\n searchResult.push(list[i])\n }\n ... | [
"0.607398",
"0.59947836",
"0.59385705",
"0.5855764",
"0.5741945",
"0.5741871",
"0.5680226",
"0.5640158",
"0.56395453",
"0.5617488",
"0.5569284",
"0.5556031",
"0.55249614",
"0.5502286",
"0.5495562",
"0.5477914",
"0.54422957",
"0.53863883",
"0.5382863",
"0.53760797",
"0.5369613... | 0.7902705 | 0 |
Takes a class name and textContent as arguments and creates a message for different search results, assigning the class and text parameters to the message. Returns the message. | function createSearchMessage (className, textContent) {
const $p = createElement('p', '', '');
$($p).attr('class', 'student-item ' + className);
$($p).text(textContent);
return $p;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function CreateMessage(searchterm, result){\n\tvar message = \"\";\n\tmessage += `Here are the results for \\'${searchterm}\\': \\n\\n`;\n\n\tfor(var i = 0; i < result.length; i++){\n\t\t\n\t\tvar resultName = result[i].name;\n\n\t\t//var resultDescription = result[i].description;\n\t\tvar resultEffect = result[i]... | [
"0.63190687",
"0.5356533",
"0.5139687",
"0.51348084",
"0.51258385",
"0.5116994",
"0.50907475",
"0.50646293",
"0.50418335",
"0.5038811",
"0.50259733",
"0.5024224",
"0.50207365",
"0.50085175",
"0.5002622",
"0.50012696",
"0.5000294",
"0.4966444",
"0.49575764",
"0.49439797",
"0.4... | 0.73951095 | 0 |
Takes a student list as an argument. Creates and returns an unordered list to serve as page links. The number of links is determined in the for loop by dividing studentList.length by 10. If the text content of any li's anchor tag equals the current page number, it is given the class name 'active' to ensure it is approp... | function constructPaginationUl (studentList) {
const $ul = createElement('ul', '', '');
for(let i = 0; i < studentList.length/10; i++) {
const $li = createElement('li', '', '');
const $a = createElement('a', 'href', '#');
pageNum = i + 1;
$($a).text(pageNum);
if($($a).text() === pageNumber)
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function appendPageLinks(studentList) {\n\n const studentNumber = studentList.length;\n const maxPageNumber = Math.ceil(studentNumber / 10);\n const $ul = $('div.pagination > ul');\n\t\n // unobtrusive JavaScript design pattern. \n //\t clear all the old html data and dynamiclly add page l... | [
"0.80700964",
"0.79862916",
"0.7907794",
"0.77879757",
"0.75472134",
"0.7524386",
"0.7457074",
"0.74532443",
"0.7449141",
"0.743211",
"0.7351101",
"0.73300785",
"0.7323817",
"0.7323312",
"0.72641534",
"0.7262168",
"0.7260091",
"0.7230468",
"0.72253907",
"0.7199236",
"0.717460... | 0.80290294 | 1 |
Removes the element passed as an argument if it exists on the page. | function removeElement (element) {
if(element != null)
//Does not work (improperly used)
//$($pageDiv).remove(element);
//Thes two work for some reason
element.remove();
//pageDivElem.removeChild(element);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function removeElement(elem){ if (elem) elem.parentNode.removeChild(elem) }",
"function removeElement(elem){ if (elem) elem.parentNode.removeChild(elem) }",
"function removeElement(element) {\n\t element && element.parentNode && element.parentNode.removeChild(element);\n\t }",
"function removeElement(ele... | [
"0.74082005",
"0.74082005",
"0.7268168",
"0.7268168",
"0.7268168",
"0.7268168",
"0.72646046",
"0.72646046",
"0.72646046",
"0.7238492",
"0.7238492",
"0.7238492",
"0.7238492",
"0.7238492",
"0.7238492",
"0.7238492",
"0.7238492",
"0.7238492",
"0.7238492",
"0.7238492",
"0.7238492"... | 0.7817351 | 0 |
Calls removeElement() on any number of elements passed as arguments. | function removeElements (...elements) {
for(let i = 0; i < elements.length; i++)
removeElement(elements[i]);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function removeElems() {\n [].forEach.call(arguments, function(selector) {\n var elem = document.querySelector(selector);\n elem && elem.parentNode.removeChild(elem);\n });\n}",
"removeElements (elems, checkFunc) {\n // checkFunc returns true if an element is to be deleted\n super.remov... | [
"0.7208857",
"0.69870216",
"0.69870216",
"0.68742913",
"0.6827588",
"0.6653487",
"0.6445428",
"0.6372408",
"0.63116235",
"0.62832046",
"0.62832046",
"0.6149378",
"0.6149378",
"0.6134998",
"0.6129606",
"0.61109513",
"0.61109513",
"0.6109043",
"0.6108714",
"0.60789627",
"0.6078... | 0.7595069 | 0 |
Convert a nontopological path to one or more topological arcs | function convertPath(start, end) {
var arcIds = [],
firstNodeId = -1,
arcStartId;
// Visit each point in the path, up to but not including the last point
//
for (var i = start; i < end; i++) {
if (pointIsArcEndpoint(i)) {
if (firstNodeId > -1) {
arcIds.push(addEd... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function convertPath(start, end) {\n var arcIds = [],\n firstNodeId = -1,\n arcStartId;\n\n // Visit each point in the path, up to but not including the last point\n for (var i = start; i < end; i++) {\n if (pointIsArcEndpoint(i)) {\n if (firstNodeId > -1) {\n ... | [
"0.6473823",
"0.5900086",
"0.548541",
"0.54169124",
"0.53616655",
"0.5356819",
"0.5294911",
"0.5283737",
"0.5278077",
"0.5266836",
"0.5256434",
"0.51830924",
"0.51079696",
"0.51032513",
"0.50796825",
"0.5074798",
"0.5062296",
"0.50470805",
"0.5040545",
"0.5018614",
"0.501815"... | 0.6502048 | 0 |
Create a lookup table for path ids; path ids are indexed by point id | function initPathIds(size, pathSizes) {
var pathIds = new Int32Array(size),
j = 0;
for (var pathId=0, pathCount=pathSizes.length; pathId < pathCount; pathId++) {
for (var i=0, n=pathSizes[pathId]; i<n; i++, j++) {
pathIds[j] = pathId;
}
}
return pathIds;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function recordPath2Id(uri, id) {\r\n if (kernel.path2id[uri]) {\r\n kernel.path2id[uri].push(id)\r\n } else {\r\n kernel.path2id[uri] = [id]\r\n }\r\n}",
"function initPathIds(size, pathSizes) {\n var pathIds = new Int32Array(size),\n j = 0;\n for (var pathId=0, pathCount=pathSizes.length;... | [
"0.58209395",
"0.58095235",
"0.5709332",
"0.55625385",
"0.537927",
"0.53659916",
"0.53530455",
"0.5304144",
"0.52385384",
"0.5225209",
"0.52133894",
"0.5199777",
"0.51809543",
"0.51809543",
"0.51483524",
"0.5132214",
"0.51238203",
"0.5104408",
"0.5087568",
"0.50662553",
"0.50... | 0.5844141 | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.