Commit 98a3c4cd authored by Thomas Löffler's avatar Thomas Löffler

Merge branch 'develop' into 'master'

Release 10-09-20

See merge request !391
parents 6f33ae31 876f11e8
Pipeline #9590 passed with stages
in 10 minutes and 35 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.*
......@@ -2,6 +2,7 @@ include:
- project: 't3o/t3olayout'
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"
......@@ -20,6 +21,7 @@ stages:
- build
- layout
- deploy
- badges
- warmup
.deploy-template: &deploy_template
......@@ -58,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
This diff is collapsed.
<?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;
}
}
<?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,',
]
]
];
......@@ -11,6 +11,21 @@
<trans-unit id="tx_t3org_layout.events.importdate">
<source>Import event dates</source>
</trans-unit>
<trans-unit id="tx_t3org_layout.news.contributors.roles.0">
<source>Contributor</source>
</trans-unit>
<trans-unit id="tx_t3org_layout.news.contributors.roles.1">
<source>Reviewer</source>
</trans-unit>
<trans-unit id="tx_t3org_layout.news.contributors.roles.2">
<source>Copy Editor</source>
</trans-unit>
<trans-unit id="tx_t3org_layout.news.contributors.roles.3">
<source>Proofreader</source>
</trans-unit>
<trans-unit id="tx_t3org_layout.news.contributors.roles.4">
<source>Translator</source>
</trans-unit>
</body>
</file>
</xliff>
......@@ -2,7 +2,7 @@
# Table structure for table 'tx_sfeventmgt_domain_model_event'
#
CREATE TABLE tx_sfeventmgt_domain_model_event (
skills text,
skills text
);
#
......@@ -10,5 +10,15 @@ CREATE TABLE tx_sfeventmgt_domain_model_event (
#
CREATE TABLE tx_news_domain_model_news (
author_fe_user varchar(30) DEFAULT '' NOT NULL,
default_image varchar(30) DEFAULT '' NOT NULL
default_image varchar(30) DEFAULT '' NOT NULL,
contributors int DEFAULT 0
);
#
# Table structure for table 'tx_t3orglayout_domain_model_contributors'
#
CREATE TABLE tx_t3orglayout_domain_model_contributors (
author_fe_user varchar(30) DEFAULT '' NOT NULL,
role varchar(100) DEFAULT '' NOT NULL,
parent int(11) DEFAULT '0' NOT NULL
);
......@@ -63,7 +63,9 @@ return [
'enableFESSO' => '0',
'forceLowerCaseUsername' => '0',
'keepBEGroups' => '0',
'keepBESSODomainName' => '0',
'keepFEGroups' => '1',
'keepFESSODomainName' => '0',
'throwExceptionAtLogin' => '1',
'useExtConfConfiguration' => '0',
],
......@@ -88,6 +90,7 @@ return [
'rteForTeaser' => '0',
'showAdministrationModule' => '1',
'showImporter' => '0',
'slugBehaviour' => 'unique',
'storageUidImporter' => '1',
'tagPid' => '1',
],
......@@ -111,6 +114,7 @@ return [
'sf_event_mgt' => [
'enableInvoice' => '1',
'enableTransfer' => '1',
'slugBehaviour' => 'uniqueInSite',
],
'solr' => [
'allowLegacySiteMode' => '0',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment