Redmine Preview Office
发布于: https://github.com/HugoHasenbein/redmine_preview_office 兼容于: Redmine 4.2.*, 4.1.*, 4.0.*, 3.4.*
最新版本: 1.0.3_2 更新日期: 2022-03-10 22:12
发布于: https://github.com/HugoHasenbein/redmine_preview_office 兼容于: Redmine 4.2.*, 4.1.*, 4.0.*, 3.4.*
最新版本: 1.0.3_2 更新日期: 2022-03-10 22:12
|
作者: | redmineplugins.cn Admin |
---|---|---|
主页: | https://github.com/HugoHasenbein/redmine_preview_office | |
版本库: | https://github.com/HugoHasenbein/redmine_preview_office | |
创建于: | 2021-07-27 | |
当前版本: | 1.0.3_2 | |
兼容性: | Redmine 4.2.*, 4.1.*, 4.0.*, 3.4.* |
在系统安装Libreoffice后,该插件可以使Redmine通过预览面板预览Office文档。支持的Office的文档格式包括:docx, xlsx, pptx, doc, xls, ppt, doc, rtf, odt.
※ 注意: lightbox2插件会影响redmine_office_preview插件工作,导致Office文档预览功能失效。
sudo apt-get install libxrender1 libsm6 libice6 fontconfig libcups2 libdbus-glib-1-2 libgl1-mesa-dev libcairo2-dev sudo apt-get install libreoffice-pdfimport
sudo apt-get install language-pack-zh* sudo apt-get install chinese*
积分(5)
兼容性: Redmine 3.4.*, 4.0.*, 4.1.*, 4.2.*
文件
redmine_preview_office-1.0.3_2.zip (609 KB)
积分(5)
兼容性: Redmine 3.4.*, 4.0.*, 4.1.*, 4.2.*
文件
redmine_preview_office-1.0.3_1.zip (607 KB)
评论
添加评论
#1
由 guo hongxing 在 6 个月 之前添加
下载界面出现的支付宝二维码,扫描二维码获得积分
#2
由 peng hechy 在 6 个月 之前添加
好东西,话说积分怎么获取?
#3
由 guo hongxing 在 8 个月 之前添加
如果时docker方式,要看你挂载的位置,例如/var/log/redmine/ 参考 https://redmineplugins.cn/issues/168#note-10
#4
由 moto jl 在 8 个月 之前添加
才接触redmine,不知道应该看哪个日志
#5
由 redmineplugins.cn Admin 在 8 个月 之前添加
@moto jl 之前的错误最好能贴上redmine的报错日志才能找到根本原因
#6
由 moto jl 在 8 个月 之前添加
换了一个版本的插件,结果还是一片空白,换edge浏览器居然能正常显示了,哎
#7
由 moto jl 在 8 个月 之前添加
请问怎么判断soffice文件访问路径可达呢?
#8
由 guo hongxing 在 8 个月 之前添加
@moto jl docker安装方式要确保temp/tmp文件夹可写以及soffice文件访问路径可达,具体问题只能从redmine的日志里的报错内容判断
#9
由 moto jl 在 8 个月 之前添加
我也遇到一样的问题,docker装的,插件放进去后重启docker,然后启不来了,删除插件就能正常启动
#10
由 Chen Snowman 在 8 个月 之前添加
@chen ming 需要查看redmine的日志才能判定具体问题
#11
由 chen ming 在 8 个月 之前添加
用docker装的redmine,装完这插件后起不来是什么情况?
#12
由 Chen Snowman 在 9 个月 之前添加
你好, @Huang James
是安装redmine还是安装Preview Office插件? 或者贴日志到 https://redmineplugins.cn/projects/redmineplugins/issues/new
#13
由 Huang James 在 9 个月 之前添加
安裝完redmine顯示502 bad gateway
#14
由 redmineplugins.cn Admin 在 10 个月 之前添加
@chen chun 给你发了一个补丁文件,你再试试看
#15
由 chen chun 在 10 个月 之前添加
环境变量设置好了,能识别命令了。
C:\Program Files\LibreOffice\program
手动输入如下命令也能生成PDF。
soffice --convert-to pdf D:\Bitnami\redmine-4.1.1-8\apps\redmine\htdocs\files\2021\07\210727185044_aaa.docx --outdir D:\Bitnami\redmine-4.1.1-8\apps\redmine\htdocs\files\2021\07
预览的时候提示bootstrap.ini文件损坏,这应该不是真正原因。
控制台现在报找不到文件。没有具体指明哪个文件。
日志如下:
[2021-07-28 09:59:54 +0800] [ERROR] – Creating preview with libreoffice failed (pid 41460 exit 1):
Command: cd C:/Users/chenchun/AppData/Local/Temp/d20210728-35044-1cug5o8 & “soffice”
env:UserInstallation=file:///tmp/ --convert-to pdf “D:/Bitnami/redmine-4.1.1-8/apps/redmine/htdocs/files/2021/07/210727185044_aaa.docx” & move “210727185044_aaa.pdf” “D:/Bitnami/redmine-4.1.1-8/apps/redmine/htdocs/tmp/thumbnails/1300_7e242d00e712558b034b948bd83e7358c111374d5b5ada3c859fedfc1de23e85.pdf”Completed 404 Not Found in 7027ms (ActiveRecord: 41.6ms)[2021-07-28 09:59:54 +0800] [INFO] -
好像和#25类似,但是说补丁不适用windows。
#16
由 redmineplugins.cn Admin 在 10 个月 之前添加
@chen chun 先确定手动执行soffice转换是否可行,或者手动执行时报什么错误。
另外,环境变量的设置方法:

