formatear fechas
This commit is contained in:
@@ -128,8 +128,8 @@ class ShowPlanes extends Component
|
|||||||
$consulta_tarifas = Tarifas::take(1);
|
$consulta_tarifas = Tarifas::take(1);
|
||||||
|
|
||||||
if (empty($this->fecha_inicial)) {
|
if (empty($this->fecha_inicial)) {
|
||||||
$this->fecha_inicial = Carbon::now()->format('Y-m-d');
|
$this->fecha_inicial = Carbon::now()->toDateTimeString();
|
||||||
$this->fecha_final = Carbon::now()->addDay(30)->format('Y-m-d');
|
$this->fecha_final = Carbon::now()->addDay(30)->toDateTimeString();
|
||||||
}
|
}
|
||||||
if ($this->servicio_modTarifas) {
|
if ($this->servicio_modTarifas) {
|
||||||
$this->tarifas = Tarifas::with('rol')
|
$this->tarifas = Tarifas::with('rol')
|
||||||
@@ -222,8 +222,9 @@ class ShowPlanes extends Component
|
|||||||
|
|
||||||
public function calcularFechas()
|
public function calcularFechas()
|
||||||
{
|
{
|
||||||
$this->fecha_inicial_renovar = now()->format('Y-m-d');
|
$this->fecha_inicial_renovar = now()->format('Y-m-d H:i:s');
|
||||||
$this->fecha_final_renovar = now()->addDays(30)->format('Y-m-d');
|
$this->fecha_final_renovar = now()->addDays(30)->format('Y-m-d H:i:s');
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -26,8 +26,8 @@ class UsersImport implements ToModel
|
|||||||
'correo' => $row[0],
|
'correo' => $row[0],
|
||||||
'password' => $row[1],
|
'password' => $row[1],
|
||||||
'estado' => $row[2],
|
'estado' => $row[2],
|
||||||
'inicio' => \PhpOffice\PhpSpreadsheet\Shared\Date::excelToDateTimeObject($row[3]),
|
'inicio' => \PhpOffice\PhpSpreadsheet\Shared\Date::excelToDateTimeObject($row[3])->format('Y-m-d H:i:s'),
|
||||||
'vencimiento' => \PhpOffice\PhpSpreadsheet\Shared\Date::excelToDateTimeObject($row[4]),
|
'vencimiento' => \PhpOffice\PhpSpreadsheet\Shared\Date::excelToDateTimeObject($row[4])->format('Y-m-d H:i:s'),
|
||||||
'servicio_id' => $row[5],
|
'servicio_id' => $row[5],
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user