Sha256: e633f357a71c5fb4dbabfc1381bf4d473d8eeec2c3dca2a964ee6032a68c54ad
Contents?: true
Size: 1.12 KB
Versions: 6
Compression:
Stored size: 1.12 KB
Contents
Sequel.migration do up do run "CREATE TABLE `relationships` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `name` varchar(255) DEFAULT NULL, `active` tinyint(1) unsigned NOT NULL DEFAULT '1', `chain_id` int(11) unsigned DEFAULT NULL, `trigger_id` int(11) unsigned NOT NULL, `action_id` int(11) unsigned NOT NULL, `delay` int(11) unsigned NOT NULL DEFAULT '0', `allow_new_chains` tinyint(1) unsigned NOT NULL DEFAULT '1', `conditions` text, `transformation` text, `created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP, `updated` datetime DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (`id`), KEY `chain_id` (`chain_id`), CONSTRAINT `function_chain_id` FOREIGN KEY (`chain_id`) REFERENCES `chains` (`id`) ON DELETE CASCADE ON UPDATE CASCADE, CONSTRAINT `relationship_action_id` FOREIGN KEY (`action_id`) REFERENCES `functions` (`id`) ON DELETE CASCADE ON UPDATE CASCADE, CONSTRAINT `relationship_trigger_id` FOREIGN KEY (`trigger_id`) REFERENCES `functions` (`id`) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=utf8;" end down do drop_table :relationships end end
Version data entries
6 entries across 6 versions & 2 rubygems