Merge branch 'dev_hjq' of http://repository.trustie.net/xianbo/trustie2 into dev_hjq
This commit is contained in:
commit
bc9a332be3
|
@ -189,6 +189,7 @@ class ProjectsController < ApplicationController
|
||||||
@project.organization_id = params[:organization_id]
|
@project.organization_id = params[:organization_id]
|
||||||
@project.user_id = User.current.id
|
@project.user_id = User.current.id
|
||||||
@project.project_new_type = params[:project_new_type]
|
@project.project_new_type = params[:project_new_type]
|
||||||
|
params[:project][:is_public] ? @project.is_public = 1 : @project.is_public = 0
|
||||||
if validate_parent_id && @project.save
|
if validate_parent_id && @project.save
|
||||||
@project.set_allowed_parent!(params[:project]['parent_id']) if params[:project].has_key?('parent_id')
|
@project.set_allowed_parent!(params[:project]['parent_id']) if params[:project].has_key?('parent_id')
|
||||||
# Add current user as a project member if he is not admin
|
# Add current user as a project member if he is not admin
|
||||||
|
|
|
@ -86,7 +86,7 @@ class Message < ActiveRecord::Base
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
safe_attributes 'subject', 'content'
|
safe_attributes 'subject', 'content', 'reply_id'
|
||||||
safe_attributes 'board_id','locked', 'sticky',
|
safe_attributes 'board_id','locked', 'sticky',
|
||||||
:if => lambda {|message, user|
|
:if => lambda {|message, user|
|
||||||
if message.project
|
if message.project
|
||||||
|
|
|
@ -45,134 +45,13 @@
|
||||||
<div class="cl"></div>
|
<div class="cl"></div>
|
||||||
|
|
||||||
<!--属性-->
|
<!--属性-->
|
||||||
<<<<<<< .mine
|
|
||||||
<%= render :partial => 'attributes_show' %>
|
<%= render :partial => 'attributes_show' %>
|
||||||
<!--pro_info_box 属性 end-->
|
<!--pro_info_box 属性 end-->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
=======
|
|
||||||
<div class="pro_info_box mb10">
|
|
||||||
<%= issue_fields_rows do |rows| %>
|
|
||||||
<ul class="fl">
|
|
||||||
<li><p class="label03"> 状态 : </p>
|
|
||||||
|
|
||||||
<p class="pro_info_p"><%= @issue.status.name %></p>
|
|
||||||
</li>
|
|
||||||
<div class="cl"></div>
|
|
||||||
<% unless @issue.disabled_core_fields.include?('assigned_to_id') %>
|
|
||||||
<li><p class="label03"> 指派给 : </p>
|
|
||||||
<span class="pro_info_p"><%= @issue.assigned_to ? link_to_isuue_user(@issue.assigned_to) : "--" %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
<div class="cl"></div>
|
|
||||||
</ul>
|
|
||||||
<ul class="fl">
|
|
||||||
<li><p class="label03"> 优先级 : </p>
|
|
||||||
<span class="pro_info_p" style="width:50px;"><%= @issue.priority.name %></span>
|
|
||||||
</li>
|
|
||||||
<div class="cl"></div>
|
|
||||||
<% unless @issue.disabled_core_fields.include?('done_ratio') %>
|
|
||||||
<li><p class="label03"> % 完成 : </p>
|
|
||||||
<span class="pro_info_p" style="width:50px;"><%= @issue.done_ratio %>%</span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
<div class="cl"></div>
|
|
||||||
</ul>
|
|
||||||
>>>>>>> .theirs
|
|
||||||
|
|
||||||
<<<<<<< .mine
|
|
||||||
<%# 该应用是对issue主题内容的引用,对应:to => 'journals#new %>
|
<%# 该应用是对issue主题内容的引用,对应:to => 'journals#new %>
|
||||||
<!--<div class="cl"></div>-->
|
<!--<div class="cl"></div>-->
|
||||||
<!--<%#= link_to l(:button_quote), quoted_issue_path(@issue.id), :remote => true, :method => 'post', :class => 'talk_edit fr' if authorize_for('issues', 'edit') %>-->
|
<!--<%#= link_to l(:button_quote), quoted_issue_path(@issue.id), :remote => true, :method => 'post', :class => 'talk_edit fr' if authorize_for('issues', 'edit') %>-->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div class="cl"></div>
|
<div class="cl"></div>
|
||||||
=======
|
|
||||||
<ul class="fl ">
|
|
||||||
<% unless @issue.disabled_core_fields.include?('start_date') %>
|
|
||||||
<li><p class="label03" style="width:50px;"> 开始 : </p>
|
|
||||||
|
|
||||||
<p class="pro_info_p"><%= format_date(@issue.start_date) %></p>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
<div class="cl"></div>
|
|
||||||
>>>>>>> .theirs
|
|
||||||
<<<<<<< .mine
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
=======
|
|
||||||
<% unless @issue.disabled_core_fields.include?('estimated_hours') %>
|
|
||||||
<li><p class="label03" style="width:50px;"> 周期 : </p>
|
|
||||||
<span class="pro_info_p"><%= l_hours(@issue.estimated_hours) %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
<div class="cl"></div>
|
|
||||||
</ul>
|
|
||||||
<ul class="fl ">
|
|
||||||
<% unless @issue.disabled_core_fields.include?('due_date') %>
|
|
||||||
<li><p class="label03"> 计划完成 : </p>
|
|
||||||
<span class="pro_info_p" style="width:120px;"><%= format_date(@issue.due_date) ? format_date(@issue.due_date) : "--" %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
<div class="cl"></div>
|
|
||||||
<% unless @issue.disabled_core_fields.include?('fixed_version_id') %>
|
|
||||||
<li><p class="label03"> 目标版本 : </p>
|
|
||||||
<span class="pro_info_p" style="width:120px;"><%= (@issue.fixed_version ? link_to_version(@issue.fixed_version, :class => "pro_info_p") : "--") %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
<div class="cl"></div>
|
|
||||||
</ul>
|
|
||||||
<% end %><!--pro_info_box end-->
|
|
||||||
<%#= render_custom_fields_rows(@issue) %>
|
|
||||||
<%#= call_hook(:view_issues_show_details_bottom, :issue => @issue) %>
|
|
||||||
>>>>>>> .theirs
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!--problem_main end-->
|
<!--problem_main end-->
|
||||||
|
|
13
db/schema.rb
13
db/schema.rb
|
@ -11,7 +11,7 @@
|
||||||
#
|
#
|
||||||
# It's strongly recommended to check this file into your version control system.
|
# It's strongly recommended to check this file into your version control system.
|
||||||
|
|
||||||
ActiveRecord::Schema.define(:version => 20150918134804) do
|
ActiveRecord::Schema.define(:version => 20150924063215) do
|
||||||
|
|
||||||
create_table "activities", :force => true do |t|
|
create_table "activities", :force => true do |t|
|
||||||
t.integer "act_id", :null => false
|
t.integer "act_id", :null => false
|
||||||
|
@ -476,6 +476,13 @@ ActiveRecord::Schema.define(:version => 20150918134804) do
|
||||||
|
|
||||||
add_index "delayed_jobs", ["priority", "run_at"], :name => "delayed_jobs_priority"
|
add_index "delayed_jobs", ["priority", "run_at"], :name => "delayed_jobs_priority"
|
||||||
|
|
||||||
|
create_table "discuss_demos", :force => true do |t|
|
||||||
|
t.string "title"
|
||||||
|
t.text "body"
|
||||||
|
t.datetime "created_at", :null => false
|
||||||
|
t.datetime "updated_at", :null => false
|
||||||
|
end
|
||||||
|
|
||||||
create_table "documents", :force => true do |t|
|
create_table "documents", :force => true do |t|
|
||||||
t.integer "project_id", :default => 0, :null => false
|
t.integer "project_id", :default => 0, :null => false
|
||||||
t.integer "category_id", :default => 0, :null => false
|
t.integer "category_id", :default => 0, :null => false
|
||||||
|
@ -895,6 +902,7 @@ ActiveRecord::Schema.define(:version => 20150918134804) do
|
||||||
t.datetime "updated_on", :null => false
|
t.datetime "updated_on", :null => false
|
||||||
t.boolean "locked", :default => false
|
t.boolean "locked", :default => false
|
||||||
t.integer "sticky", :default => 0
|
t.integer "sticky", :default => 0
|
||||||
|
t.integer "reply_id"
|
||||||
end
|
end
|
||||||
|
|
||||||
add_index "messages", ["author_id"], :name => "index_messages_on_author_id"
|
add_index "messages", ["author_id"], :name => "index_messages_on_author_id"
|
||||||
|
@ -912,7 +920,6 @@ ActiveRecord::Schema.define(:version => 20150918134804) do
|
||||||
t.datetime "created_on"
|
t.datetime "created_on"
|
||||||
t.integer "comments_count", :default => 0, :null => false
|
t.integer "comments_count", :default => 0, :null => false
|
||||||
t.integer "course_id"
|
t.integer "course_id"
|
||||||
t.datetime "updated_on"
|
|
||||||
end
|
end
|
||||||
|
|
||||||
add_index "news", ["author_id"], :name => "index_news_on_author_id"
|
add_index "news", ["author_id"], :name => "index_news_on_author_id"
|
||||||
|
@ -1324,7 +1331,7 @@ ActiveRecord::Schema.define(:version => 20150918134804) do
|
||||||
t.datetime "updated_at", :null => false
|
t.datetime "updated_at", :null => false
|
||||||
t.integer "late_penalty", :default => 0
|
t.integer "late_penalty", :default => 0
|
||||||
t.integer "absence_penalty", :default => 0
|
t.integer "absence_penalty", :default => 0
|
||||||
t.float "system_score", :default => 0.0
|
t.integer "system_score"
|
||||||
t.boolean "is_test", :default => false
|
t.boolean "is_test", :default => false
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue