aboutsummaryrefslogtreecommitdiffstats
path: root/app/models/public_body.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/public_body.rb')
-rw-r--r--app/models/public_body.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/models/public_body.rb b/app/models/public_body.rb
index c45ec75a6..82eaa5822 100644
--- a/app/models/public_body.rb
+++ b/app/models/public_body.rb
@@ -22,14 +22,12 @@
# Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved.
# Email: francis@mysociety.org; WWW: http://www.mysociety.org/
#
-# $Id: public_body.rb,v 1.33 2008-03-05 18:14:03 francis Exp $
+# $Id: public_body.rb,v 1.34 2008-03-07 23:13:38 francis Exp $
require 'csv'
require 'set'
class PublicBody < ActiveRecord::Base
- #acts_as_solr :fields => [:name, :short_name]
-
validates_presence_of :name
validates_presence_of :url_name
validates_presence_of :request_email
@@ -61,6 +59,8 @@ class PublicBody < ActiveRecord::Base
acts_as_versioned
self.non_versioned_columns << 'created_at' << 'updated_at'
+ acts_as_solr :fields => [{:name => { :boost => 10.0 }}, {:short_name => { :boost => 10.0 }} ]
+
# When name or short name is changed, also change the url name
def short_name=(short_name)
write_attribute(:short_name, short_name)