From 5885bd12735637430e093c896499c3f26832fceb Mon Sep 17 00:00:00 2001 From: wei <> Date: Wed, 21 Mar 2007 03:27:12 +0000 Subject: minor AR updates, remove obsolete TApplication::$_pageService --- .../protected/pages/Database/Scaffold.page | 80 ++++++++++++++++++---- 1 file changed, 66 insertions(+), 14 deletions(-) (limited to 'demos/quickstart/protected/pages') diff --git a/demos/quickstart/protected/pages/Database/Scaffold.page b/demos/quickstart/protected/pages/Database/Scaffold.page index 055cac26..b2d52b6d 100644 --- a/demos/quickstart/protected/pages/Database/Scaffold.page +++ b/demos/quickstart/protected/pages/Database/Scaffold.page @@ -17,6 +17,7 @@ the following builtin functionality:
The above code will list the current records in the users table. +Each record can be edited by clicking on the "edit" button and deleted by +clicking on the "delete" button. A new record can be added by clicking on the +"Add new record" button, enter some data (notice the automatic validation of required fields and data types), and click the "save" button. +Specifying search terms in the search textbox to find particular records. Finally, the +record list can be sorted for each column by changing the sorting column and order. +
+ +The TScaffoldView is a template control composed of other scaffold controls. +The following properties gives access to these composite controls.
++ All these composite controls can be customized as we shall see below. +
+ +A list of Active Records can be displayed using the TScaffoldListView +with the following useful properties.
+Other views... list view
+Custom rendering of the each Active Record can be achieved by specifying +the ItemTemplate and/or AlternatingItemTemplate property of the List +repeater. +The TScaffoldListView will listen for two command events named "delete" and +"edit". A "delete" command will delete a the record for the row where the "delete" command originates. +An "edit" command will push the record data to be edited by a +TScaffoldEditView with ID specified by the EditViewID property. +The following example lists the usernames only with bold formatting. +
edit view...
+The SearchCondition property and +SearchParameters property (takes array values) can be +specified to customize the records to be shown. The SearchCondition +will be used as the Condition property of TActiveRecordCriteria +and the SearchParameters property corresponds to +Parameters property of TActiveRecordCriteria.
+ +Combining list + edit views
+custom list view...
+To be completed...
- -Address book example...
- -