using InvercargillSql.Orm; /** * Order entity representing an order in the e-commerce system. */ public class Order : Object { public int64 id { get; set; } public int64 user_id { get; set; } public int64 product_id { get; set; } public int64 quantity { get; set; } public double total { get; set; } public string status { get; set; } public DateTime? created_at { get; set; } public Order() { status = ""; } public static void configure_mapper(EntityMapperBuilder b) { b.table("orders") .column("id", o => o.id, (o, v) => o.id = v) .column("user_id", o => o.user_id, (o, v) => o.user_id = v) .column("product_id", o => o.product_id, (o, v) => o.product_id = v) .column("quantity", o => o.quantity, (o, v) => o.quantity = v) .column("total", o => o.total, (o, v) => o.total = v) .column("status", o => o.status, (o, v) => o.status = v) .column("created_at", o => o.created_at, (o, v) => o.created_at = v); } }