summaryrefslogtreecommitdiff
path: root/app/views/group_memberships
diff options
context:
space:
mode:
authorStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-02-27 12:22:29 +0100
committerStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-02-27 12:22:29 +0100
commit67c1a0a951403a546250ea860a3e3d199cae2fce (patch)
treef86ec6cedf081a1a57005eca1661e9bead34e4de /app/views/group_memberships
parent5d8ce5f4775ac8bc5f523964e6e36f63ff3c4683 (diff)
parent211f558a86ae30cdd5b392ab1376e1393f97e22c (diff)
Merge branch 'develop'5.1-beta6
Diffstat (limited to 'app/views/group_memberships')
-rw-r--r--app/views/group_memberships/_form.html.haml7
-rw-r--r--app/views/group_memberships/_form_core.html.haml4
-rw-r--r--app/views/group_memberships/_index_core.html.haml11
-rw-r--r--app/views/group_memberships/edit.html.haml3
-rw-r--r--app/views/group_memberships/index.html.haml6
-rw-r--r--app/views/group_memberships/new.html.haml3
-rw-r--r--app/views/group_memberships/show.html.haml10
7 files changed, 44 insertions, 0 deletions
diff --git a/app/views/group_memberships/_form.html.haml b/app/views/group_memberships/_form.html.haml
new file mode 100644
index 0000000..c8a6a51
--- /dev/null
+++ b/app/views/group_memberships/_form.html.haml
@@ -0,0 +1,7 @@
+= simple_form_for([@group, @group_membership]) do |f|
+ = f.error_notification
+
+ = render "form_core", :f => f
+
+ .form-actions
+ = f.button :submit, conditional_t('group_memberships.form.submit')
diff --git a/app/views/group_memberships/_form_core.html.haml b/app/views/group_memberships/_form_core.html.haml
new file mode 100644
index 0000000..4a28a06
--- /dev/null
+++ b/app/views/group_memberships/_form_core.html.haml
@@ -0,0 +1,4 @@
+.inputs
+ - if @group.group_memberships.count < 1
+ = f.input :item_type, :label => t('group_memberships.form.item_type.label'), :hint => conditional_hint('group_memberships.form.item_type.hint')
+ = f.input :item_id, :label => t('group_memberships.form.item_id.label'), :hint => conditional_hint('group_memberships.form.item_id.hint')
diff --git a/app/views/group_memberships/_index_core.html.haml b/app/views/group_memberships/_index_core.html.haml
new file mode 100644
index 0000000..beeefc9
--- /dev/null
+++ b/app/views/group_memberships/_index_core.html.haml
@@ -0,0 +1,11 @@
+%table.table.table-striped
+ %tr
+ %th= t('group_memberships.index.item_type')
+ %th= t('group_memberships.index.item_id')
+
+
+ - for group_membership in group_memberships
+ %tr
+ %td= group_membership.item_type
+ %td= group_membership.item_id
+ =render :partial => 'shared/index_view_edit_destroy_part', :locals => {:parent => group_membership.group, :child => group_membership}
diff --git a/app/views/group_memberships/edit.html.haml b/app/views/group_memberships/edit.html.haml
new file mode 100644
index 0000000..643c095
--- /dev/null
+++ b/app/views/group_memberships/edit.html.haml
@@ -0,0 +1,3 @@
+- content_for :title, t("group_memberships.edit.page_title")
+
+= render "form" \ No newline at end of file
diff --git a/app/views/group_memberships/index.html.haml b/app/views/group_memberships/index.html.haml
new file mode 100644
index 0000000..b493017
--- /dev/null
+++ b/app/views/group_memberships/index.html.haml
@@ -0,0 +1,6 @@
+- content_for :title, t("group_memberships.index.page_title")
+
+- if @group_memberships && @group_memberships.count > 0
+ = render "index_core", :group_memberships => @group_memberships
+
+= render :partial => 'shared/create_link', :locals => {:parent => @group, :child_class => GroupMembership}
diff --git a/app/views/group_memberships/new.html.haml b/app/views/group_memberships/new.html.haml
new file mode 100644
index 0000000..6cf2ce7
--- /dev/null
+++ b/app/views/group_memberships/new.html.haml
@@ -0,0 +1,3 @@
+- content_for :title, t("group_memberships.new.page_title")
+
+= render "form" \ No newline at end of file
diff --git a/app/views/group_memberships/show.html.haml b/app/views/group_memberships/show.html.haml
new file mode 100644
index 0000000..0875f0b
--- /dev/null
+++ b/app/views/group_memberships/show.html.haml
@@ -0,0 +1,10 @@
+- content_for :title, t("group_memberships.show.page_title")
+
+%p
+ %strong= t('group_memberships.show.item_type') + ":"
+ = @group_membership.item_type
+%p
+ %strong= t('group_memberships.show.item_id') + ":"
+ = @group_membership.item_id
+
+= render :partial => 'shared/show_edit_destroy_part', :locals => { :parent => @group, :child => @group_membership }