mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-13 21:21:27 +00:00
searchfolder returns full path of folder
This commit is contained in:
parent
e8192d2813
commit
a5e975caa5
|
@ -161,7 +161,8 @@ switch($command) {
|
||||||
$result = array();
|
$result = array();
|
||||||
foreach($hits['folders'] as $hit) {
|
foreach($hits['folders'] as $hit) {
|
||||||
if($hit->getAccessMode($user, 'search') >= M_READ)
|
if($hit->getAccessMode($user, 'search') >= M_READ)
|
||||||
$result[] = $hit->getID().'#'.$basefolder->getName().'/'.$hit->getName();
|
//$result[] = $hit->getID().'#'.$basefolder->getName().'/'.$hit->getName();
|
||||||
|
$result[] = $hit->getID().'#'.$hit->getFolderPathPlain(true, '/');
|
||||||
}
|
}
|
||||||
header('Content-Type: application/json');
|
header('Content-Type: application/json');
|
||||||
echo json_encode($result);
|
echo json_encode($result);
|
||||||
|
@ -172,7 +173,8 @@ switch($command) {
|
||||||
$subfolders = SeedDMS_Core_DMS::filterAccess($subfolders, $user, M_READ);
|
$subfolders = SeedDMS_Core_DMS::filterAccess($subfolders, $user, M_READ);
|
||||||
$result = array();
|
$result = array();
|
||||||
foreach($subfolders as $subfolder) {
|
foreach($subfolders as $subfolder) {
|
||||||
$result[] = $subfolder->getID().'#'.$basefolder->getName().'/'.$subfolder->getName();
|
//$result[] = $subfolder->getID().'#'.$basefolder->getName().'/'.$subfolder->getName();
|
||||||
|
$result[] = $subfolder->getID().'#'.$subfolder->getFolderPathPlain(true, '/');
|
||||||
}
|
}
|
||||||
header('Content-Type: application/json');
|
header('Content-Type: application/json');
|
||||||
echo json_encode($result);
|
echo json_encode($result);
|
||||||
|
@ -187,7 +189,7 @@ switch($command) {
|
||||||
$result = array();
|
$result = array();
|
||||||
foreach($hits['folders'] as $hit) {
|
foreach($hits['folders'] as $hit) {
|
||||||
if($hit->getAccessMode($user, 'search') >= M_READ)
|
if($hit->getAccessMode($user, 'search') >= M_READ)
|
||||||
$result[] = $hit->getID().'#'.$hit->getName();
|
$result[] = $hit->getID().'#'.$hit->getFolderPathPlain(true, '/');
|
||||||
}
|
}
|
||||||
header('Content-Type: application/json');
|
header('Content-Type: application/json');
|
||||||
echo json_encode($result);
|
echo json_encode($result);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user