Commit 3aa30495 authored by Marco Huber's avatar Marco Huber

Merge branch 'main' into 363-donation-record-creation-fails-2

parents f979039a 612d5fab
Pipeline #9727 passed with stages
in 5 minutes and 48 seconds
#ddev-generated: Automatically generated ddev .gitignore.
# You can remove the above line if you want to edit and maintain this file yourself.
/commands/*/*.example
/commands/*/README.txt
/commands/host/launch
/commands/web/xdebug
/commands/db/mysql
/homeadditions/*.example
/homeadditions/README.txt
/.gitignore
/import.yaml
/**/*.example
/.dbimageBuild
/.dbimageExtra
/.ddev-docker-compose-base.yaml
/.ddev-docker-compose-full.yaml
/db_snapshots
/sequelpro.spf
/import-db
/config.*.y*ml
/.webimageBuild
/.dbimageBuild
/.ddevlive-downloads
/.global_commands
/.homeadditions
/.sshimageBuild
/.webimageBuild
/.webimageExtra
/.dbimageExtra
/*-build/Dockerfile.example
/apache/apache-site.conf
/commands/.gitattributes
/commands/db/mysql
/commands/host/launch
/commands/web/live
/commands/web/xdebug
/config.*.y*ml
/db_snapshots
/import-db
/import.yaml
/nginx_full/nginx-site.conf
/sequelpro.spf
/**/README.*
......@@ -4,6 +4,5 @@
## Usage: build-frontend
## Example: "ddev build-frontend"
npm --prefix private/typo3conf/ext/t3olayout/Build install
npm --prefix private/typo3conf/ext/t3olayout/Build ci
npm --prefix private/typo3conf/ext/t3olayout/Build run-script build
rm -Rf private/typo3conf/ext/t3olayout/Build/node_modules
# EditorConfig is awesome: http://EditorConfig.org
# top-most EditorConfig file
root = true
# Unix-style newlines with a newline ending every file
[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
# CSS-Files
[*.css]
indent_style = tab
indent_size = 4
# HTML-Files
[*.html]
indent_style = tab
indent_size = 2
# TMPL-Files
[*.tmpl]
indent_style = tab
indent_size = 4
# SCSS-Files
[*.scss]
indent_style = space
indent_size = 4
# JS-Files
[*.js]
indent_style = space
indent_size = 2
# JSON-Files
[*.json]
indent_style = tab
indent_size = 4
# PHP-Files
[*.php]
indent_style = space
indent_size = 4
# ReST-Files
[*.rst]
indent_style = space
indent_size = 3
# MD-Files
[*.md]
indent_style = space
indent_size = 4
# YAML-Files
[{*.yaml,*.yml}]
indent_style = space
indent_size = 2
# package.json
# .travis.yml
# bower.json
[{package.json,.travis.yml,bower.json}]
indent_style = space
indent_size = 2
# TypoScript
[*.ts]
indent_style = space
indent_size = 2
[*.typoscript]
indent_style = space
indent_size = 2
[*.tsconfig]
indent_style = space
indent_size = 2
# XLF-Files
[*.xlf]
indent_style = tab
indent_size = 4
# SQL-Files
[*.sql]
indent_style = tab
indent_size = 2
\ No newline at end of file
include:
- project: 't3o/t3olayout'
ref: master
ref: main
file: '/Configuration/GitLab/t3o-builds.yml'
- remote: 'https://git.spooner.io/spooner-web/gitlab-anybadge-creator/-/raw/main/anybadges.yml'
variables:
GIT_STRATEGY: "none"
GIT_SSL_NO_VERIFY: "true"
STAGE_HOST: "typo3.dev"
PRODUCTION_HOST: "t3o03.typo3server.ch"
PRODUCTION_HOST: "typo3.org"
DUMP_USER: "t3o-stage"
STAGE_USER: "t3o-stage"
DUMP_EXCLUDE_TABLES_LIST: "be_groups,be_sessions,be_users,cf_cache_hash,cf_cache_hash_tags,cf_cache_imagesizes,cf_cache_imagesizes_tags,cf_cache_news_category,cf_cache_news_category_tags,cf_cache_pages,cf_cache_pages_tags,cf_cache_pagesection,cf_cache_pagesection_tags,cf_cache_rootline,cf_cache_rootline_tags,cf_extbase_datamapfactory_datamap,cf_extbase_datamapfactory_datamap_tags,cf_extbase_object,cf_extbase_object_tags,cf_extbase_reflection,cf_extbase_reflection_tags,cf_tx_solr,cf_tx_solr_configuration,cf_tx_solr_configuration_tags,cf_tx_solr_tags,fe_groups,fe_sessions,fe_users,sys_domain,sys_log,tx_solr_cache,tx_solr_cache_tags"
PHP_EXECUTABLE: "/opt/php/php72/bin/php"
ADDITIONAL_TABLE_EXCLUDES: "-e 'tx_certifications_*' -e 'tx_t3odonation_domain_model_donation' -e 'tx_t3omembership_domain_model_member' -e 'tx_randombanners_domain_model_banner'"
stages:
- maintenance
- test
- build
- layout
- deploy
- badges
- warmup
.deploy-template: &deploy_template
stage: deploy
image: composer:1
......@@ -50,3 +60,9 @@ deploy-develop:
url: https://${STAGE_HOST}
only:
- develop
"Create Badge":
stage: badges
script:
- last_master_deploy=$(git --no-pager log -1 --date=format:"%Y/%m/%d-%T" --format="%ad" origin/master)
- anybadge -l "Last Production Deployment" -v $last_master_deploy -f lastProductionDeployment.svg -c orange
master:
stage: master
hostname: t3o03.typo3server.ch
hostname: typo3.org
user: t3o-prod
writable_mode: chmod
forward_agent: true
......
......@@ -48,12 +48,14 @@
}
],
"require": {
"apache-solr-for-typo3/solr": "dev-master",
"apache-solr-for-typo3/solr": "^11.0",
"brotkrueml/typo3-matomo-widgets": "^0.1.0",
"cweagans/composer-patches": "^1.6",
"derhansen/sf_event_mgt": "^5.0",
"georgringer/news": "^8.0",
"gordalina/cachetool": "^4.0",
"reelworx/rx-shariff": "^13.0",
"spooner/deployer-information": "^1.1",
"t3g/hubspot-forms": "^1.1",
"t3o/certifications": "^3.0",
"t3o/randombanners": "^2.0",
......@@ -82,5 +84,8 @@
"cms-package-dir": "{$vendor-dir}/typo3/cms"
},
"enable-patching": true
},
"require-dev": {
"ichhabrecht/filefill": "^3.2"
}
}
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -40,7 +40,7 @@ routeEnhancers:
plugin: Pi1
routes:
-
routePath: '/{page}'
routePath: '/page-{page}'
_controller: 'News::list'
_arguments:
page: '@widget_0/currentPage'
......@@ -59,7 +59,7 @@ routeEnhancers:
_arguments:
category-name: overwriteDemand/categories
-
routePath: '/{category-name}/{page}'
routePath: '/{category-name}/page-{page}'
_controller: 'News::list'
_arguments:
category-name: overwriteDemand/categories
......@@ -129,15 +129,16 @@ routeEnhancers:
type: StaticRangeMapper
start: '1'
end: '100'
PageTypeSuffix:
type: PageType
map:
sitemap.xml: 1533906435
yoast-snippetpreview.json: 1480321830
routes:
-
route: robots.txt
type: staticText
content: "User-agent: *\r\nAllow: /\r\n\r\n# folders\r\nDisallow: /typo3/\r\nDisallow: /typo3conf/\r\nAllow: /typo3conf/ext/\r\nAllow: /typo3temp/\r\n\r\n# parameters\r\nDisallow: /*?id=* # non speaking URLs\r\nDisallow: /*cHash # no cHash\r\nDisallow: /*tx_powermail_pi1 # no powermail thanks pages\r\nDisallow: /*tx_form_formframework # no forms\r\n\r\n# sitemap\r\nSitemap: https://typo3.org/?type=1533906435\r\n"
-
route: sitemap.xml
type: uri
source: 'https://typo3.org/?type=1533906435'
solr_enabled_read: true
solr_host_read: solr
solr_path_read: /solr/
......
......@@ -220,6 +220,7 @@ return [
'type' => 'input',
'size' => '30',
'eval' => 'datetime',
'renderType' => 'inputDateTime',
]
],
'crdate' => [
......
<?php
namespace T3o\T3orgLayout\Domain\Model;
/*
* This file is part of the TYPO3 project.
*
* It is free software; you can redistribute it and/or modify it under
* the terms of the GNU Lesser General Public License, either version 3
* of the License, or (at your option) any later version.
*
* For the full copyright and license information, please read the LICENSE
* file that was distributed with this source code.
*
* The TYPO3 project - inspiring people to share!
*/
/**
* Class News
*/
class Contributors extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity
{
/**
* @var string
*/
protected $role;
/**
* @var int
*/
protected $parent;
/**
* @var string
*/
protected $authorFeUser;
/**
* @return \TYPO3\CMS\Extbase\Domain\Model\FrontendUser|null
*/
public function getAuthorFeUser()
{
if (!$this->authorFeUser) {
return null;
}
$objectManager = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Extbase\Object\ObjectManager::class);
$querySettings = $objectManager->get(\TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::class);
$querySettings->setRespectStoragePage(false);
$userRepository = $objectManager->get(\TYPO3\CMS\Extbase\Domain\Repository\FrontendUserRepository::class);
$userRepository->setDefaultQuerySettings($querySettings);
return $userRepository->findOneByUsername($this->authorFeUser);
}
/**
* @param string $authorFeUser
*/
public function setAuthorFeUser(string $authorFeUser)
{
$this->authorFeUser = $authorFeUser;
}
public function getRole(): string
{
return $this->role;
}
public function setRole(string $role)
{
$this->role = $role;
}
public function getParent(): int
{
return $this->parent;
}
public function setParent(int $parent)
{
$this->parent = $parent;
}
}
......@@ -25,6 +25,11 @@ class News extends \GeorgRinger\News\Domain\Model\News
*/
protected $authorFeUser;
/**
* @var \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\T3o\T3orgLayout\Domain\Model\Contributors>
*/
protected $contributors;
/**
* @var string
*/
......@@ -64,4 +69,19 @@ class News extends \GeorgRinger\News\Domain\Model\News
return $userRepository->findOneByUsername($this->authorFeUser);
}
/**
* Sets the contributors
*
* @param \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\T3o\T3orgLayout\Domain\Model\Contributors> $contributors
*/
public function setContributors($contributors): void
{
$this->contributors = $contributors;
}
public function getContributors(): \TYPO3\CMS\Extbase\Persistence\ObjectStorage
{
return $this->contributors;
}
}
......@@ -107,7 +107,7 @@ class DataHandlerHook
{
$slug = $params['slug'];
if ($params['record']['startdate']) {
$slug = date('Ymd', strtotime($params['record']['startdate'])) . '-' . $params['record']['title'];
$slug = date('Ymd', strtotime($params['record']['startdate'])) . '-' . str_replace('/', '-', $params['record']['title']);
}
return $slug;
......
tx_sfeventmgt.templateLayouts {
1 = Latest view
2 = List view, no category selector
3 = List view, nothing more
}
<?php
$GLOBALS['TCA']['tx_news_domain_model_news']['columns']['author_fe_user'] = [
'exclude' => '0',
'exclude' => 0,
'label' => 'Select fe user',
'config' => [
'type' => 'select',
......@@ -13,6 +13,29 @@ $GLOBALS['TCA']['tx_news_domain_model_news']['columns']['author_fe_user'] = [
]
];
$GLOBALS['TCA']['tx_news_domain_model_news']['columns']['contributors'] = [
'exclude' => 0,
'label' => 'Select contributors for this article',
'config' => [
'type' => 'inline',
'foreign_table' => 'tx_t3orglayout_domain_model_contributors',
'foreign_field' => 'parent',
'foreign_sortby' => 'sorting',
'size' => 5,
'minitems' => 0,
'maxitems' => 10,
'appearance' => [
'collapseAll' => true,
'expandSingle' => true,
'levelLinksPosition' => 'bottom',
'useSortable' => true,
'enabledControls' => [
'info' => false,
]
],
]
];
$GLOBALS['TCA']['tx_news_domain_model_news']['columns']['default_image'] = [
'exclude' => 0,
'label' => 'Default Image',
......@@ -93,3 +116,10 @@ $GLOBALS['TCA']['tx_news_domain_model_news']['types']['0']['columnsOverrides'] =
'',
'before:author'
);
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addToAllTCAtypes(
'tx_news_domain_model_news',
'contributors',
'',
'before:author'
);
<?php
use T3o\T3orgLayout\TCA\TcaProcFunc;
defined('TYPO3_MODE') or die();
return [
'ctrl' => [
'title' => 'tx_news_domain_model_contributors',
'label' => 'author_fe_user',
'label_alt' => 'role',
'label_alt_force' => true,
'tstamp' => 'tstamp',
'crdate' => 'crdate',
'cruser_id' => 'cruser_id',
'default_sortby' => 'ORDER BY sorting',
'sortby' => 'sorting',
'delete' => 'deleted',
'enablecolumns' => [
'disabled' => 'hidden',
],
'hideTable' => true,
],
'interface' => [
'showRecordFieldList' => 'hidden,role,author_fe_user'
],
'columns' => [
'pid' => [
'label' => 'pid',
'config' => [
'type' => 'passthrough'
]
],
'crdate' => [
'label' => 'crdate',
'config' => [
'type' => 'input',
'renderType' => 'inputDateTime',
'eval' => 'datetime',
]
],
'tstamp' => [
'label' => 'tstamp',
'config' => [
'type' => 'input',
'renderType' => 'inputDateTime',
'eval' => 'datetime',
]
],
'hidden' => [
'exclude' => true,
'label' => 'LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.hidden',
'config' => [
'type' => 'check',
'default' => 0
]
],
'role' => [
'exclude' => false,
'label' => 'Role',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'items' => [
['Please select a role', 0],
['Reviewer', 1],
['Copy Editor', 2],
['Proofreader', 3],
['Translator', 4],
]
],
],
'author_fe_user' => [
'exclude' => '0',
'label' => 'Select fe user',
'config' => [
'type' => 'select',
'minitems' => 0,
'maxitems' => 1,
'renderType' => 'selectMultipleSideBySide',
'enableMultiSelectFilterTextfield' => true,
'itemsProcFunc' => TcaProcFunc::class . '->feUserItems',
]
],
],
'types' => [
0 => [
'showitem' => 'role,author_fe_user, --palette--;;paletteCore'
]
],
'palettes' => [
'paletteCore' => [
'showitem' => 'hidden,sys_language_uid,l10n_parent, l10n_diffsource,',
]
]
];
......@@ -74,7 +74,7 @@ config {
disablePrefixComment = 1
metaCharset = utf-8
additionalHeaders.5 {
header = Content-Type:application/rss+xml;charset=utf-8
header = Content-Type:application/xml;charset=utf-8
replace = 1
}
absRefPrefix = {$plugin.tx_news.rss.channel.link}
......@@ -129,7 +129,7 @@ config {
disablePrefixComment = 1
metaCharset = utf-8
additionalHeaders.5 {
header = Content-Type:application/rss+xml;charset=utf-8
header = Content-Type:application/xml;charset=utf-8
replace = 1
}
absRefPrefix = {$plugin.tx_news.rss.channel.link}
......@@ -184,7 +184,7 @@ config {
disablePrefixComment = 1
metaCharset = utf-8
additionalHeaders.5 {
header = Content-Type:application/rss+xml;charset=utf-8
header = Content-Type:application/xml;charset=utf-8
replace = 1
}
absRefPrefix = {$plugin.tx_news.rss.channel.link}
......
@import 'EXT:seo/Configuration/TypoScript/XmlSitemap'
@import 'EXT:news/Configuration/TypoScript/Sitemap'
plugin.tx_seo {
config {
xmlSitemap {
sitemaps {
pages {
config {
excludedDoktypes = 3, 4, 5, 6, 7, 199, 254, 255
additionalWhere = AND (no_index = 0)
}
}
news {
provider = TYPO3\CMS\Seo\XmlSitemap\RecordsXmlSitemapDataProvider
config {
table = tx_news_domain_model_news
additionalWhere =
sortField = sorting
lastModifiedField = tstamp
pid = 179
recursive = 2
url {
pageId = 185
fieldToParameterMap {
uid = tx_news_pi1[news]
}
additionalGetParameters {
tx_news_pi1 {
controller = News
action = detail
}
}
useCacheHash = 1
}
}
}
events {
provider = TYPO3\CMS\Seo\XmlSitemap\RecordsXmlSitemapDataProvider
config {
table = tx_sfeventmgt_domain_model_event
sortField = tstamp
lastModifiedField = tstamp
pid = 180,43,461
recursive = 2
url {
pageId = 230
fieldToParameterMap {
uid = tx_sfeventmgt_pievent[event]
}
additionalGetParameters {
tx_sfeventmgt_pievent {
controller = Event
action = detail
}