DateTime picker in hawtio

14 views
Skip to first unread message

Tomaž Hauzer

unread,
Feb 7, 2018, 8:49:56 AM2/7/18
to hawtio
Hi,

i'm developing a Hawtio plugin and it's my first time working with AngularJS. I'm trying to have some component that would be enable to pick a date and time.
Basically what i did is expanded the simple plugin project.

First i tried it with the datetime-local input component, which gets the job done. The only thing i have a problem is that i don't know if the format of the datetime can be set. Couldn't find any information about that and it if can be controlled?

The other option is to using something like this:
https://dalelotts.github.io/angular-bootstrap-datetimepicker/

But here my problem begins where i lack some understanding of the whole AngularJS framework and how it is connected to the Hawtio plugin implementation.
How do i add that datetimepicker to my plugin or any other custom components for that matter? Is there any documentation about that?

If is this more of a AngularJS issue, then i can ask it somewhere else.

Probably i just overlooked something, but if i could get some help with this it would be great.

Cheers,
Tomaz

Tadayoshi Sato

unread,
Feb 7, 2018, 10:46:14 PM2/7/18
to Tomaž Hauzer, hawtio
Hi Tomaz,

A hawtio plugin is basically an AngularJS 1.x app so everything you can use on AngularJS 1.x can be used for hawtio plugin.

Regarding the datetime-local input, you can find the doc here.

It says:

One thing to note is that the displayed date and time formats differ from the actual value; the displayed date and time are formatted according to the user's locale as reported by their operating system, whereas the date/time value is always formatted yyyy-MM-ddThh:mm. When the above value submitted to the server, for example, it will look like partydate=2017-06-01T08:30.

You may also use angular-bootstrap-datetimepicker. I believe you can just add <script> tags to the template html files to load 3rd party components for your hawtio plugin.

Best regards,
Tadayoshi


--
You received this message because you are subscribed to the Google Groups "hawtio" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hawtio+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Tomaž Hauzer

unread,
Feb 9, 2018, 7:40:13 AM2/9/18
to hawtio

Will go with the separate elements for date and time, they are little more consistent across browsers.

In any case, thanks for the info.

Regards,
Tomaz
To unsubscribe from this group and stop receiving emails from it, send an email to hawtio+un...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages