Franz Holzinger

Verse of the day

So ist nun nichts Verdammliches an denen, die in Christo Jesu sind, die nicht nach dem Fleisch wandeln, sondern nach dem Geist. Denn das Gesetz des Geistes, der da lebendig macht in Christo Jesu, hat mich frei gemacht von dem Gesetz der Sünde und des Todes.
Roemer 8:1-2

© Bible Gateway's Verse of the Day


Buch: Der TYPO3 Webshop
 
 
adding fields to tt_products
 
Autor: Franz Holzinger Datum: 17-06-14 16:40:02
 
You can use the Extension Kickstarter extension to create your own extension which extends the tt_products table with more fields. No programming knowledge is necessary.

Hint:
Add the new fields into the file model/class.tx_ttproducts_table_base.php.

private $fieldClassArray = array (
'datasheet' => 'tx_ttproducts_field_datafield',
'graduated_price_uid' => 'tx_ttproducts_field_graduated_price',
'image' => 'tx_ttproducts_field_image',
'itemnumber' => 'tx_ttproducts_field_text',
'note' => 'tx_ttproducts_field_note',
'note2' => 'tx_ttproducts_field_note',
'price' => 'tx_ttproducts_field_price',
'price2' => 'tx_ttproducts_field_price',
'subtitle' => 'tx_ttproducts_field_text',
'title' => 'tx_ttproducts_field_text',
);

I think that this will do most of the job. Only the marker names and subpart marker names will need some modification in the template file. Maybe you should not name the new fields datasheet1, datasheet2 and datasheet3, because the numbers at the end of the fieldnames could create conflicts with the numbers in the markers of DATASHEET.
Use other names for the new fields:
datasheetcatalog, datasheetmanual, datasheetnote.