Zen Cart Logo
Forums / Customization from the Admin / Link to Jump from Order to Customer Record

Link to Jump from Order to Customer Record

Views: 951

Results 1 to 5 of 5
20 Jun 2013, 17:38
#1
mmwilcox avatar

mmwilcox

New Zenner

Join Date:
Nov 2007
Location:
Huntington, Indiana
Posts:
67
Plugin Contributions:
0

Link to Jump from Order to Customer Record

Many times, it would be useful to be able to jump directly from an order to the customer's master record to see their information or their past orders. This small addition to the orders.php file enables that.

File: store/admin/orders.php. Go to the section near line 545 (depending on past plug-ins) labeled "Begin Customer and Payment Information." Find this section of code:

<tr>
<td class="main"><strong><?php echo TEXT_INFO_IP_ADDRESS; ?></strong></td>
<td class="main"><?php echo $order->info['ip_address']; ?></td>
</tr>

After this code, enter a new line and paste the following:

<!-- Begin Customer Info Link-->
<tr>
  <td class="main"><strong><?php echo ENTRY_CUSTOMER; ?></strong></td>
  <td class="main">
      <?php echo '<a href="' . zen_href_link(FILENAME_CUSTOMERS, 'search=' . $order->customer['email_address'] . '&origin=' . FILENAME_DEFAULT, 'NONSSL') . '" . >' . 'Lookup Customer' . '</a>'; ?>
   </td>
</tr> 
<!-- End Customer Info Link-->

Posted here in case someone else finds this useful.

16 Sep 2013, 16:33
#2
shopville avatar

shopville

Zen Follower

Join Date:
Aug 2012
Posts:
331
Plugin Contributions:
0

Re: Link to Jump from Order to Customer Record

Great tool!

anyway to have it link to customers orders page directly?

16 Sep 2013, 16:36
#3
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Link to Jump from Order to Customer Record

There is already built into the Admin Orders a link to the Customer ... there is an icon next to the Customer Name, just click on it and it takes you to the Customer page in the Admin ...

Is there something different that you change is doing?

16 Sep 2013, 16:41
#4
shopville avatar

shopville

Zen Follower

Join Date:
Aug 2012
Posts:
331
Plugin Contributions:
0

Re: Link to Jump from Order to Customer Record

the built in one is not on the actual orders.php page

16 Sep 2013, 16:52
#5
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Link to Jump from Order to Customer Record

I see, you did not mean in the Order Listing but from the actual viewing of an Order itself ...

Good news, is there is a Link from the Order itself to the customers.php in the upcoming Zen Cart v1.6 ... :smile: