kopia lustrzana https://github.com/miklobit/TiddlyWiki5
Fix view format=date so that it doesn't crash on empty fields
rodzic
02d3620d93
commit
c7d5905242
|
@ -148,7 +148,12 @@ ViewWidget.prototype.getValueAsDoubleUrlEncoded = function() {
|
|||
};
|
||||
|
||||
ViewWidget.prototype.getValueAsDate = function(format) {
|
||||
return $tw.utils.formatDateString(this.getValue(),format);
|
||||
var value = this.getValue();
|
||||
if(value) {
|
||||
return $tw.utils.formatDateString(value,format);
|
||||
} else {
|
||||
return "";
|
||||
}
|
||||
};
|
||||
|
||||
ViewWidget.prototype.getValueAsRelativeDate = function(format) {
|
||||
|
|
Ładowanie…
Reference in New Issue