Sha256: 03956f19879a2350fb04cae56cdfa3ba4fed63f74e62ea84b8f7b5fe029dfcc3
Contents?: true
Size: 739 Bytes
Versions: 1
Compression:
Stored size: 739 Bytes
Contents
Volontariat.EditBrainstormingRoute = Ember.Route.extend controllerName: 'brainstorming' model: (params) -> if Volontariat.User.current() == undefined || params.user_slug != Volontariat.User.current().slug @transitionTo 'index' Volontariat.alert 'danger', 'Access denied!' else @controllerFor('brainstorming').set 'userSlug', params.user_slug @controllerFor('brainstorming').set 'slug', params.slug Ember.$.getJSON("/api/v1/brainstormings/#{params.slug}?user_slug=#{params.user_slug}").then (json) => @controllerFor('brainstorming').set 'name', json.brainstorming.name @controllerFor('brainstorming').set 'text', json.brainstorming.text json.brainstorming
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
voluntary_brainstorming-0.0.2 | app/assets/javascripts/voluntary_brainstorming/routes/edit_brainstorming_route.js.coffee |