Skip to content

Latest commit

 

History

History
583 lines (299 loc) · 12.8 KB

class.HelperViewCore.md

File metadata and controls

583 lines (299 loc) · 12.8 KB

Class HelperViewCore

Contents

Properties

Methods

Properties

$id

public mixed $id

$table

public mixed $table

$title

public \if $title = null

$token

public mixed $token

$toolbar

public mixed $toolbar = true

$base_folder

public string $base_folder

$base_tpl

public string $base_tpl = 'content.tpl'

$bootstrap

public mixed $bootstrap = false

$context

public mixed $context

$currentIndex

public mixed $currentIndex

$identifier

public mixed $identifier

$module

public \Module $module

$override_folder

public string $override_folder

$ps_help_context

public mixed $ps_help_context

$show_toolbar

public mixed $show_toolbar = true

$toolbar_btn

public mixed $toolbar_btn

$toolbar_scroll

public mixed $toolbar_scroll = false

$tpl

protected \smartyTemplate $tpl

$tpl_vars

public mixed $tpl_vars = array()

Methods

__construct

mixed HelperViewCore::__construct()

createTemplate

\Template HelperCore::createTemplate(string $tpl_name)

Create a template from the override file, else from the base file.

Arguments

  • $tpl_name string - filename

generate

string HelperCore::generate()

default behaviour for helper is to return a tpl fetched

generateView

mixed HelperViewCore::generateView()

l

string HelperCore::l(mixed $string, string $class, \boolan $addslashes, boolean $htmlentities)

use translations files to replace english expression.

Arguments

  • $string mixed - term or expression in english
  • $class string
  • $addslashes boolan - if set to true, the return value will pass through addslashes(). Otherwise, stripslashes().
  • $htmlentities boolean - if set to true(default), the return value will pass through htmlentities($string, ENT_QUOTES, 'utf-8')

renderAdminCategorieTree

mixed HelperCore::renderAdminCategorieTree($translations, $selected_cat, $input_name, $use_radio, $use_search, $disabled_categories, $use_in_popup)

Arguments

  • $translations mixed
  • $selected_cat mixed
  • $input_name mixed
  • $use_radio mixed
  • $use_search mixed
  • $disabled_categories mixed
  • $use_in_popup mixed

renderCategoryTree

string HelperCore::renderCategoryTree(array $root, \type $selected_cat, string $input_name, boolean $use_radio, boolean $use_search, array $disabled_categories, boolean $use_in_popup, boolean $use_shop_context)

Arguments

  • $root array - array with the name and ID of the tree root category, if null the Shop's root category will be used
  • $selected_cat type - array of selected categories Format Array ( [0] => 1 [1] => 2 ) OR Array ( [1] => Array ( [id_category] => 1 [name] => Home page ) )
  • $input_name string - name of input
  • $use_radio boolean - use radio tree or checkbox tree
  • $use_search boolean - display a find category search box
  • $disabled_categories array
  • $use_in_popup boolean
  • $use_shop_context boolean

renderModulesList

mixed HelperCore::renderModulesList($modules_list)

Arguments

  • $modules_list mixed

renderRequiredFields

string HelperCore::renderRequiredFields(string $class_name, string $identifier, array $table_fields)

Render a form with potentials required fields

Arguments

  • $class_name string
  • $identifier string
  • $table_fields array

renderShopList

mixed HelperCore::renderShopList()

setTpl

mixed HelperCore::setTpl($tpl)

Arguments

  • $tpl mixed