Example #1
0
 /**
  * Create a new Eloquent model instance.
  *
  * @param  array  $attributes
  * @return void
  */
 public function __construct(array $attributes = [])
 {
     $this->table = cd_config('database.e.product.table.name');
     $this->primaryKey = cd_config('database.e.product.table.primary');
     $this->fillable = cd_config('database.e.product.model.fillable');
     parent::__construct($attributes);
 }
Example #2
0
 /**
  * By Category
  * @param type $query
  * @param \Claremontdesign\Ecommerce\Model\Category $category
  * @return type
  */
 public function scopeCategorized($query, Category $category = null)
 {
     if (is_null($category)) {
         return $query->with(cd_config('database.e.productCategory.table.name'));
     }
     $categoryIds = $category->getDescendantsAndSelf()->lists(cd_config('database.e.productCategory.table.primary'));
     return $query->with('categories')->join(cd_config('database.e.productCategoryPivot.table.name'), cd_config('database.e.productCategoryPivot.table.name') . '.' . cd_config('database.e.product.table.primary'), '=', cd_config('database.e.product.table.name') . '.' . cd_config('database.e.product.table.primary'))->whereIn(cd_config('database.e.productCategoryPivot.table.name') . '.' . cd_config('database.e.productCategory.table.primary'), $categoryIds);
 }
 /**
  * Run the database seeds.
  *
  * @return void
  */
 public function run()
 {
     $categoryId = cd_config('database.e.productCategory.table.primary');
     $className = cd_config('database.e.productCategory.model.class');
     $categories = [[$categoryId => 1, 'title' => 'Root Category', 'status' => rand(0, 1), 'children' => [[$categoryId => 2, 'title' => 'Tablets & E-Readers', 'status' => rand(0, 1)], [$categoryId => 3, 'title' => 'Computers', 'status' => rand(0, 1), 'children' => [[$categoryId => 4, 'title' => 'Laptops', 'status' => rand(0, 1), 'children' => [[$categoryId => 5, 'title' => 'PC Laptops', 'status' => rand(0, 1)], [$categoryId => 6, 'title' => 'Macbooks (Air/Pro)', 'status' => rand(0, 1)]]], [$categoryId => 7, 'title' => 'Desktops', 'status' => rand(0, 1)], [$categoryId => 8, 'title' => 'Monitors', 'status' => rand(0, 1)]]], [$categoryId => 9, 'title' => 'Cell Phones', 'status' => rand(0, 1)]]]];
     $className::buildTree($categories);
     factory(cd_config('database.e.product.model.class'), rand(2, 10))->create()->each(function ($product) use($className, $categoryId) {
         $category = $className::where($categoryId, '=', rand(1, 9))->first();
         $product->save();
         $product->categories()->attach($category);
     });
 }
Example #4
0
<?php

/**
 * Dx
 *
 * @link http://dennesabing.com
 * @author Dennes B Abing <*****@*****.**>
 * @license proprietary
 * @copyright Copyright (c) 2015 ClaremontDesign/MadLabs-Dx
 * @version 0.0.0.1
 * @since Dec 17, 2015 1:43:45 PM
 * @file routes.php
 * @project Claremontdesign
 * @package Ecommerce
 */
