コード例 #1
0
/**
 * Quick Product Content Element for Isotope eCommerce and Contao Open Source CMS
 *
 * Copyright (C) 2015 Rhyme.Digital
 *
 * @package    Isotope_Quickproducts
 * @link       http://rhyme.digital
 * @license    http://opensource.org/licenses/lgpl-3.0.html
 */
\Controller::loadDataContainer('tl_module');
\Controller::loadLanguageFile('tl_module');
/**
 * Palettes
 */
$GLOBALS['TL_DCA']['tl_content']['palettes']['isotope_quick'] = '{type_legend},type,headline;{include_legend},iso_products;{config_legend},iso_listingSortField,iso_listingSortDirection,iso_cols,iso_use_quantity,iso_buttons,iso_addProductJumpTo;{template_settings},iso_gallery,iso_list_layout;{protected_legend:hide},protected;{expert_legend:hide},guests,cssID,space;{invisible_legend:hide},invisible,start,stop';
/**
 * Fields
 */
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_products'] = array('label' => &$GLOBALS['TL_LANG']['tl_content']['iso_products'], 'exclude' => true, 'inputType' => 'tableLookup', 'sql' => "blob NULL", 'eval' => array('mandatory' => true, 'doNotSaveEmpty' => true, 'tl_class' => 'clr', 'foreignTable' => 'tl_iso_product', 'fieldType' => 'checkbox', 'listFields' => array('type' => "type", 'name', 'sku'), 'searchFields' => array('name', 'alias', 'sku', 'description'), 'sqlWhere' => 'pid=0', 'searchLabel' => 'Search products'));
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_gallery'] = array('label' => &$GLOBALS['TL_LANG']['tl_content']['iso_gallery'], 'exclude' => true, 'inputType' => 'select', 'foreignKey' => \Isotope\Model\Gallery::getTable() . '.name', 'eval' => array('includeBlankOption' => true, 'chosen' => true, 'tl_class' => 'w50'), 'sql' => "int(10) unsigned NOT NULL default '0'");
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_list_layout'] = array('label' => &$GLOBALS['TL_LANG']['tl_content']['iso_list_layout'], 'exclude' => true, 'inputType' => 'select', 'options_callback' => function (\DataContainer $dc) {
    return \Isotope\Backend::getTemplates('iso_list_');
}, 'eval' => array('includeBlankOption' => true, 'tl_class' => 'w50', 'chosen' => true), 'sql' => "varchar(64) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_use_quantity'] = array('label' => &$GLOBALS['TL_LANG']['tl_content']['iso_use_quantity'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_cols'] = array('label' => &$GLOBALS['TL_LANG']['tl_content']['iso_cols'], 'exclude' => true, 'default' => 1, 'inputType' => 'text', 'eval' => array('maxlength' => 1, 'rgxp' => 'digit', 'tl_class' => 'w50'), 'sql' => "int(1) unsigned NOT NULL default '1'");
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_buttons'] = array('label' => &$GLOBALS['TL_LANG']['tl_content']['iso_buttons'], 'exclude' => true, 'inputType' => 'checkboxWizard', 'default' => array('add_to_cart'), 'options_callback' => array('Isotope\\Backend\\Module\\Callback', 'getButtons'), 'eval' => array('multiple' => true, 'tl_class' => 'clr'), 'sql' => "blob NULL");
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_listingSortField'] = array('label' => &$GLOBALS['TL_LANG']['tl_content']['iso_listingSortField'], 'exclude' => true, 'inputType' => 'select', 'options_callback' => array('Isotope\\Backend\\Module\\Callback', 'getSortingFields'), 'eval' => array('includeBlankOption' => true, 'tl_class' => 'clr w50'), 'sql' => "varchar(255) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_listingSortDirection'] = array('label' => &$GLOBALS['TL_LANG']['tl_content']['iso_listingSortDirection'], 'exclude' => true, 'default' => 'DESC', 'inputType' => 'select', 'options' => array('DESC', 'ASC'), 'reference' => &$GLOBALS['TL_LANG']['tl_content']['sortingDirection'], 'eval' => array('tl_class' => 'w50'), 'sql' => "varchar(8) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_cart_jumpTo'] = array('label' => &$GLOBALS['TL_LANG']['tl_content']['iso_cart_jumpTo'], 'exclude' => true, 'inputType' => 'pageTree', 'foreignKey' => 'tl_page.title', 'eval' => array('fieldType' => 'radio', 'tl_class' => 'clr'), 'explanation' => 'jumpTo', 'sql' => "int(10) unsigned NOT NULL default '0'", 'relation' => array('type' => 'hasOne', 'load' => 'lazy'));
$GLOBALS['TL_DCA']['tl_content']['fields']['iso_addProductJumpTo'] = $GLOBALS['TL_DCA']['tl_module']['fields']['iso_addProductJumpTo'];
コード例 #2
0
ファイル: tl_iso_gallery.php プロジェクト: rpquadrat/core
<?php

/**
 * Isotope eCommerce for Contao Open Source CMS
 *
 * Copyright (C) 2009-2014 terminal42 gmbh & Isotope eCommerce Workgroup
 *
 * @package    Isotope
 * @link       http://isotopeecommerce.org
 * @license    http://opensource.org/licenses/lgpl-3.0.html
 */
/**
 * Table tl_iso_gallery
 */
$GLOBALS['TL_DCA']['tl_iso_gallery'] = array('config' => array('dataContainer' => 'Table', 'enableVersioning' => true, 'closed' => true, 'onload_callback' => array(array('Isotope\\Backend', 'initializeSetupModule')), 'sql' => array('keys' => array('id' => 'primary'))), 'list' => array('sorting' => array('mode' => 1, 'flag' => 1, 'fields' => array('name'), 'panelLayout' => 'filter;search,limit'), 'label' => array('fields' => array('name', 'type'), 'format' => '%s <span style="color:#b3b3b3; padding-left:3px;">[%s]</span>'), 'global_operations' => array('back' => array('label' => &$GLOBALS['TL_LANG']['MSC']['backBT'], 'href' => 'mod=&table=', 'class' => 'header_back', 'attributes' => 'onclick="Backend.getScrollOffset();"'), 'new' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['new'], 'href' => 'act=create', 'class' => 'header_new', 'attributes' => 'onclick="Backend.getScrollOffset();"'), 'all' => array('label' => &$GLOBALS['TL_LANG']['MSC']['all'], 'href' => 'act=select', 'class' => 'header_edit_all', 'attributes' => 'onclick="Backend.getScrollOffset();" accesskey="e"')), 'operations' => array('edit' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['edit'], 'href' => 'act=edit', 'icon' => 'edit.gif'), 'copy' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['copy'], 'href' => 'act=copy', 'icon' => 'copy.gif'), 'delete' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['delete'], 'href' => 'act=delete', 'icon' => 'delete.gif', 'attributes' => 'onclick="if (!confirm(\'' . $GLOBALS['TL_LANG']['MSC']['deleteConfirm'] . '\')) return false; Backend.getScrollOffset();"'), 'show' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['show'], 'href' => 'act=show', 'icon' => 'show.gif'))), 'palettes' => array('__selector__' => array('type', 'anchor'), 'default' => '{name_legend},name,type', 'standard' => '{name_legend},name,type,anchor,placeholder;{size_legend},main_size,gallery_size;{watermark_legend:hide},main_watermark_image,main_watermark_position,gallery_watermark_image,gallery_watermark_position;{template_legend:hide},customTpl', 'standardlightbox' => '{name_legend},name,type,anchor,placeholder;{size_legend},main_size,gallery_size;{lightbox_legend},lightbox_template,lightbox_size;{watermark_legend:hide},main_watermark_image,main_watermark_position,gallery_watermark_image,gallery_watermark_position,lightbox_watermark_image,lightbox_watermark_position;{template_legend:hide},customTpl', 'inline' => '{name_legend},name,type,placeholder;{size_legend},main_size,gallery_size;{watermark_legend:hide},main_watermark_image,main_watermark_position,gallery_watermark_image,gallery_watermark_position;{template_legend:hide},customTpl'), 'fields' => array('id' => array('sql' => "int(10) unsigned NOT NULL auto_increment"), 'tstamp' => array('sql' => "int(10) unsigned NOT NULL default '0'"), 'name' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['name'], 'exclude' => true, 'search' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'tl_class' => 'w50'), 'sql' => "varchar(255) NOT NULL default ''"), 'type' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['type'], 'exclude' => true, 'filter' => true, 'default' => 'standard', 'inputType' => 'select', 'options_callback' => function () {
    return \Isotope\Model\Gallery::getModelTypeOptions();
}, 'eval' => array('helpwizard' => true, 'submitOnChange' => true, 'chosen' => true, 'tl_class' => 'w50'), 'sql' => "varchar(64) NOT NULL default ''"), 'anchor' => array('label' => $GLOBALS['TL_LANG']['tl_iso_gallery']['anchor'], 'exclude' => true, 'inputType' => 'radio', 'options' => array('none', 'reader', 'lightbox'), 'reference' => &$GLOBALS['TL_LANG']['tl_iso_gallery'], 'eval' => array('mandatory' => true, 'submitOnChange' => true, 'tl_class' => 'clr w50 w50h'), 'sql' => "varchar(8) NOT NULL default ''"), 'placeholder' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['placeholder'], 'exclude' => true, 'inputType' => 'fileTree', 'eval' => array('fieldType' => 'radio', 'files' => true, 'filesOnly' => true, 'extensions' => $GLOBALS['TL_CONFIG']['validImageTypes'], 'tl_class' => 'w50 w50h'), 'sql' => "binary(16) NULL"), 'main_size' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['main_size'], 'exclude' => true, 'inputType' => 'imageSize', 'options' => $GLOBALS['TL_CROP'], 'reference' => &$GLOBALS['TL_LANG']['MSC'], 'eval' => array('rgxp' => 'digit', 'nospace' => true, 'helpwizard' => true, 'tl_class' => 'w50'), 'sql' => "varchar(64) NOT NULL default ''"), 'gallery_size' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['gallery_size'], 'exclude' => true, 'inputType' => 'imageSize', 'options' => $GLOBALS['TL_CROP'], 'reference' => &$GLOBALS['TL_LANG']['MSC'], 'eval' => array('rgxp' => 'digit', 'nospace' => true, 'helpwizard' => true, 'tl_class' => 'w50'), 'sql' => "varchar(64) NOT NULL default ''"), 'lightbox_template' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['lightbox_template'], 'exclude' => true, 'inputType' => 'checkboxWizard', 'options_callback' => function () {
    // Do not use \Isotope\Backend::getTemplates() here, as they cannot be selected in a page layout!
    return array_merge(\Controller::getTemplateGroup('moo_'), \Controller::getTemplateGroup('j_'));
}, 'eval' => array('mandatory' => true, 'multiple' => true, 'tl_class' => 'w50 w50h'), 'sql' => "blob NULL"), 'lightbox_size' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['lightbox_size'], 'exclude' => true, 'inputType' => 'imageSize', 'options' => $GLOBALS['TL_CROP'], 'reference' => &$GLOBALS['TL_LANG']['MSC'], 'eval' => array('rgxp' => 'digit', 'nospace' => true, 'helpwizard' => true, 'tl_class' => 'w50'), 'sql' => "varchar(64) NOT NULL default ''"), 'main_watermark_image' => array('label' => $GLOBALS['TL_LANG']['tl_iso_gallery']['main_watermark_image'], 'exclude' => true, 'inputType' => 'fileTree', 'eval' => array('fieldType' => 'radio', 'files' => true, 'filesOnly' => true, 'extensions' => $GLOBALS['TL_CONFIG']['validImageTypes'], 'tl_class' => 'clr w50 w50h'), 'sql' => "binary(16) NULL"), 'main_watermark_position' => array('label' => $GLOBALS['TL_LANG']['tl_iso_gallery']['main_watermark_position'], 'exclude' => true, 'inputType' => 'select', 'options' => array('left_top', 'center_top', 'right_top', 'left_center', 'center_center', 'right_center', 'left_bottom', 'center_bottom', 'right_bottom'), 'reference' => $GLOBALS['TL_LANG']['MSC'], 'eval' => array('tl_class' => 'w50'), 'sql' => "varchar(16) NOT NULL default ''"), 'gallery_watermark_image' => array('label' => $GLOBALS['TL_LANG']['tl_iso_gallery']['gallery_watermark_image'], 'exclude' => true, 'inputType' => 'fileTree', 'eval' => array('fieldType' => 'radio', 'files' => true, 'filesOnly' => true, 'extensions' => $GLOBALS['TL_CONFIG']['validImageTypes'], 'tl_class' => 'clr w50 w50h'), 'sql' => "binary(16) NULL"), 'gallery_watermark_position' => array('label' => $GLOBALS['TL_LANG']['tl_iso_gallery']['gallery_watermark_position'], 'exclude' => true, 'inputType' => 'select', 'options' => array('left_top', 'center_top', 'right_top', 'left_center', 'center_center', 'right_center', 'left_bottom', 'center_bottom', 'right_bottom'), 'reference' => $GLOBALS['TL_LANG']['MSC'], 'eval' => array('tl_class' => 'w50'), 'sql' => "varchar(16) NOT NULL default ''"), 'lightbox_watermark_image' => array('label' => $GLOBALS['TL_LANG']['tl_iso_gallery']['lightbox_watermark_image'], 'exclude' => true, 'inputType' => 'fileTree', 'eval' => array('fieldType' => 'radio', 'files' => true, 'filesOnly' => true, 'extensions' => $GLOBALS['TL_CONFIG']['validImageTypes'], 'tl_class' => 'clr w50 w50h'), 'sql' => "binary(16) NULL"), 'lightbox_watermark_position' => array('label' => $GLOBALS['TL_LANG']['tl_iso_gallery']['lightbox_watermark_position'], 'exclude' => true, 'inputType' => 'select', 'options' => array('left_top', 'center_top', 'right_top', 'left_center', 'center_center', 'right_center', 'left_bottom', 'center_bottom', 'right_bottom'), 'reference' => $GLOBALS['TL_LANG']['MSC'], 'eval' => array('tl_class' => 'w50'), 'sql' => "varchar(16) NOT NULL default ''"), 'customTpl' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_gallery']['customTpl'], 'exclude' => true, 'inputType' => 'select', 'options_callback' => function () {
    return \Isotope\Backend::getTemplates('iso_gallery_');
}, 'eval' => array('includeBlankOption' => true, 'chosen' => true, 'tl_class' => 'w50'), 'sql' => "varchar(64) NOT NULL default ''")));
コード例 #3
0
<?php

