Skip to content

Commit

Permalink
Corrige erro em update_groups
Browse files Browse the repository at this point in the history
  • Loading branch information
LeandroJatai committed Nov 27, 2017
1 parent 87b2f92 commit 079ce5e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion sapl/rules/apps.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,8 @@ def cria_usuario(self, nome, grupo):
**param_username)[0]
usuario.set_password('interlegis')
usuario.save()
grupo.user_set.add(usuario)
g = Group.objects.get_or_create(name=grupo)[0]
g.user_set.add(usuario)

def cria_usuarios_padrao(self):
for group, user in (
Expand Down
2 changes: 1 addition & 1 deletion sapl/rules/map_rules.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@
'view_tabelas_auxiliares'
]),

(base.CasaLegislativa, __listdetailchange__),
(base.CasaLegislativa, __listdetailchange__ + [RP_ADD]),
(base.ProblemaMigracao, []),
(base.Argumento, []),
(base.Constraint, []),
Expand Down

0 comments on commit 079ce5e

Please sign in to comment.