From d10e137939d8f88d3dd742ec71c653628467c51d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Schie=C3=9Fle?= Date: Tue, 29 Jan 2013 10:03:04 +0100 Subject: [PATCH] icons added; empty trash bin message added --- apps/files/js/filelist.js | 2 +- apps/files_trashbin/index.php | 1 + apps/files_trashbin/js/trash.js | 2 +- apps/files_trashbin/lib/trash.php | 2 +- apps/files_trashbin/templates/index.php | 9 ++++----- core/img/actions/undelete.png | Bin 0 -> 680 bytes 6 files changed, 8 insertions(+), 8 deletions(-) create mode 100644 core/img/actions/undelete.png diff --git a/apps/files/js/filelist.js b/apps/files/js/filelist.js index 40d75aae93..5cb8849ffe 100644 --- a/apps/files/js/filelist.js +++ b/apps/files/js/filelist.js @@ -292,7 +292,7 @@ var FileList={ procesSelection(); } }); - }, + } }; $(document).ready(function(){ diff --git a/apps/files_trashbin/index.php b/apps/files_trashbin/index.php index 20f9cb8daf..2e978ae190 100644 --- a/apps/files_trashbin/index.php +++ b/apps/files_trashbin/index.php @@ -95,6 +95,7 @@ $list->assign('dirlisting', $dirlisting); $list->assign('disableDownloadActions', true); $tmpl->assign('breadcrumb', $breadcrumbNav->fetchPage(), false); $tmpl->assign('fileList', $list->fetchPage(), false); +$tmpl->assign('files', $files); $tmpl->assign('dir', OC_Filesystem::normalizePath($view->getAbsolutePath())); $tmpl->printPage(); diff --git a/apps/files_trashbin/js/trash.js b/apps/files_trashbin/js/trash.js index 92a431d495..553e4cbc6f 100644 --- a/apps/files_trashbin/js/trash.js +++ b/apps/files_trashbin/js/trash.js @@ -2,7 +2,7 @@ $(document).ready(function() { if (typeof FileActions !== 'undefined') { - FileActions.register('all', 'Undelete', OC.PERMISSION_READ, '', function(filename) { + FileActions.register('all', 'Undelete', OC.PERMISSION_READ, OC.imagePath('core', 'actions/undelete.png'), function(filename) { var tr=$('tr').filterAttr('data-file', filename); $.post(OC.filePath('files_trashbin','ajax','undelete.php'), {files:tr.attr('data-file'), dirlisting:tr.attr('data-dirlisting') }, diff --git a/apps/files_trashbin/lib/trash.php b/apps/files_trashbin/lib/trash.php index e81ba12758..fad96e5222 100644 --- a/apps/files_trashbin/lib/trash.php +++ b/apps/files_trashbin/lib/trash.php @@ -54,7 +54,7 @@ class Trashbin { self::copy_recursive($file_path, 'files_trashbin/'.$deleted.'.d'.$timestamp, $view); $query = \OC_DB::prepare("INSERT INTO *PREFIX*files_trash (id,timestamp,location,type,mime,user) VALUES (?,?,?,?,?,?)"); - $result = $query->execute(array($deleted, $timestamp, $location, $type, $mime, $user)); + $query->execute(array($deleted, $timestamp, $location, $type, $mime, $user)); if ( \OCP\App::isEnabled('files_versions') ) { if ( $view->is_dir('files_versions'.$file_path) ) { diff --git a/apps/files_trashbin/templates/index.php b/apps/files_trashbin/templates/index.php index a9cb216b1f..ebabec2d4d 100644 --- a/apps/files_trashbin/templates/index.php +++ b/apps/files_trashbin/templates/index.php @@ -5,8 +5,8 @@
- -
t('Nothing in here. Upload something!')?>
+ +
t('Nothing in here. Trash bin empty!')?>
@@ -17,9 +17,8 @@ t( 'Name' ); ?> - + Undelete" /> t('Undelete')?> diff --git a/core/img/actions/undelete.png b/core/img/actions/undelete.png new file mode 100644 index 0000000000000000000000000000000000000000..9f728252394f15555fe35e3ca049995a1c2d6117 GIT binary patch literal 680 zcmV;Z0$2TsP)Px#24YJ`L;(K){{a7>y{D4^000SaNLh0L01m_e01m_fl`9S#00007bV*G`2i*Z3 z2rD*9zB=mw000?uMObu0Z*6U5Zgc=ca%Ew3Wn>_CX>@2HM@dakSAh-}00065Nkl4dSG%CZndg-Aj!-AlP_7c^@Bq$|{f?k9u zjA}0i&6fp1e@L*l$Oa`niAk0*yht=H8FM7t+V1Tk*V?89c^-e?-#MJ$`JJzz>$=Vg zU|4RDno|kCe9h-?NzB!DT&-?4Se3GSLf%2h-^0x@D|fFPrmx4xKxho3Nk)a)Bp(-CXQ{%0fCvg~>=-GqR_BKTgM5W~as(3Ps3@CgkcS0>OJU zSi~isAV^dy63BLfgO6}p3ZqN&Q=B?}f;Z{}z6-Z_aQ!4A@Y{=~{gGvQn(p)0SkMYb z;+i^c_ zC6=6pJqKv2t>UZto}uTj$Vf6q>qY{>0F8@15K4C;mr%KU)<-Zh zfypEzi2_=_iEWEbG%wM_QY628Bs@IAOd^HZYR9$DjpJ{-@V^jQA$|hu6u!#TV1_XO O0000