Did I find the right examples for you? yes no

All Samples(1)  |  Call(0)  |  Derive(0)  |  Import(1)

src/c/o/commcare-hq-HEAD/corehq/apps/reminders/forms.py   commcare-hq(Download)
from corehq.apps.groups.models import Group
from corehq.apps.hqwebapp.crispy import BootstrapMultiField, FieldsetAccordionGroup, HiddenFieldWithErrors, FieldWithHelpBubble
from .models import (
    REPEAT_SCHEDULE_INDEFINITELY,
    CaseReminderEvent,
MATCH_TYPE_DISPLAY_CHOICES = (
    (MATCH_EXACT, "equals"),
    (MATCH_ANY_VALUE, "exists"),
    (MATCH_REGEX, "matches the regular expression")
)
    def clean_start_value(self):
        if self.cleaned_data.get("start_match_type", None) == MATCH_ANY_VALUE or self.cleaned_data.get("start_condition_type") != CASE_CRITERIA:
            return None
        else:
            value = self.cleaned_data.get("start_value").strip()
 
MATCH_TYPE_CHOICES = (
    (MATCH_ANY_VALUE, "exists."),
    (MATCH_EXACT, "equals"),
    (MATCH_REGEX, "matches regular expression"),
    def relevant_choices(self):
        return {
            'MATCH_ANY_VALUE': MATCH_ANY_VALUE,
            'START_REMINDER_ON_CASE_PROPERTY': START_REMINDER_ON_CASE_PROPERTY,
            'START_REMINDER_ON_CASE_DATE': START_REMINDER_ON_CASE_DATE,