Class: ProMashRec::MashStep
Constant Summary
collapse
- @@step_types =
{ 0 => "Infusion", 1 => "Direct", 2 => "Decoction" }
Instance Method Summary
collapse
#as_json, json_create
#as_beerxml, #as_brewson, auto_migrate_down!, auto_migrate_up!, auto_upgrade!, default_repository_name
Instance Method Details
#from_promash(step, idx = nil) ⇒ Object
315
316
317
318
319
320
321
322
323
324
325
326
|
# File 'lib/brewser/engines/promash_rec.rb', line 315
def from_promash(step,idx=nil)
self.name = step.name
self.index = idx
self.type = @@step_types[step.type]
self.ramp_time = "#{step.step_time} min".u
self.rest_temperature = "#{step.start_temp} dF".u
self.rest_time = "#{step.rest_time} min".u
self.infusion_temperature = "#{step.step_temp} dF".u unless step.step_temp.blank?
self.infusion_amount = "#{step.amount} qts".u unless step.amount.blank?
return self
end
|
#from_simple(idx, name, rest_temp, rest_time) ⇒ Object
306
307
308
309
310
311
312
313
|
# File 'lib/brewser/engines/promash_rec.rb', line 306
def from_simple(idx, name, rest_temp, rest_time)
self.index = idx
self.name = name
self.rest_temperature = rest_temp.u
self.rest_time = rest_time.u
return self
end
|