Calling datepicker from a FormHelper - Using CrispyForms

2019-08-15 Thread chevalier
I am trying to call my JQuery datepicker from a FormHelper. I just can't find a way to send attributes to JQuery e.g "theme":"dark" etc. This is important for me because i want to define the format type also. class DeviceFilterFormHelper(FormHelper): form_id =

Using Django admin datepicker in a custom form

2018-06-26 Thread sum abiut
I am trying to use a django admin datepicker in a custom form. it is displaying alright but the year only begin in 2018 but no later than 2018. Please assist, below is my form.py #my form.py from django.forms.extras.widgets import SelectDateWidgetclass ContactForm(forms.ModelForm): class Meta

Django 1.11 - Best Datepicker to use?

2017-10-21 Thread Jack Zhang
I'm looking for a datepicker widget to use for a DateTime form field. I searched around and most of the answers were old Stack Overflow posts from 2011 about hacking the calendar datepicker widget from Django's Admin. The information about that was inconclusive and I couldn't get mine to work

Jquery datepicker in a django form

2017-09-11 Thread giuseppe ricci
Hi guys, I need to insert 2 datapicker in a django form. I have not a form.py file. My views.py related to the datepicker: class DatePicker(forms.DateInput): template_name = 'dkey.html' class Media: js = ( 'js/jquery.min.js', 'js/jquery-ui.min.js', ) css = { 'all': ( 'css/jquery-ui.css

Re: django admin datepicker

2017-03-30 Thread Mike Dewhirst
On 31/03/2017 7:55 AM, sum abiut wrote: Hi, i am trying to use django admin datepicker on my custom form to have it show on two fields but when i run the app it only showing on one field, the start_date but not showing on end_date. can some please point me to the right direction. What

django admin datepicker

2017-03-30 Thread sum abiut
Hi, i am trying to use django admin datepicker on my custom form to have it show on two fields but when i run the app it only showing on one field, the start_date but not showing on end_date. can some please point me to the right direction. here is my quote. models.py class stafleave

KeyError on Form using datePicker

2017-02-21 Thread Baktha Muralidharan
Hello, I am new to Django framework and have run into the following issue. Any help to resolve the issue will be much appreciated. Background: I am using the jQuery datePicker to gather date input. I am able to see the calendar show on the Appointment form and am able to select a date from

Re: datepicker

2015-05-27 Thread aRkadeFR
Hey, Look at the widgets in the fields forms: https://docs.djangoproject.com/en/1.8/ref/forms/widgets/ Implement your own widget, so it includes the javascript and the css your datepicker needs. Then render it in your template (the medias included). Have a good one On 05/26/2015 07:30 PM

Re: datepicker

2015-05-26 Thread Peith Vergil
it with form fields. An easy > way is to simply create a regular CharField, render it like usual. Then, on > the front-end, you simply target that specific char field and initialize > the datepicker on it. > On May 27, 2015 01:31, "sum abiut" <suab...@gmail.com> wrote:

datepicker

2015-05-26 Thread sum abiut
Hi, Is there a way to implement jquery datepicker with Django models. I am looking at http://jqueryui.com/datepicker/ but i am finding very difficult to apply it to django models. any help will be very much appreciated. Cheers -- You received this message because you are subscribed

Re: ModelForm not creating datepicker

2013-04-03 Thread Nick D
've created a ModelForm and am attempting to use it, but all of my date > > fields are coming up with type "text" instead of a datepicker. Can > anybody > > tell me what's going on? > > > > DateField forms are still represented by a simple > widget. The fact

Re: ModelForm not creating datepicker

2013-04-03 Thread Tom Evans
On Wed, Apr 3, 2013 at 12:14 AM, Nick D <dominguez.nicho...@gmail.com> wrote: > Hi all, > > I've created a ModelForm and am attempting to use it, but all of my date > fields are coming up with type "text" instead of a datepicker. Can anybody > tell me what's going o

Re: ModelForm not creating datepicker

2013-04-03 Thread Nick D
: > yes that is correct maybe you want to use a datepicker > http://jqueryui.com/datepicker/ > > Cheers > > > > On Tue, Apr 2, 2013 at 5:14 PM, Nick D <dominguez...@gmail.com > > wrote: > >> Hi all, >> >> I've created a ModelForm and

Re: ModelForm not creating datepicker

2013-04-02 Thread carlos
yes that is correct maybe you want to use a datepicker http://jqueryui.com/datepicker/ Cheers On Tue, Apr 2, 2013 at 5:14 PM, Nick D <dominguez.nicho...@gmail.com> wrote: > Hi all, > > I've created a ModelForm and am attempting to use it, but all of my date > fields are c

ModelForm not creating datepicker

2013-04-02 Thread Nick D
Hi all, I've created a ModelForm and am attempting to use it, but all of my date fields are coming up with type "text" instead of a datepicker. Can anybody tell me what's going on? MODEL: class GIS_WO(models.Model): WON = models.CharField(max_length=7, blank=True, null=True)

Re: how to add datepicker (available in admin)

2012-09-10 Thread vasil mir
i followed the steps but i m ngetting following error Reverse for 'jsi18n' with arguments '()' and keyword arguments '{}' not found. Regards Vasil Mir On Thursday, 5 May 2011 19:53:52 UTC+5:30, Tom Evans wrote: > > On Wed, May 4, 2011 at 9:53 AM, GKR > wrote: > > thanks

Re: better datepicker

2011-11-28 Thread Mario Gudelj
Hey, I use http://docs.jquery.com/UI/Datepicker on the front end. It's as simple as placing $("#datepicker").datepicker(); inside the page where you want to convert the text fields to date picker fields. I'll you have to do is change the ID inside $("#datepicker").datepicker

better datepicker

2011-11-28 Thread marjenni
Hi, class SearchForm(forms.Form): date = forms.DateField(required=True, input_formats=('%d/%m/%Y',)) I am trying to change this so that it displays a calendar when the user starts to enter a date. I have seen various examples using JQuery, but I can't find an example that

Re: Missing datepicker in Django 1.3 admin

2011-08-20 Thread kenneth gonsalves
On Sat, 2011-08-20 at 20:49 +0300, Yaşar Arabacı wrote: > Did you copy admin static files to your static path? They are stored > in {DJANGO_ROOT_DIR}/contrib/admin/media . You need to copy all of > them to {YOUR_STATIC_ROOT}/admin > > or do collectstatic -- regards Kenneth Gonsalves -- You

Re: Missing datepicker in Django 1.3 admin

2011-08-20 Thread kenneth gonsalves
On Sat, 2011-08-20 at 10:40 -0700, George wrote: > Yep, that's what I did .. ADMIN_MEDIA_PREFIX = '/static/admin/' ... > was there by default. It does't show even with a new Project! ADMIN_MEDIA_PREFIX is not there in 1.3 -- regards Kenneth Gonsalves -- You received this message because you

Re: Missing datepicker in Django 1.3 admin

2011-08-20 Thread kenneth gonsalves
On Sat, 2011-08-20 at 03:40 -0700, George wrote: > I commented that out .. I'm still not seeing the datepicker icons in > admin! did you do python manage.py collectstatic? -- regards Kenneth Gonsalves -- You received this message because you are subscribed to the Google Groups "D

Re: Missing datepicker in Django 1.3 admin

2011-08-20 Thread Yaşar Arabacı
t help you figure out what is > > going on. > > > > 2011/8/20 George <gmiddlec...@gmail.com> > > > > > > > > > > > > > > > > > Thanks Kenneth > > > > > I commented that out .. I'm still not seeing the datepicker icons in

Re: Missing datepicker in Django 1.3 admin

2011-08-20 Thread George
ult settings for static files. it might help you figure out what is > going on. > > 2011/8/20 George <gmiddlec...@gmail.com> > > > > > > > > > Thanks Kenneth > > > I commented that out .. I'm still not seeing the datepicker icons in > > admin

Re: Missing datepicker in Django 1.3 admin

2011-08-20 Thread Yaşar Arabacı
If that is what kenneth says, I might suggest creating a new project and see default settings for static files. it might help you figure out what is going on. 2011/8/20 George <gmiddlec...@gmail.com> > Thanks Kenneth > > I commented that out .. I'm still not seeing the d

Re: Missing datepicker in Django 1.3 admin

2011-08-20 Thread George
Thanks Kenneth I commented that out .. I'm still not seeing the datepicker icons in admin! On Aug 20, 2:51 pm, kenneth gonsalves <law...@thenilgiris.com> wrote: > On Sat, 2011-08-20 at 01:53 -0700, George wrote: > > ADMIN_MEDIA_PREFIX = '/static/admin/' > > this does not

Re: Missing datepicker in Django 1.3 admin

2011-08-20 Thread kenneth gonsalves
On Sat, 2011-08-20 at 01:53 -0700, George wrote: > ADMIN_MEDIA_PREFIX = '/static/admin/' this does not exist in 1.3 - please read the docs on django.contrib.staticfiles -- regards Kenneth Gonsalves -- You received this message because you are subscribed to the Google Groups "Django users"

Re: how to add datepicker (available in admin)

2011-05-05 Thread Tom Evans
On Wed, May 4, 2011 at 9:53 AM, GKR wrote: > thanks but its giving an error like > > name 'AdminDateWidget' is not defined > > please help it might be a configuration problem > > please help > > thanks > I wrote: > Then modify your form to use the admin date picker widget:

Re: how to add datepicker (available in admin)

2011-05-04 Thread GKR
thanks but its giving an error like name 'AdminDateWidget' is not defined please help it might be a configuration problem please help thanks -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Re: how to add datepicker (available in admin)

2011-05-02 Thread Kenneth Gonsalves
On Mon, 2011-05-02 at 18:21 -0700, GKR wrote: > how to add datepicker (available in admin) into my custom page for > date > input form field. easier to use jquery datepicker (admin datepicker does not change years) -- regards KG http://lawgon.livejournal.com Coimbatore LUG

how to add datepicker (available in admin)

2011-05-02 Thread GKR
how to add datepicker (available in admin) into my custom page for date input form field. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this g

Re: cannot change the year in the admin datepicker

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 08:33 -0300, Ramiro Morales wrote: > > shall I file a ticket? I am still amazed that it took me 4 odd years > to > > notice this. > > There is already a [1]ticket for this. I've just tried the latest > patch, it > applies (with some fuzz) and works. Souyou can use that one >

Re: cannot change the year in the admin datepicker

2011-03-09 Thread Ramiro Morales
On Wed, Mar 9, 2011 at 8:07 AM, Kenneth Gonsalves wrote: > On Wed, 2011-03-09 at 18:58 +0800, Russell Keith-Magee wrote: >> Either way, this is worth a ticket, and it would be a good project to >> tackle for 1.4. > > shall I file a ticket? I am still amazed that it took me

Re: cannot change the year in the admin datepicker

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 18:58 +0800, Russell Keith-Magee wrote: > Either way, this is worth a ticket, and it would be a good project to > tackle for 1.4. shall I file a ticket? I am still amazed that it took me 4 odd years to notice this. -- regards KG http://lawgon.livejournal.com Coimbatore LUG

Re: cannot change the year in the admin datepicker

2011-03-09 Thread Russell Keith-Magee
On Wed, Mar 9, 2011 at 4:43 PM, Kenneth Gonsalves <law...@thenilgiris.com> wrote: > hi, > > a client has pointed out to me that it is not possible to change the > year in the admin datepicker. One has to go back month by month or > manually do it in the text input. Could thi

cannot change the year in the admin datepicker

2011-03-09 Thread Kenneth Gonsalves
hi, a client has pointed out to me that it is not possible to change the year in the admin datepicker. One has to go back month by month or manually do it in the text input. Could this be considered a bug? -- regards KG http://lawgon.livejournal.com Coimbatore LUG rox http://ilugcbe.techstud.org

Wrong datetime format with datepicker in admin

2011-02-28 Thread Dirk Eschler
Hello, using django-1.2.4 i get the wrong date format when using the datepicker or the today shortcut in the admin. Instead of the format specified in my settings, it generates a local format - "28.02.2011" instead of "2011-02-2011". settings.py: DATE_FORMAT = 'Y-m-d' DATE

Re: ModelForm+datepicker

2010-03-10 Thread Shawn Milochik
The widget has nothing to do with the model. It needs to be specified in your forms.Form or forms.ModelForm. Remember that the model is all about the database table and the form is all about the HTML form. Shawn -- You received this message because you are subscribed to the Google Groups

Re: ModelForm+datepicker

2010-03-10 Thread H . İbrahim Yılmaz
Hi, I've already checked that and i got nothing :) I did in my model.py that: from django.forms.extras.widgets import SelectDateWidget date = forms.DateField(widget=SelectDateWidget()) But did not see the datepicker :S I got name error (forms) blabla? Is there any complete reference for &quo

Re: ModelForm+datepicker

2010-03-10 Thread Shawn Milochik
Here you go: http://docs.djangoproject.com/en/1.1/ref/forms/widgets/ (Try searching http://docs.djangoproject.com/ before Google. It's really a great reference.) Shawn -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group,

ModelForm+datepicker

2010-03-10 Thread H . İbrahim Yılmaz
Hi I have some ModelForm. I want to use in my templates (or views not sure cause i am a newbie) date selector. I search about that in google but there is not very clear information. Some of thems were for old old versions of dango. Regards... -- http://www.arkeoloji.web.tr -- You received this

Re: How to add datepicker for InputDateField

2009-04-22 Thread Juanjo Conti
Search this list. I am sure this question was answered many times. 2009/4/22 Joshua Partogi <joshua.j...@gmail.com> > > All, > > I've got an InputDateField in my form, but when it is rendered to the > templates, there is no datepicker beside it like the ones in the

How to add datepicker for InputDateField

2009-04-22 Thread Joshua Partogi
All, I've got an InputDateField in my form, but when it is rendered to the templates, there is no datepicker beside it like the ones in the admin. How do I add this datepicker to an InputDateField in my form? Thank you very much in advance -- If you can't believe in God the chances are your

Re: Using Admin Datepicker in Other Apps

2009-03-01 Thread Chris Spencer
, and found that some of > my custom CSS was interfering. Thanks for your help. Quick update. I found that it was actually RUZEE.ShadedBorder (http://www.ruzee.com/blog/shadedborder) that was interfering. I'm not exactly sure how, but removing that fixe

Re: Using Admin Datepicker in Other Apps

2009-03-01 Thread Chris Spencer
09 at 7:48 AM, Chris <chriss...@gmail.com> wrote: >> > >> > > Is it a good idea to reuse admin's JS datepicker widget in other apps, >> > > and if so, what's the best way? >> > >> > > I'm using django.contrib.admin.widgets.AdminDateWidget in my f

Re: Using Admin Datepicker in Other Apps

2009-03-01 Thread Alex Gaynor
On Sun, Mar 1, 2009 at 10:25 PM, Chris <chriss...@gmail.com> wrote: > > On Feb 21, 10:03 am, Alex Gaynor <alex.gay...@gmail.com> wrote: > > On Sat, Feb 21, 2009 at 7:48 AM, Chris <chriss...@gmail.com> wrote: > > > > > Is it a good idea to reu

Re: Using Admin Datepicker in Other Apps

2009-03-01 Thread Chris
On Feb 21, 10:03 am, Alex Gaynor <alex.gay...@gmail.com> wrote: > On Sat, Feb 21, 2009 at 7:48 AM, Chris <chriss...@gmail.com> wrote: > > > Is it a good idea to reuse admin's JS datepicker widget in other apps, > > and if so, what's

Re: Using Admin Datepicker in Other Apps

2009-02-21 Thread Alex Gaynor
On Sat, Feb 21, 2009 at 7:48 AM, Chris <chriss...@gmail.com> wrote: > > Is it a good idea to reuse admin's JS datepicker widget in other apps, > and if so, what's the best way? > > I'm using django.contrib.admin.widgets.AdminDateWidget in my form, and > I've added thes

Using Admin Datepicker in Other Apps

2009-02-21 Thread Chris
Is it a good idea to reuse admin's JS datepicker widget in other apps, and if so, what's the best way? I'm using django.contrib.admin.widgets.AdminDateWidget in my form, and I've added these JS tags to my template: admin/DateTimeShortcuts.js admin/RelatedObjectLookups.js calendar.js core.js

Using datepicker outside of admin

2008-10-03 Thread jeffhg58
Before Django 1.0, I was successful able to use the datepicker outside of admin within my own application. But, since the upgrade I get a runtime error with a syntax error on line 1. This error occurs with the following line This error only occurs when the user does not have administrative