Re: Proble understanding DetailView url doesn't match the slug

2015-02-14 Thread Daniel Roseman
On Saturday, 14 February 2015 04:28:40 UTC, inoyon artlover KLANGRAUSCH wrote: > > > urlpatterns = patterns('', > url(r'^admin/', include(admin.site.urls)), > url(r'^(?P)$',List.as_view()), > ) > That regex will never match anything. You need to give it some character classes to match:

Re: Proble understanding DetailView url doesn't match the slug

2015-02-14 Thread Adailton (Dhelbegor)
models.py slug = models.SlugField(verbose_name='Slug', unique=True) @models.permalink def get_absolute_url(self): return ('myapp:List', (), {'slug': self.slug}) admin.py from .models import List01 class ArticleAdmin(admin.ModelAdmin): prepopulated_fields = {"slug": ("name",)} admin.s

Re: passing a list of list to a template

2015-02-14 Thread Adailton (Dhelbegor)
#views def tests(request): acept = get_object_or_404(Modeltest, released=True) context = {'keys': acept} # [1] return render(request, 'temp_test.html', context) #template {% for key in keys %} # [1] {{key.title}} {{key.name}} {{key.number}} {{key.etc}} {% endfor %}

Hit API in python django

2015-02-14 Thread Kapil Tomer
I am developing a site on django. I want to hit a api url. Please suggest me. Its realy very urgent. Thanks -- 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 djan

Is there anyone whos used Django with webfaction that has made there own tutorial ?

2015-02-14 Thread djangocharm2020
seem to be having issues with it one question if anyone has if you make a new project from scratch do you still need to use the virtualenv to create a project -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and

Re: Hit API in python django

2015-02-14 Thread Mike Dewhirst
On 14/02/2015 8:06 PM, Kapil Tomer wrote: I am developing a site on django. I want to hit a api url. Please suggest me. Its realy very urgent. Thanks http://www.django-rest-framework.org/tutorial/quickstart/ -- You received this message because you are subscribed to the Google Groups "Django

Re: Hit API in python django

2015-02-14 Thread James Schneider
Do you want code in your Django project to contact an API provided by another site in order to display information on your site? Or are you writing an API to provide services for end users? If the latter, I would recommend the DRF in the link provided in the previous response by Mike. -James On F