以下を参考に合体させたいと考えているところ。まだnested formに対応してない。
- formをfillする
- nasted formも対応しているように見えるがcheckbox対応できてない
- backbone-railsのbackbone_datalink.jsの改良版
- これは、codebrew/backbone-rails #27でpull requestとなっているもの
- checkbox対応してる
| #!/usr/bin/env ruby | |
| num = ARGV.first.to_i | |
| nums1 = ['zero', 'one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight', 'nine'] | |
| nums10 = ['ten', 'eleven', 'twelve', 'thirteen', 'fourteen', 'fifteen', 'sixteen', 'seventeen', 'eighteen', 'nineteen'] | |
| if num < 10 | |
| puts nums1[num] | |
| elsif 10 <= num && num < 20 |
| { | |
| "color_scheme": "Packages/User/Railscasts.tmTheme", | |
| "font_face": "Bitstream Vera Sans Mono", | |
| "font_size": 14.0, | |
| "ignored_packages": [""], | |
| "vintage_start_in_command_mode": true, | |
| "translate_tabs_to_spaces": true, | |
| "vintage_ctrl_keys": true | |
| } |
| require 'spec_helper' | |
| describe 'layouts/application' do | |
| describe 'rendered application layout' do | |
| subject { rendered } | |
| context 'when body_class is setted ' do | |
| before do | |
| view.content_for(:body_class, 'test_class') | |
| render | |
| end |
以下を参考に合体させたいと考えているところ。まだnested formに対応してない。
| #import <Foundation/Foundation.h> | |
| @interface AccessTokenManager : NSObject | |
| @property (nonatomic, copy) NSString *facebookAccessTokenKey; | |
| + (AccessTokenManager *)sharedManager; | |
| @end |
| #import <Foundation/Foundation.h> | |
| @interface UIUtilitiy : NSObject | |
| + (void)showAlert: (NSString*)title text:(NSString*)text; | |
| + (void)showActivityIndicator:(UIViewController *)controller; | |
| + (void)hideActivityIndicator; | |
| @end |
| NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:url]]; | |
| AFJSONRequestOperation *operation = [AFJSONRequestOperation JSONRequestOperationWithRequest:request success:^(NSURLRequest *request, NSHTTPURLResponse *response, id JSON) { | |
| if (self.item_page == 1 && !JSON) { | |
| [UIUtilitiy hideActivityIndicator]; | |
| [UIUtilitiy showAlert:@"error" text:@"見つかりませんでした"]; | |
| return; | |
| } | |
| if (JSON) { | |
| [self.items addObjectsFromArray:[[[NSMutableArray alloc]initWithArray:JSON]autorelease]]; | |
| self.not_found = NO; |
| window.App = | |
| Models: {} | |
| Collections: {} | |
| Views: {} | |
| Routers: {} | |
| init: (options)-> | |
| options = {} unless options | |
| options.pushState = true | |
| options.hashChange = false # don't want to rewrite /pathname to #pathname |
| My::Application.routes.draw do | |
| # /my scope for current_user | |
| scope :path => :my do | |
| resources :followings, :only => [:index, :update, :destroy], :as => :my_followings | |
| resources :followers, :only => [:index], :as => :my_followers | |
| resources :feeds, :only => [:index], :as => :my_feeds | |
| resources :groups, :only => [:index], :as => :my_groups do | |
| member do | |
| put :entry, :action => :join |
| My::Application.routes.draw do | |
| resources :users, :only => [:show] do | |
| resources :followings, :only => [:index] | |
| resources :followers, :only => [:index] | |
| resources :groups, :only => [:index] | |
| end | |
| end |