Corrige problema para visualizar miniaturas de archivos PDF
Se aplica parche previsto para la versión 4.1.2 de Redmine, por lo que no se documentan los archivos modificados. Resuelve #500
This commit is contained in:
parent
1d7bec0ca3
commit
8b19a0fac0
3 changed files with 15 additions and 8 deletions
15
README.md
15
README.md
|
@ -34,37 +34,38 @@ License v2* (GPL).
|
|||
|
||||
### Redmine Additionals plugin
|
||||
|
||||
* additionals 2.0.20
|
||||
* additionals 3.0.0
|
||||
* https://alphanodes.com/redmine-additionals
|
||||
* https://github.com/alphanodes/additionals.git
|
||||
|
||||
### Redmine Checklists plugin (Light version)
|
||||
|
||||
* checklists 3.1.10
|
||||
* checklists 3.1.18
|
||||
* https://www.redmine.org/plugins/redmine_checklists
|
||||
* https://www.redmineup.com/pages/plugins/checklists
|
||||
|
||||
### Redmine CKEditor plugin
|
||||
|
||||
* ckeditor 1.1.5
|
||||
* ckeditor 1.2.3
|
||||
* https://www.redmine.org/plugins/redmine-ckeditor
|
||||
* http://github.com/a-ono/redmine_ckeditor
|
||||
|
||||
### Redmine Glossary Plugin
|
||||
|
||||
* glossary 0.9.2
|
||||
* glossary 1.1.0
|
||||
* https://www.r-labs.org/projects/rp-glossary/wiki/UsageEn
|
||||
* https://github.com/torutk/redmine_glossary
|
||||
|
||||
### Redmine Private Wiki Plugin
|
||||
|
||||
* private_wiki 0.2.0
|
||||
* private_wiki 0.2.0 (mistraloz)
|
||||
* http://www.redmine.org/plugins/redmine_private_wiki
|
||||
* https://github.com/BlueXML/redmine_private_wiki
|
||||
* https://github.com/mistraloz/redmine_private_wiki (*fork* con ajustes para
|
||||
Redmine >= 4.0.3)
|
||||
|
||||
### Redmine Q&A plugin
|
||||
|
||||
* questions 1.0.0
|
||||
* questions 1.0.2
|
||||
* https://www.redmine.org/plugins/redmine_questions
|
||||
* http://www.redminecrm.com/projects/questions
|
||||
|
||||
|
|
|
@ -179,6 +179,10 @@ default:
|
|||
# the ImageMagick's `convert` binary. Used to generate attachment thumbnails.
|
||||
#imagemagick_convert_command:
|
||||
|
||||
# Absolute path (e.g. /usr/bin/gs, c:/ghostscript/gs.exe) to
|
||||
# the `gs` binary. Used to generate attachment thumbnails of PDF files.
|
||||
#gs_command:
|
||||
|
||||
# Configuration of MiniMagick font.
|
||||
#
|
||||
# Redmine uses MiniMagick in order to export a gantt chart to a PNG image.
|
||||
|
|
|
@ -25,6 +25,7 @@ module Redmine
|
|||
extend Redmine::Utils::Shell
|
||||
|
||||
CONVERT_BIN = (Redmine::Configuration['imagemagick_convert_command'] || 'convert').freeze
|
||||
GS_BIN = (Redmine::Configuration['gs_command'] || 'gs').freeze
|
||||
ALLOWED_TYPES = %w(image/bmp image/gif image/jpeg image/png application/pdf)
|
||||
|
||||
# Generates a thumbnail for the source image to target
|
||||
|
@ -79,12 +80,13 @@ module Redmine
|
|||
@gs_available = false
|
||||
else
|
||||
begin
|
||||
`gs -version`
|
||||
`#{shell_quote GS_BIN} -version`
|
||||
@gs_available = $?.success?
|
||||
rescue
|
||||
@gs_available = false
|
||||
end
|
||||
end
|
||||
logger.warn("gs binary (#{GS_BIN}) not available") unless @gs_available
|
||||
@gs_available
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue