PiRSquared17 / redmine-dmsf

Automatically exported from code.google.com/p/redmine-dmsf
0 stars 0 forks source link

undefined method `display_title' #197

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Happens randomly after a document is uploaded
2. After upload return to the DMSF tab
3. Get a 500 server error

What is the expected output? What do you see instead?
Should see the document/folder listings

What version of the DMSF and Redmine are you using? On what browser and
operating
system?

Redmine version 1.3.0 + postgres
DMSF version 1.2.2
Browser Firefox
O.S. Linux

Please provide any additional information below.

Stack from the logs.

ActionView::TemplateError (undefined method `display_title' for nil:NilClass) 
on line #107 of vendor/plugins/redmine_dmsf/app/views/dmsf/show.html.erb:
104:                    <td class="check"><%= check_box_tag("files[]", file.id, 
false, :title => l(:title_check_for_zip_download_or_email)) %></td>
105:                    <td class="title">
106:                            <% file_download_url = url_for({:only_path => 
false, :controller => :dmsf_files, :action => "show", :id => file, :download => 
""}) %>
107:                            <%= link_to(h(file.last_revision.display_title),
108:                                    file_download_url,
109:                                    :class => "icon icon-file 
#{DmsfHelper.filetype_css(file.name)}",
110:                                            :title => 
l(:title_title_version_version_download, :title => h(file.title), :version => 
file.version),

    vendor/plugins/redmine_dmsf/app/views/dmsf/show.html.erb:107
    vendor/plugins/redmine_dmsf/app/views/dmsf/show.html.erb:102:in `each'
    vendor/plugins/redmine_dmsf/app/views/dmsf/show.html.erb:102
    vendor/plugins/redmine_dmsf/app/views/dmsf/show.html.erb:27
    public/dispatch.fcgi:24

Original issue reported on code.google.com by rivera.d...@gmail.com on 15 Feb 2012 at 1:42

GoogleCodeExporter commented 9 years ago
I have tracked this one down.  It is another manifestation of issue 191.

Original comment by smip...@gmail.com on 26 Mar 2012 at 4:41

GoogleCodeExporter commented 9 years ago
If the erroneous file (the one with no versions) is located in a directory 
below the displayed level, issue 191 manifests itself.  If the erroneous file 
is located in the displayed directory, issue 197 manifests itself.

Original comment by smip...@gmail.com on 26 Mar 2012 at 4:43

GoogleCodeExporter commented 9 years ago
If this kills the use of DMSF for one of your projects, follow the workaround 
given with issue 191 (comment 7)

Original comment by smip...@gmail.com on 16 Apr 2012 at 1:28