Example #1
0
						<div id="product-tab-content-category" class="product-tab-content" style=" display:none">
							<div class="row">
								<div class="col-md-10 form-horizontal">
									<div class="form-group">
										<label for="categoryBox" class="col-sm-2 control-label">关联分类</label>
										<div class="col-sm-10">
											<?php 
$trads = array('Home' => '根分类', 'selected' => '选择', 'Collapse All' => '关闭', 'Expand All' => '展开', 'Check All' => '全选', 'Uncheck All' => '全不选');
if (!isset($obj)) {
    $categoryBox = Tools::getRequest('categoryBox') ? Tools::getRequest('categoryBox') : array();
} else {
    if (Tools::isSubmit('categoryBox')) {
        $categoryBox = Tools::getRequest('categoryBox');
    } else {
        $categoryBox = Product::getProductCategoriesFullId($obj->id);
    }
}
echo Helper::renderAdminCategorieTree($trads, $categoryBox, 'categoryBox', false, 'Tree');
?>
											<a href="index.php?rule=category_edit" class="btn btn-link bt-icon confirm_leave">
												<span class="glyphicon glyphicon-plus"></span> 创建一个新分类 <span class="glyphicon glyphicon-new-window"></span>
											</a>
										</div>
									</div>
									<?php 
if (!isset($obj)) {
    $selectedCat = Category::getCategoryInformations(Tools::getRequest('categoryBox'));
} else {
    if (Tools::isSubmit('categoryBox')) {
        $selectedCat = Category::getCategoryInformations(Tools::getRequest('categoryBox'));