2022-01-30 21:03:49 +01:00
|
|
|
import React from 'react';
|
|
|
|
import { setHostSetting } from './email-host-settings';
|
|
|
|
import { EmailTemplate3Config } from './email-template-3';
|
|
|
|
|
|
|
|
export default function LegitimateInteresProblems({
|
|
|
|
settings,
|
|
|
|
host_id,
|
|
|
|
pronoun,
|
|
|
|
setConfig,
|
|
|
|
}: {
|
|
|
|
host_id: string;
|
|
|
|
settings: EmailTemplate3Config['hosts_settings'][string];
|
|
|
|
setConfig: React.Dispatch<React.SetStateAction<EmailTemplate3Config>>;
|
|
|
|
}) {
|
|
|
|
if (settings.legal_basis_type !== 'legitimate_interest') {
|
|
|
|
return '';
|
|
|
|
}
|
|
|
|
const [description, setDescription] = React.useState('marketing');
|
|
|
|
return (
|
|
|
|
<div>
|
|
|
|
<div>
|
|
|
|
Czy administrator strony opisał szczegółowo, na czym polega uzasadniony interes w
|
|
|
|
kontekście tego celu?
|
2022-02-06 17:05:33 +01:00
|
|
|
{/* {hostSettingsDropdown({
|
2022-01-30 21:03:49 +01:00
|
|
|
settings,
|
|
|
|
host_id,
|
|
|
|
setConfig,
|
|
|
|
field: 'legitimate_interest_activity_specified' as const,
|
|
|
|
value: settings.legitimate_interest_activity_specified,
|
|
|
|
options: {
|
|
|
|
precise: [
|
|
|
|
'Tak, wskazuje jasno na bieżące działania lub korzyści wynikające z takiego przetwarzania danych.',
|
|
|
|
],
|
|
|
|
vague: ['Wskazuje tylko ogólnie, jak np. „marketing” czy „statystyki”.'],
|
|
|
|
no: ['Nie. Nie wiadomo, na czym ten uzasadniony interes polega.'],
|
|
|
|
},
|
2022-02-06 17:05:33 +01:00
|
|
|
})} */}
|
2022-01-30 21:03:49 +01:00
|
|
|
</div>
|
|
|
|
{settings.legitimate_interest_activity_specified === 'vague' ? (
|
|
|
|
<div>
|
|
|
|
Jak administrator opisał to, na czym polega uzasadniony interes w kontekście{' '}
|
|
|
|
{host_id}?{' '}
|
|
|
|
<input
|
|
|
|
type="text"
|
|
|
|
value={description}
|
|
|
|
onChange={(e) => setDescription(e.target.value)}
|
|
|
|
/>
|
|
|
|
<button
|
|
|
|
onClick={(e) =>
|
|
|
|
setHostSetting(
|
|
|
|
setConfig,
|
|
|
|
[host_id, 'legitimate_interest_activity_description'],
|
|
|
|
description
|
|
|
|
)
|
|
|
|
}
|
|
|
|
>
|
|
|
|
zatwierdź
|
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
) : (
|
|
|
|
''
|
|
|
|
)}
|
|
|
|
</div>
|
|
|
|
);
|
|
|
|
}
|