Questions tagged as 'django'

1
answer

Files limit per folder - Django 1.7

Does Django 1.7 provide any upload control mechanism per folder? I say this because when the number of files in a folder gets too large it tends to slow down. An example would be: Every 800 files in a folder, a folder is created at the root o...
asked by 27.03.2015 / 11:33
1
answer

Django - Error saving to Database

The data is not being saved in the Database and Django is not generating Error, but when I create an object of Livro and try to save by the shell it returns me the following error:    ValueError: invalid literal for int () with base 10...
asked by 13.05.2014 / 22:50
0
answers

Django admin use the request attributes

I'm developing an application in Django and have used the request data in form to validate some fields. For example, if the user who is changing form is from the "Administrator" group, changing the user's password does not have...
asked by 12.08.2018 / 17:22
0
answers

Error trying to disconnect using social-auth-app-django

Good afternoon guys, I am building an application in Django, where it is necessary for the user to authenticate through his Microsoft account, for this, I am using the social-auth-app-django / strong>. Authentication is occurring normall...
asked by 29.05.2018 / 23:55
2
answers

How to use the Django User part in a model?

I'm doing a blog and the question has arisen, how can I use the Django user system to make a ForeignKey in my author variable? from django.db import models class Category(DatastampMixin): name = models.CharField(max_length=20) acti...
asked by 15.03.2018 / 01:34
1
answer

Click the Save and change Boolean Django 2.0 button

Gentlemen, I'm studying Django 2.0, and I'm having a problem, when I click Save I want to change the Boolean database from False to True in the database, and I do not the slightest idea how to do it. If someone can help me? Follow summ...
asked by 18.08.2018 / 16:51
0
answers

Problems Elements / Images in Selenium Django

I'm having some problem with elements not loading properly on the ChromeDriver page using selenium in my Django application. I dumped Django's testing tool because in my scenario, I need the whole loaded database. And doing a load fi...
asked by 26.06.2018 / 18:28
1
answer

How to pair two queries using Django Filter

I was breaking my head to make union of two queries using Django Filter and ended up doing it on the same hand ( Model.objects.raw("SELECT....") ). How could I do union with Django's ORM? Note: I have 2 different tabl...
asked by 14.12.2017 / 21:44
0
answers

Project Structure in Django

I installed Django in a project and would like to leave the folder structure somewhat similar to Laravel. I can organize myself better like this. But I do not know if it's possible using such a framework. I would like this: PROJETO --- venv...
asked by 27.12.2017 / 14:27
2
answers

Static files in Django

Oops, I can not load static files. Thestaticfolderisinthecoreapplication,IalsotesteditwiththerootprojectandalsodidnotgetitImadeatestindexfile:{%loadstatic%}{%static"assets/css/bootstrap.css"%} <link href="{% static "assets/css/bootstrap....
asked by 11.10.2017 / 21:01