return ['widgets' => ['ecommerceCategoryProductsData' => ['access' => 'minimum', 'enable' => true, 'type' => 'datatable', 'sortable' => ['enable' => false], 'messages' => ['empty' => ['empty' => 'No data found.', 'notfound' => 'Cannot find the record/s you are looking for. Kindly try again.']], 'attributes' => ['recordName' => ['singular' => 'Product', 'plural' => 'Products']], 'ajax' => ['enable' => true, 'route' => ['name' => 'Module', 'module' => 'ecommerce-categories', 'action' => 'products', 'record' => function () {
    return app('cdbackend')->routeParam('record');
}]], 'action' => ['enable' => true, 'route' => ['name' => 'Module', 'module' => 'ecommerce-products'], 'actions' => ['update' => ['enable' => true, 'attributes' => ['label' => 'Edit']]]], 'columns' => ['position' => ['enable' => true, 'position' => 0, 'index' => 'position', 'value' => ['editable' => ['enable' => true, 'element' => ['type' => 'integer', 'inputonly' => true, 'attributes' => ['size' => 'xsmall', 'data' => ['data-positioning' => 1]]], 'init' => true]], 'filter' => ['enable' => true, 'index' => cd_config('database.e.productCategoryPivot.table.name') . '.position'], 'sort' => ['enable' => true, 'index' => cd_config('database.e.productCategoryPivot.table.name') . '.position'], 'type' => 'minmax', 'attributes' => ['label' => 'Position']], 'id' => ['enable' => true, 'position' => 1, 'index' => cd_config('database.e.product.table.primary'), 'filter' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.' . cd_config('database.e.product.table.primary')], 'sort' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.' . cd_config('database.e.product.table.primary')], 'type' => 'integer', 'attributes' => ['label' => 'ID'], 'ui' => ['html' => ['filterInput' => ['placeholder' => 'Product Id']], 'events' => []]], 'title' => ['position' => 2, 'index' => 'title', 'type' => 'string', 'attributes' => ['label' => 'Title'], 'enable' => true, 'ui' => ['html' => ['filterInput' => ['placeholder' => 'Search Title']]], 'sort' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.title'], 'filter' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.title']], 'price' => ['position' => 3, 'index' => 'price', 'type' => 'price', 'attributes' => ['label' => 'Price'], 'enable' => true, 'ui' => ['html' => ['filterInput' => ['placeholder' => '']]], 'sort' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.price'], 'filter' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.price']], 'status' => ['position' => 4, 'index' => 'status', 'type' => 'enabledisable', 'attributes' => ['label' => 'Status'], 'enable' => true, 'filter' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.status'], 'ui' => ['html' => ['filterInput' => ['placeholder' => 'Search Status']]], 'sort' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.status']]], 'model' => ['nested' => ['enable' => true, 'request' => ['index' => 'record'], 'model' => ['class' => cd_config('database.e.productCategory.model.class'), 'primary' => cd_config('database.e.productCategory.table.primary'), 'repository' => ['class' => cd_config('database.e.productCategory.repository.class')]]], 'value' => ['index' => cd_config('database.e.product.table.primary')], 'class' => cd_config('database.e.product.model.class'), 'repository' => ['sortrequest' => 'position-asc', 'sort' => [cd_config('database.e.productCategoryPivot.table.name') . '.position' => 'ASC'], 'rowsPerPage' => 2, 'class' => cd_config('database.e.product.repository.class')]]]]];
<?php

/**
 * Dx
 *
 * @link http://dennesabing.com
 * @author Dennes B Abing <*****@*****.**>
 * @license proprietary
 * @copyright Copyright (c) 2015 ClaremontDesign/MadLabs-Dx
 * @version 0.0.0.1
 * @since Dec 17, 2015 1:43:45 PM
 * @file routes.php
 * @project Claremontdesign
 * @package Ecommerce
 */
$config = ['modules' => ['ecommerce-categories' => ['enable' => true, 'name' => 'Products', 'metas' => ['pagetitle' => 'Ecommerce Categories', 'pagesubtitle' => 'Manage e-Commerce Categories.'], 'breadcrumb' => ['nav::ecommerce', 'nav::ecommerce.children.productsCategory'], 'module' => ['controller' => ['class' => \Claremontdesign\Cdbase\Widgets\WidgetTypes\Treeview\NestedController::class]], 'access' => 'minimum', 'actions' => ['index' => ['enable' => true, 'view' => ['template' => false], 'widgets' => ['ecommerceCategoriesTreeview']], 'position' => ['enable' => true, 'request' => ['methods' => ['ajaxpost']], 'nested' => ['attributes' => ['recordName' => ['singular' => 'Category', 'plural' => 'Categories']], 'models' => ['category' => ['primaryKey' => cd_config('database.e.productCategory.table.primary'), 'class' => cd_config('database.e.productCategory.model.class'), 'repository' => ['class' => cd_config('database.e.productCategory.repository.class')]]]], 'parent' => ['parent' => ['enable' => true, 'request' => ['index' => ['record']], 'model' => ['value' => ['index' => [cd_config('database.e.productCategory.table.primary')]], 'repository' => ['record' => ['index' => cd_config('database.e.productCategory.table.name') . '.' . cd_config('database.e.productCategory.table.primary'), 'class' => cd_config('database.e.productCategory.model.class'), 'repository' => ['class' => cd_config('database.e.productCategory.repository.class'), 'index' => cd_config('database.e.productCategory.table.name') . '.' . cd_config('database.e.productCategory.table.primary')]]]], 'error' => ['notfound' => 'Category not found.']]]], 'update' => ['enable' => true, 'request' => ['methods' => ['ajaxpost']], 'widgets' => ['ecommerceCategoryForm']], 'delete' => ['enable' => true, 'widgets' => ['ecommerceCategoriesForm']], 'create' => ['enable' => true, 'metas' => ['pagetitle' => 'Create A Category', 'pagesubtitle' => 'Create a new category.'], 'widgets' => ['ecommerceCategoriesForm']], 'products' => ['enable' => true, 'request' => ['methods' => ['ajaxpost', 'ajaxget']], 'breadcrumb' => ['nav::ecommerce.children.productsCategory.children.products'], 'parent' => ['parent' => ['enable' => true, 'request' => ['index' => ['record']], 'route' => [['record' => ['name' => 'Module', 'module' => 'ecommerce-categories']]], 'model' => ['value' => ['index' => ['category_id']], 'repository' => ['record' => ['primaryKey' => cd_config('database.e.productCategory.table.primary'), 'class' => cd_config('database.e.productCategory.model.class'), 'repository' => ['class' => cd_config('database.e.productCategory.repository.class')]]]], 'error' => ['notfound' => 'Category not found.']]], 'widgets' => ['ecommerceCategoryProductsData']]]]]];
return array_merge_recursive($config, require __DIR__ . '/tree.php', require __DIR__ . '/products.php', require __DIR__ . '/form.php');
Example #6
0
<?php

