18 Apr '12, 2am

ActiveRecord Store in Rails 3.2 is really handy!

Store gives you a thin wrapper around serialize for the purpose of storing hashes in a single column. It's like a simple key/value store backed into your record when you don't care about being able to query that store outside the context of a single record. You can then declare accessors to this store that are then accessible just like any other attribute of the model. This is very helpful for easily exposing store keys to a form or elsewhere that’s already built around just accessing attributes on the model. Make sure that you declare the database column used for the serialized store as a text, so there’s plenty of room. Examples: class User < ActiveRecord :: Base store :settings , accessors : [ :color , :homepage ] end u = User .new (color : 'black' , homepage : '37signals.com' ) u .color # Accessor stored attribute u .settings [:country ] = 'Denmark' # Any attribute, ev...

Full article: http://api.rubyonrails.org/classes/ActiveRecord/Store.html

Tweets

[News] - Nike Store Launches New Twitter RSVP System

[News] - Nike Store Launches New Twitter RSVP S...

kicksonfire.com 18 Apr '12, 1am

As of lately, the process of camping for sneakers has been a bit of an issue. In light of the challenges that this has cau...

says “we now only reload classes from files you...

weblog.rubyonrails.org 15 Apr '12, 10am

So we didn’t quite make the December release date as we intended, but hey, why break a good tradition and start hitting re...

Nike Store Launches New Twitter RSVP System Designed to End Campouts

Nike Store Launches New Twitter RSVP System Des...

kixandthecity.com 17 Apr '12, 10pm

One item allowed per person, even if you receive two confirmations of successful registrations. Abuse of this rule may res...

New iPad now available on Apple Store online from RM1499

New iPad now available on Apple Store online fr...

soyacincau.com 19 Apr '12, 4pm

For the 4G + WiFi version, although the 4G band is not supported in Malaysia, it still supports the usual 3G networks here...

Nike Store Launches Twitter RSVP

Nike Store Launches Twitter RSVP

theshoegame.com 18 Apr '12, 6pm

On the RSVP date, our store will send a tweet at a random time to begin our Twitter RSVP process, including a product spec...

Getting Started with Rails:

guides.rubyonrails.org 19 Apr '12, 1am

Rails is a web application development framework written in the Ruby language. It is designed to make programming web appl...

[SHOPPING] Happy Record Store Day! Here are our secret (well, not anymore) Singapore haunts for audiophiles:

[SHOPPING] Happy Record Store Day! Here are our...

is.asia-city.com 21 Apr '12, 4am

It’s a little known fact that Singapore was once home to a buzzing local music scene featuring psychedelic Chinese-dialect...

Rails Internals: Active Model Observers

rubyflow.com 18 Apr '12, 12pm

Rails Internals: Active Model Observers Posted by oscardb on April 18, 2012 — 0 comments New article in the Rails internal...

Haul: INGLOT Store Opens at JB City Square

Haul: INGLOT Store Opens at JB City Square

retailtherapy.onsugar.com 15 Apr '12, 9am

A couple of weeks back, the bro and I went to JB for the afternoon, nothing much on the agenda, but I did hear that INGLOT...

Riding Rails: Three reasons to love ActionContr...

weblog.rubyonrails.org 14 Apr '12, 12pm

Three reasons to love ActionController::Responder Posted by José Valim , August 31, 2009 @ 10:02 am A couple weeks ago, I ...