Skip to content

Instantly share code, notes, and snippets.

American Potato Salad
let game = {
name: 'Zymo Death Match',
location: {lat: 41.342345, lng: 83.1231}, //starting location, used to determine who sees this game in the lobby
startTime: 'Wed Dec 06 2017 07:18:50 GMT-0600 (CST)',
coordinates: [
{lat: 41.93234, lng: 83.898},
{lat: 41.24324, lng: 83.89898},
{lat: 41.24327, lng: 83.89888},
],
shrinkRate: 100, //time in seconds
@chris-held
chris-held / gist:1693eb2fd871703df1a3
Created January 6, 2016 21:46
$scope.$watch example
$scope.$watch('message', function(newValue, oldValue){
if (newValue !== oldValue) {
//do some stuff
}
});
detail: {
entryType: {
id: 1
},
account: {
//I just make sure this is there, I honestly am not sure why
},
header: {
requestDate: 1395347715000
requestType: {
{
"error":null,
"glDetails":[
{
"account":{
"accountNumber":"2041",
"accountType":{
"cr":true,
"description":"Liability",
"dr":false,
{
"error":null,
"requestId":1406,
"requestTime":1386790633095,
"transactionHandling":"AllOrNothing",
"transactions":[
{
"amount":50,
"description":"{\"transactionDate\":1386790632000,\"transactionId\":\"96426686AH5589059\",\"amount\":50,\"fee\":1.75,\"transactionType\":\"expresscheckout\",\"paymentType\":\"instant\",\"paymentStatus\":\"Completed\",\"donorInfo\":{\"email\":\"cheld100@gmail.com\",\"firstName\":\"chris\",\"lastName\":\"\",\"username\":\"chris\",\"_id\":\"b1092ba97c3544c6d798ca8120041b24\",\"isAnonymous\":false},\"billingInfo\":{\"firstName\":\"\",\"lastName\":\"\",\"address1\":\"\",\"address2\":\"\",\"city\":\"\",\"state\":\"\",\"postalCode\":\"\"},\"fundraiserInfo\":{\"name\":\"Sponsor all the things\",\"_id\":\"10bc0fa39fa52f2731385b042b2a8a15\",\"_type\":\"fundraiser\",\"benefittingCommunity\":{\"name\":\"Mainely Character\",\"_id\":\"c913041a46fdab8b0a7888e6308f4a4a\",\"orgName\":\"Mainely Character\",\"ein\":\"01-0536795\",\"email\":\"judy.kmack@zyques
{
"error":null,
"glDetails":[
{
"account":{
"accountNumber":"10,003",
"accountType":{
"cr":false,
"description":"Memo",
"dr":true,
{
"_id": "26ce59d67b68904ec6b5cf1c1c203d45",
"_rev": "5-b9981f5b44c98579fd93bd989215da20",
"name": "Gathering all Bats",
"parentFundraiser": {
"$ref": "26ce59d67b68904ec6b5cf1c1c1fd282"
},
"parentCommunity": {
"$ref": "26ce59d67b68904ec6b5cf1c1c124d55"
},
feather.Widget.load({
path: 'widgets/static/stateDropdown/',
clientOptions: {
parent: me,
container: me.get('#state_dropdown_div'),
name: 'state',
onceState: {
ready: function() {
var stateDD = this;
if(profile.fundraiser.contactInfo && profile.fundraiser.contactInfo.addresses && profile.fundraiser.contactInfo.addresses.primary){
_.each(subjects, function(subject){
//find all teachers that teach this subject that have available blocks
//if this subject has preferred times / days, check if any teacher has those
//blocks / days open, and if so assign by setting available to false on both the
//special teacher and class schedule, and adding class / teacher / subject taking up that
//slot
//if preferred block isn't available, put this class wherever there's room
//if no blocks are available, add this subject to a list that will display
//outside of the schedule as an error