From f55e4dbd5f3d7ea2d77a2630e10cff1417f198a5 Mon Sep 17 00:00:00 2001 From: Aldarien Date: Thu, 18 Jan 2024 17:15:32 -0300 Subject: [PATCH] ventas.base --- app/resources/views/ventas/base.blade.php | 36 ++ .../views/ventas/desistida.blade.php | 72 ++-- app/resources/views/ventas/desistir.blade.php | 80 ++-- app/resources/views/ventas/edit.blade.php | 52 ++- .../views/ventas/escriturar.blade.php | 374 +++++++++--------- .../views/ventas/escrituras/informe.blade.php | 169 ++++---- .../views/ventas/escrituras/show.blade.php | 37 +- .../views/ventas/pies/cuotas.blade.php | 273 +++++++------ .../views/ventas/pies/cuotas/add.blade.php | 157 ++++---- .../views/ventas/pies/edit.blade.php | 41 +- app/resources/views/ventas/show.blade.php | 39 +- 11 files changed, 679 insertions(+), 651 deletions(-) create mode 100644 app/resources/views/ventas/base.blade.php diff --git a/app/resources/views/ventas/base.blade.php b/app/resources/views/ventas/base.blade.php new file mode 100644 index 0000000..1a75b85 --- /dev/null +++ b/app/resources/views/ventas/base.blade.php @@ -0,0 +1,36 @@ +@extends('layout.base') + +@section('page_title') + Venta {{$venta->proyecto()->descripcion}} {{$venta->propiedad()->summary()}} +@endsection + +@section('page_content') +
+
+
+

+
+
{{$venta->proyecto()->descripcion}}
+ + {{$venta->propiedad()->summary()}} + +
+

+ @if (isset($showPropietario) and $showPropietario) +
+ @include('ventas.show.propietario') +
+ @endif +
+ @hasSection('venta_subtitle') +
+

+ @yield('venta_subtitle') +

+
+ @endif +
+
+ @yield('venta_content') +
+@endsection diff --git a/app/resources/views/ventas/desistida.blade.php b/app/resources/views/ventas/desistida.blade.php index 303c35a..530d572 100644 --- a/app/resources/views/ventas/desistida.blade.php +++ b/app/resources/views/ventas/desistida.blade.php @@ -1,47 +1,43 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_content') -
-

- Desistida - {{$venta->proyecto()->descripcion}} - - - {{$venta->propiedad()->summary()}} - -

-
-
-
- -
-
- - -
+@section('venta_subtitle') + Desistida +@endsection + +@section('venta_content') + +
+
+ +
+
+ +
-
- +
+
+ +
+
+
+
+ +
+
$
+
-
-
- -
-
$
- -
-
-
- -
+
+
- - - -
+
+ + + @endsection @push('page_scripts') diff --git a/app/resources/views/ventas/desistir.blade.php b/app/resources/views/ventas/desistir.blade.php index b7db556..d853777 100644 --- a/app/resources/views/ventas/desistir.blade.php +++ b/app/resources/views/ventas/desistir.blade.php @@ -1,51 +1,49 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_content') -
-

- Desistir - {{$venta->proyecto()->descripcion}} - - {{$venta->propiedad()->summary()}} -

-
-
-
Valor Pagado
-
- {{$format->pesos($venta->formaPago()->pie->pagado('pesos'))}} -
- {{$format->number($venta->formaPago()->pie->pagado() / $venta->valor * 100)}}% de la venta -
-
-
-
-
- Multa Estandar -
5%
-
-
- {{$format->pesos($venta->valor * 0.05 * $UF->get())}} +@section('venta_subtitle') + Desistir +@endsection + +@section('venta_content') +
+
+
Valor Pagado
+
+ {{$format->pesos($venta->formaPago()->pie->pagado('pesos'))}} +
+ {{$format->number($venta->formaPago()->pie->pagado() / $venta->valor * 100)}}% de la venta
-
-
- -
-
- - -
-
+
+
+ Multa Estandar +
5%
-
- -
-
$
- -
+
+ {{$format->pesos($venta->valor * 0.05 * $UF->get())}}
- - +
+
+
+ +
+
+ + +
+
+
+
+ +
+
$
+ +
+
+ +
@endsection @push('page_scripts') diff --git a/app/resources/views/ventas/edit.blade.php b/app/resources/views/ventas/edit.blade.php index 09c52fb..9bf3237 100644 --- a/app/resources/views/ventas/edit.blade.php +++ b/app/resources/views/ventas/edit.blade.php @@ -1,33 +1,31 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_content') -
-

Editar Venta - - {{$venta->proyecto()->descripcion}} - - {{$venta->propiedad()->summary()}} -

-
-
- -
- -
UF
+@section('venta_subtitle') + Editar Venta +@endsection + +@section('venta_content') + +
+ +
+ +
UF
+
+
+
+ +
+
+ +
-
- -
-
- - -
-
-
- - -
+
+ + @endsection @push('page_scripts') diff --git a/app/resources/views/ventas/escriturar.blade.php b/app/resources/views/ventas/escriturar.blade.php index 171b8ae..23445e2 100644 --- a/app/resources/views/ventas/escriturar.blade.php +++ b/app/resources/views/ventas/escriturar.blade.php @@ -1,210 +1,206 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_content') -
-

- Escriturar - {{$venta->proyecto()->descripcion}} - - - {{$venta->propiedad()->summary()}} - -

-
-
-
Faltante
-
{{$format->pesos($venta->saldo('pesos'))}}
-
{{$format->ufs($venta->saldo())}}
+@section('venta_subtitle') + Escriturar +@endsection + +@section('venta_content') +
+
+
Faltante
+
{{$format->pesos($venta->saldo('pesos'))}}
+
{{$format->ufs($venta->saldo())}}
+
+
+
+
+
+ +
+
+ + +
-
- -
- -
-
- - + @if ($venta->formaPago()->pie->reajuste === null) +

Reajuste

+
+
+ +
+
$
+ +
+
+
+ +
+
+ + +
- @if ($venta->formaPago()->pie->reajuste === null) -

Reajuste

-
-
- -
-
$
- -
+ @else +

Reajuste

+
+
+ +
+
$
+
-
- -
-
- - -
+
+
+ +
+ +
+
+
+ @endif + @if (!isset($venta->formaPago()->escritura)) +

Pago en Escritura

+
+
+ +
+
$
+ +
+
+
+ +
+ +
UF
+
+
+
+ +
+
+ +
- @else -

Reajuste

-
-
- -
-
$
- -
+
+ @else +

Pago en Escritura

+
+
+ +
+
$
+
-
- -
- +
+
+ +
+ +
UF
+
+
+
+ +
+ +
+
+
+ @endif + @if (!isset($venta->formaPago()->subsidio)) +

Subsidio

+
+
+ +
+ +
UF
+
+
+
+ +
+ +
UF
+
+
+
+ +
+ +
UF
+
+
+
+ @else +

Subsidio

+
+
+ +
+ +
UF
+
+
+
+ +
+ +
UF
+
+
+
+ @endif + @if (!isset($venta->formaPago()->credito) or $venta->formaPago()->credito->pago->banco === null) +

Crédito

+
+
+ +
+ +
UF
+
+
+
+ +
- @endif - @if (!isset($venta->formaPago()->escritura)) -

Pago en Escritura

-
-
- -
-
$
- -
-
-
- -
- -
UF
-
-
-
- -
-
- - -
-
+
+ @else +

Crédito

+
+
+ +
+ +
UF
- @else -

Pago en Escritura

-
-
- -
-
$
- -
-
-
- -
- -
UF
-
-
-
- -
- -
+
+ +
+
- @endif - @if (!isset($venta->formaPago()->subsidio)) -

Subsidio

-
-
- -
- -
UF
-
-
-
- -
- -
UF
-
-
-
- -
- -
UF
-
-
-
- @else -

Subsidio

-
-
- -
- -
UF
-
-
-
- -
- -
UF
-
-
-
- @endif - @if (!isset($venta->formaPago()->credito) or $venta->formaPago()->credito->pago->banco === null) -

Crédito

-
-
- -
- -
UF
-
-
-
- - -
-
- @else -

Crédito

-
-
- -
- -
UF
-
-
-
- -
- -
-
-
- @endif - - -
+
+ @endif + + @endsection @push('page_scripts') diff --git a/app/resources/views/ventas/escrituras/informe.blade.php b/app/resources/views/ventas/escrituras/informe.blade.php index 3c530fb..648192c 100644 --- a/app/resources/views/ventas/escrituras/informe.blade.php +++ b/app/resources/views/ventas/escrituras/informe.blade.php @@ -1,91 +1,88 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_content') -
-

