Questions tagged as 'django'

1
answer

Filtering models in Django view

Talk Galera I have the following app running in Django 1.6. when clicking on dog or cat the idea would be to present a page doing the filtering of the object The animal is modeled thus to filter: TIPO_CHOICES = ( (1, 'Cacho...
asked by 12.04.2018 / 21:03
1
answer

How do I display variables on a django page?

I am new to django and am taking some information from a web page using lxml. I would like to know how I can display the values on my web page. import requests from lxml import html from django.shortcuts import render def list_data(request):...
asked by 18.04.2018 / 23:09
1
answer

Django 2 nonexistent Template

In my project I have a project with 2 apps. The first app is learning_logs that has a template, base.html The second app is users, I'm trying to use the learning_logs template in users as follows: {% extends "learning_logs/base.html" %} It...
asked by 20.04.2018 / 00:47
2
answers

How to open a screen with pre-filled form with HTML?

I would like to know how to open a form whose fields are already filled in with user data (resulting from a search in the database), and it is up to the user to only edit the information. I am using Django to program, I was able to do...
asked by 11.04.2018 / 19:00
1
answer

Is it possible to migrate a web2py system to django while maintaining the same database?

Is it possible to migrate a web system in production made in web2py to a redone in django while maintaining the same database? Home I'm having a system done in web2py (in production) and need to redo it in django , keeping the same database...
asked by 10.04.2018 / 19:30
0
answers

Make template of a directly raw query and return results in table

Hello, I'm new to django and I'm using a read-only database and I just want to extract some data and table display in hmtl, but I'm not able to return column by column inside the table, help me! I'm using a directly raw query! Model.py from...
asked by 10.04.2018 / 15:51
1
answer

Changing how forms.ValidationError is displayed in django

Good evening, is it possible to change how ValidationError is displayed? I noticed that django creates a <ul> tag and inside it a <li> tag with the error. Can I change the way this is done? And if I wanted to change the...
asked by 10.04.2018 / 01:06
0
answers

help with listview Django

I need help getting the values of an object in a list view class Compraslist(LoginRequiredMixin, ListView): model = Solicitacao template_name = 'compraslist.html' def get_context_data(self, **kwargs): context = super(Compraslist, self).ge...
asked by 03.04.2018 / 14:17
1
answer

Multilingual website

I'm trying to put a Python / Django site as a multilanguage, but I could not understand how to actually do the documentation or what I found on the Internet, I even found one here in StackOverflow itself and I did not quite understand it either....
asked by 03.04.2018 / 14:36
1
answer

How to edit something saved in the database in Python

I need to search for a student by name or cpf that is saved in the database and retrieve that same student in a form so that you can edit it and then be saving again. I'm using Django as a framework. I've already done an html by creating the sea...
asked by 29.03.2018 / 18:49