[ Index ]

PHP Cross Reference of Joomla 4.2.2 documentation

title

Body

[close]

/administrator/components/com_menus/src/Controller/ -> ItemController.php (summary)

(no description)

Copyright: (C) 2009 Open Source Matters, Inc.
License: GNU General Public License version 2 or later; see LICENSE.txt
File Size: 582 lines (20 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

ItemController:: (11 methods):
  allowAdd()
  allowEdit()
  getMenuTypeId()
  add()
  batch()
  cancel()
  edit()
  getRedirectToItemAppend()
  save()
  setType()
  getParentItem()


Class: ItemController  - X-Ref

The Menu ItemModel  Controller

allowAdd($data = array()   X-Ref
Method to check if you can add a new record.

Extended classes can override this if necessary.

param: array  $data  An array of input data.
return: boolean

allowEdit($data = array()   X-Ref
Method to check if you edit a record.

Extended classes can override this if necessary.

param: array   $data  An array of input data.
param: string  $key   The name of the key for the primary key; default is id.
return: boolean

getMenuTypeId($menutype)   X-Ref
Loads the menutype ID by a given menutype string

param: string  $menutype  The given menutype
return: integer

add()   X-Ref
Method to add a new menu item.

return: mixed  True if the record can be added, otherwise false.

batch($model = null)   X-Ref
Method to run batch operations.

param: object  $model  The model.
return: boolean  True if successful, false otherwise and internal error is set.

cancel($key = null)   X-Ref
Method to cancel an edit.

param: string  $key  The name of the primary key of the URL variable.
return: boolean  True if access level checks pass, false otherwise.

edit($key = null, $urlVar = null)   X-Ref
Method to edit an existing record.

param: string  $key     The name of the primary key of the URL variable.
param: string  $urlVar  The name of the URL variable if different from the primary key
return: boolean  True if access level check and checkout passes, false otherwise.

getRedirectToItemAppend($recordId = null, $urlVar = 'id')   X-Ref
Gets the URL arguments to append to an item redirect.

param: integer  $recordId  The primary key id for the item.
param: string   $urlVar    The name of the URL variable for the id.
return: string  The arguments to append to the redirect URL.

save($key = null, $urlVar = null)   X-Ref
Method to save a record.

param: string  $key     The name of the primary key of the URL variable.
param: string  $urlVar  The name of the URL variable if different from the primary key (sometimes required to avoid router collisions).
return: boolean  True if successful, false otherwise.

setType()   X-Ref
Sets the type of the menu item currently being edited.

return: void

getParentItem()   X-Ref
Gets the parent items of the menu location currently.

return: void



Generated: Wed Sep 7 05:41:13 2022 Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer