Sha256: 68112a7ed7e6368a20ed35256f6b729d03eeee5fb8894257a01f5fb9362e6e60
Contents?: true
Size: 480 Bytes
Versions: 7
Compression:
Stored size: 480 Bytes
Contents
# FIXME: move this with 'node_query' into a plugins might be cleaner # make sure there exists a link with NULL content and id == -1 (used in queries using query order sorting) class ChangeDefaultLinkIdToZero < ActiveRecord::Migration def self.up Link.connection.execute "UPDATE #{Link.table_name} SET id = 0 WHERE id = -1" NodeQuery.insert_zero_link(Link) end def self.down Link.connection.execute "UPDATE #{Link.table_name} SET id = -1 WHERE id = 0" end end
Version data entries
7 entries across 7 versions & 1 rubygems