Skip to content

Order Model

PRO

Payment order created when a paid event is booked (Pro). Tracks total, currency, and order status.

Class

  • Source: fluent-booking-pro/app/Models/Order.php
  • Table: fcal_orders
  • Primary key: id
  • Extends: Model

Attributes

ColumnTypeNullableDefaultDescription
idBIGINT UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
statusVARCHAR(20)NodraftLifecycle status (scheduled, cancelled, completed, rejected, pending).
parent_idBIGINT UNSIGNEDNoParent row used for rescheduled or grouped bookings.
order_numberVARCHAR(255)No``Order Number stored for this record.
typeVARCHAR(20)NosaleSubtype discriminator.
customer_idBIGINT UNSIGNEDNoForeign key to a related record.
payment_methodVARCHAR(100)NoSelected payment method slug.
payment_modeVARCHAR(100)NoPayment Mode stored for this record.
payment_method_typeVARCHAR(100)NoPayment Method Type stored for this record.
payment_method_titleVARCHAR(100)NoPayment Method Title stored for this record.
currencyVARCHAR(10)NoCurrency stored for this record.
subtotalDECIMAL(18,9)No0.000000000Subtotal stored for this record.
discount_taxDECIMAL(18,9)No0.000000000Discount Tax stored for this record.
discount_totalDECIMAL(18,9)No0.000000000Discount Total stored for this record.
shipping_taxDECIMAL(18,9)No0.000000000Shipping Tax stored for this record.
shipping_totalDECIMAL(18,9)No0.000000000Shipping Total stored for this record.
tax_totalDECIMAL(18,9)No0.000000000Tax Total stored for this record.
total_amountDECIMAL(18,9)No0.000000000Total Amount stored for this record.
total_paidDECIMAL(18,9)No0.000000000Total Paid stored for this record.
rateDECIMAL(18,9)No1.000000000Rate stored for this record.
noteTEXTNoNote stored for this record.
ip_addressTEXTNoIP address recorded when the booking was created.
completed_atDATETIMEYesTimestamp column.
refunded_atDATETIMEYesTimestamp column.
uuidVARCHAR(100)NoUuid stored for this record.
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

Relationships

MethodTypeTarget
items()hasManyOrderItems
discounts()hasManyOrderItems
transaction()hasOneTransactions
booking()belongsToBooking

Public Methods (sample)

MethodSignature
items()
discounts()
transaction()
booking()