Questions tagged as 'django'

0
answers

update django version of a project

What is the correct way to update the python and django version of an old project? generate a more updated virtual environment and correct the errors that are generated by the version change? I'm really new to the subject, thank you in advance....
asked by 10.10.2018 / 14:35
0
answers

Form Django ImageField edit delete checkbox

I'm in a Django form and I want to modify the automatic checkbox that comes out in an ImageField field. The problem is the following: The box to clean the saved image appears on a top line, and what I want is to appear next to the word...
asked by 14.09.2018 / 09:14
0
answers

My trigger does not work

I have a problem with a trigger in postgresql, its function is to perform an update on a field of the same table in which I insert, because that field can have different values, it is understood that this field is a nomenclature of a document, i...
asked by 29.08.2018 / 07:19
0
answers

Error when I try to assign a value to a key in a dict Python-Django

I'm doing a function and I'm taking out values from the request. I made a response variable which has 3 nodes to fill. This is the function from django.http import HttpResponse as hres import json def go( req ): res = { 'success':...
asked by 28.08.2018 / 22:54
1
answer

How to Choose Grupo django when registering

I would like to know how I can choose the group to which the user belongs when I am creating it, at this moment I can only create users but not define the group to which they belong. VIEWS.PY class RegistroUsuario(CreateView): model = Use...
asked by 10.08.2018 / 23:19
0
answers

pyodb package connects to SQLSERVER 2008 and does not get data

I am working with python 3.5.4 and django 1.11.13 install pyodbc and pyodbc-azure, it connects but it does not make any sql, here I put an image of the code and the debugging with the answer , also probe with 'DATABASES = { 'default': {...
asked by 15.08.2018 / 16:51
1
answer

Multiples data bases with django

Hello, I am trying to use several databases I have followed the documentation and several examples that I have seen but the models dissected by the router that I created are not created in any database. class dbRouter(object): """ A router...
asked by 01.09.2018 / 21:51
0
answers

show a field knowing its name in a django template

if I have a "person" model with a "name" field to show the field in a template I use {{person.name}} But as it is done when I have the name of the field in a variable. For example: nombrecampo='nombre' {{persona[nombrecampo]}}...
asked by 30.07.2018 / 15:38
0
answers

How to execute function in an interval?

I am trying to execute a function in the background every 5 seconds in which I check the data of an object and modify it. I have found this form (see code) but I can not get it to run when I deploy the Django server. Code import threadin...
asked by 20.07.2018 / 12:18
1
answer

Validate events and visualize at the moment in full calendar

I have a reservation calendar. The problem I have is the following: with a URL and a view I keep the events. to show the events I have another URL as a view for it. And what I want to do is to save the events that can be shown to me in the sa...
asked by 02.08.2018 / 06:59