From b9f9a16d7eefc48ac489c8cb2b87749459bb3d38 Mon Sep 17 00:00:00 2001 From: "ctrlaltca@gmail.com" <> Date: Thu, 2 Jun 2011 09:56:29 +0000 Subject: merged documentation changes from branch/3.1 to trunk/ --- .../pages/ActiveControls/ActiveDataGrid.page | 83 +++++++++++++ .../pages/ActiveControls/ActiveDataList.page | 23 ++++ .../pages/ActiveControls/ActiveRepeater.page | 24 ++++ .../protected/pages/ActiveControls/Home.page | 6 +- .../Samples/TActiveDataGrid/Sample1.page | 3 +- .../Samples/TActiveDataGrid/Sample1.php | 10 +- .../Samples/TActiveDataGrid/Sample2.page | 17 ++- .../Samples/TActiveDataGrid/Sample2.php | 7 +- .../Samples/TActiveDataGrid/Sample3.page | 4 +- .../Samples/TActiveDataGrid/Sample3.php | 2 +- .../Samples/TActiveDataGrid/Sample4.page | 2 +- .../Samples/TActiveDataGrid/Sample4.php | 2 +- .../Samples/TActiveDataGrid/Sample5.page | 39 +----- .../Samples/TActiveDataGrid/Sample5.php | 16 ++- .../Samples/TActiveDataGrid/Sample6.page | 26 ---- .../Samples/TActiveDataGrid/Sample6.php | 56 --------- .../Samples/TActiveDataList/Home.page | 125 +++++++++++++++++++ .../Samples/TActiveDataList/Home.php | 132 +++++++++++++++++++++ .../Samples/TActiveRepeater/Home.page | 92 ++++++++++++++ .../Samples/TActiveRepeater/Home.php | 79 ++++++++++++ .../Samples/TActiveRepeater/RegionDisplay.php | 28 ----- .../Samples/TActiveRepeater/RegionDisplay.tpl | 34 ------ .../Samples/TActiveRepeater/Sample1.page | 47 -------- .../Samples/TActiveRepeater/Sample1.php | 41 ------- .../Samples/TActiveRepeater/Sample2.page | 58 --------- .../Samples/TActiveRepeater/Sample2.php | 79 ------------ .../Samples/TActiveRepeater/Sample3.page | 104 ---------------- .../Samples/TActiveRepeater/Sample3.php | 84 ------------- .../Samples/TActiveRepeater/Sample4.page | 27 ----- .../Samples/TActiveRepeater/Sample4.php | 43 ------- .../Samples/TActiveRepeater/Sample5.page | 18 --- .../Samples/TActiveRepeater/Sample5.php | 52 -------- .../protected/pages/Controls/DataGrid.page | 3 +- .../protected/pages/Controls/DataList.page | 2 + .../protected/pages/Controls/Repeater.page | 1 + 35 files changed, 597 insertions(+), 772 deletions(-) create mode 100644 demos/quickstart/protected/pages/ActiveControls/ActiveDataGrid.page create mode 100644 demos/quickstart/protected/pages/ActiveControls/ActiveDataList.page create mode 100644 demos/quickstart/protected/pages/ActiveControls/ActiveRepeater.page delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveDataGrid/Sample6.page delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveDataGrid/Sample6.php create mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveDataList/Home.page create mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveDataList/Home.php create mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Home.page create mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Home.php delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/RegionDisplay.php delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/RegionDisplay.tpl delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample1.page delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample1.php delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample2.page delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample2.php delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample3.page delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample3.php delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample4.page delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample4.php delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample5.page delete mode 100644 demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRepeater/Sample5.php (limited to 'demos/quickstart') diff --git a/demos/quickstart/protected/pages/ActiveControls/ActiveDataGrid.page b/demos/quickstart/protected/pages/ActiveControls/ActiveDataGrid.page new file mode 100644 index 00000000..9a82743d --- /dev/null +++ b/demos/quickstart/protected/pages/ActiveControls/ActiveDataGrid.page @@ -0,0 +1,83 @@ + + +

TActiveDataGrid

+ + +

+TActiveDataGrid represents a data bound and updatable grid control which is the +active counterpart to the original TDataGrid control. +

+ +

+This component can be used in the same way as the regular datagrid, the only +difference is that the active datagrid uses callbacks instead of postbacks +for interaction. +

