forked from bofh/fetsite
themen verwalten add
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<%= @themengruppe.text %>
|
||||
</p>
|
||||
<ul class="unstyled linkbox-list" >
|
||||
<% @themengruppe.themen.each do |thema| %>
|
||||
<% @themen.each do |thema| %>
|
||||
<li>
|
||||
<div class="contentbox">
|
||||
<a href="#<%=thema.id%>">
|
||||
|
||||
27
app/views/themes/2003/themengruppen/verwalten_all.html.erb
Normal file
27
app/views/themes/2003/themengruppen/verwalten_all.html.erb
Normal file
@@ -0,0 +1,27 @@
|
||||
|
||||
<ul id="themengruppen" class="sort" >
|
||||
<% @themengruppen.each do |themengruppe| %>
|
||||
<li id="themengruppen_<%= themengruppe.id %>" class="sort" style="background:white;display:block;" ><%= themengruppe.title %>-<%= themengruppe.priority %></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
|
||||
<script>
|
||||
|
||||
$( document ).ready(function(){
|
||||
$("#themengruppen").sortable({
|
||||
cursor: 'crosshair',
|
||||
drag:true,
|
||||
update: function(){
|
||||
$.ajax({
|
||||
url: '<%= sort_themengruppen_themengruppen_path() %>',
|
||||
type: 'post',
|
||||
data: $('#themengruppen').sortable('serialize'),
|
||||
dataType: 'script',
|
||||
complete: function(request){
|
||||
alert("complete");
|
||||
}
|
||||
})
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
Reference in New Issue
Block a user