/**
 * Isotope eCommerce for Contao Open Source CMS
 *
 * Copyright (C) 2009-2014 terminal42 gmbh & Isotope eCommerce Workgroup
 *
 * @package    Isotope
 * @link       http://isotopeecommerce.org
 * @license    http://opensource.org/licenses/lgpl-3.0.html
 */
/**
 * Table tl_iso_producttype
 */
$GLOBALS['TL_DCA']['tl_iso_producttype'] = array('config' => array('dataContainer' => 'Table', 'enableVersioning' => true, 'closed' => true, 'onload_callback' => array(array('Isotope\\Backend', 'initializeSetupModule'), array('Isotope\\Backend\\ProductType\\Callback', 'checkPermission'), array('Isotope\\Backend\\ProductType\\Permission', 'check')), 'sql' => array('keys' => array('id' => 'primary', 'variants' => 'index'))), 'list' => array('sorting' => array('mode' => 1, 'fields' => array('name'), 'flag' => 1, 'panelLayout' => 'filter;search,limit'), 'label' => array('fields' => array('name', 'variants', 'downloads', 'shipping_exempt'), 'showColumns' => true, 'label_callback' => array('\\Isotope\\Backend\\ProductType\\Label', 'generate')), 'global_operations' => array('back' => array('label' => &$GLOBALS['TL_LANG']['MSC']['backBT'], 'href' => 'mod=&table=', 'class' => 'header_back', 'attributes' => 'onclick="Backend.getScrollOffset();"'), 'new' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['new'], 'href' => 'act=create', 'class' => 'header_new', 'attributes' => 'onclick="Backend.getScrollOffset();"'), 'all' => array('label' => &$GLOBALS['TL_LANG']['MSC']['all'], 'href' => 'act=select', 'class' => 'header_edit_all', 'attributes' => 'onclick="Backend.getScrollOffset();"')), 'operations' => array('edit' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['edit'], 'href' => 'act=edit', 'icon' => 'edit.gif'), 'copy' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['copy'], 'href' => 'act=copy', 'icon' => 'copy.gif', 'button_callback' => array('Isotope\\Backend\\ProductType\\Callback', 'copyProductType')), 'delete' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['delete'], 'href' => 'act=delete', 'icon' => 'delete.gif', 'attributes' => 'onclick="if (!confirm(\'' . $GLOBALS['TL_LANG']['MSC']['deleteConfirm'] . '\')) return false; Backend.getScrollOffset();"', 'button_callback' => array('Isotope\\Backend\\ProductType\\Callback', 'deleteProductType')), 'show' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['show'], 'href' => 'act=show', 'icon' => 'show.gif'))), 'palettes' => array('__selector__' => array('class', 'prices', 'variants'), 'default' => '{name_legend},name,class', 'standard' => '{name_legend},name,class,fallback;{description_legend:hide},description;{prices_legend:hide},prices;{template_legend},list_template,reader_template,list_gallery,reader_gallery;{attributes_legend},attributes;{variants_legend:hide},variants;{expert_legend:hide},shipping_exempt,downloads'), 'subpalettes' => array('prices' => 'show_price_tiers', 'variants' => 'variant_attributes,force_variant_options'), 'fields' => array('id' => array('sql' => "int(10) unsigned NOT NULL auto_increment"), 'tstamp' => array('sql' => "int(10) unsigned NOT NULL default '0'"), 'name' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['name'], 'exclude' => true, 'search' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'tl_class' => 'w50'), 'sql' => "varchar(255) NOT NULL default ''"), 'class' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['class'], 'exclude' => true, 'filter' => true, 'inputType' => 'select', 'default' => 'standard', 'options_callback' => function () {
    return \Isotope\Model\Product::getModelTypeOptions();
}, 'eval' => array('mandatory' => true, 'submitOnChange' => true, 'helpwizard' => true, 'tl_class' => 'w50'), 'sql' => "varchar(64) NOT NULL default ''"), 'fallback' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['fallback'], 'exclude' => true, 'filter' => true, 'inputType' => 'checkbox', 'eval' => array('fallback' => true, 'tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''"), 'description' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['description'], 'exclude' => true, 'inputType' => 'textarea', 'eval' => array('style' => 'height:80px', 'tl_class' => 'clr'), 'sql' => "text NULL"), 'prices' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['prices'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('submitOnChange' => true, 'tl_class' => 'clr'), 'sql' => "char(1) NOT NULL default ''"), 'show_price_tiers' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['show_price_tiers'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''"), 'list_template' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['list_template'], 'exclude' => true, 'inputType' => 'select', 'default' => 'iso_list_default', 'options_callback' => function (\DataContainer $dc) {
    return \Isotope\Backend::getTemplates('iso_list_');
}, 'eval' => array('mandatory' => true, 'tl_class' => 'w50', 'chosen' => true), 'sql' => "varchar(255) NOT NULL default ''"), 'reader_template' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['reader_template'], 'exclude' => true, 'inputType' => 'select', 'default' => 'iso_reader_default', 'options_callback' => function (\DataContainer $dc) {
    return \Isotope\Backend::getTemplates('iso_reader_');
}, 'eval' => array('mandatory' => true, 'tl_class' => 'w50', 'chosen' => true), 'sql' => "varchar(255) NOT NULL default ''"), 'list_gallery' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['list_gallery'], 'exclude' => true, 'inputType' => 'select', 'foreignKey' => \Isotope\Model\Gallery::getTable() . '.name', 'eval' => array('mandatory' => true, 'includeBlankOption' => true, 'chosen' => true, 'tl_class' => 'w50'), 'sql' => "int(10) unsigned NOT NULL default '0'"), 'reader_gallery' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['reader_gallery'], 'exclude' => true, 'inputType' => 'select', 'foreignKey' => \Isotope\Model\Gallery::getTable() . '.name', 'eval' => array('mandatory' => true, 'includeBlankOption' => true, 'chosen' => true, 'tl_class' => 'w50'), 'sql' => "int(10) unsigned NOT NULL default '0'"), 'attributes' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['attributes'], 'exclude' => true, 'default' => array(array('name' => 'type', 'enabled' => 1), array('name' => 'pages', 'enabled' => 1), array('name' => 'alias', 'enabled' => 1), array('name' => 'sku', 'enabled' => 1), array('name' => 'name', 'enabled' => 1), array('name' => 'teaser', 'enabled' => 1), array('name' => 'description', 'enabled' => 1), array('name' => 'price', 'enabled' => 1), array('name' => 'images', 'enabled' => 1), array('name' => 'published', 'enabled' => 1), array('name' => 'start', 'enabled' => 1), array('name' => 'stop', 'enabled' => 1)), 'inputType' => 'multiColumnWizard', 'eval' => array('tl_class' => 'clr', 'columnsCallback' => array('Isotope\\Backend\\ProductType\\AttributeWizard', 'getColumns'), 'buttons' => array('copy' => false, 'delete' => false)), 'sql' => 'blob NULL', 'load_callback' => array(array('Isotope\\Backend\\ProductType\\AttributeWizard', 'load')), 'save_callback' => array(array('Isotope\\Backend\\ProductType\\AttributeWizard', 'save'))), 'variants' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['variants'], 'exclude' => true, 'filter' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'clr', 'submitOnChange' => true), 'sql' => "char(1) NOT NULL default ''"), 'variant_attributes' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['variant_attributes'], 'exclude' => true, 'inputType' => 'multiColumnWizard', 'eval' => array('tl_class' => 'clr', 'columnsCallback' => array('Isotope\\Backend\\ProductType\\AttributeWizard', 'getColumns'), 'buttons' => array('copy' => false, 'delete' => false)), 'sql' => 'blob NULL', 'load_callback' => array(array('Isotope\\Backend\\ProductType\\AttributeWizard', 'load')), 'save_callback' => array(array('Isotope\\Backend\\ProductType\\Callback', 'validateVariantAttributes'), array('Isotope\\Backend\\ProductType\\AttributeWizard', 'save'))), 'force_variant_options' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['force_variant_options'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'clr'), 'sql' => "char(1) NOT NULL default ''"), 'shipping_exempt' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['shipping_exempt'], 'exclude' => true, 'filter' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''"), 'downloads' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_producttype']['downloads'], 'exclude' => true, 'filter' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''")));
コード例 #4
0
 /**
  * Return filter templates as array
  * @param DataContainer
  * @return array
  */
 public function getFilterTemplates()
 {
     return \Isotope\Backend::getTemplates('iso_filter_');
 }
コード例 #5
0
ファイル: Callback.php プロジェクト: Aziz-JH/core
 /**
  * Return filter templates as array
  * @param DataContainer
  * @return array
  */
 public function getFilterTemplates(\DataContainer $dc)
 {
     $intPid = $dc->activeRecord->pid;
     if (\Input::get('act') == 'overrideAll') {
         $intPid = \Input::get('id');
     }
     return \Isotope\Backend::getTemplates('iso_filter_', $intPid);
 }
コード例 #6
0
ファイル: tl_module.php プロジェクト: Aziz-JH/core
 */
$GLOBALS['TL_DCA']['tl_module']['subpalettes']['iso_enableLimit'] = 'iso_perPage';
$GLOBALS['TL_DCA']['tl_module']['subpalettes']['iso_emptyMessage'] = 'iso_noProducts';
$GLOBALS['TL_DCA']['tl_module']['subpalettes']['iso_emptyFilter'] = 'iso_noFilter';
/**
 * Add fields to tl_module
 */
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_list_layout'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_list_layout'], 'exclude' => true, 'inputType' => 'select', 'options_callback' => function (\DataContainer $dc) {
    return \Isotope\Backend::getTemplates('iso_list_');
}, 'eval' => array('includeBlankOption' => true, 'tl_class' => 'w50', 'chosen' => true), 'sql' => "varchar(64) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_reader_layout'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_reader_layout'], 'exclude' => true, 'inputType' => 'select', 'options_callback' => function (\DataContainer $dc) {
    return \Isotope\Backend::getTemplates('iso_reader_');
}, 'eval' => array('includeBlankOption' => true, 'chosen' => true, 'tl_class' => 'w50'), 'sql' => "varchar(64) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_gallery'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_gallery'], 'exclude' => true, 'inputType' => 'select', 'foreignKey' => \Isotope\Model\Gallery::getTable() . '.name', 'eval' => array('includeBlankOption' => true, 'chosen' => true, 'tl_class' => 'w50'), 'sql' => "int(10) unsigned NOT NULL default '0'");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_collectionTpl'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_collectionTpl'], 'exclude' => true, 'inputType' => 'select', 'options_callback' => function (\DataContainer $dc) {
    return \Isotope\Backend::getTemplates('iso_collection_');
}, 'eval' => array('mandatory' => true, 'chosen' => true, 'tl_class' => 'w50'), 'sql' => "varchar(64) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_filterTpl'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_filterTpl'], 'exclude' => true, 'default' => 'iso_filter_default', 'inputType' => 'select', 'options_callback' => array('Isotope\\Backend\\Module\\Callback', 'getFilterTemplates'), 'eval' => array('mandatory' => true, 'tl_class' => 'w50', 'chosen' => true), 'sql' => "varchar(64) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_jump_first'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_jump_first'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_hide_list'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_hide_list'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_use_quantity'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_use_quantity'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_display404Page'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_display404Page'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_checkout_method'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_checkout_method'], 'exclude' => true, 'inputType' => 'radio', 'default' => 'member', 'options' => array('member', 'guest', 'both'), 'reference' => &$GLOBALS['TL_LANG']['tl_module']['iso_checkout_method_ref'], 'eval' => array('mandatory' => true, 'submitOnChange' => true), 'sql' => "varchar(10) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_login_jumpTo'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_login_jumpTo'], 'exclude' => true, 'inputType' => 'pageTree', 'foreignKey' => 'tl_page.title', 'eval' => array('fieldType' => 'radio', 'mandatory' => true, 'tl_class' => 'clr'), 'explanation' => 'jumpTo', 'sql' => "int(10) unsigned NOT NULL default '0'", 'relation' => array('type' => 'hasOne', 'load' => 'lazy'));
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_loginRequired'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_loginRequired'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('tl_class' => 'w50'), 'sql' => "char(1) NOT NULL default ''");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_addProductJumpTo'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_addProductJumpTo'], 'exclude' => true, 'inputType' => 'pageTree', 'foreignKey' => 'tl_page.title', 'eval' => array('fieldType' => 'radio', 'tl_class' => 'clr'), 'explanation' => 'jumpTo', 'sql' => "int(10) unsigned NOT NULL default '0'", 'relation' => array('type' => 'hasOne', 'load' => 'lazy'));
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_cols'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_cols'], 'exclude' => true, 'default' => 1, 'inputType' => 'text', 'eval' => array('maxlength' => 1, 'rgxp' => 'digit', 'tl_class' => 'w50'), 'sql' => "int(1) unsigned NOT NULL default '1'");
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_config_id'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_config_id'], 'exclude' => true, 'inputType' => 'select', 'foreignKey' => \Isotope\Model\Config::getTable() . '.name', 'eval' => array('includeBlankOption' => true, 'mandatory' => true, 'tl_class' => 'w50'), 'sql' => "int(10) unsigned NOT NULL default '0'", 'relation' => array('type' => 'hasOne', 'load' => 'lazy'));
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_config_ids'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_config_ids'], 'exclude' => true, 'inputType' => 'checkboxWizard', 'foreignKey' => \Isotope\Model\Config::getTable() . '.name', 'eval' => array('multiple' => true, 'mandatory' => true, 'tl_class' => 'clr'), 'sql' => "blob NULL", 'relation' => array('type' => 'hasMany', 'load' => 'lazy'));
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_payment_modules'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_payment_modules'], 'exclude' => true, 'inputType' => 'checkboxWizard', 'foreignKey' => \Isotope\Model\Payment::getTable() . '.name', 'options_callback' => array('Isotope\\Backend\\Module\\Callback', 'getPaymentModules'), 'eval' => array('multiple' => true), 'sql' => "blob NULL", 'relation' => array('type' => 'hasMany', 'load' => 'lazy'));
$GLOBALS['TL_DCA']['tl_module']['fields']['iso_shipping_modules'] = array('label' => &$GLOBALS['TL_LANG']['tl_module']['iso_shipping_modules'], 'exclude' => true, 'inputType' => 'checkboxWizard', 'foreignKey' => \Isotope\Model\Shipping::getTable() . '.name', 'options_callback' => array('Isotope\\Backend\\Module\\Callback', 'getShippingModules'), 'eval' => array('multiple' => true), 'sql' => "blob NULL", 'relation' => array('type' => 'hasMany', 'load' => 'lazy'));