aboutsummaryrefslogtreecommitdiff
path: root/mod/uservalidationbyemail/views
diff options
context:
space:
mode:
Diffstat (limited to 'mod/uservalidationbyemail/views')
-rw-r--r--mod/uservalidationbyemail/views/default/admin/users/unvalidated.php2
-rw-r--r--mod/uservalidationbyemail/views/default/forms/uservalidationbyemail/bulk_action.php25
-rw-r--r--mod/uservalidationbyemail/views/default/uservalidationbyemail/css.php7
-rw-r--r--mod/uservalidationbyemail/views/default/uservalidationbyemail/js.php8
-rw-r--r--mod/uservalidationbyemail/views/default/uservalidationbyemail/unvalidated_user.php2
5 files changed, 29 insertions, 15 deletions
diff --git a/mod/uservalidationbyemail/views/default/admin/users/unvalidated.php b/mod/uservalidationbyemail/views/default/admin/users/unvalidated.php
index 8b72126ef..abe539108 100644
--- a/mod/uservalidationbyemail/views/default/admin/users/unvalidated.php
+++ b/mod/uservalidationbyemail/views/default/admin/users/unvalidated.php
@@ -4,6 +4,6 @@
*/
echo elgg_view_form('uservalidationbyemail/bulk_action', array(
- 'name' => 'unvalidated-users',
+ 'id' => 'unvalidated-users',
'action' => 'action/uservalidationbyemail/bulk_action'
));
diff --git a/mod/uservalidationbyemail/views/default/forms/uservalidationbyemail/bulk_action.php b/mod/uservalidationbyemail/views/default/forms/uservalidationbyemail/bulk_action.php
index 0e1461058..bc4d33c6a 100644
--- a/mod/uservalidationbyemail/views/default/forms/uservalidationbyemail/bulk_action.php
+++ b/mod/uservalidationbyemail/views/default/forms/uservalidationbyemail/bulk_action.php
@@ -46,8 +46,6 @@ $pagination = elgg_view('navigation/pagination',array(
'limit' => $limit,
));
-echo $pagination;
-
$bulk_actions_checkbox = '<label><input type="checkbox" class="unvalidated-users-checkall" />'
. elgg_echo('uservalidationbyemail:check_all') . '</label>';
@@ -79,8 +77,8 @@ $delete = elgg_view('output/url', array(
));
$bulk_actions = <<<___END
-<div class="uvbe_bulk_actions">
- <div class="uvbe_admin_controls">
+<div class="uvbe_bulk_actions pas">
+ <div class="uvbe_admin_controls right">
$resend_email | $validate | $delete
</div>
@@ -90,15 +88,24 @@ ___END;
//$bulk_actions = elgg_view('page_elements/contentwrapper', array('body' => $bulk_actions));
-echo $bulk_actions;
-
-
+$list = '';
foreach ($users as $user) {
- echo elgg_view('uservalidationbyemail/unvalidated_user', array('user' => $user));
+ $list .= elgg_view('uservalidationbyemail/unvalidated_user', array('user' => $user));
}
+echo <<<___END
+<div class="elgg-module elgg-module-inline">
+ <div class="elgg-head">
+ $bulk_actions
+ </div>
+ <div class="elgg-body">
+ $list
+ </div>
+</div>
+___END;
+
if ($count > 5) {
echo $bulk_actions;
}
-echo $pagination; \ No newline at end of file
+echo $pagination;
diff --git a/mod/uservalidationbyemail/views/default/uservalidationbyemail/css.php b/mod/uservalidationbyemail/views/default/uservalidationbyemail/css.php
new file mode 100644
index 000000000..11f1aa18b
--- /dev/null
+++ b/mod/uservalidationbyemail/views/default/uservalidationbyemail/css.php
@@ -0,0 +1,7 @@
+.elgg-head .uvbe_bulk_actions label, .elgg-head .uvbe_bulk_actions a{
+ color: white;
+}
+
+.right {
+ float: right;
+}
diff --git a/mod/uservalidationbyemail/views/default/uservalidationbyemail/js.php b/mod/uservalidationbyemail/views/default/uservalidationbyemail/js.php
index 50c98406e..35f1ada7f 100644
--- a/mod/uservalidationbyemail/views/default/uservalidationbyemail/js.php
+++ b/mod/uservalidationbyemail/views/default/uservalidationbyemail/js.php
@@ -3,12 +3,12 @@ elgg.provide('elgg.uservalidationbyemail');
elgg.uservalidationbyemail.init = function() {
$('.unvalidated-users-checkall').click(function() {
- checked = $(this).attr('checked');
- $('form[name=unvalidated-users]').find('input[type=checkbox]').attr('checked', checked);
+ checked = $(this).attr('checked') == 'checked';
+ $('form#unvalidated-users').find('input[type=checkbox]').attr('checked', checked);
});
$('.unvalidated-users-bulk-post').click(function(event) {
- $form = $('form[name=unvalidated-users]');
+ $form = $('form#unvalidated-users');
event.preventDefault();
// check if there are selected users
@@ -23,6 +23,6 @@ elgg.uservalidationbyemail.init = function() {
$form.attr('action', $(this).attr('href')).submit();
});
-};
+}
elgg.register_hook_handler('init', 'system', elgg.uservalidationbyemail.init);
diff --git a/mod/uservalidationbyemail/views/default/uservalidationbyemail/unvalidated_user.php b/mod/uservalidationbyemail/views/default/uservalidationbyemail/unvalidated_user.php
index 209dbe02b..9d2f47139 100644
--- a/mod/uservalidationbyemail/views/default/uservalidationbyemail/unvalidated_user.php
+++ b/mod/uservalidationbyemail/views/default/uservalidationbyemail/unvalidated_user.php
@@ -13,7 +13,7 @@ $user = elgg_extract('user', $vars);
// 'name' => 'user_guids',
// 'options' => array("$user->username - \"$user->name\" &lt;$user->email&gt;" => $user->guid)
//));
-$checkbox = "<label><input type=\"checkbox\" value=\"$user->guid\" class=\"elgg-input-checkboxes\" name=\"user_guids[]\">"
+$checkbox = "<label><input type=\"checkbox\" value=\"$user->guid\" class=\"elgg-input-checkboxes\" name=\"user_guids[]\" />"
. "$user->username - \"$user->name\" &lt;$user->email&gt;</label>";
$created = elgg_echo('uservalidationbyemail:admin:user_created', array(elgg_view_friendly_time($user->time_created)));