Lightweight 0.20260213.0
Loading...
Searching...
No Matches
LargeDb_OrderItem Struct Reference

OrderItem entity - join between Order and Product with quantity and price. Estimated: 30,000 rows × 600B = 18MB. More...

#include <Entities.hpp>

Public Attributes

Light::Field< uint64_t, Light::PrimaryKey::ServerSideAutoIncrement > id
 
Light::Field< int > quantity
 
Light::Field< double > unit_price
 
Light::Field< double > total_price
 
Light::Field< std::optional< double > > discount_amount
 
Light::BelongsTo< Member(LargeDb_Order::id), Light::SqlRealName { "order_id" }> order {}
 
Light::BelongsTo< Member(LargeDb_Product::id), Light::SqlRealName { "product_id" }> product {}
 

Detailed Description

OrderItem entity - join between Order and Product with quantity and price. Estimated: 30,000 rows × 600B = 18MB.

Definition at line 122 of file Entities.hpp.

Member Data Documentation

◆ id

Light::Field<uint64_t, Light::PrimaryKey::ServerSideAutoIncrement> LargeDb_OrderItem::id

Definition at line 124 of file Entities.hpp.

◆ quantity

Light::Field<int> LargeDb_OrderItem::quantity

Definition at line 125 of file Entities.hpp.

◆ unit_price

Light::Field<double> LargeDb_OrderItem::unit_price

Definition at line 126 of file Entities.hpp.

◆ total_price

Light::Field<double> LargeDb_OrderItem::total_price

Definition at line 127 of file Entities.hpp.

◆ discount_amount

Light::Field<std::optional<double> > LargeDb_OrderItem::discount_amount

Definition at line 128 of file Entities.hpp.

◆ order

Light::BelongsTo<Member(LargeDb_Order::id), Light::SqlRealName { "order_id" }> LargeDb_OrderItem::order {}

Definition at line 130 of file Entities.hpp.

◆ product

Light::BelongsTo<Member(LargeDb_Product::id), Light::SqlRealName { "product_id" }> LargeDb_OrderItem::product {}

Definition at line 131 of file Entities.hpp.


The documentation for this struct was generated from the following file: