Commit b67280f0 by Torkel Ödegaard

Merge pull request #476 from lyrixx/axis-s-week

Format seconds metric by week if needed
parents ce8bdaba b40af071
...@@ -521,6 +521,10 @@ function($, _, moment) { ...@@ -521,6 +521,10 @@ function($, _, moment) {
else if (size < 604800) { else if (size < 604800) {
return (size / 86400).toFixed(decimals) + " day"; return (size / 86400).toFixed(decimals) + " day";
} }
// Less than one year, devide in week
else if (size < 31536000) {
return (size / 604800).toFixed(decimals) + " week";
}
return (size / 3.15569e7).toFixed(decimals) + " year"; return (size / 3.15569e7).toFixed(decimals) + " year";
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment