[Fusionforge-commits] FusionForge branch 6.1 updated. v6.1beta1-48-g174f8b6

Franck Villaume nerville at libremir.placard.fr.eu.org
Thu Jan 4 14:24:58 CET 2018


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "FusionForge".

The branch, 6.1 has been updated
       via  174f8b6e0e4f2df4b9f5dd4808de92e90d62c226 (commit)
      from  0a901f21ee2d51bd45d15abaec0df0e85710b37e (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=174f8b6e0e4f2df4b9f5dd4808de92e90d62c226

commit 174f8b6e0e4f2df4b9f5dd4808de92e90d62c226
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date:   Thu Jan 4 13:24:53 2018 +0000

    docman search: fix URL filetype test. Use version not document itself

diff --git a/src/www/search/include/renderers/DocsHtmlSearchRenderer.class.php b/src/www/search/include/renderers/DocsHtmlSearchRenderer.class.php
index 993c69f..265484c 100644
--- a/src/www/search/include/renderers/DocsHtmlSearchRenderer.class.php
+++ b/src/www/search/include/renderers/DocsHtmlSearchRenderer.class.php
@@ -98,6 +98,7 @@ class DocsHtmlSearchRenderer extends HtmlGroupSearchRenderer {
 		}
 		foreach ($result as $row) {
 			$document = document_get_object($row['docid'], $row['group_id']);
+			$dv = documentversion_get_object($row['version'], $row['docid'], $row['group_id']);
 			$currentDocGroup = documentgroup_get_object($document->getDocGroupID(), $document->Group->getID());
 			//section changed
 			if ($lastDocGroupID != $currentDocGroup->getID()) {
@@ -121,8 +122,8 @@ class DocsHtmlSearchRenderer extends HtmlGroupSearchRenderer {
 					$cells[][] = html_e('input', array('type' => 'checkbox', 'value' => $document->Group->getID().'-'.$document->getID(), 'class' => 'checkeddocidactive', 'title' => _('Select / Deselect this document for massaction'), 'onClick' => 'controllerListFile.checkgeneral("active")'));
 				}
 			}
-			if ($document->isURL()) {
-				$cells[][] = util_make_link($document->getFileName(), html_image($document->getFileTypeImage(), 22, 22), array('title' => _('Visit this link')), true);
+			if ($dv->isURL()) {
+				$cells[][] = util_make_link($dv->getFileName(), html_image('docman/file_type_html.png', 22, 22), array('title' => _('Visit this link')), true);
 			} else {
 				$cells[][] = util_make_link('/docman/view.php/'.$document->Group->getID().'/versions/'.$document->getID().'/'.$row['version'], html_image($document->getFileTypeImage(), 22, 22), array('title' => _('View this document')));
 			}

-----------------------------------------------------------------------

Summary of changes:
 src/www/search/include/renderers/DocsHtmlSearchRenderer.class.php | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
FusionForge



More information about the Fusionforge-commits mailing list