Skip to content
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

About third-party date and time widgets #198

Open
fengzhihenxs opened this issue Jun 12, 2020 · 7 comments
Open

About third-party date and time widgets #198

fengzhihenxs opened this issue Jun 12, 2020 · 7 comments
Labels

Comments

@fengzhihenxs
Copy link

Now the officially supported third-party date widget is bootstrap datepicker, but bootstrap datepicker cannot set the time part. Is there a way to support bootstrap datetimepicker, so that a widget date, time, datetime can be supported.

@tsv2013 tsv2013 transferred this issue from surveyjs/survey-library Jun 13, 2020
@tsv2013
Copy link
Member

tsv2013 commented Jun 13, 2020

Yes, you can implement a custom date time picker widget using the https://github.com/surveyjs/widgets/blob/master/src/bootstrapdatepicker.js widget code as a basis.

@fengzhihenxs
Copy link
Author

@tsv2013 Thank you very much, I have implemented bootstrap datatimepicker.
After the implementation, there is a small problem that needs to be asked to you: When the scroll bar appears in the survey container, scroll the scroll bar of the survey container, the datatimepicker window is fixed on the current page, and does not move with the scroll bar, but when the survey container does not appear the scroll bar When scrolling the scroll bar of the survey container, the datatimepicker window moves with the scroll bar. I think this is not reasonable. Is there a solution?

This is an example:https://plnkr.co/edit/lPfGBzQpEa98Gbch?preview

@fengzhihenxs
Copy link
Author

Just now is the bootstrap datepicker example, which is also true. The following is the case of bootstrap datatimepicker.
image

@tsv2013
Copy link
Member

tsv2013 commented Jul 7, 2020

@fengzhihenxs for some reason I think it’s caused by bootstrap... propably popup container is misplaced

@sirajansari3
Copy link

@tsv2013 Hi,
I am trying to add one of the custom widget to survey creator toolbox but getting failed...plz help.
i m referring this example https://codesandbox.io/s/crazy-rain-3wqj7?file=/src/customwidget.js

@tsv2013
Copy link
Member

tsv2013 commented Dec 21, 2020

@Mahesh4Providence
Copy link

Hello @fengzhihenxs ,
Could you share the widget.js code for bootstrap datatimepicker .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants