Hello,
I think it's not a Laravel problem.
You have to write a some queries to retrieve the good informations and then you have to use a library like GD to draw your chart.
V
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I have the following tables
'usertree'
parentid | Child id | type
'parentid' and 'child id' are the 'users id' based on the 'user.type' admin, teacher,manager,student.
are connected toghther
type 1,2,3,4 | parentid | Child id |
.......................................................................
if type = 1 : admin to manager connection
if type = 2 : manager to teacher connection
if type = 3 : teacher to teacher connection
if type = 4 : teacher to student connection
'user table'
name | email | type | phone num
where
'user.type' admin, teacher,manager,student.
I want to create a tree for the usertree table based on the type condition in the usertree when admin can see the entire connection and do CRUD on them.
can anyone show me a way to do that? or a package in laravel?
what I want to implement is something like that
Please or to participate in this conversation.