Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Antoine
ae2
Commits
12227810
Commit
12227810
authored
Jun 03, 2014
by
Bate
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Les non connectes n'ont pas droit que de lire les fichiers
parent
1a71eb67
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
include/entities/basedb.inc.php
include/entities/basedb.inc.php
+8
-2
No files found.
include/entities/basedb.inc.php
View file @
12227810
...
...
@@ -104,9 +104,13 @@ abstract class basedb extends stdentity
*/
function
is_right
(
&
$user
,
$required
)
{
if
(
(
$this
->
modere
!=
0
)
&&
((
$required
&
(
$this
->
droits_acces
))
==
$required
)
)
return
true
;
if
(
!
$user
->
is_valid
())
return
false
;
if
(
!
$user
->
is_valid
())
{
if
(
$required
==
DROIT_LECTURE
&&
(
$this
->
droits_access
&
DROIT_LECTURE
>
0
))
return
true
;
else
return
false
;
}
if
(
$this
->
is_admin
(
$user
))
return
true
;
...
...
@@ -119,6 +123,8 @@ abstract class basedb extends stdentity
if
(
(
$user
->
is_in_group_id
(
$this
->
id_groupe
))
&&
(
$required
&
(
$this
->
droits_acces
>>
4
))
==
$required
)
return
true
;
if
((
$required
&
(
$this
->
droits_acces
))
==
$required
)
return
true
;
return
false
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment