Re: simple Rest_framework cannot import name in api view

2019-11-12 Thread MEGA NATHAN
yeah bro *Regards* Meganathan G On Wed, Nov 13, 2019 at 10:15 AM Suraj Thapa FC wrote: > It should be like.. APIView not like APIview > > On Wed, 13 Nov 2019, 9:33 am MEGA NATHAN, > wrote: > >> patterns = getattr(self.urlconf_module, "urlpatterns", >> self.urlconf_module) >> File

Re: simple Rest_framework cannot import name in api view

2019-11-12 Thread Suraj Thapa FC
It should be like.. APIView not like APIview On Wed, 13 Nov 2019, 9:33 am MEGA NATHAN, wrote: > patterns = getattr(self.urlconf_module, "urlpatterns", > self.urlconf_module) > File >

where I should send file?

2019-11-12 Thread Jordan Micle
I am going to send to storage from my server. That storage url is like this ftp://***.***.com how can I send file to here? I tried to use ftplib but says "socket.gaierror: [Errno 11001] getaddrinfo failed" like this. I think this storage is located on s3, I set this storage on washabi s3.

Re: simple Rest_framework cannot import name in api view

2019-11-12 Thread MEGA NATHAN
patterns = getattr(self.urlconf_module, "urlpatterns", self.urlconf_module) File "C:\Users\Meghanathan\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\utils\functional.py", line 80, in __get__ res = instance.__dict__[self.name] = self.func(instance) File

Re: reg: Django forms and models

2019-11-12 Thread o1bigtenor
On Tue, Nov 12, 2019 at 12:39 PM 'Amitesh Sahay' via Django users wrote: > > Hello Kasper, > > Thank you for the hint. I found my mistake and resolved it. > So what did you do? (doesn't need to have all the detail just the idea please) TIA -- You received this message because you are

Turn a dataframe into a form

2019-11-12 Thread Charlie Mitchell
I am creating a form in Django. There are some static fields included but I also want to include some fields based on a csv file. However, I can't figure out how to make those text fields part of the form submission. forms.py class OptimizerForm(forms.Form): no_lineups =

Re: reg: Django forms and models

2019-11-12 Thread 'Amitesh Sahay' via Django users
Hello Kasper, Thank you for the hint. I found my mistake and resolved it. Regards, Amitesh On Tuesday, 12 November, 2019, 2:02:09 AM IST, Kasper Laudrup wrote: Hi Amitesh, In this view: On 11/11/2019 20.36, 'Amitesh Sahay' via Django users wrote: > > def contact(request): >   

Re: JSONField filter fails with TypeError: can only concatenate tuple (not "list") to tuple

2019-11-12 Thread John-Paul Navarro
Django 2.2.7 fixed the problem. Thanks! On Friday, November 1, 2019 at 4:59:11 PM UTC-5, Raffaele Salmaso wrote: > > On Fri, Nov 1, 2019 at 10:38 PM John-Paul Navarro > wrote: > >> The following fails with Django 2.2.6 but works with Django 1.11.x. >> >

Django 2.2 CheckContraint: how to check "min_foo < max_foo" ?

2019-11-12 Thread Olivier
hello, Looking at [1], I can see examples where one can check at database level, that a model field min_foo satisfies a constraint such as "min_foo > 5". How do you write a constraint involving two different fields like "min_foo < max_foo" or "discounted_price < price" ? PostgreSQL doc shows

Re: Django Query

2019-11-12 Thread Eng. Medson Naftal
Visit this link https://simpleisbetterthancomplex.com/tutorial/2018/01/18/how-to-implement-multiple-user-types-with-django.html On Tue, Nov 12, 2019, 18:20 Suraj Thapa FC wrote: > You can simply do this with a single login > > On Tue, 12 Nov 2019, 6:59 pm Deepak Singh, > wrote: > >> I have a

Re: Multi-Tenancy MySQL Database in Django

2019-11-12 Thread Integr@te System
https://github.com/citusdata/django-multitenant welcome On Tue, Nov 12, 2019, 19:30 Senthil Kumar wrote: > We are going to do a SAAS based application for our existing application. > We need to integrate the Multi-Tenancy database using MySQL in this > application. Please suggest any

Re: Django Query

2019-11-12 Thread Suraj Thapa FC
You can simply do this with a single login On Tue, 12 Nov 2019, 6:59 pm Deepak Singh, wrote: > I have a survey form for students and teachers. Questions are different > for students and teachers, so I want to provide them with different login. > How do I create different login pages in Django

Django Query

2019-11-12 Thread Deepak Singh
I have a survey form for students and teachers. Questions are different for students and teachers, so I want to provide them with different login. How do I create different login pages in Django that redirect to different pages? And how can I store the students and teachers username and password

Re:

2019-11-12 Thread prakash madariya
Hello there, If u go with django auth(django library) u will have all the options to configure the reset password, create password, login and log out process coding.. U just need implement it to ur program by importing the django-auth library.. Refer the below link.

Multi-Tenancy MySQL Database in Django

2019-11-12 Thread Senthil Kumar
We are going to do a SAAS based application for our existing application. We need to integrate the Multi-Tenancy database using MySQL in this application. Please suggest any predefined packages available in Django. For example, company1.domain.com,company2.domain.com,company3.domain.com.Here

Re: djangorestframework vs GraphQL

2019-11-12 Thread Integr@te System
Hi Freinds, GQL, when compare DRF, it as an option, and for whom familiar with other tools without DRF or Python, and align thinking with framework/anythingelse relate to JS. Base on your choice or requirement. On Tue, Nov 12, 2019, 16:24 Nick Sarbicki wrote: > GraphQL strikes me as very

Re: djangorestframework vs GraphQL

2019-11-12 Thread Nick Sarbicki
GraphQL strikes me as very similar to NoSQL. Useful in niches but the older standard is better in general. I've tried both and the added complexity (designing a system to generate all required data from a single request) of GraphQL for the, seemingly minor, gain (a single request for all your

djangorestframework vs GraphQL

2019-11-12 Thread guettli
Hi, I am new to GraphQL, but I like the idea very much. There is already an A Django integration for Graphene: https://github.com/graphql-python/graphene-django What are the pros and cons of djangorestframework and GraphQL? Which one would you choose, if you could start from scratch?

Re: How t do Login using Gmail, twtter or facebook

2019-11-12 Thread Balaji Shetty
Thank You very much to all Django Experts * Andréas Kühne, Nick Sarbicki, Kasper Laudrup, Andréas Kühne *for your nice reply about my Query. On Mon, Nov 11, 2019 at 3:08 PM Nick Sarbicki wrote: > I generally like to implement things like Google auth myself, as it's not > too complex and down