From 0c06422a170cc7bc0c80d7588c68011840c607fc Mon Sep 17 00:00:00 2001 From: vinnl Date: Tue, 6 May 2008 16:53:30 +0200 Subject: [PATCH] * [Friends] Members can now apply to be added to the contact list. * [Friends] Applications can now be rejected. --- project/modules/friends/Module.php | 2 +- project/modules/friends/controllers/ListController.php | 2 +- project/modules/friends/views/scripts/list/edit.phtml | 8 +++++++- project/modules/openid/controllers/AuthenticationController.php | 1 + 4 files changed, 10 insertions(+), 3 deletions(-) diff --git a/project/modules/friends/Module.php b/project/modules/friends/Module.php index ca71181..2f6600a 100644 --- a/project/modules/friends/Module.php +++ b/project/modules/friends/Module.php @@ -163,7 +163,7 @@ class Friends_Module extends Pivip_Module_Abstract 'contactlist/edit', $options); $router->addRoute('Friends_EditList', $route); $options = array('module' => 'friends', 'controller' => 'friend', - 'action' => 'apply'); + 'action' => 'add'); $route = new Zend_Controller_Router_Route('contacts/apply', $options); $router->addRoute('Friends_ApplyAsFriend', $route); diff --git a/project/modules/friends/controllers/ListController.php b/project/modules/friends/controllers/ListController.php index 6c6ca81..8f37eb4 100644 --- a/project/modules/friends/controllers/ListController.php +++ b/project/modules/friends/controllers/ListController.php @@ -54,7 +54,7 @@ class Friends_ListController extends Page_Abstract $acl->isAllowed($identity->aclRole, 'friendlist', 'apply')) { $this->view->showOptions = true; - $this->view->allowApprove = true; + $this->view->allowApply = true; } if($this->_isAllowed('edit')) { diff --git a/project/modules/friends/views/scripts/list/edit.phtml b/project/modules/friends/views/scripts/list/edit.phtml index 86c3c43..49263d9 100644 --- a/project/modules/friends/views/scripts/list/edit.phtml +++ b/project/modules/friends/views/scripts/list/edit.phtml @@ -23,7 +23,13 @@ if(0 < count($this->toApprove)): ?>
  • name; ?>
  • + >name; ?> + + translate('Reject'); ?> diff --git a/project/modules/openid/controllers/AuthenticationController.php b/project/modules/openid/controllers/AuthenticationController.php index d829c3e..d75308a 100644 --- a/project/modules/openid/controllers/AuthenticationController.php +++ b/project/modules/openid/controllers/AuthenticationController.php @@ -122,6 +122,7 @@ class Openid_AuthenticationController extends Page_Abstract if(false === $openid) { $data['acl_role'] = 'member'; + $data['url'] = $id; $openid = new Openid(); } else { unset($data['acl_role']); -- 2.11.4.GIT