@@ -589,12 +589,19 @@ public function getOrderDetailBasic($order)
589589 foreach ($ order ->getItemsCollection (array (), true ) as $ item ) {
590590 $ itemWithTax = $ item ->getRowTotal ();
591591 $ itemTax = $ item ->getTaxAmount ();
592+
593+ $ productId = $ item ->getProductId ();
594+ $ product = Mage::getModel ('catalog/product ' )->load ($ productId );
595+
596+ $ adminUrl = $ urlModel ->getUrl ('adminhtml/zendesk/redirect ' , array ('id ' => $ productId , 'type ' => 'product ' ));
597+
592598 $ orderInfo ['relationships ' ]['items ' ]['data ' ][] = array (
593599 'type ' => 'order_item ' ,
594600 'id ' => $ item ->getItemId (),
595601 'product_id ' => $ item ->getProductId (),
596602 'name ' => $ item ->getName (),
597603 'sku ' => $ item ->getSku (),
604+ 'url ' => $ adminUrl ,
598605 'quantity ' => intval ($ item ->getQtyOrdered ()),
599606 'refunded ' => intval ($ item ->getQtyRefunded ()),
600607 'meta ' => array (
@@ -606,6 +613,13 @@ public function getOrderDetailBasic($order)
606613 'timestamps ' => array (
607614 'created_at ' => $ item ->getCreatedAt (),
608615 'updated_at ' => $ item ->getUpdatedAt (),
616+ ),
617+ 'product ' => array (
618+ 'status ' => $ product ->getStatus (),
619+ 'type ' => $ product ->getTypeId (),
620+ 'url ' => $ product ->getUrlPath (),
621+ 'image ' => $ product ->getThumbnail (),
622+ 'description ' => $ product ->getDescription (),
609623 )
610624 )
611625 );
0 commit comments