summaryrefslogtreecommitdiff
path: root/demos/quickstart/protected/pages/Tutorial
diff options
context:
space:
mode:
authorxue <>2007-03-06 20:40:51 +0000
committerxue <>2007-03-06 20:40:51 +0000
commit8a674fb83fa2dd80bc653745e03b24450a9cf68d (patch)
tree83f72026185075b0ffacf5c1996d3424b0e2f31f /demos/quickstart/protected/pages/Tutorial
parent2ab695a553abf26e530f5e97c1ea357233d80998 (diff)
changed the way to specify active record table.
Diffstat (limited to 'demos/quickstart/protected/pages/Tutorial')
-rw-r--r--demos/quickstart/protected/pages/Tutorial/AjaxChat.page8
-rw-r--r--demos/quickstart/protected/pages/Tutorial/fr/AjaxChat.page8
2 files changed, 8 insertions, 8 deletions
diff --git a/demos/quickstart/protected/pages/Tutorial/AjaxChat.page b/demos/quickstart/protected/pages/Tutorial/AjaxChat.page
index 7d978a12..4e40b33a 100644
--- a/demos/quickstart/protected/pages/Tutorial/AjaxChat.page
+++ b/demos/quickstart/protected/pages/Tutorial/AjaxChat.page
@@ -168,11 +168,11 @@ as <tt>App_Code/chat.db</tt>.
<com:TTextHighlighter Language="php" CssClass="source block-content" id="code_90033">
class ChatUserRecord extends TActiveRecord
{
+ const TABLE='chat_users';
+
public $username;
public $last_activity;
- public static $_tablename='chat_users';
-
public static function finder($className=__CLASS__)
{
return parent::finder($className);
@@ -502,14 +502,14 @@ The corresponding <tt>ChatBufferRecord</tt> class is saved as
<com:TTextHighlighter Language="php" CssClass="source block-content" id="code_90045">
class ChatBufferRecord extends TActiveRecord
{
+ const TABLE='chat_buffer';
+
public $id;
public $for_user;
public $from_user;
public $message;
private $_created_on;
- public static $_tablename='chat_buffer';
-
public function getCreated_On()
{
if($this->_created_on === null)
diff --git a/demos/quickstart/protected/pages/Tutorial/fr/AjaxChat.page b/demos/quickstart/protected/pages/Tutorial/fr/AjaxChat.page
index 7bc36d5f..24c5ea76 100644
--- a/demos/quickstart/protected/pages/Tutorial/fr/AjaxChat.page
+++ b/demos/quickstart/protected/pages/Tutorial/fr/AjaxChat.page
@@ -168,11 +168,11 @@ as <tt>App_Code/chat.db</tt>.
<com:TTextHighlighter Language="php" CssClass="source block-content" id="code_90033">
class ChatUserRecord extends TActiveRecord
{
+ const TABLE='chat_users';
+
public $username;
public $last_activity;
- public static $_tablename='chat_users';
-
public static function finder($className=__CLASS__)
{
return parent::finder($className);
@@ -502,14 +502,14 @@ The corresponding <tt>ChatBufferRecord</tt> class is saved as
<com:TTextHighlighter Language="php" CssClass="source block-content" id="code_90045">
class ChatBufferRecord extends TActiveRecord
{
+ const TABLE='chat_buffer';
+
public $id;
public $for_user;
public $from_user;
public $message;
private $_created_on;
- public static $_tablename='chat_buffer';
-
public function getCreated_On()
{
if($this->_created_on === null)