#17
由 chen chun 在 10 个月 之前添加
window环境,下载了1.0.3_2这个版本。但是还是不能表示,起的调试环境。
控制台报的错是:不能识别soffice命令,要加什么环境变量吗?已经装了libreoffice。
日志如下;
[2021-07-27 20:23:34 +0800] [ERROR] – Creating preview with libreoffice failed (pid 34400 exit 1):
Command: cd C:/Users/chenchun/AppData/Local/Temp/d20210727-32616-tlb6ji & “soffice”
env:UserInstallation=file:///tmp/ --convert-to pdf “D:/Bitnami/redmine-4.1.1-8/apps/redmine/htdocs/files/2021/07/210727185044_aaa.docx” & move “210727185044_aaa.pdf” “D:/Bitnami/redmine-4.1.1-8/apps/redmine/htdocs/tmp/thumbnails/1300_7e242d00e712558b034b948bd83e7358c111374d5b5ada3c859fedfc1de23e85.pdf”Completed 404 Not Found in 71ms (ActiveRecord: 34.9ms)[2021-07-27 20:23:34 +0800] [INFO] -
#18
由 马 海军 在 11 个月 之前添加
报告问题:
使用nginx作为代理服务器,Apache运行Passenger的情况下,预览界面会出现127.0.0.1 拒绝了我们的连接请求。
#19
由 redmineplugins.cn Admin 在 大约一年 之前添加
@Zh yowfung 重新修订下,更新到下载区了
#20
由 Zh yowfung 在 大约一年 之前添加
关于不能预览的问题,应该是出在插件的这行代码里的:
文件:{redmine}/plugins/redmine_preview_office/lib/redmine_preview_office/patches/application_helper_patch.rb
第39行弄出来的 URL 是没问题的,是 192.168.1.145。
:href ⇒ preview_office_path(attachment)
而第60行弄出来的确是 127.0.0.1。
:src ⇒ preview_office_url(attachment)
选用 with <object><embed>-tag 是一定不能预览(显示空白界面),选用 with <iframe>-tag 是可以显示预览的(但是网址变成了 127.0.0.1,手动改了后就可以预览了,但是刷新页面后就无效了)。
希望插件作者能够根据以上反馈的信息升级插件,谢谢!
#21
由 Zh yowfung 在 大约一年 之前添加
上面的问题,附上日志:
Started GET "/attachments/thumbnail/583” for 172.21.0.1 at 2021-05-15 12:53:18 +0800
Processing by AttachmentsController#thumbnail as HTML
Parameters: {“id"⇒“583”}
Current user: zhanghuifeng (id=144)
Creating thumbnail failed (pid 4080 exit 1):
Command: 'convert’ '/usr/local/redmine/files/2021/05/210514161350_30a5608004a5f94958e6b1a25f9c3256.pdf0' -thumbnail '100x100>' 'png:/usr/local/redmine/tmp/thumbnails/2d2a7895e1a69620f32c412a5d79987f5ac7b8971aa51d1e4194bcca9cdcf046_352014_100.thumb’
Completed 404 Not Found in 96ms (ActiveRecord: 55.0ms)
Started GET "/attachments/584” for 172.21.0.1 at 2021-05-15 12:53:25 +0800
Processing by AttachmentsController#show as HTML
Parameters: {“id"⇒“584”}
Current user: zhanghuifeng (id=144)
Rendering plugins/redmine_preview_office/app/views/attachments/office.html.erb within layouts/base
Rendered layouts/_file.html.erb (23.5ms)
Rendered plugins/redmine_preview_office/app/views/attachments/office.html.erb within layouts/base (31.3ms)
Rendered plugins/clipboard_image_paste/app/views/clipboard_image_paste/_headers.html.erb (0.5ms)
Rendered plugins/redmine_favorite_projects/app/views/favorite_projects/_additional_assets.html.erb (0.3ms)
Rendered plugins/clipboard_image_paste/app/views/clipboard_image_paste/_add_form.html.erb (1.2ms)
Rendered plugins/redmine_favorite_projects/app/views/favorite_projects/_select2_transformation_rules.html.erb (0.1ms)
Completed 200 OK in 156ms (Views: 61.1ms | ActiveRecord: 76.9ms)
#22
由 Zh yowfung 在 大约一年 之前添加
插件可以正常安装,在非本地机器上访问 redmine 系统时打开的预览画面是一片空白,中间显示“127.0.0.1 已拒绝连接”。浏览器按 F12,切到 “Network”一栏,看到它请求的是这个地址“Request URL: http://127.0.0.1:3000/attachments/preview_office/584”,HTTP 响应代码584。问题应该很清晰了,这个插件里面应该是访问了 127.0.0.1 这个地址,但由于我的 redmine 网站是搭建在 192.168.1.145 这台服务器上,在其他电脑上不应该访问 127.0.0.1 而应该是访问 192.168.1.145。
#23
由 redmineplugins.cn Admin 在 大约一年 之前添加
@cao rocky 试下 https://redmineplugins.cn/issues/165 附件的补丁
#24
由 cao rocky 在 大约一年 之前添加
bitnami/redmine debian 10
Redmine 4.2.0.stable v
默认的管理员帐号已改变 v
附件路径可写 v
插件的附件路径可写 (./public/plugin_assets) v
MiniMagick 可用(可选的) v
可使用 ImageMagick 转换图片格式 (可选) v
ImageMagick PDF 支持 (可选) v
Libre Office available X 红
Pandoc available v
***********************************************log。tmp目录没有文件夹
Processing by AttachmentsController#more_preview as HTML
Parameters: {“drive_entry"⇒“true”, “id"⇒“10”}
Current user: user (id=1)
Creating preview with Libre failed (pid 2732 exit 1):
Command: cd '/tmp/d20210424-1817-1b627b8’; soffice --headless --convert-to html --outdir '/tmp/d20210424-1817-1b627b8’ -env:UserInstallation=file:///tmp/d20210424-1817-1a7i6rh/user_installation '/opt/bitnami/apps/redmine/htdocs/files/2021/04/210423065312_bab8f361e2340d0bd8a2a522234ea302.xlsx’; mv './210423065312_bab8f361e2340d0bd8a2a522234ea302.html’ '/tmp/d20210424-1817-1b627b8/index.html’
An error occured while generating preview for /opt/bitnami/apps/redmine/htdocs/files/2021/04/210423065312_bab8f361e2340d0bd8a2a522234ea302.xlsx
Exception was: ConverterShellError
***********************************
手动运行命令成功,在tmp目录可以找到。
soffice --headless --convert-to html --outdir '/tmp/d20210424-1817-1b627b8’ -env:UserInstallation=file:///tmp/d20210424-1817-1a7i6rh/user_installation '/opt/bitnami/apps/redmine/htdocs/files/2021/04/210423065312_bab8f361e2340d0bd8a2a522234ea302.xlsx’
#25
由 xu renfeng 在 大约一年 之前添加
报错查看log如下:
Installing ruby-filemagic 0.7.2 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/usr/local/bin/$(RUBY_BASE_NAME)
--with-magic-dir
--without-magic-dir
--with-magic-include
--without-magic-include=${magic-dir}/include
--with-magic-lib
--without-magic-lib=${magic-dir}/lib
--with-gnurx-dir
--without-gnurx-dir
--with-gnurx-include
--without-gnurx-include=${gnurx-dir}/include
--with-gnurx-lib
--without-gnurx-lib=${gnurx-dir}/lib
--with-gnurxlib
--without-gnurxlib
/usr/local/lib/ruby/2.6.0/mkmf.rb:467:in `try_do': The compiler failed to
generate an executable file. (RuntimeError)
You have to install development tools first.
from /usr/local/lib/ruby/2.6.0/mkmf.rb:552:in `try_link0'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:570:in `try_link'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:789:in `try_func'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:1016:in `block in have_library'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:959:in `block in checking_for'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:361:in `block (2 levels) in postpone'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:331:in `open'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:361:in `block in postpone'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:331:in `open'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:357:in `postpone'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:958:in `checking_for'
from /usr/local/lib/ruby/2.6.0/mkmf.rb:1011:in `have_library'
from extconf.rb:21:in `<main>'
To see why this extension failed to compile, please check the mkmf.log which can
be found here:
extconf failed, exit code 1
Gem files will remain installed in /usr/local/bundle/gems/ruby-filemagic-0.7.2
for inspection.
Results logged to
/usr/local/bundle/extensions/x86_64-linux/2.6.0/ruby-filemagic-0.7.2/gem_make.out
An error occurred while installing ruby-filemagic (0.7.2), and Bundler
cannot continue.
Make sure that `gem install ruby-filemagic -v '0.7.2' --source
'https://rubygems.org/'` succeeds before bundling.
In Gemfile:
ruby-filemagic
仔细核对了我的报错log和“https://redmineplugins.cn/issues/21”中的报错信息,我发现好像是ruby-filemagic的路径不对,如我的报错信息中提到的“/usr/local/bundle/gems/ruby-filemagic-0.7.2”实际上并没有这个路径,ruby-filemagic-0.7.2安装在“/var/lib/gems/2.3.0/gems/ruby-filemagic-0.7.2”中,但是我还是不知道这个要怎么解决。
#26
由 xu renfeng 在 大约一年 之前添加
@guo hongxing 没有用,还是报一样的错,
Installing ruby-filemagic 0.7.2 with native extensions
Gem::Ext::BulidError:ERROR: Failed to build gem native extension
#27
由 guo hongxing 在 大约一年 之前添加
@xu renfeng 参考下这个 https://redmineplugins.cn/issues/21
#28
由 xu renfeng 在 大约一年 之前添加
仔细核对了一遍,发现不能正常显示应该是因为没有安装redmine_preview_pdf这个插件导致的,但是我在安装这个插件时又出现了如下错误。
Installing ruby-filemagic 0.7.2 with native extensions
Gem::Ext::BulidError:ERROR: Failed to build gem native extension
#29
由 redmineplugins.cn Admin 在 大约一年 之前添加
@xu renfeng 用我新上传的补丁再试试看,见补丁
#30
由 redmineplugins.cn Admin 在 大约一年 之前添加
@xu renfeng 使用同样的版本又在4.1.1.stable.19939上测试正常 #165
#31
由 xu renfeng 在 大约一年 之前添加
试过了,还是没有用,报错信息也和之前一样
#32
由 redmineplugins.cn Admin 在 大约一年 之前添加
@xu renfeng 404问题参考 https://redmineplugins.cn/issues/25#note-6
#33
由 xu renfeng 在 大约一年 之前添加
查看log如下:
...
mv: cannot stat '210401082014_8c6ed9537f77f2c22989af8891097dcb.pdf’: No such file or directory
E, [2021-04-01T08:29:32.487992 #1] ERROR – : Creating preview with libreoffice failed (pid 104 exit 1):
Command: cd /tmp/d20210401-1-1env0tp; 'soffice’ --convert-to pdf '/usr/src/redmine/files/2021/04/210401082014_8c6ed9537f77f2c22989af8891097dcb.docx’; mv '210401082014_8c6ed9537f77f2c22989af8891097dcb.pdf’ '/usr/src/redmine/tmp/thumbnails/2_f5fa3b1b7dd6beabc62cecf14c3822414355b1c4b341566635cb83daf45e9cf9.pdf’
I, [2021-04-01T08:29:32.491595 #1] INFO – : Completed 404 Not Found in 20ms (ActiveRecord: 4.9ms)
192.168.2.5 - - [01/Apr/2021:08:29:32 UTC] “HEAD /attachments/preview_office/2 HTTP/1.1” 404 0
- → /attachments/preview_office/2
#34
由 xu renfeng 在 大约一年 之前添加
插件安装正常,没有报错,文档也能正常打开,不报错,但是文档打开后没有显示内容。
“信息”页面下没有正常显示安装步骤中提到的两个组件,只显示了一个,并且右侧显示不是绿色的对勾,而是红色的感叹号
Libre Office available (needed for plugin 'Redmine Preview Office’)
#35
由 redmineplugins.cn Admin 在 超过一年 之前添加
@苏盼 试试这个方法 https://redmineplugins.cn/issues/16
#36
由 苏 盼 在 超过一年 之前添加
LibreOffice_6.4.7_Linux_x86-64_rpm_langpack_zh-CN.tar.gz
LibreOffice_6.4.7_Linux_x86-64_rpm.tar.gz
安装完LibOffice后,能打开编辑中文,但是该插件还是乱码?
#37
由 liu wayne 在 超过一年 之前添加
需要安装:
apt-get install unoconv
apt-get install ttf-wqy-microhei
#38
由 liu wayne 在 超过一年 之前添加
插件有问题,redmine docker方式安装,按照安装方式,成功安装
chrome浏览器看docx文件是空白。
#39
由 redmineplugins.cn Admin 在 超过一年 之前添加
@z16536 如果是linux系统,按照 https://www.redmineplugins.cn/issues/25#note-7 outman的方法去解决。
#40
由 zl6536 zl6536 在 超过一年 之前添加
IE11報錯HTTP 4.0
chrome空白什麼都不顯示
#41
由 redmineplugins.cn Admin 在 将近 2 年 之前添加
看下问题跟踪 里有没有你的遇到的问题,或者把你的错误日志贴出来
#42
由 匿名用户 在 将近 2 年 之前添加
我这边安装好插件以后出现不能预览。初步想到可能是插件冲突,当删除其他插件以后,还是不能预览,出现不能打开pdf文档的提示
#43
由 普 兰店 在 将近 2 年 之前添加
谷歌浏览器导致,最新版本(83.0.4103.97 )不支持, 75.0.3770.142版本支持
火狐浏览器可以。
#44
由 redmineplugins.cn Admin 在 将近 2 年 之前添加
还是需要日志,否则没法定位问题
#45
由 普 兰店 在 将近 2 年 之前添加
开发机器未配置apache2,服务器配置了apache2。预览的时候,均发现本机(127.0.0.1)没有问题。换到其他机器就不行了。
未配置apache2的,按照之前评论 尝试使用:rails s -e production -p 8080 -b 0.0.0.0
也未生效,请问该如何配置?
#46
由 惑惑 小 在 将近 2 年 之前添加
export DISPLAY=:0.0
[18:16:22][root@mail ~]# 'soffice’ --convert-to pdf '/usr/local/redmine-4.0.5/files/2020/05/200527085921_95ef2d0f7566ff6a4378c95b5f104a3a.docx’
[18:16:27]convert /usr/local/redmine-4.0.5/files/2020/05/200527085921_95ef2d0f7566ff6a4378c95b5f104a3a.docx → /root/200527085921_95ef2d0f7566ff6a4378c95b5f104a3a.pdf using writer_pdf_Export
#47
由 惑惑 小 在 将近 2 年 之前添加
[root@mail local]# 'soffice’ --convert-to pdf '/usr/local/redmine-4.0.5/files/2020/05/200527085921_95ef2d0f7566ff6a4378c95b5f104a3a.docx’
Failed to open display
/usr/lib64/libreoffice/program/soffice.bin X11 error: Can’t open display:
Set DISPLAY environment variable, use -display option
or check permissions of your X-Server
(See “man X” resp. “man xhost” for details)
#48
由 惑惑 小 在 将近 2 年 之前添加
Completed 200 OK in 272ms (Views: 119.0ms | ActiveRecord: 57.3ms)
Started GET "/attachments/139” for 172.1.243.25 at 2020-06-03 16:50:20 +0800
Processing by AttachmentsController#show as HTML
Parameters: {“id"⇒“139”}
Current user: admin (id=1)
Rendering plugins/redmine_preview_office/app/views/attachments/office.html.erb within layouts/base
Rendered layouts/_file.html.erb (12.8ms)
Rendered plugins/redmine_preview_office/app/views/attachments/office.html.erb within layouts/base (14.8ms)
Completed 200 OK in 54ms (Views: 27.9ms | ActiveRecord: 16.6ms)
Started GET "/attachments/preview_office/139” for 172.1.243.25 at 2020-06-03 16:50:20 +0800
Processing by AttachmentsController#preview_office as */*
Parameters: {“id"⇒“139”}
Current user: admin (id=1)
Creating preview with libreoffice failed (pid 8765 exit 1):
Command: cd /tmp/d20200603-8740-jpmq1q; 'soffice’ -env:UserInstallation=file:///tmp/ --convert-to pdf '/usr/local/redmine-4.0.5/files/2020/05/2
00527085921_95ef2d0f7566ff6a4378c95b5f104a3a.docx’; mv '200527085921_95ef2d0f7566ff6a4378c95b5f104a3a.pdf’ '/usr/local/redmine-4.0.5/tmp/thumbna
ils/139_eb24b1edc78cd07415f91b6e9ee96761a092862a8cc3fc037f103970c839c2af.pdf’
cmd is → cd /tmp/d20200603-8740-jpmq1q; 'soffice’ -env:UserInstallation=file:///tmp/ --convert-to pdf '/usr/local/redmine-4.0.5/files/2020/05/
200527085921_95ef2d0f7566ff6a4378c95b5f104a3a.docx’; mv '200527085921_95ef2d0f7566ff6a4378c95b5f104a3a.pdf’ '/usr/local/redmine-4.0.5/tmp/thumbn
ails/139_eb24b1edc78cd07415f91b6e9ee96761a092862a8cc3fc037f103970c839c2af.pdf’
tmpdir is → /tmp/d20200603-8740-jpmq1q
Completed 404 Not Found in 329ms (ActiveRecord: 2.6ms)
已经在/usr/local/redmine-4.0.5/plugins/redmine_preview_office/lib/redmine_preview_office/patches中替换了thumbnail_patch.rb
默认的管理员帐号已改变
附件路径可写
插件的附件路径可写 (./public/plugin_assets)
RMagick 可用(可选的)
可使用 ImageMagick 转换图片格式 (可选)
Libre Office available (needed for plugin 'Redmine Preview Office’)
Ghostscript available (needed for plugin 'Redmine Preview PDF’)
Environment:
Redmine version 4.0.5.stable
Ruby version 2.5.7-p206 (2019-10-01) [x86_64-linux]
Rails version 5.2.3
Environment production
Database adapter Mysql2
Mailer queue ActiveJob::QueueAdapters::AsyncAdapter
Mailer delivery smtp
SCM:
Filesystem
Redmine plugins:
redmine_preview_office 1.0.3
redmine_preview_pdf 1.0.4
#49
由 redmineplugins.cn Admin 在 大约 2 年 之前添加
不支持windows,如果用这个插件,建议迁到linux下
#50
由 zh zh 在 大约 2 年 之前添加
win server 2012,打开预览是白色的没有生效
日志
Current user: admin (id=1)
Rendered layouts/_file.html.erb (0.0ms)
Rendered plugins/redmine_preview_office/app/views/attachments/office.html.erb within layouts/base (31.3ms)
Rendered plugins/quick_view/app/views/hooks/_quick_view_base_head.html.erb (0.0ms)
Rendered plugins/redmine_code_review/app/views/code_review/_html_header.html.erb (0.0ms)
Rendered plugins/quick_view/app/views/hooks/_quick_view_base_bottom_tooltip.html.erb (0.0ms)
Rendered plugins/quick_view/app/views/hooks/_quick_view_base_bottom.html.erb (0.0ms)
Rendered plugins/quick_view/app/views/hooks/_quick_view_base_bottom_worktime_ext.html.erb (0.0ms)
Rendered plugins/redmine_code_review/app/views/code_review/_body_bottom.html.erb (0.0ms)
Completed 200 OK in 188ms (Views: 50.1ms | ActiveRecord: 125.3ms)
Started GET "/redmine/attachments/preview_office/3454” for 127.0.0.1 at 2020-04-28 11:44:23 +0800
Processing by AttachmentsController#preview_office as HTML
Parameters: {“id"⇒“3454”}
Current user: admin (id=1)
Couldn’t find template for digesting: attachments/preview_office
Completed 304 Not Modified in 47ms (ActiveRecord: 15.7ms)
#51
由 redmineplugins.cn Admin 在 大约 2 年 之前添加
你的404问题看这里 centos7 redmine 4.0.4 生成不了pdf #25
#52
由 bai fuwa 在 大约 2 年 之前添加
添加了插件,apache提供服务,预览时提示404。直接用调试命令,没有问题,是apache需要修改配置吗?
#53
由 redmineplugins.cn Admin 在 大约 2 年 之前添加
请用问题跟踪里的补丁文件替换掉插件pathces目录下的对应文件,重启动redmine在试试看
#54
由 redmineplugins.cn Admin 在 大约 2 年 之前添加
嗯,你用的应该是bitnami的集成安装包. 是权限的问题,
#55
由 匿名用户 在 大约 2 年 之前添加
centos7 redmine 4.0.4 生成不了pdf,日志:
Completed 200 OK in 203ms (Views: 168.3ms | ActiveRecord: 14.7ms)
Started GET "/redmine/attachments/preview_office/26” for 192.168.1.101 at 2020-03-27 19:24:57 +0800
Processing by AttachmentsController#preview_office as HTML
Parameters: {“id"⇒“26”}
Current user: david (id=6)
Creating preview with libreoffice failed (pid 11367 exit 1):
Command: cd /tmp/d20200327-11310-1grlqs5; 'soffice’ --convert-to pdf '/opt/redmine.org.cn/apps/redmine/htdocs/files/2020/03/200327180819_test333.xlsx’; mv '200327180819_test333.pdf’ '/opt/redmine.org.cn/apps/redmine/htdocs/tmp/thumbnails/26_0d412b4d2031731b2d3fec5be178f4a7ad0bb4c5a1c2e94b4251fde9d2bb2135.pdf’
Completed 404 Not Found in 530ms (ActiveRecord: 4.3ms)
/tmp/d20200327-11310-1grlqs5 不存在,
手动运行命令:'soffice’ --convert-to pdf '/opt/redmine.org.cn/apps/redmine/htdocs/files/2020/03/200327180819_test333.xlsx’ 能生成pdf
#56
由 匿名用户 在 大约 2 年 之前添加
注意!Redmine Knowledgebase 插件会破坏Redmine Preview Office的pdf文件预览功能
#57
由 redmineplugins.cn Admin 在 大约 2 年 之前添加
导致不能预览的原因有很多,最好能在预览不成功的同时抓下最新的日志,把对应的错误日志贴上来方便故障定位
#58
由 匿名用户 在 大约 2 年 之前添加
Redmine 4.0.4.stable
安装完成后不能显示预览
以下在安装后的信息
--------------------------------------
默认的管理员帐号已改变
附件路径可写
插件的附件路径可写 (./public/plugin_assets)
RMagick 可用(可选的)
可使用 ImageMagick 转换图片格式 (可选)
Libre Office available (needed for plugin 'Redmine Preview Office’)
Environment:
Redmine version 4.0.4.stable
Ruby version 2.5.5-p157 (2019-03-15) [x86_64-linux]
Rails version 5.2.3
Environment production
Database adapter Mysql2
Mailer queue ActiveJob::QueueAdapters::AsyncAdapter
Mailer delivery smtp
SCM:
Git 2.19.1
Filesystem
Redmine plugins:
easy_gantt 1.12
redmine_preview_office 1.0.3
redmine_wktime 3.9
#59
由 redmineplugins.cn Admin 在 大约 2 年 之前添加
注册用户后留言,方便联系
#60
由 匿名用户 在 大约 2 年 之前添加
看你的Redmine的安装方式啦,确认绑定到任意地址。例如 rails s -e production -p 8080 -b 0.0.0.0
#61
由 匿名用户 在 大约 2 年 之前添加
没有配置apache2。预览的时候,发现本机(127.0.0.1)没有问题。换到其他机器就不行了,看到下面访问的地址还是127.0.0.1。
#62
由 redmineplugins.cn Admin 在 大约 2 年 之前添加
尝试安装下下面的依赖呢?
#63
由 匿名用户 在 大约 2 年 之前添加
先到Redmine的设置界面: 管理 → 信息 ,查看 Libreoffice 是否有效
#64
由 匿名用户 在 大约 2 年 之前添加
ceontos 7 redmine 4.05 no work