OXID eShop CE
6.0.4
|
Static Protected Attributes | |
static | $_aLoadedParents |
static | $_aSelList |
static | $_aArticleManufacturers = [] |
static | $_aArticleVendors = [] |
static | $_aArticleCats = [] |
static | $_aSelections = [] |
static | $_aCategoryCache = null |
static | $_blHasAmountPrice = null |
Article manager. Creates fully detailed article object, with such information as VAT, discounts, etc.
OxidEsales\EshopCommunity\Application\Model\Article::__construct | ( | $aParams = null | ) |
Constructor, sets shop ID for article (\OxidEsales\Eshop\Core\Config::getShopId()), initiates parent constructor (parent::oxI18n()).
array | $aParams | The array of names and values of oxArticle instance properties to be set on object instantiation |
OxidEsales\EshopCommunity\Application\Model\Article::__get | ( | $sName | ) |
Magic getter, deals with values which are loaded on demand. Additionally it sets default value for unknown picture fields
string | $sName | Variable name |
OxidEsales\EshopCommunity\Application\Model\Article::__set | ( | $sName, | |
$sValue | |||
) |
Sets article parameter
string | $sName | name of parameter to set |
mixed | $sValue | parameter value |
|
protected |
Applies currency factor
\OxidEsales\Eshop\Core\Price | $oPrice | Price object |
object | $oCur | Currency object |
|
protected |
Applies VAT to article
\OxidEsales\Eshop\Core\Price | $oPrice | Price object |
double | $dVat | VAT percent |
|
protected |
Adds a flag if article is on comparisonlist.
|
protected |
assigns dynimagedir to article
|
protected |
if we have variants then depending on config option the parent may be non buyable
|
protected |
Set parent field value to child - variants
|
protected |
Assigns parent field values to article
string | $sFieldName | field name |
|
protected |
Assigns parent field values to article
|
protected |
Assigns persistent param to article.
|
protected |
Assigns stock status to article
|
protected |
Calculates price of article (adds taxes, currency and discounts).
\OxidEsales\Eshop\Core\Price | $oPrice | price object |
double | $dVat | vat value, optional, if passed, bypasses "bl_perfCalcVatOnlyForBasketOrder" config value |
|
protected |
Calculates lowest price of available article variants.
|
protected |
|
protected |
Returns SQL select string with checks if items are available
bool | $forceCoreTable | forces core table usage (optional) |
|
protected |
Delete pics
|
protected |
|
protected |
Deletes variant records
string | $sOXID | Article ID |
|
protected |
Fills amount price list object and sets amount price for article object
array | $aAmPriceList | Amount price list |
|
protected |
Generates SearchString for getCategory()
string | $sOXID | Article ID |
bool | $blSearchPriceCat | Whether to perform the search within price categories |
|
protected |
Generates SQL select string for getCustomerAlsoBoughtThisProduct
|
protected |
Generates select string for isAssignedToCategory()
string | $sOXID | Article ID |
string | $sCatId | Category ID |
bool | $dPriceFromTo | Article price for price categories |
|
protected |
Generates search string for similar list.
string | $sArticleTable | Article table name |
array | $aList | A list of original articles |
|
protected |
Returns active category select snippet
|
protected |
Modifies article price depending on given amount. Takes data from oxprice2article table.
int | $amount | Basket amount |
|
protected |
Collecting assigned to article amount-price list
|
protected |
gets attribs string
string | $sAttributeSql | Attribute selection snippet |
int | $iCnt | The number of selected attributes |
|
protected |
Returns query for article categories select
bool | $blActCats | select categories if all parents are active |
|
protected |
Returns array of fields which should not changed in variants
|
protected |
get user Group A, B or C price, returns db price if user is not in groups
|
protected |
Modifies given amount price.
int | $amount |
|
protected |
Return prepared price
|
protected |
Depending on view mode prepare price for viewing
\OxidEsales\Eshop\Core\Price | $oPrice | price object |
|
protected |
Depending on view mode prepare oxPrice object
bool | $blCalculationModeNetto | - if calculation mode netto - true |
|
protected |
Place to hook to return variant max price if it might be different, for example for subshops.
|
protected |
Place to hook to return variant min price if it might be different, for example for subshops.
|
protected |
Gets similar list.
string | $sAttributeSql | Attribute selection snippet |
int | $iCnt | Similar list article count |
|
protected |
Return price suffix
|
protected |
Return variant max price
|
protected |
Return variant min price
|
protected |
Checks if parent has ANY variant assigned
bool | $blForceCoreTable | force core table usage |
|
protected |
Checks if article has uploaded master image for selected picture
int | $iIndex | master picture index |
|
protected |
Sets article creation date (\OxidEsales\Eshop\Application\Model\Article::oxarticles__oxinsert). Then executes parent method parent::_insert() and returns insertion status.
|
protected |
Detects if field is empty.
string | $sFieldName | Field name |
|
protected |
Detects if field is an image field by field name
string | $sFieldName | Field name |
|
protected |
Checks and return true if price view mode is netto
|
protected |
Check if stock status has changed since loading the article
|
protected |
Check if visibility has changed since loading the article
|
protected |
Loads data from database and returns it.
string | $articleId |
|
protected |
Get data from db
string | $articleId | id |
|
protected |
Loads and returns variants list.
bool | $loadSimpleVariants | if parameter $blSimple - list will be filled with oxSimpleVariant objects, else - oxArticle |
bool | $blRemoveNotOrderables | if true, removes from list not orderable articles, which are out of stock [optional] |
bool | null | $forceCoreTableUsage | if true forces core table use, default is false [optional] |
|
protected |
|
protected |
Modifies article price according to selected select list value
double | $dPrice | Modifiable price |
array | $aChosenList | Selection list array |
|
protected |
Resets category and vendor counts. This method is supposed to be called on article change trigger.
string | $sOxid | object to reset id ID |
string | $sVendorId | Vendor ID |
string | $sManufacturerId | Manufacturer ID |
|
protected |
Resets article count cache when stock value is zero and article goes offline.
string | $sOxid | product id |
|
protected |
Updates article stock. This method is supposed to be called on article change trigger.
string | $parentId | product parent id |
|
protected |
Updates variant count. This method is supposed to be called on article change trigger.
string | $parentId | Parent ID |
|
protected |
double | $dPrice |
|
protected |
Depending on view mode prepare price before calculation
double | $dPrice | - price |
double | $dVat | - VAT |
bool | $blCalculationModeNetto | - if calculation mode netto - true |
|
protected |
inserts article long description to artextends table
|
protected |
Saves values of sorting fields on article load.
|
protected |
Selects category IDs from given SQL statement and ID field name
string | $query | sql statement |
string | $field | category ID field name |
|
protected |
\OxidEsales\Eshop\Application\Model\Article | $article |
|
protected |
Updates variant min price. This method is supposed to be called on article change trigger.
string | $sParentId | Parent ID |
|
protected |
Removes object data fields (oxarticles__oxtimestamp, oxarticles__oxparentid, oxarticles__oxinsert).
|
protected |
Executes \OxidEsales\Eshop\Application\Model\Article::_skipSaveFields() and updates article information
|
protected |
Set parent field value to child - variants in DB
OxidEsales\EshopCommunity\Application\Model\Article::addToRatingAverage | ( | $rating | ) |
Calculates and saves product rating average
integer | $rating | new rating value |
OxidEsales\EshopCommunity\Application\Model\Article::appendLink | ( | $sAddParams, | |
$iLang = null |
|||
) |
Appends article seo url with additional request parameters
string | $sAddParams | additional parameters which needs to be added to product url |
int | $iLang | language id |
OxidEsales\EshopCommunity\Application\Model\Article::appendStdLink | ( | $sAddParams, | |
$iLang = null |
|||
) |
Appends article dynamic url with additional request parameters
string | $sAddParams | additional parameters which needs to be added to product url |
int | $iLang | language id |
OxidEsales\EshopCommunity\Application\Model\Article::applyDiscountsForVariant | ( | $oPrice | ) |
Applies discounts which should be applied in general case (for 0 amount)
\OxidEsales\Eshop\Core\Price | $oPrice | Price object |
OxidEsales\EshopCommunity\Application\Model\Article::applyVats | ( | \OxidEsales\Eshop\Core\Price | $oPrice | ) |
apply article and article use
\OxidEsales\Eshop\Core\Price | $oPrice | target price |
OxidEsales\EshopCommunity\Application\Model\Article::assign | ( | $aRecord | ) |
Assigns to oxarticle object some base parameters/values (such as detaillink, moredetaillink, etc).
array | $aRecord | Array representing current field values |
|
protected |
Collecting assigned to article amount-price list.
OxidEsales\EshopCommunity\Application\Model\Article::checkForStock | ( | $dAmount, | |
$dArtStockAmount = 0 , |
|||
$selectForUpdate = false |
|||
) |
Checks if stock configuration allows to buy user chosen amount $dAmount
double | $dAmount | buyable amount |
double | int | $dArtStockAmount | stock amount |
bool | $selectForUpdate | Set true to select for update |
OxidEsales\EshopCommunity\Application\Model\Article::checkForVpe | ( | $amount | ) |
Place to hook and change amount if it should be calculated by different logic, for example VPE.
double | $amount | Amount |
|
protected |
Create the sql for the fetchFirstInPriceCategory method.
string | $categoryPriceId | The price category id. |
OxidEsales\EshopCommunity\Application\Model\Article::delete | ( | $sOXID = null | ) |
Deletes record and other information related to this article such as images from DB, also removes variants. Returns true if entry was deleted.
string | $sOXID | Article id |
OxidEsales\EshopCommunity\Application\Model\Article::disablePriceLoad | ( | ) |
OxidEsales\EshopCommunity\Application\Model\Article::disableReminder | ( | ) |
Disables reminder functionality for article
OxidEsales\EshopCommunity\Application\Model\Article::enablePriceLoad | ( | ) |
Enable article price loading, if disabled.
|
protected |
Fetch the article corresponding to this object in the price category with the given id.
string | $categoryPriceId | The id of the category we want to check, if this article is in. |
OxidEsales\EshopCommunity\Application\Model\Article::getAccessoires | ( | ) |
Loads and returns array with accessories information.
OxidEsales\EshopCommunity\Application\Model\Article::getActiveCheckQuery | ( | $blForceCoreTable = null | ) |
Returns part of sql query used in active snippet. Query checks if product "oxactive = 1". If config option "blUseTimeCheck" is TRUE additionally checks if "oxactivefrom < current data < oxactiveto"
bool | $blForceCoreTable | force core table usage |
OxidEsales\EshopCommunity\Application\Model\Article::getAdminVariants | ( | $sLanguage = null | ) |
Loads article variants and returns variants list object. Article language may be set by passing with parameter, or GET/POST/Session variable.
string | $sLanguage | shop language. |
|
protected |
OxidEsales\EshopCommunity\Application\Model\Article::getArticleFiles | ( | $blAddFromParent = false | ) |
Return article downloadable file list (oxlist of oxfile)
bool | $blAddFromParent | - return with parent files if not buyable |
OxidEsales\EshopCommunity\Application\Model\Article::getArticleRatingAverage | ( | $blIncludeVariants = false | ) |
Returns product rating average
bool | $blIncludeVariants | - include variant ratings |
OxidEsales\EshopCommunity\Application\Model\Article::getArticleRatingCount | ( | $blIncludeVariants = false | ) |
Returns product rating count
bool | $blIncludeVariants | - include variant ratings |
OxidEsales\EshopCommunity\Application\Model\Article::getArticleUser | ( | ) |
OxidEsales\EshopCommunity\Application\Model\Article::getArticleVat | ( | ) |
retrieve article VAT (cached)
OxidEsales\EshopCommunity\Application\Model\Article::getAttributes | ( | ) |
Loads and returns attribute list associated with this article
OxidEsales\EshopCommunity\Application\Model\Article::getAttributesDisplayableInBasket | ( | ) |
Loads and returns attribute list for display in basket
OxidEsales\EshopCommunity\Application\Model\Article::getBasePrice | ( | $dAmount = 1 | ) |
Returns base article price from database. Price may differ according to users group Override this function if you want e.g. different prices for diff. usergroups.
double | $dAmount | article amount. Default is 1 |
OxidEsales\EshopCommunity\Application\Model\Article::getBaseSeoLink | ( | $iLang, | |
$blMain = false |
|||
) |
Returns raw article seo url
int | $iLang | language id |
bool | $blMain | force to return main url [optional] |
OxidEsales\EshopCommunity\Application\Model\Article::getBaseStdLink | ( | $iLang, | |
$blAddId = true , |
|||
$blFull = true |
|||
) |
Returns base dynamic url: shopurl/index.php?cl=details
int | $iLang | language id |
bool | $blAddId | add current object id to url or not [optional] |
bool | $blFull | return full including domain name [optional] |
OxidEsales\EshopCommunity\Application\Model\Article::getBasketPrice | ( | $dAmount, | |
$aSelList, | |||
$oBasket | |||
) |
OxidEsales\EshopCommunity\Application\Model\Article::getCategory | ( | ) |
Loads and returns article category object. First tries to load assigned category and is such category does not exist, tries to load category by price
OxidEsales\EshopCommunity\Application\Model\Article::getCategoryIds | ( | $blActCats = false , |
|
$blSkipCache = false |
|||
) |
Returns ID's of categories where this article is assigned
bool | $blActCats | select categories if all parents are active |
bool | $blSkipCache | Whether to skip cache |
OxidEsales\EshopCommunity\Application\Model\Article::getCrossSelling | ( | ) |
Loads and returns array with cross selling information.
OxidEsales\EshopCommunity\Application\Model\Article::getCustomerAlsoBoughtThisProducts | ( | ) |
Loads and returns articles list, bought by same customer.
OxidEsales\EshopCommunity\Application\Model\Article::getCustomVAT | ( | ) |
Returns custom article VAT value if possible By default value is taken from oxarticle__oxvat field
|
protected |
Get the database object.
OxidEsales\EshopCommunity\Application\Model\Article::getDeliveryDate | ( | ) |
Returns formatted delivery date. If the date is past or not set ('0000-00-00') returns false.
OxidEsales\EshopCommunity\Application\Model\Article::getDispSelList | ( | ) |
Returns select lists to display
OxidEsales\EshopCommunity\Application\Model\Article::getDynImageDir | ( | ) |
Get image url
OxidEsales\EshopCommunity\Application\Model\Article::getFMinPrice | ( | ) |
Returns formatted article min price
OxidEsales\EshopCommunity\Application\Model\Article::getFNetPrice | ( | ) |
Returns formatted product's NETTO price.
OxidEsales\EshopCommunity\Application\Model\Article::getFPrice | ( | ) |
Returns formatted product's price.
OxidEsales\EshopCommunity\Application\Model\Article::getFTPrice | ( | ) |
Returns rounded T price.
OxidEsales\EshopCommunity\Application\Model\Article::getFullVariants | ( | $blRemoveNotOrderables = true , |
|
$blForceCoreTable = null |
|||
) |
Returns variant list (list contains oxArticle objects)
bool | $blRemoveNotOrderables | if true, removes from list not orderable articles, which are out of stock [optional] |
bool | $blForceCoreTable | if true forces core table use, default is false [optional] |
OxidEsales\EshopCommunity\Application\Model\Article::getFUnitPrice | ( | ) |
Returns formatted price per unit
OxidEsales\EshopCommunity\Application\Model\Article::getFVarMinPrice | ( | ) |
Returns formatted min article variant price
OxidEsales\EshopCommunity\Application\Model\Article::getIconUrl | ( | $iIndex = 0 | ) |
Returns article icon picture url. If no index specified, will return main icon url.
int | $iIndex | picture index |
OxidEsales\EshopCommunity\Application\Model\Article::getItemKey | ( | ) |
Returns item key used with oxuserbasket
OxidEsales\EshopCommunity\Application\Model\Article::getLink | ( | $iLang = null , |
|
$blMain = false |
|||
) |
Gets article link
int | $iLang | language id [optional] |
bool | $blMain | force to return main url [optional] |
OxidEsales\EshopCommunity\Application\Model\Article::getLinkType | ( | ) |
Get link type
OxidEsales\EshopCommunity\Application\Model\Article::getLoadParentData | ( | ) |
Getter for do we load parent data
|
protected |
Forms query to load variants.
bool | $blRemoveNotOrderables | |
bool | $forceCoreTableUsage | |
oxSimpleVariant | oxarticle | $baseObject | |
string | $sArticleTable |
OxidEsales\EshopCommunity\Application\Model\Article::getLongDesc | ( | ) |
get long description, parsed through smarty. should only be used by exports or so. In templates use [{oxeval var=$oProduct->getLongDescription()->getRawValue()}]
OxidEsales\EshopCommunity\Application\Model\Article::getLongDescription | ( | ) |
Get article long description
OxidEsales\EshopCommunity\Application\Model\Article::getMainLink | ( | $iLang = null | ) |
Returns main object URL. If SEO is ON returned link will be in SEO form, else URL will have dynamic form
int | $iLang | language id [optional] |
OxidEsales\EshopCommunity\Application\Model\Article::getManufacturer | ( | $blShopCheck = true | ) |
Returns current article Manufacturer object. If $blShopCheck = false, then Manufacturer blReadOnly parameter will be set to true. If Manufacturer is not assigned to current shop
bool | $blShopCheck | Set false if shop check is not required (default is true) |
OxidEsales\EshopCommunity\Application\Model\Article::getManufacturerId | ( | ) |
Returns article object Manufacturer ID. Result is cached into self::$_aArticleManufacturers
OxidEsales\EshopCommunity\Application\Model\Article::getMasterZoomPictureUrl | ( | $iIndex | ) |
Get master zoom picture url
int | $iIndex | picture index |
OxidEsales\EshopCommunity\Application\Model\Article::getMdSubvariants | ( | ) |
Returns first level variants from multidimensional variants list
OxidEsales\EshopCommunity\Application\Model\Article::getMdVariants | ( | ) |
Returns multidimensional variant structure
OxidEsales\EshopCommunity\Application\Model\Article::getMediaUrls | ( | ) |
Return article media URL
OxidEsales\EshopCommunity\Application\Model\Article::getMinPrice | ( | ) |
Returns article min price in calculation included variants
OxidEsales\EshopCommunity\Application\Model\Article::getMoreDetailLink | ( | ) |
Get more details link
OxidEsales\EshopCommunity\Application\Model\Article::getParentArticle | ( | ) |
Get parent article
OxidEsales\EshopCommunity\Application\Model\Article::getParentId | ( | ) |
Returns product parent id (oxparentid)
OxidEsales\EshopCommunity\Application\Model\Article::getPersParams | ( | ) |
Get persistent parameters
OxidEsales\EshopCommunity\Application\Model\Article::getPictureFieldValue | ( | $sFieldName, | |
$iIndex = null |
|||
) |
Return article picture file name
string | $sFieldName | article picture field name |
int | $iIndex | article picture index |
OxidEsales\EshopCommunity\Application\Model\Article::getPictureGallery | ( | ) |
collect article pics, icons, zoompic and puts it all in an array structure of array (ActPicID, ActPic, MorePics, Pics, Icons, ZoomPic)
OxidEsales\EshopCommunity\Application\Model\Article::getPictureUrl | ( | $iIndex = 1 | ) |
Returns article picture
int | $iIndex | picture index |
OxidEsales\EshopCommunity\Application\Model\Article::getPrice | ( | $dAmount = 1 | ) |
Calculates and returns price of article (adds taxes and discounts).
float | int | $dAmount | article amount. |
OxidEsales\EshopCommunity\Application\Model\Article::getProductId | ( | ) |
Returns product id (oxid) (required for interface oxIArticle)
OxidEsales\EshopCommunity\Application\Model\Article::getReviews | ( | ) |
Collects user written reviews about an article.
OxidEsales\EshopCommunity\Application\Model\Article::getSelections | ( | $iLimit = null , |
|
$aFilter = null |
|||
) |
Returns product selections lists array (used in azure theme)
int | $iLimit | if given - will load limited count of selections [optional] |
array | $aFilter | selection filter [optional] |
OxidEsales\EshopCommunity\Application\Model\Article::getSelectLists | ( | $sKeyPrefix = null | ) |
Returns all selectlists this article has (used in oxbasket)
string | $sKeyPrefix | Optional key prefix |
OxidEsales\EshopCommunity\Application\Model\Article::getSimilarProducts | ( | ) |
Returns a list of similar products.
OxidEsales\EshopCommunity\Application\Model\Article::getSimpleVariants | ( | ) |
Simple way to get variants without querying oxArticle table first. This is basically used for lists.
OxidEsales\EshopCommunity\Application\Model\Article::getSize | ( | ) |
Return Size of product: length*width*height
OxidEsales\EshopCommunity\Application\Model\Article::getSqlActiveSnippet | ( | $blForceCoreTable = null | ) |
Returns SQL select string with checks if items are available
bool | $blForceCoreTable | forces core table usage (optional) |
OxidEsales\EshopCommunity\Application\Model\Article::getSqlForPriceCategories | ( | $sFields = '' | ) |
get Sql for loading price categories which include this article
string | $sFields | fields to load from oxCategories |
OxidEsales\EshopCommunity\Application\Model\Article::getStdLink | ( | $iLang = null , |
|
$aParams = [] |
|||
) |
Returns standard URL to product
int | $iLang | required language. optional |
array | $aParams | additional params to use [optional] |
OxidEsales\EshopCommunity\Application\Model\Article::getStockCheckQuery | ( | $blForceCoreTable = null | ) |
Returns part of sql query used in active snippet. If config option "blUseStock" is TRUE checks if "oxstockflag != 2 or ( oxstock + oxvarstock ) > 0". If config option "blVariantParentBuyable" is TRUE checks if product has variants, and if has - checks is there at least one variant which is buyable. If config option option "blUseTimeCheck" is TRUE additionally checks if variants "oxactivefrom < current data < oxactiveto"
bool | $blForceCoreTable | force core table usage |
OxidEsales\EshopCommunity\Application\Model\Article::getStockStatus | ( | ) |
Get stock status
OxidEsales\EshopCommunity\Application\Model\Article::getThumbnailUrl | ( | $bSsl = null | ) |
Returns article thumbnail picture url
bool | $bSsl | to force SSL |
OxidEsales\EshopCommunity\Application\Model\Article::getToBasketLink | ( | ) |
Get to basket link
OxidEsales\EshopCommunity\Application\Model\Article::getTPrice | ( | ) |
Returns T price
OxidEsales\EshopCommunity\Application\Model\Article::getUnitName | ( | ) |
Returns oxarticles__oxunitname value processed by \OxidEsales\Eshop\Core\Language::translateString()
OxidEsales\EshopCommunity\Application\Model\Article::getUnitPrice | ( | ) |
Returns price per unit
OxidEsales\EshopCommunity\Application\Model\Article::getUnitQuantity | ( | ) |
Return unit quantity
OxidEsales\EshopCommunity\Application\Model\Article::getVariantIds | ( | $blActiveVariants = true | ) |
Collects and returns active/all variant ids of article.
bool | $blActiveVariants | Parameter to load only active variants. |
OxidEsales\EshopCommunity\Application\Model\Article::getVariants | ( | $blRemoveNotOrderables = true , |
|
$blForceCoreTable = null |
|||
) |
Collects and returns article variants. Note: Only active variants are returned by this method. If you need full variant list use \OxidEsales\Eshop\Application\Model\Article::getAdminVariants()
bool | $blRemoveNotOrderables | if true, removes from list not orderable articles, which are out of stock |
bool | $blForceCoreTable | if true forces core table use, default is false [optional] |
OxidEsales\EshopCommunity\Application\Model\Article::getVariantsCount | ( | ) |
Returns amount of variants article has
OxidEsales\EshopCommunity\Application\Model\Article::getVariantSelections | ( | $aFilterIds = null , |
|
$sActVariantId = null , |
|||
$iLimit = 0 |
|||
) |
Returns variants selections lists array
array | $aFilterIds | ids of active selections [optional] |
string | $sActVariantId | active variant id [optional] |
int | $iLimit | limit variant lists count (if non zero, return limited number of multidimensional variant selections) |
OxidEsales\EshopCommunity\Application\Model\Article::getVariantsQuery | ( | $blRemoveNotOrderables, | |
$blForceCoreTable = null |
|||
) |
Returns part of query which checks if product is variant of current object. Additionally if config option "blUseStock" is TRUE checks stock state "( oxstock > 0 or ( oxstock <= 0 and ( oxstockflag = 1 or oxstockflag = 4 ) )"
bool | $blRemoveNotOrderables | remove or leave non orderable products |
bool | $blForceCoreTable | force core table usage |
OxidEsales\EshopCommunity\Application\Model\Article::getVarMinPrice | ( | ) |
Returns article min price of variants
OxidEsales\EshopCommunity\Application\Model\Article::getVendor | ( | $blShopCheck = true | ) |
Returns current article vendor object. If $blShopCheck = false, then vendor loading will fallback to oxI18n object and blReadOnly parameter will be set to true if vendor is not assigned to current shop
bool | $blShopCheck | Set false if shop check is not required (default is true) |
OxidEsales\EshopCommunity\Application\Model\Article::getVendorId | ( | ) |
Returns article object vendor ID. Result is cached into self::$_aArticleVendors
OxidEsales\EshopCommunity\Application\Model\Article::getWeight | ( | ) |
Return product weight
OxidEsales\EshopCommunity\Application\Model\Article::getZoomPictureUrl | ( | $iIndex = '' | ) |
Returns article zoom picture url
int | $iIndex | picture index |
OxidEsales\EshopCommunity\Application\Model\Article::hasAmountPrice | ( | ) |
Checks if articles has amount price
OxidEsales\EshopCommunity\Application\Model\Article::hasDownloadableAgreement | ( | ) |
Returns if article has downloadable agreement with which customer will have to agree.
OxidEsales\EshopCommunity\Application\Model\Article::hasIntangibleAgreement | ( | ) |
Returns if article has intangible agreement with which customer will have to agree.
OxidEsales\EshopCommunity\Application\Model\Article::hasMdVariants | ( | ) |
Checks if article has multidimensional variants
OxidEsales\EshopCommunity\Application\Model\Article::hasSortingFieldsChanged | ( | ) |
Checks whether sorting fields changed from last article loading.
OxidEsales\EshopCommunity\Application\Model\Article::inCategory | ( | $sCatNid | ) |
Checks if article is assigned to category $sCatNID.
string | $sCatNid | category ID |
OxidEsales\EshopCommunity\Application\Model\Article::inPriceCategory | ( | $categoryPriceId | ) |
Checks if article is assigned to price category $sCatNID.
string | $categoryPriceId | Price category ID |
OxidEsales\EshopCommunity\Application\Model\Article::isAssignedToCategory | ( | $sCatId | ) |
Checks if article is assigned to passed category (even checks if this category is "price category"). Returns true on success.
string | $sCatId | category ID |
OxidEsales\EshopCommunity\Application\Model\Article::isBuyable | ( | ) |
Checks if article is buyable.
OxidEsales\EshopCommunity\Application\Model\Article::isDownloadable | ( | ) |
Returns oxarticles__oxisdownloadable value
OxidEsales\EshopCommunity\Application\Model\Article::isInList | ( | ) |
Checks whether object is in list or not It's needed for oxArticle so that it can pass this to widgets
OxidEsales\EshopCommunity\Application\Model\Article::isMdVariant | ( | ) |
Returns TRUE if product is multidimensional variant, and false if not
OxidEsales\EshopCommunity\Application\Model\Article::isMultilingualField | ( | $sFieldName | ) |
Returns true if the field is multilanguage
string | $sFieldName | Field name |
OxidEsales\EshopCommunity\Application\Model\Article::isNotBuyable | ( | ) |
Returns true if article is not buyable
OxidEsales\EshopCommunity\Application\Model\Article::isOnComparisonList | ( | ) |
Checks whether article is inluded in comparison list
OxidEsales\EshopCommunity\Application\Model\Article::isOrderArticle | ( | ) |
Returns false if object is not derived from oxorderarticle class
OxidEsales\EshopCommunity\Application\Model\Article::isParentNotBuyable | ( | ) |
Returns true if parent is not buyable
OxidEsales\EshopCommunity\Application\Model\Article::isPriceAlarm | ( | ) |
Checks if price alarm is enabled.
OxidEsales\EshopCommunity\Application\Model\Article::isRangePrice | ( | ) |
Returns true if article has variant with different price
OxidEsales\EshopCommunity\Application\Model\Article::isVariant | ( | ) |
Returns TRUE if product is variant, and false if not
OxidEsales\EshopCommunity\Application\Model\Article::isVisible | ( | ) |
Checks if article has visible status. Returns TRUE if its visible
OxidEsales\EshopCommunity\Application\Model\Article::load | ( | $sOXID | ) |
Loads object data from DB (object data ID must be passed to method). Converts dates (\OxidEsales\Eshop\Application\Model\Article::oxarticles__oxinsert) to international format (oxUtils.php \OxidEsales\Eshop\Core\Registry::getUtilsDate()->formatDBDate(...)). Returns true if article was loaded successfully.
string | $sOXID | Article object ID |
OxidEsales\EshopCommunity\Application\Model\Article::loadAmountPriceInfo | ( | ) |
Returns list object with info about article price that depends on amount in basket. Takes data from oxprice2article table. Returns false if such info is not set.
OxidEsales\EshopCommunity\Application\Model\Article::onChange | ( | $action = null , |
|
$articleId = null , |
|||
$parentArticleId = null |
|||
) |
This function is triggered whenever article is saved or deleted or after the stock is changed. Originally we need to update the oxstock for possible article parent in case parent is not buyable Plus you may want to extend this function to update some extended information. Call \OxidEsales\Eshop\Application\Model\Article::onChange($sAction, $sOXID) with ID parameter when changes are executed over SQL. (or use module class instead of oxArticle if such exists)
string | $action | Action constant |
string | $articleId | Article ID |
string | $parentArticleId | Parent ID |
OxidEsales\EshopCommunity\Application\Model\Article::reduceStock | ( | $dAmount, | |
$blAllowNegativeStock = false |
|||
) |
Reduce article stock. return the affected amount
float | $dAmount | amount to reduce |
bool | $blAllowNegativeStock | are negative stocks allowed? |
OxidEsales\EshopCommunity\Application\Model\Article::resetParent | ( | ) |
Changes article variant to parent article
OxidEsales\EshopCommunity\Application\Model\Article::resetRemindStatus | ( | ) |
Resets oxremindactive status. If remindActive status is 2, reminder is already sent.
OxidEsales\EshopCommunity\Application\Model\Article::save | ( | ) |
(\OxidEsales\Eshop\Application\Model\Article::_saveArtLongDesc()) save the object using parent::save() method.
OxidEsales\EshopCommunity\Application\Model\Article::setAmountPriceList | ( | $amountPriceList | ) |
\OxidEsales\Eshop\Application\Model\AmountPriceList | $amountPriceList |
OxidEsales\EshopCommunity\Application\Model\Article::setArticleLongDesc | ( | $longDescription | ) |
Save article long description to oxartext table
string | $longDescription | description to set |
OxidEsales\EshopCommunity\Application\Model\Article::setArticleUser | ( | $oUser | ) |
sets article user
\OxidEsales\Eshop\Application\Model\User | $oUser | user to set |
OxidEsales\EshopCommunity\Application\Model\Article::setBuyableState | ( | $blBuyable = false | ) |
Sets product state - buyable or not
bool | $blBuyable | state - buyable or not (default false) |
OxidEsales\EshopCommunity\Application\Model\Article::setId | ( | $sId = null | ) |
Sets object ID, additionally sets $this->oxarticles__oxnid field value
string | $sId | New ID |
OxidEsales\EshopCommunity\Application\Model\Article::setItemKey | ( | $sItemKey | ) |
Sets item key used with oxuserbasket
string | $sItemKey | Item key |
OxidEsales\EshopCommunity\Application\Model\Article::setLinkType | ( | $iType | ) |
Resets details link
int | $iType | type of link to load |
OxidEsales\EshopCommunity\Application\Model\Article::setLoadParentData | ( | $blLoadParentData | ) |
A setter for $_blLoadParentData (whether article parent info should be laoded fully) class variable
bool | $blLoadParentData | Whether to load parent data |
OxidEsales\EshopCommunity\Application\Model\Article::setNoVariantLoading | ( | $blLoadVariants | ) |
Disables/enables variant loading
bool | $blLoadVariants | skip variant loading or not |
OxidEsales\EshopCommunity\Application\Model\Article::setOnComparisonList | ( | $blOnList | ) |
Set if article is inluded in comparison list
bool | $blOnList | Whether is article on the list |
OxidEsales\EshopCommunity\Application\Model\Article::setPrice | ( | \OxidEsales\Eshop\Core\Price | $oPrice | ) |
Sets the current oxPrice object
\OxidEsales\Eshop\Core\Price | $oPrice | the new price object |
OxidEsales\EshopCommunity\Application\Model\Article::setRangePrice | ( | $blIsRangePrice = true | ) |
Setter to set if article has range price
bool | $blIsRangePrice | - true if range, else false |
OxidEsales\EshopCommunity\Application\Model\Article::setRatingAverage | ( | $iRating | ) |
Set product rating average
integer | $iRating | new rating value |
OxidEsales\EshopCommunity\Application\Model\Article::setRatingCount | ( | $iRatingCnt | ) |
Set product rating count
integer | $iRatingCnt | new rating count |
OxidEsales\EshopCommunity\Application\Model\Article::setSelectlist | ( | $aSelList | ) |
Sets selectlists of current product
array | $aSelList | selectlist |
OxidEsales\EshopCommunity\Application\Model\Article::setSkipAssign | ( | $blSkipAssign | ) |
Assign condition setter. In case article assignment is skipped ($_blSkipAssign = true), it does not perform additional
bool | $blSkipAssign | Whether to skip assign process for the article |
OxidEsales\EshopCommunity\Application\Model\Article::skipDiscounts | ( | ) |
Checks if discount should be skipped for this article in basket. Returns true if yes.
|
protected |
\OxidEsales\Eshop\Application\Model\Manufacturer | $oManufacturer |
OxidEsales\EshopCommunity\Application\Model\Article::updateSoldAmount | ( | $dAmount = 0 | ) |
Recursive function. Updates quantity of sold articles. Return true if amount was changed in database.
float | $dAmount | Number of articles sold |
|
protected |
Set needed parameters to article list object like language.
\OxidEsales\Eshop\Core\Model\BaseModel | $baseObject | article list template object. |
bool | null | $forceCoreTableUsage | if true forces core table use, default is false [optional] |
OxidEsales\EshopCommunity\Application\Model\Article::updateVariantsRemind | ( | ) |
Updates article variants oxremindactive field, as variants inherit this setting from parent
|
staticprotected |
|
protected |
|
staticprotected |
|
staticprotected |
|
staticprotected |
|
protected |
|
protected |
|
staticprotected |
|
protected |
|
protected |
|
protected |
|
staticprotected |
|
staticprotected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Variable used to determine if setting parentId to empty value is allowed
|
protected |
|
protected |
|
staticprotected |
|
protected |
$_blHasVariants is set to true if article has multidimensional variants.
|
protected |
$_blHasVariants is set to true if article has any variants.
|
protected |
|
protected |
|
protected |
|
protected |
Variable used to force load parent data in export
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Variable used to force load parent data in export
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
$_fPricePerUnit holds price per unit value in active shop currency. $_fPricePerUnit is calculated from \OxidEsales\Eshop\Application\Model\Article::oxarticles__oxunitquantity->value and from \OxidEsales\Eshop\Application\Model\Article::oxarticles__oxuniname->value. If either one of these values is empty then $_fPricePerUnit is not calculated. Example: In case when product price is 10 EUR and product quantity is 0.5 (liters) then $_fPricePerUnit would be 20,00
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |