Show More
@@ -172,6 +172,7 b' class DbManage(object):' | |||||
172 |
|
172 | |||
173 | def step_4(self): |
|
173 | def step_4(self): | |
174 | print ('TODO:') |
|
174 | print ('TODO:') | |
|
175 | self.create_permissions() | |||
175 | self.klass.fixup_groups() |
|
176 | self.klass.fixup_groups() | |
176 |
|
177 | |||
177 | upgrade_steps = [0] + range(curr_version + 1, __dbversion__ + 1) |
|
178 | upgrade_steps = [0] + range(curr_version + 1, __dbversion__ + 1) | |
@@ -483,10 +484,11 b' class DbManage(object):' | |||||
483 | ] |
|
484 | ] | |
484 |
|
485 | |||
485 | for p in perms: |
|
486 | for p in perms: | |
486 |
|
|
487 | if not Permission.get_by_key(p): | |
487 |
new_perm |
|
488 | new_perm = Permission() | |
488 |
new_perm.permission_ |
|
489 | new_perm.permission_name = p[0] | |
489 | self.sa.add(new_perm) |
|
490 | new_perm.permission_longname = p[1] | |
|
491 | self.sa.add(new_perm) | |||
490 |
|
492 | |||
491 | def populate_default_permissions(self): |
|
493 | def populate_default_permissions(self): | |
492 | log.info('creating default user permissions') |
|
494 | log.info('creating default user permissions') |
General Comments 0
You need to be logged in to leave comments.
Login now