Anonymous
Guys, How much time do you managed to master django?
Anonymous
But how much time you learned being good at django
Anonymous
okay, but do you how much time it took?
Nanavel
i know basic knowledge of python.. How to start django?
Mirco
Nanavel
Nanavel
I need Any video tutorials link...
Anonymous
Shiva
Hi everyone,
I want to build 2 API endpoints.
1. It returns 5 products details
2. Returns product ratings more than 4*
How can I build this, please help me.
Any help would be appreciated. Thanks in advance
Gil
Shiva
Gil
Search on google, medium, djangorestframework, or if its to much complicated, do function based views
Shiva
Nayan
Hi guys i want to build inventory management system. From where i can keep track on parts and create purchase order . any suggestion how can i start ??
Kirill
Hi, for example i have a few models
class Parent:
api_key: str
class Child:
parent: fk (related_name='children')
status: str (new, old)
I need to write a view that take api_key from GET request and find all children from parent with that api key. Return this as children :[
{ id: 0},
{ id: 1}
]
what the most generic way to do this?
Kirill
I try to do with generics.ListApiView but i don't know how to write serializer
Kirill
If i do that with ModelSerizlizer it returns just
{
{id:0}
{id:1)
}
i mean without name of field
Mirco
look for relationships into the official docs
Kirill
look for relationships into the official docs
yep, i did, but it still doesn't work. I mean i do that:
class SerializerChild(ModelSeriazlier):
class Meta:
fields = [id]
class PSeriazlier(BaseSerializer):
children = SerializerChild(many=True)
it works, but it doesn't return as
children [
{id:0}
]
Kirill
It returns without name of field
Baku
Hello. how to fix this?
nginx: [emerg] open() "/etc/nginx/sites-enabled/frienly-octo-memory" failed (2: No such file or directory) in /etc/nginx/nginx.conf:62
nginx: configuration file /etc/nginx/nginx.conf test failed
Baku
Shijin
Helo
Shijin
When iam make migration in django
Shijin
It shows some error
Shijin
Any plz help
Anonymous
Error?
Mirco
Kirill
Kirill
I think do it in serializer - bad idea
Amit
Hey guys I have a doubt in django I have created and file upload button using forms now I have to add java script to that button how can I add javascript to it any idea ?
VIJAY
KtrlS
Hi folks, I'm trying to configure my apache server to serve a django application but I'm unlucky.
This Apache server is running to serve others site (a nextcloud instance and a Joomla instance) and works fine.
I have to add a new django site.
I tryed with these steps (http://www.tobiashinz.com/2019/04/10/apache-django-virtualenv.html) but when I access to the page the server responds with a 403 error page (Forbidden)
Mihir
can i merge an existing django project's database to postgres?
Anonymous
Yew
Anonymous
Just take Backup and push it in Postgres.
Anonymous
I did it 3 months ago when I migrated my project.
Anonymous
I assume you are trying to Sqlite3 database to postgres.
Mihir
i took the backup using run-syncdb . it created a json file. now when i loaddata - unicodedecodeerror popped up
Anonymous
I have no idea for unicode error.
Mihir
i had already applied migrations while using sqlite. shall i delete the migration files which were created back then?
Caesar
hi there. i have some problem with importing csv files into my models. I got this error
Imported file has a wrong encoding: 'charmap' codec can't decode byte 0x98 in position 388: character maps to
i already checked encoding. And i tried to importing my csv file which i created myself. That works, but after somebody send me terms of reference
i got error. What should i do?
Caesar
Rishu
What is include in django we use for url
Shubham
Include in Django is used to add application level url at project level url
Shiva
Please help
Taku
I have a problem
Taku
I have placed a form
Taku
I want to view data saved in form after adding
Taku
In the same page
Taku
After submitting the form
Taku
First I should see the data in above ,below it I have to able submit new data below
Taku
Like in chat
Taku
Qpp
Taku
App
Kirill
Does django have modern way to return file in response?
Taku
I don't know much
Taku
Iam newbie
Kirill
Taku
I don't know
Taku
😓 sorry
Anonymous
Shiva
Mirco
!paste
Doragonsureiyā
To share code or error tracebacks please use an online pasting service, here is a list of suggested sites:
- https://del.dog
- https://dpaste.org
- https://linkode.org
- https://hastebin.com
- https://bin.kv2.dev
Shiva
Shiva
views.pyhttps://del.dog/pruvupugne
Shiva
urls .py https://del.dog/azonulubyt
Shiva
i need to filter top rated (4* or above) in api