- Escritura - - {{$venta->proyecto()->descripcion}} - - {{$venta->propiedad()->summary()}} -

-
- El departamento {{$venta->propiedad()->departamentos()[0]->descripcion}}:
- @php - $estacionamientos = $venta->propiedad()->estacionamientos(); - @endphp - @if (count($estacionamientos) === 0) - no tiene estacionamientos - @else - tiene - {{count($estacionamientos) === 1 ? 'el' : 'los'}} - estacionamiento{{count($estacionamientos) === 1 ? '': 's'}} - {{implode(', ', array_map(function(Incoviba\Model\Venta\Unidad $unidad) { - return $unidad->descripcion; - }, $estacionamientos))}} - @endif - y - @php - $bodegas = $venta->propiedad()->bodegas(); - @endphp - @if (count($bodegas) === 0) - no tiene bodegas - @else - tiene - {{count($bodegas) === 1 ? 'la' : 'las'}} - bodega{{count($bodegas) === 1 ? '' : 's'}} - {{implode(', ', array_map(function(Incoviba\Model\Venta\Unidad $unidad) { - return $unidad->descripcion; - }, $bodegas))}} - @endif +@section('venta_subtitle') + Resumen Escritura +@endsection + +@section('venta_content') +
+ El departamento {{$venta->propiedad()->departamentos()[0]->descripcion}}:
+ @php + $estacionamientos = $venta->propiedad()->estacionamientos(); + @endphp + @if (count($estacionamientos) === 0) + no tiene estacionamientos + @else + tiene + {{count($estacionamientos) === 1 ? 'el' : 'los'}} + estacionamiento{{count($estacionamientos) === 1 ? '': 's'}} + {{implode(', ', array_map(function(Incoviba\Model\Venta\Unidad $unidad) { + return $unidad->descripcion; + }, $estacionamientos))}} + @endif + y + @php + $bodegas = $venta->propiedad()->bodegas(); + @endphp + @if (count($bodegas) === 0) + no tiene bodegas + @else + tiene + {{count($bodegas) === 1 ? 'la' : 'las'}} + bodega{{count($bodegas) === 1 ? '' : 's'}} + {{implode(', ', array_map(function(Incoviba\Model\Venta\Unidad $unidad) { + return $unidad->descripcion; + }, $bodegas))}} + @endif +
+
+ PRECIO + {{$format->ufs($venta->valor)}} +
+
+ @if (isset($venta->formaPago()->pie)) + @php($pie = $venta->formaPago()->pie) + PIE + {{$pie->cuotas}} cuotas que suman + {{$format->pesos($pie->pagado('pesos'))}} + equivalente a + {{$format->ufs($pie->pagado())}}. +
+ @endif + @if (isset($venta->formaPago()->escritura)) + @php($escritura = $venta->formaPago()->escritura) + ESCRITURA + {{$format->pesos($escritura->pago->valor)}} + el + {{$escritura->fecha->format('d-m-Y')}} + equivalente a + {{$format->ufs($escritura->pago->valor())}} +
+ @endif +
+ TOTAL ANTICIPO + {{$format->ufs($venta->formaPago()->anticipo())}} +
+ @if (isset($venta->formaPago()->bonoPie)) + @php($bono = $venta->formaPago()->bonoPie) + BONO PIE + {{$format->ufs($bono->pago->valor())}} +
+ @endif + @if (isset($venta->formaPago()->credito)) + @php($credito = $venta->formaPago()->credito) + CRÉDITO + {{$format->ufs($credito->pago->valor())}} + en Banco {{$credito->pago->banco->nombre}} +
+ @endif +
+ TOTAL + {{$format->ufs($venta->formaPago()->total())}} + @if (($venta->formaPago()->total() - $venta->valor) !== 0)

