View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0006186 | OXID eShop (all versions) | 4.01. Database handling | public | 2015-07-13 09:46 | 2024-02-13 11:02 |
Reporter | d3 | Assigned To | |||
Priority | normal | Severity | minor | Reproducibility | always |
Status | acknowledged | Resolution | open | ||
Product Version | 4.7.0 / 5.0.0 revision 51243 | ||||
Summary | 0006186: oxArticle::delete() method is inconsistent | ||||
Description | The method does'nt check if a database entry with this oxid exists. So the called method oxArticle::_updateParentDependFields() resets multiple fields in table oxarticles. KH | ||||
Steps To Reproduce | Try: /** @var $oArticle oxarticle * */ $oArticle = oxNew('oxarticle'); $oArticle->delete('IdDoesNotExists'); and the SQL of oxArticle::_updateParentDependFields looks like: UPDATE `oxarticles` SET `oxnonmaterial` = '0', `oxfreeshipping` = '0', `oxisdownloadable` = '0', `oxshowcustomagreement` = '0' WHERE `oxparentid` = '' | ||||
Additional Information | oxArticle::delete() should use oxArticle::exists() before the method take action | ||||
Tags | No tags attached. | ||||
Theme | Not defined | ||||
Browser | Not defined | ||||
PHP Version | Not defined | ||||
Database Version | Not defined | ||||