Hotel Raxa - Advanced Booking System Implementation

🏨 Hotel Booking Enhancements:
- Implemented Eagle Booking Advanced Pricing add-on
- Added Booking.com-style rate management system
- Created professional calendar interface for pricing
- Integrated deals and discounts functionality

💰 Advanced Pricing Features:
- Dynamic pricing models (per room, per person, per adult)
- Base rates, adult rates, and child rates management
- Length of stay discounts and early bird deals
- Mobile rates and secret deals implementation
- Seasonal promotions and flash sales

📅 Availability Management:
- Real-time availability tracking
- Stop sell and restriction controls
- Closed to arrival/departure functionality
- Minimum/maximum stay requirements
- Automatic sold-out management

💳 Payment Integration:
- Maintained Redsys payment gateway integration
- Seamless integration with existing Eagle Booking
- No modifications to core Eagle Booking plugin

🛠️ Technical Implementation:
- Custom database tables for advanced pricing
- WordPress hooks and filters integration
- AJAX-powered admin interface
- Data migration from existing Eagle Booking
- Professional calendar view for revenue management

📊 Admin Interface:
- Booking.com-style management dashboard
- Visual rate and availability calendar
- Bulk operations for date ranges
- Statistics and analytics dashboard
- Modal dialogs for quick editing

🔧 Code Quality:
- WordPress coding standards compliance
- Secure database operations with prepared statements
- Proper input validation and sanitization
- Error handling and logging
- Responsive admin interface

🤖 Generated with Claude Code (https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Hotel Raxa Dev
2025-07-11 07:43:22 +02:00
commit 5b1e2453c7
9816 changed files with 2784509 additions and 0 deletions

View File

@@ -0,0 +1,91 @@
<?php
/**
* Unique Slug validation
*
* @package Redux Framework
* @subpackage Validation
* @author Kevin Provance (kprovance) & Dovy Paukstys
* @version 4.0.0
*/
defined( 'ABSPATH' ) || exit;
if ( ! class_exists( 'Redux_Validation_Unique_Slug', false ) ) {
/**
* Class Redux_Validation_Unique_Slug
*/
class Redux_Validation_Unique_Slug extends Redux_Validate {
/**
* Field Validation Function.
* Takes the vars and validates them
*
* @since ReduxFramework 3.0.0
*/
public function validate() {
global $wpdb, $wp_rewrite;
$this->field['msg'] = $this->field['msg'] ?? esc_html__( 'That URL slug is in use, please choose another.', 'redux-framework' );
$this->field['flush_permalinks'] = $this->field['flush_permalinks'] ?? false;
$slug = $this->value;
$feeds = $wp_rewrite->feeds;
if ( ! is_array( $feeds ) ) {
$feeds = array();
}
// Post slugs must be unique across all posts.
$result = wp_cache_get( 'redux-post-name' );
if ( false === $result ) {
// phpcs:ignore WordPress.DB.DirectDatabaseQuery
$post_name_check = $wpdb->get_var( $wpdb->prepare( "SELECT post_name FROM $wpdb->posts WHERE post_name = %s LIMIT 1", $slug ) );
wp_cache_set( 'redux-post-name', $post_name_check );
}
/**
* Filter whether the post slug would be bad as a flat slug.
*
* @since 3.1.0
*
* @param bool $bad_slug Whether the post slug would be bad as a flat slug.
* @param string $slug The post slug.
* @param string $post_type Post type.
*/
if ( $post_name_check || in_array( $slug, $feeds, true ) || apply_filters( 'wp_unique_post_slug_is_bad_attachment_slug', false, $slug ) ) {
$suffix = 2;
do {
$alt_post_name = _truncate_post_slug( $slug, 200 - ( strlen( $suffix ) + 1 ) ) . "-$suffix";
$result = wp_cache_get( 'redux-alt-post-name' );
if ( false === $result ) {
// phpcs:ignore WordPress.DB.DirectDatabaseQuery
$post_name_check = $wpdb->get_var( $wpdb->prepare( "SELECT post_name FROM $wpdb->posts WHERE post_name = %s LIMIT 1", $alt_post_name ) );
wp_cache_set( 'redux-alt-post-name', $result );
}
$suffix ++;
} while ( $post_name_check );
$slug = $alt_post_name;
$this->value = ( isset( $this->current ) ) ? $this->current : '';
$this->field['msg'] = sprintf( $this->field['msg'], $slug );
$this->field['current'] = $this->value;
$this->error = $this->field;
} elseif ( isset( $this->field['flush_permalinks'] ) && true === $this->field['flush_permalinks'] ) {
add_action( 'init', array( $this, 'flush_permalinks' ), 99 );
}
}
/**
* Flush WordPress permalinks.
*/
public function flush_permalinks() {
flush_rewrite_rules();
}
}
}

View File

@@ -0,0 +1,8 @@
<?php
/**
* Silence is golden.
*
* @package Redux Framework
*/
echo null;