diff --git a/.gitignore b/.gitignore index 7f93ebb9..d6b5ecb8 100644 --- a/.gitignore +++ b/.gitignore @@ -6,8 +6,9 @@ /log/* /test/* /tmp/* - +.gitignore /config/database.yml /public/images/avatars/* /Gemfile /Gemfile.lock +/db/schema.da diff --git a/app/controllers/words_controller.rb b/app/controllers/words_controller.rb index 1e23197e..be1e3177 100644 --- a/app/controllers/words_controller.rb +++ b/app/controllers/words_controller.rb @@ -42,6 +42,14 @@ class WordsController < ApplicationController def create_reply + # 这里是创建回复所使用的方法,此方法只针对回复,每一个新的留言并不在此方法管理范围内。 + # 由于多个地方用到了留言,而之前的表设计也有jour_type/jour_id这类信息 + # 所以在方法 add_reply_adapter 中判断所有调用此方法的来源页面, + # 为了保证兼容以往所有的代码,保证以往的方法可以调用,在返回页面中都做了各式各样的判断。 + # 页面保证 render new_respond/journal_reply + # 修改 add_reply_adapter 中可以确保留言创建成功 + # 删除留言功能要调用destroy,也记得在destroy.js中修改 + # deny api. api useless parent_id = params[:reference_id] author_id = User.current.id diff --git a/app/views/layouts/_base_header.html.erb b/app/views/layouts/_base_header.html.erb index a2f0cde1..ecd348d5 100644 --- a/app/views/layouts/_base_header.html.erb +++ b/app/views/layouts/_base_header.html.erb @@ -10,4 +10,5 @@ <%= render_menu :top_menu if User.current.logged? || !Setting.login_required? -%>
+
diff --git a/app/views/projects/feedback.html.erb b/app/views/projects/feedback.html.erb index bdbcfd07..7e1c4077 100644 --- a/app/views/projects/feedback.html.erb +++ b/app/views/projects/feedback.html.erb @@ -70,7 +70,7 @@ function checkMaxLength() {
- <%= render :partial => 'new_respond', :locals => {:journal => journal, :m_reply_id => journal} %> + <%= render :partial => 'words/new_respond', :locals => {:journal => journal, :m_reply_id => journal} %>
diff --git a/app/views/welcome/index.html.erb b/app/views/welcome/index.html.erb index 633881b6..2b4412bc 100644 --- a/app/views/welcome/index.html.erb +++ b/app/views/welcome/index.html.erb @@ -1,12 +1,14 @@ -
-
-

- <%= l(:label_welcome_trustie) %> , <%= l(:label_welcome_trustie_description) %> -

+
+
+ <%= image_tag '/images/qrweixin.jpg', size: '200x200', alt: 'trustie', class: "weixin" %> +

微信扫码

-
+
+ <%= l(:label_welcome_trustie) %> , <%= l(:label_welcome_trustie_description) %> +
+
<%= call_hook :view_account_login_top %> -
+
<%= form_tag(signin_path) do %> <%= back_url_hidden_field_tag if is_logout? %> <% unless User.current.logged? %> @@ -67,6 +69,7 @@
+