This module allows to schedule a campaign (silverstripe/campaign-admin) to be published at a later date.
composer require dnadesign/silverstripe-campaign-schedule ^1
This module is not on Packagist yet, so to install, you need to require the modules via vcs.
"require": {}
"dnadesign/silverstripe-campaign-schedule": "dev-master",
},
"repositories": [
{
"type": "vcs",
"url": "[email protected]:dnadesign/silverstripe-campaign-schedule.git"
}
]
- SilverStripe ^4
- silverstripe/campaign-admin
- silverstripe/cron-task
Make sure to add the server configuration for the cron task module.
Follow the guide to add pages and documents to a new or existing campaign.
To edit a campaign, go to the Campaigns
tab and click the cog icon of the campaign you wish to schedule.
Then, open the Schedule
tab and set a date and time. You can also associate watchers (members) to the campaign so they will receive an email once the campaign has been published via cron.
Note: if a date is set in the past, the campaign will published as soon as the cron runs. Also a campaign can still be published manually at any time.
To test this functionality locally, set up a schedule for a campaign then run sake dev/cron
. This will run the cron task and if the campaign's schedule is in the past, it will get published.
Note: make sure your local environment has the right timezone set up.