This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
overwrite: true | |
schema: | |
- https://apidev.paro.io/v2/graphql: | |
headers: | |
parotoken: Bearer YOUR_TOKEN_HERE | |
documents: './src/app/**/*.graphql' | |
generates: | |
src/app/graphql.ts: | |
plugins: | |
- 'typescript-common' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type ElSearchQuery = { | |
query: { | |
bool: { | |
should: Array<MultiMatch> | |
filter: [ | |
{ | |
term: { | |
serviceLine: string | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/************* | |
clientProjects = [ | |
{ | |
estHoursHigh: 30, | |
projectedHours: 27, | |
estHoursLow: 20, | |
currentHoursBilled: 24, | |
serviceType: "premium", | |
canEditDueDate: false, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
document.addEventListener('DOMContentLoaded', Init); | |
function Init() { | |
var oForm = document.forms[0], | |
countryElem = oForm[config.countryUdf], | |
stateElem = oForm[config.stateUdf].parentElement.parentElement, | |
provinceElem = oForm[config.provinceUdf].parentElement.parentElement; | |
provinceElem.style.display = 'none'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var oPhoneField = document.getElementsByName('Phone')[0]; //get Phone input element | |
var oErrorMessage = document.createElement('p'); //create paragraph that will contain the error message | |
var cHasDuplicates = /^\D*(\d)(?:\D*|\1)*$/; //regex for later use | |
oErrorMessage.classList = 'error-message'; //give error message paragraph class for optional styling via customCSS | |
//Conditional Error Messages | |
var cMessages = { | |
charLength: 'Phone number must contain 3 to 32 characters', | |
charContent: 'Phone number cannot contain a comma, period, or semicolon', | |
charRepeated: 'Phone number cannot contain the same digits. ie "1111111111" is not an acceptable number', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//req url - https://vts.inxpo.com/scripts/Server.nxp?LASCmd=AI:1;F:LBSEXPORT!JSON&SQLID=16010&ImageLib=9 | |
//Filter Polyfill for IE | |
if (!Array.prototype.filter) { | |
Array.prototype.filter = function(fun) { | |
var len = this.length >>> 0; | |
if (typeof fun != "function") | |
throw new TypeError(); | |
var res = []; | |
var thisp = arguments[1]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
document.addEventListener('DOMContentLoaded', login); | |
function login() { | |
var oElem = document.getElementById('ItemList'); | |
var oLoginDiv = document.createElement('div'); | |
oLoginDiv.style.marginBottom = '20px'; | |
var oLoginLink = document.createElement('a'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GameObject("Trivia").Extend({ | |
initGame: function(iGameKey) { | |
var oGame = GameDataObject("Game" + iGameKey); | |
oGame.Extend({ | |
GameQuestions: [], | |
GetRandomQuestions: function() { | |
var aQuestions = [], | |
aTemp = []; | |
xDOM.cloneObject(aQuestions, this.GameQuestions.sort((function() { | |
return function(a, b) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Polyfills and Dependencies | |
(function() { | |
//https://osric.com/chris/accidental-developer/2009/08/javascript-insertafter/ | |
Object.prototype.insertAfter = function(newNode) { | |
this.parentNode.insertBefore(newNode, this.nextSibling); | |
} | |
// Production steps of ECMA-262, Edition 5, 15.4.4.19 | |
// Reference: http://es5.github.io/#x15.4.4.19 |