Merge pull request #694 from Alain-es/datepicker-custom-format
Datepicker custom format
This commit is contained in:
@@ -23,9 +23,6 @@ namespace Umbraco.Web.PropertyEditors
|
||||
|
||||
private IDictionary<string, object> _defaultPreVals;
|
||||
|
||||
/// <summary>
|
||||
/// Overridden because we ONLY support Date (no time) format and we don't have pre-values in the db.
|
||||
/// </summary>
|
||||
public override IDictionary<string, object> DefaultPreValues
|
||||
{
|
||||
get { return _defaultPreVals; }
|
||||
@@ -60,5 +57,16 @@ namespace Umbraco.Web.PropertyEditors
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
protected override PreValueEditor CreatePreValueEditor()
|
||||
{
|
||||
return new DatePreValueEditor();
|
||||
}
|
||||
|
||||
internal class DatePreValueEditor : PreValueEditor
|
||||
{
|
||||
[PreValueField("format", "Date format", "textstring", Description = "If left empty then the format is YYYY-MM-DD. (see momentjs.com for supported formats)")]
|
||||
public string DefaultValue { get; set; }
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user