+ +

+PRADO provides eight new types of active columns that can be used inside TActiveDataGrid; +they are the active counterpart of TDataGrid's columns: +

+ + +

+Please refer to the original documentation of TDataGrid for basic usage. +

+ + +

Columns

+ +

Automatically Generated Columns

+

+TDataGrid by default will create a list of columns based on the structure of the bound data. TDataGrid will read the first row of the data, extract the field names of the row, and construct a column for each field. Each column is of type TActiveBoundColumn. All of this happens in an ajax callback. +

+ + + +

Manually Specified Columns

+

+The following example uses manually specified columns to show a list of book information, +

+
    +
  • Book title - displayed as a hyperlink pointing to the corresponding amazon.com book page. TActiveHyperLinkColumn is used.
  • +
  • Publisher - displayed as a piece of text using TvBoundColumn.
  • +
  • Price - displayed as a piece of text using TActiveBoundColumn with output formatting string and customized styles.
  • +
  • In-stock or not - displayed as a checkbox using TActiveCheckBoxColumn.
  • +
  • Rating - displayed as an image using TActiveTemplateColumn which allows maximum freedom in specifying cell contents.
  • +
+

+Each column can be shown or hidden in a callback. +

+ + + +

Interacting with TActiveDataGrid

+

+The following example shows how to make the previous book information table an interactive one. It allows users to edit and delete book items from the table. Two additional columns are used in the example to allow users interact with the datagrid: TActiveEditCommandColumn and TActiveButtonColumn. In addition, +TActiveDropDownListColumn replaces the previous TActiveTemplateColumn to allow users to select a rating from a dropdown list. Note, it is also possible to use TActiveTemplateColumn to achieve the same task. +All the iteration is done using AJAX callbacks. +

+ + +

Sorting

+

+The following example turns the datagrid in Example 2 into a sortable one. Users can click on the link button displayed in the header of any column, and the data will be sorted in ascending order along that column. The grid is sorted and rendered upon a callback request. +

+ + +

Paging

+

+The following example enables the paging functionality of the datagrid shown in Example 1. In this example, you move between the datagrid pages clicking on the pager links. The grid reacts to paging rendering itself as the result of a callback request. Note that you can't change the pager style upon callback. +

+ + +
$Id$
\ No newline at end of file diff --git a/demos/quickstart/protected/pages/ActiveControls/ActiveDataList.page b/demos/quickstart/protected/pages/ActiveControls/ActiveDataList.page new file mode 100644 index 00000000..12fb941f --- /dev/null +++ b/demos/quickstart/protected/pages/ActiveControls/ActiveDataList.page @@ -0,0 +1,23 @@ + + +

TActiveDataList

+ + +

+TActiveDataList represents a data bound and updatable list control which is the +active counterpart to the original TDataList control. +

+ +

+This component can be used in the same way as the regular datalist, the only +difference is that the active datalist uses callbacks instead of postbacks +for interaction. +

+ +

+Please refer to the original documentation of TDataList for usage. +

+ + + +
$Id$
\ No newline at end of file diff --git a/demos/quickstart/protected/pages/ActiveControls/ActiveRepeater.page b/demos/quickstart/protected/pages/ActiveControls/ActiveRepeater.page new file mode 100644 index 00000000..d22a7467 --- /dev/null +++ b/demos/quickstart/protected/pages/ActiveControls/ActiveRepeater.page @@ -0,0 +1,24 @@ + + +

TActiveRepeater

+ + +

+TActiveRepeater represents a data bound and updatable repeater control which is the +active counterpart to the original TRepeater control. +

+ +

+This component can be used in the same way as the regular repeater, the only +difference is that the active repeater uses callbacks instead of postbacks +for interaction. +

+ +

+Please refer to the original documentation of TRepeater for usage. +

+ + + + +
$Id$
\ No newline at end of file diff --git a/demos/quickstart/protected/pages/ActiveControls/Home.page b/demos/quickstart/protected/pages/ActiveControls/Home.page index 93b5b6eb..798bc267 100644 --- a/demos/quickstart/protected/pages/ActiveControls/Home.page +++ b/demos/quickstart/protected/pages/ActiveControls/Home.page @@ -136,19 +136,19 @@ TActiveButton control. See also the later part of the Active Data Controls