perf: Acl action add notify and warn

pull/14095/head
feng 3 months ago committed by feng626
parent 50d3a4906a
commit 054d385ffc

@ -8,3 +8,4 @@ class ActionChoices(models.TextChoices):
review = 'review', _('Review') review = 'review', _('Review')
warning = 'warning', _('Warn') warning = 'warning', _('Warn')
notice = 'notice', _('Notify') notice = 'notice', _('Notify')
notify_and_warn = 'notify_and_warn', _('Notify and warn')

@ -62,7 +62,7 @@ class ActionAclSerializer(serializers.Serializer):
self.set_action_choices() self.set_action_choices()
class Meta: class Meta:
action_choices_exclude = [ActionChoices.warning] action_choices_exclude = [ActionChoices.warning, ActionChoices.notify_and_warn]
def set_action_choices(self): def set_action_choices(self):
field_action = self.fields.get("action") field_action = self.fields.get("action")

Loading…
Cancel
Save