add default value for terms of use in site.rake(need to find a way to break line in the terms)

This commit is contained in:
thomaschen 2013-12-20 18:27:00 +08:00 committed by saurabhbhatia
parent ebeb243249
commit fd45a70291
1 changed files with 16 additions and 0 deletions

View File

@ -19,12 +19,28 @@ namespace :site do
task :necessary_data => :environment do
site = Site.first
site.title = 'RulingOrbit Demo Site'
site.save
# home_trans = I18nVariable.create!( :document_class => 'Home', :key => 'home', :en => 'Homepage', :zh_tw => '首頁')
design = Design.first
site = Site.first
site.design = design
site.terms_of_use_translations = {"en"=>"1. The copyright of the documents in this web site is belonged to RulingDigital Inc.. It is free for non-commercial use and required to register the source “RulingDigital Inc.”. 2. Documents specified above follow the rules of separate authorization regulations.
3. We will make every effort to ensure that the data of the web pages is immediate and correct but it cannot guarantee any responsibilities. We have the authorities to change the contents of the web pages without notice in advance. Therefore, please contact the people who are in charge to make sure whatever you may concern, like the date or qualification of the tests.
4. The web site is free of any software virus but not guaranteed. We are not responsible for any loss or damage however caused by the downloaded data from this web.
5. Hyperlinks to other websites are provided as a convenience only, and imply neither responsibility for, nor approval of, the information contained in those other web sites.
6. This web site does not use cookies and also not track individual visitors to our web site. If you provide personally identifiable information about yourself, we will not use the information for any purpose other than to respond to your inquiry.
7. The revision of the regulations is not notified in advance. Any user who has opinions or suggestions to the rules of this website, please contact the webmaster.",
"zh_tw"=>"1. 本網站所刊載資料之著作權,除另有規定外,屬於 銳綸數位股份有限公司(下稱「本單位」)。任何人得為非營利目的自由使用。但使用時,不得變更其內容、詆毀或減損本單位名譽,且必須註明來源為「銳綸數位股份有限公司」。
2. 使使
3. 使
4.
5. 使便
6. 使 cookies 使使使使
7. 使使"}
site.save
theme = design.themes.first
home = Page.new( :design_id => design.id, :name => 'home', :is_published => true, :theme_id => nil, :menu_enabled_for => {"zh_tw"=>"true", "en"=>"true"} )