Arbeit
how (if its possible) can i add buttons to the browsable api (two buttons for extra actions in my viewset)? what i think about is two extra buttons next to the red delete button and the blue options button that take the action name.
i'm using django rest framework and the browsable api. i have a view with two extra actions in my viewset, that can be used with POST to save and resume something:
- "resume": POST /lab/{id}/resume
- "save": POST /lab/{id}/save
Shubham
Arbeit
a look into the browsable api showed me that i can implement get_extra_action_url_map, but than the call is GET and not POST
Arbeit
V
Randy
Does anyone have an example of using select2 or select3 with Choicefield?
Enigma
Enigma
Mirco
Doragonsureiyā
tnx❤️
You're welcome! 😊
Arbeit
Anonymous
Enigma
Zey
Can we generate pdf using Django
Doragonsureiyā
Sopan
Maset
How can we set default media_storage as FTP server storage?
Zey
Yes...many ways to do
Tell me then and actually that pdf will contain some user details so details will come from database
Zey
Harsh
Anyone know of best resource to learn advance django topics?
Harsh
Any other resources other than that
Enigma
is here anyone who used Payeer api in djngo?
Doragonsureiyā
is here anyone who used Payeer api in djngo?
Don't ask meta questions like:
"Any user of $x here?"
"Anyone used technology $y?"
"Hello, I need help on $z"
Just ask about your problem directly! With ~90,000 people here, the probability that someone will help is pretty high.
How to ask smart questions: http://catb.org/~esr/faqs/smart-questions.html
Enigma
Deepanshu
Deepanshu
Deepanshu
hi guys
In which line exactly you are getting error??
Anonymous
How get data from model object specific data
Anonymous
For suppose I three think model
Anonymous
To_city, from_weight and weight
Anonymous
In hrml I wrote get method, get from model, get not render from view
Anonymous
If any know suggest me
Anonymous
Can anyone please tell me how to load my barcode as a image to a pdf after I generate with python-barcode.
Anonymous
I would appreciate it, I am stuck after a lot of searching
Anonymous
Yes i did that but it isn't rendering
Anonymous
When i debug my image as a b64 comes with b'.....'
Anonymous
And i thinks the b' is the problem
Anonymous
But by geting it as a image[1:len(image)] it doesn't remove the b'
Anonymous
Just did it one min ago, but thank you very much
Anonymous
It worked tho 😋
Inuk
huh, epic
Jon
Does anyone know how to resolve 'Request' object is not callable?
Anonymous
Hi
Anonymous
How can I submit a code for someone to help me understand the logic?
Anonymous
Here I think it does not allow to send code.
Inuk
Anonymous
https://nekobin.com/movimacoxa
Anonymous
https://nekobin.com/manedizama
Anonymous
The first link is view.py and the second is forms.py
Salima
Hi...please I need help implementing social media login with jwt...can anyone help?
DefiAnt
Agent Q
Ninu
It shows no database file found when I drag my db. Sqlite to db browser why? Also db sqlite have a blue question mark on it can anyone help me to fix this 🙏🙏🙏
Maset
https://github.com/jschneier/django-storages/blob/master/storages/backends/ftp.py
I have use above module for django default storage(FTP storage)
The files are uploading and can be edited and deleted
But the files like images, videos are not displayed on website
Anyone knows whether to specify something else like our ftp Storage details somewhere to display these?
Rushabh
Hey is that anyone working with django watermark.?
Anonymous
Hello guys. Help Please for "Role based permission for use djoser library"
Let you send related articles or books
Thanks
Idk
Idk
وحید
Hi there . i reposte my problem from django users maling list. please help me . code is as follows:
models.Classroom table have just one record.
# THREAD 1
school_classrooms = models.Classroom.objects.select_for_update().all()
with transaction.atomic():
list(school_classrooms)
time.sleep(10)
# THREAD 2
classroom = models.Classroom.objects.first()
classroom.name = 'somename'
classroom.save()
thread 1 starts. then thread 2 starts to update the only Classroom record but because the record locked by table 1 , is will wait 10 seconds . then thread 1 releases the lock so thread 2 starts to update and exits with no error. surprisingly thread 2 didn't do anything at all and the Classroom record does not updated . How is is possible and how to solve that ? please help. thanks
database: Postgres in docker / latest version
django: django 3
disclaimer: thread 1 performed with a postman request to my api and thread 2 performed by django shell.
Rocky
In django.... I have navbar.html file... In that I am making dynamic navbar ... So I am getting error can anybody help me.... Error is when I am writing code in anchor tag ...error getting tag start is not closed....
Mr
TemplateSyntaxError at /movie/1/
Invalid block tag on line 21: 'favourite'. Did you forget to register or load this tag?
Request Method: GET
Request URL: http://127.0.0.1:8000/movie/1/
Django Version: 3.1.7
Exception Type: TemplateSyntaxError
Exception Value:
Invalid block tag on line 21: 'favourite'. Did you forget to register or load this tag?
Mr
can anyone help me with this error
Mirco
mhamed
Hi
mhamed
Iam use django class based views but in detail pages i have error page not found why this error or anyone get the same error
Enigma
mhamed
1min
mhamed
Views. Py
from django.views.generic.detail import DetailView
class TaskDetail(DetailView):
model = Task
mhamed
Urls. Py
from .views import TaskList, TaskDetail
path('task/<int:pk>/', TaskDetail.as_view(), name='task'),
mhamed
And i have in my templates
Task_detail. Html
Enigma