diff --git a/.env b/.env index e44c26b..76f561d 100755 --- a/.env +++ b/.env @@ -3,7 +3,7 @@ APP_ENV=local APP_KEY=base64:cxq+xNckU1xLwp8V9Bfj9+nOK5iZL6urcZ1EBO8usXg= APP_DEBUG=true APP_URL=http://mein.sterntours.local -APP_OLD_URL = http://cms-stern-tours.local +APP_OLD_URL=https://cms-stern-tours.local #APP_URL_V2=https://v2.stern-tours.de APP_URL_V2=http://v2-sterntours.local diff --git a/.idea/mein.sterntours.iml b/.idea/mein.sterntours.iml index e467651..512c226 100644 --- a/.idea/mein.sterntours.iml +++ b/.idea/mein.sterntours.iml @@ -29,6 +29,7 @@ + diff --git a/.idea/php.xml b/.idea/php.xml index a6960fa..f1e68aa 100644 --- a/.idea/php.xml +++ b/.idea/php.xml @@ -128,6 +128,7 @@ + diff --git a/.idea/workspace.xml b/.idea/workspace.xml index ac223c7..817ada6 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,7 +2,62 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -22,8 +77,11 @@ - - + + + + + @@ -31,36 +89,30 @@ - - + + + + + + + + + - - - - - - - - - - - - - - - - - - - + + + + - - + - + + + + @@ -101,19 +153,39 @@ - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -296,6 +368,7 @@ + @@ -315,24 +388,24 @@ - + - - - - - - - - - - - - + + + + + + + + + + + + @@ -596,6 +669,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + @@ -622,37 +720,53 @@ - - + + + + - + + + + + + + + + + - + + - + + - + + - + + - + - + + \ No newline at end of file diff --git a/.phpstorm.meta.php b/.phpstorm.meta.php index a2d63c7..d1ca819 100644 --- a/.phpstorm.meta.php +++ b/.phpstorm.meta.php @@ -5,7 +5,7 @@ namespace PHPSTORM_META { /** * PhpStorm Meta file, to provide autocomplete information for PhpStorm - * Generated on 2019-12-28 16:01:55. + * Generated on 2020-02-10 17:24:00. * * @author Barry vd. Heuvel * @see https://github.com/barryvdh/laravel-ide-helper diff --git a/_ide_helper.php b/_ide_helper.php index 3ccd4a3..b2d1393 100644 --- a/_ide_helper.php +++ b/_ide_helper.php @@ -3,7 +3,7 @@ /** * A helper file for Laravel 5, to provide autocomplete information to your IDE - * Generated for Laravel 5.8.36 on 2019-12-28 16:01:54. + * Generated for Laravel 5.8.36 on 2020-02-10 17:24:00. * * This file should not be included in your code, only analyzed by your IDE! * diff --git a/_ide_helper_models.php b/_ide_helper_models.php index 29acc2c..1eeb96a 100644 --- a/_ide_helper_models.php +++ b/_ide_helper_models.php @@ -80,6 +80,94 @@ namespace App{ class User extends \Eloquent {} } +namespace App\Models{ +/** + * App\Models\Booking + * + * @property int $id + * @property string|null $booking_date + * @property int $customer_id + * @property int|null $lead_id + * @property int|null $new_drafts + * @property int $sf_guard_user_id + * @property int $branch_id + * @property float|null $service_fee + * @property int|null $travel_country_id + * @property int|null $travel_category_id + * @property int|null $pax + * @property int|null $coupon_id + * @property \Illuminate\Support\Carbon $created_at + * @property \Illuminate\Support\Carbon $updated_at + * @property string|null $title + * @property string|null $start_date + * @property string|null $end_date + * @property int|null $website_id + * @property string|null $travel_number + * @property string|null $participant_name + * @property string|null $participant_firstname + * @property string|null $participant_birthdate + * @property int|null $participant_salutation_id + * @property string|null $ev_number + * @property string|null $merlin_knr + * @property string|null $merlin_order_number + * @property int|null $travel_company_id + * @property int|null $travel_documents + * @property float|null $price + * @property float|null $price_total + * @property float|null $deposit_total + * @property float|null $final_payment + * @property string|null $final_payment_date + * @property int|null $travelagenda_id + * @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\Sym\Arrangement[] $arrangements + * @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\BookingDraftItem[] $booking_draft_items + * @property-read \App\Models\TravelCountry|null $lead + * @property-read \App\Models\SfGuardUser $sf_guard_user + * @property-read \App\Models\TravelAgenda|null $travel_agenda + * @property-read \App\Models\TravelCountry|null $travel_country + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereBookingDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereBranchId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereCouponId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereCreatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereCustomerId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereDepositTotal($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereEndDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereEvNumber($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereFinalPayment($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereFinalPaymentDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereLeadId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereMerlinKnr($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereMerlinOrderNumber($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereNewDrafts($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereParticipantBirthdate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereParticipantFirstname($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereParticipantName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereParticipantSalutationId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking wherePax($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking wherePrice($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking wherePriceTotal($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereServiceFee($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereSfGuardUserId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereStartDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereTitle($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereTravelCategoryId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereTravelCompanyId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereTravelCountryId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereTravelDocuments($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereTravelNumber($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereTravelagendaId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereUpdatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereWebsiteId($value) + * @mixin \Eloquent + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking query() + * @property-read int|null $arrangements_count + * @property-read int|null $booking_draft_items_count + */ + class _Booking extends \Eloquent {} +} + namespace App\Models\Sym{ /** * App\Models\Sym\TravelCountry @@ -248,48 +336,75 @@ namespace App\Models{ namespace App\Models{ /** - * App\Models\Booking + * Class Booking * * @property int $id - * @property string|null $booking_date + * @property Carbon $booking_date * @property int $customer_id - * @property int|null $lead_id - * @property int|null $new_drafts + * @property int $lead_id + * @property bool $new_drafts * @property int $sf_guard_user_id * @property int $branch_id - * @property float|null $service_fee - * @property int|null $travel_country_id - * @property int|null $travel_category_id - * @property int|null $pax - * @property int|null $coupon_id - * @property \Illuminate\Support\Carbon $created_at - * @property \Illuminate\Support\Carbon $updated_at - * @property string|null $title - * @property string|null $start_date - * @property string|null $end_date - * @property int|null $website_id - * @property string|null $travel_number - * @property string|null $participant_name - * @property string|null $participant_firstname - * @property string|null $participant_birthdate - * @property int|null $participant_salutation_id - * @property string|null $ev_number - * @property string|null $merlin_knr - * @property string|null $merlin_order_number - * @property int|null $travel_company_id - * @property int|null $travel_documents - * @property float|null $price - * @property float|null $price_total - * @property float|null $deposit_total - * @property float|null $final_payment - * @property string|null $final_payment_date - * @property int|null $travelagenda_id - * @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\Sym\Arrangement[] $arrangements - * @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\BookingDraftItem[] $booking_draft_items - * @property-read \App\Models\TravelCountry|null $lead - * @property-read \App\Models\SfGuardUser $sf_guard_user - * @property-read \App\Models\TravelAgenda|null $travel_agenda - * @property-read \App\Models\TravelCountry|null $travel_country + * @property float $service_fee + * @property int $travel_country_id + * @property int $travel_category_id + * @property int $pax + * @property int $coupon_id + * @property Carbon $created_at + * @property Carbon $updated_at + * @property string $title + * @property Carbon $start_date + * @property Carbon $end_date + * @property int $website_id + * @property string $travel_number + * @property string $participant_name + * @property string $participant_firstname + * @property Carbon $participant_birthdate + * @property int $participant_salutation_id + * @property string $ev_number + * @property string $merlin_knr + * @property string $merlin_order_number + * @property int $travel_company_id + * @property bool $travel_documents + * @property float $price + * @property float $price_total + * @property float $deposit_total + * @property float $final_payment + * @property Carbon $final_payment_date + * @property int $travelagenda_id + * @property Branch $branch + * @property Coupon $coupon + * @property Customer $customer + * @property Lead $lead + * @property SfGuardUser $sf_guard_user + * @property TravelCategory $travel_category + * @property TravelCompany $travel_company + * @property TravelCountry $travel_country + * @property TravelAgenda $travel_agenda + * @property Collection|Arrangement[] $arrangements + * @property Collection|ArrangementType[] $arrangement_types + * @property Collection|BookingApplication[] $booking_applications + * @property Collection|BookingConfirmation[] $booking_confirmations + * @property Collection|BookingDraftItem[] $booking_draft_items + * @property Collection|BookingInvoice[] $booking_invoices + * @property Collection|BookingServiceItem[] $booking_service_items + * @property Collection|BookingVoucher[] $booking_vouchers + * @property Collection|Coupon[] $coupons + * @property Collection|InsuranceCertificate[] $insurance_certificates + * @property Collection|Participant[] $participants + * @property Collection|ServiceProviderEntry[] $service_provider_entries + * @property Collection|TravelInsurance[] $travel_insurances + * @package App\Models + * @property-read int|null $arrangement_types_count + * @property-read int|null $arrangements_count + * @property-read int|null $booking_draft_items_count + * @property-read int|null $booking_service_items_count + * @property-read int|null $coupons_count + * @property-read int|null $insurance_certificates_count + * @property-read int|null $participants_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking query() * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereBookingDate($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereBranchId($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereCouponId($value) @@ -325,15 +440,50 @@ namespace App\Models{ * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereUpdatedAt($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking whereWebsiteId($value) * @mixin \Eloquent - * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking newModelQuery() - * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking newQuery() - * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Booking query() - * @property-read int|null $arrangements_count - * @property-read int|null $booking_draft_items_count + * @property-read int|null $service_provider_entries_count */ class Booking extends \Eloquent {} } +namespace App\Models{ +/** + * Class ServiceProviderEntry + * + * @property int $id + * @property int $booking_id + * @property int $service_provider_id + * @property float $amount + * @property float $amount_eur + * @property float $factor + * @property Carbon $payment_date + * @property string $invoice_number + * @property bool $is_cleared + * @property Carbon $created_at + * @property Carbon $updated_at + * @property string $type + * @property Booking $booking + * @property ServiceProvider $service_provider + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereAmount($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereAmountEur($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereBookingId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereCreatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereFactor($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereInvoiceNumber($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereIsCleared($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry wherePaymentDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereServiceProviderId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereType($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProviderEntry whereUpdatedAt($value) + * @mixin \Eloquent + */ + class ServiceProviderEntry extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\UserUpdateEmail @@ -355,6 +505,43 @@ namespace App\Models{ class UserUpdateEmail extends \Eloquent {} } +namespace App\Models{ +/** + * Class BookingServiceItem + * + * @property int $id + * @property int $booking_id + * @property int $travel_company_id + * @property float $service_price + * @property float $service_price_refund + * @property float $commission + * @property Carbon $travel_date + * @property Carbon $created_at + * @property Carbon $updated_at + * @property string $name + * @property bool $is_commission_locked + * @property Booking $booking + * @property TravelCompany $travel_company + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereBookingId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereCommission($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereCreatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereIsCommissionLocked($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereServicePrice($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereServicePriceRefund($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereTravelCompanyId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereTravelDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\BookingServiceItem whereUpdatedAt($value) + * @mixin \Eloquent + */ + class BookingServiceItem extends \Eloquent {} +} + namespace App\Models{ /** * Class FewoLodging @@ -564,10 +751,57 @@ namespace App\Models{ * @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\IQContentSite[] $iq_content_sites * @property-read int|null $iq_content_sites_count * @property-read int|null $iq_content_tree_node_childs_count + * @property string|null $title + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\IQContentTreeNode whereTitle($value) */ class IQContentTreeNode extends \Eloquent {} } +namespace App\Models{ +/** + * Class Offer + * + * @property int $id + * @property int $lead_id + * @property float $total + * @property boolean $binary_data + * @property Carbon $created_at + * @property Carbon $updated_at + * @property Lead $lead + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Offer newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Offer newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Offer query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Offer whereBinaryData($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Offer whereCreatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Offer whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Offer whereLeadId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Offer whereTotal($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Offer whereUpdatedAt($value) + * @mixin \Eloquent + */ + class Offer extends \Eloquent {} +} + +namespace App\Models{ +/** + * Class Website + * + * @property int $id + * @property string $name + * @property Collection|Lead[] $leads + * @package App\Models + * @property-read int|null $leads_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Website newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Website newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Website query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Website whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Website whereName($value) + * @mixin \Eloquent + */ + class Website extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\CMSInfoHoliday @@ -594,6 +828,25 @@ namespace App\Models{ class CMSInfoHoliday extends \Eloquent {} } +namespace App\Models{ +/** + * Class Searchengine + * + * @property int $id + * @property string $name + * @property Collection|Lead[] $leads + * @package App\Models + * @property-read int|null $leads_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Searchengine newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Searchengine newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Searchengine query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Searchengine whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Searchengine whereName($value) + * @mixin \Eloquent + */ + class Searchengine extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\TravelNationalityRequirement @@ -616,6 +869,107 @@ namespace App\Models{ class TravelNationalityRequirement extends \Eloquent {} } +namespace App\Models{ +/** + * Class TravelBooking + * + * @property int $id + * @property int $salutation_id + * @property string $first_name + * @property string $last_name + * @property string $street + * @property string $zipcode + * @property string $city + * @property int $country_id + * @property string $fax + * @property string $phone + * @property string $mobile + * @property string $comments + * @property string $email + * @property Carbon $created + * @property Carbon $selected_start_date + * @property Carbon $selected_end_date + * @property string $program_name + * @property string $selected_travel + * @property string $selected_departure + * @property int $program_id + * @property int $period_id + * @property string $class + * @property int $selected_adults + * @property int $selected_childs + * @property int $participants_total + * @property string $participants + * @property string $drafts + * @property string $service_items + * @property string $arrangements + * @property string $rooms + * @property float $price + * @property float $price_total + * @property float $deposit_total + * @property float $final_payment + * @property Carbon $final_payment_date + * @property string $insurance_name + * @property string $insurances + * @property int $travel_cancellation + * @property string $options + * @property string $class_options + * @property string $extra_category + * @property bool $accept_legal_rights + * @property string $ip + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereAcceptLegalRights($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereArrangements($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereCity($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereClass($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereClassOptions($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereComments($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereCountryId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereCreated($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereDepositTotal($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereDrafts($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereEmail($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereExtraCategory($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereFax($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereFinalPayment($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereFinalPaymentDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereFirstName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereInsuranceName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereInsurances($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereIp($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereLastName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereMobile($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereOptions($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereParticipants($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereParticipantsTotal($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking wherePeriodId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking wherePhone($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking wherePrice($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking wherePriceTotal($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereProgramId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereProgramName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereRooms($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereSalutationId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereSelectedAdults($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereSelectedChilds($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereSelectedDeparture($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereSelectedEndDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereSelectedStartDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereSelectedTravel($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereServiceItems($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereStreet($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereTravelCancellation($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereZipcode($value) + * @mixin \Eloquent + * @property int|null $crm_booking_id + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelBooking whereCrmBookingId($value) + */ + class TravelBooking extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\BookingDraftItem @@ -709,6 +1063,25 @@ namespace App\Models{ class Country extends \Eloquent {} } +namespace App\Models{ +/** + * Class InitialContactType + * + * @property int $id + * @property string $name + * @property Collection|Lead[] $leads + * @package App\Models + * @property-read int|null $leads_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InitialContactType newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InitialContactType newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InitialContactType query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InitialContactType whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InitialContactType whereName($value) + * @mixin \Eloquent + */ + class InitialContactType extends \Eloquent {} +} + namespace App\Models{ /** * Class FewoLodgingType @@ -833,6 +1206,33 @@ namespace App\Models{ class FewoLodgingImage extends \Eloquent {} } +namespace App\Models{ +/** + * Class LeadParticipant + * + * @property int $id + * @property int $lead_id + * @property string $participant_name + * @property string $participant_firstname + * @property Carbon $participant_birthdate + * @property int $participant_salutation_id + * @property Lead $lead + * @property Salutation $salutation + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereLeadId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereParticipantBirthdate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereParticipantFirstname($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereParticipantName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\LeadParticipant whereParticipantSalutationId($value) + * @mixin \Eloquent + */ + class LeadParticipant extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\Account @@ -857,6 +1257,28 @@ namespace App\Models{ class Account extends \Eloquent {} } +namespace App\Models{ +/** + * Class InquiryType + * + * @property int $id + * @property string $name + * @property int $arrangement_type_id + * @property ArrangementType $arrangement_type + * @property Collection|Inquiry[] $inquiries + * @package App\Models + * @property-read int|null $inquiries_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryType newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryType newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryType query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryType whereArrangementTypeId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryType whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryType whereName($value) + * @mixin \Eloquent + */ + class InquiryType extends \Eloquent {} +} + namespace App\Models{ /** * Class FewoReservation @@ -941,6 +1363,31 @@ namespace App\Models{ class TravelCountry extends \Eloquent {} } +namespace App\Models{ +/** + * Class Salutation + * + * @property int $id + * @property string $name + * @property Collection|Customer[] $customers + * @property Collection|Lead[] $leads + * @property Collection|LeadParticipant[] $lead_participants + * @property Collection|Participant[] $participants + * @package App\Models + * @property-read int|null $customers_count + * @property-read int|null $lead_participants_count + * @property-read int|null $leads_count + * @property-read int|null $participants_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Salutation newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Salutation newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Salutation query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Salutation whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Salutation whereName($value) + * @mixin \Eloquent + */ + class Salutation extends \Eloquent {} +} + namespace App\Models{ /** * Class FewoLodgingGroupImage @@ -969,6 +1416,149 @@ namespace App\Models{ class FewoLodgingGroupImage extends \Eloquent {} } +namespace App\Models{ +/** + * Class Inquiry + * + * @property int $id + * @property int $lead_id + * @property int $template_id + * @property bool $in_pdf + * @property Carbon $begin + * @property Carbon $end + * @property int $type_id + * @property string $type_s + * @property string $data_s + * @property int $view_position + * @property Lead $lead + * @property InquiryTemplate $inquiry_template + * @property InquiryType $inquiry_type + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereBegin($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereDataS($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereEnd($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereInPdf($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereLeadId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereTemplateId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereTypeId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereTypeS($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Inquiry whereViewPosition($value) + * @mixin \Eloquent + */ + class Inquiry extends \Eloquent {} +} + +namespace App\Models{ +/** + * Class ArrangementType + * + * @property int $id + * @property string $name + * @property int $notify_rel_days + * @property int $arrangement_type_id + * @property bool $is_unique + * @property int $notify_rel_field_key + * @property ArrangementType $arrangement_type + * @property Booking $booking + * @property DraftItem $draft_item + * @property DraftType $draft_type + * @property Collection|ArrangementType[] $arrangement_types + * @property Collection|InquiryType[] $inquiry_types + * @package App\Models + * @property-read int|null $arrangement_types_count + * @property-read int|null $inquiry_types_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementType newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementType newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementType query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementType whereArrangementTypeId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementType whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementType whereIsUnique($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementType whereName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementType whereNotifyRelDays($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementType whereNotifyRelFieldKey($value) + * @mixin \Eloquent + */ + class ArrangementType extends \Eloquent {} +} + +namespace App\Models{ +/** + * Class Customer + * + * @property int $id + * @property int $salutation_id + * @property string $title + * @property string $name + * @property string $firstname + * @property Carbon $birthdate + * @property string $company + * @property string $street + * @property string $zip + * @property string $city + * @property string $email + * @property string $phone + * @property string $phonebusiness + * @property string $phonemobile + * @property string $fax + * @property string $bank + * @property string $bank_code + * @property string $bank_account_number + * @property int $credit_card_type_id + * @property string $credit_card_number + * @property Carbon $credit_card_expiration_date + * @property string $participants_remarks + * @property string $miscellaneous_remarks + * @property Carbon $created_at + * @property Carbon $updated_at + * @property int $country_id + * @property TravelCountry $travel_country + * @property CreditCardType $credit_card_type + * @property Salutation $salutation + * @property Collection|Booking[] $bookings + * @property Collection|Coupon[] $coupons + * @property Collection|Lead[] $leads + * @package App\Models + * @property-read int|null $bookings_count + * @property-read int|null $coupons_count + * @property-read int|null $leads_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereBank($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereBankAccountNumber($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereBankCode($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereBirthdate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereCity($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereCompany($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereCountryId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereCreatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereCreditCardExpirationDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereCreditCardNumber($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereCreditCardTypeId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereEmail($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereFax($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereFirstname($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereMiscellaneousRemarks($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereParticipantsRemarks($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer wherePhone($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer wherePhonebusiness($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer wherePhonemobile($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereSalutationId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereStreet($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereTitle($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereUpdatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Customer whereZip($value) + * @mixin \Eloquent + */ + class Customer extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\TravelMagazine @@ -1059,6 +1649,27 @@ namespace App\Models{ class Status extends \Eloquent {} } +namespace App\Models{ +/** + * Class TravelCategory + * + * @property int $id + * @property string $name + * @property Collection|Booking[] $bookings + * @property Collection|Lead[] $leads + * @package App\Models + * @property-read int|null $bookings_count + * @property-read int|null $leads_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCategory newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCategory newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCategory query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCategory whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCategory whereName($value) + * @mixin \Eloquent + */ + class TravelCategory extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\IQContentSite @@ -1083,6 +1694,38 @@ namespace App\Models{ class IQContentSite extends \Eloquent {} } +namespace App\Models{ +/** + * Class StatusHistory + * + * @property int $id + * @property int $status_id + * @property int $lead_id + * @property int $sf_guard_user_id + * @property Carbon $date + * @property string $remarks + * @property Carbon $target_date + * @property Carbon $created_at + * @property Lead $lead + * @property SfGuardUser $sf_guard_user + * @property Status $status + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory whereCreatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory whereDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory whereLeadId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory whereRemarks($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory whereSfGuardUserId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory whereStatusId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\StatusHistory whereTargetDate($value) + * @mixin \Eloquent + */ + class StatusHistory extends \Eloquent {} +} + namespace App\Models{ /** * Class FewoPrice @@ -1132,8 +1775,10 @@ namespace App\Models{ * @mixin \Eloquent * @property int $wday * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\CMSInfoAvailable whereWday($value) - * @property int $num - * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\CMSInfoAvailable whereNum($value) + * @property int|null $special + * @property string|null $date + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\CMSInfoAvailable whereDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\CMSInfoAvailable whereSpecial($value) */ class CMSInfoAvailable extends \Eloquent {} } @@ -1168,6 +1813,52 @@ namespace App\Models{ class SidebarWidget extends \Eloquent {} } +namespace App\Models{ +/** + * Class TravelCompany + * + * @property int $id + * @property string $name + * @property float $percentage + * @property bool $is_allowed_edit_commission + * @property bool $is_inhouse + * @property Collection|Booking[] $bookings + * @property Collection|BookingServiceItem[] $booking_service_items + * @package App\Models + * @property-read int|null $booking_service_items_count + * @property-read int|null $bookings_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCompany newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCompany newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCompany query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCompany whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCompany whereIsAllowedEditCommission($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCompany whereIsInhouse($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCompany whereName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\TravelCompany wherePercentage($value) + * @mixin \Eloquent + */ + class TravelCompany extends \Eloquent {} +} + +namespace App\Models{ +/** + * Class CreditCardType + * + * @property int $id + * @property string $name + * @property Collection|Customer[] $customers + * @package App\Models + * @property-read int|null $customers_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\CreditCardType newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\CreditCardType newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\CreditCardType query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\CreditCardType whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\CreditCardType whereName($value) + * @mixin \Eloquent + */ + class CreditCardType extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\CMSContent @@ -1201,6 +1892,25 @@ namespace App\Models{ class CMSContent extends \Eloquent {} } +namespace App\Models{ +/** + * Class ArrangementTemplate + * + * @property int $id + * @property string $title + * @property Collection|Arrangement[] $arrangements + * @package App\Models + * @property-read int|null $arrangements_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementTemplate newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementTemplate newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementTemplate query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementTemplate whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ArrangementTemplate whereTitle($value) + * @mixin \Eloquent + */ + class ArrangementTemplate extends \Eloquent {} +} + namespace App\Models{ /** * Class TravelBookingFewoChannel @@ -1224,6 +1934,55 @@ namespace App\Models{ class TravelBookingFewoChannel extends \Eloquent {} } +namespace App\Models{ +/** + * Class InsuranceCertificate + * + * @property int $id + * @property int $booking_id + * @property int $internal_id + * @property string $filename + * @property boolean $binary_data + * @property Carbon $created_at + * @property Carbon $updated_at + * @property string $request_data + * @property Booking $booking + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate whereBinaryData($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate whereBookingId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate whereCreatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate whereFilename($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate whereInternalId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate whereRequestData($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InsuranceCertificate whereUpdatedAt($value) + * @mixin \Eloquent + */ + class InsuranceCertificate extends \Eloquent {} +} + +namespace App\Models{ +/** + * Class InquiryTemplate + * + * @property int $id + * @property string $title + * @property Collection|Inquiry[] $inquiries + * @package App\Models + * @property-read int|null $inquiries_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryTemplate newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryTemplate newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryTemplate query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryTemplate whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\InquiryTemplate whereTitle($value) + * @mixin \Eloquent + */ + class InquiryTemplate extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\Page @@ -1346,36 +2105,58 @@ namespace App\Models{ namespace App\Models{ /** - * App\Models\Lead + * Class Lead * * @property int $id * @property int $customer_id - * @property string $request_date - * @property string|null $travelperiod_start - * @property string|null $travelperiod_end - * @property int|null $travelperiod_length - * @property int|null $travelcountry_id - * @property int|null $travelagenda_id - * @property string|null $remarks + * @property Carbon $request_date + * @property Carbon $travelperiod_start + * @property Carbon $travelperiod_end + * @property int $travelperiod_length + * @property int $travelcountry_id + * @property int $travelagenda_id + * @property string $remarks * @property int $sf_guard_user_id - * @property int|null $is_closed - * @property int|null $initialcontacttype_id - * @property int|null $searchengine_id - * @property string|null $searchengine_keywords + * @property bool $is_closed + * @property int $initialcontacttype_id + * @property int $searchengine_id + * @property string $searchengine_keywords * @property int $status_id - * @property string|null $next_due_date - * @property int|null $website_id - * @property int|null $travelcategory_id - * @property \Illuminate\Support\Carbon $created_at - * @property \Illuminate\Support\Carbon $updated_at - * @property float|null $price - * @property int|null $pax - * @property string|null $participant_name - * @property string|null $participant_firstname - * @property string|null $participant_birthdate - * @property int|null $participant_salutation_id - * @property-read \App\Models\SfGuardUser $sf_guard_user - * @property-read \App\Models\Status $status + * @property Carbon $next_due_date + * @property int $website_id + * @property int $travelcategory_id + * @property Carbon $created_at + * @property Carbon $updated_at + * @property float $price + * @property int $pax + * @property string $participant_name + * @property string $participant_firstname + * @property Carbon $participant_birthdate + * @property int $participant_salutation_id + * @property Customer $customer + * @property InitialContactType $initial_contact_type + * @property Salutation $salutation + * @property Searchengine $searchengine + * @property SfGuardUser $sf_guard_user + * @property Status $status + * @property TravelAgenda $travel_agenda + * @property TravelCategory $travel_category + * @property TravelCountry $travel_country + * @property Website $website + * @property Collection|Booking[] $bookings + * @property Collection|Inquiry[] $inquiries + * @property Collection|LeadParticipant[] $lead_participants + * @property Collection|Offer[] $offers + * @property Collection|StatusHistory[] $status_histories + * @package App\Models + * @property-read int|null $bookings_count + * @property-read int|null $inquiries_count + * @property-read int|null $lead_participants_count + * @property-read int|null $offers_count + * @property-read int|null $status_histories_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead query() * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead whereCreatedAt($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead whereCustomerId($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead whereId($value) @@ -1403,13 +2184,33 @@ namespace App\Models{ * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead whereUpdatedAt($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead whereWebsiteId($value) * @mixin \Eloquent - * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead newModelQuery() - * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead newQuery() - * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Lead query() */ class Lead extends \Eloquent {} } +namespace App\Models{ +/** + * Class ServiceProvider + * + * @property int $id + * @property string $name + * @property bool $dollar + * @property string $type + * @property Collection|ServiceProviderEntry[] $service_provider_entries + * @package App\Models + * @property-read int|null $service_provider_entries_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProvider newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProvider newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProvider query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProvider whereDollar($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProvider whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProvider whereName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ServiceProvider whereType($value) + * @mixin \Eloquent + */ + class ServiceProvider extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\TravelClass @@ -1467,6 +2268,43 @@ namespace App\Models{ class DraftType extends \Eloquent {} } +namespace App\Models{ +/** + * Class Arrangement + * + * @property int $id + * @property int $template_id + * @property Carbon $state + * @property Carbon $begin + * @property Carbon $end + * @property string $type_s + * @property string $data_s + * @property int $view_position + * @property int $booking_id + * @property int $type_id + * @property bool $in_pdf + * @property Booking $booking + * @property ArrangementTemplate $arrangement_template + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereBegin($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereBookingId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereDataS($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereEnd($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereInPdf($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereState($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereTemplateId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereTypeId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereTypeS($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Arrangement whereViewPosition($value) + * @mixin \Eloquent + */ + class Arrangement extends \Eloquent {} +} + namespace App\Models{ /** * Class TravelUserBookingFewo @@ -1559,6 +2397,45 @@ namespace App\Models{ class TravelUserBookingFewo extends \Eloquent {} } +namespace App\Models{ +/** + * Class Coupon + * + * @property int $id + * @property string $number + * @property int $customer_id + * @property int $booking_id + * @property float $value + * @property Carbon $issue_date + * @property Carbon $valid_date + * @property bool $is_redeemed + * @property Carbon $redeem_date + * @property Carbon $created_at + * @property Carbon $updated_at + * @property Booking $booking + * @property Customer $customer + * @property Collection|Booking[] $bookings + * @package App\Models + * @property-read int|null $bookings_count + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereBookingId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereCreatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereCustomerId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereIsRedeemed($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereIssueDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereNumber($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereRedeemDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereUpdatedAt($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereValidDate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Coupon whereValue($value) + * @mixin \Eloquent + */ + class Coupon extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\Feedback @@ -1664,6 +2541,35 @@ namespace App\Models{ class Feedback extends \Eloquent {} } +namespace App\Models{ +/** + * Class Participant + * + * @property int $id + * @property int $booking_id + * @property string $participant_name + * @property string $participant_firstname + * @property Carbon $participant_birthdate + * @property int $participant_salutation_id + * @property bool $participant_child + * @property Booking $booking + * @property Salutation $salutation + * @package App\Models + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant newModelQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant newQuery() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant query() + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant whereBookingId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant whereId($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant whereParticipantBirthdate($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant whereParticipantChild($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant whereParticipantFirstname($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant whereParticipantName($value) + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Participant whereParticipantSalutationId($value) + * @mixin \Eloquent + */ + class Participant extends \Eloquent {} +} + namespace App\Models{ /** * App\Models\TravelProgram diff --git a/app/Exports/ReportCollectionExport.php b/app/Exports/ReportCollectionExport.php new file mode 100644 index 0000000..3667f86 --- /dev/null +++ b/app/Exports/ReportCollectionExport.php @@ -0,0 +1,33 @@ +collection = $data; + $this->headings = $header; + } + + public function collection() + { + return collect($this->collection); + } + + public function headings(): array + { + return [$this->headings]; + } + +} \ No newline at end of file diff --git a/app/Http/Controllers/API/BookingController.php b/app/Http/Controllers/API/BookingController.php new file mode 100755 index 0000000..cd22cfb --- /dev/null +++ b/app/Http/Controllers/API/BookingController.php @@ -0,0 +1,191 @@ +draftRepo = $draftRepo; + } + + public function import() + { + + $request = \Request::all(); + if($request['key'] !== $this->successKey){ + return response()->json(['error' => "key"], 401); + } + $travel_booking = TravelBooking::find($request['travel_booking_id']); + + // $travel_booking = TravelBooking::find(2458); + if(!$travel_booking){ + return response()->json(['error' => 'no-booking-found'], $this->successStatus); + } + + // ---- createCustomer + $data = [ + 'salutation_id' => $travel_booking->salutation_id, + 'name' => $travel_booking->last_name, + 'firstname' => $travel_booking->first_name, + 'street' => $travel_booking->street, + 'zip' => $travel_booking->zipcode, + 'city' => $travel_booking->city, + 'country_id' => $travel_booking->country_id, + 'phone' => $travel_booking->phone, + 'phonemobile' => $travel_booking->mobile, + 'email' => $travel_booking->email + ]; + $customer = Customer::create($data); + + // ---- createLead + $data = [ + 'customer_id' => $customer->id, + 'request_date' => $travel_booking->created, + 'travelperiod_start' => $travel_booking->selected_start_date, + 'travelperiod_end' => $travel_booking->selected_end_date, + 'remarks' => $travel_booking->comments, + 'sf_guard_user_id' => 15, + 'is_closed' => true, + 'initialcontacttype_id' => 14, + 'status_id' => 7, + 'website_id' => 1, + ]; + $lead = Lead::create($data); + $lead->updateNextDueDate(); + + + $data = [ + 'booking_date' => $travel_booking->created->format('Y-m-d'), + 'customer_id' => $customer->id, + 'lead_id' => $lead->id, + 'new_drafts' => $travel_booking->drafts === null ? 0 : 1, + 'sf_guard_user_id' => 15, + 'branch_id' => 4, + 'travel_country_id' => isset($travel_booking->selected_travel['travel_country_id'][0]) ? $travel_booking->selected_travel['travel_country_id'][0] : null, + 'travel_category_id' => isset($travel_booking->selected_travel['travel_category_id']) ? $travel_booking->selected_travel['travel_category_id'] : null, + 'pax' => $travel_booking->selected_adults, + 'title' => isset($travel_booking->selected_travel['travel_title']) ? $travel_booking->selected_travel['travel_title'] : "", + 'start_date' => $travel_booking->selected_start_date->format('Y-m-d'), + 'end_date' => $travel_booking->selected_end_date->format('Y-m-d'), + 'website_id' => 1, + 'travel_number' => isset($travel_booking->selected_travel['travel_number']) ? $travel_booking->selected_travel['travel_number'] : null, + 'participant_name' => isset($travel_booking->participants[0]['last_name']) ? $travel_booking->participants[0]['last_name'] : null, + 'participant_firstname' => isset($travel_booking->participants[0]['first_name']) ? $travel_booking->participants[0]['first_name'] : null, + 'participant_birthdate' => isset($travel_booking->participants[0]['birthday']) ? date( "Y-m-d", strtotime($travel_booking->participants[0]['birthday'])) : null, + 'participant_salutation_id' => isset($travel_booking->participants[0]['gender']) ? $travel_booking->participants[0]['gender'] : null, + 'travel_company_id' => isset($travel_booking->service_items[0]['travel_company_id']) ? $travel_booking->service_items[0]['travel_company_id'] : null, + 'price' => $travel_booking->price, + 'price_total' => $travel_booking->price_total, + 'deposit_total' => $travel_booking->deposit_total, + 'final_payment' => $travel_booking->final_payment, + 'final_payment_date' => $travel_booking->final_payment_date->format('Y-m-d'), + 'travelagenda_id' => isset($travel_booking->selected_travel['travelagenda_id']) ? $travel_booking->selected_travel['travelagenda_id'] : null, + ]; + + //createBooking + $booking = Booking::create($data); + + //createTraveler + if($travel_booking->participants){ + foreach ($travel_booking->participants as $key => $participant){ + if($key > 0){ + Participant::create([ + 'booking_id' => $booking->id, + 'participant_name' => $participant['last_name'], + 'participant_firstname' => $participant['first_name'], + 'participant_birthdate' => date( "Y-m-d", strtotime($participant['birthday'])), + 'participant_salutation_id' => $participant['gender'], + 'participant_child' => $participant['child'], + ]); + } + } + } + + //createServiceItem //service_items + if($travel_booking->service_items){ + foreach ($travel_booking->service_items as $key => $service_item){ + BookingServiceItem::create([ + 'booking_id' => $booking->id, + 'travel_company_id' => $service_item['travel_company_id'], + 'service_price' => $service_item['service_price'], + 'service_price_refund' => 0, + 'commission' => $service_item['commission'], + 'travel_date' => $service_item['travel_date'], + 'name' => $service_item['name'], + 'is_commission_locked' => 0, + ]); + } + } + + //createServiceItem //insurances + if($travel_booking->insurances){ + foreach ($travel_booking->insurances as $key => $service_item){ + BookingServiceItem::create([ + 'booking_id' => $booking->id, + 'travel_company_id' => $service_item['travel_company_id'], + 'service_price' => $service_item['price'], + 'service_price_refund' => 0, + 'commission' => $service_item['commission'], + 'travel_date' => $service_item['travel_date'], + 'name' => $service_item['name'], + 'is_commission_locked' => 0, + ]); + } + } + + + + //createArrangement + if($travel_booking->arrangements) { + foreach ($travel_booking->arrangements as $key => $arrangement){ + Arrangement::create([ + 'state' => isset($arrangement['state']) ? $arrangement['state'] : null, + 'begin' => isset($arrangement['end']) ? $arrangement['end'] : null, + 'end' => isset($arrangement['end']) ? $arrangement['end'] : null, + 'type_s' => isset($arrangement['type_s']) ? $arrangement['type_s'] : null, + 'data_s' => isset($arrangement['data_s']) ? $arrangement['data_s'] : null, + 'view_position' => isset($arrangement['view_position']) ? $arrangement['view_position'] : null, + 'booking_id' => $booking->id, + 'type_id' => $arrangement['type_id'], + 'in_pdf' => isset($arrangement['in_pdf']) ? $arrangement['in_pdf'] : null, + ]); + } + } + + //createDrafts + + if($travel_booking->drafts) { + $this->draftRepo->create_drafts_from_booking($booking->id, $travel_booking->drafts); + } + + $travel_booking->crm_booking_id = $booking->id; + $travel_booking->save(); + $ret= [ + 'url_v1' => make_old_url('/index.php/booking/'.$booking->id.'/edit'), + 'url_v3' => route('booking_detail', $booking->id), + 'lead_id' => $lead->id + ]; + return response()->json(['success' => "import", "ret" => $ret], $this->successStatus); + //return response()->json(['error' => 'no-node'], $this->successStatus); + + } + + +} diff --git a/app/Http/Controllers/API/CMSContentController.php b/app/Http/Controllers/API/CMSContentController.php index f8c80cf..f3a213b 100755 --- a/app/Http/Controllers/API/CMSContentController.php +++ b/app/Http/Controllers/API/CMSContentController.php @@ -10,7 +10,8 @@ use App\Models\TravelGuide; class CMSContentController extends Controller { - public $successStatus = 200; + private $successStatus = 200; + private $successKey = 'f6077389c9ce710e554763a5de02c8ec'; public function search() @@ -22,7 +23,7 @@ class CMSContentController extends Controller return response()->json(['error' => "request no found"], $this->successStatus); } - if($request['key'] !== 'f6077389c9ce710e554763a5de02c8ec'){ + if($request['key'] !== $this->successKey){ return response()->json(['error' => "key"], 401); } @@ -35,11 +36,13 @@ class CMSContentController extends Controller $tree = IQContentTree::whereIdentifier($tree_identifier)->first(); $travel_guide = null; $url = ""; + $ret['title'] = ""; + $ret['description'] = ""; if($tree){ $lvl = 0; - $ret['tree'] = $tree->toArray(); $ret['navi'] = $this->makeNaviTree($tree, $urlArray, "", 0, false); + $url = "/".$tree->identifier; $ret['bread_crumb'][$lvl] = [ 'title' => $tree->name, @@ -51,14 +54,15 @@ class CMSContentController extends Controller $tree_node = IQContentTreeNode::whereTreeId($tree->id)->whereIdentifier($tree_node_identifier)->whereLvl($lvl)->whereActive(true)->first(); if($tree_node){ + $lvl ++; + $ret['title'] = $tree_node->title; + $ret['description'] = $tree_node->description;; $url = $url."/".$tree_node->identifier; $ret['bread_crumb'][$lvl] = [ 'title' => $tree_node->name, 'url' => $url, ]; - $ret['nodes'][$lvl] = $tree_node->toArray(); - $lvl ++; }else{ return response()->json(['error' => 'no-node'], $this->successStatus); } @@ -69,12 +73,18 @@ class CMSContentController extends Controller if($tree_node->iq_content_sites->count()){ foreach ($tree_node->iq_content_sites as $iq_content_site){ if(isset($iq_content_site->travel_guide) && $iq_content_site->travel_guide && $iq_content_site->travel_guide->active){ - $ret['sites'][] = $iq_content_site->travel_guide->toArray(); + $key = ($iq_content_site->travel_guide->scope -1) *-1; + $ret['sites'][$key] = $iq_content_site->travel_guide->toArray(); /*if(!$travel_guide){ //$travel_guide = $iq_content_site->travel_guide; }*/ } } + if(isset($ret['sites'])){ + ksort($ret['sites']); + $ret['sites'] = array_values($ret['sites']); + } + } //children if($tree_node->iq_content_tree_node_childs->count()){ diff --git a/app/Http/Controllers/API/CMSContentInfoController.php b/app/Http/Controllers/API/CMSContentInfoController.php index 1f5e04f..b24869c 100755 --- a/app/Http/Controllers/API/CMSContentInfoController.php +++ b/app/Http/Controllers/API/CMSContentInfoController.php @@ -33,35 +33,42 @@ class CMSContentInfoController extends Controller $locals = CMSInfoAvailable::whereType('local')->whereSpecial(false)->get(); foreach ($locals as $value){ $date = CMSInfoAvailable::getWeekWithDate($value->wday); - $ret['local'][$date['date']] = [ + $ret['local'][strtotime($date['date'])] = [ 'day'=>$days[$value->wday], 'active' => $value->active, 'from' => $value->from, 'to' => $value->to, + 'date' => $date['date'], + ]; } $phones = CMSInfoAvailable::whereType('phone')->whereSpecial(false)->get(); foreach ($phones as $value){ $date = CMSInfoAvailable::getWeekWithDate($value->wday); - $ret['phone'][$date['date']] = [ + $ret['phone'][strtotime($date['date'])] = [ 'day'=>$days[$value->wday], 'active' => $value->active, 'from' => $value->from, 'to' => $value->to, + 'date' => $date['date'], + ]; } $specials = CMSInfoAvailable::whereSpecial(true)->get(); foreach ($specials as $special){ - $ret[$special->type][$special->date] = [ + $ret[$special->type][strtotime($special->date)] = [ 'day'=>$days[$special->wday], 'active' => $special->active, 'from' => $special->from, 'to' => $special->to, + 'date' => $special->date, + ]; } - // ksort($ret); + ksort($ret['local']); + ksort($ret['phone']); $ret['info']['office_important_note_active'] = CMSInfo::getContentBySlug('office-important-note-active'); $ret['info']['office_important_note'] = CMSInfo::getContentBySlug('office-important-note'); diff --git a/app/Http/Controllers/API/DraftController.php b/app/Http/Controllers/API/DraftController.php index 0f24042..b9b3a58 100755 --- a/app/Http/Controllers/API/DraftController.php +++ b/app/Http/Controllers/API/DraftController.php @@ -14,8 +14,6 @@ class DraftController extends Controller { public $successStatus = 200; public $data = ""; - public $room_str = ""; - public $room_name = ""; public $className = ""; public $option = ""; @@ -23,12 +21,12 @@ class DraftController extends Controller { - if ($action == "get_draft_list") { + if ($action === "get_draft_list") { $drafts = Draft::where('active', true)->get()->sortByDesc("id"); return response()->json(['success' => $drafts], $this->successStatus); } - if ($action == "get_draft_list_for_table") { + if ($action === "get_draft_list_for_table") { $ret = []; if (request('program_id') && request('program_id') > 0) { $travel_program = TravelProgram::find(request('program_id')); @@ -50,20 +48,19 @@ class DraftController extends Controller } - if ($action == "create_drafts_from_fewo") { + if ($action === "create_drafts_from_fewo") { $data = \Input::all(); $start_date = Carbon::parse($data['startDateStr']); $end_date = Carbon::parse($data['endDateStr']); $pos = 0; - if(isset($data['priceResult']) && is_array($data['priceResult'])){ + if (isset($data['priceResult']) && is_array($data['priceResult'])) { - if(isset($data['priceResult']['season']) && is_array($data['priceResult']['season'])){ - foreach ($data['priceResult']['season'] as $season => $values){ - - $service = '* Saison: '.$season."\n". - '* Mindestbelegung: '.$values['minimumStay'].' '.($values['minimumStay'] < 2 ? 'Nacht' : 'Nächte')."\n". - '* Preis: '.number_format($values['price'], 2, ',', '.').' € / '. $values['numberDays'].' '.($values['numberDays'] < 2 ? 'Nacht' : 'Nächte').' x '.number_format($values['perNight'], 2, ',', '.')." € \n"; + if (isset($data['priceResult']['season']) && is_array($data['priceResult']['season'])) { + foreach ($data['priceResult']['season'] as $season => $values) { + $service = '* Saison: ' . $season . "\n" . + '* Mindestbelegung: ' . $values['minimumStay'] . ' ' . ($values['minimumStay'] < 2 ? 'Nacht' : 'Nächte') . "\n" . + '* Preis: ' . number_format($values['price'], 2, ',', '.') . ' € / ' . $values['numberDays'] . ' ' . ($values['numberDays'] < 2 ? 'Nacht' : 'Nächte') . ' x ' . number_format($values['perNight'], 2, ',', '.') . " € \n"; $from_date = Carbon::parse($values['fromDay']); @@ -75,7 +72,7 @@ class DraftController extends Controller 'fewo_lodging_id' => $data['fewo_lodging_id'], 'draft_type_id' => 38, 'request_date' => $data['request_date'], - 'days_duration' => $values['numberDays'], + 'days_duration' => $values['numberDays'], 'start_date' => $from_date->format("Y-m-d"), 'end_date' => $to_date->format("Y-m-d"), 'service' => $service, @@ -87,14 +84,14 @@ class DraftController extends Controller } } - if(isset($data['priceResult']['flatPrice'])){ - $service = '* Service-Gebühr: '.number_format($data['priceResult']['deposit'], 2, ',', '.'); + if (isset($data['priceResult']['flatPrice'])) { + $service = '* Service-Gebühr: ' . number_format($data['priceResult']['deposit'], 2, ',', '.'); BookingDraftItem::create([ 'booking_id' => $data['booking_id'], 'fewo_lodging_id' => $data['fewo_lodging_id'], 'draft_type_id' => 39, 'request_date' => $data['request_date'], - 'days_duration' => $data['priceResult']['days'], + 'days_duration' => $data['priceResult']['days'], 'start_date' => $start_date->format("Y-m-d"), 'end_date' => $end_date->format("Y-m-d"), 'service' => $service, @@ -106,14 +103,14 @@ class DraftController extends Controller } - if(isset($data['priceResult']['deposit'])){ - $service = '* Kaution: '.number_format($data['priceResult']['deposit'], 2, ',', '.'); + if (isset($data['priceResult']['deposit'])) { + $service = '* Kaution: ' . number_format($data['priceResult']['deposit'], 2, ',', '.'); BookingDraftItem::create([ 'booking_id' => $data['booking_id'], 'fewo_lodging_id' => $data['fewo_lodging_id'], 'draft_type_id' => 40, 'request_date' => $data['request_date'], - 'days_duration' => $data['priceResult']['days'], + 'days_duration' => $data['priceResult']['days'], 'start_date' => $start_date->format("Y-m-d"), 'end_date' => $end_date->format("Y-m-d"), 'service' => $service, @@ -124,532 +121,12 @@ class DraftController extends Controller } - } - + } return response()->json(['success' => $data['booking_id']], $this->successStatus); } - - if ($action == "create_drafts_from_booking") { - $data = \Input::all(); - $this->data = $data; - - $weekday = date('w', strtotime($data['startDateStr'])); - $travel_program = TravelProgram::find($data['travel_program_id']); - $draft = $this->getDraftByTravelProgramData($travel_program, $data, $weekday); - - $start_date = Carbon::parse($data['startDateStr']); - $end_date = Carbon::parse($data['endDateStr']); - - - if($draft){ - - //------------------------------------------------------------------------------ - //prepare rooms - //request('rooms'); // //["rooms"]=> array(1) { [0]=> object(stdClass)#7284 (5) { ["name"]=> string(12) "Einzelzimmer" ["price_adult"]=> float(1682.16) ["adult"]=> int(1) ["children"]=> int(0) ["price_children"]=> int(0) } - $price_info_rooms = []; - $room_names = []; - $room_adult = 0; - $room_children = 0; - $room_price_adult = 0; - $room_price_children = 0; - - $data['rooms'] = array_reverse($data['rooms']); - - foreach ($data['rooms'] as $room){ - - $room_adult += $room['adult']; - $room_children += $room['children']; - $room_price_adult += ($room['price_adult_full'] * $room['adult']); - $room_price_children += ($room['price_children_full'] * $room['children']); - - if(isset($room_names[$room['name']])){ - $room_names[$room['name']] = $room_names[$room['name']]+1; - }else{ - $room_names[$room['name']] = 1; - } - - $service = trans('_vorlagen.grundpreis_reise'); - $this->room_name = $room['name']; - $service = $this->replaceService($service); - - $price_info_rooms[] = [ - 'booking_id' => $data['booking_id'], - 'travel_program_id' => $data['travel_program_id'], - 'fewo_lodging_id' => null, - 'travel_class_id' => null, - 'draft_item_id' => null, - 'draft_type_id' => 30, - 'request_date' => $data['request_date'], - 'days_start' => null, - 'days_duration' => null, - 'start_date' => $data['startDateStr'], - 'end_date' => $data['endDateStr'], - 'service' => $service, - 'price_adult' => $room['price_adult_full'], - 'adult' => $room['adult'], - 'price_children' => $room['price_children_full'], - 'children' => $room['children'], - 'pos' => 0, - 'in_pdf' => true, - 'comfort' => $data['comfort'] - ]; - } - - - - - $this->room_str = ""; - foreach ($room_names as $name=>$count){ - $this->room_str .= $count.' x '.$name.', '; - } - $this->room_str = rtrim($this->room_str, ', '); - - - //before & after days - - $price_info_rooms_before = []; - $price_info_rooms_after = []; - - if(isset($data['booking_before']) && is_array($data['booking_before'])){ - foreach ($data['booking_before'] as $booking_before){ - $start_date_before = clone $start_date; - if(isset($booking_before['days']) && $booking_before['days'] > 0){ - $start_date_before->modify('-'.$booking_before['days'].' day'); - } - - $price_info_rooms_before[] = [ - 'booking_id' => $data['booking_id'], - 'travel_program_id' => $data['travel_program_id'], - 'fewo_lodging_id' => null, - 'travel_class_id' => null, - 'draft_item_id' => null, - 'draft_type_id' => 36, - 'request_date' => $data['request_date'], - 'days_start' => null, - 'days_duration' => $booking_before['days'], - 'start_date' => $start_date_before->format("Y-m-d"), - 'end_date' => $data['startDateStr'], - 'service' => $booking_before['name'], - 'price_adult' => $booking_before['price'], - 'adult' => $booking_before['adults'], - 'price_children' => $booking_before['price_children'], - 'children' => $booking_before['children'], - 'pos' => 0, - 'in_pdf' => true, - 'comfort' => $data['comfort'] - ]; - } - } - - if(isset($data['booking_after']) && is_array($data['booking_after'])){ - foreach ($data['booking_after'] as $booking_after){ - $end_date_after = clone $end_date; - if(isset($booking_after['days']) && $booking_after['days'] > 0){ - $end_date_after->modify('+'.$booking_after['days'].' day'); - } - - $price_info_rooms_after[] = [ - 'booking_id' => $data['booking_id'], - 'travel_program_id' => $data['travel_program_id'], - 'fewo_lodging_id' => null, - 'travel_class_id' => null, - 'draft_item_id' => null, - 'draft_type_id' => 37, - 'request_date' => $data['request_date'], - 'days_start' => null, - 'days_duration' => $booking_after['days'], - 'start_date' => $data['endDateStr'], - 'end_date' => $end_date_after->format("Y-m-d"), - 'service' => $booking_after['name'], - 'price_adult' => $booking_after['price'], - 'adult' => $booking_after['adults'], - 'price_children' => $booking_after['price_children'], - 'children' => $booking_after['children'], - 'pos' => 0, - 'in_pdf' => true, - 'comfort' => $data['comfort'] - ]; - } - } - - - //------------------------------------------------------------------------------ - //prepare extra_charge - $price_info_extra_charge = []; - if($data['departure_extra_charge'] > 0){ - - $service = trans('_vorlagen.aufpreis_flug'); - $service = $this->replaceService($service); - - $price_info_extra_charge[] = [ - 'booking_id' => $data['booking_id'], - 'travel_program_id' => $data['travel_program_id'], - 'fewo_lodging_id' => null, - 'travel_class_id' => null, - 'draft_item_id' => null, - 'draft_type_id' => 33, - 'request_date' => $data['request_date'], - 'days_start' => null, - 'days_duration' => null, - 'start_date' => null, - 'end_date' => null, - 'service' => $service, - 'price_adult' => $data['departure_extra_charge'] , - 'adult' => $data['traveler'] , - 'price_children' => 0, - 'children' => 0, - 'pos' => 0, - 'in_pdf' => true, - 'comfort' => $data['comfort'] - ]; - } - - //------------------------------------------------------------------------------ - //prepare $class_options - $price_info_class_options = []; - foreach ($data['class_options'] as $class_option){ - - $service = trans('_vorlagen.aufpreis_kategorie'); - $this->className = $class_option['name']; - $service = $this->replaceService($service); - - $price_info_class_options[] = [ - 'booking_id' => $data['booking_id'], - 'travel_program_id' => $data['travel_program_id'], - 'fewo_lodging_id' => null, - 'travel_class_id' => null, - 'draft_item_id' => null, - 'draft_type_id' => 32, - 'request_date' => $data['request_date'], - 'days_start' => null, - 'days_duration' => null, - 'start_date' => null, - 'end_date' => null, - 'service' => $service, - 'price_adult' => $class_option['price'], - 'adult' => $class_option['count'], - 'price_children' => 0, - 'children' => 0, - 'pos' => 0, - 'in_pdf' => true, - 'comfort' => $data['comfort'] - ]; - } - - //------------------------------------------------------------------------------ - //prepare $travel_options - $price_info_travel_options = []; - foreach ($data['travel_options'] as $travel_option){ - - $service = trans('_vorlagen.aufpreis_option'); - $this->option = $travel_option['name']; - $service = $this->replaceService($service); - - /* - * if($travel_option['children'] < 1){ - $travel_option['price_children'] = 0; - } - */ - $price_info_travel_options[] = [ - 'booking_id' => $data['booking_id'], - 'travel_program_id' => $data['travel_program_id'], - 'fewo_lodging_id' => null, - 'travel_class_id' => null, - 'draft_item_id' => null, - 'draft_type_id' => 41, - 'request_date' => $data['request_date'], - 'days_start' => null, - 'days_duration' => null, - 'start_date' => null, - 'end_date' => null, - 'service' => $service, - 'price_adult' => $travel_option['price_adult'], - 'adult' => $travel_option['adult'], - 'price_children' => $travel_option['price_children'], - 'children' => $travel_option['children'], - 'pos' => 0, - 'in_pdf' => true, - 'comfort' => $data['comfort'] - ]; - } - - $price_info_travel_discounts = []; - - foreach ($data['discount'] as $travel_discount){ - - $service = trans('_vorlagen.aufpreis_option'); - $this->option = ""; - $service = $this->replaceService($service); - - if($travel_discount['price'] > 0){ - $travel_discount['price'] = $travel_discount['price']*-1; - } - $price_info_travel_options[] = [ - 'booking_id' => $data['booking_id'], - 'travel_program_id' => $data['travel_program_id'], - 'fewo_lodging_id' => null, - 'travel_class_id' => null, - 'draft_item_id' => null, - 'draft_type_id' => 42, - 'request_date' => $data['request_date'], - 'days_start' => null, - 'days_duration' => null, - 'start_date' => null, - 'end_date' => null, - 'service' => $service, - 'price_adult' => $travel_discount['price'], - 'adult' => $travel_discount['count'], - 'price_children' => 0, - 'children' => 0, - 'pos' => 0, - 'in_pdf' => true, - 'comfort' => $data['comfort'] - ]; - } - - $info_texts = []; - $last_post = 0; - foreach ($draft->draft_items as $draft_item){ - - $service = $draft_item->service; - $price_adult = 0; - $adult = 0; - $price_children = 0; - $children = 0; - - switch ($draft_item->draft_type->id){ - case 24: //rundreise - $price_adult = $room_price_adult; - $adult = $room_adult; - $price_children = $room_price_children; - $children = $room_children; - break; - case 4: //flug - // "Hinflug: Rückflug: Flugzeiten ?" - break; - } - - $start_date_temp = null; - if($draft_item->days_start > 0){ - $start_date_temp = clone $start_date; - $start_date_temp->addDay($draft_item->days_start-1); - } - - $end_date_temp = null; - if($draft_item->days_duration > 0){ - $end_date_temp = clone $start_date; - $end_date_temp->addDay($draft_item->days_duration-1); - } - - $service = $this->replaceService($service); - - if($draft_item->draft_type->id == 27){ - //text -at last - $info_texts[] = [ - 'booking_id' => $data['booking_id'], - 'travel_program_id' => $data['travel_program_id'], - 'fewo_lodging_id' => null, - 'travel_class_id' => null, - 'draft_item_id' => $draft_item->id, - 'draft_type_id' => $draft_item->draft_type->id, - 'request_date' => $data['request_date'], - 'days_start' => $draft_item->days_start, - 'days_duration' => $draft_item->days_duration, - 'start_date' => $start_date_temp ? $start_date_temp->format("Y-m-d") : null, - 'end_date' => $end_date_temp ? $end_date_temp->format("Y-m-d") : null, - 'service' => $service, - 'price_adult' => $price_adult, - 'adult' => $adult, - 'price_children' => $price_children, - 'children' => $children, - 'pos' => $draft_item->pos, - 'in_pdf' => $draft_item->in_pdf, - 'comfort' => $data['comfort'] - ]; - - - }else{ - //create new from draft items - BookingDraftItem::create([ - 'booking_id' => $data['booking_id'], - 'travel_program_id' => $data['travel_program_id'], - 'fewo_lodging_id' => null, - 'travel_class_id' => null, - 'draft_item_id' => $draft_item->id, - 'draft_type_id' => $draft_item->draft_type->id, - 'request_date' => $data['request_date'], - 'days_start' => $draft_item->days_start, - 'days_duration' => $draft_item->days_duration, - 'start_date' => $start_date_temp ? $start_date_temp->format("Y-m-d") : null, - 'end_date' => $end_date_temp ? $end_date_temp->format("Y-m-d") : null, - 'service' => $service, - 'price_adult' => $price_adult, - 'adult' => $adult, - 'price_children' => $price_children, - 'children' => $children, - 'pos' => $draft_item->pos, - 'in_pdf' => $draft_item->in_pdf, - 'comfort' => $data['comfort'] - ]); - } - - - - $last_post = $draft_item->pos; - - } - - //set room prices - if(count($price_info_rooms)){ - foreach ($price_info_rooms as $price_info_room){ - $last_post ++; - $price_info_room['pos'] = $last_post; - BookingDraftItem::create($price_info_room); - } - } - - //set room prices before - if(count($price_info_rooms_before)){ - foreach ($price_info_rooms_before as $price_info_room){ - $last_post ++; - $price_info_room['pos'] = $last_post; - BookingDraftItem::create($price_info_room); - } - } - - //set room prices after - if(count($price_info_rooms_after)){ - foreach ($price_info_rooms_after as $price_info_room){ - $last_post ++; - $price_info_room['pos'] = $last_post; - BookingDraftItem::create($price_info_room); - } - } - - - - //set extra charge price - if(count($price_info_extra_charge)){ - foreach ($price_info_extra_charge as $price_info_extra){ - $last_post ++; - $price_info_extra['pos'] = $last_post; - BookingDraftItem::create($price_info_extra); - } - } - //set class options prices - if(count($price_info_class_options)){ - foreach ($price_info_class_options as $price_info_class_option){ - $last_post ++; - $price_info_class_option['pos'] = $last_post; - BookingDraftItem::create($price_info_class_option); - } - } - - //set travel options prices - if(count($price_info_travel_options)){ - foreach ($price_info_travel_options as $price_info_travel_option){ - $last_post ++; - $price_info_travel_option['pos'] = $last_post; - BookingDraftItem::create($price_info_travel_option); - } - } - - //set travel discount prices - if(count($price_info_travel_discounts)){ - foreach ($price_info_travel_discounts as $price_info_travel_discount){ - $last_post ++; - $price_info_travel_option['pos'] = $last_post; - BookingDraftItem::create($price_info_travel_option); - } - } - - //set travel options prices - if(count($info_texts)){ - foreach ($info_texts as $info_text){ - $last_post ++; - $info_text['pos'] = $last_post; - BookingDraftItem::create($info_text); - } - } - } - - - - - $ret = []; - /* - $travel_program_id = request('travel_program_id'); - $comfort = request('comfort'); - $booking_id = request('booking_id'); - $startDateStr = request('startDateStr'); - $endDateStr = request('endDateStr'); - $departure = request('departure'); - $departure_extra_charge = request('departure_extra_charge'); - $traveler = request('traveler'); - $title = request('title'); - $number = request('number'); - $rooms = request('rooms'); // //["rooms"]=> array(1) { [0]=> object(stdClass)#7284 (5) { ["name"]=> string(12) "Einzelzimmer" ["price_adult"]=> float(1682.16) ["adults"]=> int(1) ["children"]=> int(0) ["price_children"]=> int(0) } - $class_options = request('class_options'); //["travel_options"]=> array(2) { [0]=> array(5) { ["name"]=> string(20) "Aufpreis Halbpension" ["price_adult"]=> float(75) ["adult"]=> int(5) ["children"]=> int(0) ["price_children"]=> int(0) } - $travel_options = request('travel_options'); //["class_options"]=> array(1) { [0]=> array(3) { ["name"]=> string(39) "zugebuchte Leistung: Komfort (4 Sterne)" ["price"]=> float(152) ["count"]=> int(1) - */ - - return response()->json(['success' => $draft->id], $this->successStatus); - - - } } - protected function replaceService($service){ - - $service = str_replace('#Name#', $this->data['title'], $service); - $service = str_replace('#Nummer#', $this->data['number'], $service); - $service = str_replace('#Zimmer#', $this->room_str, $service); - $service = str_replace('#Raumname#', $this->room_name, $service); - $service = str_replace('#Kategorie#', $this->className, $service); - $service = str_replace('#Option#', $this->option, $service); - $service = str_replace('#Flughafen#', $this->data['departure'], $service); - - return $service; - - } - - protected function getDraftByTravelProgramData($travel_program, $data, $weekday){ - if ($travel_program && count($travel_program->travel_program_drafts)) { - - foreach ($travel_program->travel_program_drafts as $travel_program_draft) { - //this need an realation to travel class by booking and price - if(in_array($weekday, $travel_program_draft->weekdays)){ - if($data['comfort'] == false && strpos(strtolower($travel_program_draft->travel_class->name), 'standard') !== false){ - return $travel_program_draft->draft; - } - if($data['comfort'] == true && strpos(strtolower($travel_program_draft->travel_class->name), 'komfort') !== false){ - return $travel_program_draft->draft; - } - } - } - //found non get first - foreach ($travel_program->travel_program_drafts as $travel_program_draft) { - return $travel_program_draft->draft; - - } - - - } - return null; - } -} -/* -array(14) { - ["travel_program_id"]=> int(197) ["comfort"]=> bool(true) ["booking_id"]=> string(4) "8435" ["request_date"]=> string(10) "2018-10-29" ["startDateStr"]=> string(10) "2018-11-03" ["endDateStr"]=> string(10) "2018-11-10" ["departure"]=> string(7) "Hamburg" ["departure_extra_charge"]=> float(55) ["traveler"]=> int(3) ["title"]=> string(35) "Höhepunkte Jordaniens ab Nov. 2018" ["number"]=> string(16) "JOR-HOE1920018B1" ["rooms"]=> array(2) { - [0]=> array(5) { - ["name"]=> string(12) "Doppelzimmer" ["price_adult"]=> float(1473.85) ["adults"]=> int(2) ["children"]=> int(0) ["price_children"]=> int(0) } [1]=> array(5) { - ["name"]=> string(12) "Einzelzimmer" ["price_adult"]=> float(1682.16) ["adults"]=> int(1) ["children"]=> int(0) ["price_children"]=> int(0) } } ["class_options"]=> array(2) { - [0]=> array(3) { - ["name"]=> string(39) "zugebuchte Leistung: Komfort (4 Sterne)" ["price"]=> float(122) ["count"]=> int(2) } [1]=> array(3) { - ["name"]=> string(39) "zugebuchte Leistung: Komfort (4 Sterne)" ["price"]=> float(171) ["count"]=> int(1) } } ["travel_options"]=> array(1) { - [0]=> array(5) { - ["name"]=> string(20) "Aufpreis Halbpension" ["price_adult"]=> float(75) ["adults"]=> int(3) ["children"]=> int(0) ["price_children"]=> int(0) } } } -*/ \ No newline at end of file +} \ No newline at end of file diff --git a/app/Http/Controllers/Admin/ReportController.php b/app/Http/Controllers/Admin/ReportController.php new file mode 100755 index 0000000..dfb5822 --- /dev/null +++ b/app/Http/Controllers/Admin/ReportController.php @@ -0,0 +1,216 @@ +middleware('superadmin'); + } + + + public function bookings() + { + $data = [ + 'text' => "Umsetzung folgt", + ]; + return view('_empty', $data); + } + + public function providers() + { + $data = [ + 'serviceProviders' => ServiceProvider::all(), + ]; + return view('admin.report.index', $data); + } + + public function providersExport(){ + + $query = ServiceProviderEntry::with('booking', 'service_provider', 'booking.customer'); + if(Input::get('filter_is_cleared') != ""){ + $query->where('is_cleared', '=', Input::get('filter_is_cleared')); + } + if(Input::get('filter_service_provider_id') != ""){ + $query->where('service_provider_id', '=', Input::get('filter_service_provider_id')); + } + if(Input::get('filter_travel_date_from') != ""){ + $query->whereHas('booking', function ($q) { + $travel_date_from = Carbon::parse(Input::get('filter_travel_date_from'))->format("Y-m-d"); + $q->where("start_date", '>=', $travel_date_from); + }); + } + if(Input::get('filter_travel_date_to') != ""){ + $query->whereHas('booking', function ($q) { + $travel_date_to = Carbon::parse(Input::get('filter_travel_date_to'))->format("Y-m-d"); + $q->where("start_date", '<=', $travel_date_to); + }); + } + + $query->whereHas('booking', function ($q) { + $q->orderBy("lead_id", 'ASC'); + }); + + $filename = "file-".date('Y-m-d-H-i-s'); + $exports = $query->get(); + $columns = []; + if(Input::get('export') === "export"){ + $filename = "Export_".date('Y-m-d-H-i-s'); + + $headers = array( + 'Zähler', + 'MyJack Nr.', + 'CRM Nr', + 'Kunde', + 'Reisedatum', + 'Gesamtreisepreis', + 'Reiseland', + 'Reiseprogramm', + 'Reiseteilnehmer', + 'Leistungsträger', + 'Rechnungsnummer', + 'Zahlung', + 'Zahlungsdatum', + 'Erlös', + 'Konto', + ); + $isset = []; + foreach($exports as $export) { + $new = in_array($export->booking->lead_id, $isset) ? false : true; + $columns[] = array( + 'Zähler' => $new ? $export->getCounter() : "", + 'MyJack Nr.' => $new ? $export->booking->merlin_order_number : "", + 'CRM Nr' => $new ? $export->booking->lead_id : "", + 'Kunde' => $new ? $export->booking->customer->name : "", + 'Reisedatum' => $new ? $export->booking->getStartDateFormat() : "", + 'Gesamtreisepreis' => $new ? $export->booking->price : "", + 'Reiseland' => $new ? $export->booking->travel_country->name : "", + 'Reiseprogramm' => $new ? $export->booking->travel_agenda->name : "", + 'Reiseteilnehmer' => $new ? $export->booking->pax : "", + 'Leistungsträger' => $export->service_provider->name, + 'Rechnungsnummer' => $export->invoice_number, + 'Zahlung' => $export->getAmountFinalEur(), + 'Zahlungsdatum' => $export->getPaymentDateFormat(), + 'Erlös' => $new ? $export->booking->proceeds() : "", + 'Konto' => $export->booking->getKontoNumber() + ); + $isset[] = $export->booking->lead_id; + } + } + if(Input::get('export') === "export_lt"){ + $filename = "Export_LT_".date('Y-m-d-H-i-s'); + + $headers = array( + 'Zähler', + 'MyJack Nr.', + 'CRM Nr', + 'Kunde', + 'Reisedatum', + 'Reiseland', + 'Reiseprogramm', + 'Reiseteilnehmer', + 'Leistungsträger', + 'Rechnungsnummer', + 'Zahlung', + 'ZahlungVorgang', + ); + $isset = []; + foreach($exports as $export) { + $new = in_array($export->booking->lead_id, $isset) ? false : true; + $columns[] = array( + 'Zähler' => $new ? $export->getCounter() : "", + 'MyJack Nr.' => $new ? $export->booking->merlin_order_number : "", + 'CRM Nr' => $new ? $export->booking->lead_id : "", + 'Kunde' => $new ? $export->booking->customer->name : "", + 'Reisedatum' => $new ? $export->booking->getStartDateFormat() : "", + 'Reiseland' => $new ? $export->booking->travel_country->name : "", + 'Reiseprogramm' => $new ? $export->booking->travel_agenda->name : "", + 'Reiseteilnehmer' => $new ? $export->booking->pax : "", + 'Leistungsträger' => $export->service_provider->name, + 'Rechnungsnummer' => $export->invoice_number, + 'Zahlung' => $export->getAmountFinalEur(), + 'ZahlungVorgang' => $export->booking->getServiceProviderPaymentsTotal(), + ); + $isset[] = $export->booking->lead_id; + } + } + return Excel::download(new ReportCollectionExport($columns, $headers), $filename.'.xls'); + } + + + + + public function providersDatatable() + { + + $query = ServiceProviderEntry::with('booking', 'service_provider', 'booking.customer'); + + if(Input::get('filter_is_cleared') != ""){ + $query->where('is_cleared', '=', Input::get('filter_is_cleared')); + } + if(Input::get('filter_service_provider_id') != ""){ + $query->where('service_provider_id', '=', Input::get('filter_service_provider_id')); + } + if(Input::get('filter_travel_date_from') != ""){ + $query->whereHas('booking', function ($q) { + $travel_date_from = Carbon::parse(Input::get('filter_travel_date_from'))->format("Y-m-d"); + $q->where("start_date", '>=', $travel_date_from); + }); + } + if(Input::get('filter_travel_date_to') != ""){ + $query->whereHas('booking', function ($q) { + $travel_date_to = Carbon::parse(Input::get('filter_travel_date_to'))->format("Y-m-d"); + $q->where("start_date", '<=', $travel_date_to); + }); + } + + return \DataTables::eloquent($query) + ->addColumn('booking.customer.fullName', function (ServiceProviderEntry $serviceProviderEntry) { + return $serviceProviderEntry->booking->customer->fullName(); + }) + ->addColumn('booking.proceeds', function (ServiceProviderEntry $serviceProviderEntry) { + return $serviceProviderEntry->booking->proceeds(); + }) + ->addColumn('booking.start_date', function (ServiceProviderEntry $serviceProviderEntry) { + return $serviceProviderEntry->booking->getStartDateFormat(); + }) + ->addColumn('is_cleared', function (ServiceProviderEntry $serviceProviderEntry) { + return $serviceProviderEntry->is_cleared ? ' ' : ''; + }) + ->filterColumn('booking.customer.fullName', function ($query, $keyword) { + if ($keyword != "") { + $query->whereHas('booking', function ($q) use ($keyword) { + $q->whereHas('customer', function ($q) use ($keyword) { + $q->where("name", 'LIKE', '%' . $keyword . '%') + ->orWhere('firstname', 'LIKE', '%' . $keyword . '%'); + }); + }); + } + }) + ->orderColumn('booking.start_date', 'booking.start_date $1') + ->orderColumn('is_cleared', 'is_cleared $1') + ->rawColumns(['is_cleared']) + ->make(true); + + } + +} + + diff --git a/app/Http/Controllers/AdminUserController.php b/app/Http/Controllers/AdminUserController.php index a36c195..a76de9a 100755 --- a/app/Http/Controllers/AdminUserController.php +++ b/app/Http/Controllers/AdminUserController.php @@ -65,7 +65,7 @@ class AdminUserController extends Controller { $data = Input::all(); - if($data['user_id'] == "new"){ + if($data['user_id'] === "new"){ $rules = array( 'name' => 'required', 'email' => 'required|string|email|max:255|unique:users', @@ -81,7 +81,7 @@ class AdminUserController extends Controller return back()->withInput(Input::all())->withErrors($validator); } - if($data['user_id'] == "new"){ + if($data['user_id'] === "new"){ $user = User::create([ 'name' => $data['name'], 'email' => $data['email'], @@ -165,19 +165,19 @@ class AdminUserController extends Controller return \DataTables::eloquent($query) ->addColumn('action_edit', function (User $user) { - return ''; + return ''; }) ->addColumn('admin', function (User $user) { return ''.HTMLHelper::getRoleLabel($user->admin, ' Rechte + ','').''; }) ->addColumn('confirmed', function (User $user) { - return $user->confirmed ? '' : ''; + return $user->confirmed ? '' : ''; }) ->addColumn('active', function (User $user) { - return $user->active ? ' ' : ''; + return $user->active ? ' ' : ''; }) ->addColumn('action_delete', function (User $user) { - return ''; + return ''; }) ->orderColumn('confirmed', 'confirmed $1') ->orderColumn('active', 'active $1') diff --git a/app/Http/Controllers/DataTableController.php b/app/Http/Controllers/DataTableController.php index dfe60c2..2cdbc38 100644 --- a/app/Http/Controllers/DataTableController.php +++ b/app/Http/Controllers/DataTableController.php @@ -30,13 +30,13 @@ class DataTableController extends Controller return $user->account ? $user->account->last_name : ''; }) ->addColumn('action', function (User $user) { - return ''; + return ''; }) ->addColumn('confirmed', function (User $user) { - return $user->confirmed ? '' : ''; + return $user->confirmed ? '' : ''; }) ->addColumn('active', function (User $user) { - return $user->active ? ' ' : ''; + return $user->active ? ' ' : ''; }) ->orderColumn('confirmed', 'confirmed $1') ->orderColumn('active', 'active $1') @@ -52,205 +52,31 @@ class DataTableController extends Controller return \DataTables::eloquent($query) ->addColumn('action_edit', function (Booking $booking) { - return ''; + return ''; }) ->addColumn('id', function (Booking $booking) { return ''.$booking->id.''; }) + ->addColumn('booking_date', function (Booking $booking) { + return Carbon::parse($booking->booking_date)->format(\Util::formatDateDB()); + }) + ->addColumn('start_date', function (Booking $booking) { + return Carbon::parse($booking->start_date)->format(\Util::formatDateDB()); + }) + ->addColumn('end_date', function (Booking $booking) { + return Carbon::parse($booking->end_date)->format(\Util::formatDateDB()); + }) ->orderColumn('id', 'id $1') + ->filterColumn('id', function($query, $keyword) { + if($keyword != ""){ + $query->where('id', 'LIKE', '%'.$keyword.'%'); + } + }) ->rawColumns(['action_edit', 'id']) ->make(true); } - public function getRequests() - { - - $query = Booking::where('lead_id', '!=', NULL); - - if(Input::get('full_firstname_search') != ""){ - $query->where('participant_firstname', 'LIKE', '%'.Input::get('full_firstname_search').'%'); - } - - if(Input::get('full_lastname_search') != ""){ - $query->where('participant_name', 'LIKE', '%'.Input::get('full_lastname_search').'%'); - } - - // $query->where('end_date', '<=', $now); - - if(Input::get('travel_option_search')){ - $now = Carbon::now(); - - - switch (Input::get('travel_option_search')){ - case 'before_2': - $query->whereBetween('start_date', [Carbon::now()->modify('-2 month'), $now]); - - break; - case 'brefore_1': - $query->whereBetween('start_date', [Carbon::now()->modify('-1 month'), $now]); - - break; - case 'on_site': - $query->where('start_date', '<=', $now); - $query->where('end_date', '>=', $now); - break; - case 'after_1': - $query->whereBetween('start_date', [$now, Carbon::now()->modify('+1 month')]); - - break; - case 'after_2': - $query->whereBetween('start_date', [$now, Carbon::now()->modify('+2 month')]); - - break; - } - }else{ - $start = null; - $end = null; - if(Input::get('arrival_start_date') != ""){ - $arrStart = explode(".", Input::get('arrival_start_date')); - if(count($arrStart) == 3){ - $start = Carbon::create($arrStart[2], $arrStart[1], $arrStart[0], 0, 0, 0); - } - } - if(Input::get('arrival_end_date') != ""){ - $arrEnd = explode(".", Input::get('arrival_end_date')); - if(count($arrEnd) == 3){ - $end = Carbon::create($arrEnd[2], $arrEnd[1], $arrEnd[0], 23, 59, 59); - } - } - if($start && $end){ - $query->whereBetween('start_date', [$start, $end]); - } - if($start && !$end){ - $query->where('start_date', '>=', $start); - } - if(!$start && $end){ - $query->where('start_date', '<=', $end); - } - - $start = null; - $end = null; - if(Input::get('departure_start_date') != ""){ - $arrStart = explode(".", Input::get('departure_start_date')); - if(count($arrStart) == 3){ - $start = Carbon::create($arrStart[2], $arrStart[1], $arrStart[0], 0, 0, 0); - } - } - if(Input::get('departure_end_date') != ""){ - $arrEnd = explode(".", Input::get('departure_end_date')); - if(count($arrEnd) == 3){ - $end = Carbon::create($arrEnd[2], $arrEnd[1], $arrEnd[0], 23, 59, 59); - } - } - if($start && $end){ - $query->whereBetween('end_date', [$start, $end]); - } - if($start && !$end){ - $query->where('end_date', '>=', $start); - } - if(!$start && $end){ - $query->where('end_date', '<=', $end); - } - } - - - - if(Input::get('sort_travel_country_id') != ""){ - $query->where('travel_country_id', '=', Input::get('sort_travel_country_id')); - } - if(Input::get('sort_travelagenda_id') != ""){ - $query->where('travelagenda_id', '=', Input::get('sort_travelagenda_id')); - } - - if(Input::get('sort_sf_guard_user_id') != ""){ - $query->where('sf_guard_user_id', '=', Input::get('sort_sf_guard_user_id')); - } - - if(Input::get('sort_travel_documents') != ""){ - $query->where('travel_documents', '=', Input::get('sort_travel_documents')); - } - - - if(Input::get('full_lead_id_search') != ""){ - $query->where('lead_id', 'LIKE', '%'.Input::get('full_lead_id_search'). '%'); - } - if(Input::get('full_booking_id_search') != ""){ - $query->where('id', 'LIKE', '%'.Input::get('full_booking_id_search').'%'); - } - - //confirmation_code_remider is delete 2 - // - - return \DataTables::eloquent($query) - ->addColumn('action_edit', function (Booking $booking) { - return ''; //''; - }) - ->addColumn('lead_id', function (Booking $booking) { - return ''.$booking->lead_id.''; - }) - ->addColumn('participant_firstname', function (Booking $booking) { - return ''.$booking->participant_firstname.''; - }) - ->addColumn('participant_name', function (Booking $booking) { - return ''.$booking->participant_name.''; - }) - ->addColumn('id', function (Booking $booking) { - return ''.$booking->id.''; - }) - ->addColumn('travel_country_id', function (Booking $booking) { - return ''.($booking->travel_country_id ? $booking->travel_country->name : "-").''; - }) - ->addColumn('travelagenda_id', function (Booking $booking) { - return ''.($booking->travelagenda_id ? $booking->travel_agenda->name : "-").''; - }) - ->addColumn('start_date', function (Booking $booking) { - return $booking->getStartDateFormat(); - }) - ->addColumn('end_date', function (Booking $booking) { - return $booking->getEndDateFormat(); - }) - ->addColumn('travel_documents', function (Booking $booking) { - return $booking->travel_documents ? ' ' : ''; - }) - ->addColumn('sf_guard_user_id', function (Booking $booking) { - return ''.($booking->sf_guard_user_id? $booking->sf_guard_user->first_name." ".$booking->sf_guard_user->last_name : "-").''; - }) - ->addColumn('lead.status_id', function (Booking $booking) { - return ''.($booking->lead->status_id ? $booking->lead->status->name : "-").''; - }) - /* ->filterColumn('travel_country_id', function($query, $keyword) { - - if($keyword != "") { - $query->whereRaw("travel_country_id = ?", $keyword); - } - - }) - ->filterColumn('travelagenda_id', function($query, $keyword) { - if($keyword != ""){ - $query->whereRaw("travelagenda_id = ?", $keyword); - - } - }) - */ - ->orderColumn('lead_id', 'lead_id $1') - ->orderColumn('participant_firstname', 'participant_firstname $1') - ->orderColumn('participant_name', 'participant_name $1') - ->orderColumn('id', 'id $1') - ->orderColumn('travel_country_id', 'travel_country_id $1') - ->orderColumn('travelagenda_id', 'travelagenda_id $1') - ->orderColumn('sf_guard_user_id', 'sf_guard_user_id $1') - ->orderColumn('start_date', 'start_date $1') - ->orderColumn('end_date', 'end_date $1') - ->orderColumn('travel_documents', 'travel_documents $1') - ->rawColumns(['action_edit', 'lead_id', 'participant_firstname', 'participant_name', 'travel_country_id', 'travelagenda_id', 'sf_guard_user_id', 'lead.status_id', 'id', 'travel_documents']) - ->make(true); - } - - - - - } diff --git a/app/Http/Controllers/RequestController.php b/app/Http/Controllers/RequestController.php index f9464ca..2aae410 100755 --- a/app/Http/Controllers/RequestController.php +++ b/app/Http/Controllers/RequestController.php @@ -3,7 +3,11 @@ namespace App\Http\Controllers; use App\Models\Booking; +use App\Models\Sym\TravelCountry; +use App\Models\TravelAgenda; +use Carbon\Carbon; use Input; +use DataTables; class RequestController extends Controller { @@ -16,8 +20,13 @@ class RequestController extends Controller public function index($step = false) { + + + $d = Booking::join('travel_country', 'travel_country_id', '=', 'travel_country.id')->get()->pluck('name', 'travel_country_id')->unique()->toArray(); + $data = [ - 'step' => $step + 'step' => $step, + 'travel_countries' => $d, ]; return view('request.index', $data); } @@ -36,6 +45,209 @@ class RequestController extends Controller } die(); */ + private function getSearchRequests(){ + + $query = Booking::where('lead_id', '!=', NULL); + + if(Input::get('full_firstname_search') != ""){ + $query->where('participant_firstname', 'LIKE', '%'.Input::get('full_firstname_search').'%'); + } + + if(Input::get('full_lastname_search') != ""){ + $query->where('participant_name', 'LIKE', '%'.Input::get('full_lastname_search').'%'); + } + + + if(Input::get('travel_option_country_id') != ""){ + $country_ids = TravelCountry::where('contact_lands', 'LIKE', '%"'.Input::get('travel_option_country_id').'"%')->get()->pluck('id'); + $country_ids[] = Input::get('travel_option_country_id'); + $query->whereIn('travel_country_id', $country_ids); + + } + if(Input::get('travel_option_agenda_id') != ""){ + $query->where('travelagenda_id', '=', Input::get('travel_option_agenda_id')); + + } + + // $query->where('end_date', '<=', $now); + + if(Input::get('travel_option_search')){ + $now = Carbon::now(); + + switch (Input::get('travel_option_search')){ + case 'before_2': + $query->whereBetween('start_date', [Carbon::now()->modify('-2 month'), $now]); + + break; + case 'brefore_1': + $query->whereBetween('start_date', [Carbon::now()->modify('-1 month'), $now]); + + break; + case 'on_site': + $query->where('start_date', '<=', $now); + $query->where('end_date', '>=', $now); + break; + case 'after_1': + $query->whereBetween('start_date', [$now, Carbon::now()->modify('+1 month')]); + + break; + case 'after_2': + $query->whereBetween('start_date', [$now, Carbon::now()->modify('+2 month')]); + + break; + } + }else{ + $start = null; + $end = null; + if(Input::get('arrival_start_date') != ""){ + $arrStart = explode(".", Input::get('arrival_start_date')); + if(count($arrStart) == 3){ + $start = Carbon::create($arrStart[2], $arrStart[1], $arrStart[0], 0, 0, 0); + } + } + if(Input::get('arrival_end_date') != ""){ + $arrEnd = explode(".", Input::get('arrival_end_date')); + if(count($arrEnd) == 3){ + $end = Carbon::create($arrEnd[2], $arrEnd[1], $arrEnd[0], 23, 59, 59); + } + } + if($start && $end){ + $query->whereBetween('start_date', [$start, $end]); + } + if($start && !$end){ + $query->where('start_date', '>=', $start); + } + if(!$start && $end){ + $query->where('start_date', '<=', $end); + } + + $start = null; + $end = null; + if(Input::get('departure_start_date') != ""){ + $arrStart = explode(".", Input::get('departure_start_date')); + if(count($arrStart) == 3){ + $start = Carbon::create($arrStart[2], $arrStart[1], $arrStart[0], 0, 0, 0); + } + } + if(Input::get('departure_end_date') != ""){ + $arrEnd = explode(".", Input::get('departure_end_date')); + if(count($arrEnd) == 3){ + $end = Carbon::create($arrEnd[2], $arrEnd[1], $arrEnd[0], 23, 59, 59); + } + } + if($start && $end){ + $query->whereBetween('end_date', [$start, $end]); + } + if($start && !$end){ + $query->where('end_date', '>=', $start); + } + if(!$start && $end){ + $query->where('end_date', '<=', $end); + } + } + + + + if(Input::get('sort_travel_country_id') != ""){ + $query->where('travel_country_id', '=', Input::get('sort_travel_country_id')); + } + if(Input::get('sort_travelagenda_id') != ""){ + $query->where('travelagenda_id', '=', Input::get('sort_travelagenda_id')); + } + + if(Input::get('sort_sf_guard_user_id') != ""){ + $query->where('sf_guard_user_id', '=', Input::get('sort_sf_guard_user_id')); + } + + if(Input::get('sort_travel_documents') != ""){ + $query->where('travel_documents', '=', Input::get('sort_travel_documents')); + } + + + if(Input::get('full_lead_id_search') != ""){ + $query->where('lead_id', 'LIKE', '%'.Input::get('full_lead_id_search'). '%'); + } + if(Input::get('full_booking_id_search') != ""){ + $query->where('id', 'LIKE', '%'.Input::get('full_booking_id_search').'%'); + } + return $query; + } + public function getAjaxRequests(){ + + $query = $this->getSearchRequests(); + $ret = $query->get()->pluck('travelagenda_id', 'id')->unique()->toArray(); + return TravelAgenda::whereIn('id', $ret)->get()->pluck('name', 'id'); + } + + public function getRequests() + { + + $query = $this->getSearchRequests(); + + return \DataTables::eloquent($query) + ->addColumn('action_edit', function (Booking $booking) { + return ''; //''; + }) + ->addColumn('lead_id', function (Booking $booking) { + return ''.$booking->lead_id.''; + }) + ->addColumn('participant_firstname', function (Booking $booking) { + return ''.$booking->participant_firstname.''; + }) + ->addColumn('participant_name', function (Booking $booking) { + return ''.$booking->participant_name.''; + }) + ->addColumn('id', function (Booking $booking) { + return ''.$booking->id.''; + }) + ->addColumn('travel_country_id', function (Booking $booking) { + return ''.($booking->travel_country_id ? $booking->travel_country->name : "-").''; + }) + ->addColumn('travelagenda_id', function (Booking $booking) { + return ''.($booking->travelagenda_id ? $booking->travel_agenda->name : "-").''; + }) + ->addColumn('start_date', function (Booking $booking) { + return $booking->getStartDateFormat(); + }) + ->addColumn('end_date', function (Booking $booking) { + return $booking->getEndDateFormat(); + }) + ->addColumn('travel_documents', function (Booking $booking) { + return $booking->travel_documents ? ' ' : ''; + }) + ->addColumn('sf_guard_user_id', function (Booking $booking) { + return ''.($booking->sf_guard_user_id? $booking->sf_guard_user->first_name." ".$booking->sf_guard_user->last_name : "-").''; + }) + ->addColumn('lead.status_id', function (Booking $booking) { + return ''.($booking->lead->status_id ? $booking->lead->status->name : "-").''; + }) + /* ->filterColumn('travel_country_id', function($query, $keyword) { + + if($keyword != "") { + $query->whereRaw("travel_country_id = ?", $keyword); + } + + }) + ->filterColumn('travelagenda_id', function($query, $keyword) { + if($keyword != ""){ + $query->whereRaw("travelagenda_id = ?", $keyword); + + } + }) + */ + ->orderColumn('lead_id', 'lead_id $1') + ->orderColumn('participant_firstname', 'participant_firstname $1') + ->orderColumn('participant_name', 'participant_name $1') + ->orderColumn('id', 'id $1') + ->orderColumn('travel_country_id', 'travel_country_id $1') + ->orderColumn('travelagenda_id', 'travelagenda_id $1') + ->orderColumn('sf_guard_user_id', 'sf_guard_user_id $1') + ->orderColumn('start_date', 'start_date $1') + ->orderColumn('end_date', 'end_date $1') + ->orderColumn('travel_documents', 'travel_documents $1') + ->rawColumns(['action_edit', 'lead_id', 'participant_firstname', 'participant_name', 'travel_country_id', 'travelagenda_id', 'sf_guard_user_id', 'lead.status_id', 'id', 'travel_documents']) + ->make(true); + } } diff --git a/app/Http/Controllers/SyS/Tools/ContentLinkController.php b/app/Http/Controllers/SyS/Tools/ContentLinkController.php new file mode 100755 index 0000000..3be911e --- /dev/null +++ b/app/Http/Controllers/SyS/Tools/ContentLinkController.php @@ -0,0 +1,418 @@ +middleware('auth'); + } + + public function index() + { + $val = []; + $text = ""; + $travelGuides = TravelGuide::all(); + foreach ($travelGuides as $travelGuide){ + if(strpos($travelGuide->full_text, "


") !== false){ + $val[$travelGuide->id] = "


"; + } + } + + foreach ($travelGuides as $travelGuide){ + if(strpos($travelGuide->full_text, "id] = "full_text; + + // $new_text = preg_replace('/]*>([\s\S]*?)<\/h1[^>]*>/', '', $TravelGuide->full_text); + + + $data = [ + 'text' => $text, + 'values' => $val, + ]; + return view('sys.tools.links', $data); + } + + + + + public function store() + { + $travelGuides = TravelGuide::all(); + foreach ($travelGuides as $travelGuide){ + if(strpos($travelGuide->full_text, "


") !== false) { + $travelGuide->full_text = str_replace("


", "", $travelGuide->full_text); + $travelGuide->save(); + } + } + + foreach ($travelGuides as $travelGuide){ + if(strpos($travelGuide->full_text, "full_text = str_replace("full_text); + $travelGuide->full_text = str_replace("h1>", "h2>", $travelGuide->full_text); + $travelGuide->save(); + + } + } + + return redirect()->back(); + + //$this->readNodeAndSaveToTree(); + //$this->cleanTextTravelGuide(); + //$this->h1ToTitleTravelGuide(); + } + + + public function treeTitle() + { + $text = ""; + $val = []; + $trees = IQContentTree::all(); + foreach ($trees as $tree){ + foreach ($tree->iq_content_tree_nodes as $tree_node){ + + $text .= $tree_node->id." -- ".$tree_node->title."\n"; + foreach ($tree_node->iq_content_sites as $site){ + if(isset($site->travel_guide->meta_title)){ + if(isset($val[$tree_node->id])){ + if(strlen($site->travel_guide->meta_title) > strlen($val[$tree_node->id])){ + $val[$tree_node->id] = $site->travel_guide->meta_title; + } + }else{ + $val[$tree_node->id] = $site->travel_guide->meta_title; + } + } + } + } + } + $data = [ + 'text' => $text, + 'values' => $val, + ]; + return view('sys.tools.trees', $data); + } + + public function treeTitleStore() + { + + $trees = IQContentTree::all(); + $val = []; + foreach ($trees as $tree){ + foreach ($tree->iq_content_tree_nodes as $tree_node){ + foreach ($tree_node->iq_content_sites as $site){ + if(isset($site->travel_guide->meta_title)){ + if(isset($val[$tree_node->id])){ + if(strlen($site->travel_guide->meta_title) > strlen($val[$tree_node->id])){ + $val[$tree_node->id] = $site->travel_guide->meta_title; + } + }else{ + $val[$tree_node->id] = $site->travel_guide->meta_title; + } + } + } + if(isset($val[$tree_node->id])){ + $tree_node->title = $val[$tree_node->id]; + $tree_node->save(); + } + + } + } + return redirect()->back(); + } + + + + + public function h1ToTitleTravelGuide() + { + $TravelGuides = TravelGuide::all(); + foreach ($TravelGuides as $travelGuide){ + if(strpos($travelGuide->full_text,'

' )){ + $dom = new \DOMDocument('1.0', 'utf-8'); + @$dom->loadHTML(mb_convert_encoding($travelGuide->full_text, 'HTML-ENTITIES', 'UTF-8')); + $elements = $dom->getElementsByTagName('h1'); + + foreach ($elements as $element) { + if($element->nodeValue != ""){ + var_dump($travelGuide->id); + var_dump($element->nodeValue); + echo "
"; + var_dump($travelGuide->name); + echo "
"; + echo "--"; + echo "
"; + + $new_text = preg_replace('/]*>([\s\S]*?)<\/h1[^>]*>/', '', $travelGuide->full_text); + + $travelGuide->name = $element->nodeValue; + $travelGuide->full_text = $new_text; + $travelGuide->save(); + } + } + } + } + die("done"); + } + + + public function cleanTextTravelGuide() + { + $TravelGuides = TravelGuide::all(); + foreach ($TravelGuides as $travelGuide){ + $new_text = \App\Services\Util::cleanHTML($travelGuide->full_text); + if(strcmp($travelGuide->full_text, $new_text) != 0){ + $travelGuide->full_text = $new_text; + $travelGuide->save(); + var_dump($travelGuide->id); + echo "
"; + } + } + die("done"); + } + + + public function readNodeAndSaveToTree(){ + $input = Input::all(); + $ret = []; + if(isset($input['text'])){ + $out = $this->ul_to_array($input['text']); + $this->array_to_nodes($out); + } + die("done"); + $data = [ + 'text' => $input['text'], + 'values' => $ret, + ]; + return view('iq.tools.links', $data); + } + + public function array_to_nodes($array, $lvl = 1, $parent_id = 1, $pos=100){ + + + if(is_array($array)){ + foreach ($array as $node){ + if(isset($node['slug'])){ + + $slug = substr($node['slug'], 0, 80); + // $slug = substr($node['slug'], 0, strrpos($slug, " ")); + + $name = substr($node['name'], 0, 255); + // $name = substr($node['name'], 0, strrpos($name, " ")); + + + $data = [ + 'tree_id' => 1, + 'parent_id' => $parent_id, + 'lvl' => $lvl, + 'name' => $name, + 'identifier' => $slug, + 'active' => false, + 'pos' => $pos++, + ]; + $tree_node = IQContentTreeNode::create($data); + + + $travel_guides = TravelGuide::whereSlug($node['slug'])->get(); + foreach ($travel_guides as $travel_guide){ + if(IQContentSite::whereTreeNodeId($tree_node->id)->whereTravelGuideId($travel_guide->id)->count() == 0) { + IQContentSite::create(['tree_node_id' => $tree_node->id, 'travel_guide_id' => $travel_guide->id]); + } + } + + + } + if(isset($node['children']) && is_array($node['children'])){ + $this->array_to_nodes($node['children'], $lvl + 1, $tree_node->id, $pos); + } + } + } + + } + + + public function ul_to_array($ol){ + if(is_string($ol)){ + if(!$ol = simplexml_load_string($ol)) { + trigger_error("Syntax error in UL/LI structure"); + return FALSE; + } + return $this->ul_to_array($ol); + } else if(is_object($ol)){ + $output = array(); + foreach($ol->li as $li){ + + $tmp = false; + if(isset($li->ol)){ + $tmp = $this->ul_to_array($li->ol); + } + + if($li->count()){ + + $str = (string) $li; + + $a = new \SimpleXMLElement($li->children()->asXML()); + $str = (string) $a[0]." ".$str; + $str = str_replace("\n", "", $str); + $str = str_replace("\r", "", $str); + $str = str_replace("\t", "", $str); + $str = preg_replace(array('/\s{2,}/', '/[\t\n]/'), ' ', $str); + + if(trim($str) !== "" && $str !== null){ + $slug = (string) $a['href']; + $link = explode("/", $slug); + + $link1 = array_pop($link); + $link1 = str_replace('.htm', '',$link1); + $output[] = ['slug'=> $link1, 'name'=>$str, 'children'=>$tmp]; + } + }else{ + $str = (string) $li; + $str = str_replace("\n", "", $str); + $str = str_replace("\r", "", $str); + $str = str_replace("\t", "", $str); + if(trim($str) !== "" && $str !== null){ + + $output[] = ['slug'=>'', 'name'=>$str, 'children'=>$tmp]; + } + } + + } + return $output; + } else { + return FALSE; + } + } + + /** + * @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View + */ + public function rindex() + { + $data = [ + 'text' => "", + 'values' => [], + ]; + return view('iq.content.tools.redirects', $data); + } + + + + public function rstore() + { + + $iqContentTree = IQContentTree::find(2); + $this->makeTree($iqContentTree); + $input = Input::all(); + $ret = []; + + if(isset($input['text'])){ + + + $dom = new \DOMDocument('1.0', 'utf-8'); + @$dom->loadHTML(mb_convert_encoding($input['text'], 'HTML-ENTITIES', 'UTF-8')); + + + + + $tags = ['ol']; + foreach ($tags as $tag){ + $domElements = []; + $elements = $dom->getElementsByTagName($tag)->item(0); + + foreach($elements as $node){ + foreach($node->childNodes as $child) { + $ret[] = array($child->nodeName => $child->nodeValue); + } + } + } + + /* $tags = ['a']; foreach ($tags as $tag){ + $domElements = []; + $elements = $dom->getElementsByTagName($tag); + foreach ($elements as $element) { + $domElements[] = $element; + + } + foreach ($domElements as $domElement) { + $r = "-----"; + $href = $domElement->getAttribute('href'); + $link = explode("/", $href); + + $link1 = array_pop($link); + $link1 = str_replace('.html', '',$link1); + $link1 = str_replace('-', '',$link1); + if(isset($this->tree[$link1])){ + $r = $this->tree[$link1]; + }else{ + $link1 = array_pop($link); + $link1 = str_replace('.html', '',$link1); + $link1 = str_replace('-', '',$link1); + if(isset($this->tree[$link1])){ + $r = $this->tree[$link1]; + } + } + + $ret[] = "Redirect 301 /".$href." ".$r; + + } + }*/ + + } + $data = [ + 'text' => $input['text'], + 'values' => $ret, + ]; + + return view('iq.content.tools.redirects', $data); + + } + + + + public function makeTree(IQContentTree $iq_content_tree, $lvl = 0, $parent_id = false, $url = "") + { + + if ($parent_id) { + //where('active', true) + $tree_nodes = IQContentTreeNode::where('tree_id', $iq_content_tree->id)->where('lvl', $lvl)->where('active', true)->where('parent_id', $parent_id)->orderBy('pos', 'ASC')->get(); + } else { + + $url = "/" . $iq_content_tree->identifier . "/"; + $tree_nodes = IQContentTreeNode::where('tree_id', $iq_content_tree->id)->where('lvl', $lvl)->where('active', true)->orderBy('pos', 'ASC')->get(); + } + + foreach ($tree_nodes as $node) { + $children = IQContentTreeNode::where('tree_id', $iq_content_tree->id)->where('lvl', $lvl + 1)->where('active', true)->where('parent_id', $node->id)->count(); + $this->tree[str_replace('-', '', $node->identifier)] = url($url . $node->identifier); + + if ($children) { + $this->makeTree($iq_content_tree, $lvl + 1, $node->id, $url . $node->identifier . "/"); + + } + } + return true; + } + + + +} diff --git a/app/Http/Controllers/TravelUserBookingFewoController.php b/app/Http/Controllers/TravelUserBookingFewoController.php index 2ef521d..cd4a7a4 100755 --- a/app/Http/Controllers/TravelUserBookingFewoController.php +++ b/app/Http/Controllers/TravelUserBookingFewoController.php @@ -190,7 +190,7 @@ class TravelUserBookingFewoController extends Controller return \DataTables::eloquent($query) ->addColumn('action_edit', function (TravelUserBookingFewo $travel_user_booking_fewo) { - return ''; + return ''; }) ->addColumn('fewo_lodging', function (TravelUserBookingFewo $travel_user_booking_fewo) { //return ''.$travel_user_booking_fewo->fewo_lodging->name.''; @@ -217,7 +217,7 @@ class TravelUserBookingFewoController extends Controller return $travel_user_booking_fewo->getStatuesName(); }) ->addColumn('action_delete', function (TravelUserBookingFewo $travel_user_booking_fewo) { - return ''; + return ''; }) ->rawColumns(['action_edit', 'fewo_lodging', 'travel_user', 'is_calendar', 'is_mail', 'action_delete']) ->make(true); diff --git a/app/Http/Controllers/TravelUserController.php b/app/Http/Controllers/TravelUserController.php index 18f41ce..1d94fde 100755 --- a/app/Http/Controllers/TravelUserController.php +++ b/app/Http/Controllers/TravelUserController.php @@ -96,11 +96,11 @@ class TravelUserController extends Controller return \DataTables::eloquent($query) ->addColumn('action_edit', function (TravelUser $user) { - return ''; + return ''; }) ->addColumn('action_delete', function (TravelUser $user) { - return ''; + return ''; }) ->rawColumns(['action_edit', 'action_delete']) ->make(true); diff --git a/app/Http/Controllers/UserUpdateEmailController.php b/app/Http/Controllers/UserUpdateEmailController.php index 1071287..fd6699c 100755 --- a/app/Http/Controllers/UserUpdateEmailController.php +++ b/app/Http/Controllers/UserUpdateEmailController.php @@ -11,7 +11,7 @@ use Carbon\Carbon; use Illuminate\Database\Connection; use Illuminate\Http\Request; use App\Http\Controllers\Controller; -use App\Mail\MailActivateUser; +use App\Mail\ReportExport; use Illuminate\Support\Facades\Mail; class UserUpdateEmailController extends Controller @@ -146,7 +146,7 @@ class UserUpdateEmailController extends Controller public function sendActivationMail($user, array $data) { $token = $this->createActivation($user, $data); - Mail::to($data['email'])->send(new MailActivateUser($token, $user)); + Mail::to($data['email'])->send(new ReportExport($token, $user)); } diff --git a/app/Http/Kernel.php b/app/Http/Kernel.php index 932f721..78807d1 100755 --- a/app/Http/Kernel.php +++ b/app/Http/Kernel.php @@ -56,6 +56,7 @@ class Kernel extends HttpKernel 'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class, 'admin' => \App\Http\Middleware\Admin::class, 'superadmin' => \App\Http\Middleware\SuperAdmin::class, + 'sysadmin' => \App\Http\Middleware\SysAdmin::class, 'auth.permission' => \App\Http\Middleware\AuthPermission::class, 'bindings' => \Illuminate\Routing\Middleware\SubstituteBindings::class, 'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class, diff --git a/app/Http/Middleware/SysAdmin.php b/app/Http/Middleware/SysAdmin.php new file mode 100755 index 0000000..4f5b955 --- /dev/null +++ b/app/Http/Middleware/SysAdmin.php @@ -0,0 +1,26 @@ +isSySAdmin() ) + { + return $next($request); + } + return redirect('/home'); + + } +} diff --git a/app/Models/Arrangement.php b/app/Models/Arrangement.php new file mode 100644 index 0000000..9d559b9 --- /dev/null +++ b/app/Models/Arrangement.php @@ -0,0 +1,88 @@ + 'int', + 'view_position' => 'int', + 'booking_id' => 'int', + 'type_id' => 'int', + 'in_pdf' => 'bool' + ]; + + protected $dates = [ + 'state', + 'begin', + 'end' + ]; + + protected $fillable = [ + 'template_id', + 'state', + 'begin', + 'end', + 'type_s', + 'data_s', + 'view_position', + 'booking_id', + 'type_id', + 'in_pdf' + ]; + + public function booking() + { + return $this->belongsTo(Booking::class); + } + + public function arrangement_template() + { + return $this->belongsTo(ArrangementTemplate::class, 'template_id'); + } +} diff --git a/app/Models/ArrangementTemplate.php b/app/Models/ArrangementTemplate.php new file mode 100644 index 0000000..755556f --- /dev/null +++ b/app/Models/ArrangementTemplate.php @@ -0,0 +1,42 @@ +hasMany(Arrangement::class, 'template_id'); + } +} diff --git a/app/Models/ArrangementType.php b/app/Models/ArrangementType.php new file mode 100644 index 0000000..e95f1d7 --- /dev/null +++ b/app/Models/ArrangementType.php @@ -0,0 +1,92 @@ + 'int', + 'arrangement_type_id' => 'int', + 'is_unique' => 'bool', + 'notify_rel_field_key' => 'int' + ]; + + protected $fillable = [ + 'name', + 'notify_rel_days', + 'arrangement_type_id', + 'is_unique', + 'notify_rel_field_key' + ]; + + public function arrangement_type() + { + return $this->belongsTo(ArrangementType::class); + } + + public function booking() + { + return $this->belongsTo(Booking::class); + } + + public function draft_item() + { + return $this->belongsTo(DraftItem::class); + } + + public function draft_type() + { + return $this->belongsTo(DraftType::class); + } + + public function arrangement_types() + { + return $this->hasMany(ArrangementType::class); + } + + public function inquiry_types() + { + return $this->hasMany(InquiryType::class); + } +} diff --git a/app/Models/Booking.php b/app/Models/Booking.php index 4137c21..176f35f 100644 --- a/app/Models/Booking.php +++ b/app/Models/Booking.php @@ -1,53 +1,85 @@ 'int', + 'lead_id' => 'int', + 'new_drafts' => 'bool', + 'sf_guard_user_id' => 'int', + 'branch_id' => 'int', + 'service_fee' => 'float', + 'travel_country_id' => 'int', + 'travel_category_id' => 'int', + 'pax' => 'int', + 'coupon_id' => 'int', + 'website_id' => 'int', + 'participant_salutation_id' => 'int', + 'travel_company_id' => 'int', + 'travel_documents' => 'bool', + 'price' => 'float', + 'price_total' => 'float', + 'deposit_total' => 'float', + 'final_payment' => 'float', + 'travelagenda_id' => 'int' + ]; - public function booking_draft_items() - { - return $this->hasMany('App\Models\BookingDraftItem', 'booking_id', 'id')->orderBy('pos', 'ASC'); - } + protected $dates = [ + 'booking_date', + 'start_date', + 'end_date', + 'participant_birthdate', + 'final_payment_date' + ]; - //on crm - public function travel_agenda() + protected $fillable = [ + 'booking_date', + 'customer_id', + 'lead_id', + 'new_drafts', + 'sf_guard_user_id', + 'branch_id', + 'service_fee', + 'travel_country_id', + 'travel_category_id', + 'pax', + 'coupon_id', + 'title', + 'start_date', + 'end_date', + 'website_id', + 'travel_number', + 'participant_name', + 'participant_firstname', + 'participant_birthdate', + 'participant_salutation_id', + 'ev_number', + 'merlin_knr', + 'merlin_order_number', + 'travel_company_id', + 'travel_documents', + 'price', + 'price_total', + 'deposit_total', + 'final_payment', + 'final_payment_date', + 'travelagenda_id' + ]; + + /*public function branch() + { + return $this->belongsTo(Branch::class); + }*/ + + public function coupon() + { + return $this->belongsTo(Coupon::class); + } + + public function customer() + { + return $this->belongsTo(Customer::class); + } + + public function lead() + { + return $this->belongsTo(Lead::class); + } + + public function sf_guard_user() + { + return $this->belongsTo(SfGuardUser::class); + } + + public function travel_category() + { + return $this->belongsTo(TravelCategory::class); + } + + public function travel_company() + { + return $this->belongsTo(TravelCompany::class); + } + + /* public function travel_country() { - return $this->belongsTo('App\Models\TravelAgenda', 'travelagenda_id', 'id'); - } + return $this->belongsTo(TravelCountry::class, 'travel_country_id', 'crm_id'); + }*/ + public function travel_country() { - return $this->belongsTo('App\Models\TravelCountry', 'travel_country_id', 'crm_id'); + return $this->belongsTo(\App\Models\Sym\TravelCountry::class, 'travel_country_id', 'id'); } - public function lead() - { - return $this->belongsTo('App\Models\Lead', 'lead_id', 'id'); - } + public function travel_agenda() + { + return $this->belongsTo(TravelAgenda::class, 'travelagenda_id'); + } - public function sf_guard_user() - { - return $this->belongsTo('App\Models\SfGuardUser', 'sf_guard_user_id', 'id'); - } + public function arrangements() + { + return $this->hasMany(Arrangement::class); + } - public function arrangements() - { - return $this->hasMany('App\Models\Sym\Arrangement', 'booking_id', 'id')->orderBy('view_position', 'DESC'); - } + public function arrangement_types() + { + return $this->hasMany(ArrangementType::class); + } + + /*public function booking_applications() + { + return $this->hasMany(BookingApplication::class); + } + + public function booking_confirmations() + { + return $this->hasMany(BookingConfirmation::class); + }*/ + + public function booking_draft_items() + { + return $this->hasMany(BookingDraftItem::class)->orderBy('pos', 'ASC'); + } + + /*public function booking_invoices() + { + return $this->hasMany(BookingInvoice::class); + }*/ + + public function booking_service_items() + { + return $this->hasMany(BookingServiceItem::class); + } + + /*public function booking_vouchers() + { + return $this->hasMany(BookingVoucher::class); + }*/ + + public function coupons() + { + return $this->hasMany(Coupon::class); + } + + public function insurance_certificates() + { + return $this->hasMany(InsuranceCertificate::class); + } + + public function participants() + { + return $this->hasMany(Participant::class); + } + + public function service_provider_entries() + { + return $this->hasMany(ServiceProviderEntry::class); + } + /* + public function travel_insurances() + { + return $this->hasMany(TravelInsurance::class); + }*/ public function calculate_price_total() @@ -152,7 +325,7 @@ class Booking extends Model } $total_adult += $prices['adult']; $total_children += $prices['children']; - } + } if($travel_draft_item){ $travel_draft_item->setPriceAdultRaw($travel_price_adult); @@ -171,6 +344,11 @@ class Booking extends Model return number_format(($this->attributes['price']), 2, ',', '.'); } + public function getPriceRaw() + { + return $this->attributes['price']; + } + public function findBeforeDraftItemRelation($reid) { $before = false; @@ -207,4 +385,56 @@ class Booking extends Model return Carbon::parse($this->attributes['end_date'])->format(\Util::formatDateDB()); } + + //erlös #getRevenueFactor + public function proceeds(){ + $proceeds = $this->attributes['price'] + // - $this->getServiceTotal() + // - $this->getServiceFee() + - $this->getServiceProviderEntriesAmountFactorTotal(); + + return number_format(($proceeds), 2, ',', '.'); + + } + + public function getServiceProviderEntriesAmountFactorTotal() + { + $total = 0; + foreach ($this->service_provider_entries as $entry) + { + $total += $entry->amount / $entry->factor; + } + return $total; + } + + public function getServiceProviderPaymentsTotal() + { + $total = 0; + foreach ($this->service_provider_entries as $entry) + { + $total += $entry->amount; + } + return number_format(($total), 2, ',', '.'); + } + + public function getKontoNumber(){ + + switch ($this->ev_number){ + case 'E01': + return '4011'; + break; + case 'E02': + return '4012'; + break; + case 'E03': + return '4013'; + break; + case 'E04': + return '4014'; + break; + + } + return $this->ev_number; + } + } diff --git a/app/Models/BookingServiceItem.php b/app/Models/BookingServiceItem.php new file mode 100644 index 0000000..6027a1f --- /dev/null +++ b/app/Models/BookingServiceItem.php @@ -0,0 +1,84 @@ + 'int', + 'travel_company_id' => 'int', + 'service_price' => 'float', + 'service_price_refund' => 'float', + 'commission' => 'float', + 'is_commission_locked' => 'bool' + ]; + + protected $dates = [ + 'travel_date' + ]; + + protected $fillable = [ + 'booking_id', + 'travel_company_id', + 'service_price', + 'service_price_refund', + 'commission', + 'travel_date', + 'name', + 'is_commission_locked' + ]; + + public function booking() + { + return $this->belongsTo(Booking::class); + } + + public function travel_company() + { + return $this->belongsTo(TravelCompany::class); + } +} diff --git a/app/Models/Coupon.php b/app/Models/Coupon.php new file mode 100644 index 0000000..873bd76 --- /dev/null +++ b/app/Models/Coupon.php @@ -0,0 +1,92 @@ + 'int', + 'booking_id' => 'int', + 'value' => 'float', + 'is_redeemed' => 'bool' + ]; + + protected $dates = [ + 'issue_date', + 'valid_date', + 'redeem_date' + ]; + + protected $fillable = [ + 'number', + 'customer_id', + 'booking_id', + 'value', + 'issue_date', + 'valid_date', + 'is_redeemed', + 'redeem_date' + ]; + + public function booking() + { + return $this->belongsTo(Booking::class); + } + + public function customer() + { + return $this->belongsTo(Customer::class); + } + + public function bookings() + { + return $this->hasMany(Booking::class); + } +} diff --git a/app/Models/CreditCardType.php b/app/Models/CreditCardType.php new file mode 100644 index 0000000..87715c8 --- /dev/null +++ b/app/Models/CreditCardType.php @@ -0,0 +1,42 @@ +hasMany(Customer::class); + } +} diff --git a/app/Models/Customer.php b/app/Models/Customer.php new file mode 100644 index 0000000..b029384 --- /dev/null +++ b/app/Models/Customer.php @@ -0,0 +1,168 @@ + 'int', + 'credit_card_type_id' => 'int', + 'country_id' => 'int' + ]; + + protected $dates = [ + 'birthdate', + 'credit_card_expiration_date' + ]; + + protected $fillable = [ + 'salutation_id', + 'title', + 'name', + 'firstname', + 'birthdate', + 'company', + 'street', + 'zip', + 'city', + 'email', + 'phone', + 'phonebusiness', + 'phonemobile', + 'fax', + 'bank', + 'bank_code', + 'bank_account_number', + 'credit_card_type_id', + 'credit_card_number', + 'credit_card_expiration_date', + 'participants_remarks', + 'miscellaneous_remarks', + 'country_id', + + ]; + + public function travel_country() + { + return $this->belongsTo(TravelCountry::class, 'country_id'); + } + + public function credit_card_type() + { + return $this->belongsTo(CreditCardType::class); + } + + public function salutation() + { + return $this->belongsTo(Salutation::class); + } + + public function bookings() + { + return $this->hasMany(Booking::class); + } + + public function coupons() + { + return $this->hasMany(Coupon::class); + } + + public function leads() + { + return $this->hasMany(Lead::class); + } + + public function fullName() + { + if ($this->firstname) { + return $this->firstname . ' ' . $this->name; + } + return $this->name; + } + +} + + + diff --git a/app/Models/IQContentTreeNode.php b/app/Models/IQContentTreeNode.php index 117107a..be7f801 100644 --- a/app/Models/IQContentTreeNode.php +++ b/app/Models/IQContentTreeNode.php @@ -55,6 +55,8 @@ use Illuminate\Support\Str; * @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\IQContentSite[] $iq_content_sites * @property-read int|null $iq_content_sites_count * @property-read int|null $iq_content_tree_node_childs_count + * @property string|null $title + * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\IQContentTreeNode whereTitle($value) */ class IQContentTreeNode extends Model { @@ -68,7 +70,7 @@ class IQContentTreeNode extends Model protected $table = 'i_q_content_tree_nodes'; protected $fillable = [ - 'tree_id', 'parent_id', 'lvl', 'name', 'identifier', 'description', 'settings', 'pos', 'active', + 'tree_id', 'parent_id', 'lvl', 'name', 'identifier', 'title', 'description', 'settings', 'pos', 'active', ]; protected $casts = ['settings' => 'array']; diff --git a/app/Models/InitialContactType.php b/app/Models/InitialContactType.php new file mode 100644 index 0000000..5b31f1d --- /dev/null +++ b/app/Models/InitialContactType.php @@ -0,0 +1,42 @@ +hasMany(Lead::class, 'initialcontacttype_id'); + } +} diff --git a/app/Models/Inquiry.php b/app/Models/Inquiry.php new file mode 100644 index 0000000..6a8bd72 --- /dev/null +++ b/app/Models/Inquiry.php @@ -0,0 +1,90 @@ + 'int', + 'template_id' => 'int', + 'in_pdf' => 'bool', + 'type_id' => 'int', + 'view_position' => 'int' + ]; + + protected $dates = [ + 'begin', + 'end' + ]; + + protected $fillable = [ + 'lead_id', + 'template_id', + 'in_pdf', + 'begin', + 'end', + 'type_id', + 'type_s', + 'data_s', + 'view_position' + ]; + + public function lead() + { + return $this->belongsTo(Lead::class); + } + + public function inquiry_template() + { + return $this->belongsTo(InquiryTemplate::class, 'template_id'); + } + + public function inquiry_type() + { + return $this->belongsTo(InquiryType::class, 'type_id'); + } +} diff --git a/app/Models/InquiryTemplate.php b/app/Models/InquiryTemplate.php new file mode 100644 index 0000000..bc3cc67 --- /dev/null +++ b/app/Models/InquiryTemplate.php @@ -0,0 +1,42 @@ +hasMany(Inquiry::class, 'template_id'); + } +} diff --git a/app/Models/InquiryType.php b/app/Models/InquiryType.php new file mode 100644 index 0000000..fd90357 --- /dev/null +++ b/app/Models/InquiryType.php @@ -0,0 +1,55 @@ + 'int' + ]; + + protected $fillable = [ + 'name', + 'arrangement_type_id' + ]; + + public function arrangement_type() + { + return $this->belongsTo(ArrangementType::class); + } + + public function inquiries() + { + return $this->hasMany(Inquiry::class, 'type_id'); + } +} diff --git a/app/Models/InsuranceCertificate.php b/app/Models/InsuranceCertificate.php new file mode 100644 index 0000000..8e4db08 --- /dev/null +++ b/app/Models/InsuranceCertificate.php @@ -0,0 +1,62 @@ + 'int', + 'internal_id' => 'int', + 'binary_data' => 'boolean' + ]; + + protected $fillable = [ + 'booking_id', + 'internal_id', + 'filename', + 'binary_data', + 'request_data' + ]; + + public function booking() + { + return $this->belongsTo(Booking::class); + } +} diff --git a/app/Models/Lead.php b/app/Models/Lead.php index e4f568b..ff17846 100644 --- a/app/Models/Lead.php +++ b/app/Models/Lead.php @@ -1,40 +1,68 @@ 'int', + 'travelperiod_length' => 'int', + 'travelcountry_id' => 'int', + 'travelagenda_id' => 'int', + 'sf_guard_user_id' => 'int', + 'is_closed' => 'bool', + 'initialcontacttype_id' => 'int', + 'searchengine_id' => 'int', + 'status_id' => 'int', + 'website_id' => 'int', + 'travelcategory_id' => 'int', + 'price' => 'float', + 'pax' => 'int', + 'participant_salutation_id' => 'int' + ]; + + protected $dates = [ + 'request_date', + 'travelperiod_start', + 'travelperiod_end', + 'next_due_date', + 'participant_birthdate' + ]; + + protected $fillable = [ + 'customer_id', + 'request_date', + 'travelperiod_start', + 'travelperiod_end', + 'travelperiod_length', + 'travelcountry_id', + 'travelagenda_id', + 'remarks', + 'sf_guard_user_id', + 'is_closed', + 'initialcontacttype_id', + 'searchengine_id', + 'searchengine_keywords', + 'status_id', + 'next_due_date', + 'website_id', + 'travelcategory_id', + 'price', + 'pax', + 'participant_name', + 'participant_firstname', + 'participant_birthdate', + 'participant_salutation_id' + ]; + + public function updateNextDueDate($date = false){ + + if(!$date){ + $carbon = Carbon::now(); + $this->next_due_date = $carbon->modify('+ '.$this->status->handling_days.' days')->format("Y-m-d"); + $this->save(); + } + } + public function customer() + { + return $this->belongsTo(Customer::class); + } + + public function initial_contact_type() + { + return $this->belongsTo(InitialContactType::class, 'initialcontacttype_id'); + } + + public function salutation() + { + return $this->belongsTo(Salutation::class, 'participant_salutation_id'); + } + + public function searchengine() + { + return $this->belongsTo(Searchengine::class); + } + + public function sf_guard_user() + { + return $this->belongsTo(SfGuardUser::class); + } + + public function status() + { + return $this->belongsTo(Status::class); + } + + public function travel_agenda() + { + return $this->belongsTo(TravelAgenda::class, 'travelagenda_id'); + } + + public function travel_category() + { + return $this->belongsTo(TravelCategory::class, 'travelcategory_id'); + } + + //on crm + public function travel_country_crm() { - return $this->belongsTo('App\Models\Status', 'status_id', 'id'); + return $this->belongsTo('App\Models\Sym\TravelCountry', 'travelcountry_id', 'id'); } - public function sf_guard_user() + + //on stern other DB + public function travel_country() { - return $this->belongsTo('App\Models\SfGuardUser', 'sf_guard_user_id', 'id'); + return $this->belongsTo('App\Models\TravelCountry', 'travelcountry_id', 'crm_id'); } + + + public function website() + { + return $this->belongsTo(Website::class); + } + + public function bookings() + { + return $this->hasMany(Booking::class); + } + + public function inquiries() + { + return $this->hasMany(Inquiry::class); + } + + public function lead_participants() + { + return $this->hasMany(LeadParticipant::class); + } + + public function offers() + { + return $this->hasMany(Offer::class); + } + + public function status_histories() + { + return $this->hasMany(StatusHistory::class); + } } diff --git a/app/Models/LeadParticipant.php b/app/Models/LeadParticipant.php new file mode 100644 index 0000000..0a7f4f9 --- /dev/null +++ b/app/Models/LeadParticipant.php @@ -0,0 +1,68 @@ + 'int', + 'participant_salutation_id' => 'int' + ]; + + protected $dates = [ + 'participant_birthdate' + ]; + + protected $fillable = [ + 'lead_id', + 'participant_name', + 'participant_firstname', + 'participant_birthdate', + 'participant_salutation_id' + ]; + + public function lead() + { + return $this->belongsTo(Lead::class); + } + + public function salutation() + { + return $this->belongsTo(Salutation::class, 'participant_salutation_id'); + } +} diff --git a/app/Models/Offer.php b/app/Models/Offer.php new file mode 100644 index 0000000..54bb655 --- /dev/null +++ b/app/Models/Offer.php @@ -0,0 +1,56 @@ + 'int', + 'total' => 'float', + 'binary_data' => 'boolean' + ]; + + protected $fillable = [ + 'lead_id', + 'total', + 'binary_data' + ]; + + public function lead() + { + return $this->belongsTo(Lead::class); + } +} diff --git a/app/Models/Participant.php b/app/Models/Participant.php new file mode 100644 index 0000000..24c7ce7 --- /dev/null +++ b/app/Models/Participant.php @@ -0,0 +1,72 @@ + 'int', + 'participant_salutation_id' => 'int', + 'participant_child' => 'bool' + ]; + + protected $dates = [ + 'participant_birthdate' + ]; + + protected $fillable = [ + 'booking_id', + 'participant_name', + 'participant_firstname', + 'participant_birthdate', + 'participant_salutation_id', + 'participant_child' + ]; + + public function booking() + { + return $this->belongsTo(Booking::class); + } + + public function salutation() + { + return $this->belongsTo(Salutation::class, 'participant_salutation_id'); + } +} diff --git a/app/Models/Salutation.php b/app/Models/Salutation.php new file mode 100644 index 0000000..a0590d7 --- /dev/null +++ b/app/Models/Salutation.php @@ -0,0 +1,63 @@ +hasMany(Customer::class); + } + + public function leads() + { + return $this->hasMany(Lead::class, 'participant_salutation_id'); + } + + public function lead_participants() + { + return $this->hasMany(LeadParticipant::class, 'participant_salutation_id'); + } + + public function participants() + { + return $this->hasMany(Participant::class, 'participant_salutation_id'); + } +} diff --git a/app/Models/Searchengine.php b/app/Models/Searchengine.php new file mode 100644 index 0000000..32374bf --- /dev/null +++ b/app/Models/Searchengine.php @@ -0,0 +1,42 @@ +hasMany(Lead::class); + } +} diff --git a/app/Models/ServiceProvider.php b/app/Models/ServiceProvider.php new file mode 100644 index 0000000..f39fda1 --- /dev/null +++ b/app/Models/ServiceProvider.php @@ -0,0 +1,50 @@ + 'bool' + ]; + + protected $fillable = [ + 'name', + 'dollar', + 'type' + ]; + + public function service_provider_entries() + { + return $this->hasMany(ServiceProviderEntry::class); + } +} diff --git a/app/Models/ServiceProviderEntry.php b/app/Models/ServiceProviderEntry.php new file mode 100644 index 0000000..8c9c889 --- /dev/null +++ b/app/Models/ServiceProviderEntry.php @@ -0,0 +1,112 @@ + 'int', + 'service_provider_id' => 'int', + 'amount' => 'float', + 'amount_eur' => 'float', + 'factor' => 'float', + 'is_cleared' => 'bool' + ]; + + protected $dates = [ + 'payment_date' + ]; + + protected $fillable = [ + 'booking_id', + 'service_provider_id', + 'amount', + 'amount_eur', + 'factor', + 'payment_date', + 'invoice_number', + 'is_cleared', + 'type' + ]; + + private static $counter = 0; + private static $bookingIds = array(); + + public function booking() + { + return $this->belongsTo(Booking::class); + } + + public function service_provider() + { + return $this->belongsTo(ServiceProvider::class); + } + + public function getCounter(){ + if ($this->booking_id) { + if (!in_array($this->booking_id, self::$bookingIds)) { + self::$bookingIds[] = $this->booking_id; + self::$counter++; + } + return self::$counter; + } + } + + public function getAmountFinalEur(){ + $ret = $this->amount; + if($this->amount_eur && $this->amount_eur > 0){ + $ret = $this->amount_eur; + } + return number_format($ret, 2, ',', '.'); +; + } + + public function getPaymentDateFormat(){ + if(!$this->attributes['payment_date']){ return ""; } + return Carbon::parse($this->attributes['payment_date'])->format(\Util::formatDateDB()); + } +} diff --git a/app/Models/StatusHistory.php b/app/Models/StatusHistory.php new file mode 100644 index 0000000..4e4b47b --- /dev/null +++ b/app/Models/StatusHistory.php @@ -0,0 +1,81 @@ + 'int', + 'lead_id' => 'int', + 'sf_guard_user_id' => 'int' + ]; + + protected $dates = [ + 'date', + 'target_date' + ]; + + protected $fillable = [ + 'status_id', + 'lead_id', + 'sf_guard_user_id', + 'date', + 'remarks', + 'target_date' + ]; + + public function lead() + { + return $this->belongsTo(Lead::class); + } + + public function sf_guard_user() + { + return $this->belongsTo(SfGuardUser::class); + } + + public function status() + { + return $this->belongsTo(Status::class); + } +} diff --git a/app/Models/Sym/TravelCountry.php b/app/Models/Sym/TravelCountry.php index 2c04dc3..c0ced31 100644 --- a/app/Models/Sym/TravelCountry.php +++ b/app/Models/Sym/TravelCountry.php @@ -2,6 +2,8 @@ namespace App\Models\Sym; +use App\Models\Booking; +use App\Models\Lead; use Illuminate\Database\Eloquent\Model; @@ -62,5 +64,18 @@ class TravelCountry extends Model public $timestamps = false; + /*public function leads() + { + return $this->hasMany(Lead::class, 'travelcountry_id', 'id'); + }*/ + + public function bookings() + { + return $this->hasMany(Booking::class, 'travel_country_id', 'id'); + } + + + + } diff --git a/app/Models/Sym/_Booking.php b/app/Models/Sym/_Booking.php new file mode 100644 index 0000000..18ed573 --- /dev/null +++ b/app/Models/Sym/_Booking.php @@ -0,0 +1,210 @@ +hasMany('App\Models\BookingDraftItem', 'booking_id', 'id')->orderBy('pos', 'ASC'); + } + + //on crm + public function travel_agenda() + { + return $this->belongsTo('App\Models\TravelAgenda', 'travelagenda_id', 'id'); + } + + public function travel_country() + { + return $this->belongsTo('App\Models\TravelCountry', 'travel_country_id', 'crm_id'); + } + + public function lead() + { + return $this->belongsTo('App\Models\Lead', 'lead_id', 'id'); + } + + public function sf_guard_user() + { + return $this->belongsTo('App\Models\SfGuardUser', 'sf_guard_user_id', 'id'); + } + + public function arrangements() + { + return $this->hasMany('App\Models\Sym\Arrangement', 'booking_id', 'id')->orderBy('view_position', 'DESC'); + } + + + public function calculate_price_total() + { + $travel_draft_item = false; + $travel_price_adult = 0; + $travel_price_children = 0; + $total_adult = 0; + $total_children = 0; + foreach ($this->booking_draft_items as $booking_draft_item) { + //24 Rundreise + if($booking_draft_item->draft_type_id == 24){ + $travel_draft_item = $booking_draft_item; + continue; + } + $prices = $booking_draft_item->getItemPrice(); + //Grundpreis Reise + if($booking_draft_item->draft_type_id == 30){ + $travel_price_adult += $prices['adult']; + $travel_price_children += $prices['children']; + } + $total_adult += $prices['adult']; + $total_children += $prices['children']; + } + + if($travel_draft_item){ + $travel_draft_item->setPriceAdultRaw($travel_price_adult); + $travel_draft_item->setPriceChildrenRaw($travel_price_children); + $travel_draft_item->save(); + } + + $this->price = $total_adult + $total_children; + $this->save(); + + } + + public function getPriceAttribute() + { + // 2 = decimal places | '.' = decimal seperator | ',' = thousand seperator + return number_format(($this->attributes['price']), 2, ',', '.'); + } + + public function findBeforeDraftItemRelation($reid) + { + $before = false; + foreach($this->booking_draft_items as $booking_draft_items) { + if ($booking_draft_items->id == $reid) { + return $before; + } + $before = $booking_draft_items; + } + return false; + } + + public function findAfterDraftItemRelation($reid) + { + $next = false; + foreach($this->booking_draft_items as $booking_draft_items) { + if($next){ + return $booking_draft_items; + } + if ($booking_draft_items->id == $reid) { + $next = true; + } + } + return false; + } + + public function getStartDateFormat(){ + if(!$this->attributes['start_date']){ return ""; } + return Carbon::parse($this->attributes['start_date'])->format(\Util::formatDateDB()); + } + + public function getEndDateFormat(){ + if(!$this->attributes['end_date']){ return ""; } + return Carbon::parse($this->attributes['end_date'])->format(\Util::formatDateDB()); + } + +} diff --git a/app/Models/TravelBooking.php b/app/Models/TravelBooking.php new file mode 100644 index 0000000..7191ea1 --- /dev/null +++ b/app/Models/TravelBooking.php @@ -0,0 +1,194 @@ + 'int', + 'country_id' => 'int', + 'program_id' => 'int', + 'period_id' => 'int', + 'selected_adults' => 'int', + 'selected_childs' => 'int', + 'participants_total' => 'int', + 'price' => 'float', + 'price_total' => 'float', + 'deposit_total' => 'float', + 'final_payment' => 'float', + 'travel_cancellation' => 'int', + 'accept_legal_rights' => 'bool', + 'selected_travel' => 'array', + 'selected_departure' => 'array', + 'participants' => 'array', + 'drafts' => 'array', + 'service_items' => 'array', + 'arrangements' => 'array', + 'rooms' => 'array', + 'options' => 'array', + 'class_options' => 'array', + 'extra_category' => 'array', + 'insurances' => 'array' + ]; + + protected $dates = [ + 'created', + 'selected_start_date', + 'selected_end_date', + 'final_payment_date' + ]; + + protected $fillable = [ + 'crm_booking_id', + 'salutation_id', + 'first_name', + 'last_name', + 'street', + 'zipcode', + 'city', + 'country_id', + 'fax', + 'phone', + 'mobile', + 'comments', + 'email', + 'created', + 'selected_start_date', + 'selected_end_date', + 'program_name', + 'selected_travel', + 'selected_departure', + 'program_id', + 'period_id', + 'class', + 'selected_adults', + 'selected_childs', + 'participants_total', + 'participants', + 'drafts', + 'service_items', + 'arrangements', + 'rooms', + 'price', + 'price_total', + 'deposit_total', + 'final_payment', + 'final_payment_date', + 'insurance_name', + 'insurances', + 'travel_cancellation', + 'options', + 'class_options', + 'extra_category', + 'accept_legal_rights', + 'ip' + ]; +} diff --git a/app/Models/TravelCategory.php b/app/Models/TravelCategory.php new file mode 100644 index 0000000..637ef73 --- /dev/null +++ b/app/Models/TravelCategory.php @@ -0,0 +1,49 @@ +hasMany(Booking::class); + } + + public function leads() + { + return $this->hasMany(Lead::class, 'travelcategory_id'); + } +} diff --git a/app/Models/TravelCompany.php b/app/Models/TravelCompany.php new file mode 100644 index 0000000..dfd1c00 --- /dev/null +++ b/app/Models/TravelCompany.php @@ -0,0 +1,64 @@ + 'float', + 'is_allowed_edit_commission' => 'bool', + 'is_inhouse' => 'bool' + ]; + + protected $fillable = [ + 'name', + 'percentage', + 'is_allowed_edit_commission', + 'is_inhouse' + ]; + + public function bookings() + { + return $this->hasMany(Booking::class); + } + + public function booking_service_items() + { + return $this->hasMany(BookingServiceItem::class); + } +} diff --git a/app/Models/TravelUserBookingFewo.php b/app/Models/TravelUserBookingFewo.php index db7e971..60fcdc7 100644 --- a/app/Models/TravelUserBookingFewo.php +++ b/app/Models/TravelUserBookingFewo.php @@ -211,9 +211,9 @@ class TravelUserBookingFewo extends Model public function getCheckedBadgeCalendar(){ $back = ""; - $back .= $this->is_calendar_fewo_direct ? ' ' : ' '; - $back .= $this->is_calendar_hrs ? ' ' : ' '; - $back .= $this->is_calendar_stern_tours ? ' ' : ' '; + $back .= $this->is_calendar_fewo_direct ? ' ' : ' '; + $back .= $this->is_calendar_hrs ? ' ' : ' '; + $back .= $this->is_calendar_stern_tours ? ' ' : ' '; return $back; } diff --git a/app/Models/Website.php b/app/Models/Website.php new file mode 100644 index 0000000..68c4936 --- /dev/null +++ b/app/Models/Website.php @@ -0,0 +1,42 @@ +hasMany(Lead::class); + } +} diff --git a/app/Repositories/DraftRepository.php b/app/Repositories/DraftRepository.php new file mode 100644 index 0000000..87de70c --- /dev/null +++ b/app/Repositories/DraftRepository.php @@ -0,0 +1,519 @@ +model = $model; + } + + public function update($data) + { + return $this->model; + } + + + public function create_drafts_from_booking($booking_id, $data) { + + $this->data = $data; + + $weekday = date('w', strtotime($data['startDateStr'])); + $travel_program = TravelProgram::find($data['travel_program_id']); + $draft = $this->getDraftByTravelProgramData($travel_program, $data, $weekday); + + $start_date = Carbon::parse($data['startDateStr']); + $end_date = Carbon::parse($data['endDateStr']); + + + + //------------------------------------------------------------------------------ + //prepare rooms + //request('rooms'); // //["rooms"]=> array(1) { [0]=> object(stdClass)#7284 (5) { ["name"]=> string(12) "Einzelzimmer" ["price_adult"]=> float(1682.16) ["adult"]=> int(1) ["children"]=> int(0) ["price_children"]=> int(0) } + $price_info_rooms = []; + $room_names = []; + $room_adult = 0; + $room_children = 0; + $room_price_adult = 0; + $room_price_children = 0; + + $data['rooms'] = array_reverse($data['rooms']); + + foreach ($data['rooms'] as $room){ + + $room_adult += $room['adult']; + $room_children += $room['children']; + $room_price_adult += ($room['price_adult_full'] * $room['adult']); + $room_price_children += ($room['price_children_full'] * $room['children']); + + if(isset($room_names[$room['name']])){ + $room_names[$room['name']] = $room_names[$room['name']]+1; + }else{ + $room_names[$room['name']] = 1; + } + + $service = trans('_vorlagen.grundpreis_reise'); + $this->room_name = $room['name']; + $service = $this->replaceService($service); + + $price_info_rooms[] = [ + 'booking_id' => $booking_id, + 'travel_program_id' => $data['travel_program_id'], + 'fewo_lodging_id' => null, + 'travel_class_id' => null, + 'draft_item_id' => null, + 'draft_type_id' => 30, + 'request_date' => $data['request_date'], + 'days_start' => null, + 'days_duration' => null, + 'start_date' => $data['startDateStr'], + 'end_date' => $data['endDateStr'], + 'service' => $service, + 'price_adult' => $room['price_adult_full'], + 'adult' => $room['adult'], + 'price_children' => $room['price_children_full'], + 'children' => $room['children'], + 'pos' => 0, + 'in_pdf' => true, + 'comfort' => $data['comfort'] + ]; + } + + + + + $this->room_str = ""; + foreach ($room_names as $name=>$count){ + $this->room_str .= $count.' x '.$name.', '; + } + $this->room_str = rtrim($this->room_str, ', '); + + + //before & after days + + $price_info_rooms_before = []; + $price_info_rooms_after = []; + + if(isset($data['booking_before']) && is_array($data['booking_before'])){ + foreach ($data['booking_before'] as $booking_before){ + $start_date_before = clone $start_date; + if(isset($booking_before['days']) && $booking_before['days'] > 0){ + $start_date_before->modify('-'.$booking_before['days'].' day'); + } + + $price_info_rooms_before[] = [ + 'booking_id' => $booking_id, + 'travel_program_id' => $data['travel_program_id'], + 'fewo_lodging_id' => null, + 'travel_class_id' => null, + 'draft_item_id' => null, + 'draft_type_id' => 36, + 'request_date' => $data['request_date'], + 'days_start' => null, + 'days_duration' => $booking_before['days'], + 'start_date' => $start_date_before->format("Y-m-d"), + 'end_date' => $data['startDateStr'], + 'service' => $booking_before['name'], + 'price_adult' => $booking_before['price'], + 'adult' => $booking_before['adults'], + 'price_children' => $booking_before['price_children'], + 'children' => $booking_before['children'], + 'pos' => 0, + 'in_pdf' => true, + 'comfort' => $data['comfort'] + ]; + } + } + + if(isset($data['booking_after']) && is_array($data['booking_after'])){ + foreach ($data['booking_after'] as $booking_after){ + $end_date_after = clone $end_date; + if(isset($booking_after['days']) && $booking_after['days'] > 0){ + $end_date_after->modify('+'.$booking_after['days'].' day'); + } + + $price_info_rooms_after[] = [ + 'booking_id' => $booking_id, + 'travel_program_id' => $data['travel_program_id'], + 'fewo_lodging_id' => null, + 'travel_class_id' => null, + 'draft_item_id' => null, + 'draft_type_id' => 37, + 'request_date' => $data['request_date'], + 'days_start' => null, + 'days_duration' => $booking_after['days'], + 'start_date' => $data['endDateStr'], + 'end_date' => $end_date_after->format("Y-m-d"), + 'service' => $booking_after['name'], + 'price_adult' => $booking_after['price'], + 'adult' => $booking_after['adults'], + 'price_children' => $booking_after['price_children'], + 'children' => $booking_after['children'], + 'pos' => 0, + 'in_pdf' => true, + 'comfort' => $data['comfort'] + ]; + } + } + + + //------------------------------------------------------------------------------ + //prepare extra_charge + $price_info_extra_charge = []; + if($data['departure_extra_charge'] > 0){ + + $service = trans('_vorlagen.aufpreis_flug'); + $service = $this->replaceService($service); + + $price_info_extra_charge[] = [ + 'booking_id' => $booking_id, + 'travel_program_id' => $data['travel_program_id'], + 'fewo_lodging_id' => null, + 'travel_class_id' => null, + 'draft_item_id' => null, + 'draft_type_id' => 33, + 'request_date' => $data['request_date'], + 'days_start' => null, + 'days_duration' => null, + 'start_date' => null, + 'end_date' => null, + 'service' => $service, + 'price_adult' => $data['departure_extra_charge'] , + 'adult' => $data['traveler'] , + 'price_children' => 0, + 'children' => 0, + 'pos' => 0, + 'in_pdf' => true, + 'comfort' => $data['comfort'] + ]; + } + + //------------------------------------------------------------------------------ + //prepare $class_options + $price_info_class_options = []; + foreach ($data['class_options'] as $class_option){ + + $service = trans('_vorlagen.aufpreis_kategorie'); + $this->className = $class_option['name']; + $service = $this->replaceService($service); + + $price_info_class_options[] = [ + 'booking_id' => $booking_id, + 'travel_program_id' => $data['travel_program_id'], + 'fewo_lodging_id' => null, + 'travel_class_id' => null, + 'draft_item_id' => null, + 'draft_type_id' => 32, + 'request_date' => $data['request_date'], + 'days_start' => null, + 'days_duration' => null, + 'start_date' => null, + 'end_date' => null, + 'service' => $service, + 'price_adult' => $class_option['price'], + 'adult' => $class_option['count'], + 'price_children' => 0, + 'children' => 0, + 'pos' => 0, + 'in_pdf' => true, + 'comfort' => $data['comfort'] + ]; + } + + //------------------------------------------------------------------------------ + //prepare $travel_options + $price_info_travel_options = []; + foreach ($data['travel_options'] as $travel_option){ + + $service = trans('_vorlagen.aufpreis_option'); + $this->option = $travel_option['name']; + $service = $this->replaceService($service); + + /* + * if($travel_option['children'] < 1){ + $travel_option['price_children'] = 0; + } + */ + $price_info_travel_options[] = [ + 'booking_id' => $booking_id, + 'travel_program_id' => $data['travel_program_id'], + 'fewo_lodging_id' => null, + 'travel_class_id' => null, + 'draft_item_id' => null, + 'draft_type_id' => 41, + 'request_date' => $data['request_date'], + 'days_start' => null, + 'days_duration' => null, + 'start_date' => null, + 'end_date' => null, + 'service' => $service, + 'price_adult' => $travel_option['price_adult'], + 'adult' => $travel_option['adult'], + 'price_children' => $travel_option['price_children'], + 'children' => $travel_option['children'], + 'pos' => 0, + 'in_pdf' => true, + 'comfort' => $data['comfort'] + ]; + } + + $price_info_travel_discounts = []; + + foreach ($data['discount'] as $travel_discount){ + + $service = trans('_vorlagen.aufpreis_option'); + $this->option = ""; + $service = $this->replaceService($service); + + if($travel_discount['price'] > 0){ + $travel_discount['price'] = $travel_discount['price']*-1; + } + $price_info_travel_options[] = [ + 'booking_id' => $booking_id, + 'travel_program_id' => $data['travel_program_id'], + 'fewo_lodging_id' => null, + 'travel_class_id' => null, + 'draft_item_id' => null, + 'draft_type_id' => 42, + 'request_date' => $data['request_date'], + 'days_start' => null, + 'days_duration' => null, + 'start_date' => null, + 'end_date' => null, + 'service' => $service, + 'price_adult' => $travel_discount['price'], + 'adult' => $travel_discount['count'], + 'price_children' => 0, + 'children' => 0, + 'pos' => 0, + 'in_pdf' => true, + 'comfort' => $data['comfort'] + ]; + } + + $info_texts = []; + $last_post = 0; + foreach ($draft->draft_items as $draft_item){ + + $service = $draft_item->service; + $price_adult = 0; + $adult = 0; + $price_children = 0; + $children = 0; + + switch ($draft_item->draft_type->id){ + case 24: //rundreise + $price_adult = $room_price_adult; + $adult = $room_adult; + $price_children = $room_price_children; + $children = $room_children; + break; + case 4: //flug + // "Hinflug: Rückflug: Flugzeiten ?" + break; + } + + $start_date_temp = null; + if($draft_item->days_start > 0){ + $start_date_temp = clone $start_date; + $start_date_temp->addDay($draft_item->days_start-1); + } + + $end_date_temp = null; + if($draft_item->days_duration > 0){ + $end_date_temp = clone $start_date; + $end_date_temp->addDay($draft_item->days_duration-1); + } + + $service = $this->replaceService($service); + + if($draft_item->draft_type->id == 27){ + //text -at last + $info_texts[] = [ + 'booking_id' => $booking_id, + 'travel_program_id' => $data['travel_program_id'], + 'fewo_lodging_id' => null, + 'travel_class_id' => null, + 'draft_item_id' => $draft_item->id, + 'draft_type_id' => $draft_item->draft_type->id, + 'request_date' => $data['request_date'], + 'days_start' => $draft_item->days_start, + 'days_duration' => $draft_item->days_duration, + 'start_date' => $start_date_temp ? $start_date_temp->format("Y-m-d") : null, + 'end_date' => $end_date_temp ? $end_date_temp->format("Y-m-d") : null, + 'service' => $service, + 'price_adult' => $price_adult, + 'adult' => $adult, + 'price_children' => $price_children, + 'children' => $children, + 'pos' => $draft_item->pos, + 'in_pdf' => $draft_item->in_pdf, + 'comfort' => $data['comfort'] + ]; + + + }else{ + //create new from draft items + BookingDraftItem::create([ + 'booking_id' => $booking_id, + 'travel_program_id' => $data['travel_program_id'], + 'fewo_lodging_id' => null, + 'travel_class_id' => null, + 'draft_item_id' => $draft_item->id, + 'draft_type_id' => $draft_item->draft_type->id, + 'request_date' => $data['request_date'], + 'days_start' => $draft_item->days_start, + 'days_duration' => $draft_item->days_duration, + 'start_date' => $start_date_temp ? $start_date_temp->format("Y-m-d") : null, + 'end_date' => $end_date_temp ? $end_date_temp->format("Y-m-d") : null, + 'service' => $service, + 'price_adult' => $price_adult, + 'adult' => $adult, + 'price_children' => $price_children, + 'children' => $children, + 'pos' => $draft_item->pos, + 'in_pdf' => $draft_item->in_pdf, + 'comfort' => $data['comfort'] + ]); + } + + + + $last_post = $draft_item->pos; + + } + + //set room prices + if(count($price_info_rooms)){ + foreach ($price_info_rooms as $price_info_room){ + $last_post ++; + $price_info_room['pos'] = $last_post; + BookingDraftItem::create($price_info_room); + } + } + + //set room prices before + if(count($price_info_rooms_before)){ + foreach ($price_info_rooms_before as $price_info_room){ + $last_post ++; + $price_info_room['pos'] = $last_post; + BookingDraftItem::create($price_info_room); + } + } + + //set room prices after + if(count($price_info_rooms_after)){ + foreach ($price_info_rooms_after as $price_info_room){ + $last_post ++; + $price_info_room['pos'] = $last_post; + BookingDraftItem::create($price_info_room); + } + } + + + + //set extra charge price + if(count($price_info_extra_charge)){ + foreach ($price_info_extra_charge as $price_info_extra){ + $last_post ++; + $price_info_extra['pos'] = $last_post; + BookingDraftItem::create($price_info_extra); + } + } + //set class options prices + if(count($price_info_class_options)){ + foreach ($price_info_class_options as $price_info_class_option){ + $last_post ++; + $price_info_class_option['pos'] = $last_post; + BookingDraftItem::create($price_info_class_option); + } + } + + //set travel options prices + if(count($price_info_travel_options)){ + foreach ($price_info_travel_options as $price_info_travel_option){ + $last_post ++; + $price_info_travel_option['pos'] = $last_post; + BookingDraftItem::create($price_info_travel_option); + } + } + + //set travel discount prices + if(count($price_info_travel_discounts)){ + foreach ($price_info_travel_discounts as $price_info_travel_discount){ + $last_post ++; + $price_info_travel_option['pos'] = $last_post; + BookingDraftItem::create($price_info_travel_option); + } + } + + //set travel options prices + if(count($info_texts)){ + foreach ($info_texts as $info_text){ + $last_post ++; + $info_text['pos'] = $last_post; + BookingDraftItem::create($info_text); + } + } + + return ""; + + + } + + private function replaceService($service){ + + $service = str_replace('#Name#', $this->data['title'], $service); + $service = str_replace('#Nummer#', $this->data['number'], $service); + $service = str_replace('#Zimmer#', $this->room_str, $service); + $service = str_replace('#Raumname#', $this->room_name, $service); + $service = str_replace('#Kategorie#', $this->className, $service); + $service = str_replace('#Option#', $this->option, $service); + $service = str_replace('#Flughafen#', $this->data['departure'], $service); + + return $service; + + } + + private function getDraftByTravelProgramData($travel_program, $data, $weekday){ + if ($travel_program && count($travel_program->travel_program_drafts)) { + + foreach ($travel_program->travel_program_drafts as $travel_program_draft) { + //this need an realation to travel class by booking and price + if(in_array($weekday, $travel_program_draft->weekdays)){ + if($data['comfort'] == false && strpos(strtolower($travel_program_draft->travel_class->name), 'standard') !== false){ + return $travel_program_draft->draft; + } + if($data['comfort'] == true && strpos(strtolower($travel_program_draft->travel_class->name), 'komfort') !== false){ + return $travel_program_draft->draft; + } + } + } + //found non get first + foreach ($travel_program->travel_program_drafts as $travel_program_draft) { + if($travel_program_draft->draft){ + return $travel_program_draft->draft; + } + + } + + + } + return null; + } + + +} \ No newline at end of file diff --git a/app/Services/HTMLHelper.php b/app/Services/HTMLHelper.php index 805b8ab..7c1a363 100644 --- a/app/Services/HTMLHelper.php +++ b/app/Services/HTMLHelper.php @@ -61,6 +61,7 @@ class HTMLHelper 0 => 'Kunde', 1 => 'Admin', 2 => 'SuperAdmin', + 3 => 'SysAdmin', ]; @@ -103,6 +104,9 @@ class HTMLHelper case 2: return 'badge-primary'; break; + case 3: + return 'badge-success'; + break; } } diff --git a/app/Services/Util.php b/app/Services/Util.php index 7142b43..db1c6ea 100644 --- a/app/Services/Util.php +++ b/app/Services/Util.php @@ -127,4 +127,17 @@ class Util $html = $dom->saveHTML(); return $html; } + + public static function convertArrayWindowsCharset($values){ + foreach ($values as $key=>$string){ + $values[$key] = self::convertStringWindowsCharset($string); + } + return $values; + } + + public static function convertStringWindowsCharset($value) { + + $charset = mb_detect_encoding($value, "UTF-8, ISO-8859-1, ISO-8859-15", true); + return mb_convert_encoding($value, "Windows-1252", $charset); + } } \ No newline at end of file diff --git a/app/User.php b/app/User.php index f539078..e43f270 100755 --- a/app/User.php +++ b/app/User.php @@ -160,6 +160,17 @@ class User extends Authenticatable return false; } + /** + * @return bool + */ + public function isSySAdmin() + { + if($this->admin >= 3){ + return true; + } + return false; + } + private function setPermissionsDefault(){ $groups = config('permissions.groups'); diff --git a/app/helpers.php b/app/helpers.php index 427e040..7aaa3c6 100644 --- a/app/helpers.php +++ b/app/helpers.php @@ -51,7 +51,7 @@ if (! function_exists('get_active_badge')) { if($tooltip){ $tooltip = 'data-toggle="tooltip" data-placement="top" data-original-title="'.$tooltip.'"'; } - return $active ? '' : ''; + return $active ? '' : ''; } } diff --git a/composer.json b/composer.json index 06c5ffc..a7149db 100755 --- a/composer.json +++ b/composer.json @@ -15,22 +15,22 @@ ], "require": { "php": "^7.1.3", - "laravel/framework": "5.8.*", - "barryvdh/laravel-dompdf": "*", + "barryvdh/laravel-dompdf": "^0.8.5", "cviebrock/eloquent-sluggable": "*", "doctrine/dbal": "*", "fideloper/proxy": "*", "guzzlehttp/guzzle": "*", "intervention/image": "*", + "iqcontent/laravel-filemanager": "*", "jenssegers/date": "*", "laracasts/flash": "*", + "laravel/framework": "5.8.*", "laravel/passport": "*", "laravel/tinker": "*", "laravelcollective/html": "*", - "maatwebsite/excel": "*", + "maatwebsite/excel": "^3.1", "reliese/laravel": "*", - "yajra/laravel-datatables-oracle": "*", - "iqcontent/laravel-filemanager": "*" + "yajra/laravel-datatables-oracle": "*" }, "require-dev": { "barryvdh/laravel-debugbar": "^3.2", diff --git a/composer.lock b/composer.lock index 457cc37..834fcf8 100755 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "435ac9e96e61d608421c5720e6a64521", + "content-hash": "db27fc9863d48a36496764d8d350229a", "packages": [ { "name": "barryvdh/laravel-dompdf", @@ -129,20 +129,21 @@ }, { "name": "cviebrock/eloquent-sluggable", - "version": "4.8.0", + "version": "4.8.1", "source": { "type": "git", "url": "https://github.com/cviebrock/eloquent-sluggable.git", - "reference": "4a5bf905b55e7eb0a30ef5933f647387dc8f365a" + "reference": "8820cf93a911cd6a1c440a8f5889caedac5cf697" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/cviebrock/eloquent-sluggable/zipball/4a5bf905b55e7eb0a30ef5933f647387dc8f365a", - "reference": "4a5bf905b55e7eb0a30ef5933f647387dc8f365a", + "url": "https://api.github.com/repos/cviebrock/eloquent-sluggable/zipball/8820cf93a911cd6a1c440a8f5889caedac5cf697", + "reference": "8820cf93a911cd6a1c440a8f5889caedac5cf697", "shasum": "" }, "require": { "cocur/slugify": "^3.1", + "ext-mbstring": "*", "illuminate/config": "~5.8.0", "illuminate/database": "~5.8.0", "illuminate/support": "~5.8.0", @@ -188,7 +189,7 @@ "slug", "sluggable" ], - "time": "2019-03-01T05:04:21+00:00" + "time": "2020-02-09T22:52:29+00:00" }, { "name": "defuse/php-encryption", @@ -370,16 +371,16 @@ }, { "name": "doctrine/dbal", - "version": "v2.10.0", + "version": "v2.10.1", "source": { "type": "git", "url": "https://github.com/doctrine/dbal.git", - "reference": "0c9a646775ef549eb0a213a4f9bd4381d9b4d934" + "reference": "c2b8e6e82732a64ecde1cddf9e1e06cb8556e3d8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/0c9a646775ef549eb0a213a4f9bd4381d9b4d934", - "reference": "0c9a646775ef549eb0a213a4f9bd4381d9b4d934", + "url": "https://api.github.com/repos/doctrine/dbal/zipball/c2b8e6e82732a64ecde1cddf9e1e06cb8556e3d8", + "reference": "c2b8e6e82732a64ecde1cddf9e1e06cb8556e3d8", "shasum": "" }, "require": { @@ -458,7 +459,7 @@ "sqlserver", "sqlsrv" ], - "time": "2019-11-03T16:50:43+00:00" + "time": "2020-01-04T12:56:21+00:00" }, { "name": "doctrine/event-manager", @@ -667,28 +668,28 @@ }, { "name": "dompdf/dompdf", - "version": "v0.8.3", + "version": "v0.8.4", "source": { "type": "git", "url": "https://github.com/dompdf/dompdf.git", - "reference": "75f13c700009be21a1965dc2c5b68a8708c22ba2" + "reference": "8f49b3b01693f51037dd50da81090beba1b5c005" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/dompdf/dompdf/zipball/75f13c700009be21a1965dc2c5b68a8708c22ba2", - "reference": "75f13c700009be21a1965dc2c5b68a8708c22ba2", + "url": "https://api.github.com/repos/dompdf/dompdf/zipball/8f49b3b01693f51037dd50da81090beba1b5c005", + "reference": "8f49b3b01693f51037dd50da81090beba1b5c005", "shasum": "" }, "require": { "ext-dom": "*", "ext-mbstring": "*", - "phenx/php-font-lib": "0.5.*", - "phenx/php-svg-lib": "0.3.*", - "php": ">=5.4.0" + "phenx/php-font-lib": "^0.5.1", + "phenx/php-svg-lib": "^0.3.3", + "php": "^7.1" }, "require-dev": { - "phpunit/phpunit": "^4.8|^5.5|^6.5", - "squizlabs/php_codesniffer": "2.*" + "phpunit/phpunit": "^7.5", + "squizlabs/php_codesniffer": "^3.5" }, "suggest": { "ext-gd": "Needed to process images", @@ -729,7 +730,7 @@ ], "description": "DOMPDF is a CSS 2.1 compliant HTML to PDF converter", "homepage": "https://github.com/dompdf/dompdf", - "time": "2018-12-14T02:40:31+00:00" + "time": "2020-01-20T17:00:46+00:00" }, { "name": "dragonmantank/cron-expression", @@ -787,27 +788,27 @@ }, { "name": "egulias/email-validator", - "version": "2.1.12", + "version": "2.1.15", "source": { "type": "git", "url": "https://github.com/egulias/EmailValidator.git", - "reference": "a6255605af39f2db7f5cb62e672bd8a7bad8d208" + "reference": "e834eea5306d85d67de5a05db5882911d5b29357" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/a6255605af39f2db7f5cb62e672bd8a7bad8d208", - "reference": "a6255605af39f2db7f5cb62e672bd8a7bad8d208", + "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/e834eea5306d85d67de5a05db5882911d5b29357", + "reference": "e834eea5306d85d67de5a05db5882911d5b29357", "shasum": "" }, "require": { "doctrine/lexer": "^1.0.1", - "php": ">= 5.5" + "php": ">=5.5", + "symfony/polyfill-intl-idn": "^1.10" }, "require-dev": { - "dominicsayers/isemail": "dev-master", - "phpunit/phpunit": "^4.8.35||^5.7||^6.0", - "satooshi/php-coveralls": "^1.0.1", - "symfony/phpunit-bridge": "^4.4@dev" + "dominicsayers/isemail": "^3.0.7", + "phpunit/phpunit": "^4.8.36|^7.5.15", + "satooshi/php-coveralls": "^1.0.1" }, "suggest": { "ext-intl": "PHP Internationalization Libraries are required to use the SpoofChecking validation" @@ -841,20 +842,20 @@ "validation", "validator" ], - "time": "2019-12-20T12:49:39+00:00" + "time": "2020-01-20T21:40:59+00:00" }, { "name": "erusev/parsedown", - "version": "1.7.3", + "version": "1.7.4", "source": { "type": "git", "url": "https://github.com/erusev/parsedown.git", - "reference": "6d893938171a817f4e9bc9e86f2da1e370b7bcd7" + "reference": "cb17b6477dfff935958ba01325f2e8a2bfa6dab3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/erusev/parsedown/zipball/6d893938171a817f4e9bc9e86f2da1e370b7bcd7", - "reference": "6d893938171a817f4e9bc9e86f2da1e370b7bcd7", + "url": "https://api.github.com/repos/erusev/parsedown/zipball/cb17b6477dfff935958ba01325f2e8a2bfa6dab3", + "reference": "cb17b6477dfff935958ba01325f2e8a2bfa6dab3", "shasum": "" }, "require": { @@ -887,7 +888,7 @@ "markdown", "parser" ], - "time": "2019-03-17T18:48:37+00:00" + "time": "2019-12-30T22:54:17+00:00" }, { "name": "fideloper/proxy", @@ -1984,16 +1985,16 @@ }, { "name": "league/flysystem", - "version": "1.0.61", + "version": "1.0.64", "source": { "type": "git", "url": "https://github.com/thephpleague/flysystem.git", - "reference": "4fb13c01784a6c9f165a351e996871488ca2d8c9" + "reference": "d13c43dbd4b791f815215959105a008515d1a2e0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/4fb13c01784a6c9f165a351e996871488ca2d8c9", - "reference": "4fb13c01784a6c9f165a351e996871488ca2d8c9", + "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/d13c43dbd4b791f815215959105a008515d1a2e0", + "reference": "d13c43dbd4b791f815215959105a008515d1a2e0", "shasum": "" }, "require": { @@ -2005,7 +2006,7 @@ }, "require-dev": { "phpspec/phpspec": "^3.4", - "phpunit/phpunit": "^5.7.10" + "phpunit/phpunit": "^5.7.26" }, "suggest": { "ext-fileinfo": "Required for MimeType", @@ -2064,7 +2065,7 @@ "sftp", "storage" ], - "time": "2019-12-08T21:46:50+00:00" + "time": "2020-02-05T18:14:17+00:00" }, { "name": "league/oauth2-server", @@ -2454,16 +2455,16 @@ }, { "name": "nesbot/carbon", - "version": "2.28.0", + "version": "2.29.1", "source": { "type": "git", "url": "https://github.com/briannesbitt/Carbon.git", - "reference": "e2bcbcd43e67ee6101d321d5de916251d2870ca8" + "reference": "e509be5bf2d703390e69e14496d9a1168452b0a2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/e2bcbcd43e67ee6101d321d5de916251d2870ca8", - "reference": "e2bcbcd43e67ee6101d321d5de916251d2870ca8", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/e509be5bf2d703390e69e14496d9a1168452b0a2", + "reference": "e509be5bf2d703390e69e14496d9a1168452b0a2", "shasum": "" }, "require": { @@ -2474,7 +2475,7 @@ "require-dev": { "friendsofphp/php-cs-fixer": "^2.14 || ^3.0", "kylekatarnls/multi-tester": "^1.1", - "phpmd/phpmd": "dev-php-7.1-compatibility", + "phpmd/phpmd": "^2.8", "phpstan/phpstan": "^0.11", "phpunit/phpunit": "^7.5 || ^8.0", "squizlabs/php_codesniffer": "^3.4" @@ -2520,7 +2521,7 @@ "datetime", "time" ], - "time": "2019-12-16T16:30:25+00:00" + "time": "2020-01-21T09:36:43+00:00" }, { "name": "nikic/php-parser", @@ -3612,16 +3613,16 @@ }, { "name": "symfony/console", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "82437719dab1e6bdd28726af14cb345c2ec816d0" + "reference": "f512001679f37e6a042b51897ed24a2f05eba656" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/82437719dab1e6bdd28726af14cb345c2ec816d0", - "reference": "82437719dab1e6bdd28726af14cb345c2ec816d0", + "url": "https://api.github.com/repos/symfony/console/zipball/f512001679f37e6a042b51897ed24a2f05eba656", + "reference": "f512001679f37e6a042b51897ed24a2f05eba656", "shasum": "" }, "require": { @@ -3684,20 +3685,20 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "time": "2019-12-17T10:32:23+00:00" + "time": "2020-01-25T12:44:29+00:00" }, { "name": "symfony/css-selector", - "version": "v5.0.2", + "version": "v5.0.4", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "19d29e7098b7b2c3313cb03902ca30f100dcb837" + "reference": "ff60c90cb7950b592ebc84ad1289d0345bf24f9f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/19d29e7098b7b2c3313cb03902ca30f100dcb837", - "reference": "19d29e7098b7b2c3313cb03902ca30f100dcb837", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/ff60c90cb7950b592ebc84ad1289d0345bf24f9f", + "reference": "ff60c90cb7950b592ebc84ad1289d0345bf24f9f", "shasum": "" }, "require": { @@ -3737,20 +3738,20 @@ ], "description": "Symfony CssSelector Component", "homepage": "https://symfony.com", - "time": "2019-11-18T17:27:11+00:00" + "time": "2020-01-04T14:08:26+00:00" }, { "name": "symfony/debug", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/debug.git", - "reference": "5c4c1db977dc70bb3250e1308d3e8c6341aa38f5" + "reference": "20236471058bbaa9907382500fc14005c84601f0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/5c4c1db977dc70bb3250e1308d3e8c6341aa38f5", - "reference": "5c4c1db977dc70bb3250e1308d3e8c6341aa38f5", + "url": "https://api.github.com/repos/symfony/debug/zipball/20236471058bbaa9907382500fc14005c84601f0", + "reference": "20236471058bbaa9907382500fc14005c84601f0", "shasum": "" }, "require": { @@ -3793,20 +3794,20 @@ ], "description": "Symfony Debug Component", "homepage": "https://symfony.com", - "time": "2019-12-16T14:46:54+00:00" + "time": "2020-01-25T12:44:29+00:00" }, { "name": "symfony/error-handler", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "6d7d7712a6ff5215ec26215672293b154f1db8c1" + "reference": "d2721499ffcaf246a743e01cdf6696d3d5dd74c1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/6d7d7712a6ff5215ec26215672293b154f1db8c1", - "reference": "6d7d7712a6ff5215ec26215672293b154f1db8c1", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/d2721499ffcaf246a743e01cdf6696d3d5dd74c1", + "reference": "d2721499ffcaf246a743e01cdf6696d3d5dd74c1", "shasum": "" }, "require": { @@ -3849,20 +3850,20 @@ ], "description": "Symfony ErrorHandler Component", "homepage": "https://symfony.com", - "time": "2019-12-16T14:46:54+00:00" + "time": "2020-01-27T09:48:47+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "b3c3068a72623287550fe20b84a2b01dcba2686f" + "reference": "9e3de195e5bc301704dd6915df55892f6dfc208b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/b3c3068a72623287550fe20b84a2b01dcba2686f", - "reference": "b3c3068a72623287550fe20b84a2b01dcba2686f", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/9e3de195e5bc301704dd6915df55892f6dfc208b", + "reference": "9e3de195e5bc301704dd6915df55892f6dfc208b", "shasum": "" }, "require": { @@ -3919,7 +3920,7 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", - "time": "2019-11-28T13:33:56+00:00" + "time": "2020-01-10T21:54:01+00:00" }, { "name": "symfony/event-dispatcher-contracts", @@ -3981,16 +3982,16 @@ }, { "name": "symfony/finder", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "ce8743441da64c41e2a667b8eb66070444ed911e" + "reference": "3a50be43515590faf812fbd7708200aabc327ec3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/ce8743441da64c41e2a667b8eb66070444ed911e", - "reference": "ce8743441da64c41e2a667b8eb66070444ed911e", + "url": "https://api.github.com/repos/symfony/finder/zipball/3a50be43515590faf812fbd7708200aabc327ec3", + "reference": "3a50be43515590faf812fbd7708200aabc327ec3", "shasum": "" }, "require": { @@ -4026,20 +4027,20 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", - "time": "2019-11-17T21:56:56+00:00" + "time": "2020-01-04T13:00:46+00:00" }, { "name": "symfony/http-foundation", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "fcae1cff5b57b2a9c3aabefeb1527678705ddb62" + "reference": "491a20dfa87e0b3990170593bc2de0bb34d828a5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/fcae1cff5b57b2a9c3aabefeb1527678705ddb62", - "reference": "fcae1cff5b57b2a9c3aabefeb1527678705ddb62", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/491a20dfa87e0b3990170593bc2de0bb34d828a5", + "reference": "491a20dfa87e0b3990170593bc2de0bb34d828a5", "shasum": "" }, "require": { @@ -4081,20 +4082,20 @@ ], "description": "Symfony HttpFoundation Component", "homepage": "https://symfony.com", - "time": "2019-12-19T15:57:49+00:00" + "time": "2020-01-31T09:11:17+00:00" }, { "name": "symfony/http-kernel", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "fe310d2e95cd4c356836c8ecb0895a46d97fede2" + "reference": "62116a9c8fb15faabb158ad9cb785c353c2572e5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/fe310d2e95cd4c356836c8ecb0895a46d97fede2", - "reference": "fe310d2e95cd4c356836c8ecb0895a46d97fede2", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/62116a9c8fb15faabb158ad9cb785c353c2572e5", + "reference": "62116a9c8fb15faabb158ad9cb785c353c2572e5", "shasum": "" }, "require": { @@ -4171,20 +4172,20 @@ ], "description": "Symfony HttpKernel Component", "homepage": "https://symfony.com", - "time": "2019-12-19T16:23:40+00:00" + "time": "2020-01-31T12:45:06+00:00" }, { "name": "symfony/mime", - "version": "v5.0.2", + "version": "v5.0.4", "source": { "type": "git", "url": "https://github.com/symfony/mime.git", - "reference": "0e6a4ced216e49d457eddcefb61132173a876d79" + "reference": "2a3c7fee1f1a0961fa9cf360d5da553d05095e59" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mime/zipball/0e6a4ced216e49d457eddcefb61132173a876d79", - "reference": "0e6a4ced216e49d457eddcefb61132173a876d79", + "url": "https://api.github.com/repos/symfony/mime/zipball/2a3c7fee1f1a0961fa9cf360d5da553d05095e59", + "reference": "2a3c7fee1f1a0961fa9cf360d5da553d05095e59", "shasum": "" }, "require": { @@ -4233,7 +4234,7 @@ "mime", "mime-type" ], - "time": "2019-11-30T14:12:50+00:00" + "time": "2020-01-04T14:08:26+00:00" }, { "name": "symfony/polyfill-ctype", @@ -4588,16 +4589,16 @@ }, { "name": "symfony/process", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "b84501ad50adb72a94fb460a5b5c91f693e99c9b" + "reference": "f5697ab4cb14a5deed7473819e63141bf5352c36" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/b84501ad50adb72a94fb460a5b5c91f693e99c9b", - "reference": "b84501ad50adb72a94fb460a5b5c91f693e99c9b", + "url": "https://api.github.com/repos/symfony/process/zipball/f5697ab4cb14a5deed7473819e63141bf5352c36", + "reference": "f5697ab4cb14a5deed7473819e63141bf5352c36", "shasum": "" }, "require": { @@ -4633,7 +4634,7 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "time": "2019-12-06T10:06:46+00:00" + "time": "2020-01-09T09:50:08+00:00" }, { "name": "symfony/psr-http-message-bridge", @@ -4702,16 +4703,16 @@ }, { "name": "symfony/routing", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "628bcafae1b2043969378dcfbf9c196539a38722" + "reference": "7bf4e38573728e317b926ca4482ad30470d0e86a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/628bcafae1b2043969378dcfbf9c196539a38722", - "reference": "628bcafae1b2043969378dcfbf9c196539a38722", + "url": "https://api.github.com/repos/symfony/routing/zipball/7bf4e38573728e317b926ca4482ad30470d0e86a", + "reference": "7bf4e38573728e317b926ca4482ad30470d0e86a", "shasum": "" }, "require": { @@ -4774,7 +4775,7 @@ "uri", "url" ], - "time": "2019-12-12T12:53:52+00:00" + "time": "2020-01-08T17:29:02+00:00" }, { "name": "symfony/service-contracts", @@ -4836,16 +4837,16 @@ }, { "name": "symfony/translation", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "f7669f48a9633bf8139bc026c755e894b7206677" + "reference": "f5d2ac46930238b30a9c2f1b17c905f3697d808c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/f7669f48a9633bf8139bc026c755e894b7206677", - "reference": "f7669f48a9633bf8139bc026c755e894b7206677", + "url": "https://api.github.com/repos/symfony/translation/zipball/f5d2ac46930238b30a9c2f1b17c905f3697d808c", + "reference": "f5d2ac46930238b30a9c2f1b17c905f3697d808c", "shasum": "" }, "require": { @@ -4908,7 +4909,7 @@ ], "description": "Symfony Translation Component", "homepage": "https://symfony.com", - "time": "2019-12-12T12:53:52+00:00" + "time": "2020-01-15T13:29:06+00:00" }, { "name": "symfony/translation-contracts", @@ -4969,16 +4970,16 @@ }, { "name": "symfony/var-dumper", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "be330f919bdb395d1e0c3f2bfb8948512d6bdd99" + "reference": "46b53fd714568af343953c039ff47b67ce8af8d6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/be330f919bdb395d1e0c3f2bfb8948512d6bdd99", - "reference": "be330f919bdb395d1e0c3f2bfb8948512d6bdd99", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/46b53fd714568af343953c039ff47b67ce8af8d6", + "reference": "46b53fd714568af343953c039ff47b67ce8af8d6", "shasum": "" }, "require": { @@ -5041,7 +5042,7 @@ "debug", "dump" ], - "time": "2019-12-18T13:41:29+00:00" + "time": "2020-01-25T12:44:29+00:00" }, { "name": "tijsverkoyen/css-to-inline-styles", @@ -5285,6 +5286,7 @@ "psr", "psr-7" ], + "abandoned": "laminas/laminas-diactoros", "time": "2019-11-13T19:16:13+00:00" } ], @@ -5479,16 +5481,16 @@ }, { "name": "composer/ca-bundle", - "version": "1.2.5", + "version": "1.2.6", "source": { "type": "git", "url": "https://github.com/composer/ca-bundle.git", - "reference": "62e8fc2dc550e5d6d8c9360c7721662670f58149" + "reference": "47fe531de31fca4a1b997f87308e7d7804348f7e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/ca-bundle/zipball/62e8fc2dc550e5d6d8c9360c7721662670f58149", - "reference": "62e8fc2dc550e5d6d8c9360c7721662670f58149", + "url": "https://api.github.com/repos/composer/ca-bundle/zipball/47fe531de31fca4a1b997f87308e7d7804348f7e", + "reference": "47fe531de31fca4a1b997f87308e7d7804348f7e", "shasum": "" }, "require": { @@ -5531,20 +5533,20 @@ "ssl", "tls" ], - "time": "2019-12-11T14:44:42+00:00" + "time": "2020-01-13T10:02:55+00:00" }, { "name": "composer/composer", - "version": "1.9.1", + "version": "1.9.3", "source": { "type": "git", "url": "https://github.com/composer/composer.git", - "reference": "bb01f2180df87ce7992b8331a68904f80439dd2f" + "reference": "1291a16ce3f48bfdeca39d64fca4875098af4d7b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/composer/zipball/bb01f2180df87ce7992b8331a68904f80439dd2f", - "reference": "bb01f2180df87ce7992b8331a68904f80439dd2f", + "url": "https://api.github.com/repos/composer/composer/zipball/1291a16ce3f48bfdeca39d64fca4875098af4d7b", + "reference": "1291a16ce3f48bfdeca39d64fca4875098af4d7b", "shasum": "" }, "require": { @@ -5611,28 +5613,27 @@ "dependency", "package" ], - "time": "2019-11-01T16:20:17+00:00" + "time": "2020-02-04T11:58:49+00:00" }, { "name": "composer/semver", - "version": "1.5.0", + "version": "1.5.1", "source": { "type": "git", "url": "https://github.com/composer/semver.git", - "reference": "46d9139568ccb8d9e7cdd4539cab7347568a5e2e" + "reference": "c6bea70230ef4dd483e6bbcab6005f682ed3a8de" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/46d9139568ccb8d9e7cdd4539cab7347568a5e2e", - "reference": "46d9139568ccb8d9e7cdd4539cab7347568a5e2e", + "url": "https://api.github.com/repos/composer/semver/zipball/c6bea70230ef4dd483e6bbcab6005f682ed3a8de", + "reference": "c6bea70230ef4dd483e6bbcab6005f682ed3a8de", "shasum": "" }, "require": { "php": "^5.3.2 || ^7.0" }, "require-dev": { - "phpunit/phpunit": "^4.5 || ^5.0.5", - "phpunit/phpunit-mock-objects": "2.3.0 || ^3.0" + "phpunit/phpunit": "^4.5 || ^5.0.5" }, "type": "library", "extra": { @@ -5673,7 +5674,7 @@ "validation", "versioning" ], - "time": "2019-03-19T17:25:45+00:00" + "time": "2020-01-13T12:06:48+00:00" }, { "name": "composer/spdx-licenses", @@ -5837,16 +5838,16 @@ }, { "name": "filp/whoops", - "version": "2.6.0", + "version": "2.7.1", "source": { "type": "git", "url": "https://github.com/filp/whoops.git", - "reference": "ecbc8f3ed2cafca3cfca3d5febaae5a9d2899508" + "reference": "fff6f1e4f36be0e0d0b84d66b413d9dcb0c49130" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/filp/whoops/zipball/ecbc8f3ed2cafca3cfca3d5febaae5a9d2899508", - "reference": "ecbc8f3ed2cafca3cfca3d5febaae5a9d2899508", + "url": "https://api.github.com/repos/filp/whoops/zipball/fff6f1e4f36be0e0d0b84d66b413d9dcb0c49130", + "reference": "fff6f1e4f36be0e0d0b84d66b413d9dcb0c49130", "shasum": "" }, "require": { @@ -5865,7 +5866,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.5-dev" + "dev-master": "2.6-dev" } }, "autoload": { @@ -5894,7 +5895,7 @@ "throwable", "whoops" ], - "time": "2019-12-25T10:00:00+00:00" + "time": "2020-01-15T10:00:00+00:00" }, { "name": "fzaninotto/faker", @@ -6188,16 +6189,16 @@ }, { "name": "myclabs/deep-copy", - "version": "1.9.4", + "version": "1.9.5", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "579bb7356d91f9456ccd505f24ca8b667966a0a7" + "reference": "b2c28789e80a97badd14145fda39b545d83ca3ef" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/579bb7356d91f9456ccd505f24ca8b667966a0a7", - "reference": "579bb7356d91f9456ccd505f24ca8b667966a0a7", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/b2c28789e80a97badd14145fda39b545d83ca3ef", + "reference": "b2c28789e80a97badd14145fda39b545d83ca3ef", "shasum": "" }, "require": { @@ -6232,7 +6233,7 @@ "object", "object graph" ], - "time": "2019-12-15T19:12:40+00:00" + "time": "2020-01-17T21:11:47+00:00" }, { "name": "nunomaduro/collision", @@ -6454,40 +6455,38 @@ }, { "name": "phpdocumentor/reflection-docblock", - "version": "4.3.3", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "2ecaa9fef01634c83bfa8dc1fe35fb5cef223a62" + "reference": "a48807183a4b819072f26e347bbd0b5199a9d15f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/2ecaa9fef01634c83bfa8dc1fe35fb5cef223a62", - "reference": "2ecaa9fef01634c83bfa8dc1fe35fb5cef223a62", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/a48807183a4b819072f26e347bbd0b5199a9d15f", + "reference": "a48807183a4b819072f26e347bbd0b5199a9d15f", "shasum": "" }, "require": { - "php": "^7.0", - "phpdocumentor/reflection-common": "^1.0.0 || ^2.0.0", - "phpdocumentor/type-resolver": "~0.4 || ^1.0.0", - "webmozart/assert": "^1.0" + "ext-filter": "^7.1", + "php": "^7.2", + "phpdocumentor/reflection-common": "^2.0", + "phpdocumentor/type-resolver": "^1.0", + "webmozart/assert": "^1" }, "require-dev": { - "doctrine/instantiator": "^1.0.5", - "mockery/mockery": "^1.0", - "phpunit/phpunit": "^6.4" + "doctrine/instantiator": "^1", + "mockery/mockery": "^1" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.x-dev" + "dev-master": "5.x-dev" } }, "autoload": { "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src/" - ] + "phpDocumentor\\Reflection\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -6498,10 +6497,14 @@ { "name": "Mike van Riel", "email": "me@mikevanriel.com" + }, + { + "name": "Jaap van Otterdijk", + "email": "account@ijaap.nl" } ], "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2019-12-20T13:40:23+00:00" + "time": "2020-02-09T09:16:15+00:00" }, { "name": "phpdocumentor/type-resolver", @@ -6552,24 +6555,24 @@ }, { "name": "phpspec/prophecy", - "version": "1.10.1", + "version": "v1.10.2", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "cbe1df668b3fe136bcc909126a0f529a78d4cbbc" + "reference": "b4400efc9d206e83138e2bb97ed7f5b14b831cd9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/cbe1df668b3fe136bcc909126a0f529a78d4cbbc", - "reference": "cbe1df668b3fe136bcc909126a0f529a78d4cbbc", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/b4400efc9d206e83138e2bb97ed7f5b14b831cd9", + "reference": "b4400efc9d206e83138e2bb97ed7f5b14b831cd9", "shasum": "" }, "require": { "doctrine/instantiator": "^1.0.2", "php": "^5.3|^7.0", "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0|^5.0", - "sebastian/comparator": "^1.2.3|^2.0|^3.0", - "sebastian/recursion-context": "^1.0|^2.0|^3.0" + "sebastian/comparator": "^1.2.3|^2.0|^3.0|^4.0", + "sebastian/recursion-context": "^1.0|^2.0|^3.0|^4.0" }, "require-dev": { "phpspec/phpspec": "^2.5 || ^3.2", @@ -6611,44 +6614,45 @@ "spy", "stub" ], - "time": "2019-12-22T21:05:45+00:00" + "time": "2020-01-20T15:57:02+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "7.0.10", + "version": "8.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf" + "reference": "278b6e876467da2e6b5e5390a2310391618ebc10" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f1884187926fbb755a9aaf0b3836ad3165b478bf", - "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/278b6e876467da2e6b5e5390a2310391618ebc10", + "reference": "278b6e876467da2e6b5e5390a2310391618ebc10", "shasum": "" }, "require": { "ext-dom": "*", "ext-xmlwriter": "*", - "php": "^7.2", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.1.1", - "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^4.2.2", - "sebastian/version": "^2.0.1", + "php": "^7.3", + "phpunit/php-file-iterator": "^3.0", + "phpunit/php-text-template": "^2.0", + "phpunit/php-token-stream": "^4.0", + "sebastian/code-unit-reverse-lookup": "^2.0", + "sebastian/environment": "^5.0", + "sebastian/version": "^3.0", "theseer/tokenizer": "^1.1.3" }, "require-dev": { - "phpunit/phpunit": "^8.2.2" + "phpunit/phpunit": "^9.0" }, "suggest": { - "ext-xdebug": "^2.7.2" + "ext-pcov": "*", + "ext-xdebug": "*" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "7.0-dev" + "dev-master": "8.0-dev" } }, "autoload": { @@ -6674,32 +6678,32 @@ "testing", "xunit" ], - "time": "2019-11-20T13:55:58+00:00" + "time": "2020-02-07T06:03:55+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "2.0.2", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "050bedf145a257b1ff02746c31894800e5122946" + "reference": "354d4a5faa7449a377a18b94a2026ca3415e3d7a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/050bedf145a257b1ff02746c31894800e5122946", - "reference": "050bedf145a257b1ff02746c31894800e5122946", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/354d4a5faa7449a377a18b94a2026ca3415e3d7a", + "reference": "354d4a5faa7449a377a18b94a2026ca3415e3d7a", "shasum": "" }, "require": { - "php": "^7.1" + "php": "^7.3" }, "require-dev": { - "phpunit/phpunit": "^7.1" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -6724,26 +6728,84 @@ "filesystem", "iterator" ], - "time": "2018-09-13T20:33:42+00:00" + "time": "2020-02-07T06:05:22+00:00" }, { - "name": "phpunit/php-text-template", - "version": "1.2.1", + "name": "phpunit/php-invoker", + "version": "3.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "7579d5a1ba7f3ac11c80004d205877911315ae7a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/7579d5a1ba7f3ac11c80004d205877911315ae7a", + "reference": "7579d5a1ba7f3ac11c80004d205877911315ae7a", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": "^7.3" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.0" + }, + "suggest": { + "ext-pcntl": "*" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", + "keywords": [ + "process" + ], + "time": "2020-02-07T06:06:11+00:00" + }, + { + "name": "phpunit/php-text-template", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "526dc996cc0ebdfa428cd2dfccd79b7b53fee346" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/526dc996cc0ebdfa428cd2dfccd79b7b53fee346", + "reference": "526dc996cc0ebdfa428cd2dfccd79b7b53fee346", + "shasum": "" + }, + "require": { + "php": "^7.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -6765,32 +6827,32 @@ "keywords": [ "template" ], - "time": "2015-06-21T13:50:34+00:00" + "time": "2020-02-01T07:43:44+00:00" }, { "name": "phpunit/php-timer", - "version": "2.1.2", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e" + "reference": "4118013a4d0f97356eae8e7fb2f6c6472575d1df" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/1038454804406b0b5f5f520358e78c1c2f71501e", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/4118013a4d0f97356eae8e7fb2f6c6472575d1df", + "reference": "4118013a4d0f97356eae8e7fb2f6c6472575d1df", "shasum": "" }, "require": { - "php": "^7.1" + "php": "^7.3" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.1-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -6814,33 +6876,33 @@ "keywords": [ "timer" ], - "time": "2019-06-07T04:22:29+00:00" + "time": "2020-02-07T06:08:11+00:00" }, { "name": "phpunit/php-token-stream", - "version": "3.1.1", + "version": "4.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff" + "reference": "b2560a0c33f7710e4d7f8780964193e8e8f8effe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/995192df77f63a59e47f025390d2d1fdf8f425ff", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff", + "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/b2560a0c33f7710e4d7f8780964193e8e8f8effe", + "reference": "b2560a0c33f7710e4d7f8780964193e8e8f8effe", "shasum": "" }, "require": { "ext-tokenizer": "*", - "php": "^7.1" + "php": "^7.3" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -6863,20 +6925,20 @@ "keywords": [ "tokenizer" ], - "time": "2019-09-17T06:23:10+00:00" + "time": "2020-02-07T06:19:00+00:00" }, { "name": "phpunit/phpunit", - "version": "8.5.1", + "version": "9.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "7870c78da3c5e4883eaef36ae47853ebb3cb86f2" + "reference": "a5be9621b19ee19dca5f150a5b159f48b5389547" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/7870c78da3c5e4883eaef36ae47853ebb3cb86f2", - "reference": "7870c78da3c5e4883eaef36ae47853ebb3cb86f2", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/a5be9621b19ee19dca5f150a5b159f48b5389547", + "reference": "a5be9621b19ee19dca5f150a5b159f48b5389547", "shasum": "" }, "require": { @@ -6890,29 +6952,29 @@ "myclabs/deep-copy": "^1.9.1", "phar-io/manifest": "^1.0.3", "phar-io/version": "^2.0.1", - "php": "^7.2", + "php": "^7.3", "phpspec/prophecy": "^1.8.1", - "phpunit/php-code-coverage": "^7.0.7", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1.2", - "sebastian/comparator": "^3.0.2", - "sebastian/diff": "^3.0.2", - "sebastian/environment": "^4.2.2", - "sebastian/exporter": "^3.1.1", - "sebastian/global-state": "^3.0.0", - "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0.1", - "sebastian/type": "^1.1.3", - "sebastian/version": "^2.0.1" + "phpunit/php-code-coverage": "^8.0", + "phpunit/php-file-iterator": "^3.0", + "phpunit/php-invoker": "^3.0", + "phpunit/php-text-template": "^2.0", + "phpunit/php-timer": "^3.0", + "sebastian/comparator": "^4.0", + "sebastian/diff": "^4.0", + "sebastian/environment": "^5.0", + "sebastian/exporter": "^4.0", + "sebastian/global-state": "^4.0", + "sebastian/object-enumerator": "^4.0", + "sebastian/resource-operations": "^3.0", + "sebastian/type": "^2.0", + "sebastian/version": "^3.0" }, "require-dev": { "ext-pdo": "*" }, "suggest": { "ext-soap": "*", - "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0.0" + "ext-xdebug": "*" }, "bin": [ "phpunit" @@ -6920,12 +6982,15 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "8.5-dev" + "dev-master": "9.0-dev" } }, "autoload": { "classmap": [ "src/" + ], + "files": [ + "src/Framework/Assert/Functions.php" ] }, "notification-url": "https://packagist.org/downloads/", @@ -6946,32 +7011,32 @@ "testing", "xunit" ], - "time": "2019-12-25T14:49:39+00:00" + "time": "2020-02-07T06:56:17+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.1", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18" + "reference": "5b5dbe0044085ac41df47e79d34911a15b96d82e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/5b5dbe0044085ac41df47e79d34911a15b96d82e", + "reference": "5b5dbe0044085ac41df47e79d34911a15b96d82e", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "php": "^7.3" }, "require-dev": { - "phpunit/phpunit": "^5.7 || ^6.0" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -6991,34 +7056,34 @@ ], "description": "Looks up which function or method a line of code belongs to", "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "time": "2017-03-04T06:30:41+00:00" + "time": "2020-02-07T06:20:13+00:00" }, { "name": "sebastian/comparator", - "version": "3.0.2", + "version": "4.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da" + "reference": "85b3435da967696ed618ff745f32be3ff4a2b8e8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/5de4fc177adf9bce8df98d8d141a7559d7ccf6da", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/85b3435da967696ed618ff745f32be3ff4a2b8e8", + "reference": "85b3435da967696ed618ff745f32be3ff4a2b8e8", "shasum": "" }, "require": { - "php": "^7.1", - "sebastian/diff": "^3.0", - "sebastian/exporter": "^3.1" + "php": "^7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^7.1" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -7031,6 +7096,10 @@ "BSD-3-Clause" ], "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, { "name": "Jeff Welch", "email": "whatthejeff@gmail.com" @@ -7042,10 +7111,6 @@ { "name": "Bernhard Schussek", "email": "bschussek@2bepublished.at" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" } ], "description": "Provides the functionality to compare PHP values for equality", @@ -7055,33 +7120,33 @@ "compare", "equality" ], - "time": "2018-07-12T15:12:46+00:00" + "time": "2020-02-07T06:08:51+00:00" }, { "name": "sebastian/diff", - "version": "3.0.2", + "version": "4.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29" + "reference": "c0c26c9188b538bfa985ae10c9f05d278f12060d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/720fcc7e9b5cf384ea68d9d930d480907a0c1a29", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/c0c26c9188b538bfa985ae10c9f05d278f12060d", + "reference": "c0c26c9188b538bfa985ae10c9f05d278f12060d", "shasum": "" }, "require": { - "php": "^7.1" + "php": "^7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5 || ^8.0", - "symfony/process": "^2 || ^3.3 || ^4" + "phpunit/phpunit": "^9.0", + "symfony/process": "^4 || ^5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -7094,13 +7159,13 @@ "BSD-3-Clause" ], "authors": [ - { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" - }, { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" + }, + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" } ], "description": "Diff implementation", @@ -7111,27 +7176,27 @@ "unidiff", "unified diff" ], - "time": "2019-02-04T06:01:07+00:00" + "time": "2020-02-07T06:09:38+00:00" }, { "name": "sebastian/environment", - "version": "4.2.3", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368" + "reference": "fea125c3bf7cab63a909990133d425e5a0a61e40" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/464c90d7bdf5ad4e8a6aea15c091fec0603d4368", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/fea125c3bf7cab63a909990133d425e5a0a61e40", + "reference": "fea125c3bf7cab63a909990133d425e5a0a61e40", "shasum": "" }, "require": { - "php": "^7.1" + "php": "^7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5" + "phpunit/phpunit": "^9.0" }, "suggest": { "ext-posix": "*" @@ -7139,7 +7204,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.2-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -7164,34 +7229,34 @@ "environment", "hhvm" ], - "time": "2019-11-20T08:46:58+00:00" + "time": "2020-02-07T06:10:11+00:00" }, { "name": "sebastian/exporter", - "version": "3.1.2", + "version": "4.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e" + "reference": "80c26562e964016538f832f305b2286e1ec29566" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/68609e1261d215ea5b21b7987539cbfbe156ec3e", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/80c26562e964016538f832f305b2286e1ec29566", + "reference": "80c26562e964016538f832f305b2286e1ec29566", "shasum": "" }, "require": { - "php": "^7.0", - "sebastian/recursion-context": "^3.0" + "php": "^7.3", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-mbstring": "*", - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -7231,30 +7296,30 @@ "export", "exporter" ], - "time": "2019-09-14T09:02:43+00:00" + "time": "2020-02-07T06:10:52+00:00" }, { "name": "sebastian/global-state", - "version": "3.0.0", + "version": "4.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4" + "reference": "bdb1e7c79e592b8c82cb1699be3c8743119b8a72" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", - "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bdb1e7c79e592b8c82cb1699be3c8743119b8a72", + "reference": "bdb1e7c79e592b8c82cb1699be3c8743119b8a72", "shasum": "" }, "require": { - "php": "^7.2", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "php": "^7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-dom": "*", - "phpunit/phpunit": "^8.0" + "phpunit/phpunit": "^9.0" }, "suggest": { "ext-uopz": "*" @@ -7262,7 +7327,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -7285,34 +7350,34 @@ "keywords": [ "global state" ], - "time": "2019-02-01T05:30:01+00:00" + "time": "2020-02-07T06:11:37+00:00" }, { "name": "sebastian/object-enumerator", - "version": "3.0.3", + "version": "4.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5" + "reference": "e67516b175550abad905dc952f43285957ef4363" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/7cfd9e65d11ffb5af41198476395774d4c8a84c5", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/e67516b175550abad905dc952f43285957ef4363", + "reference": "e67516b175550abad905dc952f43285957ef4363", "shasum": "" }, "require": { - "php": "^7.0", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "php": "^7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -7332,122 +7397,27 @@ ], "description": "Traverses array structures and object graphs to enumerate all referenced objects", "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2017-08-03T12:35:26+00:00" + "time": "2020-02-07T06:12:23+00:00" }, { "name": "sebastian/object-reflector", - "version": "1.1.1", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "773f97c67f28de00d397be301821b06708fca0be" + "reference": "f4fd0835cabb0d4a6546d9fe291e5740037aa1e7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/773f97c67f28de00d397be301821b06708fca0be", - "reference": "773f97c67f28de00d397be301821b06708fca0be", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/f4fd0835cabb0d4a6546d9fe291e5740037aa1e7", + "reference": "f4fd0835cabb0d4a6546d9fe291e5740037aa1e7", "shasum": "" }, "require": { - "php": "^7.0" + "php": "^7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Allows reflection of object attributes, including inherited and non-public ones", - "homepage": "https://github.com/sebastianbergmann/object-reflector/", - "time": "2017-03-29T09:07:27+00:00" - }, - { - "name": "sebastian/recursion-context", - "version": "3.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", - "shasum": "" - }, - "require": { - "php": "^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net" - } - ], - "description": "Provides functionality to recursively process PHP variables", - "homepage": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2017-03-03T06:23:57+00:00" - }, - { - "name": "sebastian/resource-operations", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/4d7a795d35b889bf80a0cc04e08d77cedfa917a9", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9", - "shasum": "" - }, - "require": { - "php": "^7.1" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { @@ -7470,34 +7440,132 @@ "email": "sebastian@phpunit.de" } ], - "description": "Provides a list of PHP built-in functions that operate on resources", - "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "time": "2018-10-04T04:07:39+00:00" + "description": "Allows reflection of object attributes, including inherited and non-public ones", + "homepage": "https://github.com/sebastianbergmann/object-reflector/", + "time": "2020-02-07T06:19:40+00:00" }, { - "name": "sebastian/type", - "version": "1.1.3", + "name": "sebastian/recursion-context", + "version": "4.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/type.git", - "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3" + "url": "https://github.com/sebastianbergmann/recursion-context.git", + "reference": "cdd86616411fc3062368b720b0425de10bd3d579" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/3aaaa15fa71d27650d62a948be022fe3b48541a3", - "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cdd86616411fc3062368b720b0425de10bd3d579", + "reference": "cdd86616411fc3062368b720b0425de10bd3d579", "shasum": "" }, "require": { - "php": "^7.2" + "php": "^7.3" }, "require-dev": { - "phpunit/phpunit": "^8.2" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" + } + ], + "description": "Provides functionality to recursively process PHP variables", + "homepage": "http://www.github.com/sebastianbergmann/recursion-context", + "time": "2020-02-07T06:18:20+00:00" + }, + { + "name": "sebastian/resource-operations", + "version": "3.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/resource-operations.git", + "reference": "8c98bf0dfa1f9256d0468b9803a1e1df31b6fa98" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/8c98bf0dfa1f9256d0468b9803a1e1df31b6fa98", + "reference": "8c98bf0dfa1f9256d0468b9803a1e1df31b6fa98", + "shasum": "" + }, + "require": { + "php": "^7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Provides a list of PHP built-in functions that operate on resources", + "homepage": "https://www.github.com/sebastianbergmann/resource-operations", + "time": "2020-02-07T06:13:02+00:00" + }, + { + "name": "sebastian/type", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "9e8f42f740afdea51f5f4e8cec2035580e797ee1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/9e8f42f740afdea51f5f4e8cec2035580e797ee1", + "reference": "9e8f42f740afdea51f5f4e8cec2035580e797ee1", + "shasum": "" + }, + "require": { + "php": "^7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" } }, "autoload": { @@ -7518,29 +7586,29 @@ ], "description": "Collection of value objects that represent the types of the PHP type system", "homepage": "https://github.com/sebastianbergmann/type", - "time": "2019-07-02T08:10:15+00:00" + "time": "2020-02-07T06:13:43+00:00" }, { "name": "sebastian/version", - "version": "2.0.1", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" + "reference": "0411bde656dce64202b39c2f4473993a9081d39e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/0411bde656dce64202b39c2f4473993a9081d39e", + "reference": "0411bde656dce64202b39c2f4473993a9081d39e", "shasum": "" }, "require": { - "php": ">=5.6" + "php": "^7.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -7561,7 +7629,7 @@ ], "description": "Library that helps with managing the version number of Git-hosted PHP projects", "homepage": "https://github.com/sebastianbergmann/version", - "time": "2016-10-03T07:35:21+00:00" + "time": "2020-01-21T06:36:37+00:00" }, { "name": "seld/jsonlint", @@ -7614,16 +7682,16 @@ }, { "name": "seld/phar-utils", - "version": "1.0.1", + "version": "1.0.2", "source": { "type": "git", "url": "https://github.com/Seldaek/phar-utils.git", - "reference": "7009b5139491975ef6486545a39f3e6dad5ac30a" + "reference": "84715761c35808076b00908a20317a3a8a67d17e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Seldaek/phar-utils/zipball/7009b5139491975ef6486545a39f3e6dad5ac30a", - "reference": "7009b5139491975ef6486545a39f3e6dad5ac30a", + "url": "https://api.github.com/repos/Seldaek/phar-utils/zipball/84715761c35808076b00908a20317a3a8a67d17e", + "reference": "84715761c35808076b00908a20317a3a8a67d17e", "shasum": "" }, "require": { @@ -7654,20 +7722,20 @@ "keywords": [ "phra" ], - "time": "2015-10-13T18:44:15+00:00" + "time": "2020-01-13T10:41:09+00:00" }, { "name": "symfony/filesystem", - "version": "v4.4.2", + "version": "v4.4.4", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "40c2606131d56eff6f193b6e2ceb92414653b591" + "reference": "266c9540b475f26122b61ef8b23dd9198f5d1cfd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/40c2606131d56eff6f193b6e2ceb92414653b591", - "reference": "40c2606131d56eff6f193b6e2ceb92414653b591", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/266c9540b475f26122b61ef8b23dd9198f5d1cfd", + "reference": "266c9540b475f26122b61ef8b23dd9198f5d1cfd", "shasum": "" }, "require": { @@ -7704,7 +7772,7 @@ ], "description": "Symfony Filesystem Component", "homepage": "https://symfony.com", - "time": "2019-11-26T23:16:41+00:00" + "time": "2020-01-21T08:20:44+00:00" }, { "name": "theseer/tokenizer", diff --git a/config/debugbar.php b/config/debugbar.php new file mode 100644 index 0000000..0495fcf --- /dev/null +++ b/config/debugbar.php @@ -0,0 +1,202 @@ + env('DEBUGBAR_ENABLED', null), + 'except' => [ + 'telescope*' + ], + + /* + |-------------------------------------------------------------------------- + | Storage settings + |-------------------------------------------------------------------------- + | + | DebugBar stores data for session/ajax requests. + | You can disable this, so the debugbar stores data in headers/session, + | but this can cause problems with large data collectors. + | By default, file storage (in the storage folder) is used. Redis and PDO + | can also be used. For PDO, run the package migrations first. + | + */ + 'storage' => [ + 'enabled' => false, + 'driver' => 'file', // redis, file, pdo, custom + 'path' => storage_path('debugbar'), // For file driver + 'connection' => null, // Leave null for default connection (Redis/PDO) + 'provider' => '' // Instance of StorageInterface for custom driver + ], + + /* + |-------------------------------------------------------------------------- + | Vendors + |-------------------------------------------------------------------------- + | + | Vendor files are included by default, but can be set to false. + | This can also be set to 'js' or 'css', to only include javascript or css vendor files. + | Vendor files are for css: font-awesome (including fonts) and highlight.js (css files) + | and for js: jquery and and highlight.js + | So if you want syntax highlighting, set it to true. + | jQuery is set to not conflict with existing jQuery scripts. + | + */ + + 'include_vendors' => true, + + /* + |-------------------------------------------------------------------------- + | Capture Ajax Requests + |-------------------------------------------------------------------------- + | + | The Debugbar can capture Ajax requests and display them. If you don't want this (ie. because of errors), + | you can use this option to disable sending the data through the headers. + | + | Optionally, you can also send ServerTiming headers on ajax requests for the Chrome DevTools. + */ + + 'capture_ajax' => true, + 'add_ajax_timing' => false, + + /* + |-------------------------------------------------------------------------- + | Custom Error Handler for Deprecated warnings + |-------------------------------------------------------------------------- + | + | When enabled, the Debugbar shows deprecated warnings for Symfony components + | in the Messages tab. + | + */ + 'error_handler' => false, + + /* + |-------------------------------------------------------------------------- + | Clockwork integration + |-------------------------------------------------------------------------- + | + | The Debugbar can emulate the Clockwork headers, so you can use the Chrome + | Extension, without the server-side code. It uses Debugbar collectors instead. + | + */ + 'clockwork' => false, + + /* + |-------------------------------------------------------------------------- + | DataCollectors + |-------------------------------------------------------------------------- + | + | Enable/disable DataCollectors + | + */ + + 'collectors' => [ + 'phpinfo' => true, // Php version + 'messages' => true, // Messages + 'time' => true, // Time Datalogger + 'memory' => true, // Memory usage + 'exceptions' => true, // Exception displayer + 'log' => true, // Logs from Monolog (merged in messages if enabled) + 'db' => true, // Show database (PDO) queries and bindings + 'views' => true, // Views with their data + 'route' => true, // Current route information + 'auth' => false, // Display Laravel authentication status + 'gate' => true, // Display Laravel Gate checks + 'session' => true, // Display session data + 'symfony_request' => true, // Only one can be enabled.. + 'mail' => true, // Catch mail messages + 'laravel' => false, // Laravel version and environment + 'events' => false, // All events fired + 'default_request' => false, // Regular or special Symfony request logger + 'logs' => false, // Add the latest log messages + 'files' => false, // Show the included files + 'config' => false, // Display config settings + 'cache' => false, // Display cache events + 'models' => false, // Display models + ], + + /* + |-------------------------------------------------------------------------- + | Extra options + |-------------------------------------------------------------------------- + | + | Configure some DataCollectors + | + */ + + 'options' => [ + 'auth' => [ + 'show_name' => true, // Also show the users name/email in the debugbar + ], + 'db' => [ + 'with_params' => true, // Render SQL with the parameters substituted + 'backtrace' => true, // Use a backtrace to find the origin of the query in your files. + 'timeline' => false, // Add the queries to the timeline + 'explain' => [ // Show EXPLAIN output on queries + 'enabled' => false, + 'types' => ['SELECT'], // // workaround ['SELECT'] only. https://github.com/barryvdh/laravel-debugbar/issues/888 ['SELECT', 'INSERT', 'UPDATE', 'DELETE']; for MySQL 5.6.3+ + ], + 'hints' => true, // Show hints for common mistakes + ], + 'mail' => [ + 'full_log' => false + ], + 'views' => [ + 'data' => false, //Note: Can slow down the application, because the data can be quite large.. + ], + 'route' => [ + 'label' => true // show complete route on bar + ], + 'logs' => [ + 'file' => null + ], + 'cache' => [ + 'values' => true // collect cache values + ], + ], + + /* + |-------------------------------------------------------------------------- + | Inject Debugbar in Response + |-------------------------------------------------------------------------- + | + | Usually, the debugbar is added just before , by listening to the + | Response after the App is done. If you disable this, you have to add them + | in your template yourself. See http://phpdebugbar.com/docs/rendering.html + | + */ + + 'inject' => true, + + /* + |-------------------------------------------------------------------------- + | DebugBar route prefix + |-------------------------------------------------------------------------- + | + | Sometimes you want to set route prefix to be used by DebugBar to load + | its resources from. Usually the need comes from misconfigured web server or + | from trying to overcome bugs like this: http://trac.nginx.org/nginx/ticket/97 + | + */ + 'route_prefix' => '_debugbar', + + /* + |-------------------------------------------------------------------------- + | DebugBar route domain + |-------------------------------------------------------------------------- + | + | By default DebugBar route served from the same domain that request served. + | To override default domain, specify it as a non-empty value. + */ + 'route_domain' => null, +]; diff --git a/config/permissions.php b/config/permissions.php index 7780ede..98d7c70 100755 --- a/config/permissions.php +++ b/config/permissions.php @@ -29,6 +29,9 @@ return [ 'sua-st-tp' => ['name' => 'SUPERADMIN > Einstellungen > Reisprogramme' , 'color' => 'superadmin'], 'sua-st-tc' => ['name' => 'SUPERADMIN > Einstellungen > Reiseländer' , 'color' => 'superadmin'], 'sua-st-tn' => ['name' => 'SUPERADMIN > Einstellungen > Nationalitäten' , 'color' => 'superadmin'], + 'sua-re' => ['name' => 'SUPERADMIN > Export' , 'color' => 'superadmin'], + 'sua-re-bo' => ['name' => 'SUPERADMIN > Export > Buchungen' , 'color' => 'superadmin'], + 'sua-re-pp' => ['name' => 'SUPERADMIN > Export > Leistungsträger' , 'color' => 'superadmin'], 'sua-ur-rt' => ['name' => 'SUPERADMIN > User Rechte' , 'color' => 'danger'], ], ], diff --git a/database/migrations/2018_10_29_202123_create_booking_table.php b/database/migrations/2018_10_29_202123_create_booking_table.php index c05d0d9..b031d35 100644 --- a/database/migrations/2018_10_29_202123_create_booking_table.php +++ b/database/migrations/2018_10_29_202123_create_booking_table.php @@ -37,8 +37,8 @@ class CreateBookingTable extends Migration $table->date('end_date')->nullable(); $table->bigInteger('website_id')->nullable(); $table->string('travel_number', 30)->nullable(); - $table->string('participant_name', 80)->nullable(); - $table->string('participant_firstname', 80)->nullable(); + $table->string('participant_name', 255)->nullable(); + $table->string('participant_firstname', 255)->nullable(); $table->date('participant_birthdate')->nullable(); $table->bigInteger('participant_salutation_id')->nullable(); $table->string('ev_number', 255)->nullable(); diff --git a/database/migrations/2018_10_29_202125_create_lead_table.php b/database/migrations/2018_10_29_202125_create_lead_table.php index 82e524f..dd21170 100644 --- a/database/migrations/2018_10_29_202125_create_lead_table.php +++ b/database/migrations/2018_10_29_202125_create_lead_table.php @@ -31,7 +31,7 @@ class CreateLeadTable extends Migration $table->tinyInteger('is_closed')->nullable()->default(0); $table->bigInteger('initialcontacttype_id')->nullable(); $table->bigInteger('searchengine_id')->nullable(); - $table->string('searchengine_keywords', 80)->nullable(); + $table->string('searchengine_keywords', 255)->nullable(); $table->bigInteger('status_id'); $table->date('next_due_date')->nullable(); $table->bigInteger('website_id')->nullable(); @@ -40,8 +40,8 @@ class CreateLeadTable extends Migration $table->dateTime('updated_at'); $table->decimal('price', 10, 2)->nullable(); $table->bigInteger('pax')->nullable(); - $table->string('participant_name', 80)->nullable(); - $table->string('participant_firstname', 80)->nullable(); + $table->string('participant_name', 255)->nullable(); + $table->string('participant_firstname', 255)->nullable(); $table->date('participant_birthdate')->nullable(); $table->bigInteger('participant_salutation_id')->nullable(); diff --git a/database/migrations/2019_07_19_155853_create_i_q_content_tree_nodes_table.php b/database/migrations/2019_07_19_155853_create_i_q_content_tree_nodes_table.php index 5e06c92..26d3d86 100644 --- a/database/migrations/2019_07_19_155853_create_i_q_content_tree_nodes_table.php +++ b/database/migrations/2019_07_19_155853_create_i_q_content_tree_nodes_table.php @@ -29,7 +29,9 @@ class CreateIQContentTreeNodesTable extends Migration $table->string('name', 64)->index(); $table->string('identifier', 80)->index(); $table->string('slug', 80)->index()->unique(); - $table->string('description')->nullable(); + $table->text('description')->nullable(); + $table->string('title')->nullable(); + $table->text('settings')->nullable(); $table->unsignedTinyInteger('pos')->default(0); diff --git a/database/migrations/2020_01_29_143834_create_travel_booking_table.php b/database/migrations/2020_01_29_143834_create_travel_booking_table.php new file mode 100644 index 0000000..6625add --- /dev/null +++ b/database/migrations/2020_01_29_143834_create_travel_booking_table.php @@ -0,0 +1,81 @@ +create('travel_booking', function (Blueprint $table) { + $table->increments('id'); + $table->bigInteger('crm_booking_id')->nullable(); + $table->integer('salutation_id')->nullable(); + $table->string('first_name', 255)->nullable(); + $table->string('last_name', 255)->nullable(); + $table->string('street', 255)->nullable(); + $table->string('zipcode', 255)->nullable(); + $table->string('city', 255)->nullable(); + $table->integer('country_id')->nullable(); + $table->string('fax', 255)->nullable(); + $table->string('phone', 255)->nullable(); + $table->string('mobile', 255)->nullable(); + $table->text('comments')->nullable(); + $table->string('email', 255)->nullable(); + $table->dateTime('created')->nullable(); + $table->date('selected_start_date')->nullable(); + $table->date('selected_end_date')->nullable(); + $table->string('program_name', 255)->nullable(); + $table->text('selected_travel')->nullable(); + $table->text('selected_departure')->nullable(); + $table->integer('program_id')->nullable(); + $table->integer('period_id')->nullable(); + $table->string('class', 255)->nullable(); + $table->integer('selected_adults')->nullable(); + $table->integer('selected_childs')->nullable(); + $table->integer('participants_total')->nullable(); + $table->text('participants')->nullable(); + $table->text('drafts')->nullable(); + $table->text('service_items')->nullable(); + $table->text('arrangements')->nullable(); + $table->text('rooms')->nullable(); + $table->decimal('price', 10, 2)->nullable(); + $table->decimal('price_total', 10, 2)->nullable(); + $table->decimal('deposit_total', 10, 2)->nullable(); + $table->decimal('final_payment', 10, 2)->nullable(); + $table->date('final_payment_date')->nullable(); + $table->string('insurance_name', 255)->nullable(); + $table->text('insurances')->nullable(); + $table->integer('travel_cancellation')->nullable(); + $table->text('options')->nullable(); + $table->text('class_options')->nullable();; + $table->text('extra_category')->nullable();; + $table->unsignedTinyInteger('accept_legal_rights')->nullable(); + $table->string('ip', 255)->nullable(); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::connection('mysql_stern')->dropIfExists('travel_booking'); + } +} diff --git a/database/migrations/2020_01_29_150706_create_customer_table.php b/database/migrations/2020_01_29_150706_create_customer_table.php new file mode 100644 index 0000000..524519d --- /dev/null +++ b/database/migrations/2020_01_29_150706_create_customer_table.php @@ -0,0 +1,74 @@ +bigIncrements('id'); + $table->bigInteger('salutation_id')->nullable(); + $table->string('title', 255)->nullable(); + $table->string('name', 255); + $table->string('firstname', 255)->nullable(); + $table->date('birthdate')->nullable(); + $table->string('company', 255)->nullable(); + $table->string('street', 255)->nullable(); + $table->string('zip', 255)->nullable(); + $table->string('city', 255)->nullable(); + $table->string('email', 255)->nullable(); + $table->string('phone', 255)->nullable(); + $table->string('phonebusiness', 255)->nullable(); + $table->string('phonemobile', 255)->nullable(); + $table->string('fax', 255)->nullable(); + $table->string('bank', 80)->nullable(); + $table->string('bank_code', 80)->nullable(); + $table->string('bank_account_number', 80)->nullable(); + $table->bigInteger('credit_card_type_id')->nullable(); + $table->string('credit_card_number', 80)->nullable(); + $table->date('credit_card_expiration_date')->nullable(); + $table->text('participants_remarks')->nullable(); + $table->text('miscellaneous_remarks')->nullable(); + $table->dateTime('created_at'); + $table->dateTime('updated_at'); + $table->bigInteger('country_id')->nullable(); + + $table->index('salutation_id', 'salutation_id_idx'); + $table->index('credit_card_type_id', 'credit_card_type_id_idx'); + $table->index('country_id', 'country_id_idx'); + + $table->foreign('country_id', 'customer_country_id_travel_country_id')->references('id')->on('travel_country')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + $table->foreign('credit_card_type_id', 'customer_credit_card_type_id_credit_card_type_id')->references('id')->on('credit_card_type')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + $table->foreign('salutation_id', 'customer_salutation_id_salutation_id')->references('id')->on('salutation')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('customer'); + } +} diff --git a/database/migrations/2020_01_29_151231_create_initial_contact_type_table.php b/database/migrations/2020_01_29_151231_create_initial_contact_type_table.php new file mode 100644 index 0000000..e8ad7d7 --- /dev/null +++ b/database/migrations/2020_01_29_151231_create_initial_contact_type_table.php @@ -0,0 +1,43 @@ +bigIncrements('id'); + $table->string('name', 255); + + + + + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('initial_contact_type'); + } +} diff --git a/database/migrations/2020_01_29_151258_create_salutation_table.php b/database/migrations/2020_01_29_151258_create_salutation_table.php new file mode 100644 index 0000000..4523fa2 --- /dev/null +++ b/database/migrations/2020_01_29_151258_create_salutation_table.php @@ -0,0 +1,43 @@ +bigIncrements('id'); + $table->string('name', 255); + + + + + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('salutation'); + } +} diff --git a/database/migrations/2020_01_29_151309_create_searchengine_table.php b/database/migrations/2020_01_29_151309_create_searchengine_table.php new file mode 100644 index 0000000..d55f8b8 --- /dev/null +++ b/database/migrations/2020_01_29_151309_create_searchengine_table.php @@ -0,0 +1,43 @@ +bigIncrements('id'); + $table->string('name', 255); + + + + + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('searchengine'); + } +} diff --git a/database/migrations/2020_01_29_151330_create_travel_category_table.php b/database/migrations/2020_01_29_151330_create_travel_category_table.php new file mode 100644 index 0000000..0c17d23 --- /dev/null +++ b/database/migrations/2020_01_29_151330_create_travel_category_table.php @@ -0,0 +1,43 @@ +bigIncrements('id'); + $table->string('name', 255); + + + + + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('travel_category'); + } +} diff --git a/database/migrations/2020_01_29_151358_create_inquiry_table.php b/database/migrations/2020_01_29_151358_create_inquiry_table.php new file mode 100644 index 0000000..57ad9ef --- /dev/null +++ b/database/migrations/2020_01_29_151358_create_inquiry_table.php @@ -0,0 +1,58 @@ +bigIncrements('id'); + $table->bigInteger('lead_id')->nullable(); + $table->bigInteger('template_id')->nullable(); + $table->tinyInteger('in_pdf')->nullable()->default(0); + $table->date('begin')->nullable(); + $table->date('end')->nullable(); + $table->bigInteger('type_id')->nullable(); + $table->string('type_s', 80)->nullable(); + $table->text('data_s')->nullable(); + $table->bigInteger('view_position')->nullable(); + + $table->index('lead_id', 'inquiry_lead_id_idx'); + $table->index('template_id', 'inquiry_template_id_idx'); + $table->index('type_id', 'inquiry_type_id_idx'); + + $table->foreign('lead_id', 'inquiry_lead_id_lead_id')->references('id')->on('lead')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + $table->foreign('template_id', 'inquiry_template_id_inquiry_template_id')->references('id')->on('inquiry_template')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + $table->foreign('type_id', 'inquiry_type_id_inquiry_type_id')->references('id')->on('inquiry_type')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('inquiry'); + } +} diff --git a/database/migrations/2020_01_29_151358_create_lead_participant_table.php b/database/migrations/2020_01_29_151358_create_lead_participant_table.php new file mode 100644 index 0000000..0f66de2 --- /dev/null +++ b/database/migrations/2020_01_29_151358_create_lead_participant_table.php @@ -0,0 +1,51 @@ +bigIncrements('id'); + $table->bigInteger('lead_id')->nullable(); + $table->string('participant_name', 255)->nullable(); + $table->string('participant_firstname', 255)->nullable(); + $table->date('participant_birthdate')->nullable(); + $table->bigInteger('participant_salutation_id')->nullable(); + + $table->index('lead_id', 'lead_participant_lead_id_idx'); + $table->index('participant_salutation_id', 'lead_participant_participant_salutation_id_idx'); + + $table->foreign('lead_id', 'lead_participant_lead_id_lead_id')->references('id')->on('lead')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + $table->foreign('participant_salutation_id', 'lead_participant_participant_salutation_id_salutation_id')->references('id')->on('salutation')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('lead_participant'); + } +} diff --git a/database/migrations/2020_01_29_151358_create_offer_table.php b/database/migrations/2020_01_29_151358_create_offer_table.php new file mode 100644 index 0000000..9460b90 --- /dev/null +++ b/database/migrations/2020_01_29_151358_create_offer_table.php @@ -0,0 +1,48 @@ +bigIncrements('id'); + $table->bigInteger('lead_id'); + $table->decimal('total', 10, 2)->default(0.00); + // $table->UNKNOWN:longblob('binary_data'); + $table->dateTime('created_at'); + $table->dateTime('updated_at'); + + $table->index('lead_id', 'offer_lead_id_idx'); + + $table->foreign('lead_id', 'offer_lead_id_lead_id')->references('id')->on('lead')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('offer'); + } +} diff --git a/database/migrations/2020_01_29_151358_create_status_history_table.php b/database/migrations/2020_01_29_151358_create_status_history_table.php new file mode 100644 index 0000000..1e980fc --- /dev/null +++ b/database/migrations/2020_01_29_151358_create_status_history_table.php @@ -0,0 +1,56 @@ +bigIncrements('id'); + $table->bigInteger('status_id'); + $table->bigInteger('lead_id'); + $table->integer('sf_guard_user_id'); + $table->date('date'); + $table->text('remarks')->nullable(); + $table->date('target_date'); + $table->dateTime('created_at'); + + $table->index('sf_guard_user_id', 'sf_guard_user_id_idx'); + $table->index('status_id', 'status_id_idx'); + $table->index('lead_id', 'lead_id_idx'); + + $table->foreign('lead_id', 'status_history_lead_id_lead_id')->references('id')->on('lead')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + $table->foreign('sf_guard_user_id', 'status_history_sf_guard_user_id_sf_guard_user_id')->references('id')->on('sf_guard_user')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + $table->foreign('status_id', 'status_history_status_id_status_id')->references('id')->on('status')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('status_history'); + } +} diff --git a/database/migrations/2020_01_29_151359_create_website_table.php b/database/migrations/2020_01_29_151359_create_website_table.php new file mode 100644 index 0000000..a499721 --- /dev/null +++ b/database/migrations/2020_01_29_151359_create_website_table.php @@ -0,0 +1,43 @@ +bigIncrements('id'); + $table->string('name', 255); + + + + + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('website'); + } +} diff --git a/database/migrations/2020_01_29_152708_create_coupon_table.php b/database/migrations/2020_01_29_152708_create_coupon_table.php new file mode 100644 index 0000000..5921a1d --- /dev/null +++ b/database/migrations/2020_01_29_152708_create_coupon_table.php @@ -0,0 +1,56 @@ +bigIncrements('id'); + $table->string('number', 30)->nullable(); + $table->bigInteger('customer_id'); + $table->bigInteger('booking_id'); + $table->decimal('value', 10, 2)->default(0.00); + $table->date('issue_date'); + $table->date('valid_date'); + $table->tinyInteger('is_redeemed')->default(0); + $table->date('redeem_date')->nullable(); + $table->dateTime('created_at'); + $table->dateTime('updated_at'); + + $table->index('customer_id', 'customer_id_idx'); + $table->index('booking_id', 'booking_id_idx'); + + $table->foreign('booking_id', 'coupon_booking_id_booking_id')->references('id')->on('booking')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + $table->foreign('customer_id', 'coupon_customer_id_customer_id')->references('id')->on('customer')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('coupon'); + } +} diff --git a/database/migrations/2020_01_29_152708_create_credit_card_type_table.php b/database/migrations/2020_01_29_152708_create_credit_card_type_table.php new file mode 100644 index 0000000..2a4b574 --- /dev/null +++ b/database/migrations/2020_01_29_152708_create_credit_card_type_table.php @@ -0,0 +1,43 @@ +bigIncrements('id'); + $table->string('name', 255); + + + + + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('credit_card_type'); + } +} diff --git a/database/migrations/2020_01_29_152708_create_inquiry_template_table.php b/database/migrations/2020_01_29_152708_create_inquiry_template_table.php new file mode 100644 index 0000000..e0a1138 --- /dev/null +++ b/database/migrations/2020_01_29_152708_create_inquiry_template_table.php @@ -0,0 +1,43 @@ +bigIncrements('id'); + $table->string('title', 130)->nullable(); + + + + + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('inquiry_template'); + } +} diff --git a/database/migrations/2020_01_29_152709_create_inquiry_type_table.php b/database/migrations/2020_01_29_152709_create_inquiry_type_table.php new file mode 100644 index 0000000..5edff3b --- /dev/null +++ b/database/migrations/2020_01_29_152709_create_inquiry_type_table.php @@ -0,0 +1,45 @@ +bigIncrements('id'); + $table->string('name', 80); + $table->bigInteger('arrangement_type_id')->nullable(); + + $table->index('arrangement_type_id', 'inquiry_type_arrangement_type_id_idx'); + + $table->foreign('arrangement_type_id', 'inquiry_type_arrangement_type_id_arrangement_type_id')->references('id')->on('arrangement_type')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('inquiry_type'); + } +} diff --git a/database/migrations/2020_01_29_152709_create_insurance_certificate_table.php b/database/migrations/2020_01_29_152709_create_insurance_certificate_table.php new file mode 100644 index 0000000..5572a96 --- /dev/null +++ b/database/migrations/2020_01_29_152709_create_insurance_certificate_table.php @@ -0,0 +1,50 @@ +bigIncrements('id'); + $table->bigInteger('booking_id'); + $table->bigInteger('internal_id'); + $table->string('filename', 255); + // $table->UNKNOWN:longblob('binary_data'); + $table->dateTime('created_at'); + $table->dateTime('updated_at'); + $table->text('request_data')->nullable(); + + $table->index('booking_id', 'booking_id_idx'); + + $table->foreign('booking_id', 'insurance_certificate_booking_id_booking_id')->references('id')->on('booking')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('insurance_certificate'); + } +} diff --git a/database/migrations/2020_01_29_152709_create_participant_table.php b/database/migrations/2020_01_29_152709_create_participant_table.php new file mode 100644 index 0000000..4f44e21 --- /dev/null +++ b/database/migrations/2020_01_29_152709_create_participant_table.php @@ -0,0 +1,52 @@ +bigIncrements('id'); + $table->bigInteger('booking_id')->nullable(); + $table->string('participant_name', 255)->nullable(); + $table->string('participant_firstname', 255)->nullable(); + $table->date('participant_birthdate')->nullable(); + $table->bigInteger('participant_salutation_id')->nullable(); + $table->tinyInteger('participant_child')->nullable()->default(0); + + $table->index('booking_id', 'participant_booking_id_idx'); + $table->index('participant_salutation_id', 'participant_participant_salutation_id_idx'); + + $table->foreign('booking_id', 'participant_booking_id_booking_id')->references('id')->on('booking')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + $table->foreign('participant_salutation_id', 'participant_participant_salutation_id_salutation_id')->references('id')->on('salutation')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('participant'); + } +} diff --git a/database/migrations/2020_01_29_153723_create_arrangement_table.php b/database/migrations/2020_01_29_153723_create_arrangement_table.php new file mode 100644 index 0000000..292c48f --- /dev/null +++ b/database/migrations/2020_01_29_153723_create_arrangement_table.php @@ -0,0 +1,56 @@ +bigIncrements('id'); + $table->bigInteger('template_id')->nullable(); + $table->date('state')->nullable(); + $table->date('begin')->nullable(); + $table->date('end')->nullable(); + $table->string('type_s', 255)->nullable(); + $table->text('data_s')->nullable(); + $table->bigInteger('view_position')->nullable(); + $table->bigInteger('booking_id')->nullable(); + $table->bigInteger('type_id'); + $table->tinyInteger('in_pdf')->nullable()->default(0); + + $table->index('template_id', 'arrangement_template_id_idx'); + $table->index('booking_id', 'arrangement_booking_id_idx'); + + $table->foreign('booking_id', 'arrangement_booking_id_booking_id')->references('id')->on('booking')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + $table->foreign('template_id', 'arrangement_template_id_arrangement_template_id')->references('id')->on('arrangement_template')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('arrangement'); + } +} diff --git a/database/migrations/2020_01_29_153723_create_arrangement_template_table.php b/database/migrations/2020_01_29_153723_create_arrangement_template_table.php new file mode 100644 index 0000000..f2760ba --- /dev/null +++ b/database/migrations/2020_01_29_153723_create_arrangement_template_table.php @@ -0,0 +1,43 @@ +bigIncrements('id'); + $table->string('title', 130)->nullable(); + + + + + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('arrangement_template'); + } +} diff --git a/database/migrations/2020_01_29_153723_create_arrangement_type_table.php b/database/migrations/2020_01_29_153723_create_arrangement_type_table.php new file mode 100644 index 0000000..1753003 --- /dev/null +++ b/database/migrations/2020_01_29_153723_create_arrangement_type_table.php @@ -0,0 +1,48 @@ +bigIncrements('id'); + $table->string('name', 80); + $table->bigInteger('notify_rel_days')->nullable()->default(-19); + $table->bigInteger('arrangement_type_id')->nullable()->default(4); + $table->tinyInteger('is_unique')->nullable()->default(0); + $table->bigInteger('notify_rel_field_key')->nullable()->default(1); + + $table->index('arrangement_type_id', 'arrangement_type_arrangement_type_id_idx'); + + $table->foreign('arrangement_type_id', 'arrangement_type_arrangement_type_id_arrangement_type_id')->references('id')->on('arrangement_type')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('arrangement_type'); + } +} diff --git a/database/migrations/2020_01_29_154358_create_booking_service_item_table.php b/database/migrations/2020_01_29_154358_create_booking_service_item_table.php new file mode 100644 index 0000000..f2c8c48 --- /dev/null +++ b/database/migrations/2020_01_29_154358_create_booking_service_item_table.php @@ -0,0 +1,56 @@ +bigIncrements('id'); + $table->bigInteger('booking_id'); + $table->bigInteger('travel_company_id'); + $table->decimal('service_price', 10, 2)->default(0.00); + $table->decimal('service_price_refund', 10, 2)->nullable()->default(0.00); + $table->decimal('commission', 10, 2)->default(0.00); + $table->date('travel_date'); + $table->dateTime('created_at'); + $table->dateTime('updated_at'); + $table->string('name', 255)->nullable(); + $table->tinyInteger('is_commission_locked')->default(0); + + $table->index('travel_company_id', 'travel_company_id_idx'); + $table->index('booking_id', 'booking_id_idx'); + + $table->foreign('booking_id', 'booking_service_item_booking_id_booking_id')->references('id')->on('booking')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + $table->foreign('travel_company_id', 'booking_service_item_travel_company_id_travel_company_id')->references('id')->on('travel_company')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('booking_service_item'); + } +} diff --git a/database/migrations/2020_01_29_154619_create_travel_company_table.php b/database/migrations/2020_01_29_154619_create_travel_company_table.php new file mode 100644 index 0000000..6a6e6ee --- /dev/null +++ b/database/migrations/2020_01_29_154619_create_travel_company_table.php @@ -0,0 +1,42 @@ +bigIncrements('id'); + $table->string('name', 255); + $table->decimal('percentage', 6, 2)->nullable(); + $table->tinyInteger('is_allowed_edit_commission')->nullable()->default(0); + $table->tinyInteger('is_inhouse')->nullable()->default(0); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('travel_company'); + } +} diff --git a/database/migrations/2020_02_04_160054_create_service_provider_table.php b/database/migrations/2020_02_04_160054_create_service_provider_table.php new file mode 100644 index 0000000..e9d3c90 --- /dev/null +++ b/database/migrations/2020_02_04_160054_create_service_provider_table.php @@ -0,0 +1,45 @@ +bigIncrements('id'); + $table->string('name', 255); + $table->unsignedTinyInteger('dollar')->nullable()->default(0); + $table->string('type', 255)->nullable(); + + $table->index('type', 'service_provider_type_idx'); + + + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('service_provider'); + } +} diff --git a/database/migrations/2020_02_04_160055_create_service_provider_entry_table.php b/database/migrations/2020_02_04_160055_create_service_provider_entry_table.php new file mode 100644 index 0000000..39858b9 --- /dev/null +++ b/database/migrations/2020_02_04_160055_create_service_provider_entry_table.php @@ -0,0 +1,58 @@ +bigIncrements('id'); + $table->bigInteger('booking_id'); + $table->bigInteger('service_provider_id'); + $table->decimal('amount', 10, 2); + $table->decimal('amount_eur', 10, 2)->nullable()->default(0.00); + $table->decimal('factor', 6, 4)->nullable()->default(1.0000); + $table->date('payment_date')->nullable(); + $table->string('invoice_number', 255)->nullable(); + $table->tinyInteger('is_cleared')->nullable()->default(0); + $table->dateTime('created_at'); + $table->dateTime('updated_at'); + $table->string('type', 255)->nullable(); + + $table->index('booking_id', 'service_provider_payment_booking_id_idx'); + $table->index('service_provider_id', 'service_provider_payment_service_provider_id_idx'); + $table->index('type', 'service_provider_payment_type_idx'); + + $table->foreign('booking_id', 'service_provider_payment_booking_id_booking_id')->references('id')->on('booking')->onDelete('CASCADE +')->onUpdate('RESTRICT'); + $table->foreign('service_provider_id', 'service_provider_payment_service_provider_id_service_provider_id')->references('id')->on('service_provider')->onDelete('RESTRICT +')->onUpdate('RESTRICT'); + + }); + + + + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('service_provider_entry'); + } +} diff --git a/packages/iqcontent/laravel-filemanager/src/views/index.blade.php b/packages/iqcontent/laravel-filemanager/src/views/index.blade.php index 6601a06..5fbdf50 100644 --- a/packages/iqcontent/laravel-filemanager/src/views/index.blade.php +++ b/packages/iqcontent/laravel-filemanager/src/views/index.blade.php @@ -87,7 +87,7 @@
- + {{ trans('laravel-filemanager::lfm.message-empty') }}
diff --git a/public/.htaccess b/public/.htaccess index b75525b..0cf4840 100755 --- a/public/.htaccess +++ b/public/.htaccess @@ -1,3 +1,16 @@ + + AddOutputFilterByType DEFLATE text/plain + AddOutputFilterByType DEFLATE text/html + AddOutputFilterByType DEFLATE text/xml + AddOutputFilterByType DEFLATE text/shtml + AddOutputFilterByType DEFLATE text/css + AddOutputFilterByType DEFLATE application/xml + AddOutputFilterByType DEFLATE application/xhtml+xml + AddOutputFilterByType DEFLATE application/rss+xml + AddOutputFilterByType DEFLATE application/javascript + AddOutputFilterByType DEFLATE application/x-javascript + + Options -MultiViews -Indexes diff --git a/resources/views/_empty.blade.php b/resources/views/_empty.blade.php new file mode 100755 index 0000000..614d508 --- /dev/null +++ b/resources/views/_empty.blade.php @@ -0,0 +1,36 @@ +@extends('layouts.layout-2') + +@section('content') + + @if ($errors->any()) +
+
+
+
    + @foreach ($errors->all() as $error) +
  • {{ $error }}
  • + @endforeach +
+
+
+
+ @endif + + + +
+

{{ $text }}

+
+ +{{-- +
+

{{__('Delete') }}

+

{{__('If you no longer want to use our offer, you can delete your account here.')}}

+ {{__('Delete Account')}} +
+ --}} + + +@endsection diff --git a/resources/views/admin/report/index.blade.php b/resources/views/admin/report/index.blade.php new file mode 100755 index 0000000..6f6b203 --- /dev/null +++ b/resources/views/admin/report/index.blade.php @@ -0,0 +1,122 @@ +@extends('layouts.layout-2') + +@section('content') +

+ Leistungsträger-Zahlungen + zurück ins v1 CRM +

+
+ {!! Form::open(['url' => route('admin_report_export_providers'), 'class' => '']) !!} + +
+
+
+ + +
+
+ +
+
+
+ von +
+ +
+ +
+
+ bis +
+ +
+
+
+
+ + +
+
+ + + +
+
+
+ +
+ + + + + + + + + + + + + +
ID{{__('Reiseveranstalter')}}{{__('MyJack Nr.')}}{{__('Reisepreis')}}{{__('Erlös')}}{{__('Kunde')}}{{__('Reisedatum')}}{{__('bezahlt')}}
+ +
+ + +
+
+ {!! Form::close() !!} +
+ + +@endsection \ No newline at end of file diff --git a/resources/views/booking/_detail.blade.php b/resources/views/booking/_detail.blade.php index f7782a2..971b857 100644 --- a/resources/views/booking/_detail.blade.php +++ b/resources/views/booking/_detail.blade.php @@ -53,7 +53,7 @@ @php($i = 1)
- +
@foreach($booking->booking_draft_items as $booking_draft_item) @@ -133,7 +133,7 @@
- +
- +

@@ -233,7 +233,7 @@
- +

@@ -259,7 +259,7 @@ {{ Form::text('infos[office-important-note][val]', \App\Models\CMSInfo::getContentBySlug('office-important-note'), array('placeholder'=>__('Weihnachtsferien! Vom 23.12.2019 bis zum 28.12.2019 sind wir nur zu den genannten Zeiten telefonisch zu erreichen.'), 'class'=>'form-control', 'id'=>'office_important_note')) }} - {{ Form::hidden('infos[office-important-note][type]', 'text') }} + {{ Form::hidden('infos[office-important-note][type]', 'full_text') }}
diff --git a/resources/views/cms/feedback/index.blade.php b/resources/views/cms/feedback/index.blade.php index 2863165..f09319a 100755 --- a/resources/views/cms/feedback/index.blade.php +++ b/resources/views/cms/feedback/index.blade.php @@ -27,7 +27,7 @@ - + {{ $value->title }} @@ -36,14 +36,14 @@ @if($value->status) - + @else - + @endif @if($value->parent) - + @else - @endif diff --git a/resources/views/cms/sidebar/index.blade.php b/resources/views/cms/sidebar/index.blade.php index cd7f590..99259e9 100755 --- a/resources/views/cms/sidebar/index.blade.php +++ b/resources/views/cms/sidebar/index.blade.php @@ -27,7 +27,7 @@ - + @@ -39,13 +39,13 @@ @if($value->active) - + @else - + @endif - + @endforeach diff --git a/resources/views/cms/travel_guide/detail.blade.php b/resources/views/cms/travel_guide/detail.blade.php index 0039929..5e37b11 100755 --- a/resources/views/cms/travel_guide/detail.blade.php +++ b/resources/views/cms/travel_guide/detail.blade.php @@ -94,7 +94,7 @@ - + {{$iq_content_site->iq_content_tree_node->name}} @@ -102,13 +102,13 @@ @if($iq_content_site->iq_content_tree_node->active) - + @else - + @endif - + @endforeach diff --git a/resources/views/cms/travel_guide/index.blade.php b/resources/views/cms/travel_guide/index.blade.php index 30888ec..37a78b1 100755 --- a/resources/views/cms/travel_guide/index.blade.php +++ b/resources/views/cms/travel_guide/index.blade.php @@ -28,7 +28,7 @@ - + {{ $value->name }} @@ -37,20 +37,20 @@ @if($value->scope) - + @else - + @endif @if($value->active) - + @else - + @endif - + @endforeach diff --git a/resources/views/cms/travel_guide/page.blade.php b/resources/views/cms/travel_guide/page.blade.php index b4bd60a..05c3659 100755 --- a/resources/views/cms/travel_guide/page.blade.php +++ b/resources/views/cms/travel_guide/page.blade.php @@ -29,7 +29,7 @@ - + @@ -43,21 +43,21 @@ {{ $value->keyword }} @if($value->show_in_navi) - + @else - + @endif @if($value->status) - + @else - + @endif {{ $value->order }} - {{-- --}} + {{-- --}} diff --git a/resources/views/cms/travel_guide/tree-detail.blade.php b/resources/views/cms/travel_guide/tree-detail.blade.php index cb54889..553aef8 100755 --- a/resources/views/cms/travel_guide/tree-detail.blade.php +++ b/resources/views/cms/travel_guide/tree-detail.blade.php @@ -70,13 +70,13 @@
{{$model->name}} + class="fa fa-globe"> {{$model->name}} + data-route="{{ route('iq_content_modal_load') }}">
{!! \App\Services\HTMLTreeHelper::makeNestableList($model, ($tree_node ? $tree_node->id : false)) !!} @@ -134,7 +134,7 @@
+ class="fa fa-link mr-2 text-primary">
{{ Form::text('uri', $tree_node->getUri(), array('readonly'=>true, 'class'=>'form-control')) }}
@@ -180,33 +180,33 @@ - + {{$iq_content_site->travel_guide->name}} {{$iq_content_site->travel_guide->keyword}} @if($iq_content_site->travel_guide->scope) + class="fa fa-check"> @else + class="fa fa-times"> @endif @if($iq_content_site->travel_guide->active) + class="fa fa-check"> @else + class="fa fa-times"> @endif + class="fa fa-reply"> @endforeach @@ -221,12 +221,18 @@ --}}
-
+
{{ Form::text('identifier', $tree_node->identifier, array('placeholder'=>'', 'class'=>'form-control')) }}
+
+
+ + {{ Form::text('title', $tree_node->title, array('placeholder'=>'META-Titel', 'class'=>'form-control')) }} +
+
{{ Form::textarea('description', $tree_node->description, array('class'=>'form-control', 'rows'=>2)) }} diff --git a/resources/views/cms/travel_guide/tree.blade.php b/resources/views/cms/travel_guide/tree.blade.php index 5b13487..eed8baa 100755 --- a/resources/views/cms/travel_guide/tree.blade.php +++ b/resources/views/cms/travel_guide/tree.blade.php @@ -34,7 +34,7 @@ - + {{ $model->name }} diff --git a/resources/views/drafts/_detail.blade.php b/resources/views/drafts/_detail.blade.php index 4f93b97..884ebe2 100755 --- a/resources/views/drafts/_detail.blade.php +++ b/resources/views/drafts/_detail.blade.php @@ -105,7 +105,7 @@   {{ __('back') }}
- +
@@ -151,7 +151,7 @@
- +
@else
- +
  diff --git a/resources/views/drafts/detail.blade.php b/resources/views/drafts/detail.blade.php index d555bc5..9da458a 100755 --- a/resources/views/drafts/detail.blade.php +++ b/resources/views/drafts/detail.blade.php @@ -140,7 +140,7 @@   {{ __('back') }}
