is it possible to access django related field from model methods? for example, i have an Author with many Books is it possible to access the list of books fr
I have a model in my application: class GRNRFIDSerials(models.Model): grn = models.ForeignKey(Grn, on_delete=models.CASCADE) file = models.FileField(up
l get stuck in this error. l'm fresh user of Django and l m learning it by following steps on Youtube channel. l did everything same but l got this block tag er
my rest_framework authentication and permission classes "DEFAULT_PERMISSION_CLASSES": [ "rest_framework.permissions.IsAuthenticated", "rest_fra
My models.py file is as follows: from django.db import models from django.utils import timezone from random import randint # Create your models here. class Fil
Trying to save a post on a django project I got this error The above exception (insert or update on table "django_admin_log" violates foreign key constraint "dj
I have two models, client and contact model with foreign key relation, I using Django signals to create contact while the creation of the client, but I getting
I have followed the channels tutorial but while running these error throw Version of the packages is channels==2.1.2 Django==2.0.4 what I missed ? in settings
I'm using django-cas-ng framework to authenticate users. The main problem is that the admin page still uses the default login view. Methods used this far: 1.-
how do I use nested categories in django as Im nwe to django and doing this and find some solutions but didnt work anything class MainCategory(models.Model)
I create realtime chat application using websocket frontend(angular) backend(Django).. i want to store messages in to db(mySql)..when i trying to store message
TLDR: Models moved to a new app. After migrating M2M relation refers to table that does not exist. Previous M2M table was not renamed. Django Version: 3.2.3 Sce
I was using a virtualenv in Pythonanywhere and now after cloning my repo I tried to install all the packages by using this command pip install -r packageName/r
For example, I wrote the code; SyntaxError: invalid syntax >>> python manage.py command File "<console>", line 1 python manage.py command* t
I want to pass a queryset from a view to a javascript function throught the template: my view.py: def myview(request): lista=Mymodel.objects.filter(ti
I am new to Django Class Based Views and I am working on a project where on the template I want to have Form for creating customer accounts on the left and list
I want to serve all types of media files in my Django Project I used Whitenoise to server static files and static files are working well but I'm having issues w
Trying to get my Django admin to display a list of related objects as hyperlinks to those objects. These objects are related through a many-to-many relationship
I have a model SessionCategory with a unique field name. Certain pivotal instances of this model are referenced by name; the only problem is that name is also e
If we use celery beat and run about 1000 tasks by same crontab schedule, will tasks run one by one or some tasks will not run (cause of out of time)? redis as M