Inu
Please why is my static file not showing in my admin dashboard after I deploy it
Yavar kazemi
Hello friends
What is your solution to redirect the user to the Windows application after payment?
Ingvarr
Yo. Can anyone give me some good link where it's talked about how to make docker with django and postgres
cj
Singularity Sikesh
Hii connection,
I am facing app not yet loaded issue while starting django shell and importing models from an app.
Any inout on it is highly appreciated.
Thanks
Anonymous
Hi
Is there anyone khow how can I make the register with phone number instead of usernam
Oluwasegun
Doragonsureiyā
ask
How can I delete User from user table in drf, using DestroyAPIView it doesn't delete user permanently instead it turned is_active flag to false, how to hard delete??
Jimmies San
i mean: literally.
Jimmies San
first thing to learn in IT? how to google stuff.
Jimmies San
it's the biggest skill you can get.
Bhavnish
Hi
I have migrate the database from MySQL to postgresql in django application.
After this django migrations are continuously running in the server.
How can I fix this?
Akash
In my django code, a view is calling get_object_or_404() and is returning list, but i want to return it as dict.
How to achieve it ?
Akash
Basically in response.context i want a dict, but its coming as list
Alexey
Alexey
Alexey
Akash
So my code has a test that I can't edit, it iterates over response.context keys of a view that returns a blogpost detail.
The intention is that view returns dictionary instead of list
Akash
def post_detail(request, post_id):
    template = 'posts/post_detail.html'
    post = get_object_or_404(Post, pk=post_id)
    posts_count = Post.objects.filter(author_id=post.author.id)
    context = {
        'page_obj': post,
        'posts_count': posts_count
    }
    return render(request, template, context)
Asad Ullah
assalam - o - alaikum!
my question is that i have created a project in django but i am now confusing in using function based views or class based views.
which is more convenient.
Mirco
Asad Ullah
Akash
ask
I've added a boolean field to my User model and my project is currently on aws, after adding boolean field on my gitlab deployment my project tests files are throwing error although my tests are not using that newly added field, what could be the reason, any idea pls help!!!
Victor
Tamerlan
Tamerlan
Alexey
Akash
context_data?
Didn't get your point.
Also, ideally response.context is supposed to return Dict right ?
Alexey
Annoy
Anyone please help with django with react js
Alexey
fsociety
hi. how can i create model with secure access key for office?
class Office(models.Model):
name
admin
access key (unique)
Rahat
How to implement twillio api and purchase twillio
Annoy
Hey... I need to create a django website using partical js
Mendux
Hey, devs. I'm trying to collectstatic on an Azure container. I believe I have installed all the required dependencies, but on running "collectstatic" I'm getting the following error:
from Azure.storage.blob import BlockBlobService, ContentSettings
ImportError: cannot import name 'BlockBlobService' from 'azure.storage.blob' (/mnt/data/Documents/projects/django/django_on_azure/venv/lib/python3.8/site-packages/azure/storage/blob/init.py)
I'm trying to figure out what's missing but I can't seem to find a workaround.
Doragonsureiyā
Vaibhav
Vaibhav
切腹
Hello, can someone help me?
I’ve alredy renamed my app 2 times, but the error is stay
python manage.py startapp smoky_app
CommandError: 'smoky_app' conflicts with the name of an existing Python module and cannot be used as an app name. Please try another name.
The Inspired
.
hello
Hello, does anyone have knowledge about Zapier?
Kareem
Is there a Django roadmap?
Charly
𝔸𝟙𝕕𝕪𝕟
Charly
𝔸𝟙𝕕𝕪𝕟
I mean documention on the site?
Anonymous
I am getting value error : not enough value to unapack (expected 2, got 1)
Anyone, how do I solve that?
Frazil
lets make a foroum app in django to discuss about django
Charly
Charly
Frazil
but I cannot track my problems answer or the solutions that I answered
Charly
Charly
But whatever just write them down as notes
Charly
It's not like the vbest idea to go to a forum and ask to make another forum for the same thing
Anonymous
hello guys whats mean: class(Meta): abstract=True i'm beginner pls help me.
Anonymous
hello guys whats mean: class(Meta): abstract=True i'm beginner pls help me.
This code creates a class named "Meta" with an attribute "abstract" set to True.
In Python, the term 'meta' refers to an object that contains information about other objects. In this case, "Meta" may be a metaclass that is responsible for defining the behavior of other classes.
By setting the "abstract" attribute to True, this indicates that the "Meta" class is meant to be used as a blueprint or base class, but it should not be instantiated directly. Instead, other classes can inherit from it and implement their own functionality.
Overall, this code snippet suggests that the developer is creating an abstract metaclass, which can be used as a foundation for other classes.
Сэр Финли
hello guys whats mean: class(Meta): abstract=True i'm beginner pls help me.
Django documentation:
Abstract base classes are useful when you want to put some common information into a number of other models. You write your base class and put abstract=True in the Meta class. This model will then not be used to create any database table. Instead, when it is used as a base class for other models, its fields will be added to those of the child class.
Doc Django https://docs.djangoproject.com/en/4.2/topics/db/models/#abstract base classes "abstract base classes"
Anonymous
Thank you👍
ask
During deployment on gitlab on test instance getting error of database field, I've added a new field in user model but during gitlab deployment getting error, how can we run migrations before deployment on gitlab???
Roshan Rajak
https://dpaste.org/8e0Wf
this tasks don't retry for given exceptions
Mr
Okay
kiran
i have uploaded a video through file field but it is unable to move the video manually
kiran
video_file=models.FileField(upload_to="DATA/VIDEOS",default="",null=True)
kiran
<video class="video-fluid" controls>
<source src="{{les.video_file.url}}" type="video/mp4">
</video>
Edgar
Андрей
Hello 👋
Can someone help me with advice?
I have some websockets with redis and drf, and I have a question what is the best goal to save connected users, room and other information? May be someone have example? Save this users to database is it good way?
Akash