Anders (izzno / gooood) 🇳🇴
Okay. Than how can I write save method for MODEL? not for instance
https://docs.djangoproject.com/en/2.1/topics/db/models/#overriding-model-methods
None
It is on instance leve
None
l
Anders (izzno / gooood) 🇳🇴
Isn't the point saving thumbs of the instance you are saving?
None
Isn't the point saving thumbs of the instance you are saving?
To save the instance I need to get that instance.
Anders (izzno / gooood) 🇳🇴
WHEN in the timeline of using your webapp do you want to do this?
Anders (izzno / gooood) 🇳🇴
If you need it arbitrarily, then add a custom method to your custom manager.
Marko
hi, do somebody know how to send file to the server asynchronously, i have tried the following, but it do it only with a text not with files https://pastebin.com/xBefKgC1
John
hira we solved? I make user permissions there
John
hira
John
look this help - you!
Anders (izzno / gooood) 🇳🇴
Wtf?
John
we can add permissions to group
John
nome = name to group
Anders (izzno / gooood) 🇳🇴
Who's talking to whom?
Anonymous
Yess great... but its a whole custom form page or customize the inbuilt group form page.
Михаил
Hey guys! How do I run migrate with script.sh? My venv in the ~/.virtualenvs/project/
Anonymous
1. CD into directory 2. Activate venv 3. python migrate ...
Vichu
Let me 🦆 DuckDuckGo that for you: 🔎 the django material
https://duckduckgo.com/?q=the+django+material&ia=web
Anonymous
from django.http import HttpResponse from django.template import loader from .models import Question def index(request): latest_question_list = Question.objects.order_by('-pub_date')[:5] template = loader.get_template('polls/index.html') context = { 'latest_question_list': latest_question_list, } return HttpResponse(template.render(context, request)) #def detail(request, question_id) # question = get_object_or_404(Question, pk=question_id) # return render(request, 'polls/detail.html', {'question': question}) #def results(request, question_id): # response = "You.re looking at the results of question %s." # return HttpResponse(response % question_id) def vote(request, question_id): # return HttpResponse("You,re voting on question %s." % question_id)
Anonymous
This is my poll/views.py but it dosent display my templates and I don't know why
Modou-dev
he I need to get the old value when I do an update in my views.py ?
None
Hello. How can I save image via such way? inst = ModelName(name=name, image=????) inst.save()
NANDAGOPAL
How can I add another row in purchase form using python
NANDAGOPAL
How can I add header, footer, and sidebar using different files?
Marko
hi, do somebody know how to load file asynchronously to django from html page, it is possible with page refresh but not async, maybe you have some ideas or useful code https://github.com/MarkoKoval/Upload_Files_To_Django
Marko
use django_q or celery
thanks, do you have links to code or so on that could be helpful
Anonymous
Any one have any idea about payment gateway, i need to integrate with my web app.
Anonymous
Which is reliable ?
Mirco
thanks, do you have links to code or so on that could be helpful
django Q celery antoher useful link about django and celery
lew
I have a django project running in productions, in the settings.py I have two allowed host, the last one was added recently, if I restart that computer (the server), that last change configuration is lost. Why is this happening??
Anonymous
have a look to django-payments package
What i meant is any payment gateway such paypal, stripe like that
Anonymous
see django-payments :)
Okayy thank you.
Anonymous
How to convert www.codinghook.com in django
cj
How to convert www.codinghook.com in django
are you the owner oh codinghook?
Clayton
Hello guys! I would like How authenticated my page with user of windows. I need get this user for register in my application
Clayton
Can you help me?
Clayton
I had the similar solution in PHP using authenticated with LDAP. But in Django I not found.
Clayton
Yes, but a not have access admin the active directory
cj
Yes, but a not have access admin the active directory
Let me 🦆 DuckDuckGo that for you: 🔎 django auth active directory
Kabir
https://stackoverflow.com/questions/851628/django-user-doesnotexist-does-not-exist I need solution to this problem I’m using VS code
cj
Chukwuyem wanted to post: https://hastebin.com/yubatacomi
Anonymous
Pls I need ur help guys I can't display my templates
Anonymous
This is my polls/views.py
cj
Pls I need ur help guys I can't display my templates
use render_to_response() or render() functions
cj
but better use CBV 🤷🏻‍♂️
Anonymous
Sorry what's CBV
cj
Sorry what's CBV
Class Based Views
Anonymous
Hmmm how do that
cj
Hmmm how do that
https://docs.djangoproject.com/en/2.1/topics/class-based-views/intro/
Anonymous
But does this that the django tutorials were wrong, because I followed all the steps and it still gives me errors
cj
we are talking about the official tutorial, aren't we?
Anonymous
https://docs.djangoproject.com/en/2.1/topics/class-based-views/intro/
Ok I'll try it. But not now my battery is kinda down
Anonymous
we are talking about the official tutorial, aren't we?
Yes the main tutorial I don't know why I still get errors
cj
Yes the main tutorial I don't know why I still get errors
maybe you're skipping some steps 🤷🏻‍♂️
Anonymous
I'm not tho I'm really serious but I'll check I've gone through it many times still.
Django
Can somebody provide me Some resources to start learning django
Anonymous
Yh u Nigerian too right
Anonymous
Yeah
Cool
Anonymous
So r u a pro in django
Rammy
Anonymous
Oh OK cool
Anonymous
We're u in the tutorial
Anonymous
I'm still stuck on Hw to display views
None
Who's talking to whom?
I solve trouble with creating images. instance=ModelName(title=title, image=none) instance.image.save(“name.jpg”, image, save=True)