Class: Research
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- Research
- Defined in:
- app/models/research.rb
Overview
This class describes a research.
Instance Method Summary (collapse)
-
- (String) complete_date_txt
Return the complete date of queue item.
-
- (String) name
Return the description of research.
Instance Method Details
- (String) complete_date_txt
Return the complete date of queue item.
18 19 20 21 22 23 |
# File 'app/models/research.rb', line 18 def complete_date_txt return nil if allotment == 0 rq_prod_point = (level + 1) * Params::RESEARCH_COST_BASE complete_date = ((rq_prod_point - invested_point) / allotment).ceil return complete_date.to_s + I18n.t('activerecord.attributes.rq_days_suffix') end |
- (String) name
Return the description of research.
12 13 14 |
# File 'app/models/research.rb', line 12 def name return I18n.t('activerecord.attributes.research.' + symbol) end |