Andrew
How to deploy the django ptoject
You can type exactly what you wrote into google 👍
Abdullaev
Guys i need your help. I have model named Product and ProductTranslation and Language. What i want is when admin adds new language, he has to provide all ProductTranslations. how can i do that?
Zeinab
How to import csv file in postgresql and use to in django?
Azizbek Xushnazarov
How can I turn off throttling while testing? (drf)
Abdullaev
https://hatebin.com/yigjfocanl how to prevent creating 2 translations on the same language for 1 product
Zeinab
𝓙𝓪𝓶𝓸𝓵𝔁𝓸𝓷
How can I turn off throttling while testing? (drf)
Can you give more explanation on this?
Amir
How to import csv file in postgresql and use to in django?
You have write cvs_file = models.FileField() in models Automatically file saved in server And In postgresql just save a path of file in server
Azizbek Xushnazarov
Can you give more explanation on this?
class MyTestCase(ApiTestCase): def test1(): post req -> /api/endpoint def test2(): post req -> /api/endpoint Since /api/endpoint has a "1/min" throttle rate, the second request will be throttled. So I need to turn off throttles in tests.
Score
JavaScript variable to
Score
Django
Score
View
Score
How to use
Score
Var data = getelementbyid()
Score
How to get this in views. Py
OceanMan
Hi Developers, it is good to be here How can I advance my learnings in Django Any materials to read on Django signals and message?
Алекс
Documentation 😄
Ramy
youtube dude
Mihail
user.user_permissions.all().filter(content_type__app_label__contains="session")[3].codename return 'view_session' user.has_perm('session.view_session') return False the same as user.has_perm('view_session') why?
𝓙𝓪𝓶𝓸𝓵𝔁𝓸𝓷
thanks. it did work :)
Always welcome)
Shivam
How resolve the issue of moment.js when chose date 31-08-2019 it raises an error of "Invalid date"..
Ionut
Is it strange to put some code in the __init__.py file of the project? Where do I have to put code that must be executed before anything else?
Godfrey
I need your help 😭, I am using Django-rest-authmail on a project, And I am looking for a way to override the default sign-up email verification template
Drag
Can you guys tell me how to show old object values in Django update forms?
Bhuvan
I need to learn django and I had completed python fundamentals suggest a good tutorials to learn latest django 4.0
Godfrey
I need to learn django and I had completed python fundamentals suggest a good tutorials to learn latest django 4.0
I think you can this from the documentation, most tutorials out their might be from older versions but I believe they are useful and better explain Django as the documentation is harder to grasp.
Godfrey
I need to learn django and I had completed python fundamentals suggest a good tutorials to learn latest django 4.0
So for a start, go with available tutorial for available versions, with the aim of understanding Django, then you can latter comeback to the documentation to see the new updated features of version 4.0
Shazam_
Sending csrf_token is the work of frontend or backend developer over api? Please help
Shazam_
Is my code is poor if I have to manually send csrftoken in postman overapi?
Anonymous
Is there anybody who encounters the problem related to social-auth-app-django with the problem there is no such social-django module?
Doragonsureiyā
Is there anybody who encounters the problem related to social-auth-app-django with the problem there is no such social-django module?
Don't ask meta questions like: "Any user of $x here?" "Anyone used technology $y?" "Hello, I need help on $z!" Just ask directly! The better you are at explaining the problem, the more likely you are to get help. Asking smart questions
Morteza
Sending csrf_token is the work of frontend or backend developer over api? Please help
If you are using non-session based authentication like token based or jwt you dont need to think about the csrf_token since you are specifying the cors headers
Ewuru
Am having difficulties with sending mail
Ewuru
Someone should help me
Doragonsureiyā
Am having difficulties with sending mail
Don't ask meta questions like: "Any user of $x here?" "Anyone used technology $y?" "Hello, I need help on $z!" Just ask directly! The better you are at explaining the problem, the more likely you are to get help. Asking smart questions
Shubham
Hey guys need a bit help in django I am coding a model form there i want to make a dropdown syntax highlighter where people can select language for example if somebody select html and type some textarea the code he will type there will be automatically highlighted if somebody click on c++ the highlighting will be according to c++. Do somebody know a django library for this.
Егор
You are looking for something combining this(https://pygments.org/) and django
Ukasha
Hello
Ukasha
from django.db import models class Reporter(models.Model): first_name = models.CharField(max_length=30) last_name = models.CharField(max_length=30) email = models.EmailField() def str(self): return "%s %s" % (self.first_name, self.last_name) class Article(models.Model): headline = models.CharField(max_length=100) pub_date = models.DateField() reporter = models.ForeignKey(Reporter, on_delete=models.CASCADE) def str(self): return self.headline class Meta: ordering = ['headline'] According to this what is many and what is on
Ukasha
this is unreadable
Yaa but if i want student and parent model.. is it many to many or one to many
Ukasha
So let me say i want a gurdian to have many students. Should i put the foreignkey field in student model or gurdian model
Ukasha
in student model
Ok. Thanks. now what if i want it access a particular field in student model using the gurdian Model
Ukasha
Am using: gurdian.student_set.all().. But i can't access the field . So my case i want to access a particular field. Let me say gurdian.student.set.get()
Ukasha
👍 ok i solved my problem with filter instead of all()
Masoud
Hi, I created the Secrets.json file and put the secret in it and added the file in the Docker file and did the required work for it .... Now the website does not work? I do not know why ?
Kh
As far as i am concerned u dont need json files, there env file for docker
Masoud
Can u show where is json file, and how u make a dir for it
secret_file = os.path.join(BASE_DIR, 'secrets.json') with open(secret_file) as f: secrets = json.load(f.read()) def get_secret(settings, secrets=secrets): try: return secrets[settings] except KeyError: eror_msg = 'set the {0} environment rariable'.format(settings) raise ImproperlyConfigured(eror_msg) SECRET_KEY = get_secret('SECRET_KEY')
Masoud
Masoud
Can u show where is json file, and how u make a dir for it
{ "SECRET_KEY": "django-insecure-0adm+(!$g8w)34m%@+-rb*fs1ykcsxglxmm" } in json file
Muhammet U
hello for learning purposes I want to print all data from request object, request: <rest_framework.request.Request: GET '/movie/list/'> that is the result bu I know there should be more like request.META, how can I print all request data with all his insances and stuff
Doragonsureiyā
Yes, we know.
Muxtoriddin
Yes, we know.
how to solve it. please help me to solve it
Muxtoriddin
google django static
i have done this, but i haven't any result so i asked it
Maxim
i have done this, but i haven't any result so i asked it
the first google result: https://docs.djangoproject.com/en/4.0/howto/static-files/ If you read carefully, you can find a link to: https://docs.djangoproject.com/en/4.0/howto/static-files/deployment/
Gb
Hello please can Django be used to create a website builder like Shopify and a domain registrar
🅓🅡🅔🅐🅜🅒🅗🅐🅢🅔🅡會(Inactive)
Rstmsn
I've just been reading the news about the coming ORM async support in Django 4.1. It got me wondering, is it likely we'll ever see the day when Django is fully async, by default? or will using the async functionality always be an option based on design choice ?
**ꌩꂦꌗꌗꍟꎇ ꀸꍏꅏꂦꍏꀸ**
hey every one i have been looking for this for quite sometime now
**ꌩꂦꌗꌗꍟꎇ ꀸꍏꅏꂦꍏꀸ**
How to save or record live video feed received as bytes in django channels?
**ꌩꂦꌗꌗꍟꎇ ꀸꍏꅏꂦꍏꀸ**
i even post it as question so if you have an answer please consider answering the link for the question is here https://stackoverflow.com/questions/72165890/how-to-save-or-record-live-video-feed-received-as-bytes-in-django-channels
Vaibhav
Just a question, in django admin, if we have 2 pages open in 2 separate tabs of the same object and change them one by one without a refreshing page, the data getting overridden depending on what was saved last. Is there any library or setting which can avoid such conditions
André
you can create a rule to never cache in django admin views (stackoverflow to the rescue)