Aju
.....
.....
.....
it such a models okay?
for example :
video = models.FileField(upload_to='watch/' default)
like this?
.....
.....
but I still couldn't solve this :/
Gabriel
Hello guys, do you know if there is a possibility to use a custom user model in a specific schema and models like content type, admin entries, admin logs, etc in another schema and managed by Django?
D
Hi folks
Is there any package for MFA that can be used with Django rest framework
Charly
Acquaintance
Muhammed
Charly
Charly
It should be 'master.language'
Gunjan
I have created a client management system. In that there is a client information form . And that information display on the home page of all the clients in a table.so there is a one column which has view,edit,delete button. Through this button we can view,delete,edit of that specific client information. So I want to add a new field in the view form which I get to click on view button.and that field is not available in my models.py. how can I add that field in the viewform by clicking on view button. And after that I want to generate pdf of that viewform with included that field .
AIDAR
Hello, I need your help.
Used Django-ckeditor-5. Is there any function or code to remove photos (added with Ckeditor 5) from database when post is deleted?
Jai
Can I get any django video tutorials
Alex
I need help in my project where i use the Pretrained Ai model , i want to know how to handle multiple requests and serve them , if anyone can pls help me
Nikita Goncharov
Muhammed
Could I find any video tutorials for mastering ORM (Object-Relational Mapping)?
Charly
Charly
Alex
Charly
Alex
If my model is running and generating a response , and in that time i make another request, it starts executing new requests and leave before request
Charly
Alex
I just import the file and run it
cj
Bilal
hey guys
i am working on commercial website for a company and they want to have control on their website like changing images and texts so thats why i need backend for it
so now when he wants to change an image or a text then it should change the exact picture that he want and change it permanently and place it in its location i try to use django session for it to remeber the position and the image that he selected but it didnt work
can you please help me??
cj
D
Hi folks
Is Django good for micro services or not
Alex
Not much
...
I want to start with Django and further I want to switch in data scientists any one suggest me road map or project
Koen de
...
Damir
Никайтос
Hello!
I have UserFormData model with field completed=False by default. When I set completed=True on UserFormData object and save it, there is a post_save signal that looks like this
@receiver(post_save, sender=UserFormData)
def history_start(sender, instance, created, **kwargs):
"""
Creates a VisitHistory record when the patient finishes filling the intake form.
"""
if instance.completed:
create_visit_history(
client=instance.visit.client,
visit=instance.visit,
text='Patient finished filling the intake form',
value='finish_intake_form'
)
update_case_status_checker.delay(instance.visit.id, CaseStatus.form_filled)
the problem is in this row
update_case_status_checker.delay(instance.visit.id, CaseStatus.form_filled)
when i set completed=True on UserFormData object an save it, it doesn't change the status on the first time, but when I save it once again - that's when it changes the status, so It works only on the second try. I guess, post_save just doesn't see the changes on the first try, but I don't know how to fix it
Luis
Hello!
I have UserFormData model with field completed=False by default. When I set completed=True on UserFormData object and save it, there is a post_save signal that looks like this
@receiver(post_save, sender=UserFormData)
def history_start(sender, instance, created, **kwargs):
"""
Creates a VisitHistory record when the patient finishes filling the intake form.
"""
if instance.completed:
create_visit_history(
client=instance.visit.client,
visit=instance.visit,
text='Patient finished filling the intake form',
value='finish_intake_form'
)
update_case_status_checker.delay(instance.visit.id, CaseStatus.form_filled)
the problem is in this row
update_case_status_checker.delay(instance.visit.id, CaseStatus.form_filled)
when i set completed=True on UserFormData object an save it, it doesn't change the status on the first time, but when I save it once again - that's when it changes the status, so It works only on the second try. I guess, post_save just doesn't see the changes on the first try, but I don't know how to fix it
Maybe you want to update status anyway
Никайтос
< 𝕓𝕚𝕝𝕒𝕝 />
hello i need a course for build first project
i found some courses but i don't like them
please someone send me normal course
🙂
Вячеслав
Hello. I have a strange problem with objects saving.
I have a project with django 3.2, celery 5.12, redis and mysql as database. Also django-cacheops.
I have a post_save signal that calls a celery task (task.delay()). This task takes object instance id as an argument. Inside of the task it gets an object by Objet.get(id=instance_id).
The problem is that sometimes exception ObjectDoesNotExist appears after this query. How is that possible? It happens after post_save, so object must be saved already.
I think of threads race, but I don't know how to check it or how to solve it in general. Also there are several troubles like this in project and I think they all are connected (some models are being saved 2-4 times sometimes, some numbers in models return to previous values after logging a change of value).
Maybe you've had something similar happen before?
Maxim
Вячеслав
is there transactions in your code?
No. I wasn't sure how to implement it right.
Do you think that hypothetically speaking it is possible that thread1 saved model, django called post_save and then thread2 was at the state where the model wasn't saved yet?
Maxim
Qusay
Qusay
Tell us how you solve it if you do!
Вячеслав
Franky
D
D
Yes
D
I am talking why flask not fastapi
KAKASHI
Hello folks
Can you give a useful documentation or video about how to add react on Django
Maxim
clouded
Hello folks
Can you give a useful documentation or video about how to add react on Django
The general answer is to use Django rest framework. But it may be simpler to follow an up-to-date tutorial about it. You should be able to find some using a search engine. Make sure the versions of Django rest framework and react match your versions or you might have unpleasant surprises when following the tutorial. It does not harm to look into how react and the Django restframework work standalone to have a more pleasant and smoother experience.
mea
mahyar
Hello friends,
Have you ever used Google reCAPTCHA version 3 with Django Rest Framework (DRF)?
If so, please send a link to any article, post, or video.
Sam
Mugisho
Hello everyone, i need boostrap videos , how to handle boostrap. For example for creating dasboard and so one. I need to include HTML in templates's folder and CSS , JS in static folder with Django framework
...
What is rest framework
...
Thanx buddy
FORTUNATE
Hi guys,
I'm finding it difficult to insert background image to my django project.
What could be the issue pls
Charly
FORTUNATE
FORTUNATE
And the static file is register in django setting.py
FORTUNATE
Charly
FORTUNATE
Css
Background-image: url('{%static 'images'/logo.jpg'%}):
Folder arrangement
Project folder
Static folder
Images folder
Logo.jpg
Charly
Charly
FORTUNATE
COnsole shows errors, even 404 errors
The error there are error relating to where I haven't add images of which I will add them later.
The error showing are related to html error images.