aeat.domain.calculations.registry._detail_record_bindings module

Detail-record row-set registry binding helpers.

class RelatedPartyOperationObservation(**data)[source]

Bases: BaseModel

One related-party operation for modelo 232.

Parameters:
  • source_id (str)

  • counterparty_tax_id (str)

  • counterparty_legal_name (str)

  • country_code (str)

  • transaction_date (date)

  • operation_kind_code (str)

  • transfer_pricing_method_code (str)

  • amount (Decimal)

source_id: str
counterparty_tax_id: str
country_code: str
transaction_date: date
operation_kind_code: str
transfer_pricing_method_code: str
amount: Decimal

Validate a related-party-operation binding at registry-build time.

Accumulating list[str] validator: validates the selector shape against _RelatedPartySelector and lifts the resolve-time op/fact invariant (row_field fact paired with the rows op and a named row_field) to build time, preserving the underlying pydantic field error.

Return type:

list[str]

Parameters:

binding (DataBindingDefinition)

Resolve row-producer related-party bindings into per-row indexed values.

Parameters:
Return type:

dict[tuple[TypeAliasType, int], Decimal | str]

class Modelo720RowObservation(**data)[source]

Bases: BaseModel

One foreign asset for modelo 720.

Parameters:
  • source_id (str)

  • asset_class_code (str)

  • country_code (str)

  • currency_code (str)

  • asset_identifier (str)

  • acquisition_date (date)

  • valuation_amount (Decimal)

source_id: str
asset_class_code: str
country_code: str
currency_code: str
asset_identifier: str
acquisition_date: date
valuation_amount: Decimal
validate_foreign_asset_binding(binding)[source]

Validate a foreign-asset binding at registry-build time.

Accumulating list[str] validator: validates the selector against _ForeignAssetSelector and lifts the resolve-time op/fact invariant to build time, preserving the underlying pydantic field error.

Return type:

list[str]

Parameters:

binding (DataBindingDefinition)

resolve_foreign_asset_binding_row_values(revision, observations)[source]

Resolve row-producer foreign-asset bindings into per-row indexed values.

Parameters:
Return type:

dict[tuple[TypeAliasType, int], Decimal | str]

class AtributionMemberObservation(**data)[source]

Bases: BaseModel

One atribución member for modelo 184.

Parameters:
  • source_id (str)

  • member_tax_id (str)

  • member_legal_name (str)

  • country_code (str)

  • transaction_date (date)

  • share_percentage (Decimal)

  • base_imponible_assigned (Decimal)

source_id: str
member_tax_id: str
country_code: str
transaction_date: date
share_percentage: Decimal
base_imponible_assigned: Decimal
validate_atribucion_binding(binding)[source]

Validate an atribución-member binding at registry-build time.

Accumulating list[str] validator: validates the selector against _AtributionSelector and lifts the resolve-time op/fact invariant to build time, preserving the underlying pydantic field error.

Return type:

list[str]

Parameters:

binding (DataBindingDefinition)

resolve_atribucion_binding_row_values(revision, observations)[source]

Resolve row-producer atribucion bindings into per-row indexed values.

Parameters:
Return type:

dict[tuple[TypeAliasType, int], Decimal | str]

class RefundOperationObservation(**data)[source]

Bases: BaseModel

One foreign-MS refund operation for modelo 360.

Parameters:
  • source_id (str)

  • member_state_code (str)

  • operation_kind_code (str)

  • operation_date (date)

  • supplier_tax_id (str)

  • refund_amount (Decimal)

source_id: str
member_state_code: str
operation_kind_code: str
operation_date: date
supplier_tax_id: str
refund_amount: Decimal
validate_refund_binding(binding)[source]

Validate a refund-operation binding at registry-build time.

Accumulating list[str] validator: validates the selector against _RefundSelector and lifts the resolve-time op/fact invariant to build time, preserving the underlying pydantic field error.

Return type:

list[str]

Parameters:

binding (DataBindingDefinition)

resolve_refund_binding_row_values(revision, observations)[source]

Resolve row-producer refund-operation bindings into per-row indexed values.

Parameters:
Return type:

dict[tuple[TypeAliasType, int], Decimal | str]