Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Show manufacturer on Invoice

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 11-21-2005, 04:31 AM
 
VTX VTX is offline
 

Member
  
Join Date: Oct 2005
Posts: 11
 

Default Show manufacturer on Invoice

Does anyone know how to show the manufacturer of the products on the invoice? I searched and found how to do it on the product details page, but I cant figure out what I need to do in order to get the manufacturer displayed on the invoice (after ordering & the email recieved).
__________________
X-Cart Gold 4.0.16
Reply With Quote
  #2  
Old 11-22-2005, 11:07 PM
 
VTX VTX is offline
 

Member
  
Join Date: Oct 2005
Posts: 11
 

Default

Nobody knows how to do this? I would appreciate it very much
__________________
X-Cart Gold 4.0.16
Reply With Quote
  #3  
Old 04-19-2006, 03:20 PM
 
sundance sundance is offline
 

Member
  
Join Date: Oct 2004
Posts: 27
 

Default

Here is a TOTALLY DIRTY way to show the Manufacturer Names on Invoices.

Apply this fix to:
/mail/html/order_data.tpl

You can place it where you want, but in this instance I have placed it just after
Code:
{foreach from=$products item=product} <TR> <TD align="center">{$product.productcode}</TD> <TD><FONT style="FONT-SIZE: 11px">

so that the manufacturer name appears on the invoice with a comma, followed by the product name.

Code:
{* RG Add Manufacturer to Invoice Start *} {php} $manid=$this->_tpl_vars['product']['manufacturerid'] ; $productman= func_query_first_cell("select manufacturer from xcart_manufacturers where manufacturerid=$manid"); if ($productman!="") { echo " $productman, "; } {/php} {* RG Add Manufacturer to Invoice End *}

These are the reasons this fix is BAD:

1. It is hardcoded PHP in a template
2. I have hardcoded the xcart table name (xcart_manufacturers) into the template - this may need to change depending on your table names.
3. There MUST be a more elegant way to do the database call than hardcoded here in the template like this, but necessity has forced me to produce this dirty fix instead.

This is the reason this fix is GOOD:

1. It works.

Hope this helps somebody.

Rob
__________________
Xcart 4.0.17
Reply With Quote
  #4  
Old 03-23-2007, 06:09 AM
 
fearnothing fearnothing is offline
 

Senior Member
  
Join Date: Jun 2005
Location: North East England
Posts: 124
 

Default Re: Show manufacturer on Invoice

Hey sundance - just in the process of moving over all my products to manufacturer based, and this tweak is exactly what I needed.

Thanks for sharing your knowledge - a 'dirty' fix it may be, but very effective indeed!
__________________
www.smartchoicemusic.com
Smart Choice Music - Import CD and DVD Specialists
4.6.0
MySQL 5.5.34
PHP 5.4.24
Apache/2.2.26
Multiple homegrown and paid-for mods
Reply With Quote
  #5  
Old 11-05-2007, 12:15 PM
 
brocillator brocillator is offline
 

Newbie
  
Join Date: Sep 2007
Location: Florida, USA
Posts: 8
 

Default Re: Show manufacturer on Invoice

does anybody know the xcart table name (xcart_manufacturers) in 4.1.8?

I can't find this in any files.
__________________
X-Cart Gold 4.1.8
AOM 4.1.8
Apache 1.3.37 (Unix)
OS Linux
PHP 5.2.3
SQL 5.0.45
Reply With Quote
  #6  
Old 07-30-2008, 10:49 PM
 
retrtrtrytrutru retrtrtrytrutru is offline
 

Senior Member
  
Join Date: Aug 2007
Posts: 101
 

Default Re: Show manufacturer on Invoice

This thread is old, I know but I am looking for the exact same fix. I need to include the manufacturer name on the order lines but I don't know how to do that. X-Cart v4.1.8. Anyone have a clue? Thanks!
__________________
www.qualitylamps.eu
X-Cart Gold 4.1.8, PHP 5.2.6, MySQL 5.0.51a, Apache 2.2.9

www.vervangjelamp.nl
X-Cart Gold 4.2.0, PHP 5.2.6, MySQL 5.0.37-standard, Apache/2

Sorry for the weird user name, I registered it by mistake
Reply With Quote
  #7  
Old 08-16-2008, 05:00 PM
 
pcparts pcparts is offline
 

Advanced Member
  
Join Date: Jul 2006
Location: Aussie
Posts: 85
 

Default Re: Show manufacturer on Invoice

Try this skin1/mail/html/order_data.tpl

Around line 14 under
Code:
<th width="60" bgcolor="#cccccc">{$lng.lbl_sku}</th>

add
Code:
<th width="100" bgcolor="#cccccc">{$lng.lbl_manufacturer}</th>


Around line 27 under
Code:
<td align="center">{$product.productcode}</td>

add
Code:
<td align="center">{* RG Add Manufacturer to Invoice Start *} {php} $manid=$this->_tpl_vars['product']['manufacturerid'] ; $productman= func_query_first_cell("select manufacturer from xcart_manufacturers where manufacturerid=$manid"); if ($productman!="") { echo " $productman "; } {/php} {* RG Add Manufacturer to Invoice End *}</td>


Then around line 74 Above

Code:
{$lng.lbl_gift_certificate}: {$gc.gcid}<br />

Add
Code:
<td nowrap="nowrap">

Greg
__________________
Greg
X-CART Gold 4.1.10
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 11:49 PM.

   

 
X-Cart forums © 2001-2020