Object objCatalogProduct
From Snapp CMS Developer Documentation
Product Catalog Product Item Object
Contents |
Associated Objects
Construction Configuration Options
| Config Options | Description |
|---|---|
| fields : array or int (required) |
Fields for Product or ID of Product Paramaters
|
| options : array (optional) |
Related Product Information Paramaters
|
Avaliable Variables
| name | Description |
|---|---|
| id : int | Product ID |
| code : string | Product Code |
| rrpPrice : float | Current RRP Price |
| specialPrice : float | |
| summary : string | Product Summary Copy |
| description : string | Full Product Description |
| image : string | Hero Product Image |
| images : array | Array of Related Product Images |
| inStock : int | How many are currently in stock |
| reStock : int | ReStock Level |
| freight : float | Specific Freight Amount |
| freight_weight : float | Dead Weight for Freight Calculation |
| freight_cubic : string | Cubic Dimensions of Product for Freight Calculation |
| pricePolicies : array | List of all pricing policies related to this product |
| specifications : array | List of product specifications |
| relatedProducts : array | List of Related Product Categories and Products |
| categories : array | List of Categories this product is linked to |
| promo : string | Promocode currently liked to this product |
Available Functions
| rawSpecial(qty,currency) |
|---|
|
Return the raw Numerical Special Price without Formating Params
|
| special(qty,currency) |
|---|
|
Returns current special price, if no pricing policies, returns rrp Params
|
| price(currency) |
|---|
|
Returns the current RRP Params
|
| rawPrice(currency) |
|---|
|
Return the current RRP unformated Params
|
| instock() |
|---|
| Returns true or false if the current item is in stock |
| onSpecial(currency) |
|---|
|
Returns true or false if the current item in on special Params
|
| onSpecial(currency) |
|---|
|
Returns true or false if the current item in on special Params
|
| loadPolicies(code) |
|---|
|
Loads Associated Product Pricing Rules Params
|
| applyPromo(code) |
|---|
|
Apply a promo code to the current product Params
|
| loadRelatedProducts() |
|---|
| Load a list of related products for the current product |
| loadSpecifications() |
|---|
| Loads a lost of product specifications for the current product |
| loadCategories() |
|---|
| Load a list of Categories this product is linked to |
| getSpecificationsAsKeyValue() |
|---|
| Returns a list of specifications in key value pairs |
