bug#2878:公共贴吧:编辑帖子、编辑回帖的时候建议不要显示主题

This commit is contained in:
yutao 2015-06-19 11:42:07 +08:00
parent 3b3b8661c8
commit 3092121a7a
2 changed files with 3 additions and 3 deletions

View File

@ -157,7 +157,7 @@ class MemosController < ApplicationController
def update
respond_to do |format|
if( @memo.update_column(:subject, params[:memo][:subject]) &&
if( #@memo.update_column(:subject, params[:memo][:subject]) &&
@memo.update_column(:content, params[:memo][:content]) &&
@memo.update_column(:sticky, params[:memo][:sticky]) &&
@memo.update_column(:lock, params[:memo][:lock]))

View File

@ -21,9 +21,9 @@
<div class="actions">
<p>
<% if @memo.parent.nil? && @memo.children.first.nil? %>
<%= f.text_field :subject, :required => true, :size => 96 ,:readonly => false, :maxlength => 50%>
<%#= f.text_field :subject, :required => true, :size => 96 ,:readonly => false, :maxlength => 50%>
<% else %>
<%= f.text_field :subject, :required => true, :size => 96 ,:readonly => true, :style => "border: 1px solid gray", :maxlength => 50%>
<%#= f.text_field :subject, :required => true, :size => 96 ,:readonly => true, :style => "border: 1px solid gray", :maxlength => 50%>
<% end %>
</p>
<% if User.current.admin?%>