Questions tagged as 'django'

2
answers

What exactly does a --fake migrations in django?

I ran the command python manage.py migrate app --fake and it worked I do not have any errors, but I have no idea why doing this worked and I do not want to keep that gap in the project ... which is what it does exactly --fake.     
asked by 14.02.2017 / 08:15
1
answer

Django.como subtract amount entered minus stock in product table?

I am new to python and it has been difficult for me to formulate a logic for this problem, it is necessary to subtract the amount entered from an article minus the stock that is already in the article table. here the classes: class Pedido(mode...
asked by 09.02.2017 / 22:26
1
answer

Show items from a list linked to manytomanyfield

This is my models.py file from __future__ import unicode_literals from django.utils.encoding import python_2_unicode_compatible from django.db import models from django.utils import timezone import datetime class Jugadores(models.Model):...
asked by 25.01.2017 / 22:09
2
answers

You do not show me the image on my Website

Good, I've been learning django for a short time, my problem arises when I try to load the image associated with an object in the database. {% extends 'index.html' %} {% block titulo %} Jugadores {% endblock %} {% block menu%} {% if jugadores...
asked by 25.01.2017 / 10:17
2
answers

How to integrate the column search engine, above it and not below, Jquery Datatables

very good, I'm using the jquery plugin link which add a select option search engine by columns, which are integrated below the datatable, what I want is that it is shown above next to the search that comes in the plugin, I do not know how t...
asked by 02.03.2017 / 15:21
2
answers

Server Error (500) Django

Hello, I have this error when opening the site I develop in Django, this is my settings.py: SECRET_KEY = '$+(+t#5=etj8+=osa$0v%ouzw%04piwfo!3%b8mli24!s$u6#j' # SECURITY WARNING: don't run with debug turned on in production! DEBUG = False AL...
asked by 16.02.2017 / 04:27
1
answer

How to make a $ scope of location with geodjango, django and angularjs

How to make a $ scope.cities because I do not get it in PHPStorm I get an error of "Expression statement is not assignment or call" and I do not know what the error is /** * Created by gamba on 20/10/2016. */ var app = angular.modul...
asked by 07.12.2016 / 22:48
1
answer

Send the ID of the record that I just created to another template

Good afternoon I'm doing an application in Django 1.10 and I need that when creating a record this sends me to another view with another template the Id of this record that I just created. views.py def datosBasicos(request): #En esta vista...
asked by 15.01.2017 / 20:38
1
answer

Accessing nested elements in a JSON from a Django template

I have the following document JSON { "paciente": { "id": 1234, "nombre": "Pablo Andrés Agudelo Marenco", "sesion": { "id": 12345, "juego": [ { "nombre": "bonzo", "nivel": [...
asked by 29.11.2016 / 05:39
1
answer

Problem installing a django project with virtualenv in debian

I have a problem, I already installed the virtual environment and I already installed with pip django, only that there is a problem when creating the project structure, the following appears: (venv)padawan@debian:~/Documents/Git/landing-page$...
asked by 07.12.2016 / 00:49