Sagar
Using django
Sagar
When they entered employee id, they want to see all data related to that particular employee
Sagar
I am fresher, i dont know how to achieve it
Sagar
Please help me
Андрей
Using django
Using python
Sagar
Yeah
Sagar
In django framework
Anonymous
How to read external csv file in django?
just use the csv package then, instead of using models you would just work the csv reader object
Bwaks
Hello am using bootstrap 5 no jquery ........ I wanted to ajax my form ......am using django form ...and class based view... And I could not find a tutorial on how to by .........please if you have come across one please share me the link
Nitikesh
I have two django projects, I am trying to import a model of one project in the views.py of other project and unable to do so. Help me sort this problem
Nitikesh
The model is in other django project not in the app
Nitikesh
If it would be in the other app, i would have just write from app_name.models import model_name
Anonymous
Just create a model with a integer field, accept a choice from 1 to 5 Connect with a FK that model to your Article model
Hey... anyone please provide python developer experinced resume with project description and summary. And also project git repository
tushar
Hello 👋 I want to send two models data on template it's my function class CrudView(ListView): model = Excel_data template_name = 'excel_upload.html' context_object_name = 'users' How I send this
tushar
Actually
tushar
class CrudView(ListView): model = Excel_data template_name = 'excel_upload.html' context_object_name = 'users' #context object send data to template def get_queryset(self): id1=self.request.user return Excel_data.objects.filter(id_id=id1)
Anshu
https://github.com/anshuUnity/QuestionandAnswer/blob/second-branch/querstion_and_answer/preciousLife/blog/views.py This link has everything u need
Прекрасное
hello everybody, question for the knowledgeable docker
Прекрасное
i get error ImportError: cannot import name 'JSONField' from 'django.db.models', in the docker terminal shows that the jungi version is 2.2.6, although in the dockerfile I indicated 3.2.5, if i write python3 -m pip install -U -I django, then I get this error ImportError: Couldn't import Django. Are you sure it's installed and available on your PYTHONPATH environment variable? Did you forget to activate a virtual environment? and I need to stop, delete images, then compose up so that the docker terminal appears and I get again 'ImportError: cannot import name' JSONField 'from' django.db.models’, such a cycle turns out
Прекрасное
I've been trying to fix this for a week now, please help
Nayan
How can i use @user_passes_test decorator with ajax view ??
Nayan
Ex @user_passes_test(xyz, login_url= '/forbidden/') Def ajax_view(request): If request.is_ajax(): Code Return jsonResponse()
Anonymous
Hi I want to create a email warmup tool in django Has anyone worked on this before ?
Yogesh
Hi I want change my website language how can we do using Django and also translate models data . Please help.
Ruslan
Guys, hello everyone. a question. I register through user and then expand the model with 3 fields of a photo and two text fields. It registers well, but then when I edit the account through the model extension, it displays a strange error. I rummaged through the internet and found nothing, so I decided to drop it here. Thanks in advance. There is a traceback inside and files https://pastebin.com/NCUkVxaq
Saurabh
Hello everyone, I have one question, I want to show location of address given by user on map in my webpage and so how should I integrate Google maps api and how to display map with pointing the location Thank you in advance!
Karthick
how to pass a onetoone in url django
Guru
I have created an view and defined in url but if I open as directory name it works eg login but if I open like login.html it's not opening can any one help
Guru
URL name
Optimus
URL name
dm me , may be i can help u
Optimus
URL name
hope your issue solved
Guru
@bhikhu_mahatre Yes, thanks for your support and help
yusof
Hi I want change my website language how can we do using Django and also translate models data . Please help.
Thats easy you can search it You should use Gettext and gettext_lazy Import them from Django.utils.translation But search it because there is a lot of work you have to do
Optimus
Hi I want change my website language how can we do using Django and also translate models data . Please help.
Follow the django documentation, everythings about languages already there https://docs.djangoproject.com/en/3.2/topics/i18n/translation/
William
Any example do you have so that i can understand ?
Check-in google and StackOverflow how to create a custom permission class
Alexey
Hi, I need save client public key (ssl) into database (not filesystem, because using cluster) For using BinaryField with Admin form find this solution But when I try to save the object again, I get the error "Required field". That is, despite the fullness of the field, an attempt is made to erase the binary field data.
𝕯aniel
Hi I want change my website language how can we do using Django and also translate models data . Please help.
For model use model translation. For text in html use i18n tag {% trans %}
𝕯aniel
For switch lang use form
𝕯aniel
For etc translate use get_text
Karthick
I want get value from URL to views.py that value and I want store that value into my database
Karthick
But the models field in onetoone relationship
Karthick
Any one please help me
Neeraj
I want get value from URL to views.py that value and I want store that value into my database
Urls.py Path("student/<int:rollnumber>",views.studata) Views.py Def studata(request, rollnumber): Print(rollnumber) Return render HttlResponse("ok")
Anonymous
In student folder urls.py from django.contrib import admin from django.urls import path urlpatterns = ( path('admin/', admin.site.urls), path('',include('account.urls')), ) ———————————————————— In account folder urls.py from .views import RegisterAPI from django.urls import path urlpatterns = [ path('api/register/', RegisterAPI.as_view(), name='register'), ] error : path('',include('account.urls')), NameError: name 'include' is not defined
Anonymous
please help me
💙
Hello experts, I got a syntax error (In models.py on app folder... *from django.contrib.auth.models import User* <-- in this line highlighting for syntax error) As I'm learning in youtube so can you please fix this error for me!
Anonymous
what is include here?
for including urls.py from account folder
Maxim
for including urls.py from account folder
and where is the corresponding import?
Maxim
Optimus
thank you .. I will check
or Dm me may be i can help you
💙
add a space before *
I'm sorry, actually * is not a part of the code, I've highlighted the impot line with * for your better understand for my question..
💙
I never do that sir but same syntax error is showing my screen
Doragonsureiyā
I never do that sir but same syntax error is showing my screen
Please provide a full explanation including all the details that you consider relevant. Your statement is too broad and there is no clear way to answer you, you have to explain: - what you're doing - what you're expecting - what you're using - where you're running the script - what Python version you're using - what packages and their versions you're using - and the most important thing: show the code YOU wrote (read rule 5️⃣ for that) and more details, that way your chances to get help will increase
💙
then this correct only
I'm using visual studio code sir, so is that ok for me
ɱαɦαɳ
Hii guys i have a question Could not spawn process for application The application process exited prematurely. Passenger_wsgi.py is set and its in the same folder as manage.py
ɱαɦαɳ
Whats the problem then error is Could not spawn process for application The application process exited prematurely.
Morteza
and your project structure
Hian
Hi, I can change settings each request ?
Enock
Hey guys. Can someone kindly advise the minimum requirements to host a Django project on DigitalOcean. The project is basically managing orders of customers and payment information plus generating invoices/receipts in pdf. Customers are less than 200. They are not the users of the project. Total users of the system will be about 10. Thanks