- +
@@ -211,7 +211,7 @@ - + draft_type) style="background-color: {{ $draft_item->draft_type->color }}" @endif class="border-none"> @@ -316,7 +316,7 @@
@else
- +
  diff --git a/resources/views/drafts/index.blade.php b/resources/views/drafts/index.blade.php index 3261c08..812d233 100755 --- a/resources/views/drafts/index.blade.php +++ b/resources/views/drafts/index.blade.php @@ -32,19 +32,19 @@ - + {{ $value->name }} @if($value->active) - + @else - + @endif - + @endforeach @@ -96,7 +96,7 @@ data-color="{{ $value->color }}" data-active="{{ $value->active }}" data-pos="{{ $value->pos }}"> - + {{ $value->pos }} @@ -111,12 +111,12 @@ @if($value->active) - + @else - + @endif - + @endforeach diff --git a/resources/views/iq/content/assets/index.blade.php b/resources/views/iq/content/assets/index.blade.php index abeafa2..267a00c 100755 --- a/resources/views/iq/content/assets/index.blade.php +++ b/resources/views/iq/content/assets/index.blade.php @@ -132,7 +132,7 @@
- + {{ trans('laravel-filemanager::lfm.message-empty') }}
diff --git a/resources/views/layouts/includes/layout-sidenav.blade.php b/resources/views/layouts/includes/layout-sidenav.blade.php index 580a71f..4e57987 100755 --- a/resources/views/layouts/includes/layout-sidenav.blade.php +++ b/resources/views/layouts/includes/layout-sidenav.blade.php @@ -186,39 +186,60 @@ @if(Auth::user()->isSuperAdmin())
  • SUPERADMIN
  • + @if(Auth::user()->isPermission('sua-st')) +
  • + + +
    Einstellungen
    +
    + +
  • + @endif - @if(Auth::user()->isPermission('sua-st')) -
  • - - -
    Einstellungen
    -
    - -
  • - @endif - @if(Auth::user()->isPermission('sua-ur-rt')) -
  • -
    {{ __('User Rechte') }}
    -
  • + @if(Auth::user()->isPermission('sua-re')) +
  • + + +
    Reporting
    +
    + +
  • @endif + @if(Auth::user()->isPermission('sua-ur-rt')) +
  • +
    {{ __('User Rechte') }}
    +
  • + @endif + {{--
  • @@ -255,6 +276,28 @@ @endif + + @if(Auth::user()->isSySAdmin()) +
  • +
  • SYSADMIN
  • + +
  • + + +
    {{ __('Tools') }}
    +
    + + +
  • + @endif +
  • diff --git a/resources/views/request/index.blade.php b/resources/views/request/index.blade.php index 1d39646..ce0595f 100755 --- a/resources/views/request/index.blade.php +++ b/resources/views/request/index.blade.php @@ -56,6 +56,23 @@
  • +
    +
    + + +
    +
    + + +
    +
    @@ -76,7 +93,7 @@
    @@ -99,8 +116,8 @@ {{__('Vorname')}} {{__('Nachname')}} {{__('BookingID')}} - {{__('Land')}} - {{__('Reise')}} + {{__('Reiseland')}} + {{__('Programm')}} {{__('Anreise')}} {{__('Abreise')}} {{__('Reiseunterlage')}} @@ -115,6 +132,8 @@ diff --git a/resources/views/settings/travel_agenda/index.blade.php b/resources/views/settings/travel_agenda/index.blade.php index 24996a2..1f3ca11 100755 --- a/resources/views/settings/travel_agenda/index.blade.php +++ b/resources/views/settings/travel_agenda/index.blade.php @@ -28,7 +28,7 @@ data-name="{{ $value->name }}" data-active="{{ $value->active }}" data-travelcountry_id="{{$value->travelcountry_id}}"> - + {{ $value->name }} @@ -36,12 +36,12 @@ @if($value->active) - + @else - + @endif - + @endforeach diff --git a/resources/views/settings/travel_country/detail.blade.php b/resources/views/settings/travel_country/detail.blade.php index 2f1d8b7..fe47006 100755 --- a/resources/views/settings/travel_country/detail.blade.php +++ b/resources/views/settings/travel_country/detail.blade.php @@ -28,21 +28,21 @@
    diff --git a/resources/views/settings/travel_country/index.blade.php b/resources/views/settings/travel_country/index.blade.php index 95767e2..a408e5a 100755 --- a/resources/views/settings/travel_country/index.blade.php +++ b/resources/views/settings/travel_country/index.blade.php @@ -17,9 +17,9 @@ {{__('Name')}} {{__('Slug')}} - {{__('Seite')}} - {{__('CRM')}} - {{__('Kunden')}} + {{__('Seite')}} + {{__('CRM')}} + {{__('Kunden')}} # @@ -28,34 +28,34 @@ - + {{ $value->name }} {{ $value->slug }} @if($value->active_frontend) - + @else - + @endif @if($value->active_backend) - + @else - + @endif @if($value->is_customer_country) - + @else - + @endif - + diff --git a/resources/views/settings/travel_nationality/index.blade.php b/resources/views/settings/travel_nationality/index.blade.php index b918bc3..418e6d8 100755 --- a/resources/views/settings/travel_nationality/index.blade.php +++ b/resources/views/settings/travel_nationality/index.blade.php @@ -27,18 +27,18 @@ data-id="{{ $value->id }}" data-name="{{ $value->name }}" data-active="{{ $value->active }}"> - + {{ $value->name }} @if($value->active) - + @else - + @endif - + @endforeach diff --git a/resources/views/sys/tools/links.blade.php b/resources/views/sys/tools/links.blade.php new file mode 100755 index 0000000..e91ed68 --- /dev/null +++ b/resources/views/sys/tools/links.blade.php @@ -0,0 +1,50 @@ +@extends('layouts.layout-2') + +@section('content') + + @if ($errors->any()) +
    +
    +
    +
      + @foreach ($errors->all() as $error) +
    • {{ $error }}
    • + @endforeach +
    +
    +
    +
    + @endif + + +

    + Content Tools: Links +

    + + +
    + +
    + + {!! Form::open(['url' => route('sysadmin_tools_content_links'), 'class' => '']) !!} +
    + + {{ Form::textarea('text', $text, array('class'=>'form-control', 'rows'=>20)) }} +
    + + + {!! Form::close() !!} +
    + + @if(count($values)>0) +
    + + @foreach($values as $key=>$value) + {{ $key }} || {{$value}}
    + @endforeach +
    + @endif +
    + +@endsection + diff --git a/resources/views/sys/tools/trees.blade.php b/resources/views/sys/tools/trees.blade.php new file mode 100755 index 0000000..3a3f491 --- /dev/null +++ b/resources/views/sys/tools/trees.blade.php @@ -0,0 +1,50 @@ +@extends('layouts.layout-2') + +@section('content') + + @if ($errors->any()) +
    +
    +
    +
      + @foreach ($errors->all() as $error) +
    • {{ $error }}
    • + @endforeach +
    +
    +
    +
    + @endif + + +

    + Content Tools: Links +

    + + +
    + +
    + + {!! Form::open(['url' => route('sysadmin_tools_tree_title'), 'class' => '']) !!} +
    + + {{ Form::textarea('text', $text, array('class'=>'form-control', 'rows'=>20)) }} +
    + + + {!! Form::close() !!} +
    + + @if(count($values)>0) +
    + + @foreach($values as $key=>$value) + {{ $key }} || {{$value}}
    + @endforeach +
    + @endif +
    + +@endsection + diff --git a/resources/views/travel/program/detail.blade.php b/resources/views/travel/program/detail.blade.php index c834c14..d696875 100755 --- a/resources/views/travel/program/detail.blade.php +++ b/resources/views/travel/program/detail.blade.php @@ -75,17 +75,17 @@ data-name="{{ $value->name }}" data-description="{{ $value->description }}" data-standard="{{ $value->standard }}"> - + {{ $value->name }} @if($value->standard) - + @else - + @endif - + @endforeach @@ -127,7 +127,7 @@ data-travel_class_id="{{ $value->travel_class_id }}" data-draft_id="{{ $value->draft_id }}" data-weekdays="{{ json_encode($value->weekdays) }}"> - + {{ $value->draft->name }} @@ -140,7 +140,7 @@ {!! HTMLHelper::getWeekdaysString($value->weekdays) !!} - + @endforeach diff --git a/resources/views/travel/program/index.blade.php b/resources/views/travel/program/index.blade.php index 168b8e3..e8a118f 100755 --- a/resources/views/travel/program/index.blade.php +++ b/resources/views/travel/program/index.blade.php @@ -35,7 +35,7 @@ - + {{ $value->title }} @@ -44,9 +44,9 @@ @if($value->status) - + @else - + @endif @@ -92,18 +92,18 @@ data-id="{{ $value->id }}" data-name="{{ $value->name }}" data-active="{{ $value->active }}"> - + {{ $value->name }} @if($value->active) - + @else - + @endif - + @endforeach diff --git a/resources/views/travel/user/detail.blade.php b/resources/views/travel/user/detail.blade.php index 6830a76..b2543bc 100755 --- a/resources/views/travel/user/detail.blade.php +++ b/resources/views/travel/user/detail.blade.php @@ -55,7 +55,7 @@ @foreach($travel_user->travel_user_booking_fewos as $travel_user_booking_fewo) - + {{ $travel_user_booking_fewo->id }} {{ $travel_user_booking_fewo->fewo_lodging->name }} diff --git a/routes/api.php b/routes/api.php index 1c3ad57..4569657 100755 --- a/routes/api.php +++ b/routes/api.php @@ -21,11 +21,14 @@ Route::post('cms/header/info', 'API\CMSContentInfoController@headerInfo'); Route::get('cms/header/info', 'API\CMSContentInfoController@headerInfo'); + +Route::post('booking/import', 'API\BookingController@import'); +Route::get('booking/import', 'API\BookingController@import'); + + Route::group(['middleware' => 'auth:api'], function(){ Route::post('details', 'API\UserController@details'); Route::post('draft/{action}', 'API\DraftController@draft'); Route::post('load/{action}', 'API\LoaderController@load'); Route::post('fewo/{action}', 'API\FewoController@action'); - - }); \ No newline at end of file diff --git a/routes/web.php b/routes/web.php index ad0c9c0..5b3a625 100755 --- a/routes/web.php +++ b/routes/web.php @@ -188,7 +188,8 @@ Route::group(['middleware' => ['admin']], function() //Buchungen > Anfragen Route::get('/requests/{step?}', 'RequestController@index')->name('requests'); //Route::get('/lead/detail/{id}', 'LeadController@detail')->name('lead_detail'); - Route::get('data/table/requests', 'DataTableController@getRequests')->name('data_table_requests'); + Route::get('data/table/requests', 'RequestController@getRequests')->name('data_table_requests'); + Route::post('data/ajax/requests', 'RequestController@getAjaxRequests')->name('data_ajax_requests'); }); Route::group(['middleware' => ['auth.permission:crm-bo-bo']], function() { @@ -299,6 +300,23 @@ Route::group(['middleware' => ['superadmin']], function() { Route::post('/admin/settings/travel/nationality/update', 'Settings\TravelNationalityController@update')->name('admin_settings_travel_nationality_update'); Route::get('/admin/settings/travel/nationality/delete/{id}', 'Settings\TravelNationalityController@delete')->name('admin_settings_travel_nationality_delete'); }); + + Route::group(['middleware' => ['auth.permission:sua-re-bo']], function() { + //SUPERADMIN > report > Buchungen + Route::get('/admin/report/bookings', 'Admin\ReportController@bookings')->name('admin_report_bookings'); + // Route::get('datatables/leads', 'DataTableController@getLeads')->name('datatables-leads'); + + }); + + Route::group(['middleware' => ['auth.permission:sua-re-pp']], function() { + //SUPERADMIN > report > Buchungen + Route::get('/admin/report/providers', 'Admin\ReportController@providers')->name('admin_report_providers'); + Route::get('/admin/report/datatable/providers', 'Admin\ReportController@providersDatatable')->name('admin_report_providers_datatable'); + Route::post('/admin/report/export/providers/', 'Admin\ReportController@providersExport')->name('admin_report_export_providers'); + + + }); + Route::group(['middleware' => ['auth.permission:sua-ur-rt']], function() { //SUPERADMIN > User Rechte Route::get('/admin/users', 'AdminUserController@index')->name('admin_users'); @@ -317,13 +335,19 @@ Route::group(['middleware' => ['superadmin']], function() { Route::post('/admin/users/update/modal/{step}', 'AdminUserController@updateModal')->name('admin_user_update_modal'); }); - - Route::get('/iq/tools/content/links', 'IQ\Tools\ContentLinkController@index')->name('iq_tools_content_links'); - Route::post('/iq/tools/content/links', 'IQ\Tools\ContentLinkController@store')->name('iq_tools_content_links'); - - }); +//login pages for sysadmin +Route::group(['middleware' => ['sysadmin']], function() { + Route::get('/sysadmin/tools/content_links', 'SyS\Tools\ContentLinkController@index')->name('sysadmin_tools_content_links'); + Route::post('/sysadmin/tools/content_links', 'SyS\Tools\ContentLinkController@store')->name('sysadmin_tools_content_links'); + + Route::get('/sysadmin/tools/tree_title', 'SyS\Tools\ContentLinkController@treeTitle')->name('sysadmin_tools_tree_title'); + Route::post('/sysadmin/tools/tree_title', 'SyS\Tools\ContentLinkController@treeTitleStore')->name('sysadmin_tools_tree_title'); +}); + + + use App\Mail\MailResetPassword;