feat: Add PayPal configuration to settings
Introduces the ability to configure PayPal credentials for individual condos within the settings. This feature is only visible if PayPal is enabled in the global settings. Also removes and simplifies Dockerfile configurations.
This commit is contained in:
@@ -689,6 +689,26 @@ export const SettingsPage: React.FC = () => {
|
||||
<textarea value={activeCondo.notes || ''} onChange={(e) => setActiveCondo({ ...activeCondo, notes: e.target.value })} className="w-full border p-2.5 rounded-lg text-slate-700 h-24"></textarea>
|
||||
</div>
|
||||
|
||||
{/* PayPal Configuration for Single Condo Mode */}
|
||||
{globalSettings?.features.payPal && (
|
||||
<div className="bg-blue-50 p-4 rounded-lg border border-blue-100">
|
||||
<div className="flex items-center gap-2 mb-2 text-blue-800">
|
||||
<CreditCard className="w-4 h-4"/>
|
||||
<span className="text-xs font-bold uppercase">Configurazione Pagamenti</span>
|
||||
</div>
|
||||
<div>
|
||||
<label className="text-xs font-semibold text-slate-600 block mb-1">PayPal Client ID</label>
|
||||
<input
|
||||
className="w-full border p-2 rounded text-slate-700 text-sm"
|
||||
placeholder="Es: Afg... (Ottienilo da developer.paypal.com)"
|
||||
value={activeCondo.paypalClientId || ''}
|
||||
onChange={e => setActiveCondo({...activeCondo, paypalClientId: e.target.value})}
|
||||
/>
|
||||
<p className="text-[10px] text-slate-500 mt-1">Necessario per abilitare i pagamenti online delle rate.</p>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
|
||||
<div>
|
||||
<label className="block text-sm font-medium text-slate-700 mb-1">Quota Mensile Standard (€)</label>
|
||||
<input type="number" value={activeCondo.defaultMonthlyQuota} onChange={(e) => setActiveCondo({ ...activeCondo, defaultMonthlyQuota: parseFloat(e.target.value) })} className="w-full border p-2.5 rounded-lg text-slate-700" placeholder="Quota Default" required />
|
||||
|
||||
Reference in New Issue
Block a user