Re: finding get_user_model

2017-01-06 Thread roboslone
Hi! Did you run migrations after adding 'django.contrib.auth' to your INSTALLED_APPS? > On 6 Jan 2017, at 07:30, Rasika wrote: > > from django.contrib.auth import get_user_model > why I am not able to find the code forget_user_model in auth app. > > While when I searched > https://docs.djangop

Making a simple chatbot with Django

2017-01-06 Thread Ali İNCE
Hi every one; I am a phd student in Turkey (Computer and information Engineering) I want to make a simple chatbot like "http://alice.pandorabots.com"; using python/Django. can any one help or advice about it. Thanks for your help and interest. A. L. I. C. E. The Artificial Linguistic

Re: Dynamic Models

2017-01-06 Thread Guilherme Leal
@Michal Petrucha That was one of the insights that I've been wanted. One way or another I will try, but will keep in mind these points. Thank you! -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving

Re: finding get_user_model

2017-01-06 Thread M Hashmi
from django.apps.config import get_model On Fri, Jan 6, 2017 at 2:03 AM, roboslone wrote: > Hi! Did you run migrations after adding 'django.contrib.auth' to your > INSTALLED_APPS? > > On 6 Jan 2017, at 07:30, Rasika wrote: > > from django.contrib.auth import get_user_model > why I am not able t

Re: Making a simple chatbot with Django

2017-01-06 Thread ludovic coues
First, if you haven't done so, do a tutorial on django. If the official one [1] doesn't suit you, I recommend the django girls one [2]. Then, write a basic django chat application. Send data from the user to django, then echo back what that line. You'll need a form sending data, like the one for a

iterate a save in a form view based on a field value

2017-01-06 Thread MikeKJ
So I have a form of post values and one of the values is the number of resources to be used, what I want to do is save multiple instances of the form data based on the resource quantity to be used. ResourceObject is the model name views.py snippet [code] rqb = int(resource_quantity

Re: iterate a save in a form view based on a field value

2017-01-06 Thread roboslone
Hi! You probably want to use range() function for that. > On 6 Jan 2017, at 18:21, MikeKJ wrote: > > So I have a form of post values and one of the values is the number of > resources to be used, what I want to do is save multiple instances of the > form data based on the resource quantity to

Re: Making a simple chatbot with Django

2017-01-06 Thread Augusto Goulart
Simplest advice possible: Use the Dango-rest-framework.On the server side, your chat bot is simply receiving requests. Start with the Telegram API, is easier and better documented than Facebook's. Em sexta-feira, 6 de janeiro de 2017 08:14:38 UTC-2, Ali İNCE escreveu: > > *Hi every one;* > > > *

Issue whe migrate with relation between tables in different schemas

2017-01-06 Thread felipe . pereira . nitens
I'm working with Django 1.9.7 with Postgresql and I stuck in a problem with relations between tables in different schemas. The problem that I'm facing is that I have a table, for example, named *product, *which is in a schema named *dataflex *and another table named *client_product_sale_stc *

How to change a language's label in Django language specific URLs using i18n_patterns?

2017-01-06 Thread Rodrigo Cea
I'm using Django's i18n_patterns, so my URLs look like www.domain.com/pt/title. I want to change the language code in the URL to a different string, say, for example 'br' instead of 'pt', so the same url above would be rendered www.domain.com/*br*/title. I only want to change the language's lab

OSMGeoAdmin can only edit polygons, cannot create new ones

2017-01-06 Thread eric conner
Hello Django Users! I am trying to use OSMGeoAdmin to create an editable PolygonField backed by MySQL. This works great for existing polygons, but it does not seem to be possible to create new polygons using the admin. Here's a gif of me successfully modifying an existing Polygon: gfycat.com/

Re: OSMGeoAdmin can only edit polygons, cannot create new ones

2017-01-06 Thread Eric Conner
Ah, well I feel dumb. I figured out how to do it. In the second example, it is correct to use the blue drawing tool. You just have to hold 'Shift' when clicking the last point to actually get the polygon to snap onto the page. On Fri, Jan 6, 2017 at 11:50 AM, eric conner wrote: > > Hello Djan

Question Is Django Rest Framework only for APIs or can i Use it to create Users for a website?

2017-01-06 Thread djangorobert
Ya the question is what it means Ive gone through it and looks like you could but not sure I know its good for apis but wanted to see if it could be used for Authenticating User for a website that im building any responses would be appreciated thank you -- You received this message because y

Re: Question Is Django Rest Framework only for APIs or can i Use it to create Users for a website?

2017-01-06 Thread M Hashmi
Django RestAPI is a layer that exposes part of your application or your whole website to other platforms for connectivity. Once it is integrated then whatever tasks you've specified for DjangoRestFramwork to carry to another platform will act for everything what that application tend to present. So

Re: Question Is Django Rest Framework only for APIs or can i Use it to create Users for a website?

2017-01-06 Thread Robert librado
Thanks i guess i will go with djangi all auth instead kind of leaning towards a social network On Jan 6, 2017 10:39 PM, "M Hashmi" wrote: > Django RestAPI is a layer that exposes part of your application or your > whole website to other platforms for connectivity. Once it is integrated > then wh