assign('breadcrumb', $breadcrumb, false); $breadcrumbNav->assign('baseURL', $baseUrl); $data['breadcrumb'] = $breadcrumbNav->fetchPage(); } // make filelist $files = \OCA\files\lib\Helper::getFiles($dir); $list = new OCP\Template("files", "part.list", ""); $list->assign('files', $files, false); $list->assign('baseURL', $baseUrl, false); $list->assign('downloadURL', OCP\Util::linkToRoute('download', array('file' => '/'))); $data['files'] = $list->fetchPage(); OCP\JSON::success(array('data' => $data));