Zwischenstand

This commit is contained in:
Sven Wappler
2021-08-20 13:33:13 +02:00
parent ce6b9e38dc
commit 508d3d2759
32 changed files with 2807 additions and 602 deletions

View File

View File

@@ -12,4 +12,4 @@ defined('TYPO3') || die('Access denied.');
/**
* add TypoScript to template record
*/
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addStaticFile('bookmarks_likes_ratings', 'Configuration/TypoScript/', 'Bookmark Pages');
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addStaticFile('bookmarks_likes_ratings', 'Configuration/TypoScript/', 'Bookmarks/Likes/Pages');

View File

@@ -1,12 +1,4 @@
<?php
/*
* This file is part of the package buepro/bookmark_pages.
*
* For the full copyright and license information, please read the
* LICENSE file that was distributed with this source code.
*/
defined('TYPO3') || die('Access denied.');
(function () {
@@ -17,12 +9,18 @@ defined('TYPO3') || die('Access denied.');
'Bookmark Pages'
);
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerPlugin(
'BookmarksLikesRatings',
'PersonalBookmarks',
'Personal bookmarks of a user'
);
$GLOBALS['TCA']['tt_content']['types']['list']['subtypes_addlist']['bookmarkpages_bookmarks'] = 'pi_flexform';
$GLOBALS['TCA']['tt_content']['types']['list']['subtypes_addlist']['bookmarkslikesratings_bookmarks'] = 'pi_flexform';
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPiFlexFormValue(
'bookmarkpages_bookmarks',
'bookmarkslikesratings_bookmarks',
'FILE:EXT:bookmarks_likes_ratings/Configuration/FlexForms/Bookmarks.xml'
);
$GLOBALS['TCA']['tt_content']['types']['list']['subtypes_excludelist']['bookmarkpages_bookmarks'] = 'recursive,select_key,pages';
$GLOBALS['TCA']['tt_content']['types']['list']['subtypes_excludelist']['bookmarkslikesratings_bookmarks'] = 'recursive,select_key,pages';
})();

View File

@@ -0,0 +1,97 @@
<?php
return [
'ctrl' => [
'title' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.bookmark.title',
'label' => 'uid',
'label_alt' => 'rating,fe_user,vote',
'label_userFunc' => 'WapplerSystems\\BookmarksLikesRatings\\Userfuncs\\Tca->getVoteRecordTitle',
'tstamp' => 'tstamp',
'crdate' => 'crdate',
'cruser_id' => 'cruser_id',
'adminOnly' => true,
'hideTable' => true,
'editlock' => 'rating',
'enablecolumns' => [
'disabled' => 'hidden',
],
'iconfile' => 'EXT:bookmarks_likes_ratings/Resources/Public/Icons/tx_bookmarkslikesratings_domain_model_vote.gif',
],
'interface' => [
'showRecordFieldList' => 'hidden, rating, user, vote',
],
'columns' => [
'pid' => [
'exclude' => 1,
'config' => [
'type' => 'none',
],
],
'hidden' => [
'exclude' => 1,
'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_general.xlf:LGL.hidden',
'config' => [
'type' => 'check',
],
],
'tablename' => [
'exclude' => 1,
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.tablename',
'config' => [
'type' => 'input',
],
],
'object_uid' => [
'exclude' => 1,
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.object_uid',
'config' => [
'type' => 'input',
],
],
'user' => [
'exclude' => 1,
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.user',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'foreign_table' => 'fe_users',
'foreign_table_where' => 'ORDER BY fe_users.username',
'items' => [
[
'--div--', 0
],
],
'fieldControl' => [
'editPopup' => [
'disabled' => false,
],
'addRecord' => [
'disabled' => false,
'options' => [
'setValue' => 'prepend',
],
'listModule' => [
'disabled' => false,
],
],
],
],
],
'uid' => [
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.uid',
'config' => [
'type' => 'none'
],
],
],
'types' => [
'1' => [
'showitem' => 'hidden, rating, user, vote'
],
],
'palettes' => [
'1' => [
'showitem' => ''
],
],
];

View File

@@ -0,0 +1,97 @@
<?php
return [
'ctrl' => [
'title' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.like.title',
'label' => 'uid',
'label_alt' => 'rating,fe_user,vote',
'label_userFunc' => 'WapplerSystems\\BookmarksLikesRatings\\Userfuncs\\Tca->getVoteRecordTitle',
'tstamp' => 'tstamp',
'crdate' => 'crdate',
'cruser_id' => 'cruser_id',
'adminOnly' => true,
'hideTable' => true,
'editlock' => 'rating',
'enablecolumns' => [
'disabled' => 'hidden',
],
'iconfile' => 'EXT:bookmarks_likes_ratings/Resources/Public/Icons/tx_bookmarkslikesratings_domain_model_vote.gif',
],
'interface' => [
'showRecordFieldList' => 'hidden, rating, voter, vote',
],
'columns' => [
'pid' => [
'exclude' => 1,
'config' => [
'type' => 'none',
],
],
'hidden' => [
'exclude' => 1,
'label' => 'LLL:EXT:lang/Resources/Private/Language/locallang_general.xlf:LGL.hidden',
'config' => [
'type' => 'check',
],
],
'tablename' => [
'exclude' => 1,
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.tablename',
'config' => [
'type' => 'input',
],
],
'object_uid' => [
'exclude' => 1,
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.object_uid',
'config' => [
'type' => 'input',
],
],
'user' => [
'exclude' => 1,
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.user',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'foreign_table' => 'fe_users',
'foreign_table_where' => 'ORDER BY fe_users.username',
'items' => [
[
'--div--', 0
],
],
'fieldControl' => [
'editPopup' => [
'disabled' => false,
],
'addRecord' => [
'disabled' => false,
'options' => [
'setValue' => 'prepend',
],
'listModule' => [
'disabled' => false,
],
],
],
],
],
'uid' => [
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.uid',
'config' => [
'type' => 'none'
],
],
],
'types' => [
'1' => [
'showitem' => 'hidden, rating, voter, vote'
],
],
'palettes' => [
'1' => [
'showitem' => ''
],
],
];

View File

@@ -47,9 +47,9 @@ return [
'disableNoMatchingValueElement' => 1,
],
],
'voter' => [
'user' => [
'exclude' => 1,
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.voter',
'label' => 'LLL:EXT:bookmarks_likes_ratings/Resources/Private/Language/locallang.xlf:tca.model.vote.user',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',