-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
58 changed files
with
1,757 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
Empty file.
Empty file.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
from django.contrib import admin | ||
|
||
# Register your models here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
from django.apps import AppConfig | ||
|
||
|
||
class AppConfig(AppConfig): | ||
default_auto_field = 'django.db.models.BigAutoField' | ||
name = 'app' |
Empty file.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
from django.db import models | ||
|
||
# Create your models here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,154 @@ | ||
* { | ||
font-family: "Montserrat", sans-serif; | ||
} | ||
|
||
body { | ||
background-color: #021842; | ||
flex-direction: column; | ||
display: flex; | ||
margin: 0; | ||
height: 100vh; | ||
width: 100vw; | ||
} | ||
header { | ||
display: flex; | ||
align-items: center; | ||
justify-content: space-around; | ||
background-color: #ffffff; | ||
color: #004661; | ||
height: 100px; | ||
} | ||
|
||
img { | ||
width: 203px; | ||
height: 58px; | ||
} | ||
|
||
.logo { | ||
width: 100px; | ||
height: 100px; | ||
} | ||
|
||
h1 { | ||
font-size: 18px; | ||
} | ||
|
||
/* estilizacao */ | ||
|
||
.content { | ||
height: 100%; | ||
width: 100%; | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
flex-direction: column; | ||
} | ||
|
||
.footer { | ||
padding: 20px 0px; | ||
color: #8a8989; | ||
align-self: center; | ||
} | ||
|
||
.container { | ||
display: flex; | ||
align-items: center; | ||
padding: 24px 72px; | ||
width: 280px; | ||
flex-direction: column; | ||
flex-shrink: 0; | ||
border-radius: 20px; | ||
border: 1px solid #bcbcbc; | ||
color: #ffffff; | ||
gap: 1em; | ||
} | ||
|
||
.form { | ||
display: flex; | ||
flex-direction: column; | ||
gap: 4em; | ||
width: 100%; | ||
} | ||
|
||
.inputGroup { | ||
display: flex; | ||
flex-direction: column; | ||
gap: 1em; | ||
} | ||
|
||
.input { | ||
display: flex; | ||
flex-direction: column; | ||
gap: 0.5em; | ||
width: 100%; | ||
} | ||
|
||
.button-submit { | ||
color: #004661; | ||
background: #ffffff; | ||
border: none; | ||
border-radius: 20px; | ||
padding: 10px 20px; | ||
width: 100%; | ||
font-weight: 600; | ||
transition: 0.3s; | ||
cursor: pointer; | ||
} | ||
|
||
.button-submit:hover { | ||
background: #bcbcbc; | ||
} | ||
|
||
.placeholder { | ||
flex-shrink: 0; | ||
border-radius: 20px; | ||
border: 1px solid #bcbcbc; | ||
background: rgba(0, 0, 0, 0); | ||
padding: 10px 20px; | ||
color: #ffffff; | ||
} | ||
|
||
.name { | ||
font-size: 12px; | ||
font-weight: 600; | ||
} | ||
|
||
.placeholder::placeholder { | ||
color: #ffffff; | ||
} | ||
|
||
.link { | ||
color: #bcbcbc; | ||
} | ||
|
||
.otherLogin { | ||
font-size: 12px; | ||
} | ||
|
||
.placeholder option { | ||
color: black; | ||
} | ||
|
||
.button-logout{ | ||
color: #004661; | ||
background: #ffffff; | ||
border: none; | ||
border-radius: 20px; | ||
padding: 10px 20px; | ||
width: 10%; | ||
font-weight: 600; | ||
transition: 0.3s; | ||
cursor: pointer; | ||
position: absolute; | ||
right: 150px; | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
margin-top: 30px; | ||
} | ||
|
||
.button-logout:hover { | ||
background: #FF3838; | ||
color: #FFF; | ||
} | ||
|
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{% load static %} | ||
<!DOCTYPE html> | ||
<html lang="pt-br"> | ||
<head> | ||
<title>AutomaTEC</title> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<link rel="stylesheet" href="{% static 'css/style.css' %}"> | ||
<link rel="preconnect" href="https://fonts.googleapis.com"> | ||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> | ||
<link href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap" rel="stylesheet"> | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script> | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.mask/1.14.16/jquery.mask.min.js"></script> | ||
</head> | ||
|
||
<body> | ||
<header> | ||
<img src="{% static 'imagem/finateclogo.png' %}" alt="finatec"> | ||
<h1>Sistema de prestação automático</h1> | ||
</header> | ||
{% block conteudo %} | ||
|
||
{% endblock %} | ||
<footer class="footer">Copyright BRISA 2021©. Todos direitos reservados.</footer> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
{% extends 'base.html' %} | ||
{% block conteudo %} | ||
{% load static %} | ||
|
||
<script> | ||
function valida_cpf(cpf) { | ||
var numeros, digitos, soma, i, resultado, digitos_iguais; | ||
digitos_iguais = 1; | ||
if (cpf.length < 11) | ||
return false; | ||
for (i = 0; i < cpf.length - 1; i++) | ||
if (cpf.charAt(i) != cpf.charAt(i + 1)) { | ||
digitos_iguais = 0; | ||
break; | ||
} | ||
if (!digitos_iguais) { | ||
numeros = cpf.substring(0,9); | ||
digitos = cpf.substring(9); | ||
soma = 0; | ||
for (i = 10; i > 1; i--) | ||
soma += numeros.charAt(10 - i) * i; | ||
resultado = soma % 11 < 2 ? 0 : 11 - soma % 11; | ||
if (resultado != digitos.charAt(0)) | ||
return false; | ||
numeros = cpf.substring(0,10); | ||
soma = 0; | ||
for (i = 11; i > 1; i--) | ||
soma += numeros.charAt(11 - i) * i; | ||
resultado = soma % 11 < 2 ? 0 : 11 - soma % 11; | ||
if (resultado != digitos.charAt(1)) | ||
return false; | ||
return true; | ||
} else | ||
return false; | ||
} | ||
|
||
$(document).ready(function() { | ||
$('#cpf').mask('000.000.000-00', {reverse: true}); | ||
|
||
$('#cpf').on('blur', function() { | ||
var cpfValue = $(this).val().replace(/\D/g, ''); | ||
if (cpfValue && cpfValue.length === 11) { | ||
if (!valida_cpf(cpfValue)) { | ||
alert('O CPF digitado é inválido.'); | ||
$(this).val(''); | ||
$(this).focus(); | ||
} | ||
} | ||
}); | ||
}); | ||
</script> | ||
</head> | ||
|
||
<body> | ||
<content class="content"> | ||
<div class="container"> | ||
<img src="{% static 'imagem/logoFinatec.png' %}" alt="logo" class="logo"> | ||
<h3>Cadastrar</h3> | ||
<form action="{% url 'cadastro' %}" method="POST" class='form'> | ||
{% csrf_token %} | ||
<div class="inputGroup"> | ||
<div class="input"> | ||
<label class="email">Email</label> | ||
<input type="email" id="email" name="email" class="placeholder" placeholder="Digite seu Email" title="Digite um email válido." required> | ||
</div> | ||
<div class="input"> | ||
<label class="name">CPF</label> | ||
<input type="text" id="cpf" name="usuario" class="placeholder" placeholder="000.000.000-00" maxlength="14" pattern="\d{3}\.\d{3}\.\d{3}-\d{2}" title="Digite um CPF válido no formato 000.000.000-00." required> | ||
</div> | ||
<div class="input"> | ||
<label class="name">Senha</label> | ||
<input type="password" name="senha" class="placeholder" placeholder="••••••" title="Digite uma senha válida." required> | ||
</div> | ||
</div> | ||
<input type="submit" value="Cadastrar" class="button-submit"> | ||
</form> | ||
{% if error_messages %} | ||
<ul class="error-list"> | ||
{% for message in error_messages %} | ||
<li class="error">{{ message }}</li> | ||
{% endfor %} | ||
</ul> | ||
{% endif %} | ||
<p class="otherLogin">Possui uma conta? <a href="/" class="link">Logar</a></p> | ||
</div> | ||
</content> | ||
|
||
|
||
{% endblock %} |
Oops, something went wrong.