- Remove hardcoded OPENROUTER_MODEL_CHOICES from openrouter.py
- Add API endpoint /integrations/openrouter/models/ to fetch models dynamically
- Models loaded from OpenRouter API with free models (':free') at top
- Update OpenRouterIntegration model_name field (remove choices, blank=True)
- Add async buildForm() with dynamic_choices support
- Show asterisks (********) for saved API keys with helpful placeholder
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Добавлена поддержка выбора основной категории (primary_category) для товаров и наборов, а также новая модель IntegrationCategoryMapping для связи категорий с внешними площадками. Теперь можно указать категорию товара, которая будет использоваться при экспорте на внешние площадки (Recommerce, WooCommerce и др.), с возможностью настройки маппинга категорий для каждого типа интеграции.
- Удалена лишняя модель IntegrationConfig из system_settings
- Singleton-паттерн: одна запись на интеграцию с is_active тумблером
- Добавлено шифрование токенов (EncryptedCharField с Fernet AES-128)
- UI: тумблеры слева, форма настроек справа
- API endpoints: toggle, settings, form_data
- Модель Recommerce: store_url + api_token (x-auth-token)
- Модель WooCommerce: store_url + consumer_key/secret
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Создана структура marketplaces/ для маркетплейсов
- Модели: MarketplaceIntegration, WooCommerceIntegration, RecommerceIntegration
- Сервисы: MarketplaceService, WooCommerceService, RecommerceService
- RecommerceService содержит методы для работы с API:
- test_connection(), sync(), fetch_products()
- push_product(), update_stock(), update_price()
- IntegrationConfig обновлён с новой интеграцией
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Создано приложение integrations с базовой архитектурой
- BaseIntegration (абстрактная модель) для всех интеграций
- BaseIntegrationService (абстрактный сервисный класс)
- IntegrationConfig модель для тумблеров в system_settings
- Добавлена вкладка "Интеграции" в системные настройки
- Заготовка UI с тумблерами для включения интеграций
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>