remove useless rake task
This commit is contained in:
parent
38d5a193e0
commit
2416030adc
|
@ -62,15 +62,28 @@ namespace :desktop do
|
||||||
temp_file
|
temp_file
|
||||||
end
|
end
|
||||||
|
|
||||||
task :destroy_build_desktop => :environment do
|
end
|
||||||
Desktop.all.destroy_all
|
|
||||||
u = User.all
|
namespace :tiles do
|
||||||
u.each do |us|
|
task :destroy_build_tiles => :environment do
|
||||||
Thread.new {
|
Tile.destroy_all
|
||||||
us.initialize_desktop.save!
|
secs = Section.all
|
||||||
puts "Desktop created for " + us.email.to_s
|
dws = DesktopWidget.all
|
||||||
}.join
|
secs.each do |sec,x|
|
||||||
end
|
grp = sec.groups.first
|
||||||
|
t = Tile.new(data_category: "app", data_content: "wikibooks", position: 1, shape: "w1 h1", title: "WikiBooks")
|
||||||
|
grp.tiles+=[t]
|
||||||
|
t = Tile.new(data_category: "app", data_content: "envocab", position: 2, shape: "w1 h1", title: "English Vocabulary")
|
||||||
|
grp.tiles+=[t]
|
||||||
|
@i = 3
|
||||||
|
dws.each do |dw|
|
||||||
|
t = Tile.new(data_category: "widget", position: @i,desktop_widget_id: dw.id)
|
||||||
|
@i = @i + 1
|
||||||
|
grp.tiles+=[t]
|
||||||
|
end
|
||||||
|
grp.save!
|
||||||
|
puts "Section " + (x || "NilString") + " done!"
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
Reference in New Issue