summaryrefslogtreecommitdiff
path: root/demos/address-book/protected/pages/AddressProvider.php
diff options
context:
space:
mode:
authorwei <>2007-05-11 12:14:26 +0000
committerwei <>2007-05-11 12:14:26 +0000
commit4a6af98cfcf115219216b2f1102cc3785083c6c8 (patch)
tree618d8bf057918bf3886a055c4b731ce7609f2fcb /demos/address-book/protected/pages/AddressProvider.php
parentf03007a11887dbc4139d5d259c8e9fa18c4488bb (diff)
Update address book demo
Diffstat (limited to 'demos/address-book/protected/pages/AddressProvider.php')
-rw-r--r--demos/address-book/protected/pages/AddressProvider.php27
1 files changed, 2 insertions, 25 deletions
diff --git a/demos/address-book/protected/pages/AddressProvider.php b/demos/address-book/protected/pages/AddressProvider.php
index ae0b369f..94b71e11 100644
--- a/demos/address-book/protected/pages/AddressProvider.php
+++ b/demos/address-book/protected/pages/AddressProvider.php
@@ -1,36 +1,13 @@
-<?php
-
+<?php
Prado::using('Application.pages.AddressRecord');
/**
* @author Wei Zhuo <weizho[at]gmail[dot]com>
* @version $Id$
* @since 3.1
*/
-class AddressProvider extends TApplicationComponent
+class AddressProvider
{
/**
- * @throws exception if not logged in
- */
- public function __construct($server)
- {
- $authMethods = $server->getRequestedMethod()!=='login';
- $guestUser = $this->User ? $this->User->IsGuest : true;
- if($authMethods && $guestUser)
- throw new TException('authentication required');
- }
-
- /**
- * @param string $username
- * @param string $password
- * @return boolean
- * @soapmethod
- */
- public function login($username, $password)
- {
- return $this->Application->Modules['auth']->login($username, $password);
- }
-
- /**
* @return AddressRecord[]
* @soapmethod
*/