Wow. I wrote this code five month ago and the vaadin version was 10.0.0.beta8
A quick try to import this on the new vaadin version already discourage me.
@ClientDelegate annotation i used doesn’t exist anymore.
Wow. I wrote this code five month ago and the vaadin version was 10.0.0.beta8
A quick try to import this on the new vaadin version already discourage me.
@ClientDelegate annotation i used doesn’t exist anymore.
Alain HIRSCH:
Wow. I wrote this code five month ago and the vaadin version was 10.0.0.beta8A quick try to import this on the new vaadin version already discourage me.
@ClientDelegate annotation i used doesn’t exist anymore.
@ClientDelegate is now @ClientCallable I think
Yes thank you i found it too.
I achieved to make it working with the latest vaadin 10 version with some change in my code.
here is the zip of a sample vaadin starter project. I just add the CustomDatePicker component in the header to test it.
Works for me.
But it’s for french date format, you will need to adapt for your use.
And for disclaimer, i am not using vaadin 10 for my development at he moment. In my work we will stick in older vaadin versions because we need internet explorer < 11 compatibility.
And i’m not sure vaadin 10 is enough mature to start a big project either.
This was just for training me and to see if it was possible to enhance an existing vaadin 10 component.
So prefer the official vaadin component when it will be released.
17368346.zip (93.8 KB)
Cool!
It would be good if it was a standard component.
Can you make him support Instant?
Who is this question addressed to? and what do you mean for instant ? The seconds ?
@Alain HIRSCH
I have Dto with field
Instant created;
Vaadin datepicker and you widget work with LocalDateTime
Ok.
You can easily convert a LocalDateTime to Instant.
You can modify the java class CustomDatePicker to override setValue() with an Instant parameter and add a getter that will you return an Instant.
I use Crud 3.6.0
defaultCrudFormFactory.setFieldProvider(AdminDto.FIELD_CREATED, CalendarDateTimeComponent::new);
Caused by: java.lang.ClassCastException: class java.time.LocalDateTime cannot be cast to class java.time.LocalDate (java.time.LocalDateTime and java.time.LocalDate are in module java.base of loader 'bootstrap')
I have error
TypeError: Polymer.dom(...).querySelector(...).root.querySelector(...).root is undefined; can't access its "querySelector" property
Polymer.dom(this.root).querySelector("vaadin-date-picker-overlay").root.querySelector("#content").root.querySelector("vaadin-date-picker-overlay-content").root.appendChild(tmp);
Alain HIRSCH:
Yes thank you i found it too.
I achieved to make it working with the latest vaadin 10 version with some change in my code.here is the zip of a sample vaadin starter project. I just add the CustomDatePicker component in the header to test it.
Works for me.
But it’s for french date format, you will need to adapt for your use.And for disclaimer, i am not using vaadin 10 for my development at he moment. In my work we will stick in older vaadin versions because we need internet explorer < 11 compatibility.
And i’m not sure vaadin 10 is enough mature to start a big project either.This was just for training me and to see if it was possible to enhance an existing vaadin 10 component.
So prefer the official vaadin component when it will be released.
Is there a way to have this in plugin format? This is exactly what I need for my application.
Sorry but you have to wait Vaadin standard component for that. I can’t maintain this component as i said in my disclaimer. This is only a workaround.