Search is not available for this dataset
query
stringlengths
7
355k
document
stringlengths
9
341k
metadata
dict
negatives
listlengths
0
101
negative_scores
listlengths
0
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
This function retrieves all of the search criteria from the database that the user can filter projects with INNER FUNCTION CALLS: clearAndAddSingleRow(), fillDropdowns_FIND_PROJECT(), checkInitFilter()
function getSearchCriteria(_stopServerCalls) { clearAndAddSingleRow('Retrieving Search Criteria...'); $.ajax({ type: 'POST', url: 'Project', data: { domain: 'project', action: 'getSpecificObjects', warehouse: true, class: true, item: true, person: true, type: t...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function filterProjects(filter) {\n if (filter != undefined) console.log(filter);\n\n updateDisplayableProjects();\n\n let json = DISPLAYABLE_PROJECTS.slice(0);\n let outputs = new Array();\n let parameters = $('.paramHolder').children('select');\n\n let remaining = json.length;\n\n if (paramNum != 0) {\n ...
[ "0.67553717", "0.67243576", "0.6705336", "0.66027325", "0.64424235", "0.6417443", "0.628128", "0.6264447", "0.62138814", "0.61894655", "0.6188452", "0.6174487", "0.6106437", "0.6097635", "0.6095016", "0.6081944", "0.6072017", "0.60132307", "0.6011445", "0.60099757", "0.597347...
0.72020644
0
This function clears the project display table and adds a single row with a message INNER FUNCTION CALLS: none
function clearAndAddSingleRow(msg) { $('#results > tbody').children('tr:not(.head)').remove(); let placeHolder = document.createElement('tr'); let listDetails0 = document.createElement('td'); let listDetails1 = document.createElement('td'); let listDetails2 = document.createElement('td'); let listDetails3 ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function OnProjectAdd() {\n $('#project tr').removeClass(\"selected\");\n DrawProjectRow();\n $('#addProject').modal('hide');\n ProjectAddEditShowHide(false);\n}", "function setProjects()\r\n{\r\n var table = document.getElementById(\"projects\");\r\n var iRows = table.rows.length;\r\n for (var iR...
[ "0.68221873", "0.670105", "0.6370265", "0.63062906", "0.6235367", "0.6166374", "0.61538136", "0.6128441", "0.60950655", "0.6025471", "0.5992469", "0.5984969", "0.5983966", "0.5980568", "0.597742", "0.59650785", "0.59646285", "0.5942172", "0.5904853", "0.58873326", "0.5875613"...
0.5532551
84
This function sets the initial filter when finding projects INNER FUNCTION CALLS: matchUsernameToPersonID, filterProjects()
function checkInitFilter() { if (getParameterByName('id') == 'activePermit') { $('#paramID1').val('Status'); $('#paramVal1').empty(); $('#paramVal1').append(statusOptions.cloneNode(true)); document.getElementById('paramVal1').value = '30'; filterProjects(); } else if (getParameterByName('from')...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setProjectFilter(filter_name) {\n\t// initial filtering\n\tlet all_data = getProjectsData();\n\tif (filter_name === 'all'){\n\t\tcurrentProjects = all_data;\n\t}else{\n\t\tlet temp_data = [];\n\t\tfor (let i=0;i<all_data.length;i++){\n\t\t\tif (all_data[i].Category.includes(filter_name)){\n\t\t\t\ttemp_da...
[ "0.7006298", "0.66848683", "0.64181143", "0.6232716", "0.61647934", "0.60389584", "0.59803903", "0.5972582", "0.5855678", "0.5799655", "0.5744014", "0.57062566", "0.56725454", "0.5652766", "0.5613748", "0.56017107", "0.55560553", "0.55507314", "0.55117935", "0.54994345", "0.5...
0.6262634
3
This function matches the user's first name to the appropriate person ID INNER FUNCTION CALLS: removeParam()
function matchUsernameToPersonID(userFirstName, paramNum) { if (!PERSONS) return '3'; console.log('PEOPLE', PERSONS, userFirstName); for (var i = 0; i < PERSONS.length; i++) { if (PERSONS[i].name.toLowerCase() == userFirstName.toLowerCase()) { console.log(PERSONS[i].name, PERSONS[i].id); var para...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function matchUsernameToPerson(userFirstName) {\n if (!PERSONS) return '3';\n\n console.log('PEOPLE', PERSONS, userFirstName);\n for (var i = 0; i < PERSONS.length; i++) {\n if (PERSONS[i].name.toLowerCase() == userFirstName.toLowerCase()) {\n return PERSONS[i].id;\n }\n }\n\n return '3';\n}", "f...
[ "0.62657666", "0.59989417", "0.5886685", "0.58515596", "0.579642", "0.5671003", "0.56621146", "0.5601031", "0.55994505", "0.5576969", "0.5564283", "0.5552593", "0.55385935", "0.5524842", "0.5519322", "0.55135274", "0.5512167", "0.5504035", "0.5494465", "0.5481358", "0.5472500...
0.7283164
0
This function generates the dropdowns for the findProject search criteria INNER FUNCTION CALLS: none
function generateDropdowns_FIND_PROJECTS(jsonData, field) { let json = JSON.parse(jsonData); let d = document.createDocumentFragment(); let sorted = false; for (var i = 0; i < json.length; i++) { if (field == 'Manager' || field == 'Supervisor') { if (json[i].name == 'Bart' || json[i].name == 'Lillian...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function initProjects(data) {\n let dropdown = document.getElementById('slProject');\n dropdown.length = 0;\n let defaultOption = document.createElement('option');\n defaultOption.text = 'Choose project!!!';\n\n dropdown.add(defaultOption);\n dropdown.selectedIndex = 0;\n\n let option;\n fo...
[ "0.71983033", "0.70652497", "0.7026532", "0.70212615", "0.67032725", "0.6693996", "0.6669466", "0.6616822", "0.6545424", "0.6516947", "0.65163016", "0.65120465", "0.6479441", "0.64639497", "0.6414924", "0.63203496", "0.6319927", "0.63189805", "0.6312659", "0.6229288", "0.6203...
0.76012063
0
This function sets the value for the parameter INNER FUNCTION CALLS: none
function setVals(param) { let modParam = $(param).siblings('select'); let valOptions = $(param).val(); switch (valOptions) { case 'Warehouse': modParam.empty(); modParam.append(warehouseOptions.cloneNode(true)); break; case 'Project': modParam.empty(); modParam.append(classO...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setThisWithCall(fn,thisValue,arg){\n // console.log(fn) //ƒ (){ return {thisValue: this, arguments: Array.from(arguments)} }\n // console.log(thisValue) //{name:bob}\n // console.log(arg) //18\n setResults= fn.call(thisValue,arg)\n // console.log(setResults)\n return setResults\n}//setT...
[ "0.6292236", "0.61070395", "0.58734965", "0.58554345", "0.5788636", "0.5725604", "0.5643202", "0.56386024", "0.55605775", "0.5556691", "0.5526023", "0.54984796", "0.5474886", "0.5452071", "0.5440946", "0.54358345", "0.541663", "0.53956723", "0.5341821", "0.5337777", "0.532508...
0.0
-1
This function adds a parameter to the search criteria INNER FUNCTION CALLS: none
function addParameter() { paramNum++; let parameterHolder = document.createElement('div'); parameterHolder.className = 'paramHolder'; let selectID = document.createElement('select'); selectID.className = 'parameterID'; selectID.id = 'paramID' + paramNum; $(selectID).css('margin-right', '4px'); let op...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateAdanvceSearch(){\n if(typeof searchPnt != \"undefined\"){\n whereClause = searchFilters.buildWhereClause();\n findOptimalSearchRadius(providerFS,searchPnt,whereClause)\n }\n }", "function funcSearchTeachers() {\n\tadditionalParams();\n}", ...
[ "0.6734567", "0.6654129", "0.66124773", "0.63709337", "0.621435", "0.61161107", "0.6039853", "0.60143006", "0.6003313", "0.59916604", "0.590896", "0.59067345", "0.58947974", "0.5894597", "0.587362", "0.5873579", "0.5872575", "0.5870009", "0.5791715", "0.5780757", "0.57768726"...
0.0
-1
This function removes a param from the search criteria INNER FUNCTION CALLS: filterProjects()
function removeParam(param) { param.parentNode.remove(); paramNum--; filterProjects(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function filterProjects(filter) {\n if (filter != undefined) console.log(filter);\n\n updateDisplayableProjects();\n\n let json = DISPLAYABLE_PROJECTS.slice(0);\n let outputs = new Array();\n let parameters = $('.paramHolder').children('select');\n\n let remaining = json.length;\n\n if (paramNum != 0) {\n ...
[ "0.73070365", "0.68135035", "0.6246603", "0.6205264", "0.619918", "0.61687714", "0.60546535", "0.60307527", "0.60004556", "0.5993928", "0.5926079", "0.5843258", "0.5806511", "0.57829535", "0.57608813", "0.5758078", "0.57227015", "0.5714041", "0.5651307", "0.561861", "0.558195...
0.6849965
1
This function filters through the projects based off of the given search criteria and then displays the appropriate projects INNER FUNCTION CALLS: updateDisplayableProjects(), clearAndAddSingleRow()
function filterProjects(filter) { if (filter != undefined) console.log(filter); updateDisplayableProjects(); let json = DISPLAYABLE_PROJECTS.slice(0); let outputs = new Array(); let parameters = $('.paramHolder').children('select'); let remaining = json.length; if (paramNum != 0) { for (var i = 0;...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function searchProjects() {\n loadProjects(jq('#srchTxt').val());\n }", "function getExistingProjects(startRow) {\n toggleResultTable(false);\n toggleSearchingIndicator(true);\n clearTable();\n receivedProjects = 0;\n for (var i = startRow; i < currentPage * elementsPerPage; i++) {\n //end is r...
[ "0.71619576", "0.6731126", "0.6689547", "0.6657224", "0.66169584", "0.65827006", "0.65774214", "0.6544239", "0.6535556", "0.6502963", "0.640225", "0.6394738", "0.6379478", "0.631121", "0.62610614", "0.6246515", "0.6232122", "0.6223917", "0.61520517", "0.61500424", "0.60640806...
0.69491976
1
This function displays the proper div INNER FUNCTION CALLS: none
function navigateTo(source) { EDIT_INTENTION = true; console.log($(source).attr('id')); if (taskFinder) { window.location.href = TASK_CREATOR + '?id=' + $(source).attr('id').replace('project', ''); } else { document.getElementById('findProject').style.display = 'none'; $(source).attr('id').rep...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function div_show(el){ \n\t\n\t\t\tpopup6(\"\");\n\t\t\n\t}", "function display(){\r\n\r\n \r\n}", "function tiro1() {\n displays();\n}", "function func() {\r\n if (elems.style.display == 'none') {\r\n elems.style.display = 'inline-block';\r\n } else {\r\n elems.style.disp...
[ "0.68600476", "0.6851525", "0.6647072", "0.64478886", "0.6401803", "0.63716465", "0.6357231", "0.6356779", "0.6295745", "0.6245265", "0.6234916", "0.620504", "0.61986625", "0.6186428", "0.6173508", "0.6156334", "0.61551404", "0.6153235", "0.61531067", "0.61442435", "0.6132591...
0.0
-1
This function retrieves all of the taks from the server INNER FUNCTION CALLS: fillTasksTable()
function getTasks(stopServerCalls) { console.log(projectID); $.ajax({ type: 'POST', url: 'Project', data: { domain: 'project', action: 'getProjectTasks', id: projectID, }, success: function (data) { console.log('proj tasks!!!!', data); let type = getParameterByName(...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getTasks() {\n var self = this;\n\n // Get data from server\n getAPITasks(self);\n }", "getTasks(callback) {\n var result, response;\n this.db.scan({ TableName: this.tableName }, function (err, data) {\n if (err) {\n callback(err, null);\n } else {\n ...
[ "0.71714413", "0.7130676", "0.70188874", "0.6969443", "0.68705565", "0.6809379", "0.67274946", "0.6691322", "0.6671705", "0.66336846", "0.66094685", "0.66065395", "0.6509962", "0.6496987", "0.6474532", "0.6473994", "0.6441214", "0.63605326", "0.6284028", "0.6282227", "0.62797...
0.6590627
12
This function gets the specific project from the database INNER FUNCTION CALLS : fillsTabs_CHANGE_ORDER(), fillTabs_CHANGE_ORDER(), getTasks()
function getProject_CHANGE_ORDER() { console.log('P ID = ', projectID); if (projectID !== null) { $.ajax({ type: 'POST', url: 'Project', data: { domain: 'project', action: 'get', id: projectID, }, success: function (data) { PROJECT_DATA = data; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getcurrentprojects() { }", "function getProject_PROJECT_MANAGER(project_id, stopServerCalls) {\n console.log('ID = ', project_id);\n projectID = project_id;\n if (projectID !== null) {\n $.ajax({\n type: 'POST',\n url: 'Project',\n data: {\n domain: 'project',\n action: 'get',\...
[ "0.6921507", "0.6900922", "0.67259526", "0.65594506", "0.6458665", "0.62593275", "0.6253588", "0.6224826", "0.615473", "0.61481833", "0.6137833", "0.610136", "0.6074878", "0.60709345", "0.60439414", "0.60329604", "0.60103744", "0.60054016", "0.59953886", "0.5986629", "0.59603...
0.56203747
63
This function retrives the change order drop down info from the server INNER FUNCTION CALLS : fillDropdowns_CHANGE_ORDER(), getProject_CHANGE_ORDER()
function getDropdownInfo_CHANGE_ORDER() { if (projectID === null) { alert('Invalid URL. Try returning to this page again.'); return; } $.ajax({ type: 'POST', url: 'Project', data: { domain: 'project', action: 'getSpecificObjects', changeordertype: true, changeorderstat...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fillDropdowns_CHANGE_ORDER(json) {\n console.log(json);\n var changeorderStatus = JSON.parse(json['changeorderstatus']);\n changeorderStatus = sortChangeOrderStatus(changeorderStatus);\n var d = document.createDocumentFragment();\n $('#changeOrder').find('#status').empty();\n $('#changeOrder').find(...
[ "0.6928814", "0.6656755", "0.62832826", "0.6201655", "0.5988518", "0.59727436", "0.5908422", "0.59014857", "0.5898036", "0.5875588", "0.5866497", "0.5826183", "0.5823002", "0.57977295", "0.5787887", "0.57576317", "0.57281935", "0.5713014", "0.57034403", "0.57034403", "0.57014...
0.84976345
0
This function fills the change order tabs with the appropriate data for a specific change order
function fillTabs_CHANGE_ORDER(json) { console.log('EDIT == ', edit_CHANGE_ORDER); console.log('CHANGE ORDERS = ', PROJECT_DATA.changeOrders); var nextCOnum; if (PROJECT_DATA.changeOrders.length) nextCOnum = PROJECT_DATA.changeOrders.length; else nextCOnum = 1; var changeOrderToEdit; for (var i = 0...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fillChangeOrders(data) {\n clearChangeOrderTable();\n console.log('CALLED FILL CO', data);\n if (data) CHANGE_ORDERS = data.changeOrders;\n let changeOrders = CHANGE_ORDERS;\n\n changeOrders.sort(function (a, b) {\n if (!a.id) return -1;\n if (!b.id) return 1;\n\n if (a.id < b.id) return -1;...
[ "0.7124469", "0.6239577", "0.6190825", "0.5971353", "0.5971353", "0.5971353", "0.5971353", "0.5930571", "0.59267575", "0.58470225", "0.5812792", "0.5796457", "0.5786192", "0.5713509", "0.57095313", "0.56965715", "0.5685142", "0.5675274", "0.5651878", "0.5605878", "0.55955637"...
0.763937
0
This function makes a number more computer friendly by removing commas
function cleanNumericValueForSaving(num) { if (num[0] == '(') { num = num.slice(1, num.length); } while (num.indexOf(',') != -1) { num = num.replace(',', ''); } while (num.indexOf('$') != -1) { num = num.replace('$', ''); } return num; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function cleanNum(num) {\n\tnum = parseFloat(num);\n\tif (num < 1000) {\n\t\tnumStr = num.toFixed(2);\n\t}\n\telse {\n\t\tnumStr = num.toFixed();\n\t}\n\n\treturn numStr.replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n}", "function numberWithCommas(x) {\r\n return x.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, \...
[ "0.7929272", "0.7927595", "0.7904516", "0.7904433", "0.7902258", "0.79008424", "0.78732723", "0.7865229", "0.7858092", "0.7857477", "0.7857477", "0.7840454", "0.78270173", "0.78270173", "0.7804529", "0.7804529", "0.7796485", "0.7780402", "0.77744836", "0.77725637", "0.7772563...
0.0
-1
This function makes a number more human friendly by adding commas and by adding a 0 to the decimal Example : instead of 123456.7 being displayed, this method turns it into 123,456.70
function cleanNumericValueForDisplaying(num) { var neg; if (num < 0) neg = true; else neg = false; num = Math.abs(num); var str = num.toString(); var price, cleanPrice; var dollars, cleanDollars; var dollarArray = new Array(); var correctOrder = ''; var cents, cleanCents; if (str.indexOf('.') !=...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function addCommas(yourNumber) {\n //Seperates the components of the number\n var n= yourNumber.toString().split(\".\");\n //Comma-fies the first part\n n[0] = n[0].replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\");\n //Combines the two sections\n return n.join(\".\");\n}", "function numberWithCommas(...
[ "0.7856039", "0.78055716", "0.7746453", "0.77082586", "0.7680351", "0.76741725", "0.7650409", "0.7633957", "0.7614071", "0.7614071", "0.76092213", "0.76028186", "0.75897723", "0.7577671", "0.75764495", "0.7570174", "0.75659525", "0.75607216", "0.75495327", "0.75460654", "0.75...
0.0
-1
This function clears the change order tabs of their values
function clearTabs_CHANGE_ORDER() { $('#changeOrder').find('#customerCO').val(''); $('#changeOrder').find('#mcsCO').val(''); $('#changeOrder').find('#subCO').val(''); $('#changeOrder').find('#proposalDate').val(''); $('#changeOrder').find('#briefDescription').val(''); $('#changeOrder').find('#subNames').val...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function clearChangeHistory() {\n changeHistory = [];\n historyPosition = 0;\n }", "function clearSortOrder(){\n var view = tabsFrame.newView;\n var index = view.tableGroups.length - tabsFrame.selectedTableGroup - 1;\n var curTgrp = view.tableGroups[index];\n \n curTgrp.sortFields = \...
[ "0.6983018", "0.6776654", "0.6611608", "0.64693123", "0.6363089", "0.6325601", "0.6279782", "0.62458944", "0.6243508", "0.6243008", "0.62178886", "0.6213411", "0.61932796", "0.61846167", "0.61645067", "0.61476064", "0.6143771", "0.6121304", "0.6118982", "0.6117499", "0.611691...
0.73155755
0
This function converts a change order attribute id and returns the String value
function convert_CHANGE_ORDER(param) { switch (param) { case '1': return 'COP'; case '2': return 'REF'; case '3': return 'WHS'; case '4': return 'FAC'; case '5': return 'VEN'; case '6': default: return 'UDF'; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateIdStr( value ) {\n var strArray = value.split( '-' ),\n id = strArray[ strArray.length - 1 ],\n newId = parseInt( id ) + 1\n\n // console.log( strArray );\n // console.log( id );\n // console.log( newId );\n\n strArray[ strArray.length - 1 ] = newId;\n // console.log( strArra...
[ "0.5857359", "0.576781", "0.5742125", "0.5681608", "0.5584908", "0.5478775", "0.53973323", "0.5327949", "0.53012943", "0.5296309", "0.5296309", "0.5275343", "0.5268966", "0.5235856", "0.5218697", "0.5214471", "0.52121025", "0.52121025", "0.52121025", "0.52121025", "0.52121025...
0.5765697
2
This function fills the drop down selectors for the change order interface
function fillDropdowns_CHANGE_ORDER(json) { console.log(json); var changeorderStatus = JSON.parse(json['changeorderstatus']); changeorderStatus = sortChangeOrderStatus(changeorderStatus); var d = document.createDocumentFragment(); $('#changeOrder').find('#status').empty(); $('#changeOrder').find('#customerC...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function rename_dropdown_elements(cont) {\n \n var new_count = 0;\n //For each div .opts_class\n jQuery.each($(\".opts_class:visible\"), function() {\n $(this).attr(\"id\", new_count);\n var visible_select = $(this).children('select:visible');\n\n //For e...
[ "0.6512796", "0.64124215", "0.63192797", "0.6270869", "0.62616533", "0.62450224", "0.6198515", "0.61913556", "0.61864996", "0.6158296", "0.61572796", "0.60945797", "0.6083278", "0.604828", "0.6026203", "0.5997902", "0.5992993", "0.59714544", "0.59629637", "0.596214", "0.59556...
0.6748253
0
This function sorts the change order status drop down into the logical Miller order
function sortChangeOrderStatus(json) { console.log('JSONNNN == ', json); let tmp = json.slice(0); tmp[0] = json[0]; tmp[1] = json[5]; tmp[2] = json[1]; tmp[3] = json[2]; tmp[4] = json[3]; tmp[5] = json[4]; return tmp; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "processSortItemsByStatus() {\n // IF WE ARE CURRENTLY INCREASING BY STATUS SWITCH TO DECREASING\n if (window.todo.model.isCurrentItemSortCriteria(ItemSortCriteria.SORT_BY_STATUS_INCREASING)) {\n window.todo.model.sortTasks(ItemSortCriteria.SORT_BY_STATUS_DECREASING);\n }\n //...
[ "0.64060843", "0.6264458", "0.61297524", "0.6110608", "0.605366", "0.60280955", "0.59379876", "0.592002", "0.590072", "0.580668", "0.57901853", "0.5781383", "0.577928", "0.57735467", "0.5734747", "0.57314366", "0.5699788", "0.5681236", "0.567033", "0.5668917", "0.56298196", ...
0.58659995
9
This function saves a project with the current chnage order values INNER FUNCTION CALLS: goToProjectManager()
function saveProject_CHANGE_ORDER() { console.log('saving project'); var proposalDate = $('#changeOrder').find('#proposalDate').val(); var submittedDate = $('#changeOrder').find('#submittedDate').val(); var approvedDate = $('#changeOrder').find('#approvedDate').val(); var customerCO = $('#changeOrder').find...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function save() {\n localStorage.setItem(LOCAL_STORAGE_PROJECT_KEY, JSON.stringify(projects));\n localStorage.setItem(\n LOCAL_STORAGE_SELECTED_PROJECT_ID_KEY,\n selectedProjectId\n );\n}", "save() {\n get(this, 'project').save().then(() => {\n this._enterReadMode();\n this._inferIfNe...
[ "0.67016786", "0.66592175", "0.6278591", "0.6203162", "0.620056", "0.6163862", "0.60785735", "0.6069817", "0.6045731", "0.6028371", "0.6017679", "0.5994743", "0.5939255", "0.5877535", "0.58750796", "0.5852172", "0.5844793", "0.584361", "0.5834048", "0.57955736", "0.57512355",...
0.62250763
3
This function checks to see if the entered date is in valid form
function isValidInput_CHANGE_ORDER(dates) { //Check if all of the dates are in the correct format for (var i = 0; i < dates.length; i++) { var date = dates[i]; if (date != '' && !isDate(date)) { console.log('----------'); console.log(date); console.log('----------'); console.log(i);...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function dateValidation( date ) {\n\n\t\tvar pass = /^\\d{4}-\\d{2}-\\d{2}/.test( date );\n\t\treturn pass;\n\n\t}", "function dateValidator() {\n var dateFormat = /^\\d{2}\\/\\d{2}\\/\\d{4}$/;\n var now = new Date(Date.now()); //get currents date\n if (!dateFormat.test(this.value)) {\n alert(\"You...
[ "0.8084598", "0.80604243", "0.8025189", "0.78648245", "0.7819866", "0.78152204", "0.7785086", "0.77622485", "0.7736102", "0.7681407", "0.7659603", "0.76471514", "0.76442873", "0.76102173", "0.7530134", "0.75172937", "0.7501759", "0.74965614", "0.7489857", "0.74806434", "0.746...
0.0
-1
This function displays the change order div along with if the user is creating a new change order or if editing an old one INNER FUNCTION CALLS: clearTabs_CHANGE_ORDER(), getDropdownInfo_CHANGE_ORDER()
function goToChangeOrder(edit) { clearTabs_CHANGE_ORDER(); $('.editProject').hide(); $('#changeOrder').show(); $('#changeOrderInfo').addClass('active'); setCurrentDivLocation('changeOrder'); console.log('EDIT = ', edit); if (edit == 0) { edit_CHANGE_ORDER = 'false'; $('#deleteChangeOrderButton').h...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fillTabs_CHANGE_ORDER(json) {\n console.log('EDIT == ', edit_CHANGE_ORDER);\n console.log('CHANGE ORDERS = ', PROJECT_DATA.changeOrders);\n\n var nextCOnum;\n\n if (PROJECT_DATA.changeOrders.length)\n nextCOnum = PROJECT_DATA.changeOrders.length;\n else nextCOnum = 1;\n\n var changeOrderToEdit;\n...
[ "0.6931639", "0.6788614", "0.67869383", "0.6688601", "0.6623055", "0.65345496", "0.6401154", "0.61966115", "0.61819893", "0.61313045", "0.6114441", "0.60838944", "0.60713315", "0.6060486", "0.6029073", "0.59909636", "0.59890205", "0.598315", "0.5955726", "0.59228873", "0.5916...
0.6875146
1
This function deletes the selected change order from the database INNER FUNCTION CALLS: goToProjectManager()
function deleteChangeOrder() { if ( !confirm( 'Are you sure you want to permanently delete this pricing element?' ) ) return; console.log('PROJECT = ', PROJECT_DATA); for (var i = 0; i < PROJECT_DATA.changeOrders.length; i++) { if (PROJECT_DATA.changeOrders[i].id == selectedChangeOrder) {...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function deleteActiveProject() {\n\n //Reads the page header to determine current project name, then deletes that project.\n cy.get('.header__breadcrumb-link')\n .first()\n .then(($x) => {\n const projectName = $x.attr('title')\n deleteProject(projectName)\n })\n}", "function delete_project(...
[ "0.5800834", "0.5774076", "0.57342327", "0.57116544", "0.5686459", "0.5620177", "0.5588917", "0.5535695", "0.5517773", "0.5479353", "0.5436079", "0.54312766", "0.5428533", "0.54279286", "0.5411769", "0.5409189", "0.5408953", "0.54012567", "0.5381581", "0.53773206", "0.5360917...
0.6887535
0
This function alters how a change order is displayed in the changeOrderTable
function toggleChangeOrder(source) { $(source).siblings().css('background-color', 'white'); $(source).css('background-color', '#dddddd'); $('#editChangeOrder').prop('disabled', false); selectedChangeOrder = $(source).attr('value'); CHANGE_ORDER_ID = selectedChangeOrder; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fillChangeOrders(data) {\n clearChangeOrderTable();\n console.log('CALLED FILL CO', data);\n if (data) CHANGE_ORDERS = data.changeOrders;\n let changeOrders = CHANGE_ORDERS;\n\n changeOrders.sort(function (a, b) {\n if (!a.id) return -1;\n if (!b.id) return 1;\n\n if (a.id < b.id) return -1;...
[ "0.68385243", "0.6431598", "0.64193046", "0.63318145", "0.62034166", "0.6179597", "0.61165035", "0.6041773", "0.6033468", "0.6023787", "0.5980125", "0.5967024", "0.5930546", "0.5895414", "0.5861631", "0.58550686", "0.5818042", "0.58160067", "0.58038807", "0.57886314", "0.5762...
0.60031295
10
////////////////////////Navigational //////////////////////////////// ///////////////////////////////////////////////////////////////////// This function makes the findProject div visible and hides all other divs INNER FUNCTION CALLS: none
function goToFindProject() { $('#editTask').prop('disabled', true); $('#editEquipment').prop('disabled', true); $('#editChangeOrder').prop('disabled', true); clearPermitsAndInspectionsOverview(); updateFrontEnd(); sortTable($('#sortProjectsValue').val()); switch (currentDivLocation) { case 'projectDat...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function hideProject() {\n //remove the added dom elements\n img.remove();\n hr.remove();\n p.remove();\n linkContainer.remove();\n\n //change the styles back to the originals\n styles.width = 50 + 'px';\n styles.height = 50 + 'px';\n styles.top = top;\n styles.lef...
[ "0.75376403", "0.71062136", "0.6867802", "0.686017", "0.683631", "0.6785863", "0.6695727", "0.6691751", "0.65827805", "0.6576703", "0.65013003", "0.64828897", "0.6456804", "0.6447448", "0.63662857", "0.6329709", "0.6301449", "0.62833595", "0.62611234", "0.62611234", "0.625286...
0.6392181
14
This function makes the projectManager div visible while hiding the remaining divs It also manages the activeness of the infotabs INNER FUNCTION CALLS: setCurrentDivLocation()
function goToProjectManager() { $('#editTask').prop('disabled', true); $('#editEquipment').prop('disabled', true); $('#editChangeOrder').prop('disabled', true); $('.editProject').hide(); $('#projectManager').show(); console.log('GTPM CURRENT LOCATION = ', currentDivLocation); switch (currentDivLocation) ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function hideProject() {\n //remove the added dom elements\n img.remove();\n hr.remove();\n p.remove();\n linkContainer.remove();\n\n //change the styles back to the originals\n styles.width = 50 + 'px';\n styles.height = 50 + 'px';\n styles.top = top;\n styles.lef...
[ "0.7027211", "0.6687694", "0.6511587", "0.6498153", "0.6455439", "0.6455439", "0.6454459", "0.64425784", "0.6412564", "0.64011186", "0.6383012", "0.63407797", "0.62443423", "0.6198644", "0.6165978", "0.6163384", "0.61027014", "0.6088273", "0.60831934", "0.6028165", "0.6018064...
0.61492914
16
This function sets the current div location so we know what to display INNER FUNCTION CALLS: none
function setCurrentDivLocation(location) { currentDivLocation = location; console.log('LOCATION = ', location); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function showPosition() {\n}", "function showCoordsSelection(){\r\n\t// if other selection is open, close it\r\n\tif (selectionStatus.date == true){ showDateSelection(); };\r\n\r\n\tconsole.log(\"hide/show Coordinate Selection \");\r\n\r\n\t// calculating direction of div (up or down)\r\n\tif (selectionStatus.co...
[ "0.65537035", "0.61844313", "0.6094723", "0.60823077", "0.6070361", "0.6042133", "0.59412146", "0.5893638", "0.58811605", "0.58737576", "0.58583224", "0.5851839", "0.58499116", "0.5839878", "0.5788199", "0.57820165", "0.5774556", "0.5771294", "0.5769348", "0.57665974", "0.576...
0.6750373
0
This function converts the current Div Location in order to display a proper header INNER FUNCTION CALLS: none
function convertCurrentDivLocation(currentDivLocation) { console.log('CURRENT DIV: ', currentDivLocation); switch (currentDivLocation) { case 'projectManager': $('#' + currentDivLocation) .find('#pageLocation') .html("<p>Project Manager <small id='projectHeader'>---</small></p>"); br...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setCurrentDivLocation(location) {\n currentDivLocation = location;\n console.log('LOCATION = ', location);\n}", "function getHardwareDetail(div, url, thisObject, input, divPos) {\n invokeAjax(url + input, function callback(result) {\n var padding = 10;\n // Replace div area content wi...
[ "0.60878867", "0.5705811", "0.55914557", "0.5548104", "0.5531624", "0.5523784", "0.5496906", "0.54921454", "0.5482236", "0.5467987", "0.5425408", "0.5403262", "0.53925806", "0.5357265", "0.5353366", "0.5304452", "0.5298767", "0.52880913", "0.52730775", "0.52600986", "0.523967...
0.6529843
0
This function updates all of the data on the front end CURRENTLY THIS FUNCTION DOES NOTHING INNER FUNCTION CALLS: none
function updateProjectManager() { if (currentDivLocation == 'projectData') { } else if (currentDivLocation == 'permitData') { } else if (currentDivLocation == 'closeoutData') { } else if (currentDivLocation == 'scorecardData') { } else { console.log('Not Prepared for this div location!'); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateData() {\n\t/*\n\t* TODO: Fetch data\n\t*/\n}", "function updateAll() {\n updateForces();\n updateDisplay();\n}", "update() {\n this.dataChanged = true;\n this.persons.all = undefined;\n this.jobTitles.all = undefined;\n this.updateFiltered();\n this.upda...
[ "0.7601106", "0.7214134", "0.7078584", "0.7067765", "0.6972048", "0.6940846", "0.6925894", "0.689315", "0.6868043", "0.68592227", "0.6757076", "0.6743879", "0.6735226", "0.67235065", "0.6697107", "0.6684723", "0.6661656", "0.66595775", "0.6658846", "0.663562", "0.6635258", ...
0.0
-1
This function is used in projects.html in order to properly prepare which div will be displayed along with which features to make available INNER FUNCTION CALLS: getParameterByName(), getProject_PROJECT_MANAGER(), getAllProjects()
function preparePage() { let id = getParameterByName('id'); let from = getParameterByName('from'); let type = getParameterByName('type'); //new lines added by me //window.alert("Saurabh"); $('#findProject').hide(); $('.editProject').hide(); if (id) { projectID = id; EDIT_INTENTION = true; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function display_projects_list(){\n\t\n\t// Récupérer liste des projets\n\tcall_webservice(1);\n\t\n\t// Construire le code html de la liste\n\tvar i,html;\n\tif ( dataRetourJSON.errors != undefined ){\n\t\thtml = dataRetourJSON.errors[0];\n\t}else{\n\t\thtml = \"<table cellpadding='0' cellspacing='0'>\";\n\t\tfor...
[ "0.70123225", "0.6922276", "0.67154217", "0.67116696", "0.670622", "0.6647127", "0.6611138", "0.6600617", "0.65355617", "0.65258694", "0.65042573", "0.6440602", "0.6416169", "0.6414076", "0.64075744", "0.6381319", "0.6372799", "0.6317451", "0.6314473", "0.62903404", "0.628930...
0.70991796
0
This is the function that sorts the table of projects based on some criteria
function sortTable(n) { if ($('#dashboardViewValue').val() == '0') { var table, rows, switching, i, x, y, shouldSwitch; table = document.getElementById('results'); switching = true; /*Make a loop that will continue until no switching has been done:*/ while (switching) { if (n == '-1') b...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function sortByProjectByName(a, b) {\n var p1 = a[3].toLowerCase();\n var p2 = b[3].toLowerCase();\n\n var n1 = a[0].toLowerCase();\n var n2 = b[0].toLowerCase();\n\n if (p1 < p2) return -1;\n if (p1 > p2) return 1;\n if (n1 < n2) return -1;\n if (n1 > n2) return 1;\n return 0;\n}", "function createTask...
[ "0.695542", "0.6590979", "0.6561586", "0.6441237", "0.6372105", "0.630694", "0.61737734", "0.61692834", "0.6098054", "0.59972256", "0.5916829", "0.5911098", "0.58991253", "0.5875032", "0.5872223", "0.5869777", "0.58515126", "0.5820286", "0.581137", "0.58016825", "0.57910997",...
0.0
-1
TODO A.R.G When the rule is clicked, take the user to location so that he can update the issue
function fixingRules(category, text) { console.log(typeof category); switch (category) { case 'general': $('#projectInformationTabLink').trigger('click'); $('#general-info-item').trigger('click'); $('#backToFailedRules').show(); $('#backToFailedRules').html('General Rules'); break;...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function openRuleView() {\n return openInspectorSideBar(\"ruleview\");\n}", "function selectIssue(issue) {\n Issues.setIssue(issue);\n }", "function onClickMarker(title, attributes) {\n\t\n\tvar restriction = ' regviolation.location_id IS NOT NULL ';\n var attributes = eval(\"(\" + attributes + \")\");...
[ "0.5681954", "0.55513084", "0.5526347", "0.5382928", "0.53775513", "0.5353314", "0.5323757", "0.53041077", "0.5289294", "0.52420604", "0.52319324", "0.52304524", "0.5194807", "0.5188807", "0.51737964", "0.51637495", "0.5163323", "0.5159217", "0.51490694", "0.5144385", "0.5134...
0.52598166
9
THIS CONTAINS ALL THE PENDING INVOICE FUNCTIONS ////////////////////////////////////////////////////////// AUTHOR : AKASH GURRAM START OF PENDING INVOICES FUNCTIONS This function generates the Report for a project's Pending Invoices
function projectPendInvReport() { window.open( 'Report?' + 'id=' + projectID + '&type=Project PendInv Report ' + '~' + $('#pendingInvoiceSelector2').val() ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function submitPendInv() {\n let invoiceNum = $('#pendingInvoiceCreationZone')\n .find('#invoiceNumberPend')\n .val();\n let invoiceAmt = $('#pendingInvoiceCreationZone')\n .find('#invoiceAmtPend')\n .val();\n let subNames = $('#pendingInvoiceCreationZone').find('#subNamesPend').val();\n let submit...
[ "0.6172085", "0.6105018", "0.6027122", "0.5992188", "0.5896902", "0.58473873", "0.5830142", "0.57962155", "0.57900125", "0.57660145", "0.5691363", "0.56450886", "0.56319714", "0.5627997", "0.5574965", "0.55393636", "0.5511136", "0.5488783", "0.5488471", "0.54707956", "0.54340...
0.6406536
0
This function creates a new or updates an older pending invoice.
function submitPendInv() { let invoiceNum = $('#pendingInvoiceCreationZone') .find('#invoiceNumberPend') .val(); let invoiceAmt = $('#pendingInvoiceCreationZone') .find('#invoiceAmtPend') .val(); let subNames = $('#pendingInvoiceCreationZone').find('#subNamesPend').val(); let submittedDate = $('...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function createPendInv() {\n PENDINV_ACTION = 'createPendInv';\n clearPendInvForm();\n document.getElementById('pendingInvoiceInformation').style.width = '100%';\n $('#pendingInvoiceDisplay').hide();\n $('#pendingInvoiceCreationZone').show();\n $('#pendingInvoiceInformation')\n .find('#pendingInvoiceCreat...
[ "0.64679843", "0.6362667", "0.6040656", "0.6003635", "0.5900384", "0.5896818", "0.58357435", "0.57764363", "0.5724445", "0.57055193", "0.5698505", "0.56935877", "0.56606513", "0.5641225", "0.5619957", "0.56032455", "0.5563304", "0.5557549", "0.554323", "0.55369216", "0.552217...
0.5858979
6
This function gets all the subcontractors from the data bases Inner Function call : createDropdownPend()
function getSubcontractorsPend() { $.ajax({ type: 'POST', url: 'Project', data: { domain: 'project', action: 'getSubcontractors', }, complete: function (data) { if (data.responseJSON) { createSubDropdownPend(data.responseJSON); //createSubDropdownInv(data.response...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getSubcontractors() {\n\t$.ajax({\n\t\ttype: 'POST',\n\t\turl: 'Project',\n\t\tdata: {\n\t\t\t'domain': 'project',\n\t\t\t'action': 'getSubcontractors',\n\t\t}, complete: function (data) {\n\t\t\tconsole.log(\"RESPONSE JSON FOR getSubcontractors() = \",data.responseJSON);\n\t\t\tif (data.responseJSON) {\n...
[ "0.74416083", "0.6533046", "0.635505", "0.62281805", "0.61956525", "0.61858463", "0.61732537", "0.6140655", "0.6101372", "0.6093875", "0.60897756", "0.6089241", "0.60153615", "0.6015011", "0.5997102", "0.59936994", "0.5989526", "0.5977554", "0.5960304", "0.59444577", "0.59349...
0.6324098
3
This function based on the getSubcontractorsPend(), creates a dropdown for SubName in Pending Invoice
function createSubDropdownPend(json) { let d = document.createDocumentFragment(); json.sort(function (a, b) { if (a.name < b.name) return -1; else if (a.name > b.name) return 1; return 0; }); for (var i = 0; i < json.length; i++) { let option = document.createElement('option'); option.inne...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getSubcontractors() {\n\t$.ajax({\n\t\ttype: 'POST',\n\t\turl: 'Project',\n\t\tdata: {\n\t\t\t'domain': 'project',\n\t\t\t'action': 'getSubcontractors',\n\t\t}, complete: function (data) {\n\t\t\tconsole.log(\"RESPONSE JSON FOR getSubcontractors() = \",data.responseJSON);\n\t\t\tif (data.responseJSON) {\n...
[ "0.70727104", "0.64052826", "0.6200818", "0.612091", "0.608753", "0.60699224", "0.6066946", "0.5860588", "0.5826358", "0.58166355", "0.5769443", "0.57546496", "0.57340765", "0.5692162", "0.5690649", "0.5651308", "0.5636745", "0.56046516", "0.55989873", "0.5589558", "0.5574387...
0.60439044
7
This function fills the Pending Invoices Table based on the filer selected (Open, Complete, Open & Complete, Closed)
function fillPendInvsTable(pendInvs) { let selector = $('#pendingInvoiceSelector2').val(); clearPendingInvoiceTable(); let count = 0; for (var i = 0; i < pendInvs.length; i++) { if ( (selector === 'open' && pendInvs[i].status != 'Open') || (selector === 'complete' && pendInvs[i].status != 'Compl...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fillInvsTable() {\n\t\n\tlet selector = $('#invoiceSelector2').val();\t\n\t\t\n\tclearInvoiceTable();\n\t//let invs = data;\n\tlet count = 0;\n\t\n\t//shows invoices based on filter selection\n\tmainLoop:\n\tfor (var i = 0; i < invs.length; i++) {\n\t\tif(\t(selector == 'all' && (invs[i].invoiceStatus != ...
[ "0.7173295", "0.6001757", "0.5858764", "0.58221114", "0.5761338", "0.5746565", "0.5652667", "0.56269944", "0.5572741", "0.55223304", "0.5516104", "0.55004615", "0.54790103", "0.5457811", "0.5423783", "0.539456", "0.5363329", "0.52588326", "0.5214743", "0.52109784", "0.5202251...
0.7010687
1
This function shows the Pending Invoice Form when Add Pending Invoice is clicked It hides other divs. It also sets the status of a new pending Invoice to Open
function createPendInv() { PENDINV_ACTION = 'createPendInv'; clearPendInvForm(); document.getElementById('pendingInvoiceInformation').style.width = '100%'; $('#pendingInvoiceDisplay').hide(); $('#pendingInvoiceCreationZone').show(); $('#pendingInvoiceInformation') .find('#pendingInvoiceCreationZone') ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function displayPendInvWell() {\n console.log('PendInc ACTION: ', PENDINV_ACTION);\n\n $('#pendingInvoiceInformation').find('#pendingInvoiceDisplay').hide();\n $('#pendingInvoiceInformation').find('#pendingInvoiceCreationZone').show();\n $('#pendingInvoiceInformation')\n .find('#pendingInvoiceCreationZone')...
[ "0.72457147", "0.6781828", "0.67257893", "0.67233396", "0.6620463", "0.65569496", "0.65211403", "0.6464971", "0.64620054", "0.63916713", "0.6294111", "0.625713", "0.6221699", "0.6214458", "0.62047136", "0.6200859", "0.6179926", "0.6178993", "0.61496836", "0.6109649", "0.60931...
0.7507388
0
This function clears the Pending Invoice form to be empty when a add pending invoice is clicked.
function clearPendInvForm() { $('#pendingInvoiceCreationZone').find('#invoiceNumberPend').val(''); $('#pendingInvoiceCreationZone').find('#invoiceAmtPend').val(''); $('#pendingInvoiceCreationZone').find('#subNamesPend').val(''); $('#pendingInvoiceCreationZone').find('#submittedDatePend').val(''); $('#pendingI...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function clearOrderForm() {\n currentOrder = {};\n fillOrder({});\n fillOrderItemList({});\n $('#buttonDelete').hide();\n $('#buttonCreate').hide();\n $('#buttonSave').hide();\n}", "function clearAddform(){\n $(\"#qty\").css(\"border-color\", \"#eee\"); //rollback when not empty\n ...
[ "0.71297824", "0.68049014", "0.677924", "0.66837335", "0.667266", "0.663027", "0.65872735", "0.65862894", "0.65810454", "0.65638334", "0.6560708", "0.6558748", "0.65402573", "0.6538108", "0.6529142", "0.65208054", "0.6490126", "0.6455219", "0.6446502", "0.64401746", "0.643731...
0.77462935
0
This function displays the following messages when Back to Pending Invoices in clicked in the form
function viewPendInv() { let updateMessage = 'These changes will not be saved, are you sure you want to leave the screen?'; let createMessage = 'This Pending Invoice will not be added, are you sure you want to leave this screen?'; let displayedMessage; if (PENDINV_ACTION == 'createPendInv') displayedMe...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function viewInv() {\n $('#invoiceTable tr').css('background-color', '');\n\n let updateMessage =\n 'These changes will not be saved, are you sure you want to leave the screen?';\n let createMessage =\n 'This Invoice will not be added, are you sure you want to leave this screen?';\n let displayedMessage;...
[ "0.67560315", "0.66759175", "0.6626295", "0.65299296", "0.62822187", "0.6087641", "0.6050769", "0.6034597", "0.6015101", "0.5933136", "0.59191954", "0.5865569", "0.5813263", "0.5774204", "0.574014", "0.57344633", "0.572004", "0.57147133", "0.5707809", "0.57062024", "0.5687599...
0.67057014
1
This function enables the Edit Pending Invoice button when a Pending Invoice is single clicked in the table
function togglePendInv(source) { $(source).siblings().css('background-color', 'white'); $(source).css('background-color', '#dddddd'); $('#editPendingInvoice').prop('disabled', false); SELECTED_PENDINV_ID = $(source).attr('value'); console.log('Pend Inv id = ', SELECTED_PENDINV_ID); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function toggleEditBtn(){\n\t//get the number of total rows\n\tvar numRows = showTotalRowNumber();\n\t//if no rows exist\n\tif(numRows <= 0){\n\t\t//disable Edit Button\n\t\t$.editTransects.enabled = false;\n\t\t$.editTransects.title = \"Edit\";\n\t\t$.addTransect.enabled = true;\n\t\t$.tbl.editing = false;\n\t}el...
[ "0.70791733", "0.68010604", "0.6711384", "0.67080456", "0.6702838", "0.66413546", "0.66339403", "0.65496534", "0.64740247", "0.64609075", "0.64483577", "0.644722", "0.6368006", "0.6365797", "0.62940454", "0.62833244", "0.6239207", "0.6238212", "0.6218857", "0.6194555", "0.614...
0.6652893
5
This function opens the edit form of the pending invoice when double clicked.
function editSelectedPendInv() { PENDINV_ACTION = 'updatePendInv'; displayPendInvWell(); fillPendInvWell(SELECTED_PENDINV_ID); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "onBtnEditClick() {\n\t\tthis.changeTripReportMode('edit');\n\t}", "function click_edit() {\n\t document.getElementById('submit_edit_paciente').click();\n\t}", "function editar() {\n\n\t$('#mdlAgendamento').modal('toggle');\n\t$('#mdlVerAgendamento').modal('hide');\n\n}", "function edit() {\n ...
[ "0.6738161", "0.65945715", "0.6494615", "0.6490141", "0.6490141", "0.64893776", "0.64832103", "0.6479952", "0.64257115", "0.6329796", "0.63206494", "0.61794543", "0.6177457", "0.61716413", "0.6167973", "0.6150637", "0.6149265", "0.6147721", "0.61349684", "0.6132453", "0.61158...
0.66155624
1
This function shows the form.
function displayPendInvWell() { console.log('PendInc ACTION: ', PENDINV_ACTION); $('#pendingInvoiceInformation').find('#pendingInvoiceDisplay').hide(); $('#pendingInvoiceInformation').find('#pendingInvoiceCreationZone').show(); $('#pendingInvoiceInformation') .find('#pendingInvoiceCreationZone') .find(...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function showForm() {\n\t\t\teManager.trigger('cleanManagementBox');\n\t\t\ttemplates.render('csv-form', {}, function(html) {\n\t\t\t\tvar $boxContent = $('#management-box ._box-content');\n\t\t\t\t$boxContent.append(html);\n\t\t\t});\n\t\t\teManager.trigger('showManagementBox');\n\t\t}", "function showForm() {\...
[ "0.76910055", "0.7484891", "0.7088672", "0.7080216", "0.70655674", "0.69752955", "0.6963174", "0.68339837", "0.68034905", "0.6801268", "0.6791787", "0.6791253", "0.67800575", "0.67790335", "0.6775341", "0.67703927", "0.6755873", "0.67521375", "0.6749019", "0.6749019", "0.6739...
0.0
-1
This function fills the form using the old data. i.e., it is called in edit pending invoice so that older values are filled.
function fillPendInvWell(source) { let tmp_id = source; let selected_pendInv; for (var i = 0; i < pendInvs.length; i++) { if (pendInvs[i].id == tmp_id) { selected_pendInv = pendInvs[i]; SELECTED_PENDINV_ID = pendInvs[i].id; } } if (!selected_pendInv) { console.log('IMPROPER PENDINV S...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function reset_form_data() {\n $(\"#order_customer_id\").val(\"\");\n $(\"#order_created_date\").val(\"\");\n\n row_num = 0;\n $(\"#order_items\").empty();\n add_row();\n }", "fillForm ( data ) {\n this.title.value = data.title;\n this.body.value = data.body;\n...
[ "0.6805324", "0.6697237", "0.6516819", "0.6506789", "0.646027", "0.6432739", "0.643271", "0.63502926", "0.62926495", "0.6279921", "0.62754065", "0.624738", "0.62427247", "0.6230664", "0.62061244", "0.6156742", "0.61175483", "0.6113444", "0.61133003", "0.6109882", "0.6109752",...
0.5970123
42
This function adds the message No Pending Invoices to show
function clearAndAddSingleRowPendInvs(msg) { $('#pendingInvoiceTable > tbody').children('tr:not(.head)').remove(); let placeHolder = document.createElement('tr'); let listDetails0 = document.createElement('td'); let listDetails1 = document.createElement('td'); let listDetails2 = document.createElement('td');...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function showPending() {\n for (var i in pending) {\n show(pending[i]);\n }\n pending = [];\n\n // Hide the 'N new messages' button\n var el = document.getElementById('pending');\n el.innerHTML = '';\n el.setAttribute('style', 'display: none');\n}", "function viewPendInv() {\n let updateMessage =\n ...
[ "0.6351871", "0.62823665", "0.60852134", "0.58963346", "0.58615184", "0.5789395", "0.57462364", "0.5650815", "0.56215465", "0.5566065", "0.5543532", "0.5531158", "0.55273706", "0.5515748", "0.5491991", "0.54782516", "0.5472486", "0.5459816", "0.5443278", "0.54157186", "0.5409...
0.5925261
3
This function retrieves all of the pendingInvoices from the server INNER FUNCTION CALLS: fillPendInvTable()
function getPendInvs(stopServerCalls) { console.log(projectID); $.ajax({ type: 'POST', url: 'Project', data: { domain: 'project', action: 'getProjectPendInvs', id: projectID, }, success: function (data) { console.log('proj pendingInvoices!!!!', data); let type = get...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fillPendInvsTable(pendInvs) {\n let selector = $('#pendingInvoiceSelector2').val();\n clearPendingInvoiceTable();\n let count = 0;\n for (var i = 0; i < pendInvs.length; i++) {\n if (\n (selector === 'open' && pendInvs[i].status != 'Open') ||\n (selector === 'complete' && pendInvs[i].stat...
[ "0.72523296", "0.64212906", "0.6290469", "0.6241508", "0.60928106", "0.6074083", "0.60113746", "0.5987474", "0.59380424", "0.59193057", "0.5915491", "0.5897184", "0.5858006", "0.57449484", "0.5727415", "0.56937635", "0.5668729", "0.5660703", "0.564723", "0.5616178", "0.555593...
0.663285
1
Invoicing section functions (Invoices) Author: Fardeen Yaqub
function clearPeInvoiceTable() { $('#peInvoiceDisplay').find('#peInvoiceTable').find('tr:not(.head)').remove(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Invoice () {}", "function ciniki_sapos_invoice() {\n this.invoiceTypes = {};\n this.invoiceStatuses = {\n '10':'Entered',\n '20':'Pending Manufacturing',\n '30':'Pending Shipping',\n '40':'Payment Required',\n '50':'Paid',\n '55':'Refund Required',\n ...
[ "0.7201826", "0.66901475", "0.655619", "0.6371861", "0.63419545", "0.6334918", "0.6264966", "0.6211377", "0.6202763", "0.6189469", "0.6167459", "0.6111971", "0.6091981", "0.6088201", "0.60846233", "0.6073092", "0.59906423", "0.59587663", "0.5936344", "0.5908891", "0.5901896",...
0.0
-1
This function converts the peType values to a string Author: Fardeen Yaqub
function parsePETypeStatus(param) { switch (param) { case '0': return 'Project'; case '1': return 'Labor'; case '2': return 'Materials'; case '3': return 'AIA'; default: return '---'; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getCreatorType(aut) {\n\n\t\tvar typeAut = aut['4'].trim();\n\t\tswitch (typeAut) {\n\t\t\tcase \"005\":\n\t\t\tcase \"250\":\n\t\t\tcase \"275\":\n\t\t\tcase \"590\": //performer\n\t\t\tcase \"755\": //vocalist\n\t\t\t\treturn \"performer\";\n\t\t\tcase \"040\":\n\t\t\tcase \"130\": //book designer\n\t\t...
[ "0.57299477", "0.54749703", "0.5415441", "0.5411155", "0.5402825", "0.53769183", "0.5267206", "0.52590805", "0.5224268", "0.5223341", "0.5189367", "0.5142007", "0.51401186", "0.5097267", "0.50942916", "0.509232", "0.5092287", "0.50759643", "0.5060073", "0.5031198", "0.5031011...
0.48854017
35
This function fills the Invoices Table based on the filer selected (Open, Complete, Open & Complete, Closed) Author: Fardeen Yaqub
function fillPeInvsTable(data) { clearPeInvoiceTable(); console.log('CALLED FILL PE', data); if (data) CHANGE_ORDERS = data.changeOrders; let changeOrders = CHANGE_ORDERS; //sorts PE's changeOrders.sort(function (a, b) { if (!a.id) return -1; if (!b.id) return 1; if (a.id < b.id) return -1; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fillInvsTable() {\n\t\n\tlet selector = $('#invoiceSelector2').val();\t\n\t\t\n\tclearInvoiceTable();\n\t//let invs = data;\n\tlet count = 0;\n\t\n\t//shows invoices based on filter selection\n\tmainLoop:\n\tfor (var i = 0; i < invs.length; i++) {\n\t\tif(\t(selector == 'all' && (invs[i].invoiceStatus != ...
[ "0.70198506", "0.66250545", "0.59261274", "0.57039493", "0.565985", "0.5600004", "0.5583862", "0.55489385", "0.55367863", "0.5530007", "0.550964", "0.5481805", "0.5456595", "0.54473996", "0.5440306", "0.54299927", "0.5425426", "0.53935015", "0.53904265", "0.5389418", "0.53689...
0.5898677
3
takes user to invoices
function goToInvoices(source) { hideExtraInvoiceValues(); //sets the selected PE to a global var SELECTED_PE_ID = source; displayInvDisplay(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Invoice () {}", "function docreateinvoice() {\n ModalService.showModal({\n templateUrl: \"modals/createinvoice.html\",\n controller: \"CreateInvoiceController\",\n }).then(function(modal) {\n modal.element.modal();\n modal.close.then(function(result) {\n ...
[ "0.6612413", "0.64914155", "0.6426737", "0.63678217", "0.63043225", "0.62713814", "0.62616485", "0.62197196", "0.60373527", "0.6017707", "0.5885071", "0.5867865", "0.5862601", "0.584282", "0.57671887", "0.57611376", "0.5726542", "0.5687445", "0.5613935", "0.5610082", "0.55851...
0.6919068
0
returns user to Account's Receivable
function goToAccRec() { $('#peInvoiceInformation').show(); $('#invoiceInformation').hide(); $('#financialSection').show(); updatePricingInfo(); fillPeInvsTable(DATA); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function determineAccountReceivable(billToChannelDesc)\r\n{\r\n\r\n\tvar accountReceivable = '';\r\n\tvar arInternalID = '';\r\n\r\n\ttry\r\n\t{\r\n\r\n\t\tbillToChannelDesc = billToChannelDesc.toUpperCase();\r\n\r\n\t\tif(billToChannelDesc.indexOf('DISTRIBUTOR') != -1)\r\n\t\t{\r\n\t\t\tif(regionDesc=='AU') {\r\n...
[ "0.672409", "0.6362496", "0.58519775", "0.56264406", "0.55745363", "0.5514181", "0.5474369", "0.54201204", "0.53354126", "0.5332756", "0.52810895", "0.52713954", "0.5264004", "0.5264004", "0.5242389", "0.5238259", "0.5235872", "0.5207738", "0.5185463", "0.5144821", "0.5139562...
0.0
-1
gets list of invoices for project
function getInvs(stopServerCalls) { console.log(projectID); $.ajax({ type: 'POST', url: 'Project', data: { domain: 'project', action: 'getProjectInvs', id: projectID, }, success: function (data) { console.log('proj Invoices!!!!', data); let type = getParameterByNam...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getAllInvoice() {\n\t\treturn Restangular.all('eas-service/intern05Invoice/intern05Invoice').getList();\n\t}", "function getInvoices(req, res){\r\n\t//Si paso json vacio es que quiero todos los elementos de la bd\r\n\tInvoice.find({}).populate({path: 'user'}).exec((err, invoices) => {\r\n\t\tif(err){\r...
[ "0.73887515", "0.6830307", "0.63840306", "0.6382122", "0.59983826", "0.5898029", "0.58716553", "0.5759898", "0.57317775", "0.5729714", "0.56664383", "0.5617137", "0.5615026", "0.55954", "0.5550561", "0.554298", "0.5533762", "0.5513223", "0.5511289", "0.54622126", "0.5461863",...
0.6203183
4
displays invoice screen using a modal popup mirrors displayInvWell but requires its own styling for whatever reason
function displayInvWell1() { document.querySelector('.bg-modal1').style.display = 'flex'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function viewInv() {\n $('#invoiceTable tr').css('background-color', '');\n\n let updateMessage =\n 'These changes will not be saved, are you sure you want to leave the screen?';\n let createMessage =\n 'This Invoice will not be added, are you sure you want to leave this screen?';\n let displayedMessage;...
[ "0.7316253", "0.729314", "0.72505754", "0.7147935", "0.6923409", "0.6743645", "0.65384835", "0.65273607", "0.64562666", "0.6368791", "0.6346611", "0.62432176", "0.62430966", "0.62394136", "0.6205642", "0.6189277", "0.6163973", "0.6138124", "0.61289346", "0.6106215", "0.610575...
0.69932276
4
Checks to see if a submit/reject date should be added A date is added when the status is changed to Rejected or Submitted. It then sets it to the day the status was changed
function submitRejectDateCheck() { //Status is set to "Rejected" or "Submitted" if ( $('#invoiceInformation') .find('#invoiceCreationZone') .find('#invoiceStatusSelectionRow') .find('#invoiceStatus') .val() == 'Rejected' || $('#invoiceInformation') .find('#invoiceCreationZone')...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function submitRejectDateCheck(){\n\n\t//Status is set to \"Rejected\" or \"Submitted\"\n\tif(($('#invoiceCreationZone').find('#invoiceStatusSelectionRow').find('#invoiceStatus').val() == \"Rejected\" || \n\t$('#invoiceCreationZone').find('#invoiceStatusSelectionRow').find('#invoiceStatus').val() == \"Submitted\")...
[ "0.7440218", "0.594842", "0.59276235", "0.5839394", "0.57838446", "0.56840134", "0.56491053", "0.5638713", "0.5590834", "0.5563116", "0.55614036", "0.55528426", "0.55310726", "0.55228066", "0.5499388", "0.54986006", "0.54949963", "0.5473315", "0.5457152", "0.54304034", "0.541...
0.72821444
1
prompts user when they want to back out of invoice
function viewInv() { $('#invoiceTable tr').css('background-color', ''); let updateMessage = 'These changes will not be saved, are you sure you want to leave the screen?'; let createMessage = 'This Invoice will not be added, are you sure you want to leave this screen?'; let displayedMessage; if (INV_...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ExitPage() {\n\t\talert('Are you sure you want navigate away from this App?');\n\t\tgetit()\n\t}", "function onBackKeyDown() {\n\tif (shouYinEmployee.id) {\n\t\tshowAlert('提示', '请先完成交接班才能退出!');\n\t\treturn;\n\t}\n\tnavigator.notification.confirm('按确定退出程序!', // message\n\tonConfirm, // callback to invoke...
[ "0.671079", "0.6678308", "0.65513927", "0.65335834", "0.63165206", "0.6313396", "0.627712", "0.6270668", "0.6232751", "0.6230154", "0.6223861", "0.62206936", "0.61859035", "0.61584437", "0.6148978", "0.61383164", "0.61382395", "0.6130047", "0.6130047", "0.6127718", "0.6125151...
0.56157446
88
allows user to edit invoice
function editSelectedInv(source) { INV_ACTION = 'updateInv'; clearInvForm(); displayInvWell(); fillInvWell(source); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function prepareToEditInvoice() {\n\t\t\tvar invoiceId = $state.params.invoiceId;\n\t\t\tif (!invoiceId) return;\n\n\t\t\tvar custId = $state.params.customerId;\n\n\t\t\tshowLoader();\n\t\t\t$q.when(LoadRequiredData())\n\t\t\t\t.then(function(msg) {\n\t\t\t\treturn $q.when(invoiceService.getInvoice(invoiceId));\n\...
[ "0.6938256", "0.6825122", "0.64826953", "0.6477872", "0.6451865", "0.64022356", "0.64022356", "0.63729084", "0.6370489", "0.63692063", "0.634778", "0.63432616", "0.63116103", "0.62851095", "0.62466943", "0.62198883", "0.62198883", "0.62198883", "0.62198883", "0.62198883", "0....
0.62882173
13
This function shows the form.
function displayInvWell() { document.querySelector('.bg-modal').style.display = 'flex'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function showForm() {\n\t\t\teManager.trigger('cleanManagementBox');\n\t\t\ttemplates.render('csv-form', {}, function(html) {\n\t\t\t\tvar $boxContent = $('#management-box ._box-content');\n\t\t\t\t$boxContent.append(html);\n\t\t\t});\n\t\t\teManager.trigger('showManagementBox');\n\t\t}", "function showForm() {\...
[ "0.76910055", "0.7484891", "0.7088672", "0.7080216", "0.70655674", "0.69752955", "0.6963174", "0.68339837", "0.68034905", "0.6801268", "0.6791787", "0.6791253", "0.67800575", "0.67790335", "0.6775341", "0.67703927", "0.6755873", "0.67521375", "0.6749019", "0.6749019", "0.6739...
0.0
-1
This function fills the form using the old data. i.e., it is called in edit invoice so that older values are filled.
function fillInvWell(source) { clearInvForm(); let tmp_id = source; let selected_Inv; for (var i = 0; i < invs.length; i++) { //compares all invoices to find the one selected if ('Inv_' + invs[i].id == tmp_id.id) { selected_Inv = invs[i]; INVOICES_STORED = invs[i].id; break; } ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function reset_form_data() {\n $(\"#order_customer_id\").val(\"\");\n $(\"#order_created_date\").val(\"\");\n\n row_num = 0;\n $(\"#order_items\").empty();\n add_row();\n }", "fillForm ( data ) {\n this.title.value = data.title;\n this.body.value = data.body;\n...
[ "0.6837021", "0.6751196", "0.66639054", "0.6583596", "0.65781283", "0.64900446", "0.6451249", "0.6386188", "0.6311374", "0.62939847", "0.62451833", "0.6239147", "0.62259054", "0.62242955", "0.6202486", "0.61857295", "0.61803854", "0.6176558", "0.61625516", "0.6134212", "0.612...
0.58308285
75
submits invoice with user creating or editing an invoice in the invoice menu
function submitInv() { let invoiceID = $('#invoiceCreationZone').find('#invoiceID').val(); let associatedPE = $('#invoiceCreationZone').find('#associatedPE').val(); let invoiceTitle = $('#invoiceCreationZone').find('#invoiceTitle').val(); let invoiceNumber = $('#invoiceCreationZone').find('#invoiceNumber').val(...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function docreateinvoice() {\n ModalService.showModal({\n templateUrl: \"modals/createinvoice.html\",\n controller: \"CreateInvoiceController\",\n }).then(function(modal) {\n modal.element.modal();\n modal.close.then(function(result) {\n });\n });\n }", "f...
[ "0.707844", "0.65922964", "0.6539826", "0.6515872", "0.65064716", "0.64879704", "0.64358777", "0.64342743", "0.64167434", "0.63701516", "0.63250655", "0.63078094", "0.62857413", "0.6212986", "0.60890543", "0.6065483", "0.5996591", "0.5980918", "0.5943579", "0.5925856", "0.589...
0.67138994
1
submits invoice from pe summary menu
function submitInv1() { let invoiceID = $('#invoiceCreationZone1').find('#invoiceID1').val(); let associatedPE = $('#invoiceCreationZone1').find('#associatedPE1').val(); let invoiceTitle = $('#invoiceCreationZone1').find('#invoiceTitle1').val(); let invoiceNumber = $('#invoiceCreationZone1').find('#invoiceNumbe...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function docreateinvoice() {\n ModalService.showModal({\n templateUrl: \"modals/createinvoice.html\",\n controller: \"CreateInvoiceController\",\n }).then(function(modal) {\n modal.element.modal();\n modal.close.then(function(result) {\n });\n });\n }", "f...
[ "0.64464605", "0.6351418", "0.6320567", "0.6294735", "0.6252583", "0.61968374", "0.6155164", "0.6122657", "0.60241896", "0.60128266", "0.6012358", "0.60007393", "0.5971196", "0.59590226", "0.59491956", "0.59374124", "0.5895293", "0.58934754", "0.58672386", "0.58669835", "0.58...
0.6388703
1
A simple example > Here we are going to find the power of a number using recursion
function pow(number, power) { if (power == 1) { console.log("number",number) return number; } else { console.log("power",power) console.log("number",number) return number * pow(number, power - 1) } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function power(a,n){\n if(n===0){\n return 1\n }\n else{\n \n return a* power(a,n-1)\n }\n \n}", "function powerCalculator(number, exponent){\n if (exponent < 0) {\n return 'exponent should be >= 0'\n }\n if (exponent === 1) {\n return number\n }\n ...
[ "0.7704879", "0.77013886", "0.7556487", "0.7554671", "0.7544358", "0.7522956", "0.74759275", "0.74247104", "0.74121445", "0.7393808", "0.733592", "0.7294414", "0.72935027", "0.72711146", "0.7261872", "0.72594726", "0.72340554", "0.7203629", "0.720341", "0.72015053", "0.719306...
0.8076606
0
src: this.data.assetsImages + 'vip/vip_crde1.png',
success(res) { console.log(res.width); console.log(res.height); let imgH = res.height/res.width*W ctx.drawImage('/assets/images/vip/vip_crde1.png', 0, 0, res.width, res.height, 0, 0 , W, imgH) // ctx.drawImage(this.data.assetsImages + 'vip/vip_crde1.png', 0, 0...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getImageSource(){\n return `assets/images/cards/${this.rank}_of_${this.suit}.png`;\n }", "function addPathToImage() {\n $(ctrl.imageTags).each(function (index) {\n if (ctrl.imageTags[index].hasAttribute('id')) {\n var imageSrc = ctrl.imageTags[in...
[ "0.7368568", "0.701181", "0.68422574", "0.68054026", "0.67752403", "0.6728993", "0.6715093", "0.66019595", "0.65721756", "0.6565977", "0.6552734", "0.645015", "0.644314", "0.64334553", "0.63977313", "0.63965356", "0.6396491", "0.63775975", "0.636491", "0.6346859", "0.63207406...
0.0
-1
TODO: Create a function to write README file
function writeToFile(fileName, data) { fs.writeFile(fileName, data, err => { if (err) { return console.log(err); } console.log("Congrats! Your README is operational!") }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function writeREADME(savefileName, data) {\n fs.writeFile(savefileName, data, () => {});\n \n console.log('Your README has been generated, check the dist folder')\n}", "function writeToFile(data) {\n fs.writeFile(\"./README.md\", generatePage(data), (err) => {\n if (err) throw new Error(err);\n\n conso...
[ "0.80459154", "0.769568", "0.7688438", "0.7662486", "0.7625201", "0.7613852", "0.7600793", "0.75778055", "0.7540343", "0.7540213", "0.75199854", "0.75136596", "0.7454612", "0.74240106", "0.7417176", "0.7403209", "0.7387397", "0.73748857", "0.736913", "0.7356774", "0.7356653",...
0.0
-1
TODO: Create a function to initialize app
async function init() { try { const userResponses = await inquirer.prompt(questions); console.log("Your responses: ", userResponses); console.log("Thank you for your responses! Fetching your GitHub data next..."); const userInfo = await api.getUser(userResponses); console.log("Your Gi...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function initApp() {\n var router = new App.Router();\n var dispatcher = new App.Dispatcher();\n\n router.once('route', function() {\n dispatcher.runAction(router.getCurrent(), router.getParams());\n });\n\n // Start!\n router.startHistory();\n}", "function initApp() {\n\tinitSounds();\n\tinitSensors();...
[ "0.79483765", "0.77004915", "0.75859904", "0.7392242", "0.73389673", "0.7337566", "0.7098709", "0.7094714", "0.70335907", "0.70264256", "0.70233685", "0.69898516", "0.6983825", "0.6980272", "0.69399434", "0.6926202", "0.69252443", "0.69087744", "0.68747747", "0.6861737", "0.6...
0.0
-1
Fetch the data from the radio api Play radio function
async function playRadio(prop){ console.log('Loading Radio'); const { sound } = await Audio.Sound.createAsync( { uri: data[prop].url }, { shouldPlay: true }, setRadioLink(prop), setRadioName(data[prop].name), setCat(styles.cat) ); setSound(sound); console.log("Playing ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getQuestion() {\n this.setMethod('GET');\n this.setPlayerId();\n return this.getApiResult(`${Config.PLAY_API}/${this.playerId}/question`);\n }", "getAnswers() {\n this.setMethod('GET');\n this.setPlayerId();\n return this.getApiResult(`${Config.PLAY_API}/${this.playerId}/answer`);\n }", "ge...
[ "0.604885", "0.6034245", "0.59889114", "0.59712064", "0.59563434", "0.58512557", "0.58022815", "0.56987226", "0.5697084", "0.5693301", "0.56867796", "0.5663506", "0.56567675", "0.5644355", "0.5640888", "0.563892", "0.5635088", "0.5593712", "0.5587287", "0.5548421", "0.5536787...
0.59877604
3
execute main function for logic set, the context of this function is always the node
function execute( selector, options ) { let eventname = ( typeof options !== "undefined" && options.hasOwnProperty( "eventname" ) ) ? options.eventname : "timerpoke", nodes = ( selector ) ? this.querySelectorAll( selector ) : [ this ]; for ( let node of nodes ) { let tid = set...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function main() {\n doCbaam()\n doEcb()\n updateGraphFile()\n}", "execute_program(){\n\t// execution loop\n\twhile(!this.step()){}\n}", "function execute_tree() {\n root.Execute();\n}", "function run() {}", "function Main() {\n buildinterface();\n interfaceLogic();\n }", "run...
[ "0.641275", "0.63051665", "0.60556644", "0.6017696", "0.59856635", "0.59671575", "0.5951979", "0.5940442", "0.5922307", "0.5922244", "0.5907927", "0.5905115", "0.5891366", "0.5868663", "0.5848075", "0.5827018", "0.58149767", "0.5800146", "0.5796376", "0.5774734", "0.5734775",...
0.0
-1
Name this function so that class name will come up in debugger, etc. Note the checklistCollection will be passed for extensionCollection into parent so it can do upserts Also need itemsCollections to check for owners of items
function UpdateGPOchecklist(collections,session,config) { //Run the parent constructor first // "_id" is the updateKey used for updating checklists // "checklist" is just updateName which is text used on errors, logging, etc this.__parent__.constructor.call( this, '_id', 'checklist', //D...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function collectionChecker(name, items)\r\n{\r\n\treturn function(collection)\r\n\t{\r\n\t\tcheckCollection(collection, name, items);\r\n\t\tstart();\r\n\t}\r\n}", "\"groceryLists.update\"(_id, item) {\n if (!this.userId) {\n throw new Meteor.Error(\"Not authorized\");\n }\n\n new SimpleSchema({\n ...
[ "0.5866923", "0.5734786", "0.56511563", "0.55208063", "0.5467889", "0.54187775", "0.53828037", "0.5349579", "0.5331004", "0.527151", "0.52237135", "0.5211492", "0.52101815", "0.52101815", "0.52101815", "0.5188398", "0.5188398", "0.5188398", "0.5163705", "0.51627374", "0.51196...
0.6487617
0
Operation: getPathParam summary: Test path parameters req.params: type: object properties: id: type: integer required: id valid responses: '200': description: ok
async getPathParam(req) { if (typeof req.params.id !== "number") { throw new Error("req.params.id is not a number"); } return ""; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getPathParams(req, res){\n const params = 'id' in req.params ? req.params.id : null;\n console.log(\"getPathParams\");\n console.log(req.method);\n console.log(params);\n return params\n}", "pathParameter(id) {\n if (typeof(id) !== \"string\") id = toString(id);\n this.url +...
[ "0.68141294", "0.6488442", "0.5773003", "0.572371", "0.56621486", "0.5517886", "0.54683", "0.54603004", "0.5385529", "0.5332954", "0.5319399", "0.53078157", "0.52846956", "0.52733314", "0.52681834", "0.52223086", "0.51665175", "0.5166408", "0.5033953", "0.5026405", "0.5024532...
0.7523284
0
Operation: getQueryParam summary: Test query parameters req.query: type: object properties: int1: type: integer int2: type: integer valid responses: '200': description: ok
async getQueryParam(req) { if ( typeof req.query.int1 !== "number" || typeof req.query.int2 !== "number" ) { throw new Error("req.params.int1 or req.params.int2 is not a number"); } return ""; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async getQueryParamObject(req) {\n\t\tif (\n\t\t\ttypeof req.query.int1 !== \"number\" ||\n\t\t\ttypeof req.query.int2 !== \"number\"\n\t\t) {\n\t\t\tthrow new Error(\"req.params.int1 or req.params.int2 is not a number\");\n\t\t}\n\t\treturn \"\";\n\t}", "function QueryParameters() {}", "exQueryParams(request,...
[ "0.7400048", "0.63211024", "0.62980676", "0.6090812", "0.5966797", "0.5848519", "0.5772755", "0.56653583", "0.5579984", "0.5562631", "0.5562631", "0.5562631", "0.5562631", "0.5562631", "0.55422574", "0.55327463", "0.5522443", "0.5490263", "0.53456885", "0.53456885", "0.532618...
0.7390382
1
Operation: getQueryParamObject summary: Test query parameters req.query: type: object properties: int1: type: integer int2: type: integer valid responses: '200': description: ok
async getQueryParamObject(req) { if ( typeof req.query.int1 !== "number" || typeof req.query.int2 !== "number" ) { throw new Error("req.params.int1 or req.params.int2 is not a number"); } return ""; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async getQueryParam(req) {\n\t\tif (\n\t\t\ttypeof req.query.int1 !== \"number\" ||\n\t\t\ttypeof req.query.int2 !== \"number\"\n\t\t) {\n\t\t\tthrow new Error(\"req.params.int1 or req.params.int2 is not a number\");\n\t\t}\n\t\treturn \"\";\n\t}", "function parseQueryFromParams(queryObject, single, toJSON) {\n ...
[ "0.63659585", "0.59244514", "0.5905726", "0.5857554", "0.5715891", "0.56717783", "0.5543266", "0.55410737", "0.5496277", "0.5378934", "0.5366179", "0.5296495", "0.52780855", "0.52778095", "0.5267302", "0.5258921", "0.52518326", "0.5215186", "0.5205647", "0.52006376", "0.51969...
0.74700785
0
Operation: getQueryParamArray summary: Test query parameters req.query: type: object properties: arr: type: array items: type: integer valid responses: '200': description: ok
async getQueryParamArray(req) { if ( typeof req.query.arr[0] !== "number" || typeof req.query.arr[1] !== "number" ) { throw new Error("req.params[0] or req.params[1] is not a number"); } return ""; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "get isArray() {}", "function queryParamsValues() {\n const params = [];\n urlBase.searchParams.forEach((value) => {\n params.push(value);\n });\n\n return params;\n }", "function queryParamsValues() {\n const params = [];\n urlBase.searchParams.forEach((value) =>...
[ "0.59579396", "0.5923042", "0.59011817", "0.58713806", "0.5825603", "0.57390714", "0.5668074", "0.5540394", "0.55012643", "0.54985154", "0.54938835", "0.54938835", "0.54938835", "0.54938835", "0.54938835", "0.5481782", "0.54119265", "0.5411346", "0.54050714", "0.5381109", "0....
0.7619911
0
Operation: getHeaderParam summary: Test header parameters req.headers: type: object properties: XRequestID: type: string valid responses: '200': description: ok
async getHeaderParam(req) { if (typeof req.headers["x-request-id"] !== "string") { throw new Error("req.header['x-request-id'] is not a string"); } return ""; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async getAuthHeaderParam(req) {\n\t\tif (typeof req.headers[\"authorization\"] !== \"string\") {\n\t\t\tthrow new Error(\"req.header['authorization'] is not a string\");\n\t\t}\n\t\treturn \"\";\n\t}", "getHeader(key) {\n const val = this.headers[key];\n return val == null ? '' : val;\n }", "h...
[ "0.65984964", "0.585964", "0.5659978", "0.5646387", "0.5561892", "0.553718", "0.547035", "0.5466406", "0.54624295", "0.5422869", "0.53700215", "0.535628", "0.5332979", "0.5319653", "0.5319653", "0.5319653", "0.53142077", "0.52458084", "0.52173346", "0.5202684", "0.51993084", ...
0.79440707
0
Operation: getAuthHeaderParam summary: Test authorization header parameters req.headers: type: object properties: authorization: type: string valid responses: '200': description: ok
async getAuthHeaderParam(req) { if (typeof req.headers["authorization"] !== "string") { throw new Error("req.header['authorization'] is not a string"); } return ""; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static getAuthHeader() {\n let token = AuthService.getAuthToken();\n if (token) {\n return {\n 'Authorization': 'Bearer ' + AuthService.getAuthToken()\n };\n } else {\n return {};\n }\n }", "function getAuthorization (req) {\n if (!req.headers || typeof req.headers !== 'object...
[ "0.6849485", "0.65214074", "0.65214074", "0.65214074", "0.65214074", "0.65214074", "0.64783424", "0.6438889", "0.6367992", "0.63518083", "0.62794393", "0.62307763", "0.6200982", "0.619043", "0.6099741", "0.59860444", "0.59795356", "0.59586036", "0.59586036", "0.593307", "0.59...
0.8048335
0
Operation: getNoParam summary: Test no parameters valid responses: '200': description: ok
async getNoParam() { return ""; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function noOp(param) {\n return param;\n}", "function paramTypeNotSpecified(p) {\n return p;\n}", "function mandatory() {\n throw new Error('Missing parameter');\n}", "function isEmpty(parameter) {\n if (parameter === undefined) return 'your parameter is empty';\n else return parameter;\n}", "fu...
[ "0.6223975", "0.5780865", "0.5630484", "0.5529393", "0.5527589", "0.54669416", "0.54359835", "0.5431822", "0.5392578", "0.53744656", "0.53715855", "0.5296443", "0.5283848", "0.5271718", "0.52611005", "0.51736623", "0.5172169", "0.5168797", "0.51653135", "0.51542133", "0.51377...
0.7243203
0
Operation: postBodyParam summary: Test body parameters req.body: type: string valid responses: '200': description: ok
async postBodyParam(req) { if (typeof req.body.str1 !== "string") { throw new Error("req.body.str1 is not a string"); } return ""; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "POST(path, body = {}, opts = {}) {\n if(__DEV__) {\n body.should.be.an.Object;\n opts.should.be.an.Object;\n }\n /* eslint-disable new-cap */\n return Request.POST(this._resolve(path), body, opts);\n /* eslint-enable new-cap */\n }", "addBodyParam(key, value) {\n ...
[ "0.60395986", "0.6036195", "0.5928195", "0.58238196", "0.5710737", "0.56867075", "0.5651281", "0.56169754", "0.5579777", "0.5579191", "0.5508395", "0.54609245", "0.54294175", "0.54079586", "0.53982866", "0.5336241", "0.53345776", "0.53345776", "0.53345776", "0.53345776", "0.5...
0.66995513
0
Operation: getResponse summary: Test response serialization req.query: type: object properties: respType: type: string valid responses: '200': description: ok schema: type: object properties: response: type: string required: response
async getResponse(req) { if (req.query.replyType === "valid") { return { response: "test data" }; } else { return { invalid: 1 }; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async getResult(set, endpoint, json_field, response_type) {\n\t\t\n\t\tvar res = await this.makeRequest(endpoint, json_field);\n\t\tconsole.log(\"request processor, inside getResult res:\", res)\n\t\treturn checkType(res, response_type);\n\t}", "query(options) {\n const operationArguments = {\n ...
[ "0.5980974", "0.55406696", "0.55406696", "0.5527204", "0.54681593", "0.5428021", "0.540946", "0.5385138", "0.5327573", "0.53037465", "0.5291534", "0.5282699", "0.52677375", "0.5252352", "0.5239145", "0.52321845", "0.51840997", "0.5160837", "0.51576936", "0.51105314", "0.51067...
0.7256795
0
Operation: testOperationSecurity summary: Test response serialization req.query: type: object properties: respType: type: string valid responses: '200': description: ok schema: type: object properties: response: type: string required: response
async testOperationSecurity(req) { return { response: req.scope || "authentication succeeded!", }; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async testOperationSecurityWithParameter(req) {\n\t\treturn {\n\t\t\tresponse: req.scope || \"authentication succeeded!\",\n\t\t};\n\t}", "function equalsToBeSwaggerSpec(res) {\n\n // Check if result equals expected spec\n if (JSON.stringify(res.body) !== JSON.stringify(swaggerSpec)) {\n throw new Error('Re...
[ "0.6584732", "0.56718767", "0.5647526", "0.5493304", "0.5474456", "0.5469386", "0.543569", "0.54123086", "0.5406431", "0.53830254", "0.536369", "0.5297928", "0.5291457", "0.52892137", "0.5286368", "0.5250884", "0.52479595", "0.52228796", "0.5200564", "0.51895094", "0.5171276"...
0.66263205
0
Operation: testOperationSecurityWithParameter summary: Test response serialization req.query: type: object properties: respType: type: string valid responses: '200': description: ok schema: type: object properties: response: type: string required: response
async testOperationSecurityWithParameter(req) { return { response: req.scope || "authentication succeeded!", }; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async testOperationSecurity(req) {\n\t\treturn {\n\t\t\tresponse: req.scope || \"authentication succeeded!\",\n\t\t};\n\t}", "async testOption(ctx) {\n // console.log('In testOption');\n // console.log('ctx.params', ctx.params);\n // console.log(\"ctx.request.body\", ctx.request.body)\n const tests =...
[ "0.63968337", "0.5558426", "0.54145", "0.5279535", "0.5226377", "0.51874727", "0.51812464", "0.5145551", "0.51050365", "0.51012576", "0.506019", "0.5051189", "0.5049689", "0.50465196", "0.5008223", "0.49953339", "0.49929067", "0.49927995", "0.495483", "0.4915307", "0.49019134...
0.7349258
0
array of questions for user
function questions() { return inquirer.prompt([ { type: "input", name: "title", message: "Hello there! What is the title of your Readme?" }, { type: "input", name: "description", message: "Alright than, describe your p...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function user_answers(user_input) {\n var user_answers_list = [];\n user_answers_list.append(user_input);\n return user_answers_list;\n}", "function pushquestion() {\n for (var i = 0; i < Questions.length; i++) {\n questionarray.push(Questions[i]);\n }\n }", "function getQuestions(){\n ...
[ "0.7079581", "0.6901407", "0.6866087", "0.6829175", "0.6820706", "0.6810747", "0.6756412", "0.67470616", "0.6745506", "0.67152274", "0.66815114", "0.6675446", "0.6647392", "0.6625104", "0.6592825", "0.6554027", "0.6554027", "0.6554027", "0.6550735", "0.6549925", "0.6538435", ...
0.0
-1
function to write README file
async function writeToFile(fileName, data) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function writeREADME(savefileName, data) {\n fs.writeFile(savefileName, data, () => {});\n \n console.log('Your README has been generated, check the dist folder')\n}", "function writeToFile() {\n fs.writeFile(\"README.md\", \"\", function(err){console.log(err || \"File written successfully!\")})\n}", "func...
[ "0.801536", "0.76840633", "0.7673515", "0.7667203", "0.76559424", "0.76176333", "0.7575873", "0.7530438", "0.7515387", "0.74816114", "0.7430493", "0.7424468", "0.7421114", "0.7400896", "0.73803383", "0.73524326", "0.73434895", "0.7312492", "0.7306044", "0.7301438", "0.7290952...
0.0
-1
function to initialize program
function init() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "setupProgram(program) {\n }", "function initProgram() {\n var program = require('commander');\n\n program.option(\n '-p, --probability [number]',\n 'probability of sampling chunk',\n parseFloat\n );\n program.option(\n '-s, --split [pattern]',\n 'delimiter or reg...
[ "0.77688205", "0.73319626", "0.66867465", "0.6662992", "0.6656498", "0.65002453", "0.64708996", "0.64708996", "0.6469112", "0.6469112", "0.6469112", "0.6469112", "0.6469112", "0.6469112", "0.6469112", "0.6469112", "0.6469112", "0.6469112", "0.64647335", "0.6458828", "0.645172...
0.0
-1
Function to say Hello World
function sayHello() { alert('Hello World') }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function sayHello() {}", "function sayHello(){}", "function sayHello() {\n console.log('Hello, ' + name);\n }", "function sayhello(){\nconsole.log('Hello World!')\n}", "function sayHello(){\n return \"Hello World\"\n}", "function sayHello(name) { \n console.log(\"Hello, \"+name);\n ...
[ "0.83662206", "0.8314372", "0.81717104", "0.81421906", "0.8106666", "0.80301124", "0.8018027", "0.8003041", "0.79945636", "0.798745", "0.7976876", "0.79658324", "0.79452443", "0.7927407", "0.7924047", "0.79210573", "0.7903536", "0.7899119", "0.7890958", "0.78845847", "0.78745...
0.0
-1
Function to check age
function checkAge(name, age) { if (age < 21) { alert("Sorry " + name + ", you aren't old enough to view this page"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isValidAge(age) {\n return age\n}", "function isAge(value)\n {\n var dateOfBirth = value;\n var arr_dateText = dateOfBirth.split(\"/\");\n month = arr_dateText[0];\n day = arr_dateText[1];\n year = arr_dateText[2];\n var dob = new Date(year, month - 1, day, 0, 0, 0);\n var campD...
[ "0.8280855", "0.8185035", "0.80779576", "0.7856295", "0.7781905", "0.77398676", "0.7724088", "0.77012295", "0.7673642", "0.7592213", "0.7578026", "0.7578026", "0.75772035", "0.756776", "0.7529714", "0.7527117", "0.7483919", "0.7477215", "0.74544543", "0.73974675", "0.7386928"...
0.7001364
59
Creates a function that returns the length of a string
function getLength(string) { return string.length }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getLength(string){\n return string.length;\n}", "function length (string){\n\treturn string.length;\n}", "function length(str) {\n return str.length;\n}", "function sc_stringLength(s) { return s.length; }", "function getLength(string) {\n return string.length;\n}", "function getLength(str...
[ "0.79882234", "0.7967623", "0.79510343", "0.7946426", "0.7819918", "0.7819918", "0.7819918", "0.7763561", "0.7762455", "0.7762455", "0.7762455", "0.7724886", "0.76456684", "0.76433486", "0.75746524", "0.75731283", "0.7390591", "0.7386021", "0.7274247", "0.7263797", "0.7249635...
0.79140526
4
function to display the object(s)
display(){ //give the condition to make the bow move up if (keyIsDown(UP_ARROW) && this.angle < 2){ //change the value of angle this.angle += 0.02; } //give the condition to make the bow move down if (keyIsDown(DOWN_ARROW) && this.angle > 1){ //change the value of angle this.angle -= 0.02; } //declare a samp...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function show( obj )\r\n{ var r = \"\" ;\r\n for (var i in obj)\r\n r += i + \" = \" + obj[i] + \"\\n\" ;\r\n return r ;\r\n}", "display() {\n this.object.display();\n }", "function show(obj,d){\n\tstr=\"\"\n\tfor(i in obj){\n\t\tstr+=i + \" : \" +String(obj[i])+\"\\n\"\n\t\t}\n\talert(str)\n\t}...
[ "0.77535784", "0.73628324", "0.7127228", "0.6983607", "0.69810355", "0.69650054", "0.67824954", "0.67822504", "0.6778194", "0.6768324", "0.6746995", "0.6734782", "0.67210275", "0.67154974", "0.6661495", "0.6634161", "0.6597605", "0.6544113", "0.65343773", "0.6529249", "0.6526...
0.0
-1
Constructs a new ServiceInstance.
constructor() { ServiceInstance.initialize(this); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Service() {\n\t\t_classCallCheck(this, Service);\n\t}", "static createService(obj) {\n return class {\n constructor(config) {\n this.name = obj.name;\n this.run = obj.runService;\n this.config = config || {};\n this.descriptio...
[ "0.6996512", "0.6793073", "0.6748576", "0.6605391", "0.6582312", "0.6542875", "0.6402517", "0.6365349", "0.6356333", "0.62810904", "0.621472", "0.6183131", "0.6183131", "0.6116361", "0.60969263", "0.6010335", "0.592171", "0.589279", "0.5853733", "0.58206457", "0.58206457", ...
0.69806796
1
Initializes the fields of this object. This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mixins). Only for internal use.
static initialize(obj) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "constructor() {\n super();\n this._init();\n }", "init() {\n this._super(...arguments);\n this._applyDefaults();\n }", "_init() {\n\t\tthis.life.init();\n\t\tthis.render.init();\n\n\t\tthis.emission.init();\n\t\tthis.trail.init(this.node);\n\n\t\tthis.color.init();\n\t}", "function Co...
[ "0.71314037", "0.69630265", "0.6814572", "0.67468137", "0.6715615", "0.6642555", "0.6633626", "0.66017884", "0.6580413", "0.65630656", "0.6409274", "0.64043665", "0.6334331", "0.63041437", "0.62964106", "0.6283095", "0.626907", "0.6240725", "0.6238583", "0.6234676", "0.623446...
0.0
-1
Prompt 2: Write a function that can reverse a number.
function reversedNumber(num) { return parseFloat(num.toString().split('').reverse().join('') ) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function reverseNumber (n) {\n\n}", "function reverseInteger(number) {\nvar reversed = 0;\n\n}", "function reverse(input) {}", "function reverse_a_number(n)\n{\n\tn = n + \"\";\n\treturn n.split(\"\").reverse().join(\"\");\n}", "function reverseNum(n) {\r\n let result = n.toString();\r\n let rev = re...
[ "0.8480217", "0.7926279", "0.78614163", "0.7681963", "0.75765693", "0.7566152", "0.752195", "0.74934494", "0.74741805", "0.7438434", "0.7392204", "0.7382486", "0.7379795", "0.73383313", "0.7320389", "0.72831905", "0.7257046", "0.72477704", "0.7223618", "0.7214848", "0.7209849...
0.6758665
55
Prompt 3: Write a function that checks whether the passed string is palindrome or not?
function isPalindrome(isIt) { isIt = isIt.toLowerCase(); for(let i = 0; i < isIt.length; i++){ if(isIt[i] !== isIt[isIt.length - 1 -i]){ return false; } else{ return true; } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function palindrome(str) {}", "function palindrome(string) {\n\n}", "function isPalindrome(str) {\n\n}", "function palindrome(str) {\n return true;\n}", "function palindrome(str) {\r\n // Good luck!\r\n return true;\r\n}", "function palindrome(str){\r\n return reverseString(str) === str;\r\n}",...
[ "0.89548063", "0.88835436", "0.87138975", "0.8616385", "0.85542214", "0.8531675", "0.8468684", "0.84636617", "0.8431441", "0.8424982", "0.8392615", "0.83746904", "0.83601564", "0.8342267", "0.83356994", "0.8306263", "0.8285814", "0.82811147", "0.82770646", "0.82722217", "0.82...
0.0
-1
Prompt 4: Create a function named alphaOrder that returns a passed string with letters in alphabetical order.
function alphaOrder(alpha) { alpha = alpha.toLowerCase(); return alpha.split('').sort().join(''); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function alphaOrder(str) {\n /* const strInArr = str.split(\"\"); // to make array from str\n const arrLetters = strInArr.sort(); // to sort al\n const line = arrLetters.join(\"\"); // to make str from array\n return line; */\n\n return str.split(\"\").sort().join(\"\");\n}", "function alphaOrder(...
[ "0.80175817", "0.7884488", "0.7792854", "0.769112", "0.7602225", "0.75757426", "0.74849683", "0.7445277", "0.7445277", "0.7445277", "0.74066234", "0.73783755", "0.73328483", "0.72986054", "0.7095973", "0.7094852", "0.70539683", "0.6989461", "0.69507575", "0.6944295", "0.68543...
0.8253387
0
Prompt 5: Create a function named changeToLowerCase that accepts a string as a parameter and converts letters of each word of the string to lowercase
function changeToLowerCase(){ let words = ''; return words.toLowerCase(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function lowercase(input) {}", "function kleineLetters(text) {\nvar str = \"Hello World!\";\nvar res = str.toLowerCase();\n}", "function whisper(string){ return string.toLowerCase() }", "function toLowerCase(string) {\n // YOUR CODE BELOW HERE //\n \n // The .toLowerCase() method converts a given st...
[ "0.81850994", "0.7762686", "0.7733038", "0.7654007", "0.746139", "0.73753536", "0.73729044", "0.73583776", "0.73583776", "0.7357952", "0.7341044", "0.73047876", "0.7296007", "0.7265935", "0.72591823", "0.72591823", "0.72591823", "0.7229696", "0.72067285", "0.71973747", "0.719...
0.80611354
1
Prompt 6: Make a function that accepts a string as a parameter and converts the first letter of each word of the string in uppercase.
function firstLetter(firstWord) { let words = firstWord.split(" ") for (let i = 0; i < words.length; i++) { words[i] = words[i][0].toUpperCase() + words[i].substr(1); } return words.join(" ") }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function uppercase(input) {}", "function capitalWord(string) {\n return string.charAt(0).toUpperCase() + string.slice(1);\n //function to make input value to have capital as it is inputed\n}", "function upperCaser(input) {\n return input.toUpperCase();\n}", "function i(e){return e[0].toUpperCase()+e.s...
[ "0.8095058", "0.8051525", "0.76423264", "0.75388616", "0.7520683", "0.75113684", "0.7509104", "0.74825627", "0.7470386", "0.7454116", "0.7454116", "0.74343973", "0.7418697", "0.7416029", "0.7413305", "0.74095976", "0.73777205", "0.7374262", "0.73724955", "0.73599815", "0.7358...
0.0
-1
Prompt 7: Make a function that accepts a string as a parameter and find the longest word within the string.
function longestWord(text) { let sentence = text.split(' '); let maxLength = 0; for(let i = 0; i < sentence.length; i++) { if(sentence[i].length > maxLength){ maxLength = sentence[i].length; } } return maxLength; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function longestWord(sen) {}", "function findLongestWord(string) {\n return string.length;\n}", "function longestWord(str) {\n // check if argument is a string\n if (typeof str === 'string') {\n // check if string is empty\n if (str === '') {\n return ''\n } else {\n // split the string i...
[ "0.85105646", "0.83578897", "0.83286166", "0.8245638", "0.82440233", "0.8209988", "0.8209988", "0.8188632", "0.8188188", "0.8185581", "0.8183568", "0.8180633", "0.8173036", "0.81546795", "0.8151216", "0.81478673", "0.81442195", "0.81268287", "0.8112564", "0.8102897", "0.80919...
0.0
-1
Prompt 8: Create a function that takes two parameters: a and b. When called, multiply a times b. Print the answer to the console.
function twoParams(a, b){ return a*b; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function multiply(a,b) {\n return a*b;\n}", "function multiply(a,b) {\n return a*b;\n}", "function multiply(a,b) {\n return a*b;\n}", "function multiply(a,b) {\n return a*b;\n}", "function multiply(a,b) { \n return a * b\n}", "function multiplyTwoNumbers(a, b) {\nreturn a * b\n}", "function mu...
[ "0.7810701", "0.7810701", "0.7810701", "0.7797115", "0.7790851", "0.7767597", "0.7766473", "0.77604353", "0.77582824", "0.77313435", "0.7727795", "0.7727795", "0.7719944", "0.7665005", "0.76637214", "0.7649277", "0.76343983", "0.76343983", "0.76343983", "0.76343983", "0.76343...
0.0
-1
Prompt 10: Write a function to find the repeated character in a string.
function repeatedCharacter(find) { for(let i = 0; i <= find.length; i++){ for(let m = i+1; m <= find.length; m++){ if(find[m] === find[i]){ return find[i].repeat(1); } } } return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function findDuplicateCharacters(input) {\n}", "function firstNonRepeatingCharacter(string) {\n let seenHash = {};\n\n for (const char of string){\n if (!seenHash[char]){\n seenHash[char] = 1;\n } else {\n seenHash[char]++;\n }\n }\n\n for (const key in seenHash){\n const value = seenHa...
[ "0.8207544", "0.81396824", "0.80595183", "0.8054167", "0.80325603", "0.8025002", "0.7999558", "0.7865542", "0.7806933", "0.78062135", "0.78035885", "0.7801028", "0.77985024", "0.77319634", "0.77172786", "0.77132046", "0.76004267", "0.7563687", "0.753781", "0.75165004", "0.749...
0.8180357
1
Funktion Create a Puppy Age Teller: Write a function named calculateDogAge that: takes 1 argument: your puppy's age. calculates your dog's age based on the conversion rate of 1 human year to 7 dog years. outputs the result to the screen like so: "Your doggie is _ years old in dog years!" Call the function three times w...
function calculateDogAge(puppyAge) { let question = prompt("What is your dog's age?"); let puppyAge = question + 7; return 'Your doggie is ' + puppyAge + ' years old in dog years!'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function calculateDogAge(PuppyAge, HumanAge){\r\n\r\nvar PuppyYears = PuppyAge * 7;\r\nvar PuppyHuman = HumanAge / 7;\r\n\r\nalert(\"Your doggie is \" + PuppyYears + \" years old in dog years! (converted from Human years to dog years)\");\r\n\r\n// Bonus: Add an additional argument to the function that takes the c...
[ "0.8326652", "0.8234085", "0.818434", "0.8088635", "0.8067124", "0.7977554", "0.7962869", "0.7923129", "0.78969264", "0.7829708", "0.7757537", "0.76330936", "0.7621806", "0.75787985", "0.7520227", "0.750255", "0.74993443", "0.7487793", "0.7470715", "0.7452793", "0.7324976", ...
0.75886774
13
Funstion (main and section) => visible added and remove
function hideTabContent(a, b) { for (let i = a; i < b.length; i++) { b[i].classList.remove("show"); b[i].classList.add("hide"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function remove_visible_sections() {\n for (let c = 0; c < options.length; c++) {\n options[c].classList.add(\"hidden\");\n options[c].classList.remove(\"visible\");\n descript[c].classList.add(\"hidden\");\n descript[c].classList.remove(\"visible\");\n }\n}", "function hidMainS...
[ "0.65376866", "0.6475927", "0.62952274", "0.6268639", "0.62585825", "0.62530243", "0.6227059", "0.6223426", "0.6223405", "0.61411166", "0.61018306", "0.6087842", "0.6079253", "0.6053887", "0.6024478", "0.6024026", "0.5967969", "0.5951198", "0.59271973", "0.5918467", "0.589020...
0.0
-1
Funstion header => grow added and remove
function growOn(a, b) { for (let i = a; i < b.length; i++) { b[i].classList.remove("grow-on"); b[i].classList.add("grow-off"); b[i].classList.remove("color-dark"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateHeader() {\n removeChemElements();\n elementsCurrentlyUsed.forEach(molId => addChemElement(molId));\n}", "updateHeader() {\n const header = new HeaderView(this.model.state);\n this.root.replaceChild(header.element, this.header.element);\n this.header = header;\n this.header.updateTim...
[ "0.69135386", "0.6583157", "0.650807", "0.64839596", "0.64239264", "0.63870203", "0.63350564", "0.63350564", "0.62285626", "0.6225326", "0.6217903", "0.6206336", "0.6192998", "0.61235416", "0.61204314", "0.6088215", "0.60805064", "0.60535", "0.60370797", "0.6022815", "0.59774...
0.0
-1
Setting studentsDataArray from Class.attendance.studentsInfo which was earlier set from Class.studentsData table
async fetchAttendanceOnDate() { // Resetting studentsDataArray to clear the previous date so that only the selected records are present on the page this.setState({ studentsDataArray: [] }); var fetchAttendanceOnDateRequest = { "class": this.state.class, "section": this.state.section,...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getAllStudentData() {\n var studentData = {moduleStudentList, studentChanges};\n \n return studentData;\n}", "function fill_students_table( student_id )\r\n{\r\n\tlet url;\r\n\tif ( !student_id )\r\n\t\turl = './api/students/list';\r\n\telse\r\n\t\turl = './api/student/' + student_id;\r\n\tget_...
[ "0.620823", "0.61232996", "0.60636896", "0.60481983", "0.5927449", "0.58811295", "0.58296937", "0.5820967", "0.5817121", "0.57869476", "0.5777823", "0.5770027", "0.57474375", "0.57280684", "0.56836325", "0.5676937", "0.56329215", "0.56323904", "0.562896", "0.561661", "0.55721...
0.5891746
5