Default value on a Date Picker object

13 views
Skip to first unread message

Gonzalo Espinoza Davalos

unread,
Oct 16, 2015, 7:05:00 PM10/16/15
to Tethys Platform
I'm trying to set a default value on a Date picker object (pic 01) but it is not loaded correctly in the html page (pic 02). The double quotation marks (") are rendered as a html special character (").
02.png
01.png

Shawn Crawley

unread,
Oct 16, 2015, 7:08:52 PM10/16/15
to Gonzalo Espinoza Davalos, Tethys Platform
I believe that you don't need the quotation marks. The python wrapper adds them for you. Thus, your code segment should appear like this:

attributes='value=02/01/2015',

Give that a try. If that's not it, then I don't know.

On Fri, Oct 16, 2015 at 5:05 PM, Gonzalo Espinoza Davalos <esda...@gmail.com> wrote:
I'm trying to set a default value on a Date picker object (pic 01) but it is not loaded correctly in the html page (pic 02). The double quotation marks (") are rendered as a html special character (&quot;).

--
You received this message because you are subscribed to the Google Groups "Tethys Platform" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tethysplatfor...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tethysplatform/a4d0a4f4-f734-4870-a660-7d81a6221bf9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Gonzalo Espinoza Davalos

unread,
Oct 16, 2015, 7:47:12 PM10/16/15
to Tethys Platform, esda...@gmail.com
I tried it but it didn't work. The python wrapper doesn't add the quotes.
03.png

swainn

unread,
Nov 4, 2015, 2:15:41 PM11/4/15
to Tethys Platform
I think this is related to this issue: https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!topic/tethysplatform/3_AGvbj3cUc

The quotes are removed at some point during the Gizmo rendering. 

swainn

unread,
Nov 4, 2015, 2:17:27 PM11/4/15
to Tethys Platform
If you are trying to set the initial value of the date picker, then you should use the 'initial' option:



On Friday, October 16, 2015 at 5:05:00 PM UTC-6, Gonzalo Espinoza Davalos wrote:
Reply all
Reply to author
Forward
0 new messages