/**
 * Dx
 *
 * @link http://dennesabing.com
 * @author Dennes B Abing <*****@*****.**>
 * @license proprietary
 * @copyright Copyright (c) 2015 ClaremontDesign/MadLabs-Dx
 * @version 0.0.0.1
 * @since Dec 17, 2015 1:43:45 PM
 * @file routes.php
 * @project Claremontdesign
 * @package Ecommerce
 */
return ['widgets' => ['ecommerceProductsForm' => ['enable' => true, 'type' => 'form', 'access' => 'minimum', 'request' => ['index' => 'record', 'multiple' => true], 'attributes' => ['recordName' => ['singular' => 'Product', 'plural' => 'Products']], 'form' => ['messages' => ['empty' => 'No data found.', 'notfound' => 'Cannot find the record/s you are looking for. Kindly try again.'], 'ui' => ['html' => ['form' => []]], 'fieldsets' => [], 'tabs' => ['general' => ['enable' => true, 'position' => 100, 'attributes' => ['label' => 'General'], 'elements' => ['title', 'description', 'shortDescription', 'sku', 'slug', 'status']], 'price' => ['enable' => true, 'position' => 70, 'attributes' => ['label' => 'Prices'], 'elements' => ['price']], 'meta' => ['enable' => true, 'position' => 60, 'attributes' => ['label' => 'Meta Information'], 'elements' => ['metaTitle', 'metaDescription', 'metaKeywords']], 'categories' => ['enable' => true, 'position' => 50, 'attributes' => ['label' => 'Categories'], 'events' => ['onclick' => ['ajax' => true]], 'elements' => ['category']]], 'actions' => ['submit' => ['type' => 'submit', 'enable' => true, 'ui' => ['html' => ['input' => []]], 'attributes' => ['label' => 'Submit']], 'confirm' => ['enable' => false, 'type' => 'confirm', 'ui' => ['html' => ['input' => []]], 'attributes' => ['label' => 'Confirm']], 'cancel' => ['enable' => true, 'type' => 'cancel', 'ui' => ['tag' => 'a', 'url' => ['route' => ['name' => 'Module', 'module' => 'ecommerce-products']], 'html' => ['input' => []]], 'attributes' => ['label' => 'Cancel']]], 'elements' => ['title' => ['enable' => true, 'model' => ['value' => ['index' => 'title']], 'type' => 'text', 'position' => 3, 'attributes' => ['label' => 'Title', 'placeholder' => 'Title'], 'validation' => ['required' => ['enable' => true, 'message' => 'Title is required.']]], 'sku' => ['enable' => true, 'model' => ['value' => ['index' => 'sku']], 'type' => 'text', 'position' => 3, 'attributes' => ['label' => 'SKU', 'placeholder' => 'SKU'], 'validation' => ['required' => ['enable' => true, 'message' => 'SKU is required.']]], 'price' => ['enable' => true, 'model' => ['value' => ['index' => 'price']], 'type' => 'price', 'position' => 3, 'attributes' => ['label' => 'Price', 'placeholder' => 'Price'], 'validation' => ['required' => ['enable' => false, 'message' => 'Price is required.']]], 'description' => ['enable' => true, 'model' => ['value' => ['index' => 'description']], 'type' => 'textarea', 'position' => 2, 'attributes' => ['label' => 'Description', 'placeholder' => 'Description']], 'shortDescription' => ['enable' => true, 'model' => ['value' => ['index' => 'short_description']], 'type' => 'textarea', 'position' => 2, 'attributes' => ['label' => 'Short Description', 'placeholder' => 'Short Description']], 'slug' => ['enable' => true, 'model' => ['value' => ['index' => 'slug']], 'type' => 'text', 'position' => 2, 'attributes' => ['label' => 'Slug', 'placeholder' => 'Slug', 'data' => ['data-slug' => 1, 'data-reference' => 'title']]], 'metaTitle' => ['enable' => true, 'model' => ['value' => ['index' => 'meta_title']], 'type' => 'text', 'position' => 2, 'attributes' => ['label' => 'Meta Title', 'placeholder' => 'Meta Title']], 'metaKeywords' => ['enable' => true, 'model' => ['value' => ['index' => 'meta_keywords']], 'type' => 'textarea', 'position' => 2, 'attributes' => ['label' => 'Meta Keywords', 'placeholder' => 'Meta Keywords']], 'metaDescription' => ['enable' => true, 'model' => ['value' => ['index' => 'meta_description']], 'type' => 'textarea', 'position' => 2, 'attributes' => ['label' => 'Meta Description', 'placeholder' => 'Meta Description']], 'status' => ['enable' => true, 'model' => ['value' => ['index' => 'status']], 'type' => 'select', 'select' => ['options' => ['options' => 'enabledisable']], 'position' => 1, 'attributes' => ['label' => 'Status']], 'category' => ['enable' => true, 'type' => 'checkabletree', 'position' => 1, 'attributes' => ['label' => 'Category'], 'defer' => ['enable' => true], 'view' => ['widget' => 'ecommerceProductsCategorySelectableTree']]]], 'model' => ['value' => ['index' => cd_config('database.e.product.table.primary')], 'class' => cd_config('database.e.product.model.class'), 'repository' => ['class' => cd_config('database.e.product.repository.class'), 'index' => cd_config('database.e.product.table.name') . '.' . cd_config('database.e.product.table.primary')], 'crud' => ['duplicate' => ['enable' => false], 'create' => ['enable' => true, 'type' => 'create', 'crud' => ['type' => 'crud', 'enable' => true], 'success' => ['redirect' => ['enable' => true, 'route' => ['name' => 'Module', 'module' => 'ecommerce-categories']], 'back' => [], 'message' => 'Created successfull!']], 'update' => ['enable' => true, 'type' => 'update', 'success' => ['route' => [], 'message' => 'Update successfull!'], 'crud' => ['type' => 'crud', 'enable' => true, 'ui' => ['tag' => 'a', 'url' => ['route' => ['name' => 'Module', 'module' => 'ecommerce-categories', 'action' => 'update']], 'html' => ['input' => []]], 'attributes' => ['label' => 'Update']]], 'view' => ['enable' => true, 'type' => 'view', 'crud' => ['type' => 'crud', 'enable' => true], 'actions' => ['update', 'delete']], 'delete' => ['enable' => true, 'type' => 'delete', 'crud' => ['type' => 'crud', 'enable' => true, 'ui' => ['tag' => 'a', 'url' => ['route' => ['name' => 'Module', 'module' => 'ecommerce-categories', 'action' => 'delete']], 'html' => ['input' => []]], 'attributes' => ['label' => 'Delete']], 'view' => ['form' => ['enable' => false, 'path' => 'form.index', 'pre' => [], 'post' => []]], 'success' => ['redirect' => ['enable' => true, 'route' => ['name' => 'Module', 'module' => 'ecommerce-categories']], 'message' => 'Delete successfull!']]]]]]];
<?php

/**
 * Dx
 *
 * @link http://dennesabing.com
 * @author Dennes B Abing <*****@*****.**>
 * @license proprietary
 * @copyright Copyright (c) 2015 ClaremontDesign/MadLabs-Dx
 * @version 0.0.0.1
 * @since Nov 7, 2015 1:25:03 PM
 * @file config.php
 * @project Cdsurvey
 */
return ['widgets' => ['ecommerceProductsCategorySelectableTree' => ['access' => 'minimum', 'enable' => true, 'type' => 'treeview', 'tree' => ['selectable' => true, 'multiple' => true, 'positionable' => false, 'collapsed' => true], 'messages' => ['empty' => ['empty' => 'No Categories  found.', 'notfound' => 'Cannot find the category/s you are looking for. Kindly try again.']], 'request' => ['ajax' => true, 'item' => 'record', 'list' => 'paramOne', 'form' => ['index' => 'category']], 'response' => ['json' => false], 'models' => ['item' => ['primaryKey' => cd_config('database.e.product.table.primary'), 'class' => cd_config('database.e.product.model.class'), 'repository' => ['class' => cd_config('database.e.product.repository.class')]], 'category' => ['primaryKey' => cd_config('database.e.productCategory.table.primary'), 'class' => cd_config('database.e.productCategory.model.class'), 'repository' => ['class' => cd_config('database.e.productCategory.repository.class')]], 'pivot' => ['class' => cd_config('database.e.productCategoryPivot.model.class'), 'repository' => ['class' => cd_config('database.e.productCategoryPivot.repository.class')]]]]]];
Example #8
0
 /**
  * Products
  * @return Collection
  */
 public function products()
 {
     return $this->belongsToMany(Product::class, cd_config('database.e.productCategoryPivot.table.name'), cd_config('database.e.productCategory.table.primary'), cd_config('database.e.product.table.primary'));
 }
