v1.7.0: refactor max_bot to flat structure, add VCF+UserModel+NLP history context, portal pages and proxy fixes
- Refactored max_bot from nested packages to flat module structure - Q2: Extended BotUser model (patronymic, email, org, address, vcf_raw, contact_hash, phone_verified, email_verified, last_interaction, total_conversations, total_tickets) - Q2: VCF parser (FN, N, TEL, EMAIL, ORG, ADR), upsert on re-contact, NLP history context (_get_user_history_context -> YandexGPT) - Q1: Broadcast preview modal with 10s confirmation timer - Q3: CSS var(--white)->var(--bg-card), var(--text)->var(--text-primary) - Q4: bot_settings showNotification(), editable max_bot_id - Q5: Webhook secret passthrough via X-Max-Bot-Api-Secret - Masking sensitive keys, dialog_cleared handler, migrate via _add_column_if_not_exists() - Rate limit (asyncio.sleep 0.5 per 10), dead code removed, conv.intent context in contact.py - Portal pages: bot_consent, bot_kb (edit), bot_settings, bot_test, bot_tickets, portal_settings - Tests: 21/21 passing, added test_yandex_gpt.py, test_email_sender.py - Deploy: deploy_full.sh, schema.sql, seed_knowledge_base.sql
This commit is contained in:
@@ -26,16 +26,10 @@
|
||||
{% if role_permissions.get('checklist', True) != False %}<a href="/service/checklist" class="{% if active_page == 'checklist' %}active{% endif %}">Чек-лист</a>{% endif %}
|
||||
{% if role_permissions.get('tech_access', True) != False %}<a href="/service/documents/tech-access" class="{% if active_page == 'tech-access' %}active{% endif %}">Доступ техников</a>{% endif %}
|
||||
|
||||
<div class="sidebar-section">Чат-бот Max</div>
|
||||
{% if role_permissions.get('bot_analytics', True) != False %}<a href="/service/bot-settings/analytics" class="{% if active_page == 'bot-analytics' %}active{% endif %}">Аналитика</a>{% endif %}
|
||||
{% if role_permissions.get('bot_users', True) != False %}<a href="/service/bot-settings/users" class="{% if active_page == 'bot-users' %}active{% endif %}">Пользователи бота</a>{% endif %}
|
||||
{% if role_permissions.get('bot_conversations', True) != False %}<a href="/service/bot-settings/conversations" class="{% if active_page == 'bot-conversations' %}active{% endif %}">Диалоги бота</a>{% endif %}
|
||||
{% if role_permissions.get('bot_tickets', True) != False %}<a href="/service/bot-settings/tickets" class="{% if active_page == 'bot-tickets' %}active{% endif %}">Заявки</a>{% endif %}
|
||||
{% if role_permissions.get('bot_handoffs', True) != False %}<a href="/service/bot-settings/handoffs" class="{% if active_page == 'bot-handoffs' %}active{% endif %}">Handoff-диалоги</a>{% endif %}
|
||||
{% if role_permissions.get('bot_notifications', True) != False %}<a href="/service/bot-settings/notifications" class="{% if active_page == 'bot-notifications' %}active{% endif %}">Уведомления</a>{% endif %}
|
||||
{% if role_permissions.get('bot_risk_questions', True) != False %}<a href="/service/bot-settings/risk-questions" class="{% if active_page == 'bot-risk-questions' %}active{% endif %}">Вопросы риск-инжиниринга</a>{% endif %}
|
||||
{% if role_permissions.get('bot_storage', True) != False %}<a href="/service/bot-settings/storage" class="{% if active_page == 'bot-storage' %}active{% endif %}">Яндекс.Диск</a>{% endif %}
|
||||
{% if role_permissions.get('bot_broadcasts', True) != False %}<a href="/service/bot-settings/broadcasts" class="{% if active_page == 'bot-broadcasts' %}active{% endif %}">Рассылки</a>{% endif %}
|
||||
<div class="sidebar-section">Чат-бот MAX</div>
|
||||
{% if role_permissions.get('bot_consent', True) != False %}<a href="/service/bot-consent" class="{% if active_page == 'bot-consent' %}active{% endif %}">Согласия ФЗ-152</a>{% endif %}
|
||||
{% if role_permissions.get('bot_tickets', True) != False %}<a href="/service/bot-tickets" class="{% if active_page == 'bot-tickets' %}active{% endif %}">Заявки от бота</a>{% endif %}
|
||||
{% if role_permissions.get('bot_kb', True) != False %}<a href="/service/bot-kb" class="{% if active_page == 'bot-kb' %}active{% endif %}">База знаний</a>{% endif %}
|
||||
|
||||
<div class="sidebar-section">Контент</div>
|
||||
{% if role_permissions.get('blog', True) != False %}<a href="/service/blog" class="{% if active_page == 'blog' %}active{% endif %}">Управление блогом</a>{% endif %}
|
||||
@@ -48,9 +42,9 @@
|
||||
<div class="sidebar-section">Настройки</div>
|
||||
<a href="/service/questionnaire-config" class="{% if active_page == 'questionnaire-config' %}active{% endif %}">Настройка опросника</a>
|
||||
<a href="/service/formulas" class="{% if active_page == 'formulas' %}active{% endif %}">Формулы</a>
|
||||
<a href="/service/bot-settings" class="{% if active_page == 'bot-settings' %}active{% endif %}">Чат-бот Max</a>
|
||||
<a href="/service/portal-settings" class="{% if active_page == 'portal-settings' %}active{% endif %}">Настройка портала</a>
|
||||
<a href="/service/role-settings" class="{% if active_page == 'role-settings' %}active{% endif %}">Настройка Ролей</a>
|
||||
{% if role_permissions.get('bot_settings', True) != False %}<a href="/service/bot-settings" class="{% if active_page == 'bot-settings' %}active{% endif %}">Настройки чат-бота</a>{% endif %}
|
||||
<a href="/service/ideas" class="{% if active_page == 'ideas' %}active{% endif %}">Идеи</a>
|
||||
</nav>
|
||||
<div class="sidebar-footer">
|
||||
|
||||
Reference in New Issue
Block a user