Firdaus
Django coding structure?
Ghorz
According to fastapi.tiangolo.com FastAPI is a modern, fast (high-performance), web framework for building APIs with Python 3.6+ based on standard Python type hints.
Ghorz
Django coding structure?
DRF CBV is identical to Django CBV
Mirco
I've checked it but in reality, only DRF has django coding structure
Yup, that's why is always cool to use DRF 😊
Ghorz
Have a look also to FastAPI 😊
It's self reliant. Can be deployed just like django or flask. Was specifically built for API services . It's more of a web framework to me. The website states it borrowed it features from django, drf, flask,......
Ghorz
Yup you can deploy it as always Better under uvicorn
If its that way, it will compete with django. Default as async. But I love my django. Its async already.
Mirco
3.0
Not fully
Ghorz
Not fully
But in progress
Ghorz
If django goes full asynchronous, drf will be dead
Mirco
Nope DRF is a Django app
Mirco
If Django dies, DRF will die
Ghorz
😂
Anders (izzno / gooood) 🇳🇴
In these microservice days, my Django app is getting pretty complicated. I don't know if I would do the same all over. Mainly (or only) to get help / set someone in this project is a lot of moving parts.
Anders (izzno / gooood) 🇳🇴
BUT. Major upside = one code base and one set of tests.
Anders (izzno / gooood) 🇳🇴
Not to mention how fast it is to implement new features with a pipeline set up... Never mind I'd do it again 😂😂
Anonymous
Microservices is a fud
Anders (izzno / gooood) 🇳🇴
Delete all your messages and structure your question please. I dont get it.
Anders (izzno / gooood) 🇳🇴
Microservices is a fud
Many large coorporations live by it...
Anders (izzno / gooood) 🇳🇴
It's a good strategy in a large company..
Anonymous
Gigantic
Anders (izzno / gooood) 🇳🇴
*mega
yes...
Anonymous
I hope you are getting the point.
Anders (izzno / gooood) 🇳🇴
I work for a "mega" ;)
Anonymous
Anders (izzno / gooood) 🇳🇴
Anders (izzno / gooood) 🇳🇴
Anders (izzno / gooood) 🇳🇴
;)
Anders (izzno / gooood) 🇳🇴
It's not a tech company, but has 50 000+ employees.
Anonymous
Ok, but I'll suggest keeping your code together Unless it's really gigantic.
Anders (izzno / gooood) 🇳🇴
*primarely tech company
Anonymous
> 1 Million lines of code
Anders (izzno / gooood) 🇳🇴
> 1 Million lines of code
Our out facing apps are at that stage.
Anders (izzno / gooood) 🇳🇴
In house apps are not microservices.
Anders (izzno / gooood) 🇳🇴
But we also do a lot of experimenting.
Anders (izzno / gooood) 🇳🇴
Care to name it?
And if you really want to know Im sure youll figure it out. I'm not that anonymous.
Anonymous
No that interested. Just wanted to know to get an idea.
Anonymous
Bro i would like to study django, I need some references
Suraj
Help me please .. I want to know that deleting row or doing anything in database by creating url link for operation is a good practice ..for example: If I want to delete a row in my events table creating url - "/events/<eventId>/delete" and adding check "current.user == 'admin'" is a good way or there is some better practice?
Андрей
Brother I need ur help😔
Try Django official tutorial and django-girls
Suraj
You can use django-rest-framework and permission classes https://www.django-rest-framework.org/api-guide/permissions/
Sorry this will hurt you .. but I am using flask don't kick me .. I can't use anything fancy like api ..it's a college project .. not so great. All I want to know .. my way is not very stupid. or something dangerous which I can't see.
Suraj
Also ..is there any another way which is better practice but not api or anything very hard.
Андрей
Your way is pretty good. I guess that you can find some flask packages to check the permissions of user, also i heard something about flask-restfull package, but didn't use it, maybe it will be helpfull
Андрей
Also you can check request.method, to provide crud operations instead of creating new urls for every new method
Anonymous
where will i get complete source code of a django project for free
Anonymous
anyone please help me
Anonymous
Github
thanku
Anders (izzno / gooood) 🇳🇴
Anders (izzno / gooood) 🇳🇴
thanku
use at your own risk ;)
Anonymous
okay but i need projects like online Fashion store, online grocery store, online mobile store, online E commerce portal, photo gallery portal etc....
Anonymous
django 2 by example
Anders (izzno / gooood) 🇳🇴
is a book
Anonymous
can u please share me a photo gallery source code?
Mohan
is a book
Can u send prf
Mohan
Pdf
Anders (izzno / gooood) 🇳🇴
I dont support piracy...
Batman
🧐
Remy
This thread is going too fast man 😂
Remy
Things to check (list taken from above chat): - alpine / asgi / daphny (faster?) - test django 3 - tastypie - fastAPI - uvicorn
Surya
I am a naive I am trying to use background image using <div style="background-image: url('{{STATIC_URL}} images/name.jpg') in my html file But this is not working I tried stackoverlow solutions but not helpful STATIC_URL = '/static/' Any possible solutions ?
Mirco
or better not use django for static files
This is a second step, when he needs to deploy
Surya
Okay
Anonymous
seems like your looking for some project for university assignments to showcase as your own?
no... already am completed my graduation. & .. learned python and django.. but i never created a complete website... for a clarity purpose I've asked that
Anders (izzno / gooood) 🇳🇴
Anonymous
Hello
Suraj
I deleted my user but his profile is still there .. there is no cascade in database