update
This commit is contained in:
@@ -76,9 +76,9 @@ class ShowClientes extends Component
|
|||||||
|
|
||||||
if ($this->venceHoy) {
|
if ($this->venceHoy) {
|
||||||
|
|
||||||
$fecha5 = Carbon::parse($fechaHoy)->subDay(5);
|
//$fecha5 = Carbon::parse($fechaHoy)->subDay(5);
|
||||||
$consulta_clientes = $consulta_clientes->whereDate('fecha_final', '<=', $fechaHoy)
|
$consulta_clientes = $consulta_clientes->whereDate('fecha_final', $fechaHoy);
|
||||||
->whereDate('fecha_final', '>=', $fecha5);
|
//->whereDate('fecha_final', '>=', $fecha5);
|
||||||
}
|
}
|
||||||
|
|
||||||
$consulta_clientes = $consulta_clientes->with('tarifa', 'promocion', 'cliente')
|
$consulta_clientes = $consulta_clientes->with('tarifa', 'promocion', 'cliente')
|
||||||
|
|||||||
@@ -11,7 +11,8 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{-- Buscador --}}
|
{{-- Buscador --}}
|
||||||
<div class="bg-[#f5f5f5] m-auto p-2 md:p-5 rounded-[1.2rem] w-auto mb-4 x-auto grid grid-cols-1 lg:grid-cols-1text-center rounded-xl py-4 px-2 ms:px-8 xl:mx-10 mb-8 ">
|
<div
|
||||||
|
class="bg-[#f5f5f5] m-auto p-2 md:p-5 rounded-[1.2rem] w-auto mb-4 x-auto grid grid-cols-1 lg:grid-cols-1text-center rounded-xl py-4 px-2 ms:px-8 xl:mx-10 mb-8 ">
|
||||||
<div class="md:flex justify-center my-2 items-center text-center ">
|
<div class="md:flex justify-center my-2 items-center text-center ">
|
||||||
<div class="flex text-sm">
|
<div class="flex text-sm">
|
||||||
<svg class="w-4" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
|
<svg class="w-4" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||||
@@ -42,7 +43,7 @@
|
|||||||
</svg>
|
</svg>
|
||||||
</div>
|
</div>
|
||||||
<div class="text-sm mr-auto ">
|
<div class="text-sm mr-auto ">
|
||||||
<label for="cbox2">Vencidos (Hace 5 días)</label>
|
<label for="cbox2">Vencidos Hoy</label>
|
||||||
<input type="checkbox" name="" id="cbox2" wire:model="venceHoy">
|
<input type="checkbox" name="" id="cbox2" wire:model="venceHoy">
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@@ -69,10 +70,22 @@
|
|||||||
</x-slot>
|
</x-slot>
|
||||||
<x-slot name="tbody">
|
<x-slot name="tbody">
|
||||||
@foreach ($clientes as $cliente)
|
@foreach ($clientes as $cliente)
|
||||||
<tr class="border-gray-200 text-left w-full pl-4 hover:bg-gray-200 hover:ring-gray-500" x-data="{ openOption: false }">
|
<tr class="border-gray-200 text-left w-full pl-4 hover:bg-gray-200 hover:ring-gray-500"
|
||||||
|
x-data="{ openOption: false }">
|
||||||
<td class="pl-2">{{ $cliente->nombre_cliente ?? $cliente->cliente->name }}</td>
|
<td class="pl-2">{{ $cliente->nombre_cliente ?? $cliente->cliente->name }}</td>
|
||||||
|
|
||||||
<td class="pl-2">{{ $cliente->cliente->email ?? '' }}</td>
|
<td class="pl-2">
|
||||||
|
@if (!empty($cliente->cuentas_obsoletas->unique()))
|
||||||
|
@foreach ($cliente->cuentas_obsoletas->unique() as $cuenta)
|
||||||
|
{{ $cuenta->correo }} <br>
|
||||||
|
@endforeach
|
||||||
|
@endif
|
||||||
|
@if (!empty($cliente->cuentas->unique()))
|
||||||
|
@foreach ($cliente->cuentas->unique() as $cuenta1)
|
||||||
|
{{ $cuenta1->correo }} <br>
|
||||||
|
@endforeach
|
||||||
|
@endif
|
||||||
|
</td>
|
||||||
|
|
||||||
<td class="pl-2">{{ $this->consultaPassword($cliente->id) }}</td>
|
<td class="pl-2">{{ $this->consultaPassword($cliente->id) }}</td>
|
||||||
|
|
||||||
@@ -126,7 +139,9 @@
|
|||||||
|
|
||||||
@if (!empty($cliente->tarifa_id))
|
@if (!empty($cliente->tarifa_id))
|
||||||
<td class=" w-[1rem]">
|
<td class=" w-[1rem]">
|
||||||
<button class="flex m-auto gap-2 items-center bg-[#B221FD] text-white px-4 py-1 rounded-lg" wire:click="enviarNotificacion({{ $cliente->id }})">Notificar
|
<button
|
||||||
|
class="flex m-auto gap-2 items-center bg-[#B221FD] text-white px-4 py-1 rounded-lg"
|
||||||
|
wire:click="enviarNotificacion({{ $cliente->id }})">Notificar
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" version="1.1"
|
<svg xmlns="http://www.w3.org/2000/svg" version="1.1"
|
||||||
xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.com/svgjs"
|
xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.com/svgjs"
|
||||||
class="w-4" x="0" y="0" viewBox="0 0 511.996 511.996"
|
class="w-4" x="0" y="0" viewBox="0 0 511.996 511.996"
|
||||||
@@ -190,7 +205,9 @@
|
|||||||
<path
|
<path
|
||||||
d="M20,0H4A4,4,0,0,0,0,4V16a4,4,0,0,0,4,4H6.9l4.451,3.763a1,1,0,0,0,1.292,0L17.1,20H20a4,4,0,0,0,4-4V4A4,4,0,0,0,20,0ZM7,5h5a1,1,0,0,1,0,2H7A1,1,0,0,1,7,5ZM17,15H7a1,1,0,0,1,0-2H17a1,1,0,0,1,0,2Zm0-4H7A1,1,0,0,1,7,9H17a1,1,0,0,1,0,2Z" />
|
d="M20,0H4A4,4,0,0,0,0,4V16a4,4,0,0,0,4,4H6.9l4.451,3.763a1,1,0,0,0,1.292,0L17.1,20H20a4,4,0,0,0,4-4V4A4,4,0,0,0,20,0ZM7,5h5a1,1,0,0,1,0,2H7A1,1,0,0,1,7,5ZM17,15H7a1,1,0,0,1,0-2H17a1,1,0,0,1,0,2Zm0-4H7A1,1,0,0,1,7,9H17a1,1,0,0,1,0,2Z" />
|
||||||
</svg></button>
|
</svg></button>
|
||||||
<button x-on:click="openOption=!openOption" wire:click="enviarNotificacion({{ $cliente->id }})" class=" md:hidden hover:fill-white fill-gray-500 flex justify-center items-center gap-2 text-gray-500 w-full py-1 hover:bg-[#00be00] hover:text-white border-b border-gray-300 ">Notificar
|
<button x-on:click="openOption=!openOption"
|
||||||
|
wire:click="enviarNotificacion({{ $cliente->id }})"
|
||||||
|
class=" md:hidden hover:fill-white fill-gray-500 flex justify-center items-center gap-2 text-gray-500 w-full py-1 hover:bg-[#00be00] hover:text-white border-b border-gray-300 ">Notificar
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" version="1.1"
|
<svg xmlns="http://www.w3.org/2000/svg" version="1.1"
|
||||||
xmlns:xlink="http://www.w3.org/1999/xlink"
|
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||||
xmlns:svgjs="http://svgjs.com/svgjs" class="w-4" x="0"
|
xmlns:svgjs="http://svgjs.com/svgjs" class="w-4" x="0"
|
||||||
|
|||||||
Reference in New Issue
Block a user