修改迁移文件

This commit is contained in:
nwb 2014-06-16 14:42:48 +08:00
parent e698f3a6c6
commit 2a4486bf0d
4 changed files with 5 additions and 6 deletions

View File

@ -225,7 +225,6 @@ class CoursesController < ApplicationController
@course.setup_time = params[:setup_time]
@course.endup_time = params[:endup_time]
@course.class_period = params[:class_period]
@course.description = params[:description]
end
@issue_custom_fields = IssueCustomField.sorted.all

View File

@ -320,12 +320,12 @@ module ApplicationHelper
courses.each do |course|
# set the project environment to please macros.
@course = course
if (ancestors.empty? || course.is_descendant_of?(ancestors.last))
if (ancestors.empty? )#|| course.is_descendant_of?(ancestors.last))
s << "<ul class=courses'>\n"
else
ancestors.pop
s << "</li>"
while (ancestors.any? && !course.is_descendant_of?(ancestors.last))
while (ancestors.any? )#&& !course.is_descendant_of?(ancestors.last))
ancestors.pop
s << "</ul></li>\n"
end

View File

@ -12,8 +12,8 @@ class StoredCourseProcedure < ActiveRecord::Migration
course.description = project.description
course.status = project.status
course.attachmenttype = 2
course.lft = project.lft
course.rgt = project.rgt
#course.lft = project.lft
#course.rgt = project.rgt
course.save
# 更新状态表

View File

@ -528,7 +528,7 @@ ActiveRecord::Schema.define(:version => 20140611161801) do
t.integer "project_id", :default => 0
t.datetime "created_on"
t.boolean "mail_notification", :default => false, :null => false
t.integer "course_id"
t.integer "course_id", :default => -1
end
add_index "members", ["project_id"], :name => "index_members_on_project_id"