templates/tracking/_Tab_track_code.html.twig line 1

Open in your IDE?
  1. <style>
  2.     :root { --afi-green: #006E51; --afi-yellow: #F6D155; }
  3.     /* Card & Grid */
  4.     .result-card { background: #fff; border-radius: 20px; box-shadow: 0 10px 30px rgba(0,0,0,0.08); overflow: hidden; margin-bottom: 30px; border: 1px solid #eee; }
  5.     .summary-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); background: #fdfdfd; border-bottom: 2px solid var(--afi-green); padding: 15px; text-align: center; }
  6.     .summary-box { padding: 10px; border-right: 1px solid #eee; }
  7.     .summary-box:last-child { border-right: none; }
  8.     .summary-box label { display: block; font-size: 10px; color: #888; text-transform: uppercase; font-weight: bold; margin-bottom: 3px; }
  9.     .summary-box span { font-weight: 800; color: #333; font-size: 13px; display: block; }
  10.     /* Container de l'image miniature */
  11.     .img-preview-container {
  12.         position: relative;
  13.         cursor: pointer;
  14.         border-radius: 12px;
  15.         overflow: hidden;
  16.         border: 2px solid #eee;
  17.         background: #f9f9f9;
  18.         height: 110px;
  19.         transition: all 0.3s ease;
  20.     }
  21.     .img-preview-container:hover { border-color: var(--afi-green); transform: translateY(-3px); }
  22.     .img-preview-container img { width: 100%; height: 100%; object-fit: cover; }
  23.     .img-overlay-icon {
  24.         position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  25.         background: rgba(0, 110, 81, 0.2); display: flex; align-items: center; justify-content: center;
  26.         opacity: 0; transition: 0.3s; color: white; font-size: 20px;
  27.     }
  28.     .img-preview-container:hover .img-overlay-icon { opacity: 1; }
  29.     /* LIGHTBOX CSS (Le Preview) */
  30.     .afi-lightbox {
  31.         position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  32.         background: rgba(0, 0, 0, 0.85);
  33.         backdrop-filter: blur(5px); /* Flou d'arrière-plan */
  34.         display: none; z-index: 10000;
  35.         align-items: center; justify-content: center;
  36.         padding: 20px;
  37.     }
  38.     .afi-lightbox:target { display: flex; animation: fadeIn 0.3s ease; }
  39.     .afi-lightbox img {
  40.         max-width: 95%; max-height: 85vh;
  41.         border-radius: 10px;
  42.         box-shadow: 0 0 30px rgba(0,0,0,0.5);
  43.         border: 3px solid white;
  44.     }
  45.     .close-lightbox {
  46.         position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  47.         cursor: default;
  48.     }
  49.     .close-btn-icon {
  50.         position: absolute; top: 20px; right: 20px;
  51.         width: 45px; height: 45px; background: white; color: black;
  52.         border-radius: 50%; display: flex; align-items: center; justify-content: center;
  53.         font-size: 24px; text-decoration: none; font-weight: bold; z-index: 10001;
  54.     }
  55.     @keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
  56.     /* Détails Colis */
  57.     .goods-box { background: #fff; border: 1px solid #efefef; border-radius: 15px; padding: 15px; margin-bottom: 15px; border-left: 4px solid var(--afi-yellow); }
  58.     .location-badge { background: #fff9e6; border: 1px solid #f6d155; border-radius: 10px; padding: 10px; margin-top: 10px; text-align: center; }
  59. </style>
  60. {% if recept is not empty %}
  61.     {% for reception in recept|reverse %}
  62.         {% set pathBase = "https://a.afisarl.com/file/agents/reception/" ~ reception.dateOperation|date('d-m-Y') ~ "-" ~ reception.recunumero ~ "/" %}
  63.         {% set defaultImg = "https://a.afisarl.com/dist/images/defaultColis.png" %}
  64.         {{ include('tracking/_Tab.html.twig') }}
  65.     {% endfor %}
  66. {% else %}
  67.     <div class="container mt-5">
  68.         <div class="text-center py-5 shadow-sm rounded-lg bg-white border-0" style="border-radius: 20px;">
  69.             <div class="mb-4">
  70.                 <div class="d-inline-flex align-items-center justify-content-center bg-light rounded-circle" style="width: 100px; height: 100px;">
  71.                     <i class="fas fa-search fa-3x text-muted"></i>
  72.                 </div>
  73.             </div>
  74.             <h3 class="text-dark font-weight-bold mb-2">NO RECORDS FOUND</h3>
  75.             <p class="text-muted mx-auto mb-4" style="max-width: 450px;">
  76.                 We couldn't find any cargo tracking information for this customer code.
  77.                 Please verify the code or check back later once the warehouse has updated the system.
  78.             </p>
  79.             <div class="d-flex justify-content-center gap-3">
  80.                 <button onclick="window.location.reload()" class="btn btn-outline-secondary px-4 mr-2">
  81.                     <i class="fas fa-sync-alt mr-2"></i> Refresh
  82.                 </button>
  83.                 <a href="/" class="btn btn-warning px-4 font-weight-bold">
  84.                     <i class="fas fa-home mr-2"></i> New Search
  85.                 </a>
  86.             </div>
  87.         </div>
  88.         <p class="text-center mt-4 text-muted small">
  89.             <i class="fas fa-question-circle mr-1"></i> Need help? Contact our support at <strong>support@afisarl.com</strong>
  90.         </p>
  91.     </div>
  92. {% endif %}