myexperiment-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[myexperiment-hackers] [2801] branches/datasets: Merged layout update fr


From: noreply
Subject: [myexperiment-hackers] [2801] branches/datasets: Merged layout update from trunk
Date: Thu, 10 Nov 2011 10:23:19 -0500 (EST)

Revision
2801
Author
fbacall
Date
2011-11-10 10:23:19 -0500 (Thu, 10 Nov 2011)

Log Message

Merged layout update from trunk

Modified Paths

Diff

Modified: branches/datasets/app/models/network.rb (2800 => 2801)


--- branches/datasets/app/models/network.rb	2011-11-10 14:52:03 UTC (rev 2800)
+++ branches/datasets/app/models/network.rb	2011-11-10 15:23:19 UTC (rev 2801)
@@ -213,7 +213,7 @@
     new_member_policy == :invitation_only
   end
 
-  #Returns the page_template defined for this network in settings.yml > layouts:
+  #Returns the layout defined for this network in settings.yml > layouts:
   def layout_name
     Conf.layouts.each do |k,v|
       if v["network_id"] == id

Modified: branches/datasets/config/default_settings.yml (2800 => 2801)


--- branches/datasets/config/default_settings.yml	2011-11-10 14:52:03 UTC (rev 2800)
+++ branches/datasets/config/default_settings.yml	2011-11-10 15:23:19 UTC (rev 2801)
@@ -469,6 +469,8 @@
 #
 #     Example:
 #
+#layouts:
+#
 #     example_layout:
 #       network_id: 123
 #       stylesheets:

Modified: branches/datasets/db/schema.rb (2800 => 2801)


--- branches/datasets/db/schema.rb	2011-11-10 14:52:03 UTC (rev 2800)
+++ branches/datasets/db/schema.rb	2011-11-10 15:23:19 UTC (rev 2801)
@@ -2,7 +2,7 @@
 # migrations feature of ActiveRecord to incrementally modify your database, and
 # then regenerate this schema definition.
 
-ActiveRecord::Schema.define(:version => 95) do
+ActiveRecord::Schema.define(:version => 93) do
 
   create_table "activity_limits", :force => true do |t|
     t.column "contributor_type", :string,   :null => false
@@ -156,6 +156,7 @@
     t.column "rating",               :float
     t.column "contributable_type",   :string
     t.column "contributor_id",       :integer
+    t.column "layout",               :string
     t.column "created_at",           :datetime
     t.column "policy_id",            :integer
     t.column "updated_at",           :datetime
@@ -168,7 +169,6 @@
     t.column "downloads_count",      :integer,  :default => 0
     t.column "site_viewings_count",  :integer,  :default => 0
     t.column "contributable_id",     :integer
-    t.column "layout",               :string
   end
 
   add_index "contributions", ["contributable_id", "contributable_type"], :name => "index_contributions_on_contributable_id_and_contributable_type"
@@ -194,10 +194,25 @@
     t.column "updated_at",   :datetime
   end
 
+  create_table "data_items", :force => true do |t|
+    t.column "label",       :text
+    t.column "data",        :text
+    t.column "category",    :text
+    t.column "created_at",  :datetime
+    t.column "data_set_id", :integer
+    t.column "updated_at",  :datetime
+  end
+
   create_table "data_sets", :force => true do |t|
-    t.column "workflow_id", :integer
-    t.column "title",       :string
-    t.column "description", :text
+    t.column "contributable_type", :string
+    t.column "category",           :text
+    t.column "description_html",   :text
+    t.column "created_at",         :datetime
+    t.column "title",              :text
+    t.column "updated_at",         :datetime
+    t.column "user_id",            :integer
+    t.column "description",        :text
+    t.column "contributable_id",   :integer
   end
 
   create_table "downloads", :force => true do |t|
@@ -756,12 +771,6 @@
     t.column "description",      :text
   end
 
-  create_table "workflow_ports", :force => true do |t|
-    t.column "workflow_id", :integer
-    t.column "port_type",   :string
-    t.column "name",        :string
-  end
-
   create_table "workflow_processors", :force => true do |t|
     t.column "name",           :string
     t.column "wsdl_operation", :string

Modified: branches/datasets/lib/conf.rb (2800 => 2801)


--- branches/datasets/lib/conf.rb	2011-11-10 14:52:03 UTC (rev 2800)
+++ branches/datasets/lib/conf.rb	2011-11-10 15:23:19 UTC (rev 2801)
@@ -167,7 +167,8 @@
 
   def self.layouts
     #TODO: Perhaps implement code that can load different/extra settings files based on current environment
-    self.fetch_entry('layouts').delete_if {|k,v| v["environment"] && (v["environment"] != ENV["RAILS_ENV"])}
+    layouts = self.fetch_entry('layouts')
+    layouts ? layouts.delete_if {|k,v| v["environment"] && (v["environment"] != ENV["RAILS_ENV"])} : {}
   end
 
   # This method is required to create an administrator in the test fixtures

reply via email to

[Prev in Thread] Current Thread [Next in Thread]