// Multistore bootstrap design
This commit is contained in:
1 parent
2f3d736f13
commit
f312a055b1
8 files changed
+147
-127
No files matched your search
@@ -27,15 +27,12 @@
|
|||||||
{include file="toolbar.tpl" toolbar_btn=$toolbar_btn toolbar_scroll=$toolbar_scroll title=$title}
|
{include file="toolbar.tpl" toolbar_btn=$toolbar_btn toolbar_scroll=$toolbar_scroll title=$title}
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
<div class="multishop-left">
|
<div class="row">
|
||||||
<div class="multishop-title">{l s='Multistore tree'}</div>
|
<div class="col-lg-4">
|
||||||
{include file="controllers/shop/tree.tpl" selected_tree_id=$selected_tree_id}
|
<fieldset>
|
||||||
</div>
|
<h3><i class="icon-sitemap"></i> {l s='Multistore tree'}</h3>
|
||||||
<div class="multishop-right">{$content}</div>
|
{include file="controllers/shop/tree.tpl" selected_tree_id=$selected_tree_id}
|
||||||
|
</fieldset>
|
||||||
<script type="text/javascript">
|
</div>
|
||||||
$().ready(function(){
|
<div class="col-lg-8">{$content}</div>
|
||||||
if (parseInt($('.multishop-right').css('height')) > 200)
|
</div>
|
||||||
$('.multishop-left').css('height', $('.multishop-right').css('height'));
|
|
||||||
})
|
|
||||||
</script>
|
|
||||||
@@ -27,10 +27,15 @@
|
|||||||
{block name="input"}
|
{block name="input"}
|
||||||
{if $input.type == 'theme'}
|
{if $input.type == 'theme'}
|
||||||
{foreach $input.values as $theme}
|
{foreach $input.values as $theme}
|
||||||
<div class="select_theme {if $theme->id == $fields_value.id_theme_checked}select_theme_choice{/if}" onclick="$(this).find('input').attr('checked', true); $('.select_theme').removeClass('select_theme_choice'); $(this).toggleClass('select_theme_choice');">
|
<div class="col-lg-3 select_theme {if $theme->id == $fields_value.id_theme_checked}select_theme_choice{/if}" onclick="$(this).find('input').attr('checked', true); $('.select_theme').removeClass('select_theme_choice'); $(this).toggleClass('select_theme_choice');">
|
||||||
{$theme->name}<br />
|
<div class="radio">
|
||||||
<img src="../themes/{$theme->directory}/preview.jpg" alt="{$theme->directory}" /><br />
|
<label>
|
||||||
<input type="radio" name="id_theme" value="{$theme->id}" {if $theme->id == $fields_value.id_theme_checked}checked="checked"{/if} />
|
<input type="radio" name="id_theme" value="{$theme->id}"{if $theme->id == $fields_value.id_theme_checked} checked="checked"{/if}> {$theme->name}
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
<div class="theme_container">
|
||||||
|
<img class="thumbnail" src="../themes/{$theme->directory}/preview.jpg" alt="{$theme->directory}">
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{/foreach}
|
{/foreach}
|
||||||
<div class="clear"> </div>
|
<div class="clear"> </div>
|
||||||
@@ -65,50 +70,55 @@
|
|||||||
|
|
||||||
{block name="other_fieldsets"}
|
{block name="other_fieldsets"}
|
||||||
{if isset($form_import)}
|
{if isset($form_import)}
|
||||||
<br /><br />
|
<fieldset>
|
||||||
<fieldset><legend>{l s='Import data from another shop'}</legend>
|
<h3><i class="icon-cloud-download"></i> {l s='Import data from another shop'}</h3>
|
||||||
{foreach $form_import as $key => $field}
|
{foreach $form_import as $key => $field}
|
||||||
{if $key == 'radio'}
|
<div class="row">
|
||||||
<label>{$field.label} :</label>
|
{if $key == 'radio'}
|
||||||
<div class="margin-form">
|
<label class="control-label col-lg-3">{$field.label} :</label>
|
||||||
<label class="t" for="{$field.name}_on"><img src="../img/admin/enabled.gif" alt="{l s='Yes'}" title="{l s='Yes'}" /></label>
|
<div class="col-lg-2">
|
||||||
<input type="radio" name="{$field.name}" id="{$field.name}_on" value="1" {if $field.value } checked="checked" {/if} />
|
<span class="switch prestashop-switch">
|
||||||
<label class="t" for="{$field.name}_on"> {l s='Yes'}</label>
|
<input type="radio" name="{$field.name}" id="{$field.name}_on" value="1" {if $field.value } checked="checked" {/if}>
|
||||||
<label class="t" for="{$field.name}_off"><img src="../img/admin/disabled.gif" alt="{l s='No'}" title="{l s='No'}" style="margin-left: 10px;" /></label>
|
<label class="radio" for="{$field.name}_on">
|
||||||
<input type="radio" name="{$field.name}" id="{$field.name}_off" value="0" {if !$field.value } checked="checked" {/if}/>
|
<i class="icon-check-sign color_success"></i> {l s='Yes'}
|
||||||
<label class="t" for="{$field.name}_off"> {l s='No'}</label>
|
</label>
|
||||||
</div>
|
<input type="radio" name="{$field.name}" id="{$field.name}_off" value="0" {if !$field.value } checked="checked" {/if}>
|
||||||
{elseif $key == 'select'}
|
<label class="radio" for="{$field.name}_off">
|
||||||
<div id="shop_list" {if !$checked}display:none{/if}>
|
<i class="icon-ban-circle color_danger"></i> {l s='No'}
|
||||||
<label>{$field.label} :</label>
|
</label>
|
||||||
<div class="margin-form">
|
<span class="slide-button btn btn-default"></span>
|
||||||
<select name="{$field.name}" id="{$field.name}" >
|
</span>
|
||||||
{foreach $field.options.query AS $key => $option}
|
</div>
|
||||||
<option value="{$key}" {if $key == $defaultShop}selected="selected"{/if}>
|
{elseif $key == 'select'}
|
||||||
{$option.name}
|
<div id="shop_list" {if !$checked}display:none{/if}>
|
||||||
</option>
|
<label class="control-label col-lg-3">{$field.label} :</label>
|
||||||
{/foreach}
|
<div class="col-lg-9">
|
||||||
</select>
|
<select name="{$field.name}" id="{$field.name}" >
|
||||||
</div>
|
{foreach $field.options.query AS $key => $option}
|
||||||
</div>
|
<option value="{$key}" {if $key == $defaultShop}selected="selected"{/if}>
|
||||||
{elseif $key == 'allcheckbox'}
|
{$option.name}
|
||||||
<div id="data_list" {if !$checked}display:none{/if}>
|
</option>
|
||||||
<label>{$field.label} :</label>
|
{/foreach}
|
||||||
<div class="margin-form">
|
</select>
|
||||||
<ul>
|
|
||||||
{foreach $field.values as $key => $label}
|
|
||||||
<li><input type="checkbox" name="importData[{$key}]" checked="checked" /> {$label}</li>
|
|
||||||
{/foreach}
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
{elseif $key == 'submit'}
|
</div>
|
||||||
<div class="margin-form">
|
{elseif $key == 'allcheckbox'}
|
||||||
<input type="submit" value="{$field.title}" name="submitAdd{$table}" {if isset($field.class)}class="{$field.class}"{/if} />
|
<div id="data_list" {if !$checked}display:none{/if}>
|
||||||
</div>
|
<label class="control-label col-lg-3">{$field.label} :</label>
|
||||||
{/if}
|
<div class="col-lg-9">
|
||||||
{/foreach}
|
{foreach $field.values as $key => $label}
|
||||||
</fieldset>
|
<p class="checkbox"><input type="checkbox" name="importData[{$key}]" checked="checked" /> {$label}</p>
|
||||||
|
{/foreach}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{elseif $key == 'submit'}
|
||||||
|
<div class="col-lg-9">
|
||||||
|
<input type="submit" value="{$field.title}" name="submitAdd{$table}" class="btn btn-default{if isset($field.class)} {$field.class}{/if}" />
|
||||||
|
</div>
|
||||||
|
{/if}
|
||||||
|
</div>
|
||||||
|
{/foreach}
|
||||||
|
</fieldset>
|
||||||
{/if}
|
{/if}
|
||||||
{/block}
|
{/block}
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -28,5 +28,5 @@
|
|||||||
{elseif isset($confirm)}
|
{elseif isset($confirm)}
|
||||||
onclick="if (confirm('{$confirm}')){ return true; } else { event.stopPropagation(); event.preventDefault();};"
|
onclick="if (confirm('{$confirm}')){ return true; } else { event.stopPropagation(); event.preventDefault();};"
|
||||||
{/if} title="{$action}">
|
{/if} title="{$action}">
|
||||||
<img src="../img/admin/delete.gif" alt="{$action}" />
|
<i class="icon-trash"></i> {$action}
|
||||||
</a>
|
</a>
|
||||||
@@ -75,7 +75,7 @@
|
|||||||
{/if}
|
{/if}
|
||||||
{block name="label"}
|
{block name="label"}
|
||||||
{if isset($field['title']) && isset($field['hint'])}
|
{if isset($field['title']) && isset($field['hint'])}
|
||||||
<label class="control-label col-lg-3 {if isset($field['required']) && $field['required'] && $field['type'] != 'radio'}required{/if}">
|
<label class="control-label col-lg-3 {if isset($field['required']) && $field['required'] && $field['type'] != 'radio'}required{/if}" for="{$key}">
|
||||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="
|
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="
|
||||||
{if is_array($field['hint'])}
|
{if is_array($field['hint'])}
|
||||||
{foreach $field['hint'] as $hint}
|
{foreach $field['hint'] as $hint}
|
||||||
@@ -93,7 +93,7 @@
|
|||||||
</span>
|
</span>
|
||||||
</label>
|
</label>
|
||||||
{elseif isset($field['title'])}
|
{elseif isset($field['title'])}
|
||||||
<label class="control-label col-lg-3">{$field['title']}</label>
|
<label class="control-label col-lg-3" for="{$key}">{$field['title']}</label>
|
||||||
{/if}
|
{/if}
|
||||||
{/block}
|
{/block}
|
||||||
{block name="field"}
|
{block name="field"}
|
||||||
|
|||||||
@@ -105,7 +105,7 @@ class HelperFormCore extends Helper
|
|||||||
$tree->setUseSearch($params['tree']['use_search']);
|
$tree->setUseSearch($params['tree']['use_search']);
|
||||||
|
|
||||||
if (isset($params['tree']['use_checkbox']))
|
if (isset($params['tree']['use_checkbox']))
|
||||||
$tree->setuseCheckBox($params['tree']['use_checkbox']);
|
$tree->setUseCheckBox($params['tree']['use_checkbox']);
|
||||||
|
|
||||||
$this->context->smarty->assign('categories_tree', $tree->render());
|
$this->context->smarty->assign('categories_tree', $tree->render());
|
||||||
$categories = false;
|
$categories = false;
|
||||||
|
|||||||
@@ -29,6 +29,7 @@ class AdminShopControllerCore extends AdminController
|
|||||||
{
|
{
|
||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
|
$this->bootstrap = true;
|
||||||
$this->context = Context::getContext();
|
$this->context = Context::getContext();
|
||||||
$this->table = 'shop';
|
$this->table = 'shop';
|
||||||
$this->className = 'Shop';
|
$this->className = 'Shop';
|
||||||
@@ -39,7 +40,7 @@ class AdminShopControllerCore extends AdminController
|
|||||||
'id_shop' => array(
|
'id_shop' => array(
|
||||||
'title' => $this->l('ID'),
|
'title' => $this->l('ID'),
|
||||||
'align' => 'center',
|
'align' => 'center',
|
||||||
'width' => 25
|
'class' => 'fixed-width-xs'
|
||||||
),
|
),
|
||||||
'name' => array(
|
'name' => array(
|
||||||
'title' => $this->l('Shop'),
|
'title' => $this->l('Shop'),
|
||||||
@@ -145,7 +146,6 @@ class AdminShopControllerCore extends AdminController
|
|||||||
|
|
||||||
public function initContent()
|
public function initContent()
|
||||||
{
|
{
|
||||||
$this->list_simple_header = true;
|
|
||||||
parent::initContent();
|
parent::initContent();
|
||||||
|
|
||||||
$this->addJqueryPlugin('cookie-plugin');
|
$this->addJqueryPlugin('cookie-plugin');
|
||||||
@@ -313,14 +313,15 @@ class AdminShopControllerCore extends AdminController
|
|||||||
|
|
||||||
$this->fields_form = array(
|
$this->fields_form = array(
|
||||||
'legend' => array(
|
'legend' => array(
|
||||||
'title' => $this->l('Shop')
|
'title' => $this->l('Shop'),
|
||||||
|
'icon' => 'icon-shopping-cart'
|
||||||
),
|
),
|
||||||
'input' => array(
|
'input' => array(
|
||||||
array(
|
array(
|
||||||
'type' => 'text',
|
'type' => 'text',
|
||||||
'label' => $this->l('Shop name:'),
|
'label' => $this->l('Shop name:'),
|
||||||
'desc' => $this->l('This field does not refer to the shop name visible in the front office.').' '.
|
'desc' => array($this->l('This field does not refer to the shop name visible in the front office.'),
|
||||||
sprintf($this->l('Follow %sthis link%s to edit the shop name used on the Front Office.'), '<a href="'.$this->context->link->getAdminLink('AdminStores').'">', '</a>'),
|
sprintf($this->l('Follow %sthis link%s to edit the shop name used on the Front Office.'), '<a href="'.$this->context->link->getAdminLink('AdminStores').'">', '</a>')),
|
||||||
'name' => 'name',
|
'name' => 'name',
|
||||||
'required' => true,
|
'required' => true,
|
||||||
)
|
)
|
||||||
@@ -398,34 +399,60 @@ class AdminShopControllerCore extends AdminController
|
|||||||
if (Tools::isSubmit('id_shop'))
|
if (Tools::isSubmit('id_shop'))
|
||||||
{
|
{
|
||||||
$shop = new Shop((int)Tools::getValue('id_shop'));
|
$shop = new Shop((int)Tools::getValue('id_shop'));
|
||||||
$parent = $shop->id_category;
|
$id_root = $shop->id_category;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
$parent = $categories[0]['id_category'];
|
$id_root = $categories[0]['id_category'];
|
||||||
|
|
||||||
|
|
||||||
|
$id_shop = (int)Tools::getValue('id_shop');
|
||||||
|
$shop = new Shop($id_shop);
|
||||||
|
$selected_cat = Shop::getCategories($id_shop);
|
||||||
|
|
||||||
|
if (empty($selected_cat))
|
||||||
|
{
|
||||||
|
// get first category root and preselect all these children
|
||||||
|
$root_categories = Category::getRootCategories();
|
||||||
|
$root_category = new Category($root_categories[0]['id_category']);
|
||||||
|
$children = $root_category->getAllChildren($this->context->language->id);
|
||||||
|
$selected_cat[] = $root_categories[0]['id_category'];
|
||||||
|
|
||||||
|
foreach ($children as $child)
|
||||||
|
$selected_cat[] = $child->id;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (Shop::getContext() == Shop::CONTEXT_SHOP && Tools::isSubmit('id_shop'))
|
||||||
|
$root_category = new Category($shop->id_category);
|
||||||
|
else
|
||||||
|
$root_category = new Category($id_root);
|
||||||
|
|
||||||
$this->fields_form['input'][] = array(
|
$this->fields_form['input'][] = array(
|
||||||
'type' => 'categories_select',
|
'type' => 'categories',
|
||||||
'name' => 'categoryBox',
|
'name' => 'categoryBox',
|
||||||
'label' => $this->l('Associated categories:'),
|
'label' => $this->l('Associated categories:'),
|
||||||
'category_tree' => $this->initCategoriesAssociation($parent),
|
'tree' => array(
|
||||||
|
'id' => 'categories-tree',
|
||||||
|
'selected_categories' => $selected_cat,
|
||||||
|
'root_category' => $root_category->id,
|
||||||
|
'use_search' => true,
|
||||||
|
'use_checkbox' => true
|
||||||
|
),
|
||||||
'desc' => $this->l('By selecting associated categories, you are choosing to share the categories between shops. Once associated between shops, any alteration of this category will impact every shop.')
|
'desc' => $this->l('By selecting associated categories, you are choosing to share the categories between shops. Once associated between shops, any alteration of this category will impact every shop.')
|
||||||
);
|
);
|
||||||
/*$this->fields_form['input'][] = array(
|
/*$this->fields_form['input'][] = array(
|
||||||
'type' => 'radio',
|
'type' => 'switch',
|
||||||
'label' => $this->l('Status:'),
|
'label' => $this->l('Enabled:'),
|
||||||
'name' => 'active',
|
'name' => 'active',
|
||||||
'required' => true,
|
'required' => true,
|
||||||
'class' => 't',
|
|
||||||
'is_bool' => true,
|
'is_bool' => true,
|
||||||
'values' => array(
|
'values' => array(
|
||||||
array(
|
array(
|
||||||
'id' => 'active_on',
|
'id' => 'active_on',
|
||||||
'value' => 1,
|
'value' => 1
|
||||||
'label' => $this->l('Enabled')
|
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'active_off',
|
'id' => 'active_off',
|
||||||
'value' => 0,
|
'value' => 0
|
||||||
'label' => $this->l('Disabled')
|
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
'desc' => $this->l('Enable or disable your store?')
|
'desc' => $this->l('Enable or disable your store?')
|
||||||
|
|||||||
@@ -28,6 +28,7 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
{
|
{
|
||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
|
$this->bootstrap = true;
|
||||||
$this->table = 'shop_group';
|
$this->table = 'shop_group';
|
||||||
$this->className = 'ShopGroup';
|
$this->className = 'ShopGroup';
|
||||||
$this->lang = false;
|
$this->lang = false;
|
||||||
@@ -47,7 +48,7 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
'id_shop_group' => array(
|
'id_shop_group' => array(
|
||||||
'title' => $this->l('ID'),
|
'title' => $this->l('ID'),
|
||||||
'align' => 'center',
|
'align' => 'center',
|
||||||
'width' => 25,
|
'class' => 'fixed-width-xs',
|
||||||
),
|
),
|
||||||
'name' => array(
|
'name' => array(
|
||||||
'title' => $this->l('Group shop'),
|
'title' => $this->l('Group shop'),
|
||||||
@@ -92,7 +93,6 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
|
|
||||||
public function initContent()
|
public function initContent()
|
||||||
{
|
{
|
||||||
$this->list_simple_header = true;
|
|
||||||
parent::initContent();
|
parent::initContent();
|
||||||
|
|
||||||
if ($this->display == 'options')
|
if ($this->display == 'options')
|
||||||
@@ -128,7 +128,8 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
{
|
{
|
||||||
$this->fields_form = array(
|
$this->fields_form = array(
|
||||||
'legend' => array(
|
'legend' => array(
|
||||||
'title' => $this->l('Shop group:')
|
'title' => $this->l('Shop group'),
|
||||||
|
'icon' => 'icon-shopping-cart'
|
||||||
),
|
),
|
||||||
'description' => $this->l('Warning: Enabling the "share customers" and "share orders" options is not recommended. Once activated and orders are created, you will not be able to disable these options. If you need these options, we recommend using several categories rather than several shops.'),
|
'description' => $this->l('Warning: Enabling the "share customers" and "share orders" options is not recommended. Once activated and orders are created, you will not be able to disable these options. If you need these options, we recommend using several categories rather than several shops.'),
|
||||||
'input' => array(
|
'input' => array(
|
||||||
@@ -139,7 +140,7 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
'required' => true
|
'required' => true
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'type' => 'radio',
|
'type' => 'switch',
|
||||||
'label' => $this->l('Share customers:'),
|
'label' => $this->l('Share customers:'),
|
||||||
'name' => 'share_customer',
|
'name' => 'share_customer',
|
||||||
'required' => true,
|
'required' => true,
|
||||||
@@ -149,19 +150,17 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
'values' => array(
|
'values' => array(
|
||||||
array(
|
array(
|
||||||
'id' => 'share_customer_on',
|
'id' => 'share_customer_on',
|
||||||
'value' => 1,
|
'value' => 1
|
||||||
'label' => $this->l('Enabled')
|
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'share_customer_off',
|
'id' => 'share_customer_off',
|
||||||
'value' => 0,
|
'value' => 0
|
||||||
'label' => $this->l('Disabled')
|
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
'desc' => $this->l('Once this option is enabled, the shops in this group will share customers. If a customer registers in any one of these shops, the account will automatically be available in the others shops of this goup. rnrnWarning: you will not be able to disable this option once you have registered customers.'),
|
'desc' => $this->l('Once this option is enabled, the shops in this group will share customers. If a customer registers in any one of these shops, the account will automatically be available in the others shops of this goup. rnrnWarning: you will not be able to disable this option once you have registered customers.'),
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'type' => 'radio',
|
'type' => 'switch',
|
||||||
'label' => $this->l('Share available quantities to sell:'),
|
'label' => $this->l('Share available quantities to sell:'),
|
||||||
'name' => 'share_stock',
|
'name' => 'share_stock',
|
||||||
'required' => true,
|
'required' => true,
|
||||||
@@ -170,19 +169,17 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
'values' => array(
|
'values' => array(
|
||||||
array(
|
array(
|
||||||
'id' => 'share_stock_on',
|
'id' => 'share_stock_on',
|
||||||
'value' => 1,
|
'value' => 1
|
||||||
'label' => $this->l('Enabled')
|
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'share_stock_off',
|
'id' => 'share_stock_off',
|
||||||
'value' => 0,
|
'value' => 0
|
||||||
'label' => $this->l('Disabled')
|
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
'desc' => $this->l('Share available quantities between shops of this group. When changing this option, all available products quantities will be reset to 0.'),
|
'desc' => $this->l('Share available quantities between shops of this group. When changing this option, all available products quantities will be reset to 0.'),
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'type' => 'radio',
|
'type' => 'switch',
|
||||||
'label' => $this->l('Share orders:'),
|
'label' => $this->l('Share orders:'),
|
||||||
'name' => 'share_order',
|
'name' => 'share_order',
|
||||||
'required' => true,
|
'required' => true,
|
||||||
@@ -192,19 +189,17 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
'values' => array(
|
'values' => array(
|
||||||
array(
|
array(
|
||||||
'id' => 'share_order_on',
|
'id' => 'share_order_on',
|
||||||
'value' => 1,
|
'value' => 1
|
||||||
'label' => $this->l('Enabled')
|
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'share_order_off',
|
'id' => 'share_order_off',
|
||||||
'value' => 0,
|
'value' => 0
|
||||||
'label' => $this->l('Disabled')
|
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
'desc' => $this->l('Once this option is enabled (which is only possible if customers and available quantities are shared among shops), the customer\'s cart will be shared by all shops in this group. This way, any purchase started in one shop will be able to be completed in another shop from the same group. rnrnWarning: You will not be able to disable this option once you\'ve started to accept orders.')
|
'desc' => $this->l('Once this option is enabled (which is only possible if customers and available quantities are shared among shops), the customer\'s cart will be shared by all shops in this group. This way, any purchase started in one shop will be able to be completed in another shop from the same group. rnrnWarning: You will not be able to disable this option once you\'ve started to accept orders.')
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'type' => 'radio',
|
'type' => 'switch',
|
||||||
'label' => $this->l('Status:'),
|
'label' => $this->l('Status:'),
|
||||||
'name' => 'active',
|
'name' => 'active',
|
||||||
'required' => true,
|
'required' => true,
|
||||||
@@ -213,13 +208,11 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
'values' => array(
|
'values' => array(
|
||||||
array(
|
array(
|
||||||
'id' => 'active_on',
|
'id' => 'active_on',
|
||||||
'value' => 1,
|
'value' => 1
|
||||||
'label' => $this->l('Enabled')
|
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'active_off',
|
'id' => 'active_off',
|
||||||
'value' => 0,
|
'value' => 0
|
||||||
'label' => $this->l('Disabled')
|
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
'desc' => $this->l('Enable or disable group shops?')
|
'desc' => $this->l('Enable or disable group shops?')
|
||||||
@@ -305,10 +298,7 @@ class AdminShopGroupControllerCore extends AdminController
|
|||||||
if ($this->fields_options && is_array($this->fields_options))
|
if ($this->fields_options && is_array($this->fields_options))
|
||||||
{
|
{
|
||||||
$this->display = 'options';
|
$this->display = 'options';
|
||||||
$this->show_toolbar = true;
|
$this->show_toolbar = false;
|
||||||
|
|
||||||
unset($this->toolbar_btn);
|
|
||||||
$this->initToolbar();
|
|
||||||
$helper = new HelperOptions($this);
|
$helper = new HelperOptions($this);
|
||||||
$this->setHelperDisplay($helper);
|
$this->setHelperDisplay($helper);
|
||||||
$helper->id = $this->id;
|
$helper->id = $this->id;
|
||||||
|
|||||||
@@ -28,6 +28,7 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
{
|
{
|
||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
|
$this->bootstrap = true;
|
||||||
$this->table = 'shop_url';
|
$this->table = 'shop_url';
|
||||||
$this->className = 'ShopUrl';
|
$this->className = 'ShopUrl';
|
||||||
$this->lang = false;
|
$this->lang = false;
|
||||||
@@ -44,11 +45,10 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
'id_shop_url' => array(
|
'id_shop_url' => array(
|
||||||
'title' => $this->l('ID'),
|
'title' => $this->l('ID'),
|
||||||
'align' => 'center',
|
'align' => 'center',
|
||||||
'width' => 25
|
'class' => 'fixed-width-xs'
|
||||||
),
|
),
|
||||||
'shop_name' => array(
|
'shop_name' => array(
|
||||||
'title' => $this->l('Shop name'),
|
'title' => $this->l('Shop name'),
|
||||||
'width' => 150,
|
|
||||||
'filter_key' => 's!name'
|
'filter_key' => 's!name'
|
||||||
),
|
),
|
||||||
'url' => array(
|
'url' => array(
|
||||||
@@ -63,7 +63,7 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
'type' => 'bool',
|
'type' => 'bool',
|
||||||
'orderby' => false,
|
'orderby' => false,
|
||||||
'filter_key' => 'main',
|
'filter_key' => 'main',
|
||||||
'width' => 100,
|
'class' => 'fixed-width-md'
|
||||||
),
|
),
|
||||||
'active' => array(
|
'active' => array(
|
||||||
'title' => $this->l('Enabled'),
|
'title' => $this->l('Enabled'),
|
||||||
@@ -72,7 +72,7 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
'type' => 'bool',
|
'type' => 'bool',
|
||||||
'orderby' => false,
|
'orderby' => false,
|
||||||
'filter_key' => 'active',
|
'filter_key' => 'active',
|
||||||
'width' => 50,
|
'class' => 'fixed-width-md'
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -118,7 +118,8 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
array(
|
array(
|
||||||
'form' => array(
|
'form' => array(
|
||||||
'legend' => array(
|
'legend' => array(
|
||||||
'title' => $this->l('URL options')
|
'title' => $this->l('URL options'),
|
||||||
|
'icon' => 'icon-cogs'
|
||||||
),
|
),
|
||||||
'input' => array(
|
'input' => array(
|
||||||
array(
|
array(
|
||||||
@@ -139,20 +140,18 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
)
|
)
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'type' => 'radio',
|
'type' => 'switch',
|
||||||
'label' => $this->l('Main URL:'),
|
'label' => $this->l('Main URL:'),
|
||||||
'name' => 'main',
|
'name' => 'main',
|
||||||
'class' => 't',
|
'class' => 't',
|
||||||
'values' => array(
|
'values' => array(
|
||||||
array(
|
array(
|
||||||
'id' => 'main_on',
|
'id' => 'main_on',
|
||||||
'value' => 1,
|
'value' => 1
|
||||||
'label' => '<img src="../img/admin/enabled.gif" alt="'.$this->l('Enabled').'" title="'.$this->l('Enabled').'" />'
|
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'main_off',
|
'id' => 'main_off',
|
||||||
'value' => 0,
|
'value' => 0
|
||||||
'label' => '<img src="../img/admin/disabled.gif" alt="'.$this->l('Disabled').'" title="'.$this->l('Disabled').'" />'
|
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
'desc' => array(
|
'desc' => array(
|
||||||
@@ -168,24 +167,21 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
)
|
)
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'type' => 'radio',
|
'type' => 'switch',
|
||||||
'label' => $this->l('Status:'),
|
'label' => $this->l('Enabled:'),
|
||||||
'name' => 'active',
|
'name' => 'active',
|
||||||
'required' => false,
|
'required' => false,
|
||||||
'class' => 't',
|
'class' => 't',
|
||||||
'values' => array(
|
'values' => array(
|
||||||
array(
|
array(
|
||||||
'id' => 'active_on',
|
'id' => 'active_on',
|
||||||
'value' => 1,
|
'value' => 1
|
||||||
'label' => '<img src="../img/admin/enabled.gif" alt="'.$this->l('Enabled').'" title="'.$this->l('Enabled').'" />'
|
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'active_off',
|
'id' => 'active_off',
|
||||||
'value' => 0,
|
'value' => 0
|
||||||
'label' => '<img src="../img/admin/disabled.gif" alt="'.$this->l('Disabled').'" title="'.$this->l('Disabled').'" />'
|
|
||||||
)
|
)
|
||||||
),
|
)
|
||||||
'desc' => $this->l('Enabled or disabled')
|
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
'submit' => array(
|
'submit' => array(
|
||||||
@@ -197,7 +193,8 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
array(
|
array(
|
||||||
'form' => array(
|
'form' => array(
|
||||||
'legend' => array(
|
'legend' => array(
|
||||||
'title' => $this->l('Shop URL')
|
'title' => $this->l('Shop URL'),
|
||||||
|
'icon' => 'icon-shopping-cart'
|
||||||
),
|
),
|
||||||
'input' => array(
|
'input' => array(
|
||||||
array(
|
array(
|
||||||
@@ -225,7 +222,7 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
'name' => 'virtual_uri',
|
'name' => 'virtual_uri',
|
||||||
'desc' => $desc_virtual_uri,
|
'desc' => $desc_virtual_uri,
|
||||||
'size' => 50,
|
'size' => 50,
|
||||||
'hint' => (!$update_htaccess) ? $this->l('Warning: URL rewriting (e.g. mod_rewrite for Apache) seems to be disabled. If your URL doesn\'t work, please check with your host provider on how to activate URL rewriting.') : '',
|
'hint' => (!$update_htaccess) ? $this->l('Warning: URL rewriting (e.g. mod_rewrite for Apache) seems to be disabled. If your URL doesn\'t work, please check with your host provider on how to activate URL rewriting.') : null,
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'type' => 'text',
|
'type' => 'text',
|
||||||
@@ -290,7 +287,6 @@ class AdminShopUrlControllerCore extends AdminController
|
|||||||
|
|
||||||
public function initContent()
|
public function initContent()
|
||||||
{
|
{
|
||||||
$this->list_simple_header = true;
|
|
||||||
parent::initContent();
|
parent::initContent();
|
||||||
|
|
||||||
$this->addJqueryPlugin('cookie-plugin');
|
$this->addJqueryPlugin('cookie-plugin');
|
||||||
|
|||||||
Reference in new issue
Block a user