mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-14 02:37:08 -07:00
cache busting for js file based on server version.
This commit is contained in:
parent
5c3f0203e5
commit
0916c8b8d1
12 changed files with 205 additions and 126 deletions
18
UI/Handlebars/Helpers/DateTime.js
Normal file
18
UI/Handlebars/Helpers/DateTime.js
Normal file
|
@ -0,0 +1,18 @@
|
|||
"use strict";
|
||||
define(
|
||||
[
|
||||
'sugar'
|
||||
], {
|
||||
register: function (handlebars) {
|
||||
handlebars.registerHelper("ShortDate", function (input) {
|
||||
if (!input) {
|
||||
return '';
|
||||
}
|
||||
|
||||
var date = Date.create(input);
|
||||
var result = '<span title="' + date.full() + '">' + date.short() + '</span>';
|
||||
|
||||
return new handlebars.SafeString(result);
|
||||
});
|
||||
}
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue