コード例 #1
0
ファイル: tl_module.php プロジェクト: rburch/core-1
 /**
  * Return filter templates as array
  * @param DataContainer
  * @return array
  */
 public function getFilterTemplates(DataContainer $dc)
 {
     $intPid = $dc->activeRecord->pid;
     if ($this->Input->get('act') == 'overrideAll') {
         $intPid = $this->Input->get('id');
     }
     return IsotopeBackend::getTemplates('iso_filter_', $intPid);
 }
コード例 #2
0
<?php

if (!defined('TL_ROOT')) {
    die('You can not access this file directly!');
}
/**
 * PHP version 5
 * @copyright  Copyright (C) 2013 Kirsten Roschanski
 * @author     Kirsten Roschanski <*****@*****.**>
 * @license    http://opensource.org/licenses/lgpl-3.0.html
 * @package    IsotopeInvoice 
 * @filesource https://github.com/katgirl/isotope_invoice
 */
/**
 * Table tl_iso_config
 */
// Palettes
$GLOBALS['TL_DCA']['tl_iso_config']['palettes']['default'] = str_replace('{config_legend}', '{bank_account_legend:hide},bank_name,bank_id,account_number,iban,bic;{config_legend},invoice_template', $GLOBALS['TL_DCA']['tl_iso_config']['palettes']['default']);
// Palettes
$GLOBALS['TL_DCA']['tl_iso_config']['palettes']['default'] = str_replace('vat_no', 'tax_number,vat_no,register,managing_directors', $GLOBALS['TL_DCA']['tl_iso_config']['palettes']['default']);
// Fields
$GLOBALS['TL_DCA']['tl_iso_config']['fields']['bank_name'] = array('label' => &$GLOBALS['TL_LANG']['tl_iso_config']['bank_name'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'w50'));
$GLOBALS['TL_DCA']['tl_iso_config']['fields']['bank_id'] = array('label' => &$GLOBALS['TL_LANG']['tl_iso_config']['bank_id'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'w50'));
$GLOBALS['TL_DCA']['tl_iso_config']['fields']['account_number'] = array('label' => &$GLOBALS['TL_LANG']['tl_iso_config']['account_number'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'w50'));
$GLOBALS['TL_DCA']['tl_iso_config']['fields']['iban'] = array('label' => &$GLOBALS['TL_LANG']['tl_iso_config']['iban'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'clr w50'));
$GLOBALS['TL_DCA']['tl_iso_config']['fields']['bic'] = array('label' => &$GLOBALS['TL_LANG']['tl_iso_config']['bic'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'w50'));
$GLOBALS['TL_DCA']['tl_iso_config']['fields']['tax_number'] = array('label' => &$GLOBALS['TL_LANG']['tl_iso_config']['tax_number'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'clr w50'));
$GLOBALS['TL_DCA']['tl_iso_config']['fields']['register'] = array('label' => &$GLOBALS['TL_LANG']['tl_iso_config']['register'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'w50'));
$GLOBALS['TL_DCA']['tl_iso_config']['fields']['managing_directors'] = array('label' => &$GLOBALS['TL_LANG']['tl_iso_config']['managing_directors'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'w50'));
$GLOBALS['TL_DCA']['tl_iso_config']['fields']['invoice_template'] = array('label' => &$GLOBALS['TL_LANG']['tl_iso_config']['invoice_template'], 'exclude' => true, 'inputType' => 'select', 'default' => 'iso_invoice', 'options' => IsotopeBackend::getTemplates('iso_invoice'), 'eval' => array('mandatory' => true, 'tl_class' => 'w50', 'chosen' => true));
コード例 #3
0
ファイル: tl_iso_producttypes.php プロジェクト: rburch/core-1
 /**
  * Return reader templates as array
  * @param DataContainer
  * @return array
  */
 public function getReaderTemplates(DataContainer $dc)
 {
     return IsotopeBackend::getTemplates('iso_reader_');
 }
コード例 #4
0
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this program. If not, please visit the Free
 * Software Foundation website at <http://www.gnu.org/licenses/>.
 *
 * PHP version 5
 * @copyright  Isotope eCommerce Workgroup 2009-2012
 * @author     Andreas Schempp <*****@*****.**>
 * @author     Fred Bliss <*****@*****.**>
 * @license    http://opensource.org/licenses/lgpl-3.0.html
 */
