Users and Roles Confusion

"chambrenoire [email protected] [domaindrivendesign]" <[email protected]> Wed, 6 Sep 2017 03:43:23 -0700 (MST)
Newsgroups gmane.comp.programming.domain-driven-design
Message-ID <[email protected]>
Hello

I=E2=80=99m new to DDD and working on a new domain model. Here=E2=80=99s th=
e gist:

I have four types of users : a unique Admin, Managers and Assistants (both
Employees) and Clients
All are Persons except the Admin who has no name or personal details.=20
Both Employees and Clients are assigned to a single Branch.=20
A Manager owns a number of Clients.=20
Assistants are assigned to any number of Managers within the same Branch.
Assistants can thus access all Clients of their assigned Managers.

My initial attempt is na=C3=AFve and presents the usual problems. User > Pe=
rson >
Practitioner and so a) all Persons and thus Practitioners are necessarily
Users and b) a user cannot fill both the Manager and Assistant roles
simultaneously. There=E2=80=99s also a chance that Branches will in the fut=
ure have
their own unique User accounts but simply extending User forces all Branche=
s
to be users=E2=80=A6

I have looked into the =E2=80=9Crole object=E2=80=9D pattern and have looke=
d at previous
threads on the subject but I=E2=80=99m still hazy on this. I have seen comm=
ents
mentioning Qi4j (now Apache Polygene) and it is also mentioned in Vince
Vaughan=E2=80=99s IDDD but using this isn=E2=80=99t an option at the moment=
.

Any help or pointers would be most appreciated.

Many thanks,

CN



--
Sent from: http://domain-driven-design.3010926.n2.nabble.com/


------------------------------------
Posted by: chambrenoire <[email protected]>
------------------------------------


------------------------------------

Yahoo Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/domaindrivendesign/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/domaindrivendesign/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected]=20
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo Groups is subject to:
    https://info.yahoo.com/legal/us/yahoo/utos/terms/