hobo

How do I get aside layout to work in hobo 0.8

I have tried several different things in clean.dryml and application.dryml. It's not clear (without reading the source) how this works. I would expect one of these to work, but they do not. <old-page merge layout="aside"> OR <old-page merge aside-layout> ...

How do I define a database index in HoboFields?

With HoboFields, I can declare fields for my model in its own file, like this: class User < ActiveRecord::Base fields do login :string persistence_token :string end end I'd like to know if there's equivalent syntax for the add_index command I can use in vanilla Rails migrations. ...

How do i create a form that inputs multiple items of a model?

I have a simple point of sale application written in ruby and rails, and hobo. Originally intended to be for only one product at the time, now the client wants to add multiple products into the sale model Besides that i am using brands for categorizing products and in my new sale form i use ajax in order to populate a select product me...

Custom validation help needed.

hi i have in my model: validate :check_product_stock def check_product_stock @thisproduct = product.id @productbeingchecked = Product.find_by_id(@thisproduct) @stocknumber = @productbeingchecked.stock_number if producto.en_stock == 0 raise "El Producto no tiene stock suficiente para completar la venta" #errors.add ...

fading flash notices with hobo?

Hello I need help in order to create site-wide fading flash notices. I am using hobo. thanks in advance. ...

Rails and Hobo with Single Table Inheritance problem

I'm getting an error when running db:setup for my Hobo project with a clean database. I have two models, A and B, where B extends A through single-table-inheritance. Creating everything works. But if I start with a fresh database, rake fails with an error: $ rake db:setup ... rake aborted! Table as does not exist Here are the steps I ...

Does anybody have any experience with Hobo?

I'm thinking of adopting HOBO for quicker development of some Rails apps I want to develop on the side for myself. Obviously there seems to be a certain learning curve to get the different concepts and specific coding practices of the gem and its dryml templates. Also the documentation seems close to non-existent so I'm not sure I wan...

Radio buttons in Hobo Rails

How can I use radio buttons in a form in Hobo Rails? I want a gender field with two options "Male" and "Female". If I use the default enum_string type it creates drop down select instead of radio buttons. ...

RAils Authlogic and Hobo

Is there anyone out there who has an idea of how to incorporate Hobo as an admin subsite on a existing rails app running on authlogic. I've been following this tutorial, but it not working. Any help or Tutorial link please! Some erorr code for anyone who fancies a crack: ~/dev/copy> ./script/server => Booting Mongrel => Rails 2.3.4 a...

Hobo with authlogic user session problem

Just a day into hobo now I think it's great but got a small problem. User session are running with hobo, can't get current_user. I can login in to my site as normal without adding the line session[:user] = user.typed_id def create @user_session = UserSession.new(params[:user_session]) session[:user] = user.typed_id if...

Syntax highlighting for .dryml in Notepad++

I've been learning Hobo, an awesome wrapper for Ruby on Rails that I'm finding extremely DRY and n00b-friendly. But how do I set Notepad++ to automatically recognize .dryml files such that appropriate syntax highlighting is applied? ...

How does one pre-fill a has_many collection using Hobo?

I have an order entry-like system where we know most of the time we'll need to use most items in the product catalog. The models are: class Product < ActiveRecord::Base hobo_model fields do name :string end end class Order < ActiveRecord::Base hobo_model fields do ship_to :text end has_many :order_lines end class...