beef-slides 0.2.4 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
1.0.0
|
@@ -18,7 +18,7 @@
|
|
18
18
|
<td><%= link_to slide_show.title, admin_slide_show_slides_path(slide_show) %></td>
|
19
19
|
<td><%= link_to pluralize(slide_show.slides.count, "Slide"), admin_slide_show_slides_path(slide_show) %></td>
|
20
20
|
<td><%= link_to 'Edit', admin_slide_show_path(slide_show), :class => 'edit' %></td>
|
21
|
-
<td><%= link_to 'Destroy', admin_slide_show_path(slide_show), :confirm => 'Are you sure?', :method => :delete, :class => 'delete' %></td>
|
21
|
+
<td><%= link_to 'Destroy', admin_slide_show_path(slide_show), :confirm => 'Are you sure?', :method => :delete, :class => 'delete' unless slide_show.lock_level >=1 || !current_user.admin? %></td>
|
22
22
|
</tr>
|
23
23
|
<% end %>
|
24
24
|
</tbody>
|
@@ -3,10 +3,19 @@
|
|
3
3
|
<% form_for([:admin, @slide_show]) do |f| %>
|
4
4
|
<%= f.error_messages %>
|
5
5
|
|
6
|
+
<% if @slide_show.lock_level < 3 %>
|
6
7
|
<p>
|
7
8
|
<%= f.label :title %><br />
|
8
9
|
<%= f.text_field :title %>
|
9
10
|
</p>
|
11
|
+
<% else %>
|
12
|
+
<p>
|
13
|
+
<%= f.label :title %><br />
|
14
|
+
<%= @slide_show.title %> (locked)
|
15
|
+
</p>
|
16
|
+
<% end %>
|
17
|
+
|
18
|
+
|
10
19
|
<p class="submission">
|
11
20
|
<%= f.submit @slide_show.new_record? ? 'Create' : 'Update', :disable_with => 'Submitting...' %> or <%= link_to 'Cancel', admin_slide_shows_path %>
|
12
21
|
</p>
|
data/slides.gemspec
CHANGED