From 8415e4e7b8ef86fc7d8273cba83c23c2ef6851dc Mon Sep 17 00:00:00 2001 From: Ryan Mathis Date: Mon, 14 Dec 2020 13:37:01 -0700 Subject: [PATCH] Latest changes --- Controller/GrouperGroupsController.php | 50 ++++++- View/Elements/Components/groupattributes.ctp | 22 +++ View/Elements/Components/groupproperties.ctp | 42 ++++++ View/Elements/Components/navigation.ctp | 22 ++- View/Elements/Components/search.ctp | 2 +- View/Elements/Components/subscriberList.ctp | 5 + View/GrouperGroups/emaillistinfo.ctp | 95 ++++++++++++ View/GrouperGroups/emaillistsmanaged.ctp | 39 +++++ View/GrouperGroups/emaillistsoptin.ctp | 36 +++++ View/GrouperGroups/groupcreateform.ctp | 149 ++++++++++++++----- View/GrouperGroups/groupinfo.ctp | 91 ++++------- View/GrouperGroups/groupowner.ctp | 18 ++- webroot/css/co-grouper-plugin.css | 3 +- 13 files changed, 460 insertions(+), 114 deletions(-) create mode 100644 View/Elements/Components/groupattributes.ctp create mode 100644 View/Elements/Components/groupproperties.ctp create mode 100644 View/Elements/Components/subscriberList.ctp create mode 100644 View/GrouperGroups/emaillistinfo.ctp create mode 100644 View/GrouperGroups/emaillistsmanaged.ctp create mode 100644 View/GrouperGroups/emaillistsoptin.ctp diff --git a/Controller/GrouperGroupsController.php b/Controller/GrouperGroupsController.php index f7b71db..db63416 100644 --- a/Controller/GrouperGroupsController.php +++ b/Controller/GrouperGroupsController.php @@ -9,10 +9,12 @@ class GrouperGroupsController extends GrouperLiteAppController public $components = array('Flash'); public $name = 'GrouperGroups'; - public $userId = ''; + public $userId = 'ryan.mathis@at.internet2.edu'; public function index() { - return $this->redirect(array('controller' => 'GrouperGroups', 'action' => 'groupoptin')); + return $this->redirect( + array('controller' => 'GrouperGroups', 'action' => 'groupoptin') + ); } @@ -29,7 +31,7 @@ public function groupInfo() $details = $this->GrouperGroup->groupDescriptions($name); $this->set('groupname', $name); - $this->set('title', 'Grouper Groups Info and Attributes:'); + $this->set('title', 'Group configuration and attributes'); $this->set('groupergroupsdetail', $details[0]); } @@ -58,6 +60,48 @@ public function groupOptin() } } + public function emailListsOptin() + { + $this->set('title', 'Email lists'); + // mock data + $this->set('group', array( + 'member' => true, + 'name' => 'Email List 1', + 'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.', + 'enabled' => 'T' + )); + } + + public function emailListsManaged() + { + $this->set('title', 'Email lists I manage'); + // mock data + $this->set('group', array( + 'member' => true, + 'name' => 'Email List 1', + 'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.', + 'enabled' => 'T' + )); + } + + public function emailListInfo() + { + $this->set('title', 'Email list configuration and attributes'); + // mock data + $this->set('groupergroupsdetail', array( + 'member' => true, + 'uuid' => 'abc123xyz789', + 'displayExtension' => 'email-list-1', + 'extension' => 'email-list-1', + 'displayName' => 'Email List 1', + 'typeOfGroup' => 'list', + 'name' => 'Email List 1', + 'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.', + 'enabled' => 'T', + 'attributes' => array() + )); + } + public function groupCreateForm() { $this->set('title', 'Create Grouper Group'); } diff --git a/View/Elements/Components/groupattributes.ctp b/View/Elements/Components/groupattributes.ctp new file mode 100644 index 0000000..11cb6a7 --- /dev/null +++ b/View/Elements/Components/groupattributes.ctp @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + +
Attribute nameAttribute descriptionAction
+ + View + +
\ No newline at end of file diff --git a/View/Elements/Components/groupproperties.ctp b/View/Elements/Components/groupproperties.ctp new file mode 100644 index 0000000..7f78303 --- /dev/null +++ b/View/Elements/Components/groupproperties.ctp @@ -0,0 +1,42 @@ +
+
Display Name:
+
+ +
+
+
+
Grouper Name:
+
+ +
+
+
+
Display Extension:
+
+ +
+
+
+
Extension:
+
+ +
+
+
+
Enabled:
+
+ +
+
+
+
Type of Group:
+
+ +
+
+
+
UUID:
+
+ +
+
\ No newline at end of file diff --git a/View/Elements/Components/navigation.ctp b/View/Elements/Components/navigation.ctp index 4547920..fc5c06c 100644 --- a/View/Elements/Components/navigation.ctp +++ b/View/Elements/Components/navigation.ctp @@ -30,10 +30,28 @@ ?>
diff --git a/View/Elements/Components/search.ctp b/View/Elements/Components/search.ctp index 6ebe8e0..4be109f 100644 --- a/View/Elements/Components/search.ctp +++ b/View/Elements/Components/search.ctp @@ -75,7 +75,7 @@ $(document).ready(function() {
- + - - - - - + Form->input('grouptemplate', array( + 'label' => false, + 'class' => 'custom-select', + 'id' => 'template-select', + 'options' => array('1' => 'Template', '2' => 'Another template', '3' => 'Yet another template'), + 'empty' => '(choose one)' + )); ?>
- + Form->label(false, 'Group Name', array( + 'for' => 'name', + 'class' => "col-sm-3 col-form-label" + )); ?>
- + Form->input('grouptemplate', array( + 'label' => false, + 'class' => 'form-control', + 'id' => 'name' + )); ?> Name is the label that identifies this group, and might change.
- + Form->label(false, 'Create in this folder:', array( + 'for' => 'folder', + 'class' => "col-sm-3 col-form-label" + )); ?>
- + Form->input('grouptemplate', array( + 'label' => false, + 'class' => 'form-control', + 'id' => 'folder', + 'default' => 'sandbox:org:unicon:', + 'readonly' => true + )); ?> Enter a folder name. @@ -124,51 +145,96 @@
- - + Form->checkbox('privelages', array( + 'value' => 'READ', + 'class' => 'form-check-input', + 'id' => 'assign-1', + 'hiddenField' => false + )); ?> + Form->label(false, 'READ', array( + 'for' => 'assign-1', + 'class' => "form-check-label" + )); ?>
- - + Form->checkbox('privelages', array( + 'value' => 'VIEW', + 'class' => 'form-check-input', + 'id' => 'assign-2', + 'hiddenField' => false + )); ?> + Form->label(false, 'VIEW', array( + 'for' => 'assign-2', + 'class' => "form-check-label" + )); ?>
- - + Form->checkbox('privelages', array( + 'value' => 'OPTIN', + 'class' => 'form-check-input', + 'id' => 'assign-3', + 'hiddenField' => false + )); ?> + Form->label(false, 'OPTIN', array( + 'for' => 'assign-3', + 'class' => "form-check-label" + )); ?>
- - + Form->checkbox('privelages', array( + 'value' => 'OPTOUT', + 'class' => 'form-check-input', + 'id' => 'assign-4', + 'hiddenField' => false + )); ?> + Form->label(false, 'OPTOUT', array( + 'for' => 'assign-4', + 'class' => "form-check-label" + )); ?>
- - + Form->checkbox('privelages', array( + 'value' => 'ATTRIBUTE_READ', + 'class' => 'form-check-input', + 'id' => 'assign-5', + 'hiddenField' => false + )); ?> + Form->label(false, 'ATTRIBUTE READ', array( + 'for' => 'assign-5', + 'class' => "form-check-label" + )); ?>
- + Form->label(false, 'Description:', array( + 'for' => 'descr', + 'class' => "col-sm-3 col-form-label" + )); ?>
- + Form->textarea('description', array( + 'class' => 'form-control', + 'id' => 'descr', + 'rows' => 5 + )); ?> Description contains notes about the group, which could include: what the group represents, why it was created, etc.
- + Form->label(false, 'Subscribers:', array( + 'for' => 'subscribers', + 'class' => "col-sm-3 col-form-label" + )); ?>
- + Form->input('grouptemplate', array( + 'label' => false, + 'class' => 'typeahead form-control', + 'id' => 'name', + 'placeholder' => 'Find subscribers' + )); ?> Select subscribers to add to the group. @@ -177,11 +243,14 @@
- + Form->button('Save Group', array( + 'type' => 'submit', + 'class' => 'btn btn-primary btn-lg btn-raised' + )); ?>
- + Form->end(); ?> \ No newline at end of file diff --git a/View/GrouperGroups/groupinfo.ctp b/View/GrouperGroups/groupinfo.ctp index 2ed5fe1..1d7424b 100644 --- a/View/GrouperGroups/groupinfo.ctp +++ b/View/GrouperGroups/groupinfo.ctp @@ -19,77 +19,38 @@ $attrUrlBase = $baseUrl.$path.$attrOperation;
-
+

Group Properties

-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
-
- -
- -
-
+ element('Components/groupproperties', array( + 'group' => $groupergroupsdetail + )); ?>

Attributes

- - - - - - - - - - - - - - - - - -
Attribute nameAttribute descriptionAction
- - View - -
+ element('Components/groupattributes', array( + 'attributes' => $groupergroupsdetail['attributes'], + 'baseUrl' => $attrUrlBase + )); ?>
+
+

Subscribers

+
+ element('Components/subscriberList', array('subscribers' => array( + array( + "name" => "Galena Munoz", + "email" => "ipsum.cursus.vestibulum@urnaconvalliserat.net", + "cou" => "Active, Member", + "org" => "Eu Corporation" + ), + array( + "name" => "Doris Santos", + "email" => "vitae@non.org", + "cou" => "Active, Filesource, Member", + "org" => "Aliquam LLC" + ) + ))); ?> +
diff --git a/View/GrouperGroups/groupowner.ctp b/View/GrouperGroups/groupowner.ctp index cc0e97d..7a48fcd 100644 --- a/View/GrouperGroups/groupowner.ctp +++ b/View/GrouperGroups/groupowner.ctp @@ -8,7 +8,7 @@ Name Description Status - Action + Action @@ -20,6 +20,15 @@ 'controller' => 'groupergroups', 'action' => 'groupinfo', '?' => array('groupname' => urlencode($group['name'])) + ), + array( + 'data-toggle' => 'popover', + 'data-content' => $this->element('Components/groupproperties', array( + 'group' => $group + )), + 'data-html' => 'true', + 'data-trigger' => 'hover', + 'data-placement' => 'top' ) ) ?> @@ -30,7 +39,7 @@ @@ -38,4 +47,9 @@ + diff --git a/webroot/css/co-grouper-plugin.css b/webroot/css/co-grouper-plugin.css index d695144..e275434 100644 --- a/webroot/css/co-grouper-plugin.css +++ b/webroot/css/co-grouper-plugin.css @@ -90,7 +90,8 @@ a { } #grouper-plugin .table thead th.group.action { - width: 150px; + width: 20%; + max-width: 200px; } #grouper-plugin .table thead th.attr {