Re: Add model item with AJAX pop up

2016-02-08 Thread pa xapy
hi easiest way is to write separate view which will handle ajax requests (get and post) and render html (as a json field) and success status as response. on frontend you will handle this response to show modal with form and submit it until model will successfully saved once it happens, you can

Re: search page

2016-01-28 Thread pa xapy
queryset.filter(title__icontains=query) is not enough? On Wednesday, January 27, 2016 at 12:46:21 AM UTC+3, Xristos Xristoou wrote: > > hello, > > > i want to an easy way to create search page on my site to searching only > the titles. > who is the better and easy way for to doa that ? > mayde

Re: django pagination

2016-01-26 Thread pa xapy
are you using python 3? that's actually what i talking about - it's too old try another one, like this https://github.com/jamespacileo/django-pure-pagination - follow the instructions and i hope you'll be fine On Tuesday, January 26, 2016 at 5:09:29 PM UTC+3, Xristos Xristoou wrote: > > i

Re: django pagination

2016-01-26 Thread pa xapy
are you familiar with the pip utility? if not, i highly recommend to read about it https://pip.pypa.io/en/stable/quickstart/ if yes, you should know that you can install any application with pip install package_name and how set it up with django - it's better if you read in instructions for

Re: django pagination

2016-01-26 Thread pa xapy
you can read the usage doc i sent linked, but yes - you don't need to do anything with you queryset in view only pass it to template On Tuesday, January 26, 2016 at 4:39:17 PM UTC+3, Xristos Xristoou wrote: > > if i use {autopagination} i dont need quyre on my view ? > > Τη Δευτέρα, 25

Re: django pagination

2016-01-26 Thread pa xapy
if you'll decide to use some app for pagination, you can do it in template, like so https://github.com/ericflo/django-pagination/blob/master/docs/usage.txt ({% autopaginate posts 10 %}) or you can choose one of these https://www.djangopackages.com/grids/g/pagination/ there is no actual need to

Re: django pagination

2016-01-26 Thread pa xapy
you want to paginate both querysets at the same page? i believe it's a pretty strange idea and if so, you should think how to refactor it if you want only paginate posts, i'll recommend you to use django-pagination app of some sort, it's can be used in template On Monday, January 25, 2016 at

Re: How to write Model.get_absolute_url()?

2015-12-07 Thread pa xapy
there is two approaches: you can either create unique names for each url pattern entry like url(, name='my_app_unique_view_name') or use namespace and pass it to reverse like reverse('my-app-namespace:my-url-pattern-view-name') On Sunday, December 6, 2015 at 3:29:29 AM UTC+3, Jon Ribbens

Re: Django - How to combine queries in to one and display it in the template?

2013-11-03 Thread pa xapy
> > write custom method on User model or custom template tag first one allow you to do something like: {% for item in user.get_what_you_need %} ... {% endfor %} and second one: {% get_what_you_need user %} -- You received this message because you are subscribed to the Google Groups "Django

Re: "Writing First App" Tutorial - no settings

2013-09-23 Thread pa xapy
which version of tutorial you working through? which version of django did you use? usually, with latest versions. your settings.py file should be in .../myproject/myproject/ folder. On Monday, September 23, 2013 2:04:07 PM UTC+4, Avril Lang wrote: > > So I'm obviously a newbie and working my

Re: pattern matching wrong app ???

2013-09-04 Thread pa xapy
you shouldn't use "$" in the include patterns > > -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this

Re: Exception Value: No module named url -- on django poll tutorial

2013-08-08 Thread pa xapy
you have a typo in the urls.py -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to

Re: Can't run manage.py runserver (Django 1.5.1)

2013-08-06 Thread pa xapy
try to use linux. running python on win is suffering -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this

Re: django graphics

2013-07-10 Thread pa xapy
why you do this with django? there so many js libraries i think that for the web purposes its best solution than generate graphics with python. personally, i'm using the http://www.highcharts.com/ - flexible and easy to start. great docs. On Tuesday, July 9, 2013 5:30:45 PM UTC+4, amanjot kaur