Defect #10153
closedMissing "add new file" in Files section after upgrade from 1.0.0 to 1.3.0
0%
Description
After upgrading from redmine 1.0.0 to 1.3.0 (latest stable release) i don't have the "add new file" button in the Files section of my project though i have the proper permission (Manage Files), why ? How can i solve this issue ?
Ruby Version : ruby 1.8.7 (2010-06-23 patchlevel 299) [x86_64-linux]
Redmine Version : 1.3.0.stable
Files
Updated by Jean-Philippe Lang almost 13 years ago
- Priority changed from High to Normal
- Resolution set to Cant reproduce
Works ok for me on 1.3 stable.
Some changes were done in the files view, any plugins or custom code changes?
Updated by Alessio Pollero almost 13 years ago
- Assignee set to Jean-Philippe Lang
I have this plugins installed :
- Localizable plugin 0.1.1
- Redmine Gitrevision Download plugin 0.0.8
- Redmine Light Box plugin 0.0.1
- Issues XLS export 0.1.3
Updated by Jean-Philippe Lang almost 13 years ago
Make sure that none of these plugins override app/views/files/index.html.erb and that you don't have local changes.
Updated by Alessio Pollero almost 13 years ago
Here's the content of my app/views/files/index.html.erb :
<div class="contextual"> <%= link_to(l(:label_attachment_new), new_project_file_path(@project), :class => 'icon icon-add') if User.current.allowed_to?(:manage_files, @project) %> </div> <h2><%=l(:label_attachment_plural)%></h2> <% delete_allowed = User.current.allowed_to?(:manage_files, @project) %> <table class="list files"> <thead><tr> <%= sort_header_tag('filename', :caption => l(:field_filename)) %> <%= sort_header_tag('created_on', :caption => l(:label_date), :default_order => 'desc') %> <%= sort_header_tag('size', :caption => l(:field_filesize), :default_order => 'desc') %> <%= sort_header_tag('downloads', :caption => l(:label_downloads_abbr), :default_order => 'desc') %> <th>MD5</th> <th></th> </tr></thead> <tbody> <% @containers.each do |container| %> <% next if container.attachments.empty? -%> <% if container.is_a?(Version) -%> <tr> <th colspan="6" align="left"> <%= link_to(h(container), {:controller => 'versions', :action => 'show', :id => container}, :class => "icon icon-package") %> </th> </tr> <% end -%> <% container.attachments.each do |file| %> <tr class="file <%= cycle("odd", "even") %>"> <td class="filename"><%= link_to_attachment file, :download => true, :title => file.description %></td> <td class="created_on"><%= format_time(file.created_on) %></td> <td class="filesize"><%= number_to_human_size(file.filesize) %></td> <td class="downloads"><%= file.downloads %></td> <td class="digest"><%= file.digest %></td> <td align="center"> <%= link_to(image_tag('delete.png'), attachment_path(file), :confirm => l(:text_are_you_sure), :method => :delete) if delete_allowed %> </td> </tr> <% end reset_cycle %> <% end %> </tbody> </table> <% html_title(l(:label_attachment_plural)) -%>
Updated by Etienne Massip almost 13 years ago
Plugins usually override a page by having their own vendor/plugin/<plugin name>app/views/files/index.html.erb
(or .rhtml
).
A good test would be to remove temporarily these plugins (especially Redmine Light Box plugin 0.0.1), restart Redmine and try to reproduce the issue without any plugin.
Updated by Alessio Pollero almost 13 years ago
I don't have any plugin that override the files view, what could it be ?
/usr/share/redmine/vendor/plugins# find . -name index.html.erb ./engines/test/plugins/test_assets/app/views/assets/index.html.erb
Updated by Etienne Massip almost 13 years ago
Still, I advise you to make a test with no plugins.
Updated by Jean-Philippe Lang almost 13 years ago
- can you post the piece of HTML that is generated and where the link should be present
- what happens when you access the new file form manually with this url:
/projects/[project_id]/files/new
Updated by Alessio Pollero almost 13 years ago
- File page.html page.html added
- File ScreenShot.PNG ScreenShot.PNG added
If i go through direct URL link /projects/[project_id]/files/new i can upload files without any problem.
I even tried removing lightbox plugin but still the same problem .
I don't see the new File button, though it seems to be in the page source, could depends on the theme ?
Take a look at the screenshot in the attachment...
Updated by Jean-Philippe Lang almost 13 years ago
- Status changed from New to Closed
Yes, it's a theme issue. The link must be just below your h2 background. Try to add a z-index to .contextual in your css.
Updated by Alessio Pollero almost 13 years ago
Solved, it was a problem of the CSS, the element was set as hidden unreasonably :
.controller-files.action-index .contextual{ display:none; }
changed to :
.controller-files.action-index .contextual{ display:inline; }
Now it works.
Thanks.