search for: beds_f

Displaying 3 results from an estimated 3 matches for "beds_f".

Did you mean: beds_a
2006 Feb 18
1
sql logic is killing me
...y_id] ], :include => [:facility, :client], :order_by => ''facilities.name, clients.last_name, :per_page => 14) @facility = Facility.find(:first, :conditions => ["id = ?", params[:facility_id] ]) @beds_total = @facility.beds_m + @facility.beds_f + @facility.beds_a @beds_m_cnt = Client.count_by_sql("select count(*) " + " from clients where sex = ''M'' ") end the @beds_m_cnt gives me count of all Male clients but I only need the ones in @placements which I can''t seem to use in the @be...
2006 May 17
5
select list
I''m trying to build a selection list which I have done in various ways but this one is new to me. I have a ''facilities'' table which has all the outpatient facilities but I need to add ''Float'' and ''Main Office'' which I don''t want to add to the ''facilities'' table itself. so I figure I can add these to an
2006 Mar 16
32
iterating a partial with :collection
.... I have hash of several arrays that I want to iterate though and display. the first hashed element looks like this (greatly simplified) - :facility: !ruby/object:Facility attributes: name: Toby I beds_a: "12" beds_m: "12" id: "1" beds_f: "12" :placements: [] My view code (fac_log_all_test) is a one liner... <%= render :partial => ''fac_log_test'', :collection => @facility_log_run %> According to the AWDWR book "Inside the partial, the local variable ''article'' will b...