This is a migrated thread and some comments may be shown as answers.

DatePicker not showing up

1 Answer 357 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Happy
Top achievements
Rank 1
Happy asked on 13 Dec 2012, 02:51 AM
I have a column bound to a nullable datetime on my entity framework object.  I have my formatting set to yyyy-MM-dd.  The grid renders properly.

But when I click to edit, all I get is a textbox, and the textbox has changed the formatting of the date from 

2013-03-20
to
Wed Mar 20 00:00:00 EDT 2013. 

And worse, without even actually editting that date, I can't save anymore as I get a date format validation error.

I've tried various things getting ideas from other posts.  Right now what I have:
columns.Bound(p => p.SaleDate).Format("{0:yyyy-MM-dd}").EditorTemplateName("saleDatePicker");

then I also have

<script type="text/x-kendo-template" id="saleDatePicker" >
     @(Html.Kendo().DatePicker().Name("SaleDatePicker"))
 </script>

For a datepicker, should I even be doing anything or should it be automatic?

 

 

 

1 Answer, 1 is accepted

Sort by
0
Happy
Top achievements
Rank 1
answered on 13 Dec 2012, 06:32 PM
Finally figured this out. It wasn't finding the editor templates.  I removed all the custom stuff, put the editor templates folder into my shared folder and now the dropdowns are appearing.
Tags
Grid
Asked by
Happy
Top achievements
Rank 1
Answers by
Happy
Top achievements
Rank 1
Share this question
or