Class Navigator
Object
|
+--MoreMotionObject
|
+--Navigator
- class
Navigator
- extends MoreMotionObject
Represents a Data Source Navigator.
Defined in Navigator.js
|
Field Summary |
Object |
callbackCustomData
The custom data object to pass to the callback function defined with this.props.callbackFunc
property. |
Object |
callbackFunc
The callback function to be called after the ajax navigation. |
HTMLElement |
cpelm
Handle to the "currentPage" element |
HTMLElement |
ippelm
Handle to the "itemsPerPage" element |
HTMLElement |
pielm
Handle to the "pageIndex" element |
HTMLElement |
ppbelm
Handle to the "pagesPerBlock" element |
Object |
props
Navigator Properties Object. |
callbackCustomData
Object callbackCustomData
callbackFunc
Object callbackFunc
The callback function to be called after the ajax navigation.
Before submiting the navigation request with ajax this field is checked to see it contains
a function. If this field is null then this.props.callbackFunc property is
checked to see if it contains a callback function name.
cpelm
HTMLElement cpelm
Handle to the "currentPage" element
ippelm
HTMLElement ippelm
Handle to the "itemsPerPage" element
pielm
HTMLElement pielm
Handle to the "pageIndex" element
ppbelm
HTMLElement ppbelm
Handle to the "pagesPerBlock" element
props
Object props
Navigator Properties Object.
| dataSource | The name of the data source to navigate over |
| submitType | The Submit Type of the navigation request. The valid values are:
- Http Get
- Http Post
- Ajax
|
| pagingInfo | This property contains paging info for the specified data source. It contains
the following sub-properties that are separated with semicolumn chars.
noi - Number of items
cp - Current page number
ipp - Items per page
ppb - Pages per block
lp - Last page flag
mp - More pages flag
fp - The number of the first page in the block
tp - The number of the last page in the block
Example value: noi:340;cp:5;ipp:10;ppb:5;lp:false;mp:true;fp:51;tp:60
|
| focusTo | The code of the input element which should gain focus
after the navigation. The codes are:
cp - Current page element
ipp - Items per page element
ppb - Pages per block element
|
| callbackFunc | The name of the Javascript function to be called after the Ajax navigation |
| errorHandler | The name of the Javascript function to be called to handle the errors during the Ajax navigation |
| commandName | The name of the Ajax ProcessCommand to use for the Ajax navigation |
| beforeSubmitFunc | The name of the javascript function to be called before the
navigate request is submitted. The function receives Navigator object as the parameter. |
| requiredBlocks | The names of the blocks (separated with commas) to be
validated before submitting the form with this command |
| skin |
Initial skin of the navigator. It can be changed using changeSkin() method. To create new skins copy the folder /moremotion/face/Navigators/default/ and modify.
|
Navigator
Navigator(node)
Parameters:
node - the DOM Element node that is marked as a Navigator by means of "mo:type" attribute with a value of "Navigator".
addRequestParameter
void addRequestParameter(name, value)
Adds the given parameter to the navigation request parameters.
Parameters:
name - The name of the parameter
value - The value of the parameter
changeSkin
void changeSkin(newSkin)
init
void init()
navigateTo
void navigateTo(page, focusTo)
Navigates to the specified page.
Parameters:
page - The page to navigate. The valid values are "nextPage", "previousPage", "firstPage", "lastPage", "nextBlock", "previousBlock" or a page number.
focusTo - The code of the input element which should gain focus after the navigation. Codes: cp: currentPage Element, ipp: itemsPerPage Element, ppb: pagesPerBlock Element
setCommandName
String setCommandName(name)
Sets the name command to submit with "_cmd" parameter.
Parameters:
name - The name of the command
Copyright 2002 - 2011, MOR YAZILIM
Documentation generated by
JSDoc on Fri Mar 4 11:53:29 2011