<?php

/*
 |--------------------------------------------------------------------------
 | Model Factories
 |--------------------------------------------------------------------------
 |
 | Here you may define all of your model factories. Model factories give
 | you a convenient way to create models for testing and seeding your
 | database. Just tell the factory how a default model should look.
 |
*/
$factory->define(cd_config('database.e.product.model.class'), function (Faker\Generator $faker) {
    $title = implode(' ', $faker->words(rand(3, 8)));
    return ['product_type' => 'default', 'title' => $title, 'sku' => $faker->word(), 'price' => $faker->randomFloat(), 'qty' => rand(0, 100), 'description' => $faker->text(rand(100, 200)), 'status' => rand(0, 1), 'slug' => \Illuminate\Support\Str::slug($title), 'created_at' => $faker->date('Y-m-d'), 'updated_at' => $faker->date('Y-m-d')];
});
Example #10
0
 /**
  * Return the Item Table
  * @return string
  */
 protected function _pivotTable()
 {
     return cd_config('database.e.productCategoryPivot.table.name');
 }
 /**
  * Reverse the migrations.
  *
  * @return void
  */
 public function down()
 {
     Schema::dropIfExists(cd_config('database.e.product.table.name'));
     Schema::dropIfExists(cd_config('database.e.productCategory.table.name'));
     Schema::dropIfExists(cd_config('database.e.productCategoryPivot.table.name'));
 }
Example #12
0
<?php

/**
 * Dx
 *
 * @link http://dennesabing.com
 * @author Dennes B Abing <*****@*****.**>
 * @license proprietary
 * @copyright Copyright (c) 2015 ClaremontDesign/MadLabs-Dx
 * @version 0.0.0.1
 * @since Dec 17, 2015 1:43:45 PM
 * @file routes.php
 * @project Claremontdesign
 * @package Ecommerce
 */
