-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #11 from arthursuzuki/deployments_tests
Deployments tests to main
- Loading branch information
Showing
34 changed files
with
1,449 additions
and
35 deletions.
There are no files selected for viewing
Binary file modified
BIN
+149 Bytes
(150%)
project_bloom/app_bloom/__pycache__/admin.cpython-311.pyc
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 |
---|---|---|
@@ -1,3 +1,4 @@ | ||
from django.contrib import admin | ||
from .models import Crianca | ||
|
||
# Register your models here. | ||
admin.site.register(Crianca) |
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,8 @@ | ||
from django import forms | ||
from app_bloom.models import Crianca | ||
|
||
|
||
class CriancaForm(forms.ModelForm): | ||
class Meta: | ||
model = Crianca | ||
fields = '__all__' |
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,28 @@ | ||
# Generated by Django 4.2 on 2023-10-17 00:21 | ||
|
||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
initial = True | ||
|
||
dependencies = [ | ||
] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name='Crianca', | ||
fields=[ | ||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), | ||
('nome', models.CharField(max_length=100)), | ||
('data_nascimento', models.DateField()), | ||
('genero', models.CharField(choices=[('Feminino', 'Feminino'), ('Masculino', 'Masculino'), ('Outro', 'Outro')], max_length=10)), | ||
('cpf', models.CharField(max_length=11)), | ||
('rg', models.CharField(max_length=20)), | ||
('endereco', models.CharField(max_length=100)), | ||
('historico_medico', models.FileField(upload_to='historicos/')), | ||
('autorizacao_responsavel', models.FileField(upload_to='autorizacoes/')), | ||
], | ||
), | ||
] |
Binary file added
BIN
+1.65 KB
project_bloom/app_bloom/migrations/__pycache__/0001_initial.cpython-311.pyc
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 |
---|---|---|
@@ -1,3 +1,17 @@ | ||
from django.db import models | ||
|
||
# Create your models here. | ||
class Crianca(models.Model): | ||
nome = models.CharField(max_length=100) | ||
data_nascimento = models.DateField() | ||
genero = models.CharField(max_length=10, choices=[('Feminino', 'Feminino'), | ||
('Masculino', 'Masculino' | ||
), ('Outro', 'Outro')]) | ||
cpf = models.CharField(max_length=11) | ||
rg = models.CharField(max_length=20) | ||
endereco = models.CharField(max_length=100) | ||
historico_medico = models.FileField(upload_to='historicos/') | ||
autorizacao_responsavel = models.FileField(upload_to='autorizacoes/') | ||
|
||
def __str__(self): | ||
return self.nome |
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.
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 was deleted.
Oops, something went wrong.
216 changes: 216 additions & 0 deletions
216
project_bloom/app_bloom/templates/inicial/cadastrocrianca.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,216 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<style> | ||
body { | ||
font-family: Arial, sans-serif; | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
justify-content: center; | ||
height: 100vh; | ||
margin: 0; | ||
} | ||
|
||
#header { | ||
position: fixed; | ||
top: 0; | ||
left: 0; | ||
width: 100%; | ||
height: 30px; | ||
background-color: #F2F2F2; | ||
display: flex; | ||
justify-content: space-between; | ||
align-items: center; | ||
padding: 14px; | ||
z-index: 1000; | ||
} | ||
|
||
#container { | ||
width: 100%; | ||
height: 80%; | ||
position: relative; | ||
background: #f0f0f0; | ||
margin: 0; | ||
padding: 0; | ||
} | ||
.form-container { | ||
width: 70%; | ||
margin: 0 auto; | ||
padding: 20px; | ||
background: white; | ||
border-radius: 10px; | ||
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1); | ||
} | ||
|
||
.form-element { | ||
margin-bottom: 20px; | ||
} | ||
.form-element-label { | ||
font-size: 18px; | ||
} | ||
.form-input { | ||
width: 100%; | ||
font-size: 16px; | ||
padding: 10px; | ||
box-sizing: border-box; | ||
} | ||
|
||
#submit-button { | ||
width: 100%; | ||
background: #080808; | ||
color: white; | ||
padding: 15px; | ||
font-size: 18px; | ||
border: none; | ||
border-radius: 5px; | ||
cursor: pointer; | ||
} | ||
#submit-button:hover { | ||
background: #8e399c; | ||
} | ||
.required { | ||
color: red; | ||
} | ||
|
||
#logo-container { | ||
display: flex; | ||
align-items: center; | ||
gap: 10px; | ||
} | ||
|
||
#links { | ||
display: flex; | ||
gap: 20px; | ||
align-items: left; | ||
justify-content: flex-start; | ||
margin-left: 15px; | ||
} | ||
|
||
#links a { | ||
text-decoration: none; | ||
color: black; | ||
cursor: pointer; | ||
} | ||
|
||
#images { | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
} | ||
|
||
#usuario { | ||
display: flex; | ||
align-items: center; | ||
gap: 10px; | ||
margin-right: 20px; | ||
width: 50px; | ||
} | ||
|
||
#images img { | ||
width: 150px; | ||
height: auto; | ||
margin-bottom: 20px; | ||
} | ||
|
||
#text { | ||
text-align: center; | ||
color: #333; | ||
font-size: 16px; | ||
font-weight: lighter; | ||
font-family: 'Trebuchet MS', sans-serif; | ||
} | ||
|
||
</style> | ||
|
||
<script> | ||
function showSuccessPopup(message) { | ||
var popup = document.getElementById("success-popup"); | ||
var successMessage = document.getElementById("success-message"); | ||
|
||
successMessage.innerHTML = message; | ||
|
||
popup.style.display = "block"; | ||
|
||
setTimeout(function() { | ||
popup.style.display = "none"; | ||
}, 3000); // 3000 milissegundos = 3 segundos | ||
} | ||
</script> | ||
|
||
</head> | ||
<body> | ||
{% load static %} | ||
<!-- Seção do cabeçalho --> | ||
<div id="header"> | ||
<div id="logo-container"> | ||
<div id="logo-principal"> | ||
<img src="{% static 'logo\Logo.png' %}" alt="Logo Bloom" style="width: 150px; height: auto;"></div> | ||
<div id="links"> | ||
<a href="{% url 'sobre' %}">Sobre nós</a> | ||
<a href="{% url 'l_padrinho' %}">Apadrinhar</a> | ||
<a href="{% url 'l_padrinho' %}">Acompanhar Aluno</a> | ||
<a href="{% url 'doar' %}">Contribuir</a> | ||
<a href="{% url 'opc_login' %}">Login</a> | ||
</div> | ||
</div> | ||
|
||
<h1 style="text-align: center;">CADASTRO CRIANÇA</h1> | ||
<div id="container"> | ||
<div class="form-container"> | ||
<form method="post" enctype="multipart/form-data" action="{% url 'cadastrar_crianca' %}"> | ||
{% csrf_token %} | ||
<div class="form-element"> | ||
<label class="form-element-label">Nome completo<span class="required">*</span>:</label> | ||
<input class="form-input" type="text" name="nome"> | ||
</div> | ||
<div class="form-element"> | ||
<label class="form-element-label">Data de nascimento<span class="required">*</span>:</label> | ||
<input class="form-input" type="date" name="data_nascimento"> | ||
</div> | ||
<div class="form-element"> | ||
<label class="form-element-label">Gênero<span class="required">*</span>:</label> | ||
<select class="form-input" name="genero"> | ||
<option value="Feminino" selected>Feminino</option> | ||
<option value="Masculino">Masculino</option> | ||
<option value="Outro">Outro</option> | ||
</select> | ||
</div> | ||
<div class="form-element"> | ||
<label class="form-element-label">CPF (apenas números)<span class="required">*</span>:</label> | ||
<input class="form-input" type="text" name="cpf"> | ||
</div> | ||
<div class="form-element"> | ||
<label class="form-element-label">RG<span class="required">*</span>:</label> | ||
<input class="form-input" type="text" name="rg"> | ||
</div> | ||
<div class="form-element"> | ||
<label class="form-element-label">Endereço:</label> | ||
<input class="form-input" type="text" name="endereco"> | ||
</div> | ||
<div class="form-element"> | ||
<label class="form-element-label">Histórico Médico<span class="required">*</span>:</label> | ||
<input class="form-input" type="file" name="historico_medico"> | ||
</div> | ||
<div class="form-element"> | ||
<label class="form-element-label">Autorização do Responsável<span class="required">*</span>:</label> | ||
<input class="form-input" type="file" name="autorizacao_responsavel"> | ||
</div> | ||
<div class="form-element" style="text-align: center;"> | ||
<button id="submit-button" type="submit">Enviar</button> | ||
</div> | ||
</form> | ||
</div> | ||
</div> | ||
<div id="success-popup" style="display: none; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); background: #fff; padding: 20px; border: 1px solid #ccc; border-radius: 5px; box-shadow: 0 0 10px rgba(0, 0, 0, 0.2); text-align: center;"> | ||
<p id="success-message">Sucesso!</p> | ||
</div> | ||
|
||
{% if success_message %} | ||
<script> | ||
showSuccessPopup("{{ success_message|escapejs }}"); | ||
</script> | ||
{% endif %} | ||
|
||
</body> | ||
</html> |
Oops, something went wrong.