So you have an NSDictionary that looks like this.
{
anonymous = true;
"attendee_id" = 5796;
"briefing_id" = 616;
comments = "More Cookies please!";
data = (
{
"agenda_id" = 1200;
| <!-- layout file --> | |
| <% if current_user %> | |
| Welcome <%= current_user.username %>. Not you? <%= link_to "Log out", logout_path %> | |
| <% else %> | |
| <%= link_to "Sign up", signup_path %> or <%= link_to "log in", login_path %>. | |
| <% end %> |
| # create rvmrc file | |
| create_file ".rvmrc", "rvm gemset use #{app_name}" | |
| gem "haml-rails" | |
| gem "sass" | |
| # hpricot and ruby_parser required by haml | |
| gem "hpricot", :group => :development | |
| gem "ruby_parser", :group => :development | |
| gem "nifty-generators" | |
| gem "simple_form" |
| var _save = Backbone.Model.prototype.save; | |
| var BaseModel = Backbone.Model.extend({ | |
| save: function(attrs, options) { | |
| options || (options = {}); | |
| var success = options.success; | |
| var model = this; | |
| // success doesn't have an event so always trigger | |
| options.success = function(resp, status, xhr) { | |
| model.trigger('success', model, resp, xhr); |
| // found this here, OMG http://net.tutsplus.com/tutorials/javascript-ajax/what-they-didnt-tell-you-about-es5s-array-extras | |
| function calculate (calculation) { | |
| //build an array containing the individual parts | |
| var parts = calculation.match( | |
| // digits |operators|whitespace | |
| /(?:\-?[\d\.]+)|[-\+\*\/]|\s+/g | |
| ); | |
| //test if everything was matched | |
| if( calculation !== parts.join("") ) { |
So you have an NSDictionary that looks like this.
{
anonymous = true;
"attendee_id" = 5796;
"briefing_id" = 616;
comments = "More Cookies please!";
data = (
{
"agenda_id" = 1200;
| " Set up some useful Rails.vim bindings for working with Backbone.js | |
| autocmd User Rails Rnavcommand template app/assets/javascripts/backbone/templates -glob=**/* -suffix=.jst.ejs | |
| autocmd User Rails Rnavcommand jmodel app/assets/javascripts/backbone/models -glob=**/* -suffix=.coffee | |
| autocmd User Rails Rnavcommand jview app/assets/javascripts/backbone/views -glob=**/* -suffix=.coffee | |
| autocmd User Rails Rnavcommand jcollection app/assets/javascripts/backbone/collections -glob=**/* -suffix=.coffee | |
| autocmd User Rails Rnavcommand jrouter app/assets/javascripts/backbone/routers -glob=**/* -suffix=.coffee | |
| autocmd User Rails Rnavcommand jspec spec/javascripts -glob=**/* -suffix=.coffee |
If you need to add the ability change passwords in the "admin" panel of boilerplate.
Add the password and password_confirmation to the User Decorator
# app/decorators/inherited_resources/user_decorator.rb
module InheritedResources
class UserDecorator < Decorator
# ...