User entry of Organization does not match valid organization name values

Create issue
Issue #1477 new
Darren Hollenbeck created an issue

In the contact model, the OrganizationManager by_name() method filters on role and type:

class OrganizationManager(models.Manager):
    def by_name(self, name, create=False, role='Customer', orgtype='Company'):
        org = None
        orgs = self.filter(name=name, role__key=role, type__key=orgtype)

...but the user form (edit profile) has no way of providing alternatives to these keys, so if you have actually assigned a non-default role or type in the admin site, any user input of an organization won't match the existing one and will instead create a new record.

Not sure I see the point of filtering on role and type in the by_name method.

Comments (0)

  1. Log in to comment