Zen Cart Logo
Forums / All Other Contributions/Addons / Super Orders v3.0 Support Thread (for ZC v1.3.9)

Super Orders v3.0 Support Thread (for ZC v1.3.9)

Views: 176,750

Results 921 to 940 of 1,018
19 Nov 2012, 11:09 PM
#921
abcisme avatar

abcisme

Zen Follower

Join Date:
Jun 2006
Posts:
298
Plugin Contributions:
0

Super Orders v3.0 Support Thread (for ZC v1.3.9)

Also had to decode the order status and order comments:

            if ($orders_history->RecordCount() > 0) {   
               while (!$orders_history->EOF) {   
                    if ($orders_history->fields['comments'] != '' && strpos($orders_history->fields['comments'], 'PayPal status:') === false){ 
                        $count_comments++;
                        $pdf->Cell(120, 14, zen_datetime_short($orders_history->fields['date_added']));  
                        $pdf->MultiCell(456, 14, utf8_decode($orders_status_array[$orders_history->fields['orders_status_id']]));                                       
                        $pdf->Cell(27, 14, '', 0, 0, '', 1);
                        $pdf->MultiCell(549, 14, (utf8_decode(zen_db_output($orders_history->fields['comments']))), 'B');  
                        $pdf->SetLineWidth(.5);
                        $pdf->Line(18,$pdf->GetY(),594,$pdf->GetY());                                    
                    } 
                    $orders_history->MoveNext();
                    if (ORDER_COMMENTS_PACKING_SLIP == 1 && $count_comments >= 1) {
                        break;
                    }
                }       
            } 
20 Nov 2012, 4:31 AM
#922
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

abcisme:

Also had to decode the order status and order comments:

        if ($orders_history->RecordCount() > 0) {   
           while (!$orders_history->EOF) {   
                if ($orders_history->fields['comments'] != '' && strpos($orders_history->fields['comments'], 'PayPal status:') === false){ 
                    $count_comments++;
                    $pdf->Cell(120, 14, zen_datetime_short($orders_history->fields['date_added']));  
                    $pdf->MultiCell(456, 14, utf8_decode($orders_status_array[$orders_history->fields['orders_status_id']]));                                       
                    $pdf->Cell(27, 14, '', 0, 0, '', 1);
                    $pdf->MultiCell(549, 14, (utf8_decode(zen_db_output($orders_history->fields['comments']))), 'B');  
                    $pdf->SetLineWidth(.5);
                    $pdf->Line(18,$pdf->GetY(),594,$pdf->GetY());                                    
                } 
                $orders_history->MoveNext();
                if (ORDER_COMMENTS_PACKING_SLIP == 1 && $count_comments >= 1) {
                    break;
                }
            }       
        } 
20 Nov 2012, 11:35 AM
#923
abcisme avatar

abcisme

Zen Follower

Join Date:
Jun 2006
Posts:
298
Plugin Contributions:
0

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

DivaVocals:

To help others it would be useful if you included the approximate line numbers where you made your changes..

Sorry! Here you go. My store is in French and English, so I needed to specify UTF-8 in order for the French characters to show up correctly. I am sure there must be a better way to specify the default charset for the whole pdf file, but this was the only way I knew how to do it.

These were the changes I made in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

I have made a LOT of changes to this file, so line numbers are approximate.

Around line 242:

                $orderText .= utf8_decode( ' ' . $order->products[$i]['qty'] . 'x ' . $order->products[$i]['name'] . '/' . $order->products[$i]['model'] . $attribText);

Around line 345:

    function draw_packing_slip_customer($order, &$pdf){
        $billTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->billing, 0, '', "\n"));
        if($order->billing['street_address'] == ''){
            $billTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->customer, 0, '', "\n"));    
        } 
        
        $shipTo = utf8_decode(zen_address_format($order->delivery['format_id'], $order->delivery, 0, '', "\n")); 
        if($order->delivery['street_address'] == ''){
            $shipTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->customer, 0, '', "\n"));    
        } 

