Open LenkaSoma opened 4 years ago
Hi for first can you change the environment to development for seeing your error? change environment on index.php
Thanks
I managed to remove the blank page by adding the variable in the controller and making a condition with it.
lsdh_effectifs.php (controller)
$this->data['test'] = $this->model_lsdh_effectifs->roles();
lsdh_effectifs_list.php (view)
<?php if ($test == true): ?>
A problem solved, but it still does not work, I may have crashed in the function ... :/
can you change
$result = $this->db->get()->row(); dd($result);
for see return value
blank page :x
A Database Error Occurred
Error Number: 1052
Column 'roles' in field list is ambiguous
SELECT `roles` FROM `lsdh_effectifs` LEFT JOIN `aauth_users` ON `aauth_users`.`username` = `lsdh_effectifs`.`lsdh_id`
Filename: /home/armalifejq/intranet/modules/lsdh_effectifs/models/Model_lsdh_effectifs.php
Line Number: 95
It's okay, I don't have the error anymore, I also had a roles column in aauth_users, the result returns value1 but the condition doesn't work
Hello, I have a little problem,
I'm trying to check the user's
role
in thelsdh_effectifs
table but to verify the user, I need to check if hisusername
in theaauth_users
table is the same as thelsdh_id
inlsdh_effectifs
j tried to create a request on the view with a php condition but a blank page appears, so I tried to create a function on the model but similarly a blank page appears, do you have any idea of the problem ?More simply, I want the user to be able to see the content only if he has
value1
as value in theroles
column of thelsdh_effectifs
tableModel_lsdh_effectifs.php (model)
lsdh_effectifs_list.php (view)
Thank you very much