fix modal clientes
This commit is contained in:
@@ -50,10 +50,11 @@ class ShowClientes extends Component
|
||||
$this->fechaActual = date('d/m/Y');
|
||||
$fechaVencimiento = Carbon::now()->subDay(30);
|
||||
|
||||
$consulta_clientes = Historiale::where('vendedor_id', Auth()->user()->id)->whereDate('fecha_final', '>', $fechaVencimiento);
|
||||
// $consulta_clientes = Historiale::whereDate('fecha_final', '>', $fechaVencimiento);
|
||||
$consulta_clientes = Historiale::
|
||||
where('vendedor_id', Auth()->user()->id)->
|
||||
whereDate('fecha_final', '>', $fechaVencimiento);
|
||||
|
||||
$this->configuracion = User::where('id', Auth::user()->id)->whereDate('updated_at', '!=', $fechaHoy)->first();
|
||||
$this->configuracion = User::where('id', Auth::user()->id)->whereDate('updated_at', '!=', Carbon::now())->first();
|
||||
|
||||
if ($this->configuracion) {
|
||||
$this->vencidosHoy = true;
|
||||
@@ -72,20 +73,13 @@ class ShowClientes extends Component
|
||||
}
|
||||
|
||||
if ($this->venceHoy) {
|
||||
|
||||
//$fecha5 = Carbon::parse($fechaHoy)->subDay(5);
|
||||
$consulta_clientes = $consulta_clientes->whereDate('fecha_final', $fechaHoy);
|
||||
//->whereDate('fecha_final', '>=', $fecha5);
|
||||
}
|
||||
|
||||
$consulta_clientes = $consulta_clientes->with('tarifa', 'promocion', 'cliente')
|
||||
->orderBy('id', 'DESC')
|
||||
->paginate($this->entradas);
|
||||
|
||||
|
||||
|
||||
// dd($consulta_clientes);
|
||||
|
||||
return view('livewire.show-clientes', [
|
||||
'clientes' => $consulta_clientes
|
||||
]);
|
||||
|
||||
Reference in New Issue
Block a user