Context: I'm playing around with setting up a DRF project using the postgresql sample database located here: Postresql Sample DB Problem: The sample database is
I'm just passing the same object 2 times in the same serializer but I want to pass key: "retweet": null in one object and in another object I want to pass some
I work with Mongoengine in Django, got task to sort by first_name, last_name fields ignoring case and leading whitespaces that is why add collation in queryset:
I have created filters that filter API responses, if the response contains at least one letter in the value as substring, I need to create a filter to filter re
Even if I've enough experience with Python & VScode, I often get this major misunderstanding. For example, I have two projects Project1_folder .env1
I followed YouTube Django E-commerce video, I did exactly the same as the tutorial. But I found some difficulty in certain code. CONTEXT_PROCESSORS.PY from .mod
I'm trying to list all facilties owned by a user on a "facility list page" using the django rest framework and react. I tried the following to make this happen
I am trying to build a web app which should get data from Django Rest Framework (using Serializer) and pass it to JavaScript and generate markers of GoogleMaps.
I'm trying to test my view which requires csv_file and one parameter in request, but getting error "details": {"csv_file": ["The submitted data was not a file.
I have checked every single solution on other questions but they are of zero help,using bulk email services also require having a domain name
I have a model with a nullable boolean field that I'd like to have serialized in a way that converts null in the output to false. My model: class UserPreference
I have these 2 models in my models.py class Student(AbstractBaseUser): date_of_birth = models.DateField(null=True) phone_number = PhoneNumberField(null=
I need to filter API response based on URL parameters that both exact match and also the substring of the parameter matches in Django. The API call would be : "
What is the best way to manage groups and permissions with django-rest-framework API endpoints? I want to have all functionalities that admin panel has to manag
I'm using django as a backend for a React frontend, and deploying both applications on Heroku. I also use Gunicorn do serve the application and signed the Hobby
By default, rest_framework's TokenAuthentication uses the "Authorization" key in the header, and looks for the keyword "Token" when authenticating requests. Aut
I am building an application with a DRF/React stack, and I have a bit of an issue. I am using a HyperlinkedModelSerializer to be able to easily make a GET reque
I have these 2 models in Django: class Invoice(models.Model): id = models.UUIDField(primary_key=True, default=uuid.uuid4, editable=False) owner = model
class User(models.Model): user_id = models.CharField(max_length=255, unique=True) mobile = models.CharField(max_length=12) first_name = models.CharF
I'm trying to add a custom field with some special constrains in DRF serializer. Following are 2 sample models: class ModelA(models.Model): field1 = models.