Cron Picker
Cron Picker is a gh-element that allows you to get a cron expression using convenient options and save it. It can be used to set the schedule for your server.
After the user clicks on the current field, a cron pop-up window will open. This pop-up window contains the main list of options.
Picker Options
As mentioned earlier, a cron pop-up window appears after clicking on the field. This pop-up window contains all the options that allow the user to customize the cron value.
In the upper left part of the window, the user can see a field that displays the final cron value. On the right side, there are three buttons that allow to copy, reset, and save the configured value.
The next interface elements are the options tabs. Each of them allows a user to customize a specific unit of time. There are four default tabs:
But, there is also an additional extra tab called Seconds. It is responsible for the seconds. This tab appears if the Show Seconds option is enabled.
In general, the unit settings are very similar. All of them have options that allow users to choose: all units at once, units for a certain period, each unit starting with a certain one, or select several specific unit values. But also, some tabs has a unique options or unique variations of the above options.
Above the tabs, the user can see the value of each unit separately:
- Seconds
- Minutes
- Hours
- Day of month
- Month
- Day of week
Depending on which tab and how the user edits, the value will change.
Minutes
The first default tab of the picker allows user to select the certain minutes or minute periods.
Hours
This is the default tab, which has a standard set of settings customized for its units.
Day
The current tab has the biggest set of options. In addition to the standard options, this tab allows users to select a specific day of the week and several additional time periods by default.
Month
The last default tab allows user to configure the month unit.
Seconds
A single additional options tab allows the user to set the required seconds.
Functional Characteristics
The current gh-element is mostly used to generate cron expressions. If you're working with a server, you can use the current element to get the expression you need.
Element Options
The current gh-element has only one block of settings.
Field Settings
Field settings of the current element has quite small set of settings. The first two settings are standard, and the third is unique to this element.
Name | Description |
---|---|
Show seconds | allows to use the seconds in the cron picker |
Show Seconds
The current setting allows you to add seconds to your cron. When this option is on, the seconds tab appears in the cron picker.
Element Style
Cron Picker is one of the gh elements that are almost unaffected by style settings. Therefore, it has only a standard set of style options and a couple of interpretation types.
Filtration
Despite that this element has a field value, it cannot be filtered out.
Interpretation
The current gh-element has only two types of interpretation:
Default
The first interpretation type allows user to open the cron picker and enter any value.
Value
The second type of interpretation displays only the saved value without the ability to update it.
Value Format
The value of the current element stores the created cron expression in the string format:
{
"field_value": "0 0,2 0,2 1,7 JAN,APR ?"
}
Data Model
The current element has only two properties in its data model:
{
"data_model": {
"interpretation": [],
"show_seconds": 1
}
}
Name | Type | Description |
---|---|---|
interpretation | array |
contains all element interpretation types |
show_seconds | boolean |
shows whether seconds are used in the cron picker or not |