View Issue Details

IDProjectCategoryView StatusLast Update
0004935OXID eShop (all versions)4.07. Source code, Testpublic2015-12-01 10:23
Reporterdominik_ziegler 
PrioritynormalSeverityminorReproducibilitysometimes
Status acknowledgedResolutionopen 
Product Version4.6.6 revision 54646 
Target VersionFixed in Version 
Summary0004935: oxBasketItem::getArticle returns oxOrderArticle instance instead of oxArticle
DescriptionCreating a new virtual basket from existing order with the code below results in errors when using select lists.

The method getBasketArticles of oxBasket iterates over the article objects, fetches the object via oxBasketItem::getArticle and tries to execute "getSelectlist", but instead of oxArticle it has an oxOrderArticle where this method does not exist.

Called in a method in oxOrder:
$basket = $this->_getOrderBasket();
$this->_addOrderArticlesToBasket($basket, $this->getOrderArticles(true));
$basket->calculateBasket(true);

$basket->getBasketArticles() causes an error.

I think the problem is, that oxBasketItem::initFromOrderArticle sets the object in the class variable _oArticle and then returns it with oxBasketItem::getArticle, although the method should only return oxArticle.
TagsNo tags attached.
ThemeAzure, Mobile
BrowserAll
PHP VersionNot defined
Database VersionNot defined

Relationships

related to 0006113 acknowledgedflorian.auer getArticle method of oxbasketItem must be refactored 

Activities

There are no notes attached to this issue.