Esempio n. 1
0
def create_default_per_instance_preferences(sender, created, instance, **kwargs):
    """Create default preferences for PerInstancePreferenceModel"""

    if created:
        try:
            registry = preference_models.get_by_instance(instance)
            registry.create_default_preferences(instance)
        except AttributeError:
            pass
def create_default_per_instance_preferences(sender, created, instance,
                                            **kwargs):
    """Create default preferences for PerInstancePreferenceModel"""

    if created:
        try:
            registry = preference_models.get_by_instance(instance)
            registry.create_default_preferences(instance)
        except AttributeError:
            pass
Esempio n. 3
0
 def registry(self):
     return preference_models.get_by_instance(self.instance)
Esempio n. 4
0
 def registry(self):
     return preference_models.get_by_instance(self.instance)