From 45e1436676165c707d233457a5a6bf0fad50cb18 Mon Sep 17 00:00:00 2001
From: s j <sj@1729.be>
Date: Mon, 25 Sep 2023 09:47:56 +0200
Subject: [PATCH 1/3] imp: shareholder extract with twig filter

---
 ..._template.template.shareholder_extract.yml | 29 ++++++++++++-------
 1 file changed, 19 insertions(+), 10 deletions(-)

diff --git a/config/optional/mail_template.template.shareholder_extract.yml b/config/optional/mail_template.template.shareholder_extract.yml
index 8898203..8fac650 100644
--- a/config/optional/mail_template.template.shareholder_extract.yml
+++ b/config/optional/mail_template.template.shareholder_extract.yml
@@ -6,6 +6,14 @@ label: shareholder_extract
 type: pdf
 applicable_entity_type: ''
 mail_key: mail_shareholder_extract
+pdf_options: |
+  margin-top: 2cm
+  margin-bottom: 2cm
+  margin-left: 1cm
+  margin-right: 1cm
+subject: ''
+cc: ''
+bcc: ''
 template:
   value: |
     <header>
@@ -135,7 +143,10 @@ template:
           <th>Transactie</th>
           <th>Aantal</th>
           <th>Serienummer</th>
+          <th>Aandeel type</th>
+          <th>Uitgifte</th>
           <th>Nominale waarde</th>
+          <th>Uitgiftepremie</th>
           <th>Totaal</th>
         </tr>
       </thead>
@@ -146,8 +157,11 @@ template:
           <td> {{ transaction.getName() }} </td>
           <td> {{ transaction.quantity.0.value }} </td>
           <td> {{ transaction.getFormattedShareNames() }}</td>
-          <td>EUR {{ transaction.share_type_id.0.entity.par_value.value }} </td>
-          <td>EUR {{ transaction.getTotalValue() }} </td>
+          <td> {{ transaction | share_types }} </td>
+          <td> {{ transaction | share_issues }} </td>
+          <td> {{ transaction | share_nominal_values }} </td>
+          <td> {{ transaction | share_issue_premiums }} </td>
+          <td>EUR {{ transaction.getShareTotalValue() }} </td>
         </tr>
         {% endfor %}
       </tbody>
@@ -200,13 +214,8 @@ template:
       </tbody>
     </table>
     {% endif %}
+
+    </main>
   format: code
 theme_name: ''
-subject: ''
-cc: ''
-bcc: ''
-pdf_options: |
-  margin-top: 2cm
-  margin-bottom: 2cm
-  margin-left: 1cm
-  margin-right: 1cm
+
-- 
GitLab


From 5832da7aa224367cb680fb9d76472eb5d2a672c7 Mon Sep 17 00:00:00 2001
From: s j <sj@1729.be>
Date: Thu, 23 May 2024 06:36:49 +0200
Subject: [PATCH 2/3] fix: 1.x gitlabci

---
 .gitlab-ci.yml                                | 192 +++---------------
 ...ds-cause-schema-exception-2976616-11.patch |  36 ----
 .gitlab-ci/build.php                          |  99 ---------
 .gitlab-ci/webform_views-schema.patch         |  26 ---
 composer.json                                 |  10 +-
 5 files changed, 31 insertions(+), 332 deletions(-)
 delete mode 100644 .gitlab-ci/aggregated-entity-fields-cause-schema-exception-2976616-11.patch
 delete mode 100644 .gitlab-ci/build.php
 delete mode 100644 .gitlab-ci/webform_views-schema.patch

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index cb16b70..7cb36d1 100755
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -1,168 +1,30 @@
-################################################################################
-# Gitlab CI integration for Drupal 8/9 project or module: tests, code quality,
-# linting, metrics and deploy samples.
+################
+# GitLabCI template for Drupal projects.
 #
-# Project: https://gitlab.com/mog33/gitlab-ci-drupal
-# Documentation: https://mog33.gitlab.io/gitlab-ci-drupal
-# Issues: https://gitlab.com/mog33/gitlab-ci-drupal/-/issues
-# Author: Jean Valverde contact@dev-drupal.com
-# License: GPL-3
-#
-# If you want to support this project, you can
-# - Buy me a coffee: https://bit.ly/34jPKcE
-# - Hire me as a freelance for any Drupal related work
-# - Promote me to any company looking for any Drupal related work
-# - Help me with testing / documentation / grammar fixes / use cases...
-#
-################################################################################
-
-# The ref is relative to the version of the project to use.
+# 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:
-  # If hosted on gitlab.com.
-  # - project: 'mog33/gitlab-ci-drupal'
-  #   ref: 3.x-dev
-  #   file: '/.gitlab-ci/.gitlab-ci-template.yml'
-  # If hosted on an other Gitlab instance.
-  # - remote: 'https://gitlab.com/mog33/gitlab-ci-drupal/-/raw/3.x-dev/.gitlab-ci/.gitlab-ci-template.yml'
-  - remote: 'https://git.startx.be/forks/gitlab-ci-drupal/-/raw/startx/.gitlab-ci/.gitlab-ci-template.yml'
-
-# If needed by your Gitlab-ci instance, you can set global tags for all jobs.
-# default:
-#   tags:
-#     - docker
-
-################################################################################
-# Gitlab-CI variables documentation:
-# https://docs.gitlab.com/ee/ci/variables/
-#
-# Variables, can be set here or on
-#   Gitlab CI UI > settings > CI/CD > variables
-# UI take precedence on variables here.
-# https://docs.gitlab.com/ee/ci/variables/README.html#priority-of-environment-variables
-################################################################################
-
+  - project: 'forks/gitlab_templates'
+    ref: 'startx'
+    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
+# Uncomment the lines below if you want to override any of the variables. The following is just an example.
+################
 variables:
-  # This is mandatory to get default variables.
-  extends: .default_variables
-
-  # Global config remote files ref.
-  # SHOULD be the same as 'include: ref:' from above.
-  CI_REF: 3.x-dev
-
-  # Minor Drupal version to work with, limited to tags on
-  # https://hub.docker.com/r/mogtofu33/drupal8ci/tags?name=3.x
-  # CI_DRUPAL_VERSION: "9.2"
-
-  ##############################################################################
-  # Tests disabled by default because need a specific setup / configuration.
-  #
-  # Only needed if you have Behat tests, comment or set to 0 to enable.
-  # https://mog33.gitlab.io/gitlab-ci-drupal/advanced-usage/#behat-tests
-  SKIP_TEST_BEHAT: 1
-  # Can use a profile setup or a dump file in dump/
-  BEHAT_INSTALL_PROFILE: "minimal"
-
-  # Accessibility tests.
-  # https://mog33.gitlab.io/gitlab-ci-drupal/advanced-usage/#accessibility-with-pa11y
-  SKIP_TEST_PA11Y: 1
-  # Can use a profile setup or a dump file in dump/
-  PA11Y_INSTALL_PROFILE: "minimal"
-
-  # Only if you have Nightwatch tests in your code.
-  # https://mog33.gitlab.io/gitlab-ci-drupal/advanced-usage/#nightwatchjs
-  SKIP_TEST_NIGHTWATCH: 1
-  # Default is '--skiptags core', add your tag.
-  # NIGHTWATCH_TESTS: --tag my_module
-
-  # Phpunit tests to run, default provide only custom code or if this variable
-  # is empty all tests (including Drupal core).
-  # https://mog33.gitlab.io/gitlab-ci-drupal/advanced-usage/#phpunit-tests
-  PHPUNIT_TESTS: "custom"
-
-  # Specify a group of tests to run rather than all tests in the suite.
-  # PHPUNIT_GROUP: my_group_1,my_group_2
-
-  ##############################################################################
-  # Override default variables for a module.
-  #
-  # Default CI setup is for a 'project' (full Drupal with a composer.json), next
-  # section contains common variables to change for a module (module, theme or
-  # profile). Simply uncomment and adapt dirs to set the CI for a module.
-  #
-  CI_TYPE: module
-  # Code quality dirs, must include your PHP code to check.
-  # Phpstan need autoloading, that's why we use web_root.
-  DIRS_QA: "${WEB_ROOT}/modules/custom"
-  # Eslint / Stylelint files to test.
-  DIRS_JS: "${CI_PROJECT_DIR}/js/*.js"
-  DIRS_CSS: "${CI_PROJECT_DIR}/css/*.css"
-  # Twig files to test.
-  DIRS_TWIG: "${CI_PROJECT_DIR}/templates"
-  # phpmetrics / phpstats dirs to include.
-  DIRS_PHP: "${CI_PROJECT_DIR}"
-  # Set SKIP_XXX variable to 1 to skip.
-  # Security is for a Drupal project with third party.
-  SKIP_TEST_SECURITY: 1
-  # If you don't have any css files, you can skip with
-  SKIP_LINT_CSS: 1
-  # If you don't have any javascript files, you can skip with
-  SKIP_LINT_JS: 1
-  # If you don't have any twig files, you can skip with
-  SKIP_LINT_TWIG: 1
-  #
-  ##############################################################################
-
-  ##############################################################################
-  # As a sample here is a list of some variables, see documentation for more
-  # variables.
-  #
-  # List of DIRS_* variables to define dirs to analyse for specific jobs.
-  # Code quality dirs, must include your PHP code to check.
-  #
-  # DIRS_QA: "${WEB_ROOT}/modules/custom,${WEB_ROOT}/themes/custom"
-  #
-  # Eslint / Stylelint files to test.
-  # Space separated for multiple folders.
-  # Default is to check files under all custom folders.
-  #
-  # DIRS_JS: "${WEB_ROOT}/**/custom/**/*.js"
-  # DIRS_CSS: "${WEB_ROOT}/**/custom/**/css/*.css"
-  #
-  # Twig files to test, recursive.
-  #
-  # DIRS_TWIG: "${WEB_ROOT}/themes/custom"
-  #
-  # Phpmetrics / Phpstats dirs to include.
-  # Default is to check all dirs.
-  #
-  # DIRS_PHP: "${WEB_ROOT}/modules/custom,${WEB_ROOT}/themes/custom"
-  #
-  # # ALL SKIP variables, uncomment and set to 1 to skip a job.
-  # SKIP_BUILD: 1 # if not running any tests or deploy.
-  #
-  # SKIP_TESTS: 1 # Skip all tests, ignore SKIP_TEST_*.
-  # SKIP_TEST_UNITKERNEL: 1
-  # SKIP_TEST_FUNCTIONAL: 1
-  # SKIP_TEST_FUNCTIONALJS: 1
-  # SKIP_TEST_SECURITY: 1
-  #
-  # SKIP_QA: 1
-  #
-  # SKIP_LINT: 1 # Skip all lint, ignore SKIP_LINT_*.
-  # SKIP_LINT_CSS: 1
-  # SKIP_LINT_JS: 1
-  # SKIP_LINT_TWIG: 1
-  #
-  # SKIP_METRICS: 1
-
-  # QA and Metrics tools.
-  # See Phpqa available tools: https://github.com/EdgedesignCZ/phpqa#available-tools
-  # ':0' is the number of errors allowed, default here is very strict.
-  #
-  # TOOLS_QA: "phpcs:0,phpmd:0,parallel-lint:0,phpstan:0,phpcpd:0"
-  # TOOLS_METRICS: "phpmetrics,phploc,pdepend"
-
-################################################################################
-# Advanced usage with this file, see doc.
-# https://mog33.gitlab.io/gitlab-ci-drupal/advanced-usage
-################################################################################
+  _TARGET_CORE: "9.5"
+#   _CURL_TEMPLATES_REF: 'startx'
+#   SKIP_ESLINT: '1'
+#   OPT_IN_TEST_NEXT_MAJOR: '1'
diff --git a/.gitlab-ci/aggregated-entity-fields-cause-schema-exception-2976616-11.patch b/.gitlab-ci/aggregated-entity-fields-cause-schema-exception-2976616-11.patch
deleted file mode 100644
index d9a407e..0000000
--- a/.gitlab-ci/aggregated-entity-fields-cause-schema-exception-2976616-11.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-diff --git a/core/modules/views/config/schema/views.data_types.schema.yml b/core/modules/views/config/schema/views.data_types.schema.yml
-index 708e12f..bb5c107 100644
---- a/core/modules/views/config/schema/views.data_types.schema.yml
-+++ b/core/modules/views/config/schema/views.data_types.schema.yml
-@@ -574,6 +574,31 @@ views_field:
-     plugin_id:
-       type: string
-       label: 'Plugin ID'
-+    # In case of using aggregation, field has numeric settings.
-+    set_precision:
-+      type: boolean
-+      label: 'Round'
-+    precision:
-+      type: integer
-+      label: 'Precision'
-+    decimal:
-+      type: string
-+      label: 'Decimal point'
-+    separator:
-+      type: string
-+      label: 'Thousands marker'
-+    format_plural:
-+      type: boolean
-+      label: 'Format plural'
-+    format_plural_string:
-+      type: plural_label
-+      label: 'Plural variants'
-+    prefix:
-+      type: label
-+      label: 'Prefix'
-+    suffix:
-+      type: label
-+      label: 'Suffix'
- 
- views_pager:
-   type: mapping
diff --git a/.gitlab-ci/build.php b/.gitlab-ci/build.php
deleted file mode 100644
index e9a7179..0000000
--- a/.gitlab-ci/build.php
+++ /dev/null
@@ -1,99 +0,0 @@
-<?php
-
-/**
- * @file
- * You can use this file to run extra Robo build tasks.
- *
- * See RoboFile.php and https://robo.li/ documentation to run a task.
- *
- * For CI_TYPE='project', this file is executed directly during the Build job
- * script after the regular composer install.
- *
- * For CI_TYPE='module', this file is executed on each 'before_script' part of
- * jobs.
- *
- * It's important to have any action relative to the docRoot or webRoot as
- * we are not working from the CI_PROJECT_DIR.
- *
- * Examples:
- *
- * $this->say("This will be run in Build script!");
- *
- * $this->taskGulpRun()
- *   ->dir($this->webRoot . 'themes/my_theme_with_gulp_task')
- *   ->run();
- *
- * $this->taskComposerRequire()
- *   ->noInteraction()
- *   ->noAnsi()
- *   ->workingDir($this->docRoot);
- *   ->dependency('drupal/webform', '^5.13')
- *   ->run();
- *
- * Or shortcut method in the RoboFile.php with this project:
- * $this->composerRequire()
- *  ->dependency('drupal/webform', '^5.13')
- *  ->run();
- */
-
-$this->taskComposerConfig()
-  ->noInteraction()
-  ->noAnsi()
-  ->workingDir($this->docRoot)
-  ->repository("1", "https://packages.startx.be", "composer")
-  ->run();
-
-$this->taskComposerConfig()
-  ->noInteraction()
-  ->noAnsi()
-  ->workingDir($this->docRoot)
-  ->repository("0", "https://packages.drupal.org/8", "composer")
-  ->run();
-
-$this->taskComposerConfig()
-  ->noInteraction()
-  ->noAnsi()
-  ->workingDir($this->docRoot)
-  ->args(["minimum-stability", "dev"])
-  ->run();
-
-$repo = <<<EOT
-{
-  "type": "package",
-  "package": {
-    "name": "google/charts",
-    "version": "45",
-    "type": "drupal-library",
-    "extra": {
-      "installer-name": "google_charts"
-    },
-    "dist": {
-      "url": "https://www.gstatic.com/charts/loader.js",
-      "type": "file"
-    },
-    "require": {
-      "composer/installers": "~1.0"
-    }
-  }
-}
-EOT;
-
-$this->_exec("composer config --working-dir {$this->docRoot} repositories.100 '{$repo}' --no-interaction --no-ansi");
-
-$this->composerRequire()
-  ->dependency("drupal/dsr", "^1.0.21")
-  ->dependency("drupal/dsr_portal", "^1.0")
-  ->dependency("drupal/swiftmailer", "^2.2")
-  ->dependency("drupal/telephone_international_widget", "^2.0")
-  ->dependency("drupal/telephone_validation", "^2.0")
-  ->dependency("drupal/twig_tweak", "^2.0")
-  ->dependency("drupal/webform_rrn_nrn", "^2.2")
-  ->dependency("drupal/field_rrn_nrn", "^1.0")
-  // FIXME: temoporary, until stable release
-  ->dependency("drupal/accounting", "^1.0.11")
-  ->dependency("drupal/banking_orders_accounting", "^1.0.3")
-  ->run();
-
-$this->_exec("cat /builds/DAR/dsr_demo/.gitlab-ci/webform_views-schema.patch | patch -p 1 -d {$this->webRoot}/modules/contrib/webform_views/");
-$this->_exec("cat /builds/DAR/dsr_demo/.gitlab-ci/aggregated-entity-fields-cause-schema-exception-2976616-11.patch | patch -p 1 -d {$this->webRoot}/");
-$this->_exec("curl -fsSL https://www.drupal.org/files/issues/2021-12-02/2429699-453-9.3.x.patch | patch -p 1 -d {$this->webRoot}");
diff --git a/.gitlab-ci/webform_views-schema.patch b/.gitlab-ci/webform_views-schema.patch
deleted file mode 100644
index e6a66cf..0000000
--- a/.gitlab-ci/webform_views-schema.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-diff --git a/config/schema/webform_views.schema.yml b/config/schema/webform_views.schema.yml
-index 4d5a84d..462f742 100644
---- a/config/schema/webform_views.schema.yml
-+++ b/config/schema/webform_views.schema.yml
-@@ -13,6 +13,21 @@ views.field.webform_submission_field:
-       type: integer
-       label: 'Delta to use'
- 
-+# Schema definition for webform submission composite field.
-+views.field.webform_submission_composite_field:
-+  type: views.field.webform_submission_field
-+  label: 'Webform submission composite field'
-+  mapping:
-+    webform_element_format:
-+      type: string
-+      label: 'Format'
-+    webform_multiple_value:
-+      type: boolean
-+      label: 'Whether to show all multiple values in a single field'
-+    webform_multiple_delta:
-+      type: integer
-+      label: 'Delta to use'
-+
- # Schema definition for select filter.
- views.filter.webform_submission_select_filter:
-   type: views.filter.in_operator
diff --git a/composer.json b/composer.json
index 83d6d5d..8b25957 100644
--- a/composer.json
+++ b/composer.json
@@ -11,6 +11,10 @@
     "source": "http://cgit.drupalcode.org/dsr_demo"
   },
   "repositories": [
+    {
+      "type": "composer",
+      "url": "https://packages.startx.be"
+    },
     {
       "type": "package",
       "package": {
@@ -31,7 +35,6 @@
     }
   ],
   "require": {
-    "cweagans/composer-patches": "^1.7",
     "drupal/dsr_portal": "^1.0",
     "drupal/dsr": "^2.0",
     "drupal/field_rrn_nrn": "^1.0",
@@ -47,11 +50,6 @@
       "services": {
         "drush.services.yml": "^9"
       }
-    },
-    "patches": {
-      "drupal/telephone_international_widget": {
-        "multiple_fields": "https://git.startx.be/modules/drupal-patches/-/raw/main/telephone_international_widget-multiple_fields.patch"
-      }
     }
   }
 }
-- 
GitLab


From aad0ccac38541d360eb31b1a9b5f4c3938efe9ca Mon Sep 17 00:00:00 2001
From: s j <sj@1729.be>
Date: Tue, 28 May 2024 12:55:24 +0200
Subject: [PATCH 3/3] tmp

---
 composer.json | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/composer.json b/composer.json
index 8b25957..1de0b9f 100644
--- a/composer.json
+++ b/composer.json
@@ -35,6 +35,7 @@
     }
   ],
   "require": {
+    "cweagans/composer-patches": "^1.7",
     "drupal/dsr_portal": "^1.0",
     "drupal/dsr": "^2.0",
     "drupal/field_rrn_nrn": "^1.0",
@@ -46,9 +47,12 @@
     "giggsey/libphonenumber-for-php": "^8.0"
   },
   "extra": {
-    "drush": {
-      "services": {
-        "drush.services.yml": "^9"
+    "patches": {
+      "drupal/core": {
+        "entity_reference_views_exposed_filter": "https://www.drupal.org/files/issues/2021-12-02/2429699-453-9.3.x.patch"
+      },
+      "drupal/webform_views": {
+        "webform_views-schema": "https://git.startx.be/modules/drupal-patches/-/raw/main/webform_views-schema.patch"
       }
     }
   }
-- 
GitLab