f0f1f2.studio Template reference
English
Open application
Interface

ICustomer

Definition

Namespace
Resto.Front.PrintTemplates.Cheques.Razor.TemplateModels
Available since
3.5

A guest card from the shared customer directory: name and surname, card number, contacts and the "high risk" flag.

Detailed description

One and the same directory record — also known as "delivery customers" and "banquet and reservation guests" — is visible both in the back office and at the till.

A guest reaches the print model four ways: Model.Delivery.Customer, Model.Reserve.Customer, Model.Customer on a VAT invoice, and the Model.Order.Customers collection on an ordinary order.

An object existing does not mean it is filled. On a delivery and on a reservation the guest is declared non-null: for an anonymous order — a walk-in pickup with no card, say — the object is still created, but only Name is filled, the other fields are empty, and Phones, Addresses and Emails are empty collections. A Customer != null check proves nothing here; check the fields you are about to print.

Contacts are always collections, even when there is a single phone: take the first element explicitly and expect emptiness.

Do not confuse this with IUser: IUser is a staff account (waiter, cashier, courier), ICustomer is a guest profile. They share no fields — even the name is arranged differently.

Available in documents

Access pathDocument types
Model.Order.Customers[]Guest bill, Sales receipt, Fiscal receipt appendix, Correction fiscal receipt appendix, Delivery label for regular order, iikoCard receipt, Prepayment receipt, Payment/refund receipt, Service ticket, VAT invoice
Model.Delivery.CustomerDelivery invoice, Delivery label
Model.Order.BaseOrder.Customers[]Cooking complete ticket, Cooking complete label
Model.Banquet.CustomerBanquet preliminary order ticket
Model.CustomerVAT invoice
Model.Deliveries[].CustomerCourier's route list
Model.ParentOrder.Customers[]Payment/refund receipt
Model.Reserve.CustomerTable reserved sign

Properties

NameTypeDescription
AddressesIEnumerable<IAddress>Addresses
BlackListReasonstringReason for assigning "high-risk" status
CardDiscountTypeIDiscountTypeCustomer card discount type
CardNumberstringCard number
CommentstringComment
EmailsIEnumerable<IEmail>Email addresses
InBlackListbool"High-risk" status client
NamestringName
PhonesIEnumerable<IPhone>Phone numbers
SurnamestringLast name