Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • project/recurring_events
  • issue/recurring_events-3183502
  • issue/recurring_events-3183463
  • issue/recurring_events-3183483
  • issue/recurring_events-3190526
  • issue/recurring_events-3191715
  • issue/recurring_events-3190833
  • issue/recurring_events-3188808
  • issue/recurring_events-3180479
  • issue/recurring_events-3122823
  • issue/recurring_events-3196649
  • issue/recurring_events-3196428
  • issue/recurring_events-3196702
  • issue/recurring_events-3196704
  • issue/recurring_events-3198532
  • issue/recurring_events-3164409
  • issue/recurring_events-3206960
  • issue/recurring_events-3115678
  • issue/recurring_events-3218496
  • issue/recurring_events-3207435
  • issue/recurring_events-3219082
  • issue/recurring_events-3217367
  • issue/recurring_events-3229514
  • issue/recurring_events-3231841
  • issue/recurring_events-3238591
  • issue/recurring_events-3282502
  • issue/recurring_events-3283128
  • issue/recurring_events-3240862
  • issue/recurring_events-3247034
  • issue/recurring_events-3071679
  • issue/recurring_events-3264621
  • issue/recurring_events-3266436
  • issue/recurring_events-3268690
  • issue/recurring_events-3269555
  • issue/recurring_events-3271328
  • issue/recurring_events-3272361
  • issue/recurring_events-3163804
  • issue/recurring_events-3297681
  • issue/recurring_events-3299575
  • issue/recurring_events-3300786
  • issue/recurring_events-3302916
  • issue/recurring_events-3304286
  • issue/recurring_events-3298679
  • issue/recurring_events-3309652
  • issue/recurring_events-3310360
  • issue/recurring_events-3311843
  • issue/recurring_events-3311712
  • issue/recurring_events-3312003
  • issue/recurring_events-3312084
  • issue/recurring_events-3312242
  • issue/recurring_events-3316080
  • issue/recurring_events-3295367
  • issue/recurring_events-3196417
  • issue/recurring_events-3309859
  • issue/recurring_events-3318590
  • issue/recurring_events-3244975
  • issue/recurring_events-3318998
  • issue/recurring_events-3321269
  • issue/recurring_events-3320512
  • issue/recurring_events-3321235
  • issue/recurring_events-3321550
  • issue/recurring_events-3322998
  • issue/recurring_events-3315836
  • issue/recurring_events-3324055
  • issue/recurring_events-3328907
  • issue/recurring_events-3318490
  • issue/recurring_events-3339288
  • issue/recurring_events-3345618
  • issue/recurring_events-3347935
  • issue/recurring_events-3362297
  • issue/recurring_events-3359696
  • issue/recurring_events-3318666
  • issue/recurring_events-3366907
  • issue/recurring_events-3366910
  • issue/recurring_events-3403064
  • issue/recurring_events-3404311
  • issue/recurring_events-3405567
  • issue/recurring_events-3376639
  • issue/recurring_events-3384836
  • issue/recurring_events-3382387
  • issue/recurring_events-3384389
  • issue/recurring_events-3315503
  • issue/recurring_events-3411229
  • issue/recurring_events-3415222
  • issue/recurring_events-3415308
  • issue/recurring_events-3172514
  • issue/recurring_events-3419694
  • issue/recurring_events-3178696
  • issue/recurring_events-3408924
  • issue/recurring_events-3447130
  • issue/recurring_events-3416436
  • issue/recurring_events-3451613
  • issue/recurring_events-3452632
  • issue/recurring_events-3453086
  • issue/recurring_events-3452641
  • issue/recurring_events-3454012
  • issue/recurring_events-3455716
  • issue/recurring_events-3456300
  • issue/recurring_events-3456641
  • issue/recurring_events-3462327
  • issue/recurring_events-3463467
  • issue/recurring_events-3463979
  • issue/recurring_events-3462480
  • issue/recurring_events-3464792
  • issue/recurring_events-3456045
  • issue/recurring_events-3468300
  • issue/recurring_events-3468521
  • issue/recurring_events-3475611
  • issue/recurring_events-3477247
  • issue/recurring_events-3477047
  • issue/recurring_events-3477650
  • issue/recurring_events-3257502
  • issue/recurring_events-3090186
  • issue/recurring_events-3478802
  • issue/recurring_events-3479449
  • issue/recurring_events-3479843
  • issue/recurring_events-3479860
  • issue/recurring_events-3480495
  • issue/recurring_events-3480500
  • issue/recurring_events-3480746
  • issue/recurring_events-3480973
  • issue/recurring_events-3481021
  • issue/recurring_events-3481722
  • issue/recurring_events-3482804
  • issue/recurring_events-3483283
  • issue/recurring_events-3484209
  • issue/recurring_events-3170156
  • issue/recurring_events-3484558
  • issue/recurring_events-3485904
  • issue/recurring_events-3485935
  • issue/recurring_events-3487412
  • issue/recurring_events-3496270
  • issue/recurring_events-3480508
  • issue/recurring_events-3499792
  • issue/recurring_events-3500920
  • issue/recurring_events-3510919
  • issue/recurring_events-3510942
  • issue/recurring_events-3478268
