konova/ema/views/share.py
mpeltriaux 00bf03f58d # Share view refactoring
* refactors share views for eiv, oek, ema (kom does not have any)
2025-11-28 11:53:43 +01:00

21 lines
576 B
Python

"""
Author: Michel Peltriaux
Organization: Struktur- und Genehmigungsdirektion Nord, Rhineland-Palatinate, Germany
Contact: ksp-servicestelle@sgdnord.rlp.de
Created on: 19.08.22
"""
from ema.models import Ema
from konova.views.share import AbstractShareByTokenView, AbstractShareFormView
class EmaShareByTokenView(AbstractShareByTokenView):
_MODEL_CLS = Ema
_REDIRECT_URL = "ema:detail"
class EmaShareFormView(AbstractShareFormView):
_MODEL_CLS = Ema
_REDIRECT_URL = "ema:detail"
def _user_has_permission(self, user):
return user.is_ets_user()