offer.where
Offre le voci del catalogo che soddisfano le tue condizioni.
Firma
offer.where(where: ContentWhere, opts?: { maxItems?: number; flag?: { by: string; map: Record<string, string> } }): ContentOfferParametri
| Nome | Tipo | Obbligatorio | Descrizione |
|---|---|---|---|
where | ContentWhere | Obbligatorio | Le condizioni sui campi che una voce deve soddisfare. |
opts | { maxItems?: number; flag?: { by: string; map: Record<string, string> } } | Opzionale | Impostazioni extra, come maxItems per il massimo di voci offerte. |
Restituisce
ContentOffer L'offerta, da passare a list.add o list.addRow.
Esempio
list.add(self, "pack", trinket, offer.where({ weight: { lte: 3 } }));
