Skip to content

Commit

Permalink
Ready to release 0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
limodou committed May 21, 2016
1 parent 7f6780b commit ef6d158
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion uliweb/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
__author_email__ = '[email protected]'
__url__ = 'https://github.com/limodou/uliweb'
__license__ = 'BSD'
version = __version__ = '0.5b1'
version = __version__ = '0.5'

import os, sys
workpath = os.path.dirname(__file__)
Expand Down
4 changes: 3 additions & 1 deletion uliweb/contrib/orm/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -1204,6 +1204,8 @@ class ReflectCommand(SQLCommandMixin, Command):
option_list = (
make_option('-o', '--oracle', dest='oracle', action='store_true', default=False,
help='Create model using oracle dialect, especially using VARCHAR2.'),
make_option('--auto-id', dest='auto_id', action='store_true', default=False,
help='Automatically add id field. Default is False.'),
)
help = 'Reflect database tables to Uliweb model class code.'

Expand Down Expand Up @@ -1234,7 +1236,7 @@ def handle(self, options, global_options, *args):
table = Table(name, meta)
try:
insp.reflecttable(table, None)
print reflect_table_model(table, mapping)
print reflect_table_model(table, mapping, without_id=not options.auto_id)
print '\n'
except Exception as e:
import traceback
Expand Down

0 comments on commit ef6d158

Please sign in to comment.