diff --git a/app/controllers/admin_controller.rb b/app/controllers/admin_controller.rb index 781d07d58..a76a78dcb 100644 --- a/app/controllers/admin_controller.rb +++ b/app/controllers/admin_controller.rb @@ -148,8 +148,8 @@ class AdminController < ApplicationController elsif request.post? @first_page = FirstPage.where("page_type = 'project'").first @first_page.web_title = params[:web_title] - @first_page.description = params[:description] - @first_page.title = params[:title] + @first_page.description = params[:first_page][:description] + #@first_page.title = params[:title] @first_page.sort_type = params[:sort_type] if @first_page.save respond_to do |format| diff --git a/app/models/first_page.rb b/app/models/first_page.rb index 52c6e204d..58d20901e 100644 --- a/app/models/first_page.rb +++ b/app/models/first_page.rb @@ -2,5 +2,5 @@ class FirstPage < ActiveRecord::Base attr_accessible :description, :title, :web_title,:page_type,:sort_type validates_presence_of :web_title, :title, :description,:page_type validates_length_of :web_title,:title, maximum: 30 - validates_length_of :description, maximum: 100 + #validates_length_of :description, maximum: 100 end diff --git a/app/views/admin/first_page_made.html.erb b/app/views/admin/first_page_made.html.erb index 242b7c689..e4a5119d3 100644 --- a/app/views/admin/first_page_made.html.erb +++ b/app/views/admin/first_page_made.html.erb @@ -20,13 +20,15 @@ <%= render :partial=>"avatar/avatar_form",:style => "display:inline",:locals=> {source:@first_page} %> -

- - <%= text_field_tag 'title', params[:label_site_title], :value => @first_page.title,:size => 30,:style => "font-size:small;width:490px;margin-left:10px;" %> -

+

- <%= text_area_tag 'description',@first_page.description,:rows => 8, :size => 30,:style => "font-size:small;width:490px;margin-left:10px;" %> + + <%= text_area 'first_page', 'description', :value => @first_page.description,:cols => 80, :rows => 15, :class => 'wiki-edit' %> + <%= wikitoolbar_for 'first_page_description' %>

diff --git a/app/views/welcome/index.html.erb b/app/views/welcome/index.html.erb index dbd841159..b68bf5773 100644 --- a/app/views/welcome/index.html.erb +++ b/app/views/welcome/index.html.erb @@ -45,7 +45,8 @@

<% unless @first_page.nil? %> - <%= @first_page.title %> , <%= @first_page.description %> + + <%= @first_page.description.html_safe %> <% end %>