PluginProbe
Yatra – Travel Booking & Tour Operator Software / 3.0.17
Yatra – Travel Booking & Tour Operator Software v3.0.17
3.0.17 3.0.16 3.0.15 3.0.14 3.0.14.1 3.0.14.2 3.0.12 3.0.13 3.0.11 3.0.10 3.0.9 3.0.8 3.0.7 3.0.6 3.0.5 3.0.5.1 3.0.4 3.0.3 3.0.2.9 3.0.2.7 3.0.2.8 3.0.2.6 trunk 1.0.0 2.0.0 All 85 releases
← All changes | resources/js/pages/Dashboard.tsx +10 -2 3.0.13 → 3.0.17 View file →
@@ -395,16 +395,24 @@
395 395 queryKey: ["dashboard-upcoming-departures"],
396 396 queryFn: async () => {
397 397 const today = new Date();
398 398 const todayStr = formatDateForInput(today);
399 + // Fetch all FUTURE departures, not only status === "upcoming". A departure
400 + // that a booking has filled flips to status "full" (booked >= capacity),
401 + // and a single group-of-x booking fills a small/private departure in one
402 + // go — so filtering to "upcoming" here silently dropped fully-booked
403 + // upcoming tours from the dashboard while partially-booked ones stayed. We
404 + // keep upcoming + full (a full trip is still an upcoming trip, just sold
405 + // out) and exclude only cancelled/trash/past.
399 406 const response = await apiClient.get("/departures", {
400 407 params: {
401 - status: "upcoming",
402 408 date_from: todayStr,
403 409 include_past: false,
404 410 },
405 411 });
406 - const items = response?.data || [];
412 + const items = (response?.data || []).filter(
413 + (d: any) => d?.status === "upcoming" || d?.status === "full",
414 + );
407 415 return items.map((d: any) => {
408 416 const tripTitle = d?.trip?.title || d?.trip_title || d?.title || "";
409 417 const destination =
410 418 (d?.trip?.destinations && d.trip.destinations[0]?.name) ||