|
|
@ -519,15 +519,7 @@ define([
|
|
|
|
var resFolders = [];
|
|
|
|
var resFolders = [];
|
|
|
|
var findFoldersRec = function (folder, path) {
|
|
|
|
var findFoldersRec = function (folder, path) {
|
|
|
|
for (var key in folder) {
|
|
|
|
for (var key in folder) {
|
|
|
|
if (isFolder(folder[key])) {
|
|
|
|
if (isFolder(folder[key]) && !isSharedFolder(folder[key])) {
|
|
|
|
if (isSharedFolder(folder[key])) {
|
|
|
|
|
|
|
|
// var name = getSharedFolderData(folder[key]).title || "";
|
|
|
|
|
|
|
|
// if (name.toLowerCase().indexOf(lValue) !== -1) {
|
|
|
|
|
|
|
|
// resFolders.push(path.concat([key, ROOT]));
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
findFoldersRec(folder[key], path.concat([key, ROOT]));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else {
|
|
|
|
|
|
|
|
if (key.toLowerCase().indexOf(lValue) !== -1) {
|
|
|
|
if (key.toLowerCase().indexOf(lValue) !== -1) {
|
|
|
|
resFolders.push({
|
|
|
|
resFolders.push({
|
|
|
|
id: null,
|
|
|
|
id: null,
|
|
|
@ -540,7 +532,6 @@ define([
|
|
|
|
findFoldersRec(folder[key], path.concat(key));
|
|
|
|
findFoldersRec(folder[key], path.concat(key));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
};
|
|
|
|
};
|
|
|
|
findFoldersRec(files[ROOT], [ROOT]);
|
|
|
|
findFoldersRec(files[ROOT], [ROOT]);
|
|
|
|
resFolders = resFolders.sort(function (a, b) {
|
|
|
|
resFolders = resFolders.sort(function (a, b) {
|
|
|
|