Permalink
Browse files

Removed Group and Permissions. Start refactoring of users,groups an p…

…ermissions functionalities
  • Loading branch information...
1 parent 48e0366 commit 44ef0a8fca83a672bd7487a3be936b4233dd59fc Filippo committed Jul 27, 2010
Showing with 91 additions and 1,610 deletions.
  1. +0 −3 apps/fe/modules/sfGuardGroup/config/security.yml
  2. +0 −4 apps/fe/modules/sfGuardGroup/config/view.yml
  3. +0 −27 apps/fe/modules/sfGuardGroup/templates/editSuccess.php
  4. +0 −48 apps/fe/modules/sfGuardGroup/templates/indexSuccess.php
  5. +0 −26 apps/fe/modules/sfGuardGroup/templates/newSuccess.php
  6. +0 −3 apps/fe/modules/sfGuardPermission/config/security.yml
  7. +0 −4 apps/fe/modules/sfGuardPermission/config/view.yml
  8. +0 −28 apps/fe/modules/sfGuardPermission/templates/editSuccess.php
  9. +0 −48 apps/fe/modules/sfGuardPermission/templates/indexSuccess.php
  10. +0 −26 apps/fe/modules/sfGuardPermission/templates/newSuccess.php
  11. +0 −2 apps/fe/modules/sfGuardUser/templates/indexSuccess.php
  12. +0 −2 apps/fe/modules/sfGuardUser/templates/newSuccess.php
  13. BIN data/phpcollab_unit_test.db
  14. +0 −64 plugins/idProjectManagementPlugin/config/routing.yml
  15. +1 −0 plugins/idProjectManagementPlugin/lib/form/IdProjectForm.class.php
  16. +0 −45 plugins/idProjectManagementPlugin/lib/helper/__blaz__AutoLinkHelper.php
  17. +5 −0 plugins/idProjectManagementPlugin/lib/model/doctrine/PluginProjectUser.class.php
  18. +0 −76 plugins/idProjectManagementPlugin/lib/pager/idPager.php
  19. +1 −1 plugins/idProjectManagementPlugin/modules/idPriority/actions/actions.class.php
  20. +3 −3 plugins/idProjectManagementPlugin/modules/idProject/actions/actions.class.php
  21. +0 −46 plugins/idProjectManagementPlugin/modules/idProject/templates/_content_table.php
  22. +0 −32 plugins/idProjectManagementPlugin/modules/idProject/templates/_content_table_list.php
  23. +1 −1 plugins/idProjectManagementPlugin/modules/idProject/templates/_create_project_menu.php
  24. +0 −4 plugins/idProjectManagementPlugin/modules/idProject/templates/_sf_guard_actions.php
  25. +0 −7 plugins/idProjectManagementPlugin/modules/idProject/templates/_sf_guard_create_menu.php
  26. +0 −53 plugins/idProjectManagementPlugin/modules/idProject/templates/_sf_guard_filters.php
  27. +0 −8 plugins/idProjectManagementPlugin/modules/idProject/templates/_sf_guard_form_footer.php
  28. +0 −18 plugins/idProjectManagementPlugin/modules/idProject/templates/_sf_guard_form_header.php
  29. +0 −16 plugins/idProjectManagementPlugin/modules/idProject/templates/_sf_guard_th_as_ordering_links.php
  30. +1 −10 plugins/idProjectManagementPlugin/modules/idProject/templates/editSuccess.php
  31. +71 −7 plugins/idProjectManagementPlugin/modules/idProject/templates/newSuccess.php
  32. +1 −1 plugins/idProjectManagementPlugin/modules/idStatus/actions/actions.class.php
  33. +0 −9 test/fixtures/sfGuardGroup.yml
  34. +0 −294 test/fixtures/sfGuardGroupPermission.yml
  35. +0 −129 test/fixtures/sfGuardPermission.yml
  36. +0 −18 test/fixtures/sfGuardUserGroup.yml
  37. +6 −41 test/functional/fe/idProjectCreateTest.php
  38. +1 −6 test/functional/fe/idProjectEditTest.php
  39. +0 −29 test/functional/fe/idProjectGroupDeleteTest.php
  40. +0 −26 test/functional/fe/idProjectPermissionDeleteTest.php
  41. +0 −39 test/functional/fe/idProjectUserGroupCreateTest.php
  42. +0 −61 test/functional/fe/idProjectUserGroupEditTest.php
  43. +0 −40 test/functional/fe/idProjectUserGroupFilterTest.php
  44. +0 −60 test/functional/fe/idProjectUserGroupViewTest.php
  45. +0 −40 test/functional/fe/idProjectUserPermissionCreateTest.php
  46. +0 −60 test/functional/fe/idProjectUserPermissionEditTest.php
  47. +0 −40 test/functional/fe/idProjectUserPermissionFilterTest.php
  48. +0 −59 test/functional/fe/idProjectUserPermissionViewTest.php
  49. +0 −23 test/functional/fe/sfGuardGroupSubNavigationMenuTest.php
  50. +0 −23 test/functional/fe/sfGuardPermissionSubNavigationMenuTest.php
