Commit 1ba5471c by sn

0.0.1 20171108: add Model with vars

0 parents
Showing with 2911 additions and 0 deletions
0.0.1 20171108: add Model with vars
<?php
namespace Netzcoop\Anctestextension\Controller;
/***
*
* This file is part of the "anc test extension" Extension for TYPO3 CMS.
*
* For the full copyright and license information, please read the
* LICENSE.txt file that was distributed with this source code.
*
* (c) 2017
*
***/
/**
* NcTestobjController
*/
class NcTestobjController extends \TYPO3\CMS\Extbase\Mvc\Controller\ActionController
{
/**
* ncTestobjRepository
*
* @var \Netzcoop\Anctestextension\Domain\Repository\NcTestobjRepository
* @inject
*/
protected $ncTestobjRepository = null;
/**
* action list
*
* @return void
*/
public function listAction()
{
$ncTestobjs = $this->ncTestobjRepository->findAll();
$this->view->assign('ncTestobjs', $ncTestobjs);
}
/**
* action show
*
* @param \Netzcoop\Anctestextension\Domain\Model\NcTestobj $ncTestobj
* @return void
*/
public function showAction(\Netzcoop\Anctestextension\Domain\Model\NcTestobj $ncTestobj)
{
$this->view->assign('ncTestobj', $ncTestobj);
}
/**
* action new
*
* @return void
*/
public function newAction()
{
}
/**
* action create
*
* @param \Netzcoop\Anctestextension\Domain\Model\NcTestobj $newNcTestobj
* @return void
*/
public function createAction(\Netzcoop\Anctestextension\Domain\Model\NcTestobj $newNcTestobj)
{
$this->addFlashMessage('The object was created. Please be aware that this action is publicly accessible unless you implement an access check. See https://docs.typo3.org/typo3cms/extensions/extension_builder/User/Index.html', '', \TYPO3\CMS\Core\Messaging\AbstractMessage::WARNING);
$this->ncTestobjRepository->add($newNcTestobj);
$this->redirect('list');
}
/**
* action edit
*
* @param \Netzcoop\Anctestextension\Domain\Model\NcTestobj $ncTestobj
* @ignorevalidation $ncTestobj
* @return void
*/
public function editAction(\Netzcoop\Anctestextension\Domain\Model\NcTestobj $ncTestobj)
{
$this->view->assign('ncTestobj', $ncTestobj);
}
/**
* action update
*
* @param \Netzcoop\Anctestextension\Domain\Model\NcTestobj $ncTestobj
* @return void
*/
public function updateAction(\Netzcoop\Anctestextension\Domain\Model\NcTestobj $ncTestobj)
{
$this->addFlashMessage('The object was updated. Please be aware that this action is publicly accessible unless you implement an access check. See https://docs.typo3.org/typo3cms/extensions/extension_builder/User/Index.html', '', \TYPO3\CMS\Core\Messaging\AbstractMessage::WARNING);
$this->ncTestobjRepository->update($ncTestobj);
$this->redirect('list');
}
/**
* action delete
*
* @param \Netzcoop\Anctestextension\Domain\Model\NcTestobj $ncTestobj
* @return void
*/
public function deleteAction(\Netzcoop\Anctestextension\Domain\Model\NcTestobj $ncTestobj)
{
$this->addFlashMessage('The object was deleted. Please be aware that this action is publicly accessible unless you implement an access check. See https://docs.typo3.org/typo3cms/extensions/extension_builder/User/Index.html', '', \TYPO3\CMS\Core\Messaging\AbstractMessage::WARNING);
$this->ncTestobjRepository->remove($ncTestobj);
$this->redirect('list');
}
}
<?php
namespace Netzcoop\Anctestextension\Domain\Model;
/***
*
* This file is part of the "anc test extension" Extension for TYPO3 CMS.
*
* For the full copyright and license information, please read the
* LICENSE.txt file that was distributed with this source code.
*
* (c) 2017
*
***/
/**
* NcTestobj
*/
class NcTestobj extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity
{
/**
* ncTestString
*
* @var string
*/
protected $ncTestString = '';
/**
* ncTestText
*
* @var string
*/
protected $ncTestText = '';
/**
* ncTestRichText
*
* @var string
*/
protected $ncTestRichText = '';
/**
* ncTestPassword
*
* @var string
*/
protected $ncTestPassword = '';
/**
* ncTestIntenger
*
* @var int
*/
protected $ncTestIntenger = 0;
/**
* ncTestFloatingPoint
*
* @var float
*/
protected $ncTestFloatingPoint = 0.0;
/**
* ncTestBoolean
*
* @var bool
*/
protected $ncTestBoolean = false;
/**
* ncTestDate
*
* @var \DateTime
*/
protected $ncTestDate = null;
/**
* ncTestDateTime
*
* @var \DateTime
*/
protected $ncTestDateTime = null;
/**
* ncTestDateTimestamp
*
* @var \DateTime
*/
protected $ncTestDateTimestamp = null;
/**
* ncTestTime
*
* @var int
*/
protected $ncTestTime = 0;
/**
* ncTestTimeSec
*
* @var int
*/
protected $ncTestTimeSec = 0;
/**
* ncTestSelectlist
*
* @var int
*/
protected $ncTestSelectlist = 0;
/**
* ncTestFile
*
* @var \TYPO3\CMS\Extbase\Domain\Model\FileReference
* @cascade remove
*/
protected $ncTestFile = null;
/**
* ncTestImage
*
* @var \TYPO3\CMS\Extbase\Domain\Model\FileReference
* @cascade remove
*/
protected $ncTestImage = null;
/**
* ncTestStringRequired
*
* @var string
* @validate NotEmpty
*/
protected $ncTestStringRequired = '';
/**
* Returns the ncTestString
*
* @return string $ncTestString
*/
public function getNcTestString()
{
return $this->ncTestString;
}
/**
* Sets the ncTestString
*
* @param string $ncTestString
* @return void
*/
public function setNcTestString($ncTestString)
{
$this->ncTestString = $ncTestString;
}
/**
* Returns the ncTestText
*
* @return string $ncTestText
*/
public function getNcTestText()
{
return $this->ncTestText;
}
/**
* Sets the ncTestText
*
* @param string $ncTestText
* @return void
*/
public function setNcTestText($ncTestText)
{
$this->ncTestText = $ncTestText;
}
/**
* Returns the ncTestRichText
*
* @return string $ncTestRichText
*/
public function getNcTestRichText()
{
return $this->ncTestRichText;
}
/**
* Sets the ncTestRichText
*
* @param string $ncTestRichText
* @return void
*/
public function setNcTestRichText($ncTestRichText)
{
$this->ncTestRichText = $ncTestRichText;
}
/**
* Returns the ncTestPassword
*
* @return string $ncTestPassword
*/
public function getNcTestPassword()
{
return $this->ncTestPassword;
}
/**
* Sets the ncTestPassword
*
* @param string $ncTestPassword
* @return void
*/
public function setNcTestPassword($ncTestPassword)
{
$this->ncTestPassword = $ncTestPassword;
}
/**
* Returns the ncTestIntenger
*
* @return int $ncTestIntenger
*/
public function getNcTestIntenger()
{
return $this->ncTestIntenger;
}
/**
* Sets the ncTestIntenger
*
* @param int $ncTestIntenger
* @return void
*/
public function setNcTestIntenger($ncTestIntenger)
{
$this->ncTestIntenger = $ncTestIntenger;
}
/**
* Returns the ncTestFloatingPoint
*
* @return float $ncTestFloatingPoint
*/
public function getNcTestFloatingPoint()
{
return $this->ncTestFloatingPoint;
}
/**
* Sets the ncTestFloatingPoint
*
* @param float $ncTestFloatingPoint
* @return void
*/
public function setNcTestFloatingPoint($ncTestFloatingPoint)
{
$this->ncTestFloatingPoint = $ncTestFloatingPoint;
}
/**
* Returns the ncTestBoolean
*
* @return bool $ncTestBoolean
*/
public function getNcTestBoolean()
{
return $this->ncTestBoolean;
}
/**
* Sets the ncTestBoolean
*
* @param bool $ncTestBoolean
* @return void
*/
public function setNcTestBoolean($ncTestBoolean)
{
$this->ncTestBoolean = $ncTestBoolean;
}
/**
* Returns the boolean state of ncTestBoolean
*
* @return bool
*/
public function isNcTestBoolean()
{
return $this->ncTestBoolean;
}
/**
* Returns the ncTestDate
*
* @return \DateTime $ncTestDate
*/
public function getNcTestDate()
{
return $this->ncTestDate;
}
/**
* Sets the ncTestDate
*
* @param \DateTime $ncTestDate
* @return void
*/
public function setNcTestDate(\DateTime $ncTestDate)
{
$this->ncTestDate = $ncTestDate;
}
/**
* Returns the ncTestDateTime
*
* @return \DateTime $ncTestDateTime
*/
public function getNcTestDateTime()
{
return $this->ncTestDateTime;
}
/**
* Sets the ncTestDateTime
*
* @param \DateTime $ncTestDateTime
* @return void
*/
public function setNcTestDateTime(\DateTime $ncTestDateTime)
{
$this->ncTestDateTime = $ncTestDateTime;
}
/**
* Returns the ncTestDateTimestamp
*
* @return \DateTime $ncTestDateTimestamp
*/
public function getNcTestDateTimestamp()
{
return $this->ncTestDateTimestamp;
}
/**
* Sets the ncTestDateTimestamp
*
* @param \DateTime $ncTestDateTimestamp
* @return void
*/
public function setNcTestDateTimestamp(\DateTime $ncTestDateTimestamp)
{
$this->ncTestDateTimestamp = $ncTestDateTimestamp;
}
/**
* Returns the ncTestTime
*
* @return int $ncTestTime
*/
public function getNcTestTime()
{
return $this->ncTestTime;
}
/**
* Sets the ncTestTime
*
* @param int $ncTestTime
* @return void
*/
public function setNcTestTime(int $ncTestTime)
{
$this->ncTestTime = $ncTestTime;
}
/**
* Returns the ncTestTimeSec
*
* @return int $ncTestTimeSec
*/
public function getNcTestTimeSec()
{
return $this->ncTestTimeSec;
}
/**
* Sets the ncTestTimeSec
*
* @param int $ncTestTimeSec
* @return void
*/
public function setNcTestTimeSec(int $ncTestTimeSec)
{
$this->ncTestTimeSec = $ncTestTimeSec;
}
/**
* Returns the ncTestSelectlist
*
* @return int $ncTestSelectlist
*/
public function getNcTestSelectlist()
{
return $this->ncTestSelectlist;
}
/**
* Sets the ncTestSelectlist
*
* @param int $ncTestSelectlist
* @return void
*/
public function setNcTestSelectlist($ncTestSelectlist)
{
$this->ncTestSelectlist = $ncTestSelectlist;
}
/**
* Returns the ncTestFile
*
* @return \TYPO3\CMS\Extbase\Domain\Model\FileReference $ncTestFile
*/
public function getNcTestFile()
{
return $this->ncTestFile;
}
/**
* Sets the ncTestFile
*
* @param \TYPO3\CMS\Extbase\Domain\Model\FileReference $ncTestFile
* @return void
*/
public function setNcTestFile(\TYPO3\CMS\Extbase\Domain\Model\FileReference $ncTestFile)
{
$this->ncTestFile = $ncTestFile;
}
/**
* Returns the ncTestImage
*
* @return \TYPO3\CMS\Extbase\Domain\Model\FileReference $ncTestImage
*/
public function getNcTestImage()
{
return $this->ncTestImage;
}
/**
* Sets the ncTestImage
*
* @param \TYPO3\CMS\Extbase\Domain\Model\FileReference $ncTestImage
* @return void
*/
public function setNcTestImage(\TYPO3\CMS\Extbase\Domain\Model\FileReference $ncTestImage)
{
$this->ncTestImage = $ncTestImage;
}
/**
* Returns the ncTestStringRequired
*
* @return string $ncTestStringRequired
*/
public function getNcTestStringRequired()
{
return $this->ncTestStringRequired;
}
/**
* Sets the ncTestStringRequired
*
* @param string $ncTestStringRequired
* @return void
*/
public function setNcTestStringRequired($ncTestStringRequired)
{
$this->ncTestStringRequired = $ncTestStringRequired;
}
}
<?php
namespace Netzcoop\Anctestextension\Domain\Repository;
/***
*
* This file is part of the "anc test extension" Extension for TYPO3 CMS.
*
* For the full copyright and license information, please read the
* LICENSE.txt file that was distributed with this source code.
*
* (c) 2017
*
***/
/**
* The repository for NcTestobjs
*/
class NcTestobjRepository extends \TYPO3\CMS\Extbase\Persistence\Repository
{
}
#
# Extension Builder settings for extension anctestextension
# generated 2017-11-08T09:58:00Z
#
# See http://www.yaml.org/spec/1.2/spec.html
#
---
########### Overwrite settings ###########
#
# These settings only apply, if the roundtrip feature of the extension builder
# is enabled in the extension manager
#
# Usage:
# nesting reflects the file structure
# a setting applies to a file or recursive to all files and subfolders
#
# merge:
# means for classes: All properties ,methods and method bodies
# of the existing class will be modified according to the new settings
# but not overwritten
#
# for locallang xlf files: Existing keys and labels are always
# preserved (renaming a property or DomainObject will result in new keys and new labels)
#
# for other files: You will find a Split token at the end of the file
# see: \EBT\ExtensionBuilder\Service\RoundTrip::SPLIT_TOKEN
#
# After this token you can write whatever you want and it will be appended
# everytime the code is generated
#
# keep:
# files are never overwritten
# These settings may break the functionality of the extension builder!
# Handle with care!
#
#
############ extension settings ##############
overwriteSettings:
Classes:
Controller: merge
Domain:
Model: merge
Repository: merge
Configuration:
#TCA merge not possible - use overrides directory
#TypoScript: keep
Resources:
Private:
#Language: merge
#Templates: keep
ext_icon.gif: keep
# ext_localconf.php: merge
# ext_tables.php: merge
# ext_tables.sql: merge
## use static date attribute in xliff files ##
#staticDateInXliffFiles: 2017-11-08T09:58:00Z
## skip docComment (license header) ##
#skipDocComment
## list of error codes for warnings that should be ignored ##
#ignoreWarnings:
#503
######### settings for classBuilder #############################
#
# here you may define default parent classes for your classes
# these settings only apply for new generated classes
# you may also just change the parent class in the generated class file.
# It will be kept on next code generation, if the overwrite settings
# are configured to merge it
#
#################################################################
classBuilder:
Controller:
parentClass: \TYPO3\CMS\Extbase\Mvc\Controller\ActionController
Model:
AbstractEntity:
parentClass: \TYPO3\CMS\Extbase\DomainObject\AbstractEntity
AbstractValueObject:
parentClass: \TYPO3\CMS\Extbase\DomainObject\AbstractValueObject
Repository:
parentClass: \TYPO3\CMS\Extbase\Persistence\Repository
setDefaultValuesForClassProperties: true
\ No newline at end of file
<?php
return [
'ctrl' => [
'title' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj',
'label' => 'nc_test_string',
'tstamp' => 'tstamp',
'crdate' => 'crdate',
'cruser_id' => 'cruser_id',
'versioningWS' => true,
'languageField' => 'sys_language_uid',
'transOrigPointerField' => 'l10n_parent',
'transOrigDiffSourceField' => 'l10n_diffsource',
'delete' => 'deleted',
'enablecolumns' => [
'disabled' => 'hidden',
'starttime' => 'starttime',
'endtime' => 'endtime',
],
'searchFields' => 'nc_test_string,nc_test_text,nc_test_rich_text,nc_test_password,nc_test_intenger,nc_test_floating_point,nc_test_boolean,nc_test_date,nc_test_date_time,nc_test_date_timestamp,nc_test_time,nc_test_time_sec,nc_test_selectlist,nc_test_file,nc_test_image,nc_test_string_required',
'iconfile' => 'EXT:anctestextension/Resources/Public/Icons/tx_anctestextension_domain_model_nctestobj.gif'
],
'interface' => [
'showRecordFieldList' => 'sys_language_uid, l10n_parent, l10n_diffsource, hidden, nc_test_string, nc_test_text, nc_test_rich_text, nc_test_password, nc_test_intenger, nc_test_floating_point, nc_test_boolean, nc_test_date, nc_test_date_time, nc_test_date_timestamp, nc_test_time, nc_test_time_sec, nc_test_selectlist, nc_test_file, nc_test_image, nc_test_string_required',
],
'types' => [
'1' => ['showitem' => 'sys_language_uid, l10n_parent, l10n_diffsource, hidden, nc_test_string, nc_test_text, nc_test_rich_text, nc_test_password, nc_test_intenger, nc_test_floating_point, nc_test_boolean, nc_test_date, nc_test_date_time, nc_test_date_timestamp, nc_test_time, nc_test_time_sec, nc_test_selectlist, nc_test_file, nc_test_image, nc_test_string_required, --div--;LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:tabs.access, starttime, endtime'],
],
'columns' => [
'sys_language_uid' => [
'exclude' => true,
'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.language',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'special' => 'languages',
'items' => [
[
'LLL:EXT:lang/locallang_general.xlf:LGL.allLanguages',
-1,
'flags-multiple'
]
],
'default' => 0,
],
],
'l10n_parent' => [
'displayCond' => 'FIELD:sys_language_uid:>:0',
'exclude' => true,
'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.l18n_parent',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'items' => [
['', 0],
],
'foreign_table' => 'tx_anctestextension_domain_model_nctestobj',
'foreign_table_where' => 'AND tx_anctestextension_domain_model_nctestobj.pid=###CURRENT_PID### AND tx_anctestextension_domain_model_nctestobj.sys_language_uid IN (-1,0)',
],
],
'l10n_diffsource' => [
'config' => [
'type' => 'passthrough',
],
],
't3ver_label' => [
'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.versionLabel',
'config' => [
'type' => 'input',
'size' => 30,
'max' => 255,
],
],
'hidden' => [
'exclude' => true,
'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.hidden',
'config' => [
'type' => 'check',
'items' => [
'1' => [
'0' => 'LLL:EXT:lang/locallang_core.xlf:labels.enabled'
]
],
],
],
'starttime' => [
'exclude' => true,
'l10n_mode' => 'mergeIfNotBlank',
'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.starttime',
'config' => [
'type' => 'input',
'size' => 13,
'eval' => 'datetime',
'default' => 0,
]
],
'endtime' => [
'exclude' => true,
'l10n_mode' => 'mergeIfNotBlank',
'label' => 'LLL:EXT:lang/locallang_general.xlf:LGL.endtime',
'config' => [
'type' => 'input',
'size' => 13,
'eval' => 'datetime',
'default' => 0,
'range' => [
'upper' => mktime(0, 0, 0, 1, 1, 2038)
]
],
],
'nc_test_string' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_string',
'config' => [
'type' => 'input',
'size' => 30,
'eval' => 'trim'
],
],
'nc_test_text' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_text',
'config' => [
'type' => 'text',
'cols' => 40,
'rows' => 15,
'eval' => 'trim'
]
],
'nc_test_rich_text' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_rich_text',
'config' => [
'type' => 'text',
'cols' => 40,
'rows' => 15,
'eval' => 'trim',
],
'defaultExtras' => 'richtext:rte_transform[mode=ts_css]'
],
'nc_test_password' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_password',
'config' => [
'type' => 'input',
'size' => 30,
'eval' => 'nospace,password'
]
],
'nc_test_intenger' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_intenger',
'config' => [
'type' => 'input',
'size' => 4,
'eval' => 'int'
]
],
'nc_test_floating_point' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_floating_point',
'config' => [
'type' => 'input',
'size' => 30,
'eval' => 'double2'
]
],
'nc_test_boolean' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_boolean',
'config' => [
'type' => 'check',
'items' => [
'1' => [
'0' => 'LLL:EXT:lang/locallang_core.xlf:labels.enabled'
]
],
'default' => 0
]
],
'nc_test_date' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_date',
'config' => [
'dbType' => 'date',
'type' => 'input',
'size' => 7,
'eval' => 'date',
'default' => '0000-00-00'
],
],
'nc_test_date_time' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_date_time',
'config' => [
'dbType' => 'datetime',
'type' => 'input',
'size' => 12,
'eval' => 'datetime',
'default' => '0000-00-00 00:00:00'
],
],
'nc_test_date_timestamp' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_date_timestamp',
'config' => [
'type' => 'input',
'size' => 7,
'eval' => 'date',
'default' => time()
],
],
'nc_test_time' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_time',
'config' => [
'type' => 'input',
'size' => 4,
'eval' => 'time',
'default' => time()
]
],
'nc_test_time_sec' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_time_sec',
'config' => [
'type' => 'input',
'size' => 6,
'eval' => 'timesec',
'default' => time()
]
],
'nc_test_selectlist' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_selectlist',
'config' => [
'type' => 'select',
'renderType' => 'selectSingle',
'items' => [
['-- Label --', 0],
],
'size' => 1,
'maxitems' => 1,
'eval' => ''
],
],
'nc_test_file' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_file',
'config' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getFileFieldTCAConfig(
'nc_test_file',
[
'appearance' => [
'createNewRelationLinkTitle' => 'LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:media.addFileReference'
],
'foreign_types' => [
'0' => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_TEXT => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_IMAGE => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_AUDIO => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_VIDEO => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_APPLICATION => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
]
],
'maxitems' => 1
]
),
],
'nc_test_image' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_image',
'config' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getFileFieldTCAConfig(
'nc_test_image',
[
'appearance' => [
'createNewRelationLinkTitle' => 'LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:images.addFileReference'
],
'foreign_types' => [
'0' => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_TEXT => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_IMAGE => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_AUDIO => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_VIDEO => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_APPLICATION => [
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
]
],
'maxitems' => 1
],
$GLOBALS['TYPO3_CONF_VARS']['GFX']['imagefile_ext']
),
],
'nc_test_string_required' => [
'exclude' => true,
'label' => 'LLL:EXT:anctestextension/Resources/Private/Language/locallang_db.xlf:tx_anctestextension_domain_model_nctestobj.nc_test_string_required',
'config' => [
'type' => 'input',
'size' => 30,
'eval' => 'trim,required'
],
],
],
];
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _admin-manual:
Administrator Manual
====================
Target group: **Administrators**
Describes how to manage the extension from an administrator point of view.
That relates to Page/User TSconfig, permissions, configuration etc.,
which administrator level users have access to.
Language should be non / semi-technical, explaining, using small examples.
.. _admin-installation:
Installation
------------
- How should the extension be installed?
- Are they dependencies to resolve?
- Is it a static template file to be included?
To install the extension, perform the following steps:
#. Go to the Extension Manager
#. Install the extension
#. Load the static template
#. ...
For a list of configuration options, using a definition list is recommended:
Some Configuration
This option enables...
Other configuration
This other option is for all the rest...
.. figure:: ../Images/AdministratorManual/ExtensionManager.png
:alt: Extension Manager
Extension Manager (caption of the image)
List of extensions within the Extension Manager also shorten with "EM" (legend of the image)
.. _admin-configuration:
Configuration
-------------
* Where and how the extension should be configured? TypoScript? PHP?
* Are there other prerequisite to full fill beforehand?
For example, configure a setting in a special way somewhere.
.. _admin-faq:
FAQ
---
Possible subsection: FAQ
Subsection
^^^^^^^^^^
Some subsection
Sub-subsection
""""""""""""""
Deeper into the structure...
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _changelog:
ChangeLog
=========
Providing a change log chapter is optional. You can also refer
users to the ChangeLog file inside the extension or to some repository's
commit listing.
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _configuration:
Configuration Reference
=======================
Technical information: Installation, Reference of TypoScript options,
configuration options on system level, how to extend it, the technical
details, how to debug it and so on.
Language should be technical, assuming developer knowledge of TYPO3.
Small examples/visuals are always encouraged.
Target group: **Developers**
.. _configuration-typoscript:
TypoScript Reference
--------------------
Possible subsections: Reference of TypoScript options.
The construct below show the recommended structure for
TypoScript properties listing and description.
Properties should be listed in the order in which they
are executed by your extension, but the first should be
alphabetical for easier access.
When detailing data types or standard TypoScript
features, don't hesitate to cross-link to the TypoScript
Reference as shown below. See the :file:`Settings.yml`
file for the declaration of cross-linking keys.
Properties
^^^^^^^^^^
.. container:: ts-properties
=========================== ===================================== ======================= ====================
Property Data type :ref:`t3tsref:stdwrap` Default
=========================== ===================================== ======================= ====================
allWrap_ :ref:`t3tsref:data-type-wrap` yes :code:`<div>|</div>`
`subst\_elementUid`_ :ref:`t3tsref:data-type-boolean` no 0
wrapItemAndSub_ :ref:`t3tsref:data-type-wrap`
=========================== ===================================== ======================= ====================
Property details
^^^^^^^^^^^^^^^^
.. only:: html
.. contents::
:local:
:depth: 1
.. _ts-plugin-tx-extensionkey-stdwrap:
allWrap
"""""""
:typoscript:`plugin.tx_extensionkey.allWrap =` :ref:`t3tsref:data-type-wrap`
Wraps the whole item.
.. _ts-plugin-tx-extensionkey-wrapitemandsub:
wrapItemAndSub
""""""""""""""
:typoscript:`plugin.tx_extensionkey.wrapItemAndSub =` :ref:`t3tsref:data-type-wrap`
Wraps the whole item and any submenu concatenated to it.
.. _ts-plugin-tx-extensionkey-substelementUid:
subst_elementUid
""""""""""""""""
:typoscript:`plugin.tx_extensionkey.subst_elementUid =` :ref:`t3tsref:data-type-boolean`
If set, all appearances of the string ``{elementUid}`` in the total
element html-code (after wrapped in allWrap_) are substituted with the
uid number of the menu item. This is useful if you want to insert an
identification code in the HTML in order to manipulate properties with
JavaScript.
.. _configuration-faq:
FAQ
---
Possible subsection: FAQ
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _developer:
Developer Corner
================
Target group: **Developers**
Use this section for *providing code examples* or any **useful** information code wise.
.. _developer-hooks:
Hooks
-----
Possible hook examples. Input parameters are:
+----------------+---------------+---------------------------------+
| Parameter | Data type | Description |
+================+===============+=================================+
| $table | string | Name of the table |
+----------------+---------------+---------------------------------+
| $field | string | Name of the field |
+----------------+---------------+---------------------------------+
Use parameter :code:`$table` to retrieve the table name...
.. _developer-api:
API
---
How to use the API...
.. code-block:: php
$stuff = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(
'\\Foo\\Bar\\Utility\\Stuff'
);
$stuff->do();
or some other language:
.. code-block:: javascript
:linenos:
:emphasize-lines: 2-4
$(document).ready(
function () {
doStuff();
}
);
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. This is 'Includes.txt'. It is included at the very top of each and
every ReST source file in this documentation project (= manual).
.. ==================================================
.. DEFINE SOME TEXT ROLES
.. --------------------------------------------------
.. role:: typoscript(code)
.. role:: ts(typoscript)
:class: typoscript
.. role:: php(code)
.. highlight:: php
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: Includes.txt
.. _start:
=============================================================
anc test extension
=============================================================
.. only:: html
:Classification:
anctestextension
:Version:
|release|
:Language:
en
:Description:
:Keywords:
comma,separated,list,of,keywords
:Copyright:
2017
:Author:
:Email:
:License:
This document is published under the Open Content License
available from http://www.opencontent.org/opl.shtml
:Rendered:
|today|
The content of this document is related to TYPO3,
a GNU/GPL CMS/Framework available from `www.typo3.org <http://www.typo3.org/>`_.
**Table of Contents**
.. toctree::
:maxdepth: 3
:titlesonly:
Introduction/Index
User/Index
Administrator/Index
Configuration/Index
Developer/Index
KnownProblems/Index
ToDoList/Index
ChangeLog/Index
Links
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _introduction:
Introduction
============
.. _what-it-does:
What does it do?
----------------
This chapter should give a brief overview of the extension. What does it do? What problems does it solve?
Who is interested in this? Basically, this section includes everything people need to know to decide whether they
should go on with this extension or not.
.. important::
Please don't forget to repeat your extension's version number in the
:file:`Settings.yml` file, in the :code:`release` property. It will be
automatically picked up on the cover page by the :code:`|release|`
substitution.
.. _screenshots:
Screenshots
-----------
This chapter should help people figure how the extension works. Remove it
if not relevant.
.. figure:: ../Images/IntroductionPackage.png
:width: 500px
:alt: Introduction Package
Introduction Package just after installation (caption of the image)
How the Frontend of the Introduction Package looks like just after installation (legend of the image)
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _known-problems:
Known Problems
==============
Say where bugs can be reported / followed up. Is it a
`bug tracker <http://forge.typo3.org/projects/typo3cms-doc-official-extension-template/issues>`_?
Use this section for informing about any type of of problem
that are not necessarily named in the bug tracker such as performance issues, ...
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: Includes.txt
.. _links:
Links
-----
:TER:
https://typo3.org/extensions/repository/view/<extension key>
:Bug Tracker:
https://forge.typo3.org/projects/extension-<extension key>/issues
:Git Repository:
https://github.com/<username>/<extension key>
:Contact:
`@<username> <https://twitter.com/your-username>`__
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _start:
=============================================================
###PROJECT_NAME### (Deutsch)
=============================================================
.. only:: html
:Klassifikation:
extension_key
:Version:
|release|
:Sprache:
de
:Beschreibung:
Geben Sie eine Beschreibung ein.
:Schlüsselwörter:
komma-getrennte,Liste,von,Schlüsselwörtern
:Copyright:
###YEAR###
:Autor:
###AUTHOR###
:E-Mail:
author@example.com
:Lizenz:
Dieses Dokument wird unter der Open Publication License, siehe
http://www.opencontent.org/openpub/ veröffentlicht.
:Gerendert:
|today|
Der Inhalt dieses Dokuments bezieht sich auf TYPO3,
ein GNU/GPL CMS-Framework auf `www.typo3.org <https://typo3.org/>`__.
**Inhaltsverzeichnis**
.. toctree::
:maxdepth: 3
:titlesonly:
.. Introduction/Index
.. UserManual/Index
.. AdministratorManual/Index
.. Configuration/Index
.. DeveloperCorner/Index
.. KnownProblems/Index
.. ToDoList/Index
.. ChangeLog/Index
How to translate
================
This directory contains the German translation of your documentation.
This is a complete Sphinx project but you may reuse assets from the
main documentation under Documentation/.
If you plan to translate your documentation to German, you should
rename this directory and remove the suffix ".tmpl":
Localization.de_DE.tmpl -> Localization.de_DE
As this file is not needed either, feel free to delete it as well.
Supported languages
===================
Please visit http://sphinx-doc.org/latest/config.html#intl-options for a
list of languages supported by Sphinx.
Please note however that TYPO3 is using locales so you may need to
extend the language code from Sphinx into a proper locale to be used
by TYPO3.
# This is the project specific Settings.yml file.
# Place Sphinx specific build information here.
# Settings given here will replace the settings of 'conf.py'.
# Below is an example of intersphinx mapping declaration
# Add more mappings depending on what manual you want to link to
# Remove entirely if you don't need cross-linking
---
conf.py:
copyright: 2012-2015
project: Extension Name (Deutsch)
version: x.y
release: x.y.z
intersphinx_mapping:
t3tsref:
- https://docs.typo3.org/typo3cms/TyposcriptReference/
- null
latex_documents:
- - Index
- <extension_key>.tex
- Extension Name (Français)
- Your Name
- manual
latex_elements:
papersize: a4paper
pointsize: 10pt
preamble: \usepackage{typo3}
...
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _start:
=============================================================
###PROJECT_NAME### (Français)
=============================================================
.. only:: html
:Classification:
extension_key
:Version:
|release|
:Langue:
fr
:Description:
entrez une description.
:Mots-clés:
list,mots-clés,séparés,par,virgules
:Copyright:
###YEAR###
:Auteur:
###AUTHOR###
:E-mail:
author@example.com
:Licence:
Ce document est publié sous la licence de publication libre
disponible sur http://www.opencontent.org/openpub/
:Généré:
|today|
Le contenu de ce document est en relation avec TYPO3,
un CMS/Framework GNU/GPL disponible sur `www.typo3.org <https://typo3.org/>`__.
**Sommaire**
.. toctree::
:maxdepth: 3
:titlesonly:
.. Introduction/Index
.. UserManual/Index
.. AdministratorManual/Index
.. Configuration/Index
.. DeveloperCorner/Index
.. KnownProblems/Index
.. ToDoList/Index
.. ChangeLog/Index
How to translate
================
This directory contains the French translation of your documentation.
This is a complete Sphinx project but you may reuse assets from the
main documentation under Documentation/.
If you plan to translate your documentation to French, you should
rename this directory and remove the suffix ".tmpl":
Localization.fr_FR.tmpl -> Localization.fr_FR
As this file is not needed either, feel free to delete it as well.
Supported languages
===================
Please visit http://sphinx-doc.org/latest/config.html#intl-options for a
list of languages supported by Sphinx.
Please note however that TYPO3 is using locales so you may need to
extend the language code from Sphinx into a proper locale to be used
by TYPO3.
# This is the project specific Settings.yml file.
# Place Sphinx specific build information here.
# Settings given here will replace the settings of 'conf.py'.
# Below is an example of intersphinx mapping declaration
# Add more mappings depending on what manual you want to link to
# Remove entirely if you don't need cross-linking
---
conf.py:
copyright: 2012-2015
project: Extension Name (Français)
version: x.y
release: x.y.z
intersphinx_mapping:
t3tsref:
- https://docs.typo3.org/typo3cms/TyposcriptReference/
- null
latex_documents:
- - Index
- <extension_key>.tex
- Extension Name (Français)
- Your Name
- manual
latex_elements:
papersize: a4paper
pointsize: 10pt
preamble: \usepackage{typo3}
...
# This is the project specific Settings.yml file.
# Place Sphinx specific build information here.
# Settings given here will replace the settings of 'conf.py'.
# Below is an example of intersphinx mapping declaration
# Add more mappings depending on what manual you want to link to
# Remove entirely if you don't need cross-linking
---
conf.py:
copyright: 2017
project: anc test extension
version: 1.0.0
release: 1.0.0
intersphinx_mapping:
t3tsref:
- http://docs.typo3.org/typo3cms/TyposcriptReference/
- null
latex_documents:
- - Index
- anctestextension.tex
- anc test extension
-
- manual
latex_elements:
papersize: a4paper
pointsize: 10pt
preamble: \usepackage
html_theme_options:
github_repository: TYPO3-Documentation/TYPO3CMS-Example-ExtensionManual
github_branch: latest
...
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _todo:
To-Do list
==========
Give a link pointing to a `roadmap <http://forge.typo3.org/projects/typo3cms-doc-official-extension-template/roadmap>`_.
Alternatively, you can dress up a list of things you want to add or fix in this chapter
or give a vision about where the extension is heading.
.. ==================================================
.. FOR YOUR INFORMATION
.. --------------------------------------------------
.. -*- coding: utf-8 -*- with BOM.
.. include:: ../Includes.txt
.. _user-manual:
Users Manual
============
Target group: **Editors**
Here should be described how to use the extension from the editor perspective.
- How does it work?
- works well when doing this.
- does not work so well when doing that
but we can live with it.
- **mind indentation when nesting lists**.
- How to install the plugin on a web page?
- What options are available?
Language should be non-technical, explaining, using small examples.
Don't use to many acronyms unless they have been explained.
Don't be confusing by putting information targeting administrators.
.. tip::
Take a break from time to time.
Admonitions should be used to warn the users about potential
pitfalls, attract their attention to important elements
or just add some notes for for information (further reading,
for example).
.. important::
Remember to always say "please" when asking your software to
do something.
Provide screenshots as needed for making things clear. When creating
screenshots, try using the `Introduction Package <http://demo.typo3.org/>`_
as a neutral TYPO3 CMS instance.
.. figure:: ../Images/UserManual/BackendView.png
:width: 500px
:alt: Backend view
Default Backend view (caption of the image)
The Backend view of TYPO3 after the user has clicked on module "Page". (legend of the image)
.. _user-faq:
FAQ
---
Possible subsection: FAQ
{
"modules": [
{
"config": {
"position": [
188,
228
]
},
"name": "New Model Object",
"value": {
"actionGroup": {
"_default0_list": true,
"_default1_show": true,
"_default2_new_create": true,
"_default3_edit_update": true,
"_default4_delete": true,
"customActions": []
},
"name": "NcTestobj",
"objectsettings": {
"addDeletedField": true,
"addHiddenField": true,
"addStarttimeEndtimeFields": true,
"aggregateRoot": true,
"categorizable": false,
"description": "",
"mapToTable": "",
"parentClass": "",
"sorting": false,
"type": "Entity",
"uid": "574264381000"
},
"propertyGroup": {
"properties": [
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestString",
"propertyType": "String",
"uid": "1463279303542"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestText",
"propertyType": "Text",
"uid": "1440981882531"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestRichText",
"propertyType": "RichText",
"uid": "618176094870"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestPassword",
"propertyType": "Password",
"uid": "413223518950"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestIntenger",
"propertyType": "Integer",
"uid": "1310630125527"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestFloatingPoint",
"propertyType": "Float",
"uid": "1333959796452"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestBoolean",
"propertyType": "Boolean",
"uid": "886965454683"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestDate",
"propertyType": "NativeDate",
"uid": "1049434907937"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestDateTime",
"propertyType": "NativeDateTime",
"uid": "1210077566205"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestDateTimestamp",
"propertyType": "Date",
"uid": "1252959760055"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestTime",
"propertyType": "Time",
"uid": "625329935437"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestTimeSec",
"propertyType": "TimeSec",
"uid": "341384887453"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestSelectlist",
"propertyType": "Select",
"uid": "831600213536"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestFile",
"propertyType": "File",
"uid": "448195561059"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": false,
"propertyName": "ncTestImage",
"propertyType": "Image",
"uid": "916561842056"
},
{
"allowedFileTypes": "",
"maxItems": "1",
"propertyDescription": "",
"propertyIsExcludeField": true,
"propertyIsRequired": true,
"propertyName": "ncTestStringRequired",
"propertyType": "String",
"uid": "676861052816"
}
]
},
"relationGroup": {
"relations": []
}
}
}
],
"properties": {
"backendModules": [],
"description": "",
"emConf": {
"category": "plugin",
"custom_category": "",
"dependsOn": "typo3 => 7.6.0-7.6.99\n",
"disableLocalization": false,
"disableVersioning": false,
"skipGenerateDocumentationTemplate": false,
"sourceLanguage": "en",
"state": "alpha",
"targetVersion": "7.6.0-7.6.99",
"version": "1.0.0"
},
"extensionKey": "anctestextension",
"name": "anc test extension",
"originalExtensionKey": "",
"originalVendorName": "",
"persons": [],
"plugins": [],
"vendorName": "Netzcoop"
},
"wires": [],
"log": {
"last_modified": "2017-11-08 09:59",
"extension_builder_version": "7.6.18",
"be_user": " (1)"
}
}
\ No newline at end of file
# Apache < 2.3
<IfModule !mod_authz_core.c>
Order allow,deny
Deny from all
Satisfy All
</IfModule>
# Apache >= 2.3
<IfModule mod_authz_core.c>
Require all denied
</IfModule>
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<xliff version="1.0">
<file source-language="en" datatype="plaintext" original="messages" date="2017-11-08T09:59:51Z" product-name="anctestextension">
<header/>
<body>
<trans-unit id="tx_anctestextension_domain_model_nctestobj">
<source>Nc Testobj</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_string">
<source>Nc Test String</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_text">
<source>Nc Test Text</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_rich_text">
<source>Nc Test Rich Text</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_password">
<source>Nc Test Password</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_intenger">
<source>Nc Test Intenger</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_floating_point">
<source>Nc Test Floating Point</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_boolean">
<source>Nc Test Boolean</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_date">
<source>Nc Test Date</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_date_time">
<source>Nc Test Date Time</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_date_timestamp">
<source>Nc Test Date Timestamp</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_time">
<source>Nc Test Time</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_time_sec">
<source>Nc Test Time Sec</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_selectlist">
<source>Nc Test Selectlist</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_file">
<source>Nc Test File</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_image">
<source>Nc Test Image</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_string_required">
<source>Nc Test String Required</source>
</trans-unit>
</body>
</file>
</xliff>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<xliff version="1.0">
<file source-language="en" datatype="plaintext" original="messages" date="2017-11-08T09:59:51Z" product-name="anctestextension">
<header/>
<body>
<trans-unit id="nc_test_string.description">
<source>ncTestString</source>
</trans-unit>
<trans-unit id="nc_test_text.description">
<source>ncTestText</source>
</trans-unit>
<trans-unit id="nc_test_rich_text.description">
<source>ncTestRichText</source>
</trans-unit>
<trans-unit id="nc_test_password.description">
<source>ncTestPassword</source>
</trans-unit>
<trans-unit id="nc_test_intenger.description">
<source>ncTestIntenger</source>
</trans-unit>
<trans-unit id="nc_test_floating_point.description">
<source>ncTestFloatingPoint</source>
</trans-unit>
<trans-unit id="nc_test_boolean.description">
<source>ncTestBoolean</source>
</trans-unit>
<trans-unit id="nc_test_date.description">
<source>ncTestDate</source>
</trans-unit>
<trans-unit id="nc_test_date_time.description">
<source>ncTestDateTime</source>
</trans-unit>
<trans-unit id="nc_test_date_timestamp.description">
<source>ncTestDateTimestamp</source>
</trans-unit>
<trans-unit id="nc_test_time.description">
<source>ncTestTime</source>
</trans-unit>
<trans-unit id="nc_test_time_sec.description">
<source>ncTestTimeSec</source>
</trans-unit>
<trans-unit id="nc_test_selectlist.description">
<source>ncTestSelectlist</source>
</trans-unit>
<trans-unit id="nc_test_file.description">
<source>ncTestFile</source>
</trans-unit>
<trans-unit id="nc_test_image.description">
<source>ncTestImage</source>
</trans-unit>
<trans-unit id="nc_test_string_required.description">
<source>ncTestStringRequired</source>
</trans-unit>
</body>
</file>
</xliff>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<xliff version="1.0">
<file source-language="en" datatype="plaintext" original="messages" date="2017-11-08T09:59:51Z" product-name="anctestextension">
<header/>
<body>
<trans-unit id="tx_anctestextension_domain_model_nctestobj">
<source>Nc Testobj</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_string">
<source>Nc Test String</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_text">
<source>Nc Test Text</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_rich_text">
<source>Nc Test Rich Text</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_password">
<source>Nc Test Password</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_intenger">
<source>Nc Test Intenger</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_floating_point">
<source>Nc Test Floating Point</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_boolean">
<source>Nc Test Boolean</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_date">
<source>Nc Test Date</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_date_time">
<source>Nc Test Date Time</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_date_timestamp">
<source>Nc Test Date Timestamp</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_time">
<source>Nc Test Time</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_time_sec">
<source>Nc Test Time Sec</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_selectlist">
<source>Nc Test Selectlist</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_file">
<source>Nc Test File</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_image">
<source>Nc Test Image</source>
</trans-unit>
<trans-unit id="tx_anctestextension_domain_model_nctestobj.nc_test_string_required">
<source>Nc Test String Required</source>
</trans-unit>
</body>
</file>
</xliff>
\ No newline at end of file
<?php
namespace Netzcoop\Anctestextension\Tests\Unit\Controller;
/**
* Test case.
*/
class NcTestobjControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
{
/**
* @var \Netzcoop\Anctestextension\Controller\NcTestobjController
*/
protected $subject = null;
protected function setUp()
{
parent::setUp();
$this->subject = $this->getMockBuilder(\Netzcoop\Anctestextension\Controller\NcTestobjController::class)
->setMethods(['redirect', 'forward', 'addFlashMessage'])
->disableOriginalConstructor()
->getMock();
}
protected function tearDown()
{
parent::tearDown();
}
/**
* @test
*/
public function listActionFetchesAllNcTestobjsFromRepositoryAndAssignsThemToView()
{
$allNcTestobjs = $this->getMockBuilder(\TYPO3\CMS\Extbase\Persistence\ObjectStorage::class)
->disableOriginalConstructor()
->getMock();
$ncTestobjRepository = $this->getMockBuilder(\Netzcoop\Anctestextension\Domain\Repository\NcTestobjRepository::class)
->setMethods(['findAll'])
->disableOriginalConstructor()
->getMock();
$ncTestobjRepository->expects(self::once())->method('findAll')->will(self::returnValue($allNcTestobjs));
$this->inject($this->subject, 'ncTestobjRepository', $ncTestobjRepository);
$view = $this->getMockBuilder(\TYPO3\CMS\Extbase\Mvc\View\ViewInterface::class)->getMock();
$view->expects(self::once())->method('assign')->with('ncTestobjs', $allNcTestobjs);
$this->inject($this->subject, 'view', $view);
$this->subject->listAction();
}
/**
* @test
*/
public function showActionAssignsTheGivenNcTestobjToView()
{
$ncTestobj = new \Netzcoop\Anctestextension\Domain\Model\NcTestobj();
$view = $this->getMockBuilder(\TYPO3\CMS\Extbase\Mvc\View\ViewInterface::class)->getMock();
$this->inject($this->subject, 'view', $view);
$view->expects(self::once())->method('assign')->with('ncTestobj', $ncTestobj);
$this->subject->showAction($ncTestobj);
}
/**
* @test
*/
public function createActionAddsTheGivenNcTestobjToNcTestobjRepository()
{
$ncTestobj = new \Netzcoop\Anctestextension\Domain\Model\NcTestobj();
$ncTestobjRepository = $this->getMockBuilder(\Netzcoop\Anctestextension\Domain\Repository\NcTestobjRepository::class)
->setMethods(['add'])
->disableOriginalConstructor()
->getMock();
$ncTestobjRepository->expects(self::once())->method('add')->with($ncTestobj);
$this->inject($this->subject, 'ncTestobjRepository', $ncTestobjRepository);
$this->subject->createAction($ncTestobj);
}
/**
* @test
*/
public function editActionAssignsTheGivenNcTestobjToView()
{
$ncTestobj = new \Netzcoop\Anctestextension\Domain\Model\NcTestobj();
$view = $this->getMockBuilder(\TYPO3\CMS\Extbase\Mvc\View\ViewInterface::class)->getMock();
$this->inject($this->subject, 'view', $view);
$view->expects(self::once())->method('assign')->with('ncTestobj', $ncTestobj);
$this->subject->editAction($ncTestobj);
}
/**
* @test
*/
public function updateActionUpdatesTheGivenNcTestobjInNcTestobjRepository()
{
$ncTestobj = new \Netzcoop\Anctestextension\Domain\Model\NcTestobj();
$ncTestobjRepository = $this->getMockBuilder(\Netzcoop\Anctestextension\Domain\Repository\NcTestobjRepository::class)
->setMethods(['update'])
->disableOriginalConstructor()
->getMock();
$ncTestobjRepository->expects(self::once())->method('update')->with($ncTestobj);
$this->inject($this->subject, 'ncTestobjRepository', $ncTestobjRepository);
$this->subject->updateAction($ncTestobj);
}
/**
* @test
*/
public function deleteActionRemovesTheGivenNcTestobjFromNcTestobjRepository()
{
$ncTestobj = new \Netzcoop\Anctestextension\Domain\Model\NcTestobj();
$ncTestobjRepository = $this->getMockBuilder(\Netzcoop\Anctestextension\Domain\Repository\NcTestobjRepository::class)
->setMethods(['remove'])
->disableOriginalConstructor()
->getMock();
$ncTestobjRepository->expects(self::once())->method('remove')->with($ncTestobj);
$this->inject($this->subject, 'ncTestobjRepository', $ncTestobjRepository);
$this->subject->deleteAction($ncTestobj);
}
}
<?php
namespace Netzcoop\Anctestextension\Tests\Unit\Domain\Model;
/**
* Test case.
*/
class NcTestobjTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
{
/**
* @var \Netzcoop\Anctestextension\Domain\Model\NcTestobj
*/
protected $subject = null;
protected function setUp()
{
parent::setUp();
$this->subject = new \Netzcoop\Anctestextension\Domain\Model\NcTestobj();
}
protected function tearDown()
{
parent::tearDown();
}
/**
* @test
*/
public function getNcTestStringReturnsInitialValueForString()
{
self::assertSame(
'',
$this->subject->getNcTestString()
);
}
/**
* @test
*/
public function setNcTestStringForStringSetsNcTestString()
{
$this->subject->setNcTestString('Conceived at T3CON10');
self::assertAttributeEquals(
'Conceived at T3CON10',
'ncTestString',
$this->subject
);
}
/**
* @test
*/
public function getNcTestTextReturnsInitialValueForString()
{
self::assertSame(
'',
$this->subject->getNcTestText()
);
}
/**
* @test
*/
public function setNcTestTextForStringSetsNcTestText()
{
$this->subject->setNcTestText('Conceived at T3CON10');
self::assertAttributeEquals(
'Conceived at T3CON10',
'ncTestText',
$this->subject
);
}
/**
* @test
*/
public function getNcTestRichTextReturnsInitialValueForString()
{
self::assertSame(
'',
$this->subject->getNcTestRichText()
);
}
/**
* @test
*/
public function setNcTestRichTextForStringSetsNcTestRichText()
{
$this->subject->setNcTestRichText('Conceived at T3CON10');
self::assertAttributeEquals(
'Conceived at T3CON10',
'ncTestRichText',
$this->subject
);
}
/**
* @test
*/
public function getNcTestPasswordReturnsInitialValueForString()
{
self::assertSame(
'',
$this->subject->getNcTestPassword()
);
}
/**
* @test
*/
public function setNcTestPasswordForStringSetsNcTestPassword()
{
$this->subject->setNcTestPassword('Conceived at T3CON10');
self::assertAttributeEquals(
'Conceived at T3CON10',
'ncTestPassword',
$this->subject
);
}
/**
* @test
*/
public function getNcTestIntengerReturnsInitialValueForInt()
{
}
/**
* @test
*/
public function setNcTestIntengerForIntSetsNcTestIntenger()
{
}
/**
* @test
*/
public function getNcTestFloatingPointReturnsInitialValueForFloat()
{
self::assertSame(
0.0,
$this->subject->getNcTestFloatingPoint()
);
}
/**
* @test
*/
public function setNcTestFloatingPointForFloatSetsNcTestFloatingPoint()
{
$this->subject->setNcTestFloatingPoint(3.14159265);
self::assertAttributeEquals(
3.14159265,
'ncTestFloatingPoint',
$this->subject,
'',
0.000000001
);
}
/**
* @test
*/
public function getNcTestBooleanReturnsInitialValueForBool()
{
self::assertSame(
false,
$this->subject->getNcTestBoolean()
);
}
/**
* @test
*/
public function setNcTestBooleanForBoolSetsNcTestBoolean()
{
$this->subject->setNcTestBoolean(true);
self::assertAttributeEquals(
true,
'ncTestBoolean',
$this->subject
);
}
/**
* @test
*/
public function getNcTestDateReturnsInitialValueForDateTime()
{
self::assertEquals(
null,
$this->subject->getNcTestDate()
);
}
/**
* @test
*/
public function setNcTestDateForDateTimeSetsNcTestDate()
{
$dateTimeFixture = new \DateTime();
$this->subject->setNcTestDate($dateTimeFixture);
self::assertAttributeEquals(
$dateTimeFixture,
'ncTestDate',
$this->subject
);
}
/**
* @test
*/
public function getNcTestDateTimeReturnsInitialValueForDateTime()
{
self::assertEquals(
null,
$this->subject->getNcTestDateTime()
);
}
/**
* @test
*/
public function setNcTestDateTimeForDateTimeSetsNcTestDateTime()
{
$dateTimeFixture = new \DateTime();
$this->subject->setNcTestDateTime($dateTimeFixture);
self::assertAttributeEquals(
$dateTimeFixture,
'ncTestDateTime',
$this->subject
);
}
/**
* @test
*/
public function getNcTestDateTimestampReturnsInitialValueForDateTime()
{
self::assertEquals(
null,
$this->subject->getNcTestDateTimestamp()
);
}
/**
* @test
*/
public function setNcTestDateTimestampForDateTimeSetsNcTestDateTimestamp()
{
$dateTimeFixture = new \DateTime();
$this->subject->setNcTestDateTimestamp($dateTimeFixture);
self::assertAttributeEquals(
$dateTimeFixture,
'ncTestDateTimestamp',
$this->subject
);
}
/**
* @test
*/
public function getNcTestTimeReturnsInitialValueForInt()
{
}
/**
* @test
*/
public function setNcTestTimeForIntSetsNcTestTime()
{
}
/**
* @test
*/
public function getNcTestTimeSecReturnsInitialValueForInt()
{
}
/**
* @test
*/
public function setNcTestTimeSecForIntSetsNcTestTimeSec()
{
}
/**
* @test
*/
public function getNcTestSelectlistReturnsInitialValueForInt()
{
}
/**
* @test
*/
public function setNcTestSelectlistForIntSetsNcTestSelectlist()
{
}
/**
* @test
*/
public function getNcTestFileReturnsInitialValueForFileReference()
{
self::assertEquals(
null,
$this->subject->getNcTestFile()
);
}
/**
* @test
*/
public function setNcTestFileForFileReferenceSetsNcTestFile()
{
$fileReferenceFixture = new \TYPO3\CMS\Extbase\Domain\Model\FileReference();
$this->subject->setNcTestFile($fileReferenceFixture);
self::assertAttributeEquals(
$fileReferenceFixture,
'ncTestFile',
$this->subject
);
}
/**
* @test
*/
public function getNcTestImageReturnsInitialValueForFileReference()
{
self::assertEquals(
null,
$this->subject->getNcTestImage()
);
}
/**
* @test
*/
public function setNcTestImageForFileReferenceSetsNcTestImage()
{
$fileReferenceFixture = new \TYPO3\CMS\Extbase\Domain\Model\FileReference();
$this->subject->setNcTestImage($fileReferenceFixture);
self::assertAttributeEquals(
$fileReferenceFixture,
'ncTestImage',
$this->subject
);
}
/**
* @test
*/
public function getNcTestStringRequiredReturnsInitialValueForString()
{
self::assertSame(
'',
$this->subject->getNcTestStringRequired()
);
}
/**
* @test
*/
public function setNcTestStringRequiredForStringSetsNcTestStringRequired()
{
$this->subject->setNcTestStringRequired('Conceived at T3CON10');
self::assertAttributeEquals(
'Conceived at T3CON10',
'ncTestStringRequired',
$this->subject
);
}
}
<?php
/***************************************************************
* Extension Manager/Repository config file for ext: "anctestextension"
*
* Auto generated by Extension Builder 2017-11-08
*
* Manual updates:
* Only the data in the array - anything else is removed by next write.
* "version" and "dependencies" must not be touched!
***************************************************************/
$EM_CONF[$_EXTKEY] = [
'title' => 'anc test extension',
'description' => '',
'category' => 'plugin',
'author' => '',
'author_email' => '',
'state' => 'alpha',
'internal' => '',
'uploadfolder' => '1',
'createDirs' => '',
'clearCacheOnLoad' => 0,
'version' => '1.0.0',
'constraints' => [
'depends' => [
'typo3' => '7.6.0-7.6.99',
],
'conflicts' => [],
'suggests' => [],
],
];
ext_icon.gif

177 Bytes

<?php
defined('TYPO3_MODE') || die('Access denied.');
call_user_func(
function($extKey)
{
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addStaticFile($extKey, 'Configuration/TypoScript', 'anc test extension');
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addLLrefForTCAdescr('tx_anctestextension_domain_model_nctestobj', 'EXT:anctestextension/Resources/Private/Language/locallang_csh_tx_anctestextension_domain_model_nctestobj.xlf');
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::allowTableOnStandardPages('tx_anctestextension_domain_model_nctestobj');
},
$_EXTKEY
);
#
# Table structure for table 'tx_anctestextension_domain_model_nctestobj'
#
CREATE TABLE tx_anctestextension_domain_model_nctestobj (
uid int(11) NOT NULL auto_increment,
pid int(11) DEFAULT '0' NOT NULL,
nc_test_string varchar(255) DEFAULT '' NOT NULL,
nc_test_text text NOT NULL,
nc_test_rich_text text NOT NULL,
nc_test_password varchar(255) DEFAULT '' NOT NULL,
nc_test_intenger int(11) DEFAULT '0' NOT NULL,
nc_test_floating_point double(11,2) DEFAULT '0.00' NOT NULL,
nc_test_boolean tinyint(1) unsigned DEFAULT '0' NOT NULL,
nc_test_date date DEFAULT '0000-00-00',
nc_test_date_time datetime DEFAULT '0000-00-00 00:00:00',
nc_test_date_timestamp int(11) DEFAULT '0' NOT NULL,
nc_test_time int(11) DEFAULT '0' NOT NULL,
nc_test_time_sec int(11) DEFAULT '0' NOT NULL,
nc_test_selectlist int(11) DEFAULT '0' NOT NULL,
nc_test_file int(11) unsigned NOT NULL default '0',
nc_test_image int(11) unsigned NOT NULL default '0',
nc_test_string_required varchar(255) DEFAULT '' NOT NULL,
tstamp int(11) unsigned DEFAULT '0' NOT NULL,
crdate int(11) unsigned DEFAULT '0' NOT NULL,
cruser_id int(11) unsigned DEFAULT '0' NOT NULL,
deleted tinyint(4) unsigned DEFAULT '0' NOT NULL,
hidden tinyint(4) unsigned DEFAULT '0' NOT NULL,
starttime int(11) unsigned DEFAULT '0' NOT NULL,
endtime int(11) unsigned DEFAULT '0' NOT NULL,
t3ver_oid int(11) DEFAULT '0' NOT NULL,
t3ver_id int(11) DEFAULT '0' NOT NULL,
t3ver_wsid int(11) DEFAULT '0' NOT NULL,
t3ver_label varchar(255) DEFAULT '' NOT NULL,
t3ver_state tinyint(4) DEFAULT '0' NOT NULL,
t3ver_stage int(11) DEFAULT '0' NOT NULL,
t3ver_count int(11) DEFAULT '0' NOT NULL,
t3ver_tstamp int(11) DEFAULT '0' NOT NULL,
t3ver_move_id int(11) DEFAULT '0' NOT NULL,
sys_language_uid int(11) DEFAULT '0' NOT NULL,
l10n_parent int(11) DEFAULT '0' NOT NULL,
l10n_diffsource mediumblob,
PRIMARY KEY (uid),
KEY parent (pid),
KEY t3ver_oid (t3ver_oid,t3ver_wsid),
KEY language (l10n_parent,sys_language_uid)
);
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!