Search Stock Villa Visibility Bug

Villa Disabling and "Hide Villa Forever" Feature

Issue Summary

This document addresses an issue where villas were unintentionally disabled on the Luxury Escapes Cape Town website, specifically affecting the villa "Anella" (https://luxuryescapes.capetown/villa/anella-villa/). The problem stemmed from a bug in the "Hide Villa Forever" feature within the Search Stock functionality, causing incorrect villas to be hidden when attempting to hide a villa from a specific supplier.

Background

  • Initial Report: Martene from Luxury Escapes Cape Town reported that Anella was not appearing in search results despite being available (https://luxuryescapes.capetown/search-stock-v2/?arrivalDate=2025-12-25&departureDate=2026-01-05&bedrooms=5&budgetFrom=3000&budgetTo=70000).

  • Confirmation: Martene confirmed that the "Disable" checkbox for Anella on the backend was not ticked.

    EOTQ0LkRuQn_SOpMEDyGpYHmm-Ispb4YVA.webp

  • Root Cause: The issue was traced to the "Hide Villa Forever" button in Search Stock. A coding error resulted in the wrong villas being deselected when hiding a villa from a supplier. This affected villas from both Turnkey and Nox.

  • Example: It was discovered that Villas365 ID 4 from Soughted could have blocked Turnkey ID 4.

  • API Issue: The API request was missing the supplier information, contributing to the problem.

    cgAHAMvPJVpf4Z7jRWEeKz-caBsCwyWjRQ.webp

  • Signoz Logs: Signoz access logs did not show any relevant entries related to the disabling action Logs Dashboard.

Solution

  1. Code Fix: The "Hide Villa Forever" feature’s code needs to be corrected to ensure that only the intended villa is hidden when using this function.
  2. Villa Review: A thorough review of all villas is necessary to identify and re-enable any other villas that were unintentionally disabled. Eugene from Web.Eng Support provided a list of potentially affected villas.
  3. API Correction: The API needs to be updated to include the supplier information in the request.
  4. Anella Re-enabled: The villa "Anella" should be re-enabled as a priority.
  5. Testing: After implementing the code fix, rigorous testing should be conducted to prevent similar issues in the future.

Prevention

  • Improved Code Review: Implement stricter code review processes to catch similar bugs before deployment.
  • Automated Testing: Develop automated tests to specifically check the "Hide Villa Forever" functionality and API requests.
  • User Training: Provide training to users on the proper use of the "Hide Villa Forever" feature.

Further Investigation

  • Determine the exact timeframe when the "Hide Villa Forever" feature was used incorrectly to narrow down the list of potentially affected villas.
  • Analyze logs to identify any patterns or common factors in the unintentionally disabled villas.

Communication

  • Keep Martene and the Luxury Escapes Cape Town team informed of the progress and resolution.
  • Document the code fix and testing procedures for future reference.

Related Links