Class: Achoo::Achievo::HourRegistrationFormRanged
- Inherits:
-
HourRegistrationForm
- Object
- HourRegistrationForm
- Achoo::Achievo::HourRegistrationFormRanged
- Defined in:
- lib/achoo/achievo/hour_registration_form_ranged.rb
Instance Method Summary collapse
- #date ⇒ Object
- #date=(date_range) ⇒ Object
-
#initialize ⇒ HourRegistrationFormRanged
constructor
A new instance of HourRegistrationFormRanged.
Methods inherited from HourRegistrationForm
#all_projects, #billing=, #billing_options, #collect_options, #get_all_projects, #hours=, #phase, #phase=, #phases_for_selected_project, #print_values, #project, #project=, #recent_projects, #remark=, #submit, #workperiod=, #worktime_periods
Constructor Details
#initialize ⇒ HourRegistrationFormRanged
Returns a new instance of HourRegistrationFormRanged.
9 10 11 12 13 14 15 16 |
# File 'lib/achoo/achievo/hour_registration_form_ranged.rb', line 9 def initialize super @page = AGENT.get(atk_submit_to_url(@page.link_with(:text => 'Select range').href)) @form = @page.form('entryform') # Need to preselect this for some reason. FIX duplicated in super @form.field_with(:name => 'billpercent')..first.select end |
Instance Method Details
#date ⇒ Object
23 24 25 |
# File 'lib/achoo/achievo/hour_registration_form_ranged.rb', line 23 def date [super, to_date()] end |
#date=(date_range) ⇒ Object
18 19 20 21 |
# File 'lib/achoo/achievo/hour_registration_form_ranged.rb', line 18 def date=(date_range) super(date_range[0]) self.to_date = date_range[1] end |