bmc_hub/migrations/229_migration_center_subscription_visibility_indexes.sql
Christian d81a8f41b4 feat: Add end-to-end tests for Sag module HTTP API
- Implemented a comprehensive end-to-end testing script for the Sag module's HTTP API, covering various functionalities including case creation, updates, and file uploads.
- Introduced a safe HTML sanitizer utility to ensure safe rendering of HTML content in the BMC Hub UI.
- Added database migrations for new features including WAN connection marking for wall outlets, permanent audit trails for supplier invoices, and dedicated permissions for the Sag module.
- Created a migration center for manual subscription and invoice migrations with relevant tables and indexes.
- Added tests for migration center functionalities, ensuring stability and correctness of the new features.
2026-07-28 14:18:24 +02:00

12 lines
543 B
SQL

-- Speed up the subscription-like invoice line classifier and company filters.
CREATE INDEX IF NOT EXISTS idx_mc_items_subscription_visibility
ON migration_center_session_items
(session_id, source_system, entity_type, customer_no, product_code, invoice_date);
CREATE INDEX IF NOT EXISTS idx_mc_items_company_name
ON migration_center_session_items (session_id, LOWER(customer_name));
CREATE INDEX IF NOT EXISTS idx_sag_subscriptions_customer_price
ON sag_subscriptions (customer_id, price)
WHERE status <> 'cancelled';