Skip to content

Admissions: added new options for how houses are automatically assigned when a student application is accepted#2121

Open
ali-ichk wants to merge 2 commits into
GibbonEdu:v31.0.00from
ali-ichk:Admissions---added-new-options-for-how-houses-are-automatically-assigned-when-a-student-application-is-accepted
Open

Admissions: added new options for how houses are automatically assigned when a student application is accepted#2121
ali-ichk wants to merge 2 commits into
GibbonEdu:v31.0.00from
ali-ichk:Admissions---added-new-options-for-how-houses-are-automatically-assigned-when-a-student-application-is-accepted

Conversation

@ali-ichk

Copy link
Copy Markdown
Contributor

Description
Improved the logic to automatically assign a house based on siblings or parents.
When a new student is accepted, the system checks if their parents are staff member and assigns the same house as them. If not, the system checks if they have siblings and assigns the student to the same house as their siblings. If not, the system automatically assigns them to a house based on old logic.

@SKuipers SKuipers left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @ali-ichk, thanks for making these improvements. I notice that there are 5 or more separate database queries for this action (depending on the number of family adults), which adds a fair bit of nested logic. I wonder if the same result could be achieved with a single new query in the HouseGateway called selectExistingHouseByFamilyID, and in that query it could get the house data for a given family, ordered by staff parents first, and siblings second.

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

Successfully merging this pull request may close these issues.

2 participants