security(v3): harden multi-tenant isolation and enhance failure feedback
This commit is contained in:
@@ -19,6 +19,7 @@ class Event_File_Base(BaseModel):
|
||||
# --- Standardized Vision IDs (Strings for API, Integers for DB) ---
|
||||
id: Optional[Union[int, str]] = Field(**base_fields['event_file_id_random'])
|
||||
event_file_id: Optional[Union[int, str]] = Field(**base_fields['event_file_id_random'])
|
||||
account_id: Optional[Union[int, str]] = Field(None, **base_fields['account_id_random'])
|
||||
hosted_file_id: Optional[Union[int, str]] = Field(**base_fields['hosted_file_id_random'])
|
||||
|
||||
# Generic Relational target
|
||||
@@ -34,6 +35,7 @@ class Event_File_Base(BaseModel):
|
||||
|
||||
# --- Standardized Legacy / Internal IDs (Excluded) ---
|
||||
id_random: Optional[str] = Field(None, alias='event_file_id_random', exclude=True)
|
||||
account_id_random: Optional[str] = Field(None, exclude=True)
|
||||
hosted_file_id_random: Optional[str] = Field(None, exclude=True)
|
||||
for_id_random: Optional[str] = Field(None, exclude=True)
|
||||
event_id_random: Optional[str] = Field(None, exclude=True)
|
||||
@@ -60,6 +62,7 @@ class Event_File_Base(BaseModel):
|
||||
# 2. Map & Resolve Relational IDs
|
||||
# (Field Name, Table Name)
|
||||
id_map = [
|
||||
('account_id', 'account'),
|
||||
('hosted_file_id', 'hosted_file'),
|
||||
('event_id', 'event'),
|
||||
('event_exhibit_id', 'event_exhibit'),
|
||||
|
||||
Reference in New Issue
Block a user