equal
deleted
inserted
replaced
1725 document = document_logic.getFromKeyFieldsOr404(django_args) |
1725 document = document_logic.getFromKeyFieldsOr404(django_args) |
1726 |
1726 |
1727 self.checkMembership('write', document.prefix, |
1727 self.checkMembership('write', document.prefix, |
1728 document.write_access, django_args) |
1728 document.write_access, django_args) |
1729 |
1729 |
|
1730 @denySidebar |
1730 @allowDeveloper |
1731 @allowDeveloper |
1731 def checkDocumentList(self, django_args): |
1732 def checkDocumentList(self, django_args): |
1732 """Checks whether the user is allowed to list documents. |
1733 """Checks whether the user is allowed to list documents. |
1733 |
1734 |
1734 Args: |
1735 Args: |
1742 roles = checker.getMembership('list') |
1743 roles = checker.getMembership('list') |
1743 |
1744 |
1744 if not self.hasMembership(roles, filter): |
1745 if not self.hasMembership(roles, filter): |
1745 raise out_of_band.AccessViolation(message_fmt=DEF_NO_LIST_ACCESS_MSG) |
1746 raise out_of_band.AccessViolation(message_fmt=DEF_NO_LIST_ACCESS_MSG) |
1746 |
1747 |
|
1748 @denySidebar |
1747 @allowDeveloper |
1749 @allowDeveloper |
1748 def checkDocumentPick(self, django_args): |
1750 def checkDocumentPick(self, django_args): |
1749 """Checks whether the user has access to the specified pick url. |
1751 """Checks whether the user has access to the specified pick url. |
1750 |
1752 |
1751 Will update the 'read_access' field of django_args['GET']. |
1753 Will update the 'read_access' field of django_args['GET']. |