All checks were successful
CI/CD Pipeline / Build and Deploy with Docker Compose (push) Successful in 4m10s
196 lines
5.5 KiB
Plaintext
196 lines
5.5 KiB
Plaintext
@using Domain.Dtos
|
|
@using System.Globalization
|
|
@model Domain.Dtos.QuoteDto
|
|
|
|
@{
|
|
var culture = CultureInfo.GetCultureInfo("es-AR");
|
|
}
|
|
|
|
<!DOCTYPE html>
|
|
<html lang="es">
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<title>Presupuesto @Model.Quotenumber</title>
|
|
<style>
|
|
body {
|
|
font-family: 'Liberation Sans', Arial, sans-serif;
|
|
font-size: 11px;
|
|
color: #000;
|
|
margin: 30px;
|
|
padding: 20px;
|
|
box-sizing: border-box;
|
|
border: 1px solid #000;
|
|
}
|
|
|
|
.row {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
gap: 20px;
|
|
}
|
|
|
|
.col {
|
|
flex: 1;
|
|
}
|
|
|
|
.izquierda {
|
|
flex-basis: 50%; /* fácil de cambiar a 40%, 30%, etc. */
|
|
}
|
|
|
|
.derecha {
|
|
flex-basis: 50%;
|
|
}
|
|
|
|
h1, h2, h3 {
|
|
margin: 0;
|
|
padding: 0;
|
|
}
|
|
|
|
.header {
|
|
text-align: center;
|
|
margin-bottom: 10px;
|
|
}
|
|
|
|
.section {
|
|
margin-top: 10px;
|
|
min-height: 60px;
|
|
}
|
|
|
|
table {
|
|
width: 100%;
|
|
border-collapse: collapse;
|
|
margin-top: 5px;
|
|
}
|
|
|
|
th, td {
|
|
border: 1px solid #ccc;
|
|
padding: 4px;
|
|
text-align: left;
|
|
}
|
|
|
|
th {
|
|
background-color: #f0f0f0;
|
|
}
|
|
|
|
.totales {
|
|
margin-top: 10px;
|
|
float: right;
|
|
width: 45%;
|
|
}
|
|
|
|
.footer {
|
|
text-align: center;
|
|
font-size: 10px;
|
|
margin-top: 20px;
|
|
color: #666;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<div class="header">
|
|
<h2>Presupuesto Nº @Model.Quotenumber</h2>
|
|
<p>Fecha de emisión: @Model.IssueDate.ToString("dd/MM/yyyy")</p>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col izquierda">
|
|
<!-- Datos del Cliente -->
|
|
<h3>Datos del Cliente</h3>
|
|
<p><strong>Nombre:</strong> @Model.Customer.Name</p>
|
|
<p><strong>Domicilio:</strong> @Model.Customer.Address</p>
|
|
<p><strong>Condición IVA:</strong> @Model.Customer.IvaCondition</p>
|
|
@if (Model.Customer.Documents != null && Model.Customer.Documents.Any())
|
|
{
|
|
<p><strong>Documentos:</strong></p>
|
|
<ul>
|
|
@foreach (var doc in Model.Customer.Documents)
|
|
{
|
|
<li>@doc.DocumentType: @doc.Number</li>
|
|
}
|
|
</ul>
|
|
}
|
|
else
|
|
{
|
|
<p>— Sin documentos —</p>
|
|
}
|
|
</div>
|
|
<div class="col derecha">
|
|
<!-- Datos del Paciente y Atención -->
|
|
<h3>Datos del Paciente y Atención</h3>
|
|
<p><strong>Paciente:</strong> @Model.PatientName</p>
|
|
<p><strong>Médico:</strong> @Model.ProfessionalName</p>
|
|
<p><strong>Institución:</strong> @Model.InstitutionName</p>
|
|
<p><strong>Fecha estimada:</strong> @(Model.EstimatedDate?.ToString("dd/MM/yyyy") ?? "—")</p>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="section">
|
|
<h3>Productos Cotizados</h3>
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Descripción</th>
|
|
<th>Cantidad</th>
|
|
<th>Precio Unitario</th>
|
|
<th>Subtotal</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach (var item in Model.Items)
|
|
{
|
|
<tr>
|
|
<td>@item.Description</td>
|
|
<td>@item.Quantity</td>
|
|
<td>@item.UnitPrice.ToString("C", culture)</td>
|
|
<td>@item.Total.ToString("C", culture)</td>
|
|
</tr>
|
|
}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="section">
|
|
<h3>Totales</h3>
|
|
<table class="totales">
|
|
<tbody>
|
|
<tr>
|
|
<td><strong>Subtotal</strong></td>
|
|
<td>@Model.Items.Sum(i => i.Subtotal).ToString("C", culture)</td>
|
|
</tr>
|
|
@if (Model.Taxes?.Any() == true)
|
|
{
|
|
@foreach (var tax in Model.Taxes)
|
|
{
|
|
<tr>
|
|
<td><strong>@tax.TaxName (@tax.TaxRate%)</strong></td>
|
|
<td>@tax.TaxAmount.ToString("C", culture)</td>
|
|
</tr>
|
|
}
|
|
}
|
|
@if (Model.Adjustments?.Any() == true)
|
|
{
|
|
@foreach (var adj in Model.Adjustments)
|
|
{
|
|
<tr>
|
|
<td><strong>Ajuste: @adj.Reason</strong></td>
|
|
<td>@adj.Amount.ToString("C", culture)</td>
|
|
</tr>
|
|
}
|
|
}
|
|
<tr>
|
|
<td><strong>Total Final</strong></td>
|
|
<td>@Model.Total.ToString("C", culture)</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="section">
|
|
<h3>Observaciones</h3>
|
|
<p>@(string.IsNullOrWhiteSpace(Model.Observations) ? "— Sin observaciones —" : Model.Observations)</p>
|
|
</div>
|
|
|
|
<div class="footer">
|
|
<p>Sistema de Gestión y Administración - PhronCare © 2025</p>
|
|
</div>
|
|
</body>
|
|
</html>
|