The plan is to have userconnted toteacherthat is connected toSchool.
The reason is to have all the information on the teacher but also connect the teacher (list) to a school so they can work toghether.
Is this a bad workflow? How do i set this up in the workflow? Create account, create a new thing (Teacher) user = current user > create new thing (school) teacher = result of step 1 is all the way i have come so far, is it wrong?
But how do i connect Teacher with the school now when i have the school connected with the teacher? Am i thinking this through correctly?
The lists are probably not a good idea given that schools could have hundreds of students and lists become incredibly inefficient very quickly. You don’t need a list of teachers on the school. If you want to display teachers for a given school, just Do a search for Teachers where School = X
And when i tried to display it with “Current user Taechers Schools Name” It’s all blank on the teachers page? It does not seem to be linked? In the user they have a teacher conneted and that teacher is conneted to a School like i showed above?
A student is part of a school. A student also has a teacher. Therefore, a Student should have a School field and a Teacher field.
A teacher is part of a school. The Teacher should have a School field.
The School is part of nothing. The School does not need any additional fields to relate it to other data.
When you create a Student, set the Teacher and School field to the relevant Thing in your data base. Then, you can reference Student’s Teacher or Student’s School. Student’s School will be equal to Student’s Teacher’s School, but Student’s School is more efficient.
This is the current setup i have now.
I have checked the database and User is assigned to Teacher and Teacher is Assigned to a School in the database. When i try to display the school’s name it is blank, why? Are they linked or am i trying to display it wrong?
Can anyone sign up and assign themselves to a certain school? Or can a school admin only invite others to their school privately? It really depends on your application. This might be a part of your issue and you might not realize it if you just went to the database and attached a school to your teacher.
Hey, @Orbit! An interesting idea to consider is adding a ‘type’ column to your user table. This way, you can easily define different user types (such as students or school admins) and specify their permissions or access to certain data/pages.
For example, your main users might be teachers. When creating a new user, you can simply assign the ‘type’ as ‘teacher’.
To enhance efficiency, you can create an Option Set called ‘user_types’. The ‘type’ column on the user table would then be linked to this Option Set. This setup gives you better control when adding new user types.
Hey @stela.vas, thanks for taking the time to do this detailed comment, i accualy just added it yesterday from a youtube video haha! It is very good idea, now in the workflow i also assign the “Role” Teacher to the user so i can keep track and also for permissions
That’s great! Yeah, this structure helps a lot, i’d say it’s a must have for applications that have different types of users. And no prob, my pelasure!