diff options
Diffstat (limited to 'provisioning-listtemplates-html.lsp')
-rw-r--r-- | provisioning-listtemplates-html.lsp | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/provisioning-listtemplates-html.lsp b/provisioning-listtemplates-html.lsp index a649bec..579119d 100644 --- a/provisioning-listtemplates-html.lsp +++ b/provisioning-listtemplates-html.lsp @@ -3,20 +3,6 @@ htmlviewfunctions = require("htmlviewfunctions") html = require("acf.html") %> -<% -function convertsize(size) - if string.find(size, "k$") then - return tonumber(string.match(size, "[%d.]*")) * 1024.0 - elseif string.find(size, "M$") then - return tonumber(string.match(size, "[%d.]*")) * 1024.0 * 1024.0 - elseif string.find(size, "G$") then - return tonumber(string.match(size, "[%d.]*")) + 1024.0 * 1024.0 * 1024.0 - else - return tonumber(string.match(size, "[%d.]*")) - end -end -%> - <script type="text/javascript"> if (typeof jQuery == 'undefined') { document.write('<script type="text/javascript" src="<%= html.html_escape(page_info.wwwprefix) %>/js/jquery-latest.js"><\/script>'); @@ -69,7 +55,7 @@ end <td><%= html.html_escape(v.filename) %></td> <td><%= html.html_escape(v.label) %></td> <td><%= html.html_escape(v.seq) %></td> - <td><span class="hide"><%= convertsize(v.filesize) %>b</span><%= html.html_escape(v.filesize) %></td> + <td><span class="hide"><%= html.html_escape(v.orig_size) %>b</span><%= html.html_escape(v.size) %></td> <td><%= html.html_escape(v.mtime) %></td> </tr> <% end %> |