Data dodania Pytanie
2017-03-31 01:03 Django - Tag inside a Template tag »
So I'm using the django-jcrop plugin to crop an image. Inside my HTML file I have this line: <img src="{% cropped_thumbnail order 'cropping' max_s...
(1) odpowiedzi
2017-03-30 20:03 Why python datetime replace timezone is returning different timezone? »
I am working on Python/Django project. I am trying to let user select date and time using jQuery plugin datetimepicker add-on. So when I select now op...
(2) odpowiedzi
2017-03-30 16:03 Django: How to limit_choices_to when using custom intermediate table »
Let me start by saying that I am working with a legacy database so avoiding the custom intermediate table is not an option. I'm looking for an altern...
(1) odpowiedzi
2017-03-30 12:03 How to fill the variables in html template in django? »
I want to pass "name" to html file and get the response instead of rendering the page. I want to send this html page via email after adding the "name"...
(1) odpowiedzi
2017-03-30 02:03 403 error code when using axios.post to Django endpoint in React app »
I am getting a 403 when I try to make a simple post request to a django view from within my react app. Here is my code: views.py @csrf_protect def t...
(0) odpowiedzi
2017-03-29 19:03 Is it possible to use Django-Admin editor/interface outside of the admin? »
I have a model that I need to edit. I have it registered in Admin.py. It works fine in my admin. How do I use this particular editing interface in oth...
(0) odpowiedzi
2017-03-29 11:03 Return django validation errors in JSON format »
Suppose I am building a registration/signup or any form in general for my web app in Django and I want the same form for Web/Android/IOS. So I want th...
(1) odpowiedzi
2017-03-29 10:03 How to create a queryset that filters multiple fields based on a single condition in Django? »
My model is class TestModel(models.Model) field1 = models.IntegerField() field2 = models.IntegerField() field3 = models.IntegerField() ...
(3) odpowiedzi
2017-03-28 19:03 How to get data from database inside DataTables upon custom filtering? »
I am using DataTables for my tables in my Django project. Now, Its like the following: There are Organizations (a separate Organization model) Each ...
(0) odpowiedzi
2017-03-28 14:03 How to create virtual env with python3 »
I am using python 2.7 + virtualenv version 1.10.1 for running myproject projects. Due to some other projects requirement I have to work with other ver...
(5) odpowiedzi
2017-03-28 12:03 "Apps aren't loaded yet" and "django.core.exceptions.ImproperlyConfigured" in Django? »
This is the directory structure of my Django project. When I am running python code of importing a model:from scraping.models import LinkVendorStand...
(1) odpowiedzi
2017-03-28 09:03 Embedded authentication + LDAP user verification in Django. How to? »
Intro Django version: 1.10 Python version: 3.5.2 I'm trying to implement an authentication based on a LDAP condition and I can't get my head aroun...
(1) odpowiedzi
2017-03-27 22:03 Django in Google Cloud App Engine: ImportError: No module named 'src' »
I'm trying to deploy my Django 1.10 app in Google Cloud App Engine flexible environment but i'am having the following error: ImportError: No module n...
(1) odpowiedzi
2017-03-27 21:03 How to combine django "prefetch_related" and "values" methods? »
How can "prefetch_related" and "values" method be applied in a combination ? Previously, I had the following code. Limiting fields in this query is ...
(0) odpowiedzi
2017-03-27 20:03 Linking Django project to existing MySQL database in EC2 instance »
So I've created an android app who's backend is stored in a AWS EC2 instance. I am now creating a website using Django and I would like them to share ...
(1) odpowiedzi
2017-03-26 23:03 How to write a stand-alone Python script working with Django modules? »
In PyCharm, I created a blank new Django app. Having created some models and issued manage.py makemigrations and manage.py migrate, I tried to write a...
(1) odpowiedzi
2017-03-26 21:03 Django: Get user's previous anonymous session key on login »
In a django app, I'm trying to associate sessions for anonymous users to the new logged-in session for that user when the user logs in. In other words...
(1) odpowiedzi
2017-03-26 17:03 After deploying django in AWS EB its not working similarly as it runs in localhost »
This is how Admin page works in local host This is how its showing after deploying in AWS EB can i get help on this like how to get it normal or ho...
(2) odpowiedzi
2017-03-25 20:03 Django, cannot import name ~~ Error, but i cant find why it is »
app1 : title // title.models.py from django.db import models from relationship.models import ContentRelationship from django.contrib.auth.models impo...
(1) odpowiedzi
2017-03-25 14:03 django-recommend not running the crontab »
I have set the RECOMMENDS_TASK_CRONTAB = {'minute': '*/1'} in the setting , so this should repeat this every 1 minute. And its not working, Any one wh...
(1) odpowiedzi
2017-03-25 03:03 Django - Issue having two different forms within one view and calling functions »
I have two different forms which I want to display in one view. When I have something like the following then the form will go through and the informa...
(1) odpowiedzi
2017-03-24 20:03 Aggregation of an annotation in GROUP BY in Django »
UPDATE Thanks to the posted answer, I found a much simpler way to formulate the problem. The original question can be seen in the revision history. ...
(3) odpowiedzi
2017-03-24 16:03 How to invoke a Django function without redirecting to a new page? »
I am working on bookmarking of articles. I want to add the article in bookmarks when a button Add To Bookmarkis clicked. Using Django, the conventio...
(1) odpowiedzi
2017-03-24 14:03 Django : ModelForm with conditions »
I'm trying to create a form variable. As default Player have the level 0 and he can just change is name. Later when he is level 1, he can change is na...
(3) odpowiedzi
2017-03-23 23:03 Foreign Key Not Setting On CSV Upload -- Django »
When importing csv to django the foreign keys are not setting. May code may be wrong. I am able to import the foreign keys but I am not able set them ...
(1) odpowiedzi
2017-03-23 15:03 Python scripts that runs every minute without stoping »
I have a Python script that sends a post request to my API every 1 minute: while True: data = requests.post("URL_HERE", json={ "api_key":...
(3) odpowiedzi
2017-03-23 15:03 How to access http array parameters in Django? »
SCENARIO 1 The following are my http request parameters PHP REQUEST: localhost/test.php?cars['key_1']=Saab&cars['key_2']=Audi If I do a print...
(1) odpowiedzi
2017-03-22 14:03 Class decorator to apply method decorator on all inherited class method »
I have several classes that inherit the same class. What I want is to have a class decorator on the base class who add an other decorator on all metho...
(0) odpowiedzi
2017-03-22 10:03 django 1.10 csrf_token not creating hidden input field »
I have a form, but Django is not creating a hidden input like - <input type="hidden" name="csrfmiddlewaretoken" value="80NGejzAPl2aCbEEuyLqIT3ppM...
(0) odpowiedzi
2017-03-22 08:03 Django - Rollback is not happening when exception raised »
settings.py DATABASES = { 'default': { 'ENGINE': 'django.db.backends.mysql', 'NAME': 'diva', 'USER': 'root', 'PASSWORD': 'admin', ...
(1) odpowiedzi
2017-03-22 05:03 Custom query filter in django admin »
Here is my models code: class Quote(models.Model): """Quote model.""" quote_text = models.TextField(unique=True) author = models.ForeignK...
(1) odpowiedzi
2017-03-21 21:03 'tuple' object has no attribute 'get' »
I am new to Django framework and I am trying to perform the Django authentication views but i keep on getting this error C:\Users\Harsley\bookmarks&g...
(1) odpowiedzi
2017-03-21 20:03 How can I make it so different clients load unique rows each time (non-overlapping), without making user login sessions? »
I have an app built in Django whose purpose is to be able to allow the user to customize a specific column of a database. Here is the current basic fu...
(1) odpowiedzi
2017-03-21 19:03 CSRF token missing or incorrect, when sending request across 2 different apps »
I am new to django, I am sending a form data from my index.html(1st app 's template) file to accounts app's(another app) views.py index.html - app01/...
(1) odpowiedzi
2017-03-21 04:03 Can this result in a deadlock in django + postgres? »
I have two simultaneous processes that run separate transactions that eventually gets to the same code path: @transaction.atomic def myFunc(): o...
(1) odpowiedzi