How to display category name in basket and order summary?

vaikis

No avatar

2007-05-09 12:18

In "order details" page I need to show the sub subcategorie name near item name.
So the customer will see from which subcategorie the Item was choosen.

I mean "orders_summary.tpl"

merci

No avatar

2007-05-09 12:20

1) edit file core/orders.php, under this line:

$content  null;


paste this:

$aCategories  throwProductsCategories( );


and under this line:

$fSummary +=  $aList['fSummary'];


paste this:

$aList['sCategories'] = throwTreeForProduct$aCategories[$aList['iProduct']], $sFile );



2) open file templates/orders_delivery.tpl and in block LIST_LIST before $aList[sProduct] paste this:
$aList[sCategories] »
and in the end of file paste:

<!-- BEGIN TREE_PARENT --><a href="?p=productsList&amp;iCategory=$aListTree[iParent]" >$aListTree[sParent]</a><!-- END TREE_PARENT -->

<!-- 
BEGIN PARENT_SEPARATOR -->&raquo;<!-- END PARENT_SEPARATOR -->

<!-- 
BEGIN TREE_CHILD --><a href="?p=productsList&amp;iCategory=$aListTree[iChild]" >$aListTree[sChild]</a><!-- END TREE_CHILD -->

<!-- 
BEGIN TREE_SEPARATOR -->|<!-- END TREE_SEPARATOR -->



3) do the same as in 2) for file templates/orders_basket.tpl

vaikis

No avatar

2007-05-09 15:30

Thank you very much!!!!, this was what i need. you are geniuos ;)

Greetings from Lithuania ;)

vaikis

No avatar

2007-05-09 15:40

ups, one problem, when i push Order button this happens:
Fatal error: Call to undefined function throwProductsCategories() in ..\core\orders.php on line 137

merci

No avatar

2007-05-10 09:46

vaikis - the solution I gave you is tested in Quick.cart v 2.1 and works good, so maybe you have some plugins installed in your Quick.cart and they cause the problem.

vaikis

No avatar

2007-05-10 16:25

i checked on fresh 2.1 version, and seems all is working, but in order list page (admin menu) if you push "More" button to see order you will get:

Fatal error: Call to undefined function throwCategories() in ..\core\products-ff.php on line 88

vaikis

No avatar

2007-05-11 08:04

no solution?

merci

No avatar

2007-05-11 10:35

vaikis - open file admin.php and paste there near 40 line

require_once DIR_CORE.'categories-'.DB_TYPE.'.php';
require_once 
DIR_CORE.'categories.php';

You have to also paste in templates/admin/orders_details.tpl blocks:

<!-- BEGIN TREE_PARENT --><a href="?p=productsList&amp;iCategory=$aListTree[iParent]" >$aListTree[sParent]</a><!-- END TREE_PARENT -->

<!-- 
BEGIN PARENT_SEPARATOR -->&raquo;<!-- END PARENT_SEPARATOR -->

<!-- 
BEGIN TREE_CHILD --><a href="?p=productsList&amp;iCategory=$aListTree[iChild]" >$aListTree[sChild]</a><!-- END TREE_CHILD -->

<!-- 
BEGIN TREE_SEPARATOR -->|<!-- END TREE_SEPARATOR -->

Does it work?

vaikis

No avatar

2007-05-11 11:08

yes, it works!

Thank you again. this was my biggest headache in few days :)

qwerty@de.hu

No avatar

2007-05-11 12:49

dose this work in 1.4 version?

treewood (OpenSolution)

Avatar: treewood

2007-05-11 15:17

qwerty@de.hu - nope but You can try to do it maybe You will get this in v1.4.

Back to top
about us | contact