-
Notifications
You must be signed in to change notification settings - Fork 101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Avoid: showing calendar / suggesting current date in <b:dateTimePicker> #590
Comments
Maybe the fact of not showing the calendar automatically, already solves the "problem" of suggesting the date. |
@ruanfelisky Have a look at http://www3.bootsfaces.net/Showcase/forms/DateTimePicker.jsf. You can use the option |
The other problem should be solved by setting |
Actually, now it does. We've confused the default value of use-current, so it had no effect. Now it has. |
You can run a test using the BootsFaces-1.1.0-SNAPSHOT on Maven Central. See #369 on how to get it. |
@stephanrauh I've tested and there is no difference in changing the option About the option |
@mtvweb Jens, it seems your pull request had some side effects:
Which errors did you PR fix? You've reported errors in your comments without mentioning which errors you've observed. In theory, these errors should be there again (see http://www3.bootsfaces.net/Showcase/forms/DateTimePicker.jsf). |
The assignment of the JQuery identifier wasn't correct in the different cases, "inline", "popup". Also there was a difference between rendering with an assigned id and with none id. Fix TheCoder4eu#590
The error in the PR regarding DataTimePicker are only related to the assigned JQuery id. Sometimes it was correct, sometimes not. As you can see at the DateTimePicker.jsf demo page, the "Embedding DateTimePicker in a form" isn't working any more. I've added a fix to my fork. It was confusing about the used id's.Depending on the properties it differs with the assigned form:id and DTP_CONTAINER_ID prefixes. Hopefully now all cases are working. |
Hi guys, the current 1.1.0-SNAPSHOT has that last correction? |
I've just uploaded the file. Happy testing! |
There's only one problem, when I click over the icon, the calendar is not showing. It's strange right? Because in the showcase it's working properly. My code is: <b:dateTimePicker allowInputToggle="false" useCurrent="false" label="Data"
value="#{myBean.date}" format="DD/MM/YYYY" fieldSize="sm" /> |
Find a snapshot build of my mtvweb-fork at: https://www.dropbox.com/s/pyx200ngh7shgjc/BootsFaces-OSP-1.1.0-20170105.jar?dl=0 feel free to check if this is working well with your project |
@mtvweb Yes, this stuff is confusing :). I hope we manage to solve the id issues soon. In the case of the dateTimePicker, it's important to call |
@ruanfelisky I've copied your snipped into the showcase, and it works just fine. Clicking the icon shows the calendar. Really strange. Maybe you've got an old snapshot - be it because my upload didn't work, or be it because of a nasty caching problem? |
@stephanrauh You're right. I was stumbled by the different cases for the previous change. Have you tried my yesterdays change? I think it is correct now, but I haven't added a PR before I am not sure that it is working in all cases. I have checked it with the Bootsfaces Showcase with my build and in my project. In any case it is working for me now. The current Showcase doesn't work completely. Check the datetimepicker in the section "Embedding a DateTimePicker in a form" |
I've discovered a funny thing with the "inline" mode. It is working well for me with Java 8 but not with Java 7. But I can't locate any Java 8 specific code in the DateTimePicker source. See http://cubie1.ddns.net/BootsFacesWeb/forms/DateTimePicker.jsf for a working example. If I run it with Java7, inline behavior is like https://showcase.bootsfaces.net/forms/DateTimePicker.jsf. Toggle inline mode results in an empty rendering. |
@mtvweb @TheCoder4eu Do we have a showcase running on Java 7? I don't have Java 7 on my PC, so I can't test the bug. |
I have setup another instance for Java7 (web app and tomcat is the same, only running on a different ajp port and another JAVA_HOME) For Java 1.8.0_111 use: http://cubie1.ddns.net/BootsFacesWeb/forms/DateTimePicker.jsf and for Java 1.7.0_51 http://cubie1.ddns.net/BootsFacesWeb7/forms/DateTimePicker.jsf |
It seems that running in Java 7 really has some bugs in I'm using Java 1.8.0_111 in my project. I will download the BootsFaces-1.1.0-SNAPSHOT again and test to see if the problem regarding the icon has been resolved. |
It's possible that the HashMap algorithm has been changed between Java 7 and Java 8. |
I've prepared a bugfix, but I'm not sure we'll include it in the 1.0.2 version we'd like to publish this weekend. My bugfix involves the |
I've compiled the current version from this repository, "inline" is working now, even in Java 7. But there is still the Id-Issue in it. I've added a PR #610 for this, because it is fixed in my repository. My current showcases are now:
|
This should be fixed by now. See http://www3.bootsfaces.net/Showcase/forms/DateTimePicker.jsf. I've uploaded a new snapshot of 1.1.0 so you can test it yourself. BTW, thanks for being so tenacious! I always looked in the wrong spots, so I didn't see the error. Too bad the bug made it into the 1.0.2 version. The main purpose of this version was to fix the dateTimePicker, along with the colorPicker and one or two other components. Sigh! |
When the
<b:dateTimePicker>
gets focus, the calendar is automatically shown, and if the input is still blank it suggests the current date.Is it possible to implement a way to avoid both behaviors or one of these individually?
I'd like to show the calendar only when the user click on the calendar icon (which also is not doing), and also not to suggest the current date every time I pass on it.
Thanks in advance.
The text was updated successfully, but these errors were encountered: