Commit f4d05419 authored by Sebastian Kotte's avatar Sebastian Kotte
Browse files

Merge branch '15-add-logos-to-membership-2' into 'master'

Resolve "Add logos to membership"

Closes #15

See merge request t3o/t3o_membership!6
parents 98c1ed2b 4b2d1bc9
......@@ -120,6 +120,13 @@ class Member extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity
*/
protected $membership;
/**
* logo
*
* @var \TYPO3\CMS\Extbase\Domain\Model\FileReference
*/
protected $logo;
/**
* Returns the name
*
......@@ -379,4 +386,25 @@ class Member extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity
$this->membership = $membership;
}
/**
* Returns the logo
*
* @return \TYPO3\CMS\Extbase\Domain\Model\FileReference $logo
*/
public function getLogo()
{
return $this->logo;
}
/**
* Sets the logo
*
* @param \TYPO3\CMS\Extbase\Domain\Model\FileReference $logo
* @return void
*/
public function setLogo(\TYPO3\CMS\Extbase\Domain\Model\FileReference $logo)
{
$this->logo = $logo;
}
}
......@@ -27,10 +27,10 @@ $tca = array(
'iconfile' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extRelPath('t3o_membership') . 'Resources/Public/Icons/tx_t3omembership_domain_model_member.gif'
),
'interface' => array(
'showRecordFieldList' => 'sys_language_uid, l10n_parent, l10n_diffsource, hidden, name, firstname, lastname, external_id, end_date, address, zip, city, country, email, invoice_email, url, membership',
'showRecordFieldList' => 'sys_language_uid, l10n_parent, l10n_diffsource, hidden, name, firstname, lastname, external_id, end_date, address, zip, city, country, email, invoice_email, url, membership, logo',
),
'types' => array(
'1' => array('showitem' => 'sys_language_uid;;;;1-1-1, l10n_parent, l10n_diffsource, hidden;;1, name, firstname, lastname, external_id, subscription_no, end_date, address, zip, city, country, email, invoice_email, url, membership,--div--;LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:tabs.access,starttime, endtime'),
'1' => array('showitem' => 'sys_language_uid;;;;1-1-1, l10n_parent, l10n_diffsource, hidden;;1, name, firstname, lastname, external_id, subscription_no, end_date, address, zip, city, country, email, invoice_email, url, membership, logo,--div--;LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:tabs.access,starttime, endtime'),
),
'palettes' => array(
'1' => array('showitem' => ''),
......@@ -235,6 +235,33 @@ $tca = array(
'maxitems' => 1,
),
),
'logo' => array(
'exclude' => 0,
'label' => 'LLL:EXT:t3o_membership/Resources/Private/Language/locallang_db.xlf:tx_t3omembership_domain_model_member.logo',
'config' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getFileFieldTCAConfig(
'image',
array(
'appearance' => array(
'createNewRelationLinkTitle' =>
'LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:images.addFileReference'
),
'foreign_types' => array(
'0' => array(
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
),
\TYPO3\CMS\Core\Resource\File::FILETYPE_IMAGE => array(
'showitem' => '
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
),
),
'maxitems' => 1
),
'svg'
),
),
),
);
......
......@@ -49,6 +49,9 @@
<trans-unit id="tx_t3omembership_domain_model_member.membership">
<source>Membership</source>
</trans-unit>
<trans-unit id="tx_t3omembership_domain_model_member.logo">
<source>Logo</source>
</trans-unit>
<trans-unit id="tx_t3omembership_domain_model_membership">
<source>Membership</source>
......
......@@ -21,6 +21,7 @@ CREATE TABLE tx_t3omembership_domain_model_member (
lastname varchar(255) DEFAULT '' NOT NULL,
membership int(11) unsigned DEFAULT '0',
agency int(11) unsigned DEFAULT '0',
logo int(11) unsigned NOT NULL default '0',
tstamp int(11) unsigned DEFAULT '0' NOT NULL,
crdate int(11) unsigned DEFAULT '0' NOT NULL,
......
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