Skip to content

Instantly share code, notes, and snippets.

View mattmontgomery's full-sized avatar

Matt Montgomery mattmontgomery

View GitHub Profile
@mattmontgomery
mattmontgomery / Search select augment.js
Created November 5, 2014 21:26
Augmenting search select for resourceMethod and resourceData
define(function(require) {
var $ = require('jQuery'),
_ = require('Underscore'),
Backbone = require('Backbone'),
Tile = require('Tile'),
Flexer = require('tile!layouts/flexer'),
Dropdown = require('tile!cmslayouts/dropdown-input'),
CMSCollection = require('cmshelpers/collection'),
Dropzone = require('tile!cmslayouts/dropzone'),
KeyNavigator = require('keynavigator');
@mattmontgomery
mattmontgomery / gist:05d151bb9d1093630130
Created November 10, 2014 17:23
ElasticsearchController additions

ElasticSearchController:23 - add constant type for FIELD_ARRAY_ALL

ElasticSearchController:91 - add check to getFieldTypeByValue for comma-separated strings

ElasticSearchController:191 - add explode toon FIELD_ARRAY_ALL and comma

ElasticSearchController:134,152 - add option for $should to equal "must" if getFieldTypeByValue is FIELD_ARRAY_ALL

Aggregations

Can replace faceting (facets api deprecated in ES). Lots of options.

  • min aggregation
  • max aggregation
  • sum aggregation
  • avg aggregation
  • stats aggregation
  • extended stats aggregation

Creating a generic widget

  • Widget file (/js/lib/cms/tile/views/widgets/api/...)
  • Details panel (as above, as panel.details.js)
  • Collection (/js/lib/cms/collections/utah/{collectionName}/collection.js)
  • Model (/js/lib/cms/collections/utah/{collectionName}/model.js)

Aerial battles prove once again to be RSL's Achilles Heel.

Whether it was anxiety or just the wrong boots, it seemed that Real Salt Lake players hardly left the ground - for the entire 90 minutes it appeared as if RSL have had weights tied around their ankles.

RSL's defense is like a rock.

Winning 57 percent of all duels and owning 54 percent of possession, Sporting was unable to turn their 12-4 edge in shots into a tally on the score sheet.

Filling the right wing

Wed., June 17: Training at America First Field in Sandy, UT - 11 a.m.-12:30 p.m.
Real Monarchs training at Juan Diego High School in Draper, UT - 11 a.m.-12:30 p.m.
Thu., June 18: Off
Real Monarchs training at Juan Diego High School in Draper, UT - 11 a.m.-12:30 p.m.
Fri., June 19: Training at America First Field in Sandy, UT - 11 a.m.-12:30 p.m.
Real Monarchs training at Juan Diego High School in Draper, UT - 11 a.m.-12:30 p.m.
Sat., June 20: Training at Rio Tinto Stadium in Sandy, UT - 11 a.m.-12 p.m.
Real Monarchs training at Juan Diego High School in Draper, UT - 11 a.m.-12:30 p.m.
Sun. June 21: RSL vs. Sporting Kansas City; 8 p.m. MT; Rio Tinto Stadium (Fox Sports 1)
@mattmontgomery
mattmontgomery / WaibelJuly22.md
Last active August 29, 2015 14:25
Craig Waibel comments on ESPN 700, July 22

Craig Waibel Wednesday July 22, 2015

-- 04:30

He's fitting in the lcoker room realy, really well ... he's a nice guy. Personable ... simple, not the guy that comes in with a huge personality. It's not

05:00

Jeff Cassar, July 28

I wish I had some news for you and everybody else, but what I can tell you is that Craig is working extremely harding at possibly finalizing a deal, and hopefully something can be announced relatively shortly. I know Craig is working tirelessly right now.

You have to go through a lot of channels to get a deal done. Hopefully everybody can come together and reach a conclusion shortly.

It's not always easy for the team or the player, but we'll bring him in at the right pace and at the right time. It's never easy to adjust to a new team and a new style of play, but when you're adding this kind of quality, it's easier.

I have a relationship with the agent, as Craig does as well. That makes it easier in the process. Whenever you're involved in other leagues and other federations, it takes a little time. These are never done over night.

Mexico squad

Goalkeepers: Moises Munoz (America), Alfredo Talavera (Toluca)

Defenders: Paul Aguilar (America), Diego Reyes (Real Sociedad), Francisco "Maza" Rodriguez (Cruz Azul), Rafa Marquez (Hellas Verona), Hector Moreno (PSV), Oswaldo Alanis (Chivas), Miguel Layun (Watford), Jorge Torres Nilo (Tigres)

Midfielders: Duenas (Tigres), Jose Juan "Gallito" Vazquez (Leon), Javier Guemez (America), Hector Herrera (Porto), Luis Montes (Leon), Javier Aquino (Tigres), Carlos Esquivel (Toluca), Andres Guardado (PSV)

Forwards: Jesus "Tecatito" Corona (Twente), Javier "Chicharito" Hernandez (Manchester United), Oribe Peralta (America), Carlos Vela (Real Sociedad), Raul Jimenez (Benfica).

/**
* Installed `jest`, `jest-cli`; ran test with `--no-watchman`
*/
describe('Helpers', function() {
jest.autoMockOff();
var Helpers = require('../helpers');
describe('isFloat', function() {
it('has isFloat as an export', function() {
expect(Helpers.isFloat).not.toBeNull();