\CalendarConfig
Calendar Config
NOTE: This module will not function properly without having been initialized through the
project specific _config.php file. At the minimum, you need to add the following line:
CalendarConfig::init();
As calendar implementations often differ substantially, the calendar module
can be configured through this file.
The configuration shown here is the calendar with all basic features enabled.
This will seldom be the case, and hence it's expected that the configuration is amended
when the module is instantiated in the project _config.php file.
...and YES, I know SilverStripe 3.1 has a built-in config system, this
has been coded prior to this though - pull requests welcome ;)
Synopsis
class CalendarConfig
{
- // members
- protected static type $settings = ;
- // methods
- public static void settings()
- protected static void mergeSettings()
- public static array subpackage_settings()
- public static boolean subpackage_enabled()
- public static void subpackage_setting()
- public static void init()
Members
protected
- $settings
—
type
Base calendar settings All basic features are enabled
Methods
protected
- mergeSettings() — method for merging setting files
public
- init() — Calendar initialization Should be called from the project _config.php file
- settings() — Config setter & getter This serves as a settings setter and getter at the same time
- subpackage_enabled() — Getter that checks if a specific subpackage is enabled A subpackage is seen as being enabled if 1. it exists in setting 2. it a) either doesn't have an 'enabled' attribute (then it's enabled by default) b) or has an 'enabled' attribute that's set to true
- subpackage_setting() — Getter for a specific setting from a subpackage
- subpackage_settings() — Getter for subpackage specific settings