Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Nounous
re2o
Commits
2263b97d
Commit
2263b97d
authored
Jul 15, 2018
by
Hugo LEVY-FALK
Browse files
Le droit add_facture englobe buy_every_article et use_every_payment
parent
899cd863
Changes
1
Hide whitespace changes
Inline
Side-by-side
cotisations/models.py
View file @
2263b97d
...
...
@@ -565,7 +565,8 @@ class Article(RevMixin, AclMixin, models.Model):
"""
return
(
self
.
available_for_everyone
or
user
.
has_perm
(
'cotisations.buy_every_article'
),
or
user
.
has_perm
(
'cotisations.buy_every_article'
)
or
user
.
has_perm
(
'cotisations.add_facture'
),
_
(
"You cannot buy this Article."
)
)
...
...
@@ -701,7 +702,8 @@ class Paiement(RevMixin, AclMixin, models.Model):
"""
return
(
self
.
available_for_everyone
or
user
.
has_perm
(
'cotisations.use_every_payment'
),
or
user
.
has_perm
(
'cotisations.use_every_payment'
)
or
user
.
has_perm
(
'cotisations.add_facture'
),
_
(
"You cannot use this Payment."
)
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment