Method: Iatelier::Controllers::Books::New#call
- Defined in:
- lib/iatelier/controllers/books/new.rb
#call(params) ⇒ Object
8 9 10 11 12 13 14 15 16 |
# File 'lib/iatelier/controllers/books/new.rb', line 8 def call(params) # [optional] setting the database @database = params.get(:database) self.set_database @database @book_type = params[:book_type].capitalize; @book = Object.const_get(@book_type).new @book.namespace = @database end |