Solo lectura. Compara el archivo real contra P001 y contra otras instalaciones del mismo stream.
app/Http/Controllers/PanelReservaController.phpcaef79695c0c2298553554a4795ed6a7dc079b9831b1a02f58de84219e25dceb/home4/silvasih/sistemas/hotel-vigo16d2cb08c694237507455862eb6f2c78a7ecb4af005b7b437e3296d1e6fea26e| Instalación | Relación | SHA-256 | Tamaño | |
|---|---|---|---|---|
| Hotel Monumental HOT0008 |
IGUAL A ESTA INSTALACIÓN | 16d2cb08c694237507455862eb6f2c78a7ecb4af005b7b437e3296d1e6fea26e |
2,506 bytes | Comparar peer |
| Hotel Occidental HOT-OCCIDENTAL |
IGUAL A ESTA INSTALACIÓN | 16d2cb08c694237507455862eb6f2c78a7ecb4af005b7b437e3296d1e6fea26e |
2,506 bytes | Comparar peer |
| Hotel Astur HOT0004 |
DIFERENTE | c63837e5367f634cc49bcc92d160310a08e5fc63386caab81438e2f1dfd29afb |
990 bytes | Comparar peer |
| Hotel Centro HOT0005 |
DIFERENTE | c63837e5367f634cc49bcc92d160310a08e5fc63386caab81438e2f1dfd29afb |
990 bytes | Comparar peer |
| Hotel Galaico HOT0006 |
DIFERENTE | c63837e5367f634cc49bcc92d160310a08e5fc63386caab81438e2f1dfd29afb |
990 bytes | Comparar peer |
| Hotel La Paz HOT0007 |
DIFERENTE | c63837e5367f634cc49bcc92d160310a08e5fc63386caab81438e2f1dfd29afb |
990 bytes | Comparar peer |
| Hotel Luar HOT0002 |
DIFERENTE | c63837e5367f634cc49bcc92d160310a08e5fc63386caab81438e2f1dfd29afb |
990 bytes | Comparar peer |
| Hotel Metro HOT0003 |
DIFERENTE | c63837e5367f634cc49bcc92d160310a08e5fc63386caab81438e2f1dfd29afb |
990 bytes | Comparar peer |
| Hotel Morelos HOT0009 |
DIFERENTE | c63837e5367f634cc49bcc92d160310a08e5fc63386caab81438e2f1dfd29afb |
990 bytes | Comparar peer |
| Hotel Platino HOT0010 |
DIFERENTE | c63837e5367f634cc49bcc92d160310a08e5fc63386caab81438e2f1dfd29afb |
990 bytes | Comparar peer |
| Hotel Sol HOT0001 |
DIFERENTE | 73a5be928a46e046713f4a921e078eb833d828d59aaa4204fa6d081d7792fb0d |
988 bytes | Comparar peer |
| Hotel Rincón HOT0011 |
FALTANTE | — |
— |
--- CANONICAL P001
+++ Hotel Vigo
@@ -1,63 +1,63 @@
#Warning: Strings contain different line endings!
-<?php
-
-namespace App\Http\Controllers;
-
-use Illuminate\Http\Request;
-use Illuminate\Support\Carbon;
-use Illuminate\Support\Facades\DB;
-use Illuminate\Support\Facades\Schema;
-
-class PanelReservaController extends Controller
-{
- public function __construct()
- {
- $this->middleware('auth');
- }
-
- //
- public function index(){
- $mytime = Carbon::now('America/Mexico_City');
- $fecha = $mytime->toDateString();
-
- $ayer = date("Y-m-d",strtotime($fecha."- 1 days"));
- $res_ayer = DB::table('apartar')
- ->whereBetween('fecIn', array($ayer . ' 00:00:01', $ayer . ' 23:59:59'))
- ->count();
-
- $res_hoy = DB::table('apartar')
- ->whereBetween('fecIn', array($fecha . ' 00:00:01', $fecha . ' 23:59:59'))
- ->count();
-
- $maniana = date("Y-m-d",strtotime($fecha."+ 1 days"));
- $res_maniana = DB::table('apartar')
- ->whereBetween('fecIn', array($maniana . ' 00:00:01', $maniana . ' 23:59:59'))
- ->count();
- $res_mes = DB::table('apartar')
- ->whereMonth('fecIn', date("m",strtotime($fecha)))
- ->count();
-
- $inicioMes = date('Y-m-01 00:00:00', strtotime($fecha));
- $finMes = date('Y-m-t 23:59:59', strtotime($fecha));
- $porCanal = DB::table('apartar')
- ->select(DB::raw("COALESCE(origen_reserva, 'RECEPCION') as canal"), DB::raw('COUNT(*) as total'))
- ->whereBetween('fecIn', [$inicioMes, $finMes])
- ->groupBy('canal')
- ->orderByDesc('total')
- ->get();
-
- // HOTFIX 0033.8.1:
- // El estado de sincronización pertenece a channel_sync_queue.estado,
- // no a apartar.estado_canal. Si la cola no existe, el panel sigue
- // operando y muestra 0 pendientes en lugar de producir HTTP 500.
- $pendientesSync = 0;
- if (Schema::hasTable('channel_sync_queue') && Schema::hasColumn('channel_sync_queue', 'estado')) {
- $pendientesSync = DB::table('channel_sync_queue')
- ->where('estado', 'PENDIENTE')
- ->count();
- }
-
- $reservasExternas = DB::table('apartar')->whereNotIn('origen_reserva', ['RECEPCION','TELEFONO','WHATSAPP'])->whereBetween('fecIn', [$inicioMes, $finMes])->count();
-
- return view('panel-reserva.index', compact("res_mes", "res_ayer", "res_hoy", "res_maniana", "porCanal", "pendientesSync", "reservasExternas"));
- }
-}
+<?php
+
+namespace App\Http\Controllers;
+
+use Illuminate\Http\Request;
+use Illuminate\Support\Carbon;
+use Illuminate\Support\Facades\DB;
+use Illuminate\Support\Facades\Schema;
+
+class PanelReservaController extends Controller
+{
+ public function __construct()
+ {
+ $this->middleware('auth');
+ }
+
+ //
+ public function index(){
+ $mytime = Carbon::now('America/Mexico_City');
+ $fecha = $mytime->toDateString();
+
+ $ayer = date("Y-m-d",strtotime($fecha."- 1 days"));
+ $res_ayer = DB::table('apartar')
+ ->whereBetween('fecIn', array($ayer . ' 00:00:01', $ayer . ' 23:59:59'))
+ ->count();
+
+ $res_hoy = DB::table('apartar')
+ ->whereBetween('fecIn', array($fecha . ' 00:00:01', $fecha . ' 23:59:59'))
+ ->count();
+
+ $maniana = date("Y-m-d",strtotime($fecha."+ 1 days"));
+ $res_maniana = DB::table('apartar')
+ ->whereBetween('fecIn', array($maniana . ' 00:00:01', $maniana . ' 23:59:59'))
+ ->count();
+ $res_mes = DB::table('apartar')
+ ->whereMonth('fecIn', date("m",strtotime($fecha)))
+ ->count();
+
+ $inicioMes = date('Y-m-01 00:00:00', strtotime($fecha));
+ $finMes = date('Y-m-t 23:59:59', strtotime($fecha));
+ $porCanal = DB::table('apartar')
+ ->select(DB::raw("COALESCE(origen_reserva, 'RECEPCION') as canal"), DB::raw('COUNT(*) as total'))
+ ->whereBetween('fecIn', [$inicioMes, $finMes])
+ ->groupBy('canal')
+ ->orderByDesc('total')
+ ->get();
+
+ // HOTFIX 0033.8.1:
+ // El estado de sincronización pertenece a channel_sync_queue.estado,
+ // no a apartar.estado_canal. Si la cola no existe, el panel sigue
+ // operando y muestra 0 pendientes en lugar de producir HTTP 500.
+ $pendientesSync = 0;
+ if (Schema::hasTable('channel_sync_queue') && Schema::hasColumn('channel_sync_queue', 'estado')) {
+ $pendientesSync = DB::table('channel_sync_queue')
+ ->where('estado', 'PENDIENTE')
+ ->count();
+ }
+
+ $reservasExternas = DB::table('apartar')->whereNotIn('origen_reserva', ['RECEPCION','TELEFONO','WHATSAPP'])->whereBetween('fecIn', [$inicioMes, $finMes])->count();
+
+ return view('panel-reserva.index', compact("res_mes", "res_ayer", "res_hoy", "res_maniana", "porCanal", "pendientesSync", "reservasExternas"));
+ }
+}