return ['widgets' => ['ecommerceProductsData' => ['access' => 'minimum', 'enable' => true, 'type' => 'datatable', 'messages' => ['empty' => ['empty' => 'No data found.', 'notfound' => 'Cannot find the record/s you are looking for. Kindly try again.']], 'config' => ['attributes' => ['recordName' => ['singular' => 'Product', 'plural' => 'Products']]], 'toolbars' => ['topleft' => ['create' => ['enable' => true, 'attributes' => ['label' => 'New Product'], 'url' => ['route' => ['name' => 'Module', 'module' => 'ecommerce-products', 'action' => 'create']]]]], 'action' => ['enable' => true, 'route' => ['name' => 'Module', 'module' => 'ecommerce-products'], 'actions' => ['update' => ['enable' => true, 'attributes' => ['label' => 'Edit']], 'delete' => ['enable' => false], 'view' => ['enable' => false]]], 'columns' => ['id' => ['enable' => true, 'position' => 0, 'index' => cd_config('database.e.product.table.primary'), 'filter' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.' . cd_config('database.e.product.table.primary')], 'sort' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.' . cd_config('database.e.product.table.primary')], 'type' => 'integer', 'attributes' => ['label' => 'ID'], 'ui' => ['html' => ['filterInput' => ['placeholder' => 'Product Id']], 'events' => []]], 'title' => ['position' => 1, 'index' => 'title', 'type' => 'string', 'attributes' => ['label' => 'Title'], 'enable' => true, 'ui' => ['html' => ['filterInput' => ['placeholder' => 'Search Title']]], 'sort' => ['enable' => true], 'filter' => ['enable' => true]], 'price' => ['position' => 2, 'index' => 'price', 'type' => 'price', 'attributes' => ['label' => 'Price'], 'enable' => true, 'ui' => ['html' => ['filterInput' => ['placeholder' => '']]], 'sort' => ['enable' => true], 'filter' => ['enable' => true]], 'status' => ['position' => 3, 'index' => 'status', 'type' => 'enabledisable', 'attributes' => ['label' => 'Status'], 'enable' => true, 'filter' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.status'], 'ui' => ['html' => ['filterInput' => ['placeholder' => 'Search Status']]], 'sort' => ['enable' => true]], 'description' => ['index' => 'description', 'type' => 'textarea', 'attributes' => ['label' => 'Description'], 'enable' => false, 'filter' => ['enable' => false], 'sort' => ['enable' => false]], 'created' => ['index' => 'created_at', 'type' => 'datetime', 'enable' => false, 'attributes' => ['label' => 'Date Created'], 'filter' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.created_at'], 'sort' => ['enable' => true]], 'updated' => ['enable' => false, 'type' => 'datetime', 'index' => 'updated_at', 'attributes' => ['label' => 'Last Update'], 'sort' => ['enable' => false], 'filter' => ['enable' => true, 'index' => cd_config('database.e.product.table.name') . '.created_at']]], 'model' => ['value' => ['index' => cd_config('database.e.product.table.primary')], 'class' => cd_config('database.e.product.model.class'), 'repository' => ['sort' => [cd_config('database.e.product.table.name') . '.' . cd_config('database.e.product.table.primary') => 'desc'], 'rowsPerPage' => 10, 'class' => cd_config('database.e.product.repository.class')]]]]];
Example #13
0
<?php

/**
 * Dx
 *
 * @link http://dennesabing.com
 * @author Dennes B Abing <*****@*****.**>
 * @license proprietary
 * @copyright Copyright (c) 2015 ClaremontDesign/MadLabs-Dx
 * @version 0.0.0.1
 * @since Dec 17, 2015 1:43:45 PM
 * @file routes.php
 * @project Claremontdesign
 * @package Ecommerce
 */
return ['widgets' => ['ecommerceCategoriesTreeview' => ['access' => 'minimum', 'enable' => true, 'type' => 'treeview', 'tree' => ['selectable' => false, 'multiple' => false, 'positionable' => true, 'collapsed' => true, 'dualpane' => true], 'toolbars' => ['topleft' => ['create' => ['enable' => true, 'attributes' => ['label' => 'New Category'], 'url' => ['route' => ['name' => 'Module', 'module' => 'ecommerce-categories', 'action' => 'create']]]]], 'infopane' => ['enable' => true, 'widget' => ['ecommerceCategoryForm']], 'messages' => ['empty' => ['empty' => 'No Categories  found.', 'notfound' => 'Cannot find the category/s you are looking for. Kindly try again.']], 'request' => ['route' => ['route' => ['name' => 'Module', 'module' => 'ecommerce-categories']], 'ajax' => true, 'item' => 'record'], 'models' => ['item' => ['primaryKey' => cd_config('database.e.product.table.primary'), 'class' => cd_config('database.e.product.model.class'), 'repository' => ['class' => cd_config('database.e.product.repository.class')]], 'category' => ['primaryKey' => cd_config('database.e.productCategory.table.primary'), 'class' => cd_config('database.e.productCategory.model.class'), 'repository' => ['class' => cd_config('database.e.productCategory.repository.class')]], 'pivot' => ['class' => cd_config('database.e.productCategoryPivot.model.class'), 'repository' => ['class' => cd_config('database.e.productCategoryPivot.repository.class')]]]]]];