- PRECIO - {{$format->ufs($venta->valor)}} -
-
- @if (isset($venta->formaPago()->pie)) - @php($pie = $venta->formaPago()->pie) - PIE - {{$pie->cuotas}} cuotas que suman - {{$format->pesos($pie->pagado('pesos'))}} - equivalente a - {{$format->ufs($pie->pagado())}}. -
- @endif - @if (isset($venta->formaPago()->escritura)) - @php($escritura = $venta->formaPago()->escritura) - ESCRITURA - {{$format->pesos($escritura->pago->valor)}} - el - {{$escritura->fecha->format('d-m-Y')}} - equivalente a - {{$format->ufs($escritura->pago->valor())}} -
- @endif -
- TOTAL ANTICIPO - {{$format->ufs($venta->formaPago()->anticipo())}} -
- @if (isset($venta->formaPago()->bonoPie)) - @php($bono = $venta->formaPago()->bonoPie) - BONO PIE - {{$format->ufs($bono->pago->valor())}} -
- @endif - @if (isset($venta->formaPago()->credito)) - @php($credito = $venta->formaPago()->credito) - CRÉDITO - {{$format->ufs($credito->pago->valor())}} - en Banco {{$credito->pago->banco->nombre}} -
- @endif -
- TOTAL - {{$format->ufs($venta->formaPago()->total())}} - @if (($venta->formaPago()->total() - $venta->valor) !== 0) -
-
- Diferencia {{$format->ufs($venta->formaPago()->total() - $venta->valor)}}. ({{$format->percent(($venta->formaPago()->total() - $venta->valor) / $venta->valor * 100)}}) - @endif -
+ Diferencia {{$format->ufs($venta->formaPago()->total() - $venta->valor)}}. ({{$format->percent(($venta->formaPago()->total() - $venta->valor) / $venta->valor * 100)}}) + @endif
@endsection diff --git a/app/resources/views/ventas/escrituras/show.blade.php b/app/resources/views/ventas/escrituras/show.blade.php index 037fe1c..5be5aab 100644 --- a/app/resources/views/ventas/escrituras/show.blade.php +++ b/app/resources/views/ventas/escrituras/show.blade.php @@ -1,27 +1,22 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_content') -
-

- Escritura - - {{$venta->proyecto()->descripcion}} - - - {{$venta->propiedad()->summary()}} - -

-
-
- -
-
- - -
+@section('venta_subtitle') + Escritura +@endsection + +@section('venta_content') + +
+ +
+
+ +
- - -
+
+ + @endsection @push('page_scripts') diff --git a/app/resources/views/ventas/pies/cuotas.blade.php b/app/resources/views/ventas/pies/cuotas.blade.php index c302d8e..e55e961 100644 --- a/app/resources/views/ventas/pies/cuotas.blade.php +++ b/app/resources/views/ventas/pies/cuotas.blade.php @@ -1,146 +1,139 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_content') -
-
-

-
-
{{$venta->proyecto()->descripcion}}
- {{$venta->propiedad()->summary()}} -
-

-
-

Cuotas - Pie

