<?php

namespace App\Modules\Booking\Infraestructure;

class BookingValidators
{

    public const ALTER_INSERT = [
        'Id_User'                           => 'int',
        'User_Name'                         => 'required|string|max:100',
        'User_LastName'                     => 'required|string|max:100',
        'User_Email'                        => 'required|string|max:250',
        'User_Phone'                        => 'string|max:20',
        'Id_UserCountry'                    => 'required|int',

        'Booking'                           => 'required|string',
        'Id_WebContactMessage'              => 'int',
        'WebContactMessage'                 => 'array',
        'WebContactMessage.*'               => 'int',
    ];

    public const ALTER_INSERT_BOOKING = [

        'Booking_DateStart'                 => 'required|string|date',
        'Booking_Receipt'                   => 'required|int',
        'Booking_Type_Real'                 => 'required|int',
        'Id_Language'                       => 'required|int',
        'Id_GuideLanguage'                  => 'required|int',
        'Booking_InPerson'                  => 'required|int',
        'Id_BookingRelationship'            => 'required|int',
        'Id_BookingReferredFrom'            => 'required|int',
        'Booking_NoPax'                     => 'required|int',
        'Id_Package'                        => 'required|int',
        'Booking_Type'                      => 'required|int',

        'Passenger'                         => 'required|array',
        'Passenger.*.Passenger_Name'        => 'string|max:100',
        'Passenger.*.Passenger_LastName'    => 'string|max:100',
        'Passenger.*.Passenger_Email'       => 'string|max:250',
        'Passenger.*.Passenger_Phone'       => 'string|max:50',
        'Passenger.*.Passenger_Gender'      => 'required|int',
        'Passenger.*.Passenger_DOB'         => 'required|string|date',
        'Passenger.*.Passenger_NoDocument'  => 'string|max:20',
        'Passenger.*.Passenger_Restriction' => 'string',
        'Passenger.*.Passenger_Extras'      => 'string',
        'Passenger.*.Id_TypeDocument'       => 'required|int',
        'Passenger.*.Id_TypeRate'           => 'required|int',
        'Passenger.*.Id_UserCountry'        => 'required|int',

        'Tour'                              => 'required|array',
        'Tour.*.BookingTour_DateStart'      => 'required|string|date',
        'Tour.*.Id_Tour'                    => 'required|int',
    ];

    public const INSERT = [
        'Id_User'               => 'int',
        'User_Name'             => 'required|string|max:100',
        'User_LastName'         => 'required|string|max:100',
        'User_Email'            => 'required|string|max:250',
        'User_Phone'            => 'string|max:20',
        'Id_UserCountry'        => 'required|int',
        'Booking'               => 'required|string',
        'CashMovement'          => 'required|string'
    ];

    public const EXPORT_TO_EXCEL = [
        'Booking_Status'    => 'required|int',
        'DateStart'         => 'required|string|date',
        'DateEnd'           => 'required|string|date',
        'Query'             => 'string|max:250',
        'User_Type'         => 'required|int',
        'Booking_Type'      => 'required|int'
    ];

    public const UPDATE = [
        'Id_Booking'                => 'required|int',
        'Booking_DateBriefing'      => 'required|string',
        'Booking_PlaceBriefing'     => 'string',
        'Booking_Hotel'             => 'string',
        'Booking_Observation'       => 'string',
        'Booking_Type'              => 'required|int',
        'Booking_InPerson'          => 'required|int',
        'Id_Language'               => 'required|int',
        'Id_GuideLanguage'          => 'required|int',
        'Id_BookingRelationship'    => 'required|int',
        'Id_BookingReferredFrom'    => 'required|int'
    ];

    public const UPDATE_MANUALLY_CONFIRMED = [
        'Id_Booking'                => 'required|int',
        'Booking_ManuallyConfirmed' => 'required|int'
    ];

    public const SEARCH_DATE = [
        'Date_Start'        => 'required|string',
        'Date_End'          => 'required|string',
        'Booking_Status'    => 'required|int'
    ];

    public const SEARCH_BOOKING = [
        'Booking_Code'    => 'required|string|max:100'
    ];

    public const SEARCH_CONFIRM = [
        'Date_Start'        => 'required|string',
        'Date_End'          => 'required|string',
        'Order_By'          => 'required|string'
    ];

    public const SEARCH_CONFIRM_EXCEL = [
        'Date_Start'        => 'required|string',
        'Date_End'          => 'required|string',
        'Order_By'          => 'required|string',
        'User_Type'         => 'required|int',
        'Booking_Type'      => 'int',
        'Id_Admin'          => 'int',
        'Search'            => 'string'
    ];

    public const SEARCH_DAY_EXCEL = [
        'Date_Start'        => 'required|string',
        'Date_End'          => 'required|string',
        'Order_By'          => 'required|string',
        'User_Type'         => 'required|int',
        'Booking_Type'      => 'int',
        'Id_Admin'          => 'int',
        'Search'            => 'string'
    ];

    public const LIST = [
        'Id_User'           => 'required|int',
        'Date_Start'        => 'required|string|date',
        'Date_End'          => 'required|string|date',
        'Booking_Status'    => 'required|int'
    ];

    public const REPORT = [
        'Name'              => 'required|string|max:100'
    ];
}
