Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 3.2.7 on 2021-09-19 00:41

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('pre_cuentas', '0001_initial'),
]

operations = [
migrations.AlterField(
model_name='foreigntransfer',
name='transfer_abroad',
field=models.BooleanField(),
),
]
14 changes: 14 additions & 0 deletions Backend/pre_cuentas/migrations/0003_merge_20210918_2247.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Generated by Django 3.2.7 on 2021-09-19 02:47

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('pre_cuentas', '0002_alter_foreigntransfer_transfer_abroad'),
('pre_cuentas', '0002_auto_20210918_2136'),
]

operations = [
]
2 changes: 1 addition & 1 deletion Backend/pre_cuentas/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ class Request(models.Model):
transfer_destiny = models.CharField(max_length=3, choices=COUNTRIES, default="Ven")
state = models.CharField(max_length=1, default='A') # Faltan opciones
def __str__(self):
return self.code
return str(self.code)
class Meta:
db_table = 'Request'

13 changes: 11 additions & 2 deletions Backend/pre_cuentas/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
from .models import *
from django.core.exceptions import ObjectDoesNotExist
from django.contrib.auth import authenticate, login
"""from django.db.models import Request;"""

def client_view(request):
context ={}
Expand Down Expand Up @@ -73,7 +74,15 @@ def form2SC(request):
return render(request, 'components/Form2SC.html')

def seeQuote(request):
return render(request, 'components/SeeQuote.html')
client = request.user.client

consultQuote = Request.objects.select_related('office_code').filter(client_document_id = client)

return render(request, 'components/SeeQuote.html',{'consultQuote' : consultQuote} )

def visualize(request):
return render(request, 'components/Visualize.html')
client = request.user.client

consultVoucher = Request.objects.select_related('client_document_id', 'office_code').filter(client_document_id = client)

return render(request, 'components/Visualize.html', {'consultVoucher' : consultVoucher} )
18 changes: 15 additions & 3 deletions Frontend/template/components/SeeQuote.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,21 @@
</thead>
<tbody>
<tr style="border: solid 1px #21516e;">
<th scope="row">G5D46S4</th>
<td>12/09/2021</td>
<td>Los Leones-Barquisimeto</td>
{%if consultQuote%}
{%for cq in consultQuote%}
<th scope="row">{{cq.code}}</th>
<td>{{cq.date_issue.day}} / {{cq.date_issue.month}} / {{cq.date_issue.year}}</td>
<td>{{cq.office_code.address}}</td>
{% endfor %}
{% else %}
<div class="alert alert-warning" role="alert">
¡No tienes citas registradas!
</div>
{% endif %}




</tr>
</tbody>
</table>
Expand Down
25 changes: 17 additions & 8 deletions Frontend/template/components/visualize.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
{% block content %}
<!-- Contenido -->
<div class="container" style="background-color: #F5F7FC; height: 542px; text-align: center; margin:4px; border: solid 3px #056DAE">
<h1 style="align:center; margin:20px auto;">COMPROBANTE N*09005357</h1>
{% for cv in consultVoucher %}
<h1 style="align:center; margin:20px auto;">COMPROBANTE N*{{cv.code}}</h1>
{% endfor %}
<div class="row1" style=" height:100px; margin:10px;">
<table class="table" style="width:100%; text-align: center;">
<thead>
Expand All @@ -15,9 +17,12 @@ <h1 style="align:center; margin:20px auto;">COMPROBANTE N*09005357</h1>
</thead>
<tbody>
<tr class="row1-2" style="height:30px">
<td style="font-size: 0.9em;">MARIHEC ESTER MIRANDA TOVAR</td>
<td style="font-size: 0.9em;">26.120.075</td>
<td style="font-size: 0.9em;">13/09/2021</td>
{% for cv in consultVoucher %}
<td style="font-size: 0.9em;">{{cv.client_document_id.first_name}} {{cv.client_document_id.last_name}}</td>
<td style="font-size: 0.9em;">{{cv.client_document_id.document_type}} - {{cv.client_document_id.document_number}}</td>
<td style="font-size: 0.9em;">{{cv.date_issue.day}} / {{cv.date_issue.month}} / {{cv.date_issue.year}}</td>
{% endfor %}

</tr>
</tbody>
</table>
Expand All @@ -33,9 +38,11 @@ <h1 style="align:center; margin:20px auto;">COMPROBANTE N*09005357</h1>
</thead>
<tbody>
<tr class="row2-2" style="height:30px">
<td style="font-size: 0.9em;">CUENTA CORRIENTE</td>
<td style="font-size: 0.9em;">LOS LEONES-Barquisimeto</td>
<td style="font-size: 0.9em;">0315</td>
{% for cv in consultVoucher %}
<td style="font-size: 0.9em;">{{cv.account_type}}</td>
<td style="font-size: 0.9em;">{{cv.office_code.name}}</td>
<td style="font-size: 0.9em;">{{cv.office_code.id}}</td>
{% endfor %}
</tr>
</tbody>
</table>
Expand All @@ -49,7 +56,9 @@ <h1 style="align:center; margin:20px auto;">COMPROBANTE N*09005357</h1>
</thead>
<tbody>
<tr class="row3-2" style="height:30px">
<td style="font-size: 1em;">Av. Los Leones, CC Los Leones, PB, Locales 1, 2 y 3, sector Este, Municipio Iribarren. </td>
{% for cv in consultVoucher %}
<td style="font-size: 1em;">{{cv.office_code.address}} </td>
{% endfor %}
</tr>
</tbody>
</table>
Expand Down
4 changes: 2 additions & 2 deletions Frontend/template/pages/LandingPage.html
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
<div class="navbar-ingresar">
<ul class="navbar-nav me-auto mb-2 mb-lg-0">
<li class="nav-item">
<a class="nav-link active" aria-current="page" href="#">Ingresar</a>
<a class="nav-link active" aria-current="page" href="{% url 'login' %}">Ingresar</a>
</li>
</ul>
</div>
Expand Down Expand Up @@ -81,7 +81,7 @@
<h1> Sistema de pre-apertura </h1>
<h1> <b> de cuenta Bancaria </b></h1>
<p> Realiza tu solicitud desde la comodidad de tu hogar, con el sistema más seguro de todo el País</p>
<a class="nav-link active" aria-current="page" href="#">Me Interesa</a>
<a class="nav-link active" aria-current="page" href="{% url 'login' %}">Me Interesa</a>
</div>
</div>

Expand Down