from django.urls import path
from . import views

app_name = 'hosting_app'

urlpatterns = [
    path('', views.home_hosting, name='home_hosting'),

    path('about/', views.about_us_hosting, name='about_us_hosting'),
    path('terms-and-conditions/', views.terms_conditions, name='terms_conditions'),
    path('faq/', views.faq, name='faq'),
    path('privacy-policy/', views.privacy_policy, name='privacy_policy'),
    path('refund-payment-policy/', views.refund_payment_policy, name='refund_payment_policy'),
    path('disclaimer/', views.disclaimer, name='disclaimer'),
    path('cookie-policy/', views.cookie_policy, name='cookie_policy'),


    path('contact/', views.contact_page, name='contact_page'),
    path('success/', views.success_page, name='success_page'),

    path('host-signup/', views.host_signup, name='host_signup'),
    path('host-login/', views.HostLoginView.as_view(), name='host_login'),
    path(
        'client-login/',
        views.HostingClientLoginView.as_view(),
        name='hosting_client_login'
    ),
    path(
        'switch-portal/<str:portal>/',
        views.switch_hosting_portal,
        name='switch_hosting_portal'
    ),
    path('host-dashboard/', views.host_dashboard, name='host_dashboard'),
    
    # Hosting Partner Profile
    path('profile/', views.host_profile_page, name='host_profile_page'),
    path('profile/edit/', views.edit_host_profile, name='edit_host_profile'),
    path('profile/upload-image/', views.upload_host_profile_image, name='upload_host_profile_image'),
    path('profile/change-username/', views.change_host_username, name='change_host_username'),
    path('profile/change-password/', views.change_host_password, name='change_host_password'),

    # Hosting Partner Password Reset
    path(
        'password-reset/',
        views.HostPasswordResetView.as_view(),
        name='host_password_reset'
    ),

    path(
        'password-reset/done/',
        views.HostPasswordResetDoneView.as_view(),
        name='host_password_reset_done'
    ),

    path(
        'reset/<uidb64>/<token>/',
        views.HostPasswordResetConfirmView.as_view(),
        name='host_password_reset_confirm'
    ),

    path(
        'reset/done/',
        views.HostPasswordResetCompleteView.as_view(),
        name='host_password_reset_complete'
    ),

    # ============================================================
    # Host Venue Management
    # ============================================================

    path(
        'venues/',
        views.host_venue_list,
        name='host_venue_list'
    ),

    path(
        'venues/create/',
        views.host_venue_create,
        name='host_venue_create'
    ),

    path(
        'venues/<slug:slug>/',
        views.host_venue_detail,
        name='host_venue_detail'
    ),

    path(
        'venues/<slug:slug>/edit/',
        views.host_venue_update,
        name='host_venue_update'
    ),

    path(
        'venues/<slug:slug>/gallery/',
        views.host_venue_gallery_manage,
        name='host_venue_gallery_manage'
    ),

    path(
        'venue-gallery/<int:pk>/delete/',
        views.host_venue_gallery_delete,
        name='host_venue_gallery_delete'
    ),

    # ============================================================
    # Public Host Venue Listings
    # ============================================================

    path(
        'public-hosts/',
        views.public_host_venue_list,
        name='public_host_venue_list'
    ),

    path(
        'public-hosts/<slug:slug>/',
        views.public_host_venue_detail,
        name='public_host_venue_detail'
    ),
    
    # ============================================================
    # Host Event Package Management
    # ============================================================

    path(
        'event-packages/',
        views.host_event_package_list,
        name='host_event_package_list'
    ),

    path(
        'event-packages/create/',
        views.host_event_package_create,
        name='host_event_package_create'
    ),

    path(
        'venues/<slug:venue_slug>/event-packages/create/',
        views.host_event_package_create_for_venue,
        name='host_event_package_create_for_venue'
    ),

    path(
        'event-packages/<slug:slug>/',
        views.host_event_package_detail,
        name='host_event_package_detail'
    ),

    path(
        'event-packages/<slug:slug>/edit/',
        views.host_event_package_update,
        name='host_event_package_update'
    ),

    # ============================================================
    # Host Meal Plan Management
    # ============================================================

    path(
        'meal-plans/',
        views.host_meal_plan_list,
        name='host_meal_plan_list'
    ),

    path(
        'meal-plans/create/',
        views.host_meal_plan_create,
        name='host_meal_plan_create'
    ),

    path(
        'venues/<slug:venue_slug>/meal-plans/create/',
        views.host_meal_plan_create_for_venue,
        name='host_meal_plan_create_for_venue'
    ),

    path(
        'meal-plans/<int:pk>/',
        views.host_meal_plan_detail,
        name='host_meal_plan_detail'
    ),

    path(
        'meal-plans/<int:pk>/edit/',
        views.host_meal_plan_update,
        name='host_meal_plan_update'
    ),

    # ============================================================
    # Host Add-on Service Management
    # ============================================================

    path(
        'add-on-services/',
        views.host_add_on_service_list,
        name='host_add_on_service_list'
    ),

    path(
        'add-on-services/create/',
        views.host_add_on_service_create,
        name='host_add_on_service_create'
    ),

    path(
        'venues/<slug:venue_slug>/add-on-services/create/',
        views.host_add_on_service_create_for_venue,
        name='host_add_on_service_create_for_venue'
    ),

    path(
        'add-on-services/<int:pk>/',
        views.host_add_on_service_detail,
        name='host_add_on_service_detail'
    ),

    path(
        'add-on-services/<int:pk>/edit/',
        views.host_add_on_service_update,
        name='host_add_on_service_update'
    ),

    # Hosting Partner Banking Details
    path(
        'host/banking-details/',
        views.host_banking_details,
        name='host_banking_details'
    ),
    # ============================================================
    # Hosting Partner Payment Center
    # ============================================================

    path(
        'host/payment-center/',
        views.host_payment_center,
        name='host_payment_center'
    ),

    path(
        'host/payment-checkout/',
        views.host_payment_checkout,
        name='host_payment_checkout'
    ),

    path(
        'host/payment-checkout/pay/',
        views.host_payment_checkout_pay,
        name='host_payment_checkout_pay'
    ),

    path(
        'host/start-stripe/',
        views.start_hosting_partner_stripe_checkout,
        name='start_hosting_partner_stripe_checkout'
    ),

    path(
        'host/start-paypal/',
        views.start_hosting_partner_paypal_checkout,
        name='start_hosting_partner_paypal_checkout'
    ),

    path(
        'host/paypal-payment-success/<int:transaction_id>/',
        views.hosting_partner_paypal_payment_success,
        name='hosting_partner_paypal_payment_success'
    ),

    path(
        'host/stripe-payment-success/<int:transaction_id>/',
        views.hosting_partner_stripe_payment_success,
        name='hosting_partner_stripe_payment_success'
    ),

    path(
        'host/payment-success/<int:transaction_id>/',
        views.host_payment_success,
        name='host_payment_success'
    ),

    path(
        'host/payment-cancelled/<int:transaction_id>/',
        views.host_payment_cancelled,
        name='host_payment_cancelled'
    ),

    path(
        'host/payment-failed/<int:transaction_id>/',
        views.host_payment_failed,
        name='host_payment_failed'
    ),
    # ============================================================
    # Host Booking Management
    # ============================================================

    path(
        'bookings/',
        views.host_booking_list,
        name='host_booking_list'
    ),

    path(
        'bookings/<int:pk>/',
        views.host_booking_detail,
        name='host_booking_detail'
    ),

    # ============================================================
    # Local Client / Public Booking Flow
    # ============================================================

    path(
        'client/start/<slug:venue_slug>/',
        views.local_client_booking_entry,
        name='local_client_booking_entry'
    ),

    path(
        'client/signup/<slug:venue_slug>/',
        views.local_client_signup,
        name='local_client_signup'
    ),

    path(
        'client/dashboard/',
        views.hosting_client_dashboard,
        name='hosting_client_dashboard'
    ),

    path(
        'client/book/<slug:venue_slug>/',
        views.local_client_booking_start,
        name='local_client_booking_start'
    ),

    path(
        'client/bookings/<int:booking_id>/review/',
        views.local_client_booking_review,
        name='local_client_booking_review'
    ),
    path(
        'client/bookings/',
        views.hosting_client_booking_list,
        name='hosting_client_booking_list'
    ),
    path(
        'client/payment-center/',
        views.hosting_client_payment_center,
        name='hosting_client_payment_center'
    ),

    # ============================================================
    # Hosting Client Payment / Checkout
    # ============================================================

    path(
        'client/payment-checkout/',
        views.hosting_client_payment_checkout,
        name='hosting_client_payment_checkout'
    ),

    path(
        'client/payment-checkout/pay/',
        views.hosting_client_payment_checkout_pay,
        name='hosting_client_payment_checkout_pay'
    ),

    path(
        'client/start-stripe/',
        views.start_hosting_client_stripe_checkout,
        name='start_hosting_client_stripe_checkout'
    ),
    path(
        'client/stripe-payment-success/<int:transaction_id>/',
        views.hosting_client_stripe_payment_success,
        name='hosting_client_stripe_payment_success'
    ),

    path(
        'client/payment-success/<int:transaction_id>/',
        views.hosting_client_payment_success,
        name='hosting_client_payment_success'
    ),

    path(
        'client/payment-cancelled/<int:transaction_id>/',
        views.hosting_client_payment_cancelled,
        name='hosting_client_payment_cancelled'
    ),

    path(
        'client/payment-failed/<int:transaction_id>/',
        views.hosting_client_payment_failed,
        name='hosting_client_payment_failed'
    ),


    path(
        'client/start-paypal/',
        views.start_hosting_client_paypal_checkout,
        name='start_hosting_client_paypal_checkout'
    ),

    path(
        'client/paypal-payment-success/<int:transaction_id>/',
        views.hosting_client_paypal_payment_success,
        name='hosting_client_paypal_payment_success'
    ),

    # Hosting Client Profile
    path(
        'client/profile/',
        views.hosting_client_profile_page,
        name='hosting_client_profile_page'
    ),
    path(
        'client/profile/edit/',
        views.edit_hosting_client_profile,
        name='edit_hosting_client_profile'
    ),
    path(
        'client/profile/upload-image/',
        views.upload_hosting_client_profile_image,
        name='upload_hosting_client_profile_image'
    ),
    path(
        'client/profile/change-username/',
        views.change_hosting_client_username,
        name='change_hosting_client_username'
    ),
    path(
        'client/profile/change-password/',
        views.change_hosting_client_password,
        name='change_hosting_client_password'
    ),

    # ============================================================
    # Hosting Client Password Reset
    # ============================================================

    path(
        'client-password-reset/',
        views.HostingClientPasswordResetView.as_view(),
        name='hosting_client_password_reset'
    ),

    path(
        'client-password-reset/done/',
        views.HostingClientPasswordResetDoneView.as_view(),
        name='hosting_client_password_reset_done'
    ),

    path(
        'client-reset/<uidb64>/<token>/',
        views.HostingClientPasswordResetConfirmView.as_view(),
        name='hosting_client_password_reset_confirm'
    ),

    path(
        'client-reset/done/',
        views.HostingClientPasswordResetCompleteView.as_view(),
        name='hosting_client_password_reset_complete'
    ),

    path(
        'information-center/',
        views.hosting_partner_information_center,
        name='hosting_partner_information_center'
    ),
]