Browse Source

Merged migrations.

Martin Edenhofer 9 years ago
parent
commit
ea640474a3

+ 1 - 0
db/migrate/20120101000010_create_ticket.rb

@@ -63,6 +63,7 @@ class CreateTicket < ActiveRecord::Migration
       t.column :escalation_time,                  :timestamp,             null: true
       t.column :pending_time,                     :timestamp,             null: true
       t.column :type,                             :string, limit: 100,    null: true
+      t.column :preferences,                      :text,   limit: 500.kilobytes + 1, null: true
       t.column :updated_by_id,                    :integer,               null: false
       t.column :created_by_id,                    :integer,               null: false
       t.timestamps                                                        null: false

+ 3 - 3
db/migrate/20150971000001_update_settings4.rb

@@ -60,9 +60,9 @@ class UpdateSettings4 < ActiveRecord::Migration
             name: 'ticket_hook_position',
             tag: 'select',
             options: {
-              'left'  => 'Left',
-              'right' => 'Right',
-              'none'  => 'None',
+              'left'  => 'left',
+              'right' => 'right',
+              'none'  => 'none',
             },
           },
         ],

+ 19 - 0
db/migrate/20151109000001_create_chat.rb

@@ -77,6 +77,25 @@ class CreateChat < ActiveRecord::Migration
       created_by_id: 1,
     )
 
+    Scheduler.create_or_update(
+      name: 'Closed chat sessions where participients are offline.',
+      method: 'Chat.cleanup_close',
+      period: 60 * 15,
+      prio: 2,
+      active: true,
+      updated_by_id: 1,
+      created_by_id: 1,
+    )
+    Scheduler.create_or_update(
+      name: 'Cleanup closed sessions.',
+      method: 'Chat.cleanup',
+      period: 5.days,
+      prio: 2,
+      active: true,
+      updated_by_id: 1,
+      created_by_id: 1,
+    )
+
   end
 
   def down

+ 0 - 25
db/migrate/20151210000001_update_chat4.rb

@@ -1,25 +0,0 @@
-class UpdateChat4 < ActiveRecord::Migration
-  def up
-    Scheduler.create_or_update(
-      name: 'Closed chat sessions where participients are offline.',
-      method: 'Chat.cleanup_close',
-      period: 60 * 15,
-      prio: 2,
-      active: true,
-      updated_by_id: 1,
-      created_by_id: 1,
-    )
-    Scheduler.create_or_update(
-      name: 'Cleanup closed sessions.',
-      method: 'Chat.cleanup',
-      period: 5.days,
-      prio: 2,
-      active: true,
-      updated_by_id: 1,
-      created_by_id: 1,
-    )
-  end
-
-  def down
-  end
-end

+ 0 - 5
db/migrate/20151213000001_update_ticket_preferences.rb

@@ -1,5 +0,0 @@
-class UpdateTicketPreferences < ActiveRecord::Migration
-  def up
-    add_column :tickets, :preferences, :text, limit: 500.kilobytes + 1, null: true
-  end
-end