138 results
Show changes
Commits on Source (207)
Showing
with 1206 additions and 70 deletions
......@@ -81,7 +81,7 @@ if [ -n "${DRUPAL_VERSION}" ] && [ -n "${DRUPAL_PROJECT_SHA}" ]; then
php -d memory_limit=-1 "$(command -v composer)" --working-dir="${BUILD_DIR}" install
else
echo "==> Initialise Drupal site from the latest scaffold."
php -d memory_limit=-1 "$(command -v composer)" create-project drupal-composer/drupal-project:8.x-dev "${BUILD_DIR}" --no-interaction
php -d memory_limit=-1 "$(command -v composer)" create-project drupal-composer/drupal-project:9.x-dev "${BUILD_DIR}" --no-interaction
fi
echo "==> Install additional dev dependencies from module's composer.json."
......@@ -91,6 +91,7 @@ php -d memory_limit=-1 "$(command -v composer)" --working-dir="${BUILD_DIR}" upd
echo "==> Install other dev dependencies."
cat <<< "$(jq --indent 4 '.extra["phpcodesniffer-search-depth"] = 10' "${BUILD_DIR}/composer.json")" > "${BUILD_DIR}/composer.json"
php -d memory_limit=-1 "$(command -v composer)" --working-dir="${BUILD_DIR}" require --dev dealerdirect/phpcodesniffer-composer-installer
php -d memory_limit=-1 "$(command -v composer)" --working-dir="${BUILD_DIR}" require --dev phpspec/prophecy-phpunit:^2
echo "==> Start inbuilt PHP server at http://${WEBSERVER_HOST}:${WEBSERVER_PORT} in $(pwd)/${BUILD_DIR}/web."
killall -9 php > /dev/null 2>&1 || true
......
......@@ -13,9 +13,9 @@ job-build: &job-build
steps:
- checkout
- run: |
sudo -E apt-get update && sudo -E apt-get install -y libfreetype6-dev libjpeg62-turbo-dev libpng-dev jq \
sudo -E apt-get --allow-releaseinfo-change update && sudo -E apt-get install -y libfreetype6-dev libjpeg62-turbo-dev libpng-dev jq \
&& sudo -E docker-php-ext-install -j$(nproc) iconv \
&& if [ "$(php -r "echo PHP_MAJOR_VERSION;")" -gt 5 ] && [ "$(php -r "echo PHP_MINOR_VERSION;")" -gt 3 ] ; then sudo -E docker-php-ext-configure gd --with-freetype --with-jpeg; else sudo -E docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/; fi \
&& if [ "$(php -r "echo PHP_MAJOR_VERSION;")" -gt 5 ] ; then sudo -E docker-php-ext-configure gd --with-freetype --with-jpeg; else sudo -E docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/; fi \
&& sudo -E docker-php-ext-install -j$(nproc) gd
- run: .circleci/build.sh
- run: .circleci/lint.sh
......@@ -35,41 +35,26 @@ jobs:
<<: *container_config
<<: *job-build
build-php-7.3:
build-php-8.0:
<<: *container_config
docker:
- image: circleci/php:7.3-cli-browsers
<<: *job-build
build-php-7.2:
<<: *container_config
docker:
- image: circleci/php:7.2-cli-browsers
- image: circleci/php:8.0-cli-browsers
<<: *job-build
build-php-7.4-legacy:
<<: *container_config
environment:
DRUPAL_VERSION: 8.8.10
DRUPAL_PROJECT_SHA: 8.x
DRUPAL_VERSION: 9.3.5
DRUPAL_PROJECT_SHA: 9.x
<<: *job-build
build-php-7.3-legacy:
build-php-8.0-legacy:
<<: *container_config
docker:
- image: circleci/php:7.3-cli-browsers
- image: circleci/php:8.0-cli-browsers
environment:
DRUPAL_VERSION: 8.8.10
DRUPAL_PROJECT_SHA: 8.x
<<: *job-build
build-php-7.2-legacy:
<<: *container_config
docker:
- image: circleci/php:7.2-cli-browsers
environment:
DRUPAL_VERSION: 8.8.10
DRUPAL_PROJECT_SHA: 8.x
DRUPAL_VERSION: 9.3.5
DRUPAL_PROJECT_SHA: 9.x
<<: *job-build
deploy:
......@@ -91,11 +76,7 @@ workflows:
filters:
tags:
only: /.*/
- build-php-7.3:
filters:
tags:
only: /.*/
- build-php-7.2:
- build-php-8.0:
filters:
tags:
only: /.*/
......@@ -103,25 +84,7 @@ workflows:
filters:
tags:
only: /.*/
- build-php-7.3-legacy:
filters:
tags:
only: /.*/
- build-php-7.2-legacy:
- build-php-8.0-legacy:
filters:
tags:
only: /.*/
# - deploy:
# requires:
# - build-php-7.4
# - build-php-7.3
# - build-php-7.2
# - build-php-7.4-legacy
# - build-php-7.3-legacy
# - build-php-7.2-legacy
# filters:
# tags:
# only: /.*/
# branches:
# 8.x, 8.x-Y.x, 2.x, ci
# only: /^8\.x(?:\-[0-9]+\.x)?|[0-9]+\.[0-9]+(?:\.x)?|ci$/
BYDAY
BYEASTER
BYHOUR
BYMINUTE
BYMONTH
BYMONTHDAY
BYSECOND
BYSETPOS
BYWEEKDAY
BYWEEKNO
BYYEARDAY
datecompact
datetimes
DTEND
DTSTAMP
DTSTART
~eventseries
~eventinstance
~eventinstances
EXDATE
EXRULE
fromto
~fullcalendar
INCDATE
langname
LINELENGTH
monthday
monthdays
nonwaitlisted
PRODID
recreator
~rrule
~rrule's
~rrules
VCALENDAR
VEVENT
~waitlist
~waitlisted
~webform
WKST
################
# GitLabCI template for Drupal projects.
#
# This template is designed to give any Contrib maintainer everything they need to test, without requiring modification.
# It is also designed to keep up to date with Core Development automatically through the use of include files that can be centrally maintained.
# As long as you include the project, ref and three files below, any future updates added by the Drupal Association will be used in your
# pipelines automatically. However, you can modify this template if you have additional needs for your project.
# The full documentation is on https://project.pages.drupalcode.org/gitlab_templates/
################
# For information on alternative values for 'ref' see https://project.pages.drupalcode.org/gitlab_templates/info/templates-version/
# To test a Drupal 7 project, change the first include filename from .main.yml to .main-d7.yml
include:
- project: $_GITLAB_TEMPLATES_REPO
ref: $_GITLAB_TEMPLATES_REF
file:
- "/includes/include.drupalci.main.yml"
- "/includes/include.drupalci.variables.yml"
- "/includes/include.drupalci.workflows.yml"
################
# Pipeline configuration variables are defined with default values and descriptions in the file
# https://git.drupalcode.org/project/gitlab_templates/-/blob/main/includes/include.drupalci.variables.yml
################
variables:
# Keep testing on Drupal 10 until our dependencies are D11 ready.
CORE_STABLE: $CORE_PREVIOUS_STABLE
phpcs:
allow_failure: false
services:
php:
image: q0rban/tugboat-drupal:9.0
default: true
http: false
depends: mysql
commands:
update: |
set -eux
# Check out a branch using the unique Tugboat ID for this repository, to
# ensure we don't clobber an existing branch.
git checkout -b $TUGBOAT_REPO_ID
# Composer is hungry. You need a Tugboat project with a pretty sizeable
# chunk of memory.
export COMPOSER_MEMORY_LIMIT=-1
# This is an environment variable we added in the Dockerfile that
# provides the path to Drupal composer root (not the web root).
cd $DRUPAL_COMPOSER_ROOT
# We configure the Drupal project to use the checkout of the module as a
# Composer package repository.
composer config repositories.tugboat vcs $TUGBOAT_ROOT
# Now we can require this module, specifing the branch name we created
# above that uses the $TUGBOAT_REPO_ID environment variable.
composer require drupal/recurring_events:dev-$TUGBOAT_REPO_ID
# Install Drupal on the site.
vendor/bin/drush \
--yes \
--db-url=mysql://tugboat:tugboat@mysql:3306/tugboat \
--site-name="Live preview for ${TUGBOAT_PREVIEW_NAME}" \
--account-pass=admin \
site:install standard
# Set up the files directory permissions.
mkdir -p $DRUPAL_DOCROOT/sites/default/files
chgrp -R www-data $DRUPAL_DOCROOT/sites/default/files
chmod 2775 $DRUPAL_DOCROOT/sites/default/files
chmod -R g+w $DRUPAL_DOCROOT/sites/default/files
# Enable the module.
vendor/bin/drush --yes pm:enable recurring_events
build: |
set -eux
# Delete and re-check out this branch in case this is built from a Base Preview.
git branch -D $TUGBOAT_REPO_ID && git checkout -b $TUGBOAT_REPO_ID || true
export COMPOSER_MEMORY_LIMIT=-1
cd $DRUPAL_COMPOSER_ROOT
composer install --optimize-autoloader
# Update this module, including all dependencies.
composer update drupal/recurring_events --with-all-dependencies
vendor/bin/drush --yes updb
vendor/bin/drush cache:rebuild
mysql:
image: tugboatqa/mariadb
......@@ -202,7 +202,7 @@ modules can be written to modify, or enhance the core functionality
of `recurring_events` by making use of these hooks.
The `recurring_events` module also has a number of Field Inheritance plugins
written to handle core fields, and custom plugins can be creared providing they
written to handle core fields, and custom plugins can be created providing they
implement the `FieldInheritance` annotation and extend
the `FieldInheritancePluginBase` class. The core plugins are defined
in `src/Plugin/FieldInheritance`.
......@@ -228,3 +228,9 @@ therefore can be overridden or extended, without affecting the rest of the
series. This module also comes with a registration submodule, including the
ability to register either for an entire series, or individual events.
Using `date_recur` that would not be possible as there is only one entity.
### Getting Started
- Configure the Events Series and Event Instances at /admin/structure/events.
- Add an event entity by going to Content -> Events -> Add Event (/events/add). Note: If you already have an Events node type, there may be some route collisions, and you may now see two menu items with a title of "Events". See the recurring_events.routing.yml for the existing routes.
- Note: If you try to add the newly created Event fields types (Consecutive Event, Daily Event, Monthly Event, Weekly Event) directly on a node/entity, you're doing it wrong and it will complain about missing plugin types.
......@@ -11,6 +11,9 @@
"source": "http://cgit.drupalcode.org/recurring_events"
},
"require": {
"drupal/field_inheritance": "^1"
"drupal/field_inheritance": "^2"
},
"require-dev": {
"drupal/token": "^1.11"
}
}
......@@ -28,7 +28,7 @@ content:
third_party_settings: { }
custom_date:
type: daterange_default
weight: 7
weight: 8
region: content
settings: { }
third_party_settings: { }
......@@ -40,13 +40,13 @@ content:
third_party_settings: { }
excluded_dates:
type: daterange_default
weight: 8
weight: 9
settings: { }
region: content
third_party_settings: { }
included_dates:
type: daterange_default
weight: 9
weight: 10
settings: { }
region: content
third_party_settings: { }
......@@ -66,7 +66,7 @@ content:
type: boolean_checkbox
settings:
display_label: true
weight: 12
weight: 13
region: content
third_party_settings: { }
title:
......@@ -79,7 +79,7 @@ content:
third_party_settings: { }
uid:
type: entity_reference_autocomplete
weight: 11
weight: 12
settings:
match_operator: CONTAINS
size: 60
......@@ -93,4 +93,10 @@ content:
region: content
settings: { }
third_party_settings: { }
yearly_recurring_date:
type: yearly_recurring_date
weight: 7
region: content
settings: { }
third_party_settings: { }
hidden: { }
......@@ -51,3 +51,4 @@ hidden:
event_registration: true
monthly_recurring_date: true
weekly_recurring_date: true
yearly_recurring_date: true
......@@ -36,3 +36,4 @@ hidden:
monthly_recurring_date: true
recur_type: true
weekly_recurring_date: true
yearly_recurring_date: true
......@@ -7,8 +7,9 @@ days: 'monday,tuesday,wednesday,thursday,friday,saturday,sunday'
limit: 10
excludes: 1
includes: 1
enabled_fields: 'consecutive_recurring_date,daily_recurring_date,weekly_recurring_date,monthly_recurring_date,custom'
enabled_fields: 'consecutive_recurring_date,daily_recurring_date,weekly_recurring_date,monthly_recurring_date,yearly_recurring_date,custom'
threshold_warning: 1
threshold_count: 200
threshold_message: 'Saving this series will create up to @total event instances. This could result in memory exhaustion or site instability.'
threshold_prevent_save: 0
creator_plugin: recurring_events_eventinstance_recreator
......@@ -44,6 +44,9 @@ recurring_events.eventseries.config:
threshold_prevent_save:
type: integer
label: 'Prevent saving a series if too many instances are being created'
creator_plugin:
type: string
label: 'The creator plugin used when creating event instances'
recurring_events.eventinstance.config:
type: config_object
......
......@@ -2,8 +2,8 @@
* @file
* Javascript functionality for the recurring events create form.
*/
(function ($) {
/* eslint-disable */
(function ($, once) {
'use strict';
/**
......@@ -30,12 +30,12 @@
// Remove all the weekday recurrence options.
$('#edit-weekly-recurring-date-0-days').find('input').each(function (key, item) {
$(item).prop('checked', false);
$(item).prop('checked', FALSE);
});
// Set the event to recur on the same day of the week as the start
// date.
$('#edit-weekly-recurring-date-0-days-' + weekday).prop('checked', true);
$('#edit-weekly-recurring-date-0-days-' + weekday).prop('checked', TRUE);
}
});
......@@ -49,12 +49,12 @@
// Remove all the monthly recurrence options.
$('#edit-monthly-recurring-date-0-days').find('input').each(function (key, item) {
$(item).prop('checked', false);
$(item).prop('checked', FALSE);
});
// Set the event to recur on the same day of the week as the start
// date.
$('#edit-monthly-recurring-date-0-days-' + weekday).prop('checked', true);
$('#edit-monthly-recurring-date-0-days-' + weekday).prop('checked', TRUE);
}
});
}
......@@ -65,7 +65,7 @@
*/
Drupal.behaviors.recurring_events_excluded_included_dates = {
attach: function (context, settings) {
$('#edit-excluded-dates-wrapper, #edit-included-dates-wrapper').find('input.form-date').once().on('change', function (e) {
$(once('edit_excluded_date', $('#edit-excluded-dates-wrapper, #edit-included-dates-wrapper').find('input.form-date'))).on('change', function (e) {
if ($(this).attr('name').includes('[value][date]')) {
var start_date = this;
var parent = $(this).closest('.form-wrapper');
......@@ -81,4 +81,4 @@
}
};
}(jQuery));
}(jQuery, once));
......@@ -2,8 +2,8 @@
* @file
* Javascript functionality for the included/excluded date forms.
*/
(function ($) {
/* eslint-disable */
(function ($, once) {
'use strict';
/**
......@@ -12,7 +12,7 @@
Drupal.behaviors.recurring_events_excluded_included_config_dates = {
attach: function (context, settings) {
$('#edit-start').once().on('change', function (e) {
$(once('edit_recurring_events_excluded_included_config_dates', $('#edit-start'))).on('change', function (e) {
if ($('#edit-end').val() == '') {
$('#edit-end').val($(this).val());
}
......@@ -20,4 +20,4 @@
}
};
}(jQuery));
}(jQuery, once));
access group_recurring_events_series overview:
title: 'Access group recurring events series overview'
description: 'Access the overview of all group recurring events series, regardless of type'
name: 'Group recurring events'
description: 'Enables Group functionality for the Recurring events module'
package: 'Group'
type: 'module'
core_version_requirement: ^9.3 || ^10
dependencies:
- 'recurring_events:recurring_events'
- 'group:group'
<?php
/**
* @file
* Install, and update functions for group recurring events series module.
*/
group_content.group_recurring_events_series_relate_page:
route_name: 'entity.group_content.group_recurring_events_series_relate_page'
title: 'Add existing events'
appears_on:
- 'view.group_recurring_events_series.page_1'
group_content.group_recurring_events_series_add_page:
route_name: 'entity.group_content.group_recurring_events_series_add_page'
title: 'Add new events'
appears_on:
- 'view.group_recurring_events_series.page_1'
<?php
/**
* @file
* Enables Group functionality for the Recurring events module.
*/
use Drupal\Core\Entity\EntityInterface;
use Drupal\Core\Url;
use Drupal\recurring_events\Entity\EventSeriesTypeInterface;
/**
* Implements hook_ENTITY_TYPE_insert().
*/
function group_recurring_events_series_eventseries_type_insert(EventSeriesTypeInterface $eventseries_type) {
if (\Drupal::isConfigSyncing()) {
return;
}
\Drupal::service('plugin.manager.group_content_enabler')->clearCachedDefinitions();
}
/**
* Implements hook_entity_operation().
*/
function group_recurring_events_series_entity_operation(EntityInterface $entity) {
$operations = [];
if ($entity->getEntityTypeId() == 'group' && \Drupal::moduleHandler()->moduleExists('views')) {
/** @var \Drupal\group\Entity\GroupInterface $entity */
if ($entity->hasPermission('access group_recurring_events_series overview', \Drupal::currentUser())) {
/** @var \Symfony\Component\Routing\RouterInterface $router */
$router = \Drupal::service('router.no_access_checks');
if ($router->getRouteCollection()->get('view.group_recurring_events_series.page_1') !== NULL) {
$operations['recurring_events_series'] = [
'title' => t('Events series'),
'weight' => 20,
'url' => Url::fromRoute('view.group_recurring_events_series.page_1', ['group' => $entity->id()]),
];
}
}
}
return $operations;
}
/**
* Implements hook_entity_type_build().
*/
function group_recurring_events_series_entity_type_build(array &$entity_types) {
if (isset($entity_types['eventinstance'])) {
$entity_types['eventinstance']->setHandlerClass('access', 'Drupal\group_recurring_events_series\Access\GroupEventInstanceHandler');
}
}