- - - - - - - - - - - - - - - - - @php - $now = new DateTimeImmutable(); - $uf_venta = $venta->uf === 0.0 ? $UF->get($venta->currentEstado()->fecha) : $venta->uf; - @endphp - @foreach ($venta->formaPago()->pie->cuotas() as $cuota) - pago->currentEstado->tipoEstadoPago->descripcion, ['anulado', 'reemplazado'])) - class="disabled" - @endif > - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + +
#FechaFecha ISOBancoIdentificadorValorValor UFEstadoFecha EstadoFecha Estado ISO
{{$cuota->numero}}{{$cuota->pago->fecha->format('d-m-Y')}}{{$cuota->pago->fecha->format('Y-m-d')}}{{$cuota->pago->banco->nombre}}{{$cuota->pago->identificador}}{{$format->pesos($cuota->pago->valor)}} - @if ($cuota->pago->currentEstado->tipoEstadoPago->descripcion === 'abonado' and $cuota->pago->currentEstado->fecha <= $now) - {{$format->ufs($cuota->pago->valor())}} - @endif - pago->currentEstado->tipoEstadoPago->descripcion === 'abonado') - class="green" - @elseif ($cuota->pago->currentEstado->tipoEstadoPago->descripcion === 'depositado') - class="yellow" - @elseif ($cuota->pago->currentEstado->tipoEstadoPago->activo !== 1) - class="red" - @endif - >{{ucwords($cuota->pago->currentEstado->tipoEstadoPago->descripcion)}} - @if (in_array($cuota->pago->currentEstado->tipoEstadoPago->descripcion, ['abonado', 'anulado', 'reemplazado'])) - {{$cuota->pago->currentEstado->fecha->format('d-m-Y')}} - @elseif (!in_array($cuota->pago->currentEstado->tipoEstadoPago->descripcion, ['anulado', 'reemplazado'])) -
-
- - - - @if ($cuota->pago->currentEstado->tipoEstadoPago->descripcion === 'depositado') - - @endif -
-
- @endif -
{{$cuota->pago->currentEstado->fecha->format('Y-m-d')}} - @if ($cuota->pago->currentEstado->tipoEstadoPago->descripcion !== 'anulado') - +@section('venta_subtitle') + Cuotas - Pie +@endsection + +@section('venta_content') + + + + + + + + + + + + + + + + + @php + $now = new DateTimeImmutable(); + $uf_venta = $venta->uf === 0.0 ? $UF->get($venta->currentEstado()->fecha) : $venta->uf; + @endphp + @foreach ($venta->formaPago()->pie->cuotas() as $cuota) + pago->currentEstado->tipoEstadoPago->descripcion, ['anulado', 'reemplazado'])) + class="disabled" + @endif > + + + + + + + - - @endforeach - - - - - - - + + + + + - - - - - - - - - - - - - - - -
#FechaFecha ISOBancoIdentificadorValorValor UFEstadoFecha EstadoFecha Estado ISO
{{$cuota->numero}}{{$cuota->pago->fecha->format('d-m-Y')}}{{$cuota->pago->fecha->format('Y-m-d')}}{{$cuota->pago->banco->nombre}}{{$cuota->pago->identificador}}{{$format->pesos($cuota->pago->valor)}} + @if ($cuota->pago->currentEstado->tipoEstadoPago->descripcion === 'abonado' and $cuota->pago->currentEstado->fecha <= $now) + {{$format->ufs($cuota->pago->valor())}} @endif -
TOTAL - {{$format->pesos($total_pesos = array_reduce($venta->formaPago()->pie->cuotas(), - function(float $sum, Incoviba\Model\Venta\Cuota $cuota) { - return $sum + $cuota->pago->valor; - }, 0))}} - - {{$format->ufs($total = array_reduce($venta->formaPago()->pie->cuotas(), - function(float $sum, Incoviba\Model\Venta\Cuota $cuota) use ($now, $uf_venta) { - return $sum + (($cuota->pago->fecha > $now or $cuota->pago->uf === null) ? - $cuota->pago->valor / $uf_venta : - $cuota->pago->valor()); - }, 0.0))}} - pago->currentEstado->tipoEstadoPago->descripcion === 'abonado') + class="green" + @elseif ($cuota->pago->currentEstado->tipoEstadoPago->descripcion === 'depositado') + class="yellow" + @elseif ($cuota->pago->currentEstado->tipoEstadoPago->activo !== 1) + class="red" + @endif + >{{ucwords($cuota->pago->currentEstado->tipoEstadoPago->descripcion)}} + @if (in_array($cuota->pago->currentEstado->tipoEstadoPago->descripcion, ['abonado', 'anulado', 'reemplazado'])) + {{$cuota->pago->currentEstado->fecha->format('d-m-Y')}} + @elseif (!in_array($cuota->pago->currentEstado->tipoEstadoPago->descripcion, ['anulado', 'reemplazado'])) +
+
+ + + + @if ($cuota->pago->currentEstado->tipoEstadoPago->descripcion === 'depositado') + + @endif +
+
+ @endif +
{{$cuota->pago->currentEstado->fecha->format('Y-m-d')}} + @if ($cuota->pago->currentEstado->tipoEstadoPago->descripcion !== 'anulado') + + @endif +
TOTAL PAGADO - {{$format->pesos($pagado_pesos = array_reduce($venta->formaPago()->pie->cuotas(true), - function(int $sum, Incoviba\Model\Venta\Cuota $cuota) { - return $sum + $cuota->pago->valor; - }, 0))}} - - {{$format->ufs($pagado = array_reduce($venta->formaPago()->pie->cuotas(true), - function(float $sum, Incoviba\Model\Venta\Cuota $cuota) { - return $sum + $cuota->pago->valor(); - }, 0.0))}} - - {{$format->number($pagado / $total * 100, 2)}}% -
POR PAGAR - {{$format->pesos($total_pesos - $pagado_pesos)}} - - {{$format->ufs($total - $pagado)}} - - {{$format->number(($total - $pagado) / $total * 100, 2)}}% -
- + @endforeach +
TOTAL + {{$format->pesos($total_pesos = array_reduce($venta->formaPago()->pie->cuotas(), + function(float $sum, Incoviba\Model\Venta\Cuota $cuota) { + return $sum + $cuota->pago->valor; + }, 0))}} + + {{$format->ufs($total = array_reduce($venta->formaPago()->pie->cuotas(), + function(float $sum, Incoviba\Model\Venta\Cuota $cuota) use ($now, $uf_venta) { + return $sum + (($cuota->pago->fecha > $now or $cuota->pago->uf === null) ? + $cuota->pago->valor / $uf_venta : + $cuota->pago->valor()); + }, 0.0))}} +
TOTAL PAGADO + {{$format->pesos($pagado_pesos = array_reduce($venta->formaPago()->pie->cuotas(true), + function(int $sum, Incoviba\Model\Venta\Cuota $cuota) { + return $sum + $cuota->pago->valor; + }, 0))}} + + {{$format->ufs($pagado = array_reduce($venta->formaPago()->pie->cuotas(true), + function(float $sum, Incoviba\Model\Venta\Cuota $cuota) { + return $sum + $cuota->pago->valor(); + }, 0.0))}} + + {{$format->number($pagado / $total * 100, 2)}}% +
POR PAGAR + {{$format->pesos($total_pesos - $pagado_pesos)}} + + {{$format->ufs($total - $pagado)}} + + {{$format->number(($total - $pagado) / $total * 100, 2)}}% +
@endsection @include('layout.body.scripts.datatables') diff --git a/app/resources/views/ventas/pies/cuotas/add.blade.php b/app/resources/views/ventas/pies/cuotas/add.blade.php index 95ee90c..2cffa1a 100644 --- a/app/resources/views/ventas/pies/cuotas/add.blade.php +++ b/app/resources/views/ventas/pies/cuotas/add.blade.php @@ -1,93 +1,86 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_content') -
-
-

