Subject: | ENUM values not listed |
Attached is a patch that adds the allowed values of ENUM columns to the
data type specification.
Subject: | enum.diff |
commit 492351cd04cb70531fc572c3a9c7b483e5672176
Author: Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>
Date: 2009-04-07 14:29:31 +0100
Add value list for enum columns
diff --git a/templates/column_type.tt2 b/templates/column_type.tt2
index 7bbd125..7167896 100644
--- a/templates/column_type.tt2
+++ b/templates/column_type.tt2
@@ -1,6 +1,8 @@
[%- FILTER collapse %]
[% col.data_type -%]
+ [%- IF col.data_type == 'enum' AND col.extra.list.size %]('[% col.extra.list.join("','") %]')[% END %]
[%- IF col.exists( 'size' ) AND col.size %]([% col.size.join(',') %])[% END %]
[%# col.exists is to keep .size from being interpreted as a vmethod #%]
+
[% END -%]
[%# $Id$ #%]