Re: javascript transpilers

2018-01-29 Thread Andréas Kühne
2018-01-30 5:18 GMT+01:00 Mike Dewhirst : > On 29/01/2018 9:03 PM, Nick Sarbicki wrote: > >> Going SPA when you don't know JS is very much a baptism of fire. >> >> Angular is personally my favourite too and essentially forces the SPA >> model. But it has a much bigger

Re: Get request, has PK, how do I access the PK data with in the model

2018-01-29 Thread Andréas Kühne
Hi, No, year__in should be for a list. For example you can write: Profile.objects.filter(year__in=[2017, 2016, 2015]) so in your case it would be Profile.objects.filter(year=user.birthday.year) You should checkout how selection works in the django documentation:

Re: Django development -

2018-01-29 Thread Matemática A3K
On Thu, Jan 25, 2018 at 10:27 AM, Matt wrote: > Hi all, > > First time poster - so hi! & hope I'm asking things here in the right > way. I've used django, on and off, for a while for personal little > projects, and found it fun to use. But I'm, no pro, and its not my day

Re: wsgi error

2018-01-29 Thread Matemática A3K
On Sat, Jan 27, 2018 at 12:05 AM, tango ward wrote: > Hi Team, > > Not sure if this issue covered here but I am getting an error uploading my > pet project in Heroku. > > ModuleNotFoundError: No module named 'animals.wsgi' > > 2018-01-27T02:59:26.637953+00:00 app[web.1]:

How do I convert an existing column to Foreign Key?

2018-01-29 Thread Tom Tanner
I have two models `model_a` and `model_b`, where their tables look something like this... Table `a` looks something like this -- first row is column names, both contain characters: id | tractce | someString 2 | "0011900" | "Label here" Table `b`: id | tractFIPS 1 |

Template Namespace Error (django2)

2018-01-29 Thread Carl Brubaker
I'm going through the Mozilla Django tutorial and I can't get the template namespacing to work. If I leave the templates in the "templates" folder, all is well. When I try to move them to the "templates/catalog" folder it's nothing but errors. I think it might have something to with the

Re: javascript transpilers

2018-01-29 Thread Mike Dewhirst
On 29/01/2018 9:03 PM, Nick Sarbicki wrote: Going SPA when you don't know JS is very much a baptism of fire. Angular is personally my favourite too and essentially forces the SPA model. But it has a much bigger learning curve compared to Vue and React (the other two common names thrown about

Re: Django-Channels: Debugging

2018-01-29 Thread Andrew Godwin
I'm not sure why the print messages were buffered - next time try flushing stdout and see if that makes it work. Andrew On Mon, Jan 29, 2018 at 6:49 AM, 'Matthias Brück' via Django users < django-users@googlegroups.com> wrote: > Ok, i found the problem, the authentification is not working

Re: Views triggering twice

2018-01-29 Thread Arun Kumar Mani
Malcolm, i'm seeing the same issue of my page loading twice. working on top of something my previous colleague built. i see "background" element when i do curl. I dont see this in any of my HTML files. I'm sure that i'm looking at the wrong place. This is my curl response: Page not

Re: Get request, has PK, how do I access the PK data with in the model

2018-01-29 Thread Travis Pickle
Hiya -- Thanks. This is sort of what I was looking for. user = User.objects.get(pk=pk) cars = Car.objects.filter(year=user.birthday.year).all() UserRelatedProfiles or user_related_profiles = Profile.objects.filter(year__in=user.birthday.year) ? On Monday, January 29, 2018 at 8:40:13 AM UTC-5,

Re: need to find out if someone is an orphan when I have mother_alive and father_alive fields in the database

2018-01-29 Thread Jani Tiainen
Hi. Your code is incomplete and actual error (whole traceback is missing) Also you're trying to mix usage of form and reading post data directly. You should only use form to deal with user input. See https://docs.djangoproject.com/en/2.0/topics/forms/ for more information. Finally with Q

Oportunidade Python/Django RJ

2018-01-29 Thread edgar
A B Rbid.com está em busca de Desenvolvedores Python, para atuar ativamente no desenvolvimento e manutenção da nossa plataforma de leilão online que é feita em Python/Django. *Requisitos:* - Experiência mínima de 2 anos desenvolvendo em python e Django; - Experiência com

Re: need to find out if someone is an orphan when I have mother_alive and father_alive fields in the database

2018-01-29 Thread Etienne Robillard
Hi Eileen, What is the error message? By the way, one way to improve your code readability would be to use form.is_valid() : For instance: new_data = form.is_valid() Hope this helps, Etienne Le 2018-01-29 à 15:03, eil...@themaii.org a écrit : Hi, I need to find out if someone is an

need to find out if someone is an orphan when I have mother_alive and father_alive fields in the database

2018-01-29 Thread eileen
Hi, I need to find out if someone is an orphan when I have mother_alive and father_alive fields in the database. Stepfathers, and stepmothers etc aren't counted when determining if someone is an orphan, only their birth mother, and birth father. I tried if form['orphaned'].data == True:

Re: Django-Channels: Debugging

2018-01-29 Thread 'Matthias Brück' via Django users
Ok, i found the problem, the authentification is not working because of django-tenant-schemas. But I'm still wondering why the print messages only gets output after a restart of the worker. Am Montag, 29. Januar 2018 12:30:54 UTC+1 schrieb Matthias Brück: > > Hi everyone, > > I have added a

Re: django 2 under python 2

2018-01-29 Thread Andy
its fixed now .. you can savely install django under python2 again :) Am Donnerstag, 25. Januar 2018 22:39:43 UTC+1 schrieb Andy: > > Hi! > > pip inside a python2 virtualenv will try to install django 2, which aint > working and will fail. > I wonder why this is happening because for instance if

Re: Get request, has PK, how do I access the PK data with in the model

2018-01-29 Thread Andréas Kühne
Hi, It's really hard to understand what you exactly want. Without showing your code it'll be even harder to understand how / what you want to do. We have to guess from the little information you are giving However. if you want to query cars with the same year as the user for example, you

Re: Get request, has PK, how do I access the PK data with in the model

2018-01-29 Thread Travis Pickle
I'm assuming not a single person has read what is in my body of my message and has only read the subject. I know bots have read the body. if http://somesite.com/user/ *1 ,where 1 is the pk,* i want to use in the view pk relation to gather all fields, and use fields

Django-Channels: Debugging

2018-01-29 Thread 'Matthias Brück' via Django users
Hi everyone, I have added a websocket connection via django-channels to one of my projects. Everything is working fine locally. But when I try to setup everything on my staging server I never come to the point where actually messages got send and received between the clients and the server.

Re: view user profile access restriction

2018-01-29 Thread sum abiut
Thanks heaps , I noticed that. On 29/01/2018 8:28 PM, "Daniel Roseman" wrote: On Monday, 29 January 2018 05:57:55 UTC, suabiut wrote: > > I manage to fixed it. I have created two instances (profile_info and info) > in my view, i use the first instance to access the

Re: javascript transpilers

2018-01-29 Thread Nick Sarbicki
Going SPA when you don't know JS is very much a baptism of fire. Angular is personally my favourite too and essentially forces the SPA model. But it has a much bigger learning curve compared to Vue and React (the other two common names thrown about nowadays). The others are also easier to not

Re: Get request, has PK, how do I access the PK data with in the model

2018-01-29 Thread Daniel Roseman
On Sunday, 28 January 2018 19:01:35 UTC, Travis Pickle wrote: > > I am using django 1.8. > > I read though the docs, however, i not seeing how I can get the PK other > attributes to use in model searching. > As others have stated, this is *fully* covered in the tutorial, specifically in part

Re: view user profile access restriction

2018-01-29 Thread Daniel Roseman
On Monday, 29 January 2018 05:57:55 UTC, suabiut wrote: > > I manage to fixed it. I have created two instances (profile_info and info) > in my view, i use the first instance to access the information from my > Profile model and the second instance to access th User model. I also set > the

Re: javascript transpilers

2018-01-29 Thread Andréas Kühne
If that is the case - I would recommend looking into creating a single page app - with Django restframework on the backend if you want to continue with Django. For the frontend you will however be required to learn some sort of JS framework - however this doesn't have to be THAT bad. I personally