Anonymous
can you help me????
Cool
Code for enterprises in you tube is perfect
Cool
https://youtu.be/VtHrTX_nTto
Anonymous
How can i check if an object is in a many to many field
Anonymous
Never mind I found a solution
Mohamed
Is there a tutorial that show us how to use Django rest framework with mobile (Android or iOS)
Anonymous
Is there a tutorial that show us how to use Django rest framework with mobile (Android or iOS)
I don't get, is it creating a DRF API for mobile or creating an API with mobile phone
Anonymous
Creating a DRF API for mobile
©aptain
Anyone with django + zurb foundation 6
©aptain
Who had worked on it
Meera
i have created a simple hello world saying django app and used a postgres database...that has a model a simple table ...first row value would be printed to root page...like 'hello world, myname' now i want to deploy it on heroku
Meera
i choose the deploy method as github and conntectd my repo to it
Anonymous
Creating a DRF API for mobile
OK, Same way you create web but more user, like for authentication you might not need to use JWT, Auth packages and the rest
Anonymous
https://youtu.be/VtHrTX_nTto
Great video, thanks for sharing
Klim
Hello guys) Do you know how to change my value in model? For example i have xn--h1alffa9f.xn--p1ai in my DB I want to save it in DB like xn--h1alffa9f.xn--p1ai, but in QS i want to see it converted
Klim
Where can i convert it?
Klim
When i call Model.objects.all() i have name field = xn--h1alffa9f.xn--p1ai, but i wanna convert it (NOT IN DB) for QS name. So in DB value should be "xn--h1alffa9f.xn--p1ai", but when i call objects.all() i want to see "россия.рф" for example. Can i define something in models to make this works?
inchidi
where you get "россия.рф" btw?
Klim
I can convert xn--h1alffa9f.xn--p1ai to россия.рф by idna library like idna.decode("xn--h1alffa9f.xn--p1ai")
inchidi
then you can add something like this in your Model class: def name_decode(self): return idna.decode(self.name) (optional) def __str__(self): return self.name_decode()
Klim
And in my QS i will see QS with converted name?
inchidi
m = Model.objects.last() m.name_decode() # will return converted name
Klim
Yes i know it, but can i automate this?
inchidi
And in my QS i will see QS with converted name?
if you override the __str__ function like example i gave
ʚɞÇherry Łoveʚɞ
can I show list migration on django admin?
Jimmies San
can I show list migration on django admin?
idn, but you can use python manage.py showmigrations by cli
ʚɞÇherry Łoveʚɞ
idn, but you can use python manage.py showmigrations by cli
I dont have permisson to access console. I only have source code and want to see what was migrated.
Jimmies San
if you have source code you can check inside the migrations directory. but if you have source code you can buildup a venv/pipenv and launch command too
Anonymous
hi every one excuse me are this setting is ture?(domain names) this is my first try for adding a domain name to my django project
ʚɞÇherry Łoveʚɞ
does it work ?
Anonymous
does it work ?
on server ip(54....)yes
Anonymous
but i set server name for domail and most wait a 24 hours
inchidi
should be fine
inchidi
or you can check your log too for sure
Anonymous
should be fine
thank you dear inchidi
inchidi
or run ... nginx -t
inchidi
how?
tail /var/log/nginx/error.log
Anonymous
or run ... nginx -t
result: syntax is ok test is successfull
inchidi
result: syntax is ok test is successfull
then the log wont show anything, at this point you are fine
Abhi
hey guys i am working on a small project and i am confused
Abhi
suppose you create an app for your django project
Abhi
and call it homepage
Abhi
now to display that homepage you redirect using your views.py but where should i keep the homepage.html,css and js files Also I am using __base.html,css,js as template where do i keep thos
Abhi
*those
Abhi
there are many methods on the internet
Abhi
but the searching directory methods by django is confusing me
@&!
And base.html or others files .html in a directory called template
@&!
You can read more here https://www.djangoproject.com/start/
Shivam Negi
I have completed the basics of django from udemy course can anyone suggest me a starting project
Shivam Negi
Thanks in advance
Abhi
thanks Alejo
@&!
thanks Alejo
👍 your welcome
Django Bot
>> Links - Laragon - portable, isolated, fast & powerful universal development environ
@&!
I have completed the basics of django from udemy course can anyone suggest me a starting project
You should make something that you need .. So there you apply the knowledge
R
https://www.mail-archive.com/python-committers@python.org/msg05628.html
Combot
inchidi has permanently banned Science Explorer!
Django Bot
>> Links - Understanding Django Channels · Arun Ravindran's Blog and Showcase
Django Bot
>> Links - Dockerizing Django, uWSGI and Postgres the serious way
Django Bot
>> Links - Logging Django errors to Slack channels.
Django Bot
>> Links - Markus Holtermann — Django Migrations Recipe #3
@&!
Hey guys.. I have a question, I will be happy with your answers.. what consume less resources gunicorn or uwsgi?
Django Bot
>> Links - Things You Must Know About Django Admin As Your App Gets Bigger - Image optimization decreased website's page weight by 62%
Shivam Negi
Anyone give me link for django e-commerce project ....
Shivam Negi
ok thanks
Mounikesh
guys does anyone have any idea of getting data from another wevsite or source through api in json format and saving thay data to our database models
pino@mastrobirraio ~$
guys does anyone have any idea of getting data from another wevsite or source through api in json format and saving thay data to our database models
https://simpleisbetterthancomplex.com/tutorial/2016/08/29/how-to-work-with-ajax-request-with-django.html
Mounikesh
I hope is usfull for you
yes,related and usefull
Maz
hi, if i have a modelform createview, how do i select all the model fields to be included in the form? is this correct:
Maz
class StaffCreate(CreateView): model = Staff fields = 'all'
Maz
there's a double underscore for fields....
Maz
telegram wont show it though 😅
Mounikesh
yes it is