[ Index ]

PHP Cross Reference of phpwcms V1.5.0 _r431 (28.01.12)

title

Body

[close]

/include/inc_module/mod_shop/inc/ -> listing.orders.inc.php (source)

   1  <?php
   2  /*************************************************************************************
   3     Copyright notice
   4     
   5     (c) 2002-2012 Oliver Georgi <oliver@phpwcms.de> // All rights reserved.
   6   
   7     This script is part of PHPWCMS. The PHPWCMS web content management system is
   8     free software; you can redistribute it and/or modify it under the terms of
   9     the GNU General Public License as published by the Free Software Foundation;
  10     either version 2 of the License, or (at your option) any later version.
  11    
  12     The GNU General Public License can be found at http://www.gnu.org/copyleft/gpl.html
  13     A copy is found in the textfile GPL.txt and important notices to the license 
  14     from the author is found in LICENSE.txt distributed with these scripts.
  15    
  16     This script is distributed in the hope that it will be useful, but WITHOUT ANY 
  17     WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  18     PARTICULAR PURPOSE.  See the GNU General Public License for more details.
  19   
  20     This copyright notice MUST APPEAR in all copies of the script!
  21  *************************************************************************************/
  22  
  23  // ----------------------------------------------------------------
  24  // obligate check for phpwcms constants
  25  if (!defined('PHPWCMS_ROOT')) {
  26     die("You Cannot Access This Script Directly, Have a Nice Day.");
  27  }
  28  // ----------------------------------------------------------------
  29  
  30  ?>
  31  <table width="100%" border="0" cellpadding="0" cellspacing="0" summary="" class="shop">
  32          
  33      <tr>
  34          <th>&nbsp;</th>
  35          <th>&nbsp;<?php echo $BLM['th_ordnr'] ?></th>
  36          <th>&nbsp;&nbsp;<?php echo $BLM['th_date'] ?></th>
  37          <th>&nbsp;&nbsp;<?php echo $BLM['th_customer'] ?></th>
  38          <th>&nbsp;&nbsp;<?php echo $BLM['th_net'] ?>&nbsp;</th>
  39          <th>&nbsp;&nbsp;<?php echo $BLM['th_gross'] ?>&nbsp;</th>
  40          <th>&nbsp;<?php echo $BLM['th_payment'] ?></th>
  41          <th>&nbsp;&nbsp;&nbsp;</th>
  42      </tr>
  43      
  44      
  45  <?php
  46  
  47  // loop listing available newsletters
  48  $row_count = 0;
  49  
  50  $BLM['shopprod_payby_INVOICE'] = $BLM['shopprod_payby_onbill'];        
  51  
  52  $sql  = "SELECT *, DATE_FORMAT(order_date,'%e.%m.%y') AS order_fdate FROM ".DB_PREPEND."phpwcms_shop_orders WHERE ";
  53  $sql .= "order_status NOT IN ('ARCHIVED', 'CLOSED') ORDER BY order_date DESC";
  54  
  55  $data = _dbQuery($sql);
  56  
  57  $_controller_link =  shop_url('controller=order');
  58  
  59  foreach($data as $row) {
  60  
  61      echo '<tr'.( ($row_count % 2) ? ' class="adsAltRow"' : '' ).'>'.LF;
  62      
  63      echo '<td width="25" style="padding:2px 3px 2px 4px;">';
  64      
  65      echo '<a href="'.$_controller_link.'&amp;show='.$row["order_id"].'">';
  66      echo '<img src="img/famfamfam/cart_go.gif" alt="'.$BLM['shop_order'].'" border="0" />';
  67      echo '</a></td>'.LF;
  68  
  69      echo '<td class="dir" width="13%">';
  70  
  71      if(SHOP_FELANG_SUPPORT) {
  72          $row['order_data']        = @unserialize($row['order_data']);
  73          $row['shopprod_lang']    = empty($row['order_data']['lang']) ? '' : html_specialchars(strtolower($row['order_data']['lang']));
  74          echo '<img src="img/famfamfam/lang/'.($row['shopprod_lang'] ? $row['shopprod_lang'] : 'all').'.png" alt="'.$row['shopprod_lang'].'" style="position:relative;top:1px;margin:0 3px 0 3px;" />';
  75      }
  76      
  77      echo html_specialchars($row['order_number'])."&nbsp;</td>\n";
  78      echo '<td class="dir" width="13%">&nbsp;'.html_specialchars($row['order_fdate'])."&nbsp;</td>\n";
  79      echo '<td class="dir" width="50%">&nbsp;<a href="mailto:'.$row['order_email'].'?subject='.rawurlencode($BLM['shopprod_order_subject'].' #'.$row['order_number']).'">';
  80      echo html_specialchars($row['order_firstname'].' '.$row['order_name'])."</a>&nbsp;</td>\n";
  81      
  82      echo '<td class="dir listNumber" width="10%">'.html_specialchars( number_format( round($row['order_net'], 2) , 2, $BLM['dec_point'], $BLM['thousands_sep'] ) )."&nbsp;</td>\n";
  83      echo '<td class="dir listNumber" width="10%">'.html_specialchars( number_format( round($row['order_gross'], 2) , 2, $BLM['dec_point'], $BLM['thousands_sep'] ) )."&nbsp;</td>\n";
  84  
  85      echo '<td class="dir" width="10%">'.html_specialchars($BLM[ 'shopprod_payby_'.$row['order_payment'] ])."&nbsp;&nbsp;</td>\n";
  86      
  87      echo '<td width="5%" align="right" nowrap="nowrap" class="button_td">';
  88      
  89          echo '<a href="'.$_controller_link.'&amp;delete='.$row["order_id"];
  90          echo '" title="delete: '.html_specialchars($row['order_number']).'"';
  91          echo ' onclick="return confirm(\''.$BLM['delete_order'].js_singlequote($row['order_number']).'\');">';
  92          echo '<img src="img/button/trash_13x13_1.gif" border="0" alt="" /></a>';
  93      
  94      echo '</td>'.LF;
  95      
  96      echo '</tr>'.LF;
  97  
  98      $row_count++;
  99  }
 100  
 101  if($row_count) {
 102      echo '<tr><td colspan="8" bgcolor="#92A1AF"><img src="img/leer.gif" alt="" width="1" height="1" /></td></tr>';
 103  }
 104  
 105  ?>    
 106  
 107  </table>


Generated: Sun Jan 29 16:31:14 2012 Cross-referenced by PHPXref 0.7.1