2025-08-21 20:28:14 +02:00
|
|
|
# services/suppliers/app/models/__init__.py
|
|
|
|
|
"""
|
|
|
|
|
Models package for the Supplier service
|
|
|
|
|
"""
|
|
|
|
|
|
2025-10-15 16:12:49 +02:00
|
|
|
# Import AuditLog model for this service
|
|
|
|
|
from shared.security import create_audit_log_model
|
|
|
|
|
from shared.database.base import Base
|
|
|
|
|
|
|
|
|
|
# Create audit log model for this service
|
|
|
|
|
AuditLog = create_audit_log_model(Base)
|
|
|
|
|
|
2025-08-21 20:28:14 +02:00
|
|
|
from .suppliers import (
|
2025-10-30 21:08:07 +01:00
|
|
|
Supplier, SupplierPriceList, SupplierQualityReview,
|
|
|
|
|
SupplierType, SupplierStatus, PaymentTerms, QualityRating,
|
|
|
|
|
# Deprecated stubs for backward compatibility
|
|
|
|
|
PurchaseOrder, PurchaseOrderItem, Delivery, DeliveryItem, SupplierInvoice,
|
|
|
|
|
PurchaseOrderStatus, DeliveryStatus, DeliveryRating, InvoiceStatus
|
2025-08-21 20:28:14 +02:00
|
|
|
)
|
|
|
|
|
|
|
|
|
|
from .performance import (
|
|
|
|
|
SupplierPerformanceMetric, SupplierAlert, SupplierScorecard,
|
|
|
|
|
SupplierBenchmark, AlertRule, AlertSeverity, AlertType, AlertStatus,
|
|
|
|
|
PerformanceMetricType, PerformancePeriod
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
__all__ = [
|
|
|
|
|
# Supplier Models
|
|
|
|
|
'Supplier',
|
|
|
|
|
'SupplierPriceList',
|
|
|
|
|
'SupplierQualityReview',
|
2025-10-30 21:08:07 +01:00
|
|
|
|
2025-08-21 20:28:14 +02:00
|
|
|
# Performance Models
|
|
|
|
|
'SupplierPerformanceMetric',
|
|
|
|
|
'SupplierAlert',
|
|
|
|
|
'SupplierScorecard',
|
|
|
|
|
'SupplierBenchmark',
|
|
|
|
|
'AlertRule',
|
2025-10-30 21:08:07 +01:00
|
|
|
|
2025-08-21 20:28:14 +02:00
|
|
|
# Supplier Enums
|
|
|
|
|
'SupplierType',
|
|
|
|
|
'SupplierStatus',
|
|
|
|
|
'PaymentTerms',
|
|
|
|
|
'QualityRating',
|
2025-10-30 21:08:07 +01:00
|
|
|
|
2025-08-21 20:28:14 +02:00
|
|
|
# Performance Enums
|
|
|
|
|
'AlertSeverity',
|
|
|
|
|
'AlertType',
|
|
|
|
|
'AlertStatus',
|
|
|
|
|
'PerformanceMetricType',
|
2025-10-15 16:12:49 +02:00
|
|
|
'PerformancePeriod',
|
2025-10-30 21:08:07 +01:00
|
|
|
"AuditLog",
|
|
|
|
|
|
|
|
|
|
# Deprecated stubs (backward compatibility only - DO NOT USE)
|
|
|
|
|
'PurchaseOrder',
|
|
|
|
|
'PurchaseOrderItem',
|
|
|
|
|
'Delivery',
|
|
|
|
|
'DeliveryItem',
|
|
|
|
|
'SupplierInvoice',
|
|
|
|
|
'PurchaseOrderStatus',
|
|
|
|
|
'DeliveryStatus',
|
|
|
|
|
'DeliveryRating',
|
|
|
|
|
'InvoiceStatus',
|
2025-08-21 20:28:14 +02:00
|
|
|
]
|