@extends('ventas.promotions.base') @section('promotions_content')
Promoción | Tipo | Valor | Fecha Inicio | Fecha Término | Válido Hasta | Contratos | |
---|---|---|---|---|---|---|---|
{{ $promotion->description }} | {{ ucwords($promotion->type->name()) }} | {{ ($promotion->type === Incoviba\Model\Venta\Promotion\Type::FIXED) ? $format->ufs($promotion->amount) : $format->percent($promotion->amount, 2, true) }} | {{ $promotion->startDate->format('d-m-Y') }} | {{ $promotion->endDate?->format('d-m-Y') }} | {{ $promotion->validUntil?->format('d-m-Y') }} |
Proyectos: {{ count($promotion->projects()) +
count(array_unique(array_map(function($unitType) {return $unitType->project;},$promotion->unitTypes()))) +
count(array_unique(array_map(function($unitLine) {return $unitLine->proyecto;},$promotion->unitLines()))) +
count($promotion->units()) }} Operadores: {{ count($promotion->brokers()) }} |