Around line 426:

       for ($i=0, $n=sizeof($order->products); $i<$n; $i++) {
            $prod_name = utf8_decode($order->products[$i]['name']);                          
            if (isset($order->products[$i]['attributes']) && (sizeof($order->products[$i]['attributes']) > 0)) {
                for ($j=0, $k=sizeof($order->products[$i]['attributes']); $j<$k; $j++) {
                    $prod_name .= utf8_decode(' ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . zen_output_string_protected($order->products[$i]['attributes'][$j]['value']));
                }

Around line 493:

           if ($orders_history->RecordCount() > 0) {   
               while (!$orders_history->EOF) {   
                    if ($orders_history->fields['comments'] != '' && strpos($orders_history->fields['comments'], 'PayPal status:') === false){ 
                        $count_comments++;
                        $pdf->Cell(120, 14, zen_datetime_short($orders_history->fields['date_added']));  
                        $pdf->MultiCell(456, 14, utf8_decode($orders_status_array[$orders_history->fields['orders_status_id']]));                                       
                        $pdf->Cell(27, 14, '', 0, 0, '', 1);
                        $pdf->MultiCell(549, 14, (utf8_decode(zen_db_output($orders_history->fields['comments']))), 'B');  
                        $pdf->SetLineWidth(.5);
                        $pdf->Line(18,$pdf->GetY(),594,$pdf->GetY());                                    
                    } 

Also, to get rid of hardcoded text and use the define text for multi-language you will need to define ENTRY_PHONE, ENTRY_EMAIL and ENTRY_ORDER_STATUS in admin/includes/languages/YOUR_LANGUAGE/super_batch_forms.php

Then, in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

Around 359:

        $pdf->SetFont('Arial','', 9);    
        $billToY = $pdf->GetY();
        $pdf->MultiCell(220, 13, ENTRY_SOLD_TO . "\n\n" . $billTo); 
        $pdf->Ln(8); 
        $pdf->MultiCell(220, 13, ENTRY_PHONE . ' : ' . $customerPhone); 
        $pdf->MultiCell(220, 13, ENTRY_EMAIL . ' : ' . $customerEmail); 
        $pdf->Ln(6);           
        $EndY = $pdf->GetY();
        $pdf->SetXY(306, $billToY);  
    	$pdf->SetFont('Arial','B', 12);
		$pdf->MultiCell(220, 13, ENTRY_SHIP_TO . "\n\n" . $shipTo);   
        $pdf->SetXY(18, $EndY);  
    }

And around line 479:

       if (ORDER_COMMENTS_PACKING_SLIP > 0) {                                                                     
            $pdf->Ln();         
            $pdf->SetFillColor(180,180,180);    
            $pdf->SetFont('Arial','B', 10);       
            $pdf->MultiCell(576, 14, ENTRY_ORDER_STATUS . ' ', 'B');   
            $pdf->SetFont('Arial','', 8);      
            $pdf->SetFillColor(256,256,256);     
20 Nov 2012, 1:40 PM
#924
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

To be clear this was all done for SO v3.0 for Zen Cart 1.3.9 correct??

abcisme:

Sorry! Here you go. My store is in French and English, so I needed to specify UTF-8 in order for the French characters to show up correctly. I am sure there must be a better way to specify the default charset for the whole pdf file, but this was the only way I knew how to do it.

These were the changes I made in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

I have made a LOT of changes to this file, so line numbers are approximate.

Around line 242:

            $orderText .= utf8_decode( ' ' . $order->products[$i]['qty'] . 'x ' . $order->products[$i]['name'] . '/' . $order->products[$i]['model'] . $attribText);
> 
> Around line 345:
> 
> ```
    function draw_packing_slip_customer($order, &$pdf){
        $billTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->billing, 0, '', "\n"));
        if($order->billing['street_address'] == ''){
            $billTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->customer, 0, '', "\n"));    
        } 
        
        $shipTo = utf8_decode(zen_address_format($order->delivery['format_id'], $order->delivery, 0, '', "\n")); 
        if($order->delivery['street_address'] == ''){
            $shipTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->customer, 0, '', "\n"));    
        } 

Around line 426:

   for ($i=0, $n=sizeof($order->products); $i<$n; $i++) {
        $prod_name = utf8_decode($order->products[$i]['name']);                          
        if (isset($order->products[$i]['attributes']) && (sizeof($order->products[$i]['attributes']) > 0)) {
            for ($j=0, $k=sizeof($order->products[$i]['attributes']); $j<$k; $j++) {
                $prod_name .= utf8_decode(' ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . zen_output_string_protected($order->products[$i]['attributes'][$j]['value']));
            }
> 
> Around line 493:
> 
> ```
           if ($orders_history->RecordCount() > 0) {   
               while (!$orders_history->EOF) {   
                    if ($orders_history->fields['comments'] != '' && strpos($orders_history->fields['comments'], 'PayPal status:') === false){ 
                        $count_comments++;
                        $pdf->Cell(120, 14, zen_datetime_short($orders_history->fields['date_added']));  
                        $pdf->MultiCell(456, 14, utf8_decode($orders_status_array[$orders_history->fields['orders_status_id']]));                                       
                        $pdf->Cell(27, 14, '', 0, 0, '', 1);
                        $pdf->MultiCell(549, 14, (utf8_decode(zen_db_output($orders_history->fields['comments']))), 'B');  
                        $pdf->SetLineWidth(.5);
                        $pdf->Line(18,$pdf->GetY(),594,$pdf->GetY());                                    
                    } 

Also, to get rid of hardcoded text and use the define text for multi-language you will need to define ENTRY_PHONE, ENTRY_EMAIL and ENTRY_ORDER_STATUS in admin/includes/languages/YOUR_LANGUAGE/super_batch_forms.php

Then, in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

Around 359:

    $pdf->SetFont('Arial','', 9);    
    $billToY = $pdf->GetY();
    $pdf->MultiCell(220, 13, ENTRY_SOLD_TO . "\n\n" . $billTo); 
    $pdf->Ln(8); 
    $pdf->MultiCell(220, 13, ENTRY_PHONE . ' : ' . $customerPhone); 
    $pdf->MultiCell(220, 13, ENTRY_EMAIL . ' : ' . $customerEmail); 
    $pdf->Ln(6);           
    $EndY = $pdf->GetY();
    $pdf->SetXY(306, $billToY);  
    $pdf->SetFont('Arial','B', 12);
    $pdf->MultiCell(220, 13, ENTRY_SHIP_TO . "\n\n" . $shipTo);   
    $pdf->SetXY(18, $EndY);  
}
> 
> And around line 479:
> 
> ```
       if (ORDER_COMMENTS_PACKING_SLIP > 0) {                                                                     
            $pdf->Ln();         
            $pdf->SetFillColor(180,180,180);    
            $pdf->SetFont('Arial','B', 10);       
            $pdf->MultiCell(576, 14, ENTRY_ORDER_STATUS . ' ', 'B');   
            $pdf->SetFont('Arial','', 8);      
            $pdf->SetFillColor(256,256,256);     
20 Nov 2012, 1:43 PM
#925
abcisme avatar

abcisme

Zen Follower

Join Date:
Jun 2006
Posts:
298
Plugin Contributions:
0

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

DivaVocals:

To be clear this was all done for SO v3.0 for Zen Cart 1.3.9 correct??

Here's what my header says:

/*
//////////////////////////////////////////////////////////////////////////
//  SUPER ORDERS v3.0                                               	//
//                                                                  	//
//  Based on Super Order 2.0                                        	//
//  By Frank Koehl - PM: BlindSide (original author)                	//
//                                                                  	//
//  Super Orders Updated by:											//
//  ~ JT of GTICustom													//
//  ~ C Jones Over the Hill Web Consulting (http://overthehillweb.com)	//
//  ~ Loose Chicken Software Development, [email protected]		//
//                                                      				//
//  Powered by Zen-Cart (www.zen-cart.com)              				//
//  Portions Copyright (c) 2005 The Zen-Cart Team       				//
//                                                     					//
//  Released under the GNU General Public License       				//
//  available at www.zen-cart.com/license/2_0.txt       				//
//  or see "license.txt" in the downloaded zip          				//
//////////////////////////////////////////////////////////////////////////
//  DESCRIPTION:   PDF version of super_packingslip.php,				//
//  Features include:													//
//	~	Pricing information which supports tax included pricing options	//
//		identical to super_invoices.php									//
//  ~	Admin configurable options to use with forms that have a peel	//
//		off	mailing label in place of the default "Packing Slip" text	//
//////////////////////////////////////////////////////////////////////////
// $Id: super_batch_forms.php v 2010-10-24 $
20 Nov 2012, 2:11 PM
#926
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

Awesome!!! Thanks for sharing..:smile:

abcisme:

Here's what my header says:

/*
//////////////////////////////////////////////////////////////////////////
// SUPER ORDERS v3.0 //
// //
// Based on Super Order 2.0 //
// By Frank Koehl - PM: BlindSide (original author) //
// //
// Super Orders Updated by: //
// ~ JT of GTICustom //
// ~ C Jones Over the Hill Web Consulting (http://overthehillweb.com) //
// ~ Loose Chicken Software Development, [email protected] //
// //
// Powered by Zen-Cart (www.zen-cart.com) //
// Portions Copyright (c) 2005 The Zen-Cart Team //
// //
// Released under the GNU General Public License //
// available at www.zen-cart.com/license/2_0.txt //
// or see "license.txt" in the downloaded zip //
//////////////////////////////////////////////////////////////////////////
// DESCRIPTION: PDF version of super_packingslip.php, //
// Features include: //
// ~ Pricing information which supports tax included pricing options //
// identical to super_invoices.php //
// ~ Admin configurable options to use with forms that have a peel //
// off mailing label in place of the default "Packing Slip" text //
//////////////////////////////////////////////////////////////////////////
// $Id: super_batch_forms.php v 2010-10-24 $

20 Nov 2012, 4:56 PM
#927
abcisme avatar

abcisme

Zen Follower

Join Date:
Jun 2006
Posts:
298
Plugin Contributions:
0

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

DivaVocals:

Awesome!!! Thanks for sharing..:smile:

You're welcome. Like I said, I'm sure someone will come up with a better way of doing it, but that's what I could come up with for now. :)

20 Nov 2012, 6:01 PM
#928
abcisme avatar

abcisme

Zen Follower

Join Date:
Jun 2006
Posts:
298
Plugin Contributions:
0

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

Found one more hard coded text in the file. The "packing slip" title.

Define TITLE_PACK_SLIP in admin/includes/languages/YOUR_LANGUAGE/super_batch_forms.php

define('TITLE_PACK_SLIP','Packing Slip'); 

in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

Around line 73:

	if(LCSD_SHOW_SHIPPING_LABEL == 'False'){ 
					$this->SetFont('Arial','B', 28);
					$this->SetXY(350, 85);  
					$this->MultiCell(270, 24, TITLE_PACK_SLIP); 
            }
24 Nov 2012, 7:35 PM
#929
wwwd avatar

wwwd

Inactive

Join Date:
Nov 2012
Posts:
100
Plugin Contributions:
0

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

I may be not seeing something but when I download all I get is a .php page without any accompanying files, i.e., the extensive readme noted.

I am not seeing any current comments, either, although it seems that the module is being currently supported.

24 Nov 2012, 10:36 PM
#930
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

Did you unzip the download package? If yes, and a single .php file is all that's there, then something went wrong with your download. Try again.

WWWD:

I may be not seeing something but when I download all I get is a .php page without any accompanying files, i.e., the extensive readme noted.

I am not seeing any current comments, either, although it seems that the module is being currently supported.

25 Nov 2012, 5:14 PM
#931
wwwd avatar

wwwd

Inactive

Join Date:
Nov 2012
Posts:
100
Plugin Contributions:
0

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

I'm using a new version of windows(7), but all I'm getting is a single php file and it's not coming down with any type of zip extension that I recognize, i.e., just .php when I download with the "Download" link.

Any ideas??

25 Nov 2012, 5:37 PM
#932
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

WWWD:

I'm using a new version of windows(7), but all I'm getting is a single php file and it's not coming down with any type of zip extension that I recognize, i.e., just .php when I download with the "Download" link.

Any ideas??Nope.. this seems to be more of an issue with your local computer.. Pretty sure it's not related to this add-on.. Have you downloaded other add-ons??

and BTW, if you are attempting to download the latest version (v4.0), this is the wrong support thread.. But again I think your issue is a local issue for you..

20 Dec 2012, 1:33 AM
#933
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

selcyis:

I uploaded all the files correctly as directed in the installation and now my whole admin area is blank. But when I take out the lcsd_merged_packing_slips.php it works perfect. Is this file necessary?Yes it's required or it wouldn't be included in the package.

To quote the post you quoted:
you need to post what the error log file that would be generated when you get the blank page says.. (log files would be located in your "cache" folder) Once we know what the error is, then I can guide you on resolving it..

Also you did not say what version of Zen Cart or Super Orders. If it is Super Orders 4.0, this is the WRONG support thread..

25 Dec 2012, 12:16 PM
#934
hipctech avatar

hipctech

Totally Zenned

Join Date:
Oct 2004
Location:
Surrey, BC, Canada
Posts:
1,466
Plugin Contributions:
1

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

Hello there,
I just downloaded Super Orders v. 4.0.5 and after I uploaded the files and then tried to click on a link in my admin side everything went blank. I could not access any page. I had to remove all of them and reupload another way. But the same thing happened. After I spent hours on trying to upload and remove and find where I might have mistaken I decided to go the long route and find the bug with the code. I uploaded file by file until I found the problematic one. There is a bug in this file: admin/includes/classes/fpdf/fpdf.php. I have PHP version 5.2 and for me the error is that at line 1047 and 1329 there is a '.' there that should not be.
Line 1047:

ini_set('magic_quotes_runtime', .$mqr);

should be:

ini_set('magic_quotes_runtime', $mqr);

Line 1329

ini_set('magic_quotes_runtime', .$mqr);

should be:

ini_set('magic_quotes_runtime', $mqr);

Thank you for this great program.
May God bless you

25 Dec 2012, 7:32 PM
#935
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

HiPCTech:

Hello there,
I just downloaded Super Orders v. 4.0.5 and after I uploaded the files and then tried to click on a link in my admin side everything went blank. I could not access any page. I had to remove all of them and reupload another way. But the same thing happened. After I spent hours on trying to upload and remove and find where I might have mistaken I decided to go the long route and find the bug with the code. I uploaded file by file until I found the problematic one. There is a bug in this file: admin/includes/classes/fpdf/fpdf.php. I have PHP version 5.2 and for me the error is that at line 1047 and 1329 there is a '.' there that should not be.
Line 1047:

ini_set('magic_quotes_runtime', .$mqr);

>    should be:
> ```php
ini_set('magic_quotes_runtime', $mqr);

Line 1329

ini_set('magic_quotes_runtime', .$mqr);

>   should be:
> ```php
ini_set('magic_quotes_runtime', $mqr);

Thank you for this great program.
May God bless you

This is the Super Order 3.0 support thread.. You need to post Super Orders 4.0 comments/questions in the Super Orders 4.0 support thread..

26 Dec 2012, 9:30 AM
#936
hipctech avatar

hipctech

Totally Zenned

Join Date:
Oct 2004
Location:
Surrey, BC, Canada
Posts:
1,466
Plugin Contributions:
1

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

Thank you for the notice. I posted it there too. I didn't know there was a thread for version 4... I guess I didn't look enough.

29 Dec 2012, 1:36 AM
#937
jasmel avatar

jasmel

Zen Follower

Join Date:
Feb 2008
Location:
Washington State
Posts:
230
Plugin Contributions:
0

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

Looks like the button to go to the Support Thread is leading us here to the 3.0 support as seen on the Super Orders Mod Page http://www.zen-cart.com/downloads.php?do=file&id=155

29 Dec 2012, 2:32 AM
#938
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

jasmel:

Looks like the button to go to the Support Thread is leading us here to the 3.0 support as seen on the Super Orders Mod Page http://www.zen-cart.com/downloads.php?do=file&id=155
That's clearly an error.. This is NOT the SO 4.0 support thread..

4 Jan 2013, 11:17 AM
#939
thegoofyone avatar

thegoofyone

New Zenner

Join Date:
Jul 2012
Posts:
8
Plugin Contributions:
0

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

Hello all. I added a status to my orders called printed. I'd like to use SO to batch update which works fine, but I don't see the ability to hide the update as I have in the standard order.php. I'm using 1.3.9 and SO 30.2.

Does anyone know how to implement this?

Thank you for any help you may be able to provide.

4 Jan 2013, 3:31 PM
#940
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

TheGoofyOne:

Hello all. I added a status to my orders called printed. I'd like to use SO to batch update which works fine, but I don't see the ability to hide the update as I have in the standard order.php. I'm using 1.3.9 and SO 30.2.

Does anyone know how to implement this?

Thank you for any help you may be able to provide.

Hidden comments not supported in the batch update function.. Would require custom code to add this feature..