View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002522 | OXID eShop (all versions) | 4.08. Cache | public | 2011-02-15 10:13 | 2012-12-10 13:39 |
Reporter | tjungcl | Assigned To | |||
Priority | normal | Severity | major | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | 4.4.6 revision 32697 | ||||
Summary | 0002522: article _resetCache: several bugs | ||||
Description | - resets nothing when frontend and blUseStock is false. For example, frontend-user adds a new tag, but the article-cache is not reseted. - deletes the whole cache, if article is part of an action. However, it does not delete the cache, if the article is part of an action and has a parent, which is NOT part of an action. - wrong parentid is used if sOxId-param is defined and $this has an id too (then it uses this->oxparentid instead of the parent of sOxId) - as implemented now, the sOxId-params only effect is, that the cache is completly reset, if sOxId-param is part of an action. After having checked that (and if it was NOT part of an action), the sOxId-param is replaced with this->oxid and the rest of the reset-code is evaluated with this->oxid. So, the function called with sOxId does not really reset the cache for $sOxId, but does a bit reseting with sOxId, and the rest with $this->oxid. | ||||
Additional Information | suggestions for fixes: //OxId-Param-Fix. Also fixes wrong parent-id-bug. protected function _resetCache( $sOxId = null ){ //if function is called with oxid !== this, load that article (simple + stock) and run resetcache there. if ($sOxId and $sOxId !== $this->getId()){ $oArt = oxNew( 'oxarticle' ); $oArt->setSkipAssign(true); $oArt->load($sOxId); $oArt->_assignStock(); return $oArt->_resetCache(); } ... //fix for oxid-action vs parentid-action $sQ = "select 1 from oxactions2article where oxartid=$sOxIdQuoted"; if ($sParentId) $sQ.=" or oxartid=".$oDb->quote($sParentId); ... } // if dont have a suggestion for the blUseStock bug. | ||||
Tags | No tags attached. | ||||
Theme | |||||
Browser | All | ||||
PHP Version | any | ||||
Database Version | any | ||||