/**
 * Table tl_iso_payment_modules
 */
$GLOBALS['TL_DCA']['tl_iso_payment_modules'] = array('config' => array('dataContainer' => 'Table', 'enableVersioning' => true, 'closed' => true, 'onload_callback' => array(array('IsotopeBackend', 'initializeSetupModule'), array('tl_iso_payment_modules', 'checkPermission'), array('tl_iso_payment_modules', 'loadShippingModules'))), 'list' => array('sorting' => array('mode' => 1, 'fields' => array('name'), 'flag' => 1, 'panelLayout' => 'sort,filter;search,limit'), 'label' => array('fields' => array('name', 'type'), 'format' => '%s <span style="color:#b3b3b3; padding-left:3px;">[%s]</span>', 'label_callback' => array('IsotopeBackend', 'addPublishIcon')), '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_payment_modules']['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_payment_modules']['edit'], 'href' => 'act=edit', 'icon' => 'edit.gif'), 'copy' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['copy'], 'href' => 'act=copy', 'icon' => 'copy.gif', 'button_callback' => array('tl_iso_payment_modules', 'copyPaymentModule')), 'delete' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['delete'], 'href' => 'act=delete', 'icon' => 'delete.gif', 'attributes' => 'onclick="if (!confirm(\'' . $GLOBALS['TL_LANG']['MSC']['deleteConfirm'] . '\')) return false; Backend.getScrollOffset();"', 'button_callback' => array('tl_iso_payment_modules', 'deletePaymentModule')), 'show' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['show'], 'href' => 'act=show', 'icon' => 'show.gif'))), 'palettes' => array('__selector__' => array('type', 'protected'), 'default' => '{type_legend},name,type', 'cash' => '{type_legend},name,label,type;{note_legend:hide},note;{config_legend},new_order_status,minimum_total,maximum_total,countries,shipping_modules,product_types;{price_legend:hide},price,tax_class;{expert_legend:hide},guests,protected;{enabled_legend},enabled', 'paypal' => '{type_legend},name,label,type;{note_legend:hide},note;{config_legend},new_order_status,minimum_total,maximum_total,countries,shipping_modules,product_types;{gateway_legend},paypal_account;{price_legend:hide},price,tax_class;{template_legend},button;{expert_legend:hide},guests,protected;{enabled_legend},debug,enabled', 'paypalpayflowpro' => '{type_legend},name,label,type;{note_legend:hide},note;{config_legend},new_order_status,allowed_cc_types,requireCCV,minimum_total,maximum_total,countries,shipping_modules,product_types;{gateway_legend},payflowpro_user,payflowpro_vendor,payflowpro_partner,payflowpro_password,payflowpro_transType;{price_legend:hide},price,tax_class;{template_legend},button;{expert_legend:hide},guests,protected;{enabled_legend},debug,enabled', 'postfinance' => '{type_legend},name,label,type;{note_legend:hide},note;{config_legend},new_order_status,minimum_total,maximum_total,countries,shipping_modules,product_types;{gateway_legend},postfinance_pspid,postfinance_secret,postfinance_method;{price_legend:hide},price,tax_class;{expert_legend:hide},guests,protected;{enabled_legend},debug,enabled', 'authorizedotnet' => '{type_legend},name,label,type;{note_legend:hide},note;{config_legend},new_order_status,allowed_cc_types,requireCCV,minimum_total,maximum_total,countries,shipping_modules,product_types;{gateway_legend},authorize_login,authorize_trans_key,authorize_trans_type,authorize_delimiter;{price_legend:hide},price,tax_class;{expert_legend:hide},guests,protected;{enabled_legend},debug,enabled', 'cybersource' => '{type_legend},name,label,type;{note_legend:hide},note;{config_legend},new_order_status,minimum_total,maximum_total,countries,shipping_modules,product_types;{gateway_legend},cybersource_merchant_id,cybersource_trans_key,cybersource_trans_type;{price_legend:hide},price,tax_class;{expert_legend:hide},guests,protected;{enabled_legend},debug,enabled'), 'subpalettes' => array('protected' => 'groups'), 'fields' => array('type' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['type'], 'default' => 'cc', 'exclude' => true, 'filter' => true, 'inputType' => 'select', 'default' => 'cash', 'options_callback' => array('tl_iso_payment_modules', 'getModules'), 'reference' => &$GLOBALS['ISO_LANG']['PAY'], 'eval' => array('helpwizard' => true, 'submitOnChange' => true, 'tl_class' => 'clr')), 'name' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['name'], 'exclude' => true, 'search' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'tl_class' => 'w50')), 'label' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['label'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'w50')), 'note' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['note'], 'exclude' => true, 'inputType' => 'textarea', 'eval' => array('rte' => 'tinyMCE')), 'new_order_status' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['new_order_status'], 'exclude' => true, 'inputType' => 'select', 'default' => 'pending', 'options_callback' => array('tl_iso_payment_modules', 'getOrderStatus'), 'reference' => &$GLOBALS['TL_LANG']['ORDER'], 'eval' => array('includeBlankOption' => true, 'mandatory' => true, 'tl_class' => 'w50')), 'price' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['price'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 16, 'rgxp' => 'surcharge', 'tl_class' => 'w50')), 'tax_class' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['tax_class'], 'exclude' => true, 'filter' => true, 'inputType' => 'select', 'options' => IsotopeBackend::getTaxClassesWithSplit(), 'eval' => array('includeBlankOption' => true, 'tl_class' => 'w50')), 'allowed_cc_types' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['allowed_cc_types'], 'exclude' => true, 'filter' => true, 'inputType' => 'checkbox', 'eval' => array('multiple' => true, 'tl_class' => 'clr'), 'options_callback' => array('tl_iso_payment_modules', 'getAllowedCCTypes')), 'trans_type' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['trans_type'], 'exclude' => true, 'default' => 'capture', 'inputType' => 'select', 'options' => array('capture', 'auth'), 'eval' => array('mandatory' => true, 'tl_class' => 'w50'), 'reference' => $GLOBALS['TL_LANG']['tl_iso_payment_modules']), 'minimum_total' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['minimum_total'], 'exclude' => true, 'inputType' => 'text', 'default' => 0, 'eval' => array('maxlength' => 255, 'rgxp' => 'price', 'tl_class' => 'clr w50')), 'maximum_total' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['maximum_total'], 'exclude' => true, 'inputType' => 'text', 'default' => 0, 'eval' => array('maxlength' => 255, 'rgxp' => 'price', 'tl_class' => 'w50')), 'countries' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['countries'], 'exclude' => true, 'inputType' => 'select', 'options' => $this->getCountries(), 'eval' => array('multiple' => true, 'size' => 8, 'tl_class' => 'clr')), 'shipping_modules' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['shipping_modules'], 'exclude' => true, 'inputType' => 'select', 'eval' => array('multiple' => true, 'size' => 8, 'tl_class' => 'clr')), 'product_types' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['product_types'], 'exclude' => true, 'inputType' => 'select', 'foreignKey' => 'tl_iso_producttypes.name', 'eval' => array('multiple' => true, 'size' => 8, 'tl_class' => 'clr')), 'paypal_account' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['paypal_account'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'rgxp' => 'email', 'tl_class' => 'w50')), 'payflowpro_user' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['payflowpro_user'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'payflowpro_vendor' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['payflowpro_vendor'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'payflowpro_partner' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['payflowpro_partner'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'payflowpro_password' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['payflowpro_password'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'hideInput' => true)), 'payflowpro_transType' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['payflowpro_transType'], 'exclude' => true, 'default' => 'Sale', 'inputType' => 'select', 'options' => array('Sale', 'Authorization'), 'eval' => array('mandatory' => true, 'maxlength' => 255), 'reference' => &$GLOBALS['TL_LANG']['tl_payment_module']['payflowpro_transTypes']), 'postfinance_pspid' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['postfinance_pspid'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'postfinance_secret' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['postfinance_secret'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'w50')), 'postfinance_method' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['postfinance_method'], 'exclude' => true, 'inputType' => 'select', 'default' => 'POST', 'options' => array('POST', 'GET'), 'eval' => array('mandatory' => true, 'tl_class' => 'w50', 'tl_class' => 'w50')), 'authorize_login' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['authorize_login'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'authorize_trans_key' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['authorize_trans_key'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'authorize_trans_type' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['authorize_trans_type'], 'exclude' => true, 'default' => 'AUTH_CAPTURE', 'inputType' => 'select', 'options' => array('AUTH_CAPTURE', 'AUTH_ONLY'), 'eval' => array('mandatory' => true, 'maxlength' => 255), 'reference' => $GLOBALS['TL_LANG']['ISO_PAY']['authorizedotnet']['modes']), 'cybersource_merchant_id' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['cybersource_merchant_id'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'cybersource_trans_key' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['cybersource_trans_key'], 'exclude' => true, 'inputType' => 'textarea', 'eval' => array('mandatory' => true, 'style' => 'height: 60px;')), 'cybersource_trans_type' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['cybersource_trans_type'], 'exclude' => true, 'default' => 'AUTH_ONLY', 'inputType' => 'select', 'options' => array('AUTH_CAPTURE', 'AUTH_ONLY'), 'eval' => array('mandatory' => true, 'maxlength' => 255), 'reference' => $GLOBALS['TL_LANG']['ISO_PAY']['authorizedotnet']['modes']), 'authorize_delimiter' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['authorize_delimiter'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 1)), 'requireCCV' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['requireCCV'], 'exclude' => true, 'inputType' => 'checkbox'), 'button' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['button'], 'exclude' => true, 'inputType' => 'fileTree', 'eval' => array('fieldType' => 'radio', 'files' => true, 'filesOnly' => true, 'extensions' => 'jpg,jpeg,png,gif')), 'guests' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['guests'], 'exclude' => true, 'inputType' => 'checkbox'), 'protected' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['protected'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('submitOnChange' => true)), 'groups' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['groups'], 'exclude' => true, 'inputType' => 'checkbox', 'foreignKey' => 'tl_member_group.name', 'eval' => array('multiple' => true)), 'debug' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['debug'], 'exclude' => true, 'inputType' => 'checkbox'), 'enabled' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_payment_modules']['enabled'], 'exclude' => true, 'inputType' => 'checkbox')));
/**
 * Class tl_iso_payment_modules
 * Provide miscellaneous methods that are used by the data configuration array.
 */
