diff --git a/lib/redmine_dmsf/webdav/base_resource.rb b/lib/redmine_dmsf/webdav/base_resource.rb
index c7fea5e6..7c4f0f2c 100644
--- a/lib/redmine_dmsf/webdav/base_resource.rb
+++ b/lib/redmine_dmsf/webdav/base_resource.rb
@@ -55,13 +55,39 @@ module RedmineDmsf
nil
end
+ # Overridden
+ def index_page
+ %{
+
+
+
+ %s
+
+
+
+ %s
+
+
+
+ | Name |
+ Size | Type |
+ Last Modified |
+
+ %s
+
+
+
+
+ }
+ end
+
# Generate HTML for Get requests, or Head requests if no_body is true
def html_display
@response.body = +''
- Confict unless collection?
- entities = children.map{|child|
+ Confict unless collection?
+ entities = children.map{ |child|
DIR_FILE % [
- "#{@options[:root_uri_path]}#{child.path}",
+ "#{@options[:root_uri_path]}#{URI.encode(child.path)}",
child.long_name || child.name,
child.collection? ? '' : number_to_human_size(child.content_length),
child.special_type || child.content_type,
@@ -69,7 +95,7 @@ module RedmineDmsf
]
} * "\n"
entities = DIR_FILE % [
- parent.public_path,
+ URI.encode(parent.public_path),
l(:parent_directory),
'',
'',