[TASK] Show "Edit Metadata of this file" icon in filelist search results 78/52278/2
authorGianluigi Martino <gmartino27@gmail.com>
Fri, 31 Mar 2017 06:57:00 +0000 (08:57 +0200)
committerFrans Saris <franssaris@gmail.com>
Fri, 31 Mar 2017 20:27:20 +0000 (22:27 +0200)
Releases: master
Resolves: #80591
Change-Id: I0a661f61f5e9bf6572903ff1de81095f95eb0b6a
Reviewed-on: https://review.typo3.org/52278
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Daniel Goerz <ervaude@gmail.com>
Tested-by: Daniel Goerz <ervaude@gmail.com>
Reviewed-by: Frans Saris <franssaris@gmail.com>
Tested-by: Frans Saris <franssaris@gmail.com>
typo3/sysext/filelist/Resources/Private/Templates/FileList/Search.html

index 4b7052d..fdac312 100644 (file)
                                                                        </f:else>
                                                                </f:if>
 
+                                                               <f:if condition="{file.IsMetadataEditable}">
+                                                                       <f:then>
+                                                                               <a href="#" class="btn btn-default filelist-file-edit"
+                                                                                  title="{f:translate( key:'LLL:EXT:lang/Resources/Private/Language/locallang_core.xlf:cm.editMetadata' )}"
+                                                                                  data-url="{fl:uri.editSysFileMetadataRecord(uid:file.metadataUid, returnUrl:'{f:uri.action( action:\'search\', arguments:{ searchWord:\'{searchWord->f:format.htmlentities()}\' } ) -> f:format.raw()}' )}"
+                                                                               >
+                                                                                       <core:icon identifier="actions-open" />
+                                                                               </a>
+                                                                       </f:then>
+                                                                       <f:else>
+                                                                               <span class="btn btn-default disabled"><core:icon identifier="empty-empty" /></span>
+                                                                       </f:else>
+                                                               </f:if>
+
                                                                <f:if condition="{file.publicUrl}">
                                                                        <f:then>
                                                                                <a href="#" class="btn btn-default filelist-file-view"