class tl_iso_payment_modules extends Backend
{
    /**
     * Check permissions to edit table tl_iso_payment_modules
     * @return void
     */
    public function checkPermission()
    {
        // Do not run the permission check on other Isotope modules
        if ($this->Input->get('mod') != 'payment') {
            return;
コード例 #5
0
 *
 * PHP version 5
 * @copyright  Isotope eCommerce Workgroup 2009-2012
 * @author     Andreas Schempp <*****@*****.**>
 * @author     Fred Bliss <*****@*****.**>
 * @license    http://opensource.org/licenses/lgpl-3.0.html
 */
/**
 * Load tl_iso_products data container and language files
 */
$this->loadDataContainer('tl_iso_products');
$this->loadLanguageFile('tl_iso_products');
/**
 * Table tl_iso_shipping_modules
 */
$GLOBALS['TL_DCA']['tl_iso_shipping_modules'] = array('config' => array('dataContainer' => 'Table', 'ctable' => array('tl_iso_shipping_options'), 'switchToEdit' => true, 'enableVersioning' => true, 'closed' => true, 'onload_callback' => array(array('IsotopeBackend', 'initializeSetupModule'), array('tl_iso_shipping_modules', 'checkPermission'))), 'list' => array('sorting' => array('mode' => 1, 'fields' => array('name'), 'flag' => 1, 'panelLayout' => 'sort,filter;search,limit'), 'label' => array('fields' => array('name', 'type'), 'format' => '%s <span style="color:#b3b3b3; padding-left:3px;">[%s]</span>', 'label_callback' => array('IsotopeBackend', 'addPublishIcon')), '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_shipping_modules']['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_shipping_modules']['edit'], 'href' => 'act=edit', 'icon' => 'edit.gif'), 'copy' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['copy'], 'href' => 'act=copy', 'icon' => 'copy.gif', 'button_callback' => array('tl_iso_shipping_modules', 'copyShippingModule')), 'delete' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['delete'], 'href' => 'act=delete', 'icon' => 'delete.gif', 'attributes' => 'onclick="if (!confirm(\'' . $GLOBALS['TL_LANG']['MSC']['deleteConfirm'] . '\')) return false; Backend.getScrollOffset();"', 'button_callback' => array('tl_iso_shipping_modules', 'deleteShippingModule')), 'show' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['show'], 'href' => 'act=show', 'icon' => 'show.gif'), 'options' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['options'], 'href' => 'table=tl_iso_shipping_options', 'icon' => 'tablewizard.gif', 'button_callback' => array('tl_iso_shipping_modules', 'optionsButton')))), 'palettes' => array('__selector__' => array('type', 'protected'), 'default' => '{title_legend},type,name', 'flat' => '{title_legend},type,name,label;{note_legend:hide},note;{price_legend},price,tax_class,flatCalculation,surcharge_field;{config_legend},countries,subdivisions,postalCodes,minimum_total,maximum_total,product_types;{expert_legend:hide},guests,protected;{enabled_legend},enabled', 'order_total' => '{title_legend},type,name,label;{note_legend:hide},note;{price_legend},price,tax_class;{config_legend},countries,subdivisions,postalCodes,minimum_total,maximum_total,product_types;{expert_legend:hide},guests,protected;{enabled_legend},enabled', 'weight_total' => '{title_legend},type,name,label;{note_legend:hide},note;{price_legend},tax_class;{config_legend},weight_unit,countries,subdivisions,postalCodes,minimum_total,maximum_total,product_types;{expert_legend:hide},guests,protected;{enabled_legend},enabled', 'ups' => '{title_legend},type,name,label;{note_legend:hide},note;{price_legend},tax_class;{ups_legend},ups_enabledService,ups_accessKey,ups_userName,ups_password;{config_legend},weight_unit,countries,subdivisions,minimum_total,maximum_total,product_types;{expert_legend:hide},guests,protected;{enabled_legend},enabled', 'usps' => '{title_legend},type,name,label;{note_legend:hide},note;{price_legend},tax_class;{usps_legend},usps_enabledService,usps_userName;{config_legend},countries,subdivisions,minimum_total,maximum_total,product_types;{expert_legend:hide},guests,protected;{enabled_legend},enabled'), 'subpalettes' => array('protected' => 'groups'), 'fields' => array('type' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['type'], 'exclude' => true, 'filter' => true, 'inputType' => 'select', 'default' => 'flat', 'options_callback' => array('tl_iso_shipping_modules', 'getModules'), 'reference' => &$GLOBALS['ISO_LANG']['SHIP'], 'eval' => array('helpwizard' => true, 'submitOnChange' => true, 'tl_class' => 'clr')), 'name' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['name'], 'exclude' => true, 'search' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'tl_class' => 'w50')), 'label' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['label'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'tl_class' => 'w50')), 'note' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['note'], 'exclude' => true, 'inputType' => 'textarea', 'eval' => array('rte' => 'tinyMCE', 'decodeEntities' => true)), 'ups_enabledService' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['ups_enabledService'], 'exclude' => true, 'inputType' => 'select', 'options' => $GLOBALS['TL_LANG']['tl_iso_shipping_modules']['ups_service'], 'eval' => array('mandatory' => true)), 'ups_accessKey' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['ups_accessKey'], 'exclude' => true, 'search' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'ups_userName' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['ups_userName'], 'exclude' => true, 'search' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'ups_password' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['ups_password'], 'exclude' => true, 'search' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'usps_enabledService' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['usps_enabledService'], 'exclude' => true, 'inputType' => 'select', 'options' => $GLOBALS['TL_LANG']['tl_iso_shipping_modules']['usps_service'], 'eval' => array('mandatory' => true)), 'usps_userName' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['usps_userName'], 'exclude' => true, 'search' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255)), 'countries' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['countries'], 'exclude' => true, 'inputType' => 'select', 'options' => $this->getCountries(), 'eval' => array('multiple' => true, 'size' => 8, 'tl_class' => 'w50 w50h')), 'subdivisions' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['subdivisions'], 'exclude' => true, 'sorting' => true, 'inputType' => 'conditionalselect', 'options_callback' => array('IsotopeBackend', 'getSubdivisions'), 'eval' => array('multiple' => true, 'size' => 8, 'conditionField' => 'countries', 'tl_class' => 'w50 w50h')), 'postalCodes' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['postalCodes'], 'exclude' => true, 'inputType' => 'textarea', 'eval' => array('style' => 'height:40px', 'tl_class' => 'clr')), 'minimum_total' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['minimum_total'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'rgxp' => 'price', 'tl_class' => 'w50')), 'maximum_total' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['maximum_total'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'rgxp' => 'price', 'tl_class' => 'w50')), 'product_types' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['product_types'], 'exclude' => true, 'inputType' => 'select', 'foreignKey' => 'tl_iso_producttypes.name', 'eval' => array('multiple' => true, 'size' => 8, 'tl_class' => 'clr')), 'price' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['price'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 16, 'rgxp' => 'surcharge', 'tl_class' => 'w50')), 'tax_class' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['tax_class'], 'exclude' => true, 'filter' => true, 'inputType' => 'select', 'options' => IsotopeBackend::getTaxClassesWithSplit(), 'eval' => array('includeBlankOption' => true, 'tl_class' => 'w50')), 'flatCalculation' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['flatCalculation'], 'exclude' => true, 'inputType' => 'select', 'options' => array('flat', 'perProduct', 'perItem'), 'reference' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules'], 'eval' => array('tl_class' => 'w50')), 'surcharge_field' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['surcharge_field'], 'exclude' => true, 'inputType' => 'select', 'options' => array_keys($GLOBALS['TL_DCA']['tl_iso_products']['fields']), 'reference' => &$GLOBALS['TL_LANG']['tl_iso_products'], 'eval' => array('includeBlankOption' => true, 'tl_class' => 'w50')), 'weight_unit' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['weight_unit'], 'exclude' => true, 'default' => 'kg', 'inputType' => 'select', 'options' => array('mg', 'g', 'kg', 't', 'ct', 'oz', 'lb', 'st', 'grain'), 'reference' => &$GLOBALS['ISO_LANG']['WGT'], 'eval' => array('tl_class' => 'clr', 'helpwizard' => &$GLOBALS['ISO_LANG']['WGT'])), 'guests' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['guests'], 'exclude' => true, 'inputType' => 'checkbox'), 'protected' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['protected'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('submitOnChange' => true)), 'groups' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['groups'], 'exclude' => true, 'inputType' => 'checkbox', 'foreignKey' => 'tl_member_group.name', 'eval' => array('multiple' => true)), 'enabled' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_shipping_modules']['enabled'], 'exclude' => true, 'inputType' => 'checkbox')));
/**
 * Class tl_iso_shipping_modules
 * Provide miscellaneous methods that are used by the data configuration array.
 */
class tl_iso_shipping_modules extends Backend
{
    /**
     * Check permissions to edit table tl_iso_shipping_modules
     * @return void
     */
    public function checkPermission()
    {
        // Do not run the permission check on other Isotope modules
        if ($this->Input->get('mod') != 'shipping') {
            return;
コード例 #6
0
ファイル: tl_iso_mail.php プロジェクト: rburch/core-1
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this program. If not, please visit the Free
 * Software Foundation website at <http://www.gnu.org/licenses/>.
 *
 * PHP version 5
 * @copyright  Isotope eCommerce Workgroup 2009-2012
 * @author     Andreas Schempp <*****@*****.**>
 * @author     Fred Bliss <*****@*****.**>
 * @license    http://opensource.org/licenses/lgpl-3.0.html
 */
/**
 * Table tl_iso_mail
 */
$GLOBALS['TL_DCA']['tl_iso_mail'] = array('config' => array('dataContainer' => 'Table', 'enableVersioning' => true, 'closed' => true, 'switchToEdit' => true, 'ctable' => array('tl_iso_mail_content'), 'onload_callback' => array(array('IsotopeBackend', 'initializeSetupModule'), array('tl_iso_mail', 'checkPermission'))), 'list' => array('sorting' => array('mode' => 1, 'fields' => array('name'), 'flag' => 1, 'panelLayout' => 'filter;search,limit'), 'label' => array('fields' => array('name', 'sender'), '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_mail']['new'], 'href' => 'act=create', 'class' => 'header_new', 'attributes' => 'onclick="Backend.getScrollOffset();"'), 'importMail' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['importMail'], 'href' => 'key=importMail', 'class' => 'header_import_mail', '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_mail']['edit'], 'href' => 'table=tl_iso_mail_content', 'icon' => 'edit.gif'), 'copy' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['copy'], 'href' => 'act=copy', 'icon' => 'copy.gif', 'button_callback' => array('tl_iso_mail', 'copyMail')), 'delete' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['delete'], 'href' => 'act=delete', 'icon' => 'delete.gif', 'attributes' => 'onclick="if (!confirm(\'' . $GLOBALS['TL_LANG']['MSC']['deleteConfirm'] . '\')) return false; Backend.getScrollOffset();"', 'button_callback' => array('tl_iso_mail', 'deleteMail')), 'show' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['show'], 'href' => 'act=show', 'icon' => 'show.gif'), 'exportMail' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['exportMail'], 'href' => 'key=exportMail', 'icon' => 'system/modules/isotope/html/drive-download.png'))), 'palettes' => array('__selector__' => array('attachDocument'), 'default' => '{name_legend},name;{address_legend},senderName,sender,cc,bcc;{document_legend:hide},attachDocument;{expert_legend:hide},template,priority'), 'subpalettes' => array('attachDocument' => 'documentTemplate,documentTitle'), 'fields' => array('name' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['name'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'tl_class' => 'long')), 'senderName' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['senderName'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'tl_class' => 'w50')), 'sender' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['sender'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'rgxp' => 'email', 'tl_class' => 'w50')), 'cc' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['cc'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'rgxp' => 'extnd', 'tl_class' => 'w50')), 'bcc' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['bcc'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('maxlength' => 255, 'rgxp' => 'extnd', 'tl_class' => 'w50')), 'template' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['template'], 'exclude' => true, 'inputType' => 'select', 'default' => 'mail_default', 'options' => IsotopeBackend::getTemplates('mail_'), 'eval' => array('mandatory' => true, 'tl_class' => 'w50')), 'priority' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['priority'], 'exclude' => true, 'inputType' => 'select', 'options' => array(1, 2, 3, 4, 5), 'default' => 3, 'reference' => &$GLOBALS['TL_LANG']['tl_iso_mail']['priority_ref'], 'eval' => array('tl_class' => 'w50')), 'attachDocument' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['attachDocument'], 'exclude' => true, 'inputType' => 'checkbox', 'eval' => array('submitOnChange' => true, 'tl_class' => 'clr')), 'documentTemplate' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['documentTemplate'], 'exclude' => true, 'inputType' => 'select', 'options' => IsotopeBackend::getTemplates('iso_invoice'), 'eval' => array('includeBlankOption' => true, 'tl_class' => 'w50')), 'documentTitle' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['documentTitle'], 'exclude' => true, 'inputType' => 'text', 'eval' => array('mandatory' => true, 'maxlength' => 255, 'decodeEntities' => true, 'tl_class' => 'w50')), 'source' => array('label' => &$GLOBALS['TL_LANG']['tl_iso_mail']['source'], 'eval' => array('fieldType' => 'checkbox', 'files' => true, 'filesOnly' => true, 'extensions' => 'imt', 'class' => 'mandatory'))));
/**
 * Class tl_iso_mail
 * Provide miscellaneous methods that are used by the data configuration array.
 */
class tl_iso_mail extends Backend
{
    /**
     * Check permissions to edit table tl_iso_mail
     * @return void
     */
    public function checkPermission()
    {
        // Do not run the permission check on other Isotope modules
        if ($this->Input->get('mod') != 'iso_mail') {
            return;