search for: programtypes

Displaying 2 results from an estimated 2 matches for "programtypes".

Did you mean: program_types
2006 Jan 23
3
problem with a selfmade helper method
...pter 17, pp. 259, 260) example from Dave & David''s Book. The optiongroups are properly created by my method, but there are no options inside. Maybe you can debug this one? -snip- from index.rhtml <%= option_groups_from_collection_for_select( grouped_programs_selector(:programs, :programtypes), # calling application_helper - method. :options, :type_name, :id, :name, @programs) %> -snap- application_helper.rb module ApplicationHelper class ProgramOption attr_reader :attributes @attributes = [] def initialize(id, name) @attributes = Str...
2006 Feb 06
4
Basic MVC in RoR question
Ok, Here''s my controller: def create trainingplan = Trainingplan.createplan(@params[:startdate], @params[:enddate], @params[:hoursperweek], @params[:programtype]) end My model is: class Trainingplan <ActiveRecord::Base def self.createplan(stardate, enddate, hoursperweek, programtype) stardate = startdate enddate = enddate hoursperweek = hoursperweek programtype