-
-
{{$venta->proyecto()->descripcion}}
- {{$venta->propiedad()->summary()}} -
-

-
-

Agregar Cuotas - Pie

-
- - - - - - - - - - - - @for ($i = count($pie->cuotas(vigentes: true)); $i < $pie->cuotas; $i ++) - - - - + + @endfor + + + + + + +
#FechaBancoIdentificadorValor
{{$i + 1}} -
-
-
- - -
-
- -
-
- +
+ +
+ @endsection @include('layout.body.scripts.dayjs') diff --git a/app/resources/views/ventas/pies/edit.blade.php b/app/resources/views/ventas/pies/edit.blade.php index 34c2ca5..db5d4ce 100644 --- a/app/resources/views/ventas/pies/edit.blade.php +++ b/app/resources/views/ventas/pies/edit.blade.php @@ -1,27 +1,24 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_content') -
-

- Pie - - {{$venta->proyecto()->descripcion}} - - {{$venta->propiedad()->summary()}} -

-
-
- -
- -
UF
-
+@section('venta_subtitle') + Pie +@endsection + +@section('venta_content') + +
+ +
+ +
UF
-
- - -
- - -
+
+
+ + +
+ + @endsection @push('page_scripts') diff --git a/app/resources/views/ventas/show.blade.php b/app/resources/views/ventas/show.blade.php index 95dfb44..ff7d258 100644 --- a/app/resources/views/ventas/show.blade.php +++ b/app/resources/views/ventas/show.blade.php @@ -1,10 +1,39 @@ -@extends('layout.base') +@extends('ventas.base') -@section('page_title') - Venta {{$venta->proyecto()->descripcion}} {{$venta->propiedad()->summary()}} +@php +$showPropietario = true; +@endphp + +@section('venta_content') +
+ @if ($venta->currentEstado()->tipoEstadoVenta->activa) + + Desistir + + + Ceder + + @else +
+ + {{ucwords($venta->currentEstado()->tipoEstadoVenta->descripcion)}} + ( + {{$format->pesos($venta->resciliacion()->valor)}} + ) +
+ @endif +
+
+ @include('ventas.show.propiedad') + @include('ventas.show.detalle') + @include('ventas.show.forma_pago', ['formaPago' => $venta->formaPago()]) + @include('ventas.show.escritura') + @include('ventas.show.entrega') + @include('ventas.show.comentarios') +
@endsection -@section('page_content') +{{--@section('page_content')

@@ -45,4 +74,4 @@ @include('ventas.show.comentarios')

-@endsection +@endsection--}}