Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Check for MeetingGroupProposal status to be accepted before creating MeetingGroup #198

Open
shamil-sadigov opened this issue Apr 28, 2021 · 1 comment

Comments

@shamil-sadigov
Copy link

shamil-sadigov commented Apr 28, 2021

First of all, thank you for this masterpiece, I gained a lot of insights and knowledge from this repo!

Don't you think we should add a rule check to make sure that proposal has been accepted by the Administration module?

public MeetingGroup CreateMeetingGroup()
{
return MeetingGroup.CreateBasedOnProposal(this.Id, _name, _description, _location, _proposalUserId);
}

I mean something like this

public MeetingGroup CreateMeetingGroup()
{
    CheckRule(new MeetingGroupProposalMustBeAcceptedRule(_status));
    return MeetingGroup.CreateBasedOnProposal(Id, _name, _description, _location, _proposalUserId);
}

PS: I may create a PR. But just wanted to be sure that I understand business logic correctly 😅

@kgrzybek
Copy link
Owner

kgrzybek commented Jun 8, 2021

@shamil-sadigov yes, you are right.

Even from the current implementation of the Application layer this kind of situation is not possible, it might be possible in the future so this rule should be checked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants