Revision 649f2d36 snf-astakos-app/astakos/im/models.py
b/snf-astakos-app/astakos/im/models.py | ||
---|---|---|
589 | 589 |
def can_change_password(self): |
590 | 590 |
return self.has_auth_provider('local', auth_backend='astakos') |
591 | 591 |
|
592 |
def can_change_email(self): |
|
593 |
non_astakos_local = self.get_auth_providers().filter(module='local') |
|
594 |
non_astakos_local = non_astakos_local.exclude(auth_backend='astakos') |
|
595 |
return non_astakos_local.count() == 0 |
|
596 |
|
|
592 | 597 |
def has_required_auth_providers(self): |
593 | 598 |
required = auth_providers.REQUIRED_PROVIDERS |
594 | 599 |
for provider in required: |
Also available in: Unified diff