1.4releasedField : Duration
A field that stores duration.
Clone URLhttps://github.com/vlad-ghita/duration_field.git
Add as a submodulegit submodule add https://github.com/vlad-ghita/duration_field.git extensions/duration_field --recursive
Compatibility
2.x.x | 2.1.x | 2.2.x | 2.3.x | 2.4.x | 2.5.x | 2.6.x | 2.7.0 | 2.7.1 | 2.7.2 | 2.7.3 | 2.7.4 | 2.7.5 | 2.7.6 | 2.7.7 | 2.7.8 | 2.7.9 | 2.7.10 |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
No | No | No | 1.4 | No | No | No | No | No | No | No | No | No | No | No | No | No | No. Soon? |
Readme
Duration Field
Duration field for Symphony CMS.
Allows input of duration through duration
settings:
- weeks
- days
- hours
- minutes
- seconds
- fractions (of a second)
Features:
- enable / disable usage of each setting. At a very minimum,
seconds
are enforced.fractions
are allowed only withseconds
- sorting
- filtering
Filters:
- Equality:
X
- Larger:
greater than X
- Equal or larger:
equal to or greater than X
- Less:
less than X
- Equal or less:
equal to or less than X
- Range:
X to Y
XML result
<duration timestamp="2044029.75">
<weeks>3</weeks>
<days>2</days>
<hours>15</hours>
<minutes>47</minutes>
<seconds>9</seconds>
<fractions>75</fractions>
</duration>
Usage in forms
1_ Either send the timestamp:
fields[field-handle] = 123456789.123
2_ Or send desired duration
settings. Any missing duration
setting will default to 0:
fields[field-handle][weeks] = ...
fields[field-handle][days] = ...
fields[field-handle][hours] = ...
fields[field-handle][minutes] = ...
fields[field-handle][seconds] = ...
fields[field-handle][fractions] = ...
Version history
Symphony 2.3.x only
- Fixed submit from Frontend
Symphony 2.3.x only
- Fixed filtering
Symphony 2.3.x only
- Added settings to field schema
Symphony 2.3.x only
- Moved timestamp output to element attribute
- Improved minimum settings enforcing upon saving
Symphony 2.3.x only
- First release.