From 908eb410cabbabaf58de556728b23c9b4dea366a Mon Sep 17 00:00:00 2001 From: WASRUSGEN Date: Sat, 30 May 2026 13:23:40 +0300 Subject: [PATCH] feat: 152-FZ compliant contact collection with RKN exception logic --- mockup.html | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/mockup.html b/mockup.html index 9a22fbf..ab3019e 100644 --- a/mockup.html +++ b/mockup.html @@ -8200,8 +8200,10 @@ function _showReminderPicker(doc, contractType, intent) { 'value="' + savedContact + '" style="font-size:12px;margin-bottom:6px">' + '' + '' + '
' + @@ -8256,15 +8258,17 @@ function _setReminder(docId, docLabel, contractType, remindAt, intent) { if (contactVal && hasConsent) { var ctx = _buildElenaContext(); - fetch(API_BASE + '/api/contact/remind', { + fetch(API_BASE + '/api/contact', { method: 'POST', headers: {'Content-Type':'application/json'}, body: JSON.stringify({ - phone_or_telegram: contactVal, - doc_label: docLabel, - remind_at: remindAt, - name: ctx.client_name || '', - consent: true + phone: contactVal.startsWith('@') || contactVal.includes('t.me') ? '' : contactVal, + telegram: contactVal.startsWith('@') || contactVal.includes('t.me') ? contactVal : '', + name: ctx.client_name || '', + case_context: 'Напоминание: ' + docLabel + ' до ' + remindAt, + consent: true, + purpose: ['reminder'], // ← ст.22 ч.2 п.1 152-ФЗ: только напоминания = уведомление РКН не нужно + source: 'reminder_picker' }) }).then(function(r){ return r.json(); }).then(function(d){ if (d.saved) {