@extends('layout.base')

@section('page_title')
    Venta {{$venta->proyecto()->descripcion}} {{$venta->propiedad()->summary()}}
@endsection

@section('page_content')
    <div class="ui container">
        <div class="ui two column grid">
            <h1 class="four wide column header">
                <div class="content">
                    <div class="ui dividing sub header">{{$venta->proyecto()->descripcion}}</div>
                    {{$venta->propiedad()->summary()}}
                </div>
            </h1>
            <div class="right floated column">
                @include('ventas.show.propietario')
            </div>
        </div>
        <br />
        <div class="ui fitted basic mini segment">
            @if ($venta->currentEstado()->tipoEstadoVenta->activa)
            <a href="{{$urls->base}}/venta/{{$venta->id}}/desistir">
                Desistir <i class="minus icon"></i>
            </a>
            <a href="{{$urls->base}}/venta/{{$venta->id}}/ceder">
                Ceder <i clasS="right chevron icon"></i>
            </a>
            @endif
        </div>
        <div class="ui segments">
            @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')
        </div>
    </div>
@endsection
