Posts by Leonardo Freitas • 143 points
10 posts
-
1
votes0
answers249
viewsQ: How to block user login with certain "status" in Django
I’m using Django 1.11 and class-based views. My user model is customized and in it I have a "status" field where it has "enabled, blocked and disabled". I would like to know how I can allow the…
-
1
votes1
answer500
viewsQ: How to redirect url with argument to another page in Django? (Updateview, Genericview)
Well, I have a very pertinent question. I am with an editing class of Django, and when I edit the user, I need it to call from the detail class of the same (Detailview), the two classes are working,…
-
1
votes2
answers594
viewsQ: How do I test user type and send to different views in DJANGO Generic views
Hello, I have a question at Django. I’m trying to do it this way. My user model has a "level" field, this field has some levels, among them "root", "seller" etc.. However, I would like to know how I…
-
0
votes1
answer258
viewsA: Page does not load elements when updating to Ionic 2
The solution for this milestones, is to use the Ngzone, follows image. If the doubt remains, can contact via Whats: +55 88 9 97295604 Follow code in image…
-
0
votes2
answers1478
viewsA: Menu effect appear slowly css
If it is only in css, try a "Transition: 1s; " where 1s refers to 1 second
-
2
votes5
answers1463
viewsA: Beginner in Python, Else and Elif
You need an if to use an Elif. understand as follows: your code in a form NOT pythonic would look like this: idade = int(input("Insira sua idade:")) if(idade<=0): print("Sua idade nao pode ser 0…
pythonanswered Leonardo Freitas 143 -
1
votes1
answer258
viewsQ: Page does not load elements when updating to Ionic 2
Well I have an app with side menu where the first page is the home, and it loads elements as soon as the user enters the app. I’m using Ionic 2 and communication is being done via socket. One detail…
-
2
votes0
answers162
viewsQ: Heroku does not work after adding dependencies to pom.xml (Maven)
I deployed a java project with Maven, it worked smoothly, but after I put the dependencies in the pom.xml file and push, Heroku no longer runs, not even "hello world". Follows as was pom.xml, then…
-
3
votes2
answers2281
viewsQ: Save a foreign key entity with Hibernate 4
I’m starting to study Hibernate and I’d like to know what the method of saving an entity with a foreign key looks like. The following is an example of two entities: Pupil: @Entity(name = "aluno")…
-
2
votes1
answer128
viewsQ: How to put only Month and Year in Datapicker (Javafx)
By default (by javafx Scene Bilder) comes the datapicker month, day and year. I would like to know how to take the day, and leave only month and year. If you can, thanks!