Method: Workpattern::Workpattern#workpattern
- Defined in:
- lib/workpattern/workpattern.rb
#workpattern(opts = {}) ⇒ Object
Applys a working or resting pattern to the Workpattern object.
The #resting and #working methods are convenience methods that call this with the appropriate :work_type already set.
apply to.It defaults to :all days to apply the pattern. Defaults to 00:00. days to apply the pattern. Defaults to 23:59. Defaults to working.
153 154 155 156 157 158 159 |
# File 'lib/workpattern/workpattern.rb', line 153 def workpattern(opts = {}) if self.class.persistence? week_pattern.workpattern(opts, @@persistence) else week_pattern.workpattern(opts) end end |