1Y=annuel etc
Deploy Nexus Portal to HestiaCP (FTP) / build-and-deploy (push) Successful in 13s

This commit is contained in:
LathanDevers
2026-06-25 14:08:47 +02:00
parent 1872a3c2fa
commit c29047e6fa
@@ -20,6 +20,21 @@ export default function DashboardServiceCard({ order, onClick }) {
} }
}; };
// Fonction utilitaire pour traduire les cycles de FOSSBilling
const formatPeriod = (periodCode) => {
const periods = {
'1W': 'Hebdomadaire',
'1M': 'Mensuel',
'3M': 'Trimestriel',
'6M': 'Semestriel',
'1Y': 'Annuel',
'2Y': 'Tous les 2 ans',
'3Y': 'Tous les 3 ans'
};
// Si le code est inconnu, on affiche le code brut par sécurité, sinon on traduit
return periods[periodCode] || periodCode;
};
return ( return (
<div <div
className="bg-gray-900 border border-gray-800 p-6 rounded-xl hover:border-cyan-400/50 transition-colors group cursor-pointer flex flex-col justify-between shadow-lg" className="bg-gray-900 border border-gray-800 p-6 rounded-xl hover:border-cyan-400/50 transition-colors group cursor-pointer flex flex-col justify-between shadow-lg"
@@ -36,7 +51,7 @@ export default function DashboardServiceCard({ order, onClick }) {
{order.title} {order.title}
</h3> </h3>
<p className="text-sm text-gray-500 mt-1"> <p className="text-sm text-gray-500 mt-1">
Facturation : {order.period} Facturation : <span className="text-cyan-400 font-medium">{formatPeriod(order.period)}</span>
</p> </p>
</div> </div>