@@ -1,3 +0,0 @@
-all:
- is_secure: true
- credentials: admin
@@ -1,4 +0,0 @@
-default:
- components:
- sidebar: []
-
@@ -1,27 +0,0 @@
-
-<?php slot('title', __('Edit a group')) ?>
-
-
-<div class="block" id="block-tables">
-
- <?php include_partial('idProject/sf_guard_create_menu', array('module_name' => 'group')); ?>
-
- <div class="content">
- <h2 class="title"><?php echo __('Edit group') ?></h2>
- <div class="inner">
- <?php echo form_tag_for($form, '@sf_guard_group', array('class' =>'form')) ?>
-
- <?php include_partial('idProject/sf_guard_form_header', array('form' => $form, 'module_name' => 'group')); ?>
-
- <table class="table">
-
- <?php include_partial('idProject/content_table', array('configuration' => $configuration, 'form' => $form)); ?>
-
- </table>
-
- <?php include_partial('idProject/sf_guard_form_footer', array('form' => $form, 'module_name' => 'group')); ?>
-
- </form>
- </div>
- </div>
-</div>
@@ -1,48 +0,0 @@
-<?php slot('title', __('Manage groups')) ?>
-
-<?php include_partial('idProject/sf_guard_filters', array(
- 'form' => $filters,
- 'configuration' => $configuration,
- 'module_name' => 'group',
- 'fields' => array('name',
- 'description'),
- )); ?>
-
-<div class="block" id="block-tables">
-
- <?php include_partial('idProject/sf_guard_create_menu', array('module_name' => 'group')); ?>
-
- <div class="content">
- <h2 class="title"><?php echo __('Groups list') ?></h2>
- <div class="inner">
- <table class="table">
-
- <tr>
- <th class="first">&nbsp;</th>
-
- <?php include_partial('idProject/sf_guard_th_as_ordering_links', array(
- 'sort' => $sort,
- 'module_name' => 'group',
- 'fields' => array(
- 'name',
- 'description'
- )
- )); ?>
-
- <th class="last"><?php echo __('Actions') ?></th>
- </tr>
-
- <?php include_partial('idProject/content_table_list', array(
- 'pager' => $pager,
- 'module_name' => 'group',
- 'fields' => array(
- 'name',
- 'description'
- )
- )); ?>
-
- </table>
-
- </div>
- </div>
-</div>
@@ -1,26 +0,0 @@
-
-<?php slot('title', __('Create a new Group')) ?>
-
-<div class="block" id="block-tables">
-
- <?php include_partial('idProject/sf_guard_create_menu', array('module_name' => 'group')); ?>
-
- <div class="content">
- <h2 class="title"><?php echo __('New group creation') ?></h2>
- <div class="inner">
- <?php echo form_tag_for($form, '@sf_guard_group', array('class' =>'form')) ?>
-
- <?php include_partial('idProject/sf_guard_form_header', array('form' => $form, 'module_name' => 'group')); ?>
-
- <table class="table">
-
- <?php include_partial('idProject/content_table', array('configuration' => $configuration, 'form' => $form)); ?>
-
- </table>
-
- <?php include_partial('idProject/sf_guard_form_footer', array('form' => $form, 'module_name' => 'group')); ?>
-
- </form>
- </div>
- </div>
-</div>
@@ -1,3 +0,0 @@
-all:
- is_secure: true
- credentials: admin
@@ -1,4 +0,0 @@
-default:
- components:
- sidebar: []
-
@@ -1,28 +0,0 @@
-
-<?php slot('title', __('Edit a permission')) ?>
-
-
-<div class="block" id="block-tables">
-
- <?php include_partial('idProject/sf_guard_create_menu', array('module_name' => 'permission')); ?>
-
- <div class="content">
- <h2 class="title"><?php echo __('Edit permission') ?></h2>
- <div class="inner">
- <?php echo form_tag_for($form, '@sf_guard_permission', array('class' =>'form')) ?>
-
- <?php include_partial('idProject/sf_guard_form_header', array('form' => $form, 'module_name' => 'permission')); ?>
-
- <table class="table">
-
- <?php include_partial('idProject/content_table', array('configuration' => $configuration, 'form' => $form)); ?>
-
- </table>
-
- <?php include_partial('idProject/sf_guard_form_footer', array('form' => $form, 'module_name' => 'permission')); ?>
-
- </form>
- </div>
- </div>
-</div>
-
@@ -1,48 +0,0 @@
-<?php slot('title', __('Manage permissions')) ?>
-
-<?php include_partial('idProject/sf_guard_filters', array(
- 'form' => $filters,
- 'configuration' => $configuration,
- 'module_name' => 'permission',
- 'fields' => array('name',
- 'description'),
- )); ?>
-
-<div class="block" id="block-tables">
-
- <?php include_partial('idProject/sf_guard_create_menu', array('module_name' => 'permission')); ?>
-
- <div class="content">
- <h2 class="title"><?php echo __('Permissions list') ?></h2>
- <div class="inner">
- <table class="table">
-
- <tr>
- <th class="first">&nbsp;</th>
-
- <?php include_partial('idProject/sf_guard_th_as_ordering_links', array(
- 'sort' => $sort,
- 'module_name' => 'permission',
- 'fields' => array(
- 'name',
- 'description'
- )
- )); ?>
-
- <th class="last"><?php echo __('Actions') ?></th>
- </tr>
-
- <?php include_partial('idProject/content_table_list', array(
- 'pager' => $pager,
- 'module_name' => 'permission',
- 'fields' => array(
- 'name',
- 'description'
- )
- )); ?>
-
- </table>
-
- </div>
- </div>
-</div>
@@ -1,26 +0,0 @@
-
-<?php slot('title', __('Create a new permission')) ?>
-
-<div class="block" id="block-tables">
-
- <?php include_partial('idProject/sf_guard_create_menu', array('module_name' => 'permission')); ?>
-
- <div class="content">
- <h2 class="title"><?php echo __('New permission creation') ?></h2>
- <div class="inner">
- <?php echo form_tag_for($form, '@sf_guard_permission', array('class' =>'form')) ?>
-
- <?php include_partial('idProject/sf_guard_form_header', array('form' => $form, 'module_name' => 'permission')); ?>
-
- <table class="table">
-
- <?php include_partial('idProject/content_table', array('configuration' => $configuration, 'form' => $form)); ?>
-
- </table>
-
- <?php include_partial('idProject/sf_guard_form_footer', array('form' => $form, 'module_name' => 'permission')); ?>
-
- </form>
- </div>
- </div>
-</div>
@@ -4,8 +4,6 @@
<div class="span-full last project-navigation">
<ul>
<li><?php echo link_to('Users', '@sf_guard_user'); ?></li>
- <li><?php echo link_to('Groups', '@sf_guard_group'); ?></li>
- <li><?php echo link_to('Permissions', '@sf_guard_permission'); ?></li>
</ul>
</div>
@@ -4,8 +4,6 @@
<div class="span-full last project-navigation">
<ul>
<li><?php echo link_to('Users', '@sf_guard_user'); ?></li>
- <li><?php echo link_to('Groups', '@sf_guard_group'); ?></li>
- <li><?php echo link_to('Permissions', '@sf_guard_permission'); ?></li>
</ul>
</div>
View
Binary file not shown.
@@ -22,70 +22,6 @@ sf_guard_password:
requirements:
sf_culture: (?:en|it)
-sf_guard_group:
- url: /:sf_culture/sfGuardGroup
- param: { module: sfGuardGroup, action: index }
- requirements:
- sf_culture: (?:en|it)
-
-sf_guard_group_edit:
- url: /:sf_culture/sfGuardGroup/:id/edit
- class: sfDoctrineRoute
- options: { model: sfGuardGroup, type: object }
- param: { module: sfGuardGroup, action: edit }
- requirements:
- id: \d+
- sf_culture: (?:en|it)
-
-sf_guard_group_new:
- url: /:sf_culture/sfGuardGroup/new
- class: sfDoctrineRoute
- options: { model: sfGuardGroup, type: object }
- param: { module: sfGuardGroup, action: new }
- requirements:
- sf_culture: (?:en|it)
-
-sf_guard_group_delete:
- url: /:sf_culture/sfGuardGroup/:id/delete
- class: sfDoctrineRoute
- options: { model: sfGuardGroup, type: object }
- param: { module: sfGuardGroup, action: delete }
- requirements:
- id: \d+
- sf_culture: (?:en|it)
-
-sf_guard_permission:
- url: /:sf_culture/sfGuardPermission
- param: { module: sfGuardPermission, action: index }
- requirements:
- sf_culture: (?:en|it)
-
-sf_guard_permission_edit:
- url: /:sf_culture/sfGuardPermission/:id/edit
- class: sfDoctrineRoute
- options: { model: sfGuardPermission, type: object }
- param: { module: sfGuardPermission, action: edit }
- requirements:
- id: \d+
- sf_culture: (?:en|it)
-
-sf_guard_permission_new:
- url: /:sf_culture/sfGuardPermission/new
- class: sfDoctrineRoute
- options: { model: sfGuardPermission, type: object }
- param: { module: sfGuardPermission, action: new }
- requirements:
- sf_culture: (?:en|it)
-
-sf_guard_permission_delete:
- url: /:sf_culture/sfGuardPermission/:id/delete
- class: sfDoctrineRoute
- options: { model: sfGuardPermission, type: object }
- param: { module: sfGuardPermission, action: delete }
- requirements:
- id: \d+
- sf_culture: (?:en|it)
-
sf_guard_user:
url: /:sf_culture/idUsers
param: { module: sfGuardUser, action: index }
@@ -60,5 +60,6 @@ public function configure()
unset($this['costs']);
unset($this['created_at']);
unset($this['updated_at']);
+ unset($this['is_public']);
}
}
@@ -1,45 +0,0 @@
-<?php
-
-use_helper('Text');
-
-/**
- * This file is part of the phpCollab3 package.
- * (c) 2009 Ideato s.r.l. <phpcollab@ideato.it>
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- *
- * pager_navigation function
- *
- * @package phpCollab3
- * @subpackage idProjectManagementPlugin Helpers
- */
-
-/**
- * Helper for displaying formatted text
- *
- * @package phpCollab3
- * @subpackage idProjectManagementPlugin Helpers
- * @author Filippo (p16) De Santis <fd@ideato.it>
- * @author Andrea (giorg) Giorgini <ag@ideato.it>
- */
-function auto_link($text, $link = 'all')
-{
- if ($link == 'all')
- {
- return _auto_link(_auto_link_email_addresses($text));
- }
- else if ($link == 'email_addresses')
- {
- return _auto_link_email_addresses($text);
- }
- else if ($link == 'urls')
- {
- return _auto_link($text);
- }
-}
-
-function _auto_link($text)
-{
- return preg_replace('@(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.]*(\?\S+)?)?)?)@', '<a href="$1">$1</a>', $text);
-}
@@ -35,4 +35,9 @@ public static function getRoleByProfileIdAndProjectId($profile_id, $project_id)
return $roles[$code];
}
}
+
+ public static function getCodesAndRoles()
+ {
+ return array_flip(self::$roles);
+ }
}
Oops, something went wrong.

0 comments on commit 44ef0a8

Please sign in to comment.