summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-03-04 11:55:33 +0100
committerStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-03-04 11:55:33 +0100
commita07b7482bb2f9d2867dafc909da8af90d5ee9143 (patch)
tree360e5a8b3cc1f9c0ccf79575709b0a9787924dd3 /app/views
parentaaffa89ef9aef6ac30e3304d735a8c58f4bdaaef (diff)
parent8042e6c314737feab61209e0b8b26ddba5c7e763 (diff)
Merge branch 'develop' of github.com:amooma/GS5 into develop
Diffstat (limited to 'app/views')
-rw-r--r--app/views/group_memberships/_index_core.html.haml3
-rw-r--r--app/views/group_memberships/show.html.haml4
-rw-r--r--app/views/groups/_index_core.html.haml10
-rw-r--r--app/views/phones/_form_core.html.haml2
-rw-r--r--app/views/phones/show.html.haml11
5 files changed, 21 insertions, 9 deletions
diff --git a/app/views/group_memberships/_index_core.html.haml b/app/views/group_memberships/_index_core.html.haml
index beeefc9..31a9050 100644
--- a/app/views/group_memberships/_index_core.html.haml
+++ b/app/views/group_memberships/_index_core.html.haml
@@ -2,10 +2,11 @@
%tr
%th= t('group_memberships.index.item_type')
%th= t('group_memberships.index.item_id')
-
+ %th= t('group_memberships.index.item')
- for group_membership in group_memberships
%tr
%td= group_membership.item_type
%td= group_membership.item_id
+ %td= group_membership.item
=render :partial => 'shared/index_view_edit_destroy_part', :locals => {:parent => group_membership.group, :child => group_membership}
diff --git a/app/views/group_memberships/show.html.haml b/app/views/group_memberships/show.html.haml
index 0875f0b..362b25f 100644
--- a/app/views/group_memberships/show.html.haml
+++ b/app/views/group_memberships/show.html.haml
@@ -7,4 +7,8 @@
%strong= t('group_memberships.show.item_id') + ":"
= @group_membership.item_id
+%p
+ %strong= t('group_memberships.show.item') + ":"
+ = @group_membership.item
+
= render :partial => 'shared/show_edit_destroy_part', :locals => { :parent => @group, :child => @group_membership }
diff --git a/app/views/groups/_index_core.html.haml b/app/views/groups/_index_core.html.haml
index 3a444bf..e67eb66 100644
--- a/app/views/groups/_index_core.html.haml
+++ b/app/views/groups/_index_core.html.haml
@@ -2,6 +2,8 @@
%tr
%th
%th= t('groups.index.name')
+ %th= t('groups.index.permissions')
+ %th= t('groups.index.memberships')
%th= t('groups.index.comment')
@@ -13,5 +15,11 @@
- else
%i.icon-ban-circle
%td= group.name
+ %td
+ - if group.group_permissions.count > 0 && group.group_permissions.count < 4
+ = group.group_permissions.pluck(:permission).uniq.join(' ')
+ - else
+ = group.group_permissions.count
+ %td= group.group_memberships.count
%td= group.comment
- =render :partial => 'shared/index_view_edit_destroy_part', :locals => {:child => group} \ No newline at end of file
+ =render :partial => 'shared/index_view_edit_destroy_part', :locals => {:child => group}
diff --git a/app/views/phones/_form_core.html.haml b/app/views/phones/_form_core.html.haml
index 31f3c24..e093899 100644
--- a/app/views/phones/_form_core.html.haml
+++ b/app/views/phones/_form_core.html.haml
@@ -11,5 +11,5 @@
- if defined? GsParameter.get('NIGHTLY_REBOOT_OF_PHONES') && GsParameter.get('NIGHTLY_REBOOT_OF_PHONES') == true
= f.input :nightly_reboot, :label => t('phones.form.nightly_reboot.label'), :hint => conditional_hint('phones.form.nightly_reboot.hint')
- - if GsParameter.get('PROVISIONING_KEY_LENGTH') == 0
+ - if @phone && @phone.provisioning_key_active
= f.input :provisioning_key_active, :label => t('phones.form.provisioning_key_active.label'), :hint => conditional_hint('phones.form.provisioning_key_active.hint')
diff --git a/app/views/phones/show.html.haml b/app/views/phones/show.html.haml
index e9b8b21..1996d48 100644
--- a/app/views/phones/show.html.haml
+++ b/app/views/phones/show.html.haml
@@ -34,12 +34,11 @@
%td
= @phone.nightly_reboot == true ? t('simple_form.yes') : t('simple_form.no')
- - if GsParameter.get('PROVISIONING_KEY_LENGTH') == 0
- %tr
- %td
- %strong= t('phones.show.provisioning_key_active') + ":"
- %td
- = @phone.provisioning_key_active == true ? t('simple_form.yes') : t('simple_form.no')
+ %tr
+ %td
+ %strong= t('phones.show.provisioning_key_active') + ":"
+ %td
+ = @phone.provisioning_key_active == true ? t('simple_form.yes') : t('simple_form.no')
%tr{:class => (@phone.ip_address.blank? ? 'warning' : '')}
%td