-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME
48 lines (38 loc) · 2.14 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
Extends Yii Frameworks CListView for selecting `List View' page size.
You can use EListView in place of CListView (Takes all the same Params and add a few new ones).
You will get a select menu with a list of various page sizes that you define while maintaining the current start position.
Params:
itemsPerPageMenu
Sets the values for the `Items Per Page Menu'
Example: 'itemsPerPageMenu'=>array(10,20,50,100,200,500),
itemsPerPageMenuItemOptionPrefix
Sets the display prefix in the `Items Per Page Menu' PREFIX X SUFFIX ie VIEW 10 Per Page
Example: 'itemsPerPageMenuItemOptionPrefix'=>'View'
itemsPerPageMenuItemOptionSufix
Sets the display suffix in the `Items Per Page Menu' PREFIX X SUFFIX ie VIEW 10 Per Page
Example: 'itemsPerPageMenuItemOptionSufix'=>'Per Page'
itemsPerPageMenuClass
Sets the Class of the `Items Per Page Menu' <select class=".$itemsPerPageMenuClass"...
Example: 'itemsPerPageMenuClass'=>'ippm'
scrollToItem
Array that Sets the scroll to item in view attributes. This is usefull when swithing between page sizes.
on => When to scroll.
Choices: ['ALWAYS', 'MISTACH', 'NEVER']
containerEntity => The Dom element to scroll
itemClass => The Class of the Dom Elment that contain the individual items.
Example: 'scrollToItem'=>array('on'=>'MISMATCH', 'containerEntity'=>'body', 'itemClass'=>'view')
renderMenuInAltDomElmWithID
Sets the #ID of the DOM element where you would like to render the menu.
By default (false) the `Items Per Page Menu' will be rendered in the summary section.
Example: 'renderMenuInAltDomElmWithID'=>false, //use and DOM ELEMENT ID IE "myID"
SAMPLE USAGE:
<?php $this->widget('ext.widgets.EListView.EListView', array(
'dataProvider'=>$dataProvider,
'itemView'=>'_view',
'itemsPerPageMenu'=>array(10,20,50,100,200,500),
'itemsPerPageMenuItemOptionPrefix'=>'View',
'itemsPerPageMenuItemOptionSufix'=>'Per Page',
'itemsPerPageMenuClass'=>'ippm',
'scrollToItem'=>array('on'=>'MISMATCH', 'containerEntity'=>'body', 'itemClass'=>'view'),
'renderMenuInAltDomElmWithID'=>false, //use and DOM ELEMENT ID IE "myID"
)); ?>