View gist:9327872
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
{ | |
"league": { | |
"id": 1, | |
"match_ids": [ | |
"129-140-league-1", | |
"130-139-league-1", | |
"131-138-league-1", | |
"132-137-league-1", | |
"133-136-league-1", | |
"134-135-league-1", |
View gist:9343092
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
"prizes": [ | |
{ | |
"id" : 1, | |
"competition_type" : "league", | |
"level": "gold", | |
"ingots" : 28.000.000, | |
"money" : 400, | |
"transfer" : "promotion" | |
}, | |
{ |
View gist:10102415
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
{ | |
"matches": [ | |
{ | |
"id": "133-149-league-2", | |
"configuration_id": "133-149-league-2", | |
"start_time": "2014-04-04T14:56:43+02:00", | |
"league_id": 2, | |
"local_cup_id": null, | |
"competition_type": "league", | |
"home_team_id": 133, |
View Gm cups
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
App.Tournament = DS.Model; | |
App.LocalCup = App.Tournament.extend(); | |
App.Championship = DS.Model.extend({ | |
type: DS.attr('string'), //champions-cup, challengue-cup, kerad-cup | |
tournament: DS.belongsTo('tournament'), | |
leagues: DS.hasMany('league') | |
}); |
View gist:67c4181f3544e2d48fdf
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
App.ApplicationSerializer = DS.ActiveModelSerializer.extend({ | |
serializeHasMany: function(record, json, relationship) { | |
var key = relationship.key; | |
var json_key = key.singularize().decamelize() + '_ids'; | |
var relationshipType = DS.RelationshipChange.determineRelationshipType( | |
record.constructor, relationship); | |
if (relationshipType === 'manyToNone' || relationshipType === 'manyToMany' || relationshipType === 'manyToOne') { |
View reopen_model.js
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
DS.Model.reopen({ | |
canReload: function() { | |
return !this.get('isSaving') && !this.get('isReloading'); | |
}.property('isSaving', 'isReloading') | |
}); |
View foo_route.js
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
App.FooRoute = App.Route.extend({ | |
dependencies: ['session.team.championship', 'session.team.teamReport', 'customDependency','position', 'user:12345', 'lineup:cached'], | |
customDependency: function() { | |
return new Ember.RSVP.Promise(); | |
} | |
}); |
View component_spec.js
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 view; | |
module('Computed properties', { | |
setup: function() { | |
view = Ember.View.create({ | |
template: Ember.Handlebars.compile( | |
'{{my-component name="hector"}}' | |
) | |
}); | |
}, |
View gist:9f643182ca51d8d1b3eb
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
App.ApplicationRoute = Em.Route.extend({ | |
actions: { | |
showModal: function() { | |
//Quiero que entre aqui | |
} | |
} | |
}) | |
App.ParentComponent = Em.Component.extend({ | |
actions: { |
View .bash_profile
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
### GIT | |
source ~/.bash/gitprompt.sh | |
if [ -f ~/.git-completion.bash ]; then | |
. ~/.git-completion.bash | |
fi | |
alias gss="git status --short" | |
alias gl="git log --pretty=format:'%Cred%h%Creset - %C(green) %an %C(reset) - %C(yellow)%d%Creset %s %Cgreen(%cr) %Creset'" |
OlderNewer