You can subscribe to this list here.
| 2011 |
Jan
|
Feb
|
Mar
(4) |
Apr
(57) |
May
(31) |
Jun
(21) |
Jul
(11) |
Aug
(23) |
Sep
(22) |
Oct
(36) |
Nov
(62) |
Dec
(85) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2012 |
Jan
(24) |
Feb
(24) |
Mar
(65) |
Apr
(232) |
May
(118) |
Jun
(22) |
Jul
(54) |
Aug
(57) |
Sep
(14) |
Oct
(27) |
Nov
(16) |
Dec
(19) |
| 2013 |
Jan
(16) |
Feb
(12) |
Mar
(3) |
Apr
(17) |
May
(2) |
Jun
(30) |
Jul
(33) |
Aug
(19) |
Sep
(35) |
Oct
(58) |
Nov
(27) |
Dec
(64) |
| 2014 |
Jan
(102) |
Feb
(80) |
Mar
(15) |
Apr
(4) |
May
(3) |
Jun
(3) |
Jul
(5) |
Aug
(11) |
Sep
(15) |
Oct
|
Nov
(3) |
Dec
(5) |
| 2015 |
Jan
(5) |
Feb
(4) |
Mar
(2) |
Apr
(11) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(9) |
Nov
(10) |
Dec
|
| 2016 |
Jan
(3) |
Feb
(2) |
Mar
(18) |
Apr
(13) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
(4) |
Oct
|
Nov
|
Dec
|
|
From: <os...@us...> - 2012-03-05 20:54:33
|
Revision: 4069
http://oscss.svn.sourceforge.net/oscss/?rev=4069&view=rev
Author: oscim
Date: 2012-03-05 20:54:24 +0000 (Mon, 05 Mar 2012)
Log Message:
-----------
correction diverse
mise a niveau du code
Modified Paths:
--------------
trunk/catalog/admin/includes/content/modules.top.inc
trunk/catalog/admin/includes/gabarit/configuration/modexpedition.listing.gab
trunk/catalog/admin/includes/gabarit/configuration/modorder.listing.gab
trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modexpedition.txt
trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt
trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modstatus.txt
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/index.txt
trunk/catalog/admin/includes/modules/configuration/cfg_37.php
trunk/catalog/admin/includes/modules/configuration/modexpedition.php
trunk/catalog/admin/includes/modules/configuration/modorder.php
trunk/catalog/admin/includes/modules/cronjob/customers_birthday.php
trunk/catalog/admin/includes/template/oscss/data/icon_set.xml
trunk/catalog/admin/includes/widget/Notification.php
trunk/catalog/admin/includes/widget/orderLastservice.php
trunk/catalog/admin/includes/widget/orderLastshipp.php
trunk/catalog/common/classes/notification.php
trunk/catalog/common/classes/osCSS_Cache.php
trunk/catalog/common/classes/osCSS_CacheLib.php
trunk/catalog/includes/modules/order_total/ot_shipping.php
trunk/catalog/install/includes/sql/mysql/tables/osc_services.sql
Added Paths:
-----------
trunk/catalog/admin/images/icons/settings.png
trunk/catalog/includes/languages/fr_FR/modules/order_total/ot_shipping.txt
Removed Paths:
-------------
trunk/catalog/includes/languages/fr_FR/modules/order_total/ot_shipping.php
Added: trunk/catalog/admin/images/icons/settings.png
===================================================================
(Binary files differ)
Property changes on: trunk/catalog/admin/images/icons/settings.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/catalog/admin/includes/content/modules.top.inc
===================================================================
--- trunk/catalog/admin/includes/content/modules.top.inc 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/content/modules.top.inc 2012-03-05 20:54:24 UTC (rev 4069)
@@ -30,9 +30,9 @@
switch ($manager){
case 'process':
$code_inistalletd_array['checkout_process']=array('key'=>'MODULE_CHECKOUT_PROCESS_INSTALLED', 'value'=>MODULE_CHECKOUT_PROCESS_INSTALLED, 'module_directory'=> 'checkout/','key_BO'=>'MODULE_CHECKOUT_PROCESS_INSTALLED_BO', 'value_BO'=>MODULE_CHECKOUT_PROCESS_INSTALLED_BO, 'prefix'=>'Pr');
- $code_inistalletd_array['shipping']=array('key'=>'MODULE_SHIPPING_INSTALLED', 'value'=>MODULE_SHIPPING_INSTALLED,'key_BO'=>'MODULE_SHIPPING_INSTALLED_BO', 'value_BO'=>MODULE_SHIPPING_INSTALLED_BO, 'module_directory'=>'shipping/', 'prefix'=>'');
+// $code_inistalletd_array['shipping']=array('key'=>'MODULE_SHIPPING_INSTALLED', 'value'=>MODULE_SHIPPING_INSTALLED,'key_BO'=>'MODULE_SHIPPING_INSTALLED_BO', 'value_BO'=>MODULE_SHIPPING_INSTALLED_BO, 'module_directory'=>'shipping/', 'prefix'=>'');
$code_inistalletd_array['payment']=array('key'=>'MODULE_PAYMENT_INSTALLED', 'value'=>MODULE_PAYMENT_INSTALLED, 'key_BO'=>'MODULE_PAYMENT_INSTALLED_BO', 'value_BO'=>MODULE_PAYMENT_INSTALLED_BO,'module_directory'=> 'payment/', 'prefix'=>'');
- $code_inistalletd_array['order_total']=array('key'=>'MODULE_ORDER_TOTAL_INSTALLED', 'value'=>MODULE_ORDER_TOTAL_INSTALLED, 'key_BO'=>'MODULE_ORDER_TOTAL_INSTALLED_BO', 'value_BO'=>MODULE_ORDER_TOTAL_INSTALLED_BO, 'module_directory'=> 'order_total/', 'prefix'=>'');
+// $code_inistalletd_array['order_total']=array('key'=>'MODULE_ORDER_TOTAL_INSTALLED', 'value'=>MODULE_ORDER_TOTAL_INSTALLED, 'key_BO'=>'MODULE_ORDER_TOTAL_INSTALLED_BO', 'value_BO'=>MODULE_ORDER_TOTAL_INSTALLED_BO, 'module_directory'=> 'order_total/', 'prefix'=>'');
$code_inistalletd_array['orders']=array('key_BO'=>'MODULE_ORDERS_INSTALLED_BO', 'value_BO'=>MODULE_ORDERS_INSTALLED_BO, 'module_directory'=> 'orders/', 'prefix'=>'');
break;
case 'general':
@@ -44,6 +44,8 @@
$code_inistalletd_array['account']=array('key'=>'MODULE_ACCOUNT_INSTALLED', 'value'=>MODULE_ACCOUNT_INSTALLED,'key_BO'=>'MODULE_ACCOUNT_INSTALLED_BO', 'value_BO'=>MODULE_ACCOUNT_INSTALLED_BO,'module_directory'=> 'account/','module_language'=>DIR_FS_ADMIN.DIR_WS_LANGUAGES , 'prefix'=>'');
$code_inistalletd_array['listing']=array('key'=>'MODULE_LISTING_INSTALLED', 'value'=>MODULE_LISTING_INSTALLED,'key_BO'=>'MODULE_LISTING_INSTALLED_BO', 'value_BO'=>@MODULE_LISTING_INSTALLED_BO,'module_directory'=> 'listing/','module_language'=>DIR_FS_ADMIN.DIR_WS_LANGUAGES , 'prefix'=>'');
$code_inistalletd_array['home']=array('key'=>'MODULE_HOME_INSTALLED', 'value'=>MODULE_HOME_INSTALLED, 'key_BO'=>'MODULE_HOME_INSTALLED_BO', 'value_BO'=>MODULE_HOME_INSTALLED_BO ,'module_directory'=>'home/','module_language'=>DIR_FS_ADMIN.DIR_WS_LANGUAGES , 'prefix'=>'');
+
+ $code_inistalletd_array['adminuser']=array('key'=>'MODULE_ADMINUSER_INSTALLED', 'value'=>MODULE_ADMINUSER_INSTALLED, 'key_BO'=>'MODULE_ADMINUSER_INSTALLED_BO', 'value_BO'=>MODULE_ADMINUSER_INSTALLED_BO ,'module_directory'=>'adminuser/','module_language'=>DIR_FS_ADMIN.DIR_WS_LANGUAGES , 'prefix'=>'');
}
Modified: trunk/catalog/admin/includes/gabarit/configuration/modexpedition.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/modexpedition.listing.gab 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/gabarit/configuration/modexpedition.listing.gab 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/09/11, 20:05
+ @date 04/03/2012, 20:05
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief mise en forme de la gestion du stock
@@ -32,7 +32,7 @@
<div id="tabs-1" class="tabPage">
- <?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&action=save_mutli') ?>
+ <?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, FILENAME_CFG_127.'action=save_mutli') ?>
<div id="modexpedition-config" class="block_form">
@@ -115,7 +115,7 @@
<div id="tabs-2" class="tabPage">
<?php /** Liste des zone de livraison */ ?>
- <?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&action=zones') ?>
+ <?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, FILENAME_CFG_127.'action=zones') ?>
<div id="modexpedition-zone" class="block_form">
<h4 class="main-title"><?php echo __('modexpedition heading zone shipping'); ?></h4>
@@ -179,19 +179,11 @@
<td><?php echo $row->content->title; ?></td>
<td><?php echo $row->content->description; ?></td>
<td class="tcenter"><?php echo $row->content->sort_order; ?></td>
- <td class="tcenter"><?php
- if($row->status) {
- echo tep_image(DIR_WS_ICONS . 'icon_status_green.gif', IMAGE_ICON_STATUS_GREEN) . ' <a href="' . tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&action=modules&mod='.$row->content->code.'&flag=0' ) . '">' . tep_image(DIR_WS_ICONS . 'icon_status_red_light.gif', IMAGE_ICON_STATUS_RED_LIGHT) . '</a>';
- } else {
- echo '<a href="' . tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&action=modules&mod='.$row->content->code.'&flag=1') . '">' . tep_image(DIR_WS_ICONS . 'icon_status_green_light.gif', IMAGE_ICON_STATUS_GREEN_LIGHT) . '</a> ' . tep_image(DIR_WS_ICONS . 'icon_status_red.gif', IMAGE_ICON_STATUS_RED);
- }
- ?></td>
+ <td class="tcenter">
+ <?php echo modexpedition::GetStatusMod($row); ?>
+ </td>
<td class="tright">
-<?php
- if($row->status) {
- echo ' <a href="' . tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&action=modules-edit&mod='.$row->content->code.'' ) . '"> Config </a>' ;
-}
- ?>
+ <?php echo modexpedition::get_item_action($row); ?>
</td>
</tr>
<?php endforeach; ?>
@@ -199,25 +191,23 @@
</table>
+ <?php /** Form for edit config module */ ?>
+ <?php if(isset(modexpedition::$moduleEdit)): ?>
+ <?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, FILENAME_CFG_127.'mod='.$_GET['mod'].'&action=modules-save') ?>
+ <fieldset class="block_field">
+ <legend><?php echo __('modexpedition heading Configuration du modules') ?></legend>
+ <?php echo modexpedition::$moduleEdit; ?>
+ <div class="button_nav">
+ <?php print tep_image_submit('button_copy.gif', IMAGE_UPDATE) .tep_js_back(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] )) ; ?>
+ </div>
+ </fieldset>
+ </form>
- <?php if(isset(modexpedition::$moduleEdit)): ?>
+ <?php endif; ?>
- <?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&mod='.$_GET['mod'].'&action=modules-save') ?>
- <fieldset class="block_field">
- <legend><?php echo __('modexpedition heading Configuration du modules') ?></legend>
- <?php echo modexpedition::$moduleEdit; ?>
- <div class="button_nav">
- <?php print tep_image_submit('button_copy.gif', IMAGE_UPDATE) .tep_js_back(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] )) ; ?>
- </div>
- </fieldset>
- </form>
-
- <?php endif; ?>
-
-
</div>
Modified: trunk/catalog/admin/includes/gabarit/configuration/modorder.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/modorder.listing.gab 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/gabarit/configuration/modorder.listing.gab 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,13 +1,13 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/09/11, 20:05
+ @date 04/03/2012, 20:05
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
- @brief mise en forme de la gestion du stock
+ @brief
*/
?>
@@ -19,103 +19,181 @@
<h3 class="main-title"><?php echo __('modorder heading') ?></h3>
-<?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&action=save_mutli') ?>
+<!-- <div class="block_form"> -->
-<div class="block_form">
+ <div id="tabs">
+ <ul>
+ <li><a href="#tabs-1"><?php echo __('modorder tab configuration'); ?></a></li>
+ <li><a href="#tabs-2"><?php echo __('modorder tab order total'); ?></a></li>
+<!-- <li><a href="#tabs-3"><?php //echo __('modorder tab orders'); ?></a></li> -->
+ </ul>
- <fieldset class="block_field">
+ <div id="tabs-1" class="tabPage">
- <legend><?php echo __('modorder legend status orders'). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></legend>
+<?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&action=save_mutli') ?>
- <?php /** */ $row = modorder::$list['DEFAULT_ORDERS_STATUS_ID']; ?>
- <h4 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h4>
- <div class="block_input">
- <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
+ <fieldset class="block_field">
- <?php /** */ $row = modorder::$list['DEFAULT_ORDERS_STATUS_PAYED']; ?>
- <h4 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h4>
- <div class="block_input">
- <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
+ <legend><?php echo __('modorder legend status orders'). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></legend>
+ <?php /** */ $row = modorder::$list['DEFAULT_ORDERS_STATUS_ID']; ?>
+ <h4 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h4>
+ <div class="block_input">
+ <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
- <?php /** */ $row = modorder::$list['DEFAULT_ORDERS_STATUS_COMPLETED']; ?>
- <h4 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h4>
- <div class="block_input">
- <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
+ <?php /** */ $row = modorder::$list['DEFAULT_ORDERS_STATUS_PAYED']; ?>
+ <h4 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h4>
+ <div class="block_input">
+ <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
- <?php /** */ $row = modorder::$list['DEFAULT_ORDERS_STATUS_ANNULATE']; ?>
- <h4 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h4>
- <div class="block_input">
- <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
- </fieldset>
+ <?php /** */ $row = modorder::$list['DEFAULT_ORDERS_STATUS_COMPLETED']; ?>
+ <h4 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h4>
+ <div class="block_input">
+ <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
+ <?php /** */ $row = modorder::$list['DEFAULT_ORDERS_STATUS_ANNULATE']; ?>
+ <h4 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h4>
+ <div class="block_input">
+ <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
+ </fieldset>
- <fieldset class="block_field">
- <?php /** */ $row = modorder::$list['USE_LOCAL_GENERAT_ORDER_REF']; ?>
- <legend title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></legend>
- <div class="block_input">
- <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
- </p>
+ <fieldset class="block_field">
+ <?php /** */ $row = modorder::$list['USE_LOCAL_GENERAT_ORDER_REF']; ?>
+ <legend title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></legend>
- <?php /** option de la gestion de stock, disponible que ci value precendente a true */ ?>
- <?php if(_test_bool(modorder::$list['USE_LOCAL_GENERAT_ORDER_REF']->value)): ?>
- <?php /** */ $row = modorder::$list['ORDERS_NUMBER_PREFIX']; ?>
- <div class="block_input">
- <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
+ <div class="block_input">
+ <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
+ </p>
- <?php endif; ?>
- </fieldset>
- <fieldset class="block_field">
- <legend class="block_field-title"><?php echo __('modorder legend other') ?></legend>
+ <?php /** option de la gestion de stock, disponible que ci value precendente a true */ ?>
+ <?php if(_test_bool(modorder::$list['USE_LOCAL_GENERAT_ORDER_REF']->value)): ?>
+ <?php /** */ $row = modorder::$list['ORDERS_NUMBER_PREFIX']; ?>
+ <div class="block_input">
+ <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
- <ul class="block_input">
- <?php foreach(modorder::$list as $row)
- if(!in_array($row->key,array('DEFAULT_ORDERS_STATUS_PAYED','DEFAULT_ORDERS_STATUS_ID', 'DEFAULT_ORDERS_STATUS_ANNULATE', 'DEFAULT_ORDERS_STATUS_COMPLETED', 'ORDERS_NUMBER_PREFIX', 'USE_LOCAL_GENERAT_ORDER_REF')) ) { ?>
- <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
+ <?php endif; ?>
+ </fieldset>
- <div class="block_input tirroir">
- <label><?php echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
- </li>
- <?php } ?>
- </ul>
- </fieldset>
+ <fieldset class="block_field">
+ <legend class="block_field-title"><?php echo __('modorder legend other') ?></legend>
- <div class="button_nav">
+ <ul class="block_input">
+ <?php foreach(modorder::$list as $row)
+ if(!in_array($row->key,array('DEFAULT_ORDERS_STATUS_PAYED','DEFAULT_ORDERS_STATUS_ID', 'DEFAULT_ORDERS_STATUS_ANNULATE', 'DEFAULT_ORDERS_STATUS_COMPLETED', 'ORDERS_NUMBER_PREFIX', 'USE_LOCAL_GENERAT_ORDER_REF')) ) { ?>
+ <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
+
+ <div class="block_input tirroir">
+ <label><?php echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
+ </li>
+ <?php } ?>
+ </ul>
+ </fieldset>
+ <fieldset class="block_field button_nav">
<?php print tep_image_submit('button_copy.gif', IMAGE_UPDATE) .tep_js_back(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] )) ; ?>
- </div>
+ </fieldset>
+</form>
+ </div>
-</div>
-</form>
\ No newline at end of file
+ <div id="tabs-2" class="tabPage">
+
+ <?php /** Liste des moduel de livraison */ ?>
+
+ <div id="modorder-module" class="block_form">
+ <h4 class="main-title"><?php echo __('modorder heading modules shipping'); ?></h4>
+
+
+ <table class="dataTable">
+ <thead>
+ <tr>
+ <th><?php echo __('table heading module code'); ?></th>
+ <th><?php echo __('table heading module title'); ?></th>
+ <th><?php echo __('table heading module desc'); ?></th>
+ <th><?php echo __('table heading module sort'); ?></th>
+ <th><?php echo __('table heading module status'); ?></th>
+ <th><?php echo __('table heading action'); ?></th>
+ </tr>
+ </thead>
+ <tbody>
+ <?php foreach(modorder::$module as $row): /*print_r($row)*/ ?>
+ <tr>
+ <td><?php echo $row->content->code; ?></td>
+ <td><?php echo $row->content->title; ?></td>
+ <td><?php echo $row->content->description; ?></td>
+ <td class="tcenter"><?php echo $row->content->sort_order; ?></td>
+ <td class="tcenter">
+ <?php echo modorder::GetStatusMod_ot($row); ?>
+ </td>
+ <td class="tright">
+<?php
+ if($row->status) {
+ echo ' <a href="' . tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&action=modules-edit&mod='.$row->content->code.'' ) . '"> Config </a>' ;
+}
+ ?>
+ </td>
+ </tr>
+ <?php endforeach; ?>
+ </tbody>
+ </table>
+
+
+
+
+
+ <?php if(isset(modorder::$moduleEdit)): ?>
+
+ <?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] . '&mod='.$_GET['mod'].'&action=modules-save') ?>
+ <fieldset class="block_field">
+ <legend><?php echo __('modorder heading Configuration du modules') ?></legend>
+ <?php echo modorder::$moduleEdit; ?>
+
+ <div class="button_nav">
+ <?php print tep_image_submit('button_copy.gif', IMAGE_UPDATE) .tep_js_back(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $_GET['gparentID'].'&gID=' . $_GET['gID'] )) ; ?>
+ </div>
+ </fieldset>
+ </form>
+
+ <?php endif; ?>
+
+
+ </div>
+<!-- <div id="tabs-3" class="tabPage">
+ </div>-->
+<br class="clear" />
+
+ </div>
+
+
+<!-- </div> -->
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modexpedition.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modexpedition.txt 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modexpedition.txt 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 27/09/11, 18:29
+ @date 04/03/2012, 20:05
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -37,6 +37,8 @@
$lang['table heading module sort']="Ordre" ;
$lang['table heading module status']="Etat" ;
+$lang['image config']="Configuration" ;
+
/**
@remarks stock Valeur stocké en db pour conversion
@note
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt 2012-03-05 20:54:24 UTC (rev 4069)
@@ -12,12 +12,27 @@
$lang['modorder heading']="Configuration gestion de commande" ;
+
+$lang['modorder tab configuration']="Configuration" ;
+$lang['modorder tab order total']="Calcul Totaux" ;
+$lang['modorder tab orders']="Modules" ;
+
+
$lang['modorder legend status orders']="Gestion des statut" ;
$lang['modorder legend other']="Autres" ;
+$lang['modorder heading modules orders']="les modules qui construisent les differentes ligne de sous total d'une commande / facture. " ;
+$lang['table heading module code']="Nom" ;
+$lang['table heading module title']="Description" ;
+$lang['table heading module desc']="crée/modifié" ;
+$lang['table heading module sort']="Ordre" ;
+$lang['table heading module status']="Etat" ;
+$lang['table heading action']="Action" ;
+$lang['image config']="Configuration" ;
+
/**
@remarks stock Valeur stocké en db pour conversion
@note
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modstatus.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modstatus.txt 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modstatus.txt 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 27/09/11, 18:29
+ @date 04/03/2012, 18:29
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -20,7 +20,8 @@
$lang['text info orders status name']="Statut des commandes :" ;
$lang['text set default created']="Statut d'une commande créee" ;
$lang['text set default completed']="Statut d'une commande livrée" ;
-$lang['text default completed']="complété" ;
+$lang['text default completed']="Complété" ;
+$lang['text default']="Defaut" ;
$lang['text set default annulate']="Statut d'une commande annulée" ;
$lang['text default annulate']="Annulé" ;
$lang['text info insert intro']="Merci de compléter cette nouvelle commande avec ses données liées" ;
@@ -33,11 +34,11 @@
$lang['error status used in history']="Erreur : Ce statut de commande est déjà utilisé dans l'historique de commande." ;
$lang['is childs status. not use default value for process']="Vous editez un statut enfant. Ces statut ne peuvent être defini pas default (pour les actions annulé, cloture, etc..). Ces statut vous fournissent un moyen de preciser le type de module qui peut avoir affecté le statut, sans pour autant modifier l'état en cours de la commande" ;
-$lang['ajoute un status']="ajoute un status" ;
-$lang['utiliser comme status par default']="utiliser comme status par défaut" ;
-$lang['utiliser comme status termine']="utiliser comme status terminé" ;
-$lang['utiliser comme status annule']="utiliser comme status annulé" ;
-$lang['list status / type']="liste status/type" ;
+$lang['ajoute un status']="Ajoute un status" ;
+$lang['utiliser comme status par default']="Utiliser comme status par défaut" ;
+$lang['utiliser comme status termine']="Utiliser comme status terminé" ;
+$lang['utiliser comme status annule']="Utiliser comme status annulé" ;
+$lang['list status / type']="Liste status/type" ;
$lang['couleurs']="Couleurs" ;
$lang['action']="Action" ;
$lang['add status']="Ajouter type" ;
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/pages/index.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/pages/index.txt 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/pages/index.txt 2012-03-05 20:54:24 UTC (rev 4069)
@@ -20,6 +20,8 @@
$lang['heading title mail']="Tableau de bord campagne emailling" ;
$lang['heading title orders']="Tableau de bord des commandes" ;
$lang['heading title admin']="Tableau de bord des utilisateurs et groupes privés" ;
+$lang['heading title services']="Tableau de bord des services" ;
+$lang['heading title shipping']="Tableau de bord des expeditions" ;
$lang['heading title config_100']="Configuration de l'apparence" ;
$lang['heading title config_110']="Configuration de base" ;
Modified: trunk/catalog/admin/includes/modules/configuration/cfg_37.php
===================================================================
--- trunk/catalog/admin/includes/modules/configuration/cfg_37.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/modules/configuration/cfg_37.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 20/09/10, 21:29
+ @version 2.1.1
+ @date 04/03/2012, 21:29
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class cfg_37
@@ -15,11 +15,11 @@
Class cfg_37 /*implements ext_configuration*/{
/**
- @p array list
+ @var $liste array list
*/
public static $liste;
/**
- @p numeric size total cache
+ @var $size numeric size total cache
*/
public static $size=0;
@@ -44,13 +44,14 @@
$cached_files= $this->load_db_values();
switch ($action) {
case 'reset':
- if (isset($_GET['cache']) && !empty($_GET['cache'])) {
- if ($_GET['cache']=='All'){
- foreach($cached_files as $cache => $stats) {
- osCSS_Cache::clear($cache, (($stats['pos']=='BO')? true:false) );
- }
- }
- else osCSS_Cache::clear($_GET['cache'], (($_GET['pos']=='BO')? true:false) );
+ if (isset($_GET['cache']) && !empty($_GET['cache'])) {
+ if ($_GET['cache']=='All'){
+ foreach($cached_files as $cache => $stats) {
+ osCSS_Cache::clear($cache, (($stats['pos']=='BO')? true:false) );
+ }
+ }
+ else
+ osCSS_Cache::clear($_GET['cache'], (($_GET['pos']=='BO')? true:false) );
}
tep_redirect(tep_href_link(FILENAME_CONFIGURATION, tep_get_all_get_params(array('action','cache','pos'), false )));
@@ -74,13 +75,13 @@
else $code = substr($file, 0, strpos($file, '.'));
if (isset($cached_files[$code])) {
- $cached_files[$code]['total']++;
- if ($last_modified > $cached_files[$code]['last_modified'])$cached_files[$code]['last_modified'] = $last_modified;
+ $cached_files[$code]['total']++;
+ if ($last_modified > $cached_files[$code]['last_modified'])$cached_files[$code]['last_modified'] = $last_modified;
} else {
- $cached_files[$code] = array('total' => 1, 'last_modified' => $last_modified,'mod'=>'FO');
+ $cached_files[$code] = array('total' => 1, 'last_modified' => $last_modified,'mod'=>'FO');
}
}
- $dir=DIR_FS_ADMIN.DIR_WS_INCLUDES.'tmp/cache/';
+ $dir=DIR_FS_ROOT_DOCS .'admin/'. DIR_CACHE;
foreach (scan($dir) as $file) {
$last_modified = filemtime($dir . '/' . $file);
self::$size +=filesize($dir . '/' . $file);
@@ -88,10 +89,10 @@
else $code = substr($file, 0, strpos($file, '.'));
if (isset($cached_files[$code])) {
- $cached_files[$code]['total']++;
- if ($last_modified > $cached_files[$code]['last_modified'])$cached_files[$code]['last_modified'] = $last_modified;
+ $cached_files[$code]['total']++;
+ if ($last_modified > $cached_files[$code]['last_modified'])$cached_files[$code]['last_modified'] = $last_modified;
} else {
- $cached_files[$code] = array('total' => 1, 'last_modified' => $last_modified, 'pos'=>'BO');
+ $cached_files[$code] = array('total' => 1, 'last_modified' => $last_modified, 'pos'=>'BO');
}
}
@@ -100,20 +101,22 @@
}
/**
- Appel\xE9 dans le header de page
+ @brief Appel\xE9 dans le header de page
*/
public static function draw_header(){
global $messageStack;
// check if the cache directory exists
if (is_dir(DIR_FS_WORK)) {
- if (!is_writeable(DIR_FS_WORK)) $messageStack->add(__('error cache directory not writeable'), 'error');
- } else {
- $messageStack->add(__('error cache directory does not exist'), 'error');
+ if (!is_writeable(DIR_FS_WORK)) $messageStack->add(__('error cache directory not writeable'), 'error');
+ }
+ else {
+ $messageStack->add(__('error cache directory does not exist'), 'error');
}
}
/**
- Contenu central
+ @brief Contenu central / traitement affichage
+ @return string full html by gabarit
*/
public function draw(){
global $action,$gparentID,$current_theme;
Modified: trunk/catalog/admin/includes/modules/configuration/modexpedition.php
===================================================================
--- trunk/catalog/admin/includes/modules/configuration/modexpedition.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/modules/configuration/modexpedition.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -12,6 +12,8 @@
*/
+define('FILENAME_CFG_127',"gparentID=127&gID=7&");
+
Class modexpedition
implements ext_configuration
{
@@ -163,8 +165,8 @@
sqlconfiguration::update(array('id'=>$current->id, 'value'=>implode(';',$result)) );
-
- tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '#modexpedition-module' ));
+ if(isset($_GET['forceajax']))
+ tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '#modexpedition-module' ));
}
break;
@@ -250,17 +252,17 @@
?>
<style type="text/css">
#central form label {
- display: inline-block;
- font-weight: normal;
- margin: 5px 10px;
- text-align: left;
- white-space: pre-wrap;
- width: 90%;
+ display: inline-block;
+ font-weight: normal;
+ margin: 5px 10px;
+ text-align: left;
+ white-space: pre-wrap;
+ width: 90%;
}
-#central form label {
- width:100%;
- font-weight:bold;
-}
+ #central form label {
+ width:100%;
+ font-weight:bold;
+ }
</style>
<?php
}
@@ -272,27 +274,72 @@
public function draw(){
global $action,$gparentID;
if($action=='cfg') return;
- self::$list = $this->load_db_values('');
- self::$zone =sqlgeozone::fetch(array('type'=>2), true);
- foreach(scan(DIR_FS_CATALOG_MODULES.'shipping/') as $row){
- if( substr($row,-3) =='php'){
+ switch($action){
+ case 'modules';
+ return self::GetStatusMod( new objectInfo( array('status'=>(int)$_GET['flag'], 'content'=> new objectInfo(array('mod'=>(int)$_GET['mod'])) )) );
+ break;
+
+ default:
+ self::$list = $this->load_db_values('');
- $class = substr($row,0, -4);
+ self::$zone =sqlgeozone::fetch(array('type'=>2), true);
- self::$module[]=modulesUtility::LoadModule('shipping', $row);
- }
- }
+ foreach(scan(DIR_FS_CATALOG_MODULES.'shipping/') as $row){
+ if( substr($row,-3) =='php'){
+ $class = substr($row,0, -4);
+ self::$module[]=modulesUtility::LoadModule('shipping', $row);
+ }
+ }
+ return tep_get_include_contents('configuration/'.__CLASS__.'.listing');
+ }
+ }
- return tep_get_include_contents('configuration/'.__CLASS__.'.listing');
+
+
+ /**
+ @fn get_item_action($orders)
+ @brief fonction qui construit l'affichage de la colonne action
+ La mise en forme est contenu dans les ressource xml du template en cours
+ @param $orders array
+ @return string
+ */
+ public static function get_item_action($row){
+ global $SecuKey;
+ return sprintf(
+ CsrtAction::getFormat('row_action'),
+ '',
+ (($row->status)
+ ? sprintf(CsrtAction::getLink('row_action_right', __('image config'), 'config'), '', tep_href_link(FILENAME_CONFIGURATION, FILENAME_CFG_127.'action=modules-edit&mod='.$row->content->code ),'' )
+ : ''
+ )
+ );
}
+
+ /**
+ @brief return format html for row status
+ @param $product array restuts row
+ @return string html
+ */
+ public static function GetStatusMod($row){
+ $exclude=array('action','mod','forceajax','type','class','function','funct', 'mod');
+ $query_s=FILENAME_CFG_127.'action=modules&mod=' . $row->content->code.'&flag=';
+
+ return '<a class="ajaxinline" href="' . tep_href_link(FILENAME_CONFIGURATION, tep_get_all_get_params($exclude).$query_s.(($row->status == '1')? '0' : '1') ) . '">'.
+ sprintf(
+ CsrtAction::getFormat('row_flag'),
+ (int)$row->status,
+ ( ($row->status == '1')? IMAGE_ICON_STATUS_GREEN : IMAGE_ICON_STATUS_RED)
+ ).
+ '</a>';
+ }
}
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/modules/configuration/modorder.php
===================================================================
--- trunk/catalog/admin/includes/modules/configuration/modorder.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/modules/configuration/modorder.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,29 +1,42 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/09/11, 19:49
+ @date 04/03/2012, 19:49
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class modorder
- @brief Mise en forme et structuration des options de stock
+ @brief Configuration et gestion des parametres associé au commandes / totaux
*/
+define('FILENAME_CFG_129',"gparentID=127&gID=129&");
Class modorder
implements ext_configuration
{
+
/**
@var array list template
*/
public static $list;
-
+ /**
+ @var
+ */
public static $cfg;
+ /**
+ @var
+ */
+ public static $module;
/**
+ @var
*/
+ public static $moduleEdit;
+
+ /**
+ */
function __construct(){
global $oscss;
$this->code=__CLASS__;
@@ -37,10 +50,9 @@
/**
- Action Prise en charge par le modules
- @param
- @e global $action
- @e global $messageStack
+ @fn draw_action()
+ @brief Action Prise en charge par le modules
+ @return none
*/
public function draw_action(){
global $action,$messageStack;
@@ -51,32 +63,122 @@
switch($action){
/**
- @brief save page groupe
+ @brief save page groupe
*/
case 'save_mutli':
- if(tep_not_null($gID) ){
+ if(tep_not_null($gID) ){
- $list=sqlconfiguration::fetch(array('group_id'=> (int)$gID), true);
+ $list=sqlconfiguration::fetch(array('group_id'=> (int)$gID), true);
- foreach($list as $row) {
+ foreach($list as $row) {
- if(isset($_POST['configuration'][$row->key])) {
- $configuration_value = tep_db_prepare_input($_POST['configuration'][$row->key]);
+ if(isset($_POST['configuration'][$row->key])) {
+ $configuration_value = tep_db_prepare_input($_POST['configuration'][$row->key]);
- if( ($res=sqlconfiguration::update(array('key'=>$row->key , 'value'=>tep_db_input($configuration_value) ))) == false)$erreur[]=false;
- else $erreur[]=true;
+ if( ($res=sqlconfiguration::update(array('key'=>$row->key , 'value'=>tep_db_input($configuration_value) ))) == false)$erreur[]=false;
+ else $erreur[]=true;
- }
+ }
+
+ }
- }
+ if(!in_array(false,$erreur)) $messageStack->add_session(SAVE_CONFIG_OK, 'success');
+ else $messageStack->add_session(SAVE_CONFIG_NOT_OK, 'error');
- if(!in_array(false,$erreur)) $messageStack->add_session(SAVE_CONFIG_OK, 'success');
- else $messageStack->add_session(SAVE_CONFIG_NOT_OK, 'error');
+ }
- }
+ tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '&cID=' . $cID));
+ break;
- tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '&cID=' . $cID));
+ /**
+ @brief Manage modules
+ */
+ case 'modules':
+
+
+ if(isset($_GET['flag'])){
+
+ $mod=tep_db_prepare_input($_GET['mod']);
+ $flag=(int)tep_db_prepare_input($_GET['flag']);
+
+ // call type module
+ $typeOri=modulesUtility::GetModttype('order_total');
+ // get current value
+ $current = sqlconfiguration::fetch(array('key'=>$typeOri->key), true);
+
+
+
+ // call
+ $type=modulesUtility::LoadModule('order_total',$mod.'.php');
+ // force install
+ if( $flag ==1 && !$type->content->check()){
+ $type->content->remove();
+ $type->content->install();
+ }
+ // force remove
+ elseif( $flag == 0 && $type->content->check())
+ $type->content->remove();
+
+ // up module
+ $r=explode(';',$typeOri->value);
+ $result[]=( ($flag ==1 ) ? $mod.'.php;' : '' );
+
+ foreach($r as $v)
+ if(trim($v) !='')
+ if( (
+ $flag ==1
+ || ($flag == 0 && $v != trim($mod).'.php' )
+ )
+ && !in_array($v,$result)
+ ){
+ $result[]=$v;
+ }
+
+ sqlconfiguration::update(array('id'=>$current->id, 'value'=>implode(';',$result)) );
+
+ if(!isset($_GET['forceajax']))
+ tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '#modorder-module' ));
+ }
+
break;
+ case 'modules-edit':
+
+ $mod=tep_db_prepare_input($_GET['mod']);
+ // call
+ $Mod=modulesUtility::LoadModule('order_total',$mod.'.php');
+ $ModCurr = $Mod->content;
+ $i=0;
+ foreach($ModCurr->keys() as $value){
+ $i++;
+ $current = sqlconfiguration::fetch(array('key'=>$value));
+
+ $keys_extra[$value]['title'] = $current['configuration_title'];
+ $keys_extra[$value]['value'] = $current['configuration_value'];
+ $keys_extra[$value]['description'] = $current['configuration_description'];
+ $keys_extra[$value]['use_function'] = $current['use_function'];
+ $keys_extra[$value]['set_function'] = $current['set_function'];
+ }
+
+ self::$moduleEdit = configUtility::FormatEditAuto(array('array'=>$keys_extra));
+ break;
+ /**
+ @brief save Config base page
+ */
+ case 'modules-save':
+ foreach($_POST['configuration'] as $key=>$value) {
+
+ $configuration_value = tep_db_prepare_input($value);
+
+ if( ($res=sqlconfiguration::update(array('key'=>$key , 'value'=>tep_db_input($value) ))) == false)$erreur[]=false;
+ else $erreur[]=true;
+
+ }
+
+ if(!in_array(false,$erreur)) $messageStack->add_session(SAVE_CONFIG_OK, 'success');
+ else $messageStack->add_session(SAVE_CONFIG_NOT_OK, 'error');
+
+ tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '&action=modules-edit&mod='. $_GET['mod'] ));
+ break;
}
}
@@ -136,6 +238,9 @@
<?php
}
+
+
+
/**
Contenu central
@param
@@ -146,9 +251,67 @@
global $action,$gparentID;
if($action=='cfg') return;
- self::$list = $this->load_db_values('');
- return tep_get_include_contents('configuration/'.__CLASS__.'.listing');
+ switch($action){
+ case 'modules';
+ return self::GetStatusMod_ot( new objectInfo( array('status'=>(int)$_GET['flag'], 'content'=> new objectInfo(array('mod'=>(int)$_GET['mod'])) )) );
+ break;
+
+ default:
+ self::$list = $this->load_db_values('');
+
+ foreach(scan(DIR_FS_CATALOG_MODULES.'order_total/') as $row){
+ if( substr($row,-3) =='php'){
+
+ $class = substr($row,0, -4);
+
+ self::$module[]=modulesUtility::LoadModule('order_total', $row);
+
+ }
+ }
+
+ return tep_get_include_contents('configuration/'.__CLASS__.'.listing');
+ }
+
}
+
+
+
+ /**
+ @fn get_item_action($orders)
+ @brief fonction qui construit l'affichage de la colonne action
+ La mise en forme est contenu dans les ressource xml du template en cours
+ @param $orders array
+ @return string
+ */
+ public static function get_item_action($row){
+ global $SecuKey;
+ return sprintf(
+ CsrtAction::getFormat('row_action'),
+ '',
+ (($row->status)
+ ? sprintf(CsrtAction::getLink('row_action_right', __('image config'), 'config'), '', tep_href_link(FILENAME_CONFIGURATION, FILENAME_CFG_129.'action=modules-edit&mod='.$row->content->code ),'' )
+ : ''
+ )
+ );
+ }
+
+ /**
+ @brief return format html for row status
+ @param $product array restuts row
+ @return string html
+ */
+ public static function GetStatusMod_ot($row){
+ $exclude=array('action','mod','forceajax','type','class','function','funct', 'mod');
+ $query_s=FILENAME_CFG_129.'action=modules&mod=' . $row->content->code.'&flag=';
+
+ return '<a class="ajaxinline" href="' . tep_href_link(FILENAME_CONFIGURATION, tep_get_all_get_params($exclude).$query_s.(($row->status == '1')? '0' : '1') ) . '">'.
+ sprintf(
+ CsrtAction::getFormat('row_flag'),
+ (int)$row->status,
+ ( ($row->status == '1')? IMAGE_ICON_STATUS_GREEN : IMAGE_ICON_STATUS_RED)
+ ).
+ '</a>';
+ }
}
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/modules/cronjob/customers_birthday.php
===================================================================
--- trunk/catalog/admin/includes/modules/cronjob/customers_birthday.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/modules/cronjob/customers_birthday.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 21/03/11, 18:38
+ @version 2.1.1
+ @date 03/03/2012, 18:38
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class customers_birthday
@@ -20,9 +20,9 @@
public $config=false;
/**
- @var string laert le jour J, or avant l'anniversaire (+2)
+ @var string alert le jour J, or avant l'anniversaire (+2)
*/
- CONST ECART = '+2'; //'+2';
+ CONST ECART = '+2';
public function __construct(){
}
@@ -55,8 +55,6 @@
tep_mail($bdarr['customers_firstname'], $bdarr['customers_email_address'], $bd_sub, $message_final, STORE_NAME, STORE_OWNER_EMAIL_ADDRESS, '');
- tep_mail('aurelien scim.com', 'aur...@os...', $bd_sub, $message_final, STORE_NAME, STORE_OWNER_EMAIL_ADDRESS, '');
-
}
}
}
Modified: trunk/catalog/admin/includes/template/oscss/data/icon_set.xml
===================================================================
--- trunk/catalog/admin/includes/template/oscss/data/icon_set.xml 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/template/oscss/data/icon_set.xml 2012-03-05 20:54:24 UTC (rev 4069)
@@ -34,6 +34,7 @@
<view>icon_view.png</view>
<trash>icon_trash.gif</trash>
<refresh>refresh.png</refresh>
+ <config>settings.png</config>
<!-- <recup_order>
</recup_order> -->
Modified: trunk/catalog/admin/includes/widget/Notification.php
===================================================================
--- trunk/catalog/admin/includes/widget/Notification.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/widget/Notification.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,15 +1,18 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 10/02/11, 19:11
+ @version 2.1.1
+ @date 04/03/2012, 19:11
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief is notification by db , list and link
*/
if(!class_exists('adminNotif'))require_once(DIR_WS_MODULES.'pages/adminNotif.php');
+
+if(count(adminNotif::$list)<=0)
+ return false;
?>
<div id="Notification" class="<?php echo $widg['class'] ?>">
<h3><a href="<?php echo tep_href_link(FILENAME_ADMINNOTIF) ?>"><?php echo __('heading notification') ;?></a></h3>
@@ -22,4 +25,4 @@
</ul>
<div class="separator"></div>
- </div>
+</div>
Modified: trunk/catalog/admin/includes/widget/orderLastservice.php
===================================================================
--- trunk/catalog/admin/includes/widget/orderLastservice.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/widget/orderLastservice.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -4,7 +4,7 @@
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 0203/2012, 20:02
+ @date 02/03/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -30,7 +30,7 @@
</tr>
<?php foreach($_query->fetchAllAssoc() as $row) : ?>
<tr>
- <td><strong><a href="<?php echo tep_href_link(FILENAME_ORDERS, 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['service_id'] ?></strong></td>
+ <td><strong><a href="<?php echo tep_href_link('services.php', 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['service_id'] ?></strong></td>
<td style="width:200px;"><?php echo tep_customers_row_action($row['customers_id'], array()) ?></td>
<td><?php echo tep_date_short($row['date_added']) ?></td>
<td><?php echo tep_date_short($row['date_start']) ?></td>
Modified: trunk/catalog/admin/includes/widget/orderLastshipp.php
===================================================================
--- trunk/catalog/admin/includes/widget/orderLastshipp.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/admin/includes/widget/orderLastshipp.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -4,7 +4,7 @@
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 0203/2012, 20:02
+ @date 02/03/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -30,7 +30,7 @@
</tr>
<?php foreach($_query->fetchAllAssoc() as $row) : ?>
<tr>
- <td class="tcenter"><strong><a href="<?php echo tep_href_link(FILENAME_ORDERS, 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['shipping_id'] ?></strong></td>
+ <td class="tcenter"><strong><a href="<?php echo tep_href_link('shipping.php', 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['shipping_id'] ?></strong></td>
<td>
<?php if(( $filepath=$datadocs->GetDoc('delivery', $row['shipping_id'] )) && file_exists($filepath)): ?>
<a href="<?php echo tep_href_link('document.php', 'mod=delivery&id='. $row['shipping_id']) ?>"><?php echo basename($filepath) ?></a>
Modified: trunk/catalog/common/classes/notification.php
===================================================================
--- trunk/catalog/common/classes/notification.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/common/classes/notification.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -12,8 +12,8 @@
UTilise les class des admins
*/
+error_reporting(E_ALL);
-
class notification {
const TABLE = TABLE_NOTIFICATION;
@@ -43,7 +43,9 @@
@remarks if not key exits in config , force put master admin
*/
self::$conf[] = array('chknotif_method' => 'sql',
- 'chknotif_user'=> 1);
+ 'chknotif_user'=> 1,
+ 'chknotif_grp'=> 1,
+ );
}
else
self::$conf=$r->fetchAllAssoc();
@@ -69,16 +71,30 @@
switch($item['chknotif_method']) {
case 'sql' :
- $DB->query($sql="INSERT INTO ".self::ADMIN_TABLE_NOTIF." (notif_id,notif_type,user_id,notif_key,notif_data,notif_text, notif_date) VALUES ('',0,'".(int)$item['chknotif_user']."', '".self::$key."','".tep_db_input($data)."','".tep_db_input($message_final['html'])."' ,now() ) " );
+ if((int)$item['chknotif_user'] > 0)
+ $DB->query($sql="INSERT INTO ".self::ADMIN_TABLE_NOTIF." (notif_id,notif_type,user_id,notif_key,notif_data,notif_text, notif_date) VALUES ('',0,'".(int)$item['chknotif_user']."', '".self::$key."','".tep_db_input($data)."','".tep_db_input($message_final['html'])."' ,now() ) " );
+ if((int)$item['chknotif_grp'] > 0){
+ $r = $DB->query("SELECT admin_id as id FROM ".TABLE_ADMIN." where admin_groups_id='".(int)$item['chknotif_grp']."' " );
+
+ foreach($r->fetchAllAssoc() as $admin)
+ if((int)$item['chknotif_user'] !=(int)$admin['id'])
+ $DB->query($sql="INSERT INTO ".self::ADMIN_TABLE_NOTIF." (notif_id,notif_type,user_id,notif_key,notif_data,notif_text, notif_date) VALUES ('',1,'".(int)$admin['id']."', '".self::$key."','".tep_db_input($data)."','".tep_db_input($message_final['html'])."' ,now() ) " );
+ }
+
break;
case 'email':
default:
- $r=$DB->query("select admin_firstname as firstname, admin_lastname as lastname, admin_email_address as email from ".TABLE_ADMIN." where admin_id='".(int)$item['chknotif_user']."' " );
+ if((int)$item['chknotif_user'] > 0)
+ $r=$DB->query("select admin_firstname as firstname, admin_lastname as lastname, admin_email_address as email from ".TABLE_ADMIN." where admin_id='".(int)$item['chknotif_user']."' " );
+ elseif((int)$item['chknotif_grp'] > 0)
+ $r=$DB->query("select admin_firstname as firstname, admin_lastname as lastname, admin_email_address as email from ".TABLE_ADMIN." where admin_groups_id='".(int)$item['chknotif_grp']."' " );
- $admin=$r->fetchAssoc();
- tep_mail($admin['firstname'].' '.$admin['lastname'], $admin['email'], $subjet, $message_final, STORE_OWNER, EMAIL_FROM);
+
+ foreach($r->fetchAllAssoc() as $admin)
+ if((int)$item['chknotif_user'] !=(int)$admin['id'])
+ tep_mail($admin['firstname'].' '.$admin['lastname'], $admin['email'], $subjet, $message_final, STORE_OWNER, EMAIL_FROM);
}
}
}
@@ -91,7 +107,7 @@
@param $myarray array
@param $data string GET
*/
- public static function notif($key,$subjet,$myarray,$data){
+ public static function notif($key,$subjet,$myarray=array(),$data=''){
self::$key=$key;
self::loadConf($key);
@@ -110,7 +126,7 @@
@param $message_final string
@param $data string GET
*/
- public static function notifInMess($key,$subjet,$message_final,$data){
+ public static function notifInMess($key,$subjet,$message_final,$data=''){
self::$key=$key;
self::loadConf($key);
Modified: trunk/catalog/common/classes/osCSS_Cache.php
===================================================================
--- trunk/catalog/common/classes/osCSS_Cache.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/common/classes/osCSS_Cache.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,10 +1,10 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- \licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
- \portion code Copyright (c) 2002 osCommerce
- \package osCSS-2 <www http://www.oscss.org>
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 31/10/11, 08:07
+ @date 04/03/2012, 21:31
\author oscim <mail aur...@os...> <www http://www.oscim.fr>
\encode UTF-8
\class osCSS_Cache
@@ -112,20 +112,22 @@
}
/**
+ @fn clear($key, $core=false)
@param $key string key base du nom des fichier a supprimer
@param $core bool core false = public, true = admin
+ @return none
*/
public static function clear($key, $core=false) {
$key_length = strlen($key);
- $folder=(($core)? DIR_FS_ADMIN.DIR_WS_INCLUDES.'tmp/cache/' : DIR_FS_WORK);
+ $folder=(($core)? DIR_FS_ROOT_DOCS.'admin/'.DIR_CACHE : DIR_FS_WORK) ;
$d = dir($folder);
if(is_object($d)){
while ($entry = $d->read()) {
- if ((strlen($entry) >= $key_length) && (substr($entry, 0, $key_length) == $key)) {
- unlink($folder . $entry);
- }
+ if ((strlen($entry) >= $key_length) && (substr($entry, 0, $key_length) == $key)) {
+ unlink($folder . $entry);
+ }
}
$d->close();
Modified: trunk/catalog/common/classes/osCSS_CacheLib.php
===================================================================
--- trunk/catalog/common/classes/osCSS_CacheLib.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/common/classes/osCSS_CacheLib.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,10 +1,10 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 26/09/10, 21:31
+ @version 2.1.1
+ @date 04/03/2012, 21:31
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class CacheLib
@@ -22,7 +22,7 @@
protected function __construct(){
self::$cache_key = null;
- self::$folder=(defined('DIR_WS_ADMIN')? DIR_FS_ADMIN.DIR_WS_INCLUDES.'tmp/cache/' : DIR_FS_WORK);
+ self::$folder=(defined('DIR_WS_ADMIN')? DIR_FS_ROOT_DOCS .'admin/'. DIR_CACHE : DIR_FS_WORK);
}
public static function read($key, $expire = 0) {
@@ -36,7 +36,7 @@
$difference = floor((time() - filemtime($filename)) / 60);
if ( ($expire == '0') || ($difference < $expire) ) {
- return true;
+ return true;
}
}
Deleted: trunk/catalog/includes/languages/fr_FR/modules/order_total/ot_shipping.php
===================================================================
--- trunk/catalog/includes/languages/fr_FR/modules/order_total/ot_shipping.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/includes/languages/fr_FR/modules/order_total/ot_shipping.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,14 +0,0 @@
-<?php
-/**
- @licence GPL 2005-2009 The osCSS developers - osCSS Open Source E-commerce
- @package oscss-2 <www http://www.oscss.org>
- @version Rc-3
- @date 10/03/10, 15:14
- @author oscim <mail aur...@os...> <www http://www.oscim.fr>
- @encode UTF-8
-*/
- define('MODULE_ORDER_TOTAL_SHIPPING_TITLE',"Expédition" );
- define('MODULE_ORDER_TOTAL_SHIPPING_DESCRIPTION',"Coût d'Expédition" );
- define('FREE_SHIPPING_TITLE',"Expédition gratuite" );
- define('FREE_SHIPPING_DESCRIPTION',"Expédition gratuite pour les commandes supérieures à %s" );
-?>
\ No newline at end of file
Copied: trunk/catalog/includes/languages/fr_FR/modules/order_total/ot_shipping.txt (from rev 4068, trunk/catalog/includes/languages/fr_FR/modules/order_total/ot_shipping.php)
===================================================================
--- trunk/catalog/includes/languages/fr_FR/modules/order_total/ot_shipping.txt (rev 0)
+++ trunk/catalog/includes/languages/fr_FR/modules/order_total/ot_shipping.txt 2012-03-05 20:54:24 UTC (rev 4069)
@@ -0,0 +1,15 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 04/02/2012, 20:00
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['module order total shipping title'] = "Expédition" ;
+$lang['module order total shipping description'] = "Coût d'Expédition" ;
+$lang['free shipping title'] = "Expédition gratuite" ;
+$lang['free shipping description'] = "Expédition gratuite pour les commandes supérieures à %s" ;
+?>
\ No newline at end of file
Modified: trunk/catalog/includes/modules/order_total/ot_shipping.php
===================================================================
--- trunk/catalog/includes/modules/order_total/ot_shipping.php 2012-03-05 10:10:43 UTC (rev 4068)
+++ trunk/catalog/includes/modules/order_total/ot_shipping.php 2012-03-05 20:54:24 UTC (rev 4069)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 20/10/11, 16:43
+ @date 02/03/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief total shipping
@@ -15,8 +15,8 @@
function ot_shipping() {
$this->code = 'ot_shipping';
- $this->title = MODULE_ORDER_TOTAL_SHIPPING_TITLE;
- $this->description = MODULE_ORDER_TOTAL_SHIPPING_DESCRIPTION;
+ $this->tit...
[truncated message content] |
|
From: <os...@us...> - 2012-03-05 10:10:53
|
Revision: 4068
http://oscss.svn.sourceforge.net/oscss/?rev=4068&view=rev
Author: oscim
Date: 2012-03-05 10:10:43 +0000 (Mon, 05 Mar 2012)
Log Message:
-----------
correction suite commit pr?\195?\169c?\195?\169dent, et fichier manquant ou coquille
Modified Paths:
--------------
trunk/catalog/admin/includes/database_tables.php
trunk/catalog/admin/includes/modules/pages/adminUsers.php
trunk/catalog/includes/database_tables.php
Added Paths:
-----------
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/shipping.txt
Modified: trunk/catalog/admin/includes/database_tables.php
===================================================================
--- trunk/catalog/admin/includes/database_tables.php 2012-03-05 10:02:05 UTC (rev 4067)
+++ trunk/catalog/admin/includes/database_tables.php 2012-03-05 10:10:43 UTC (rev 4068)
@@ -85,6 +85,11 @@
define('TABLE_ORDERS_STATUS_HISTORY', DB_TABLE_PREFIX . 'orders_status_history');
define('TABLE_ORDERS_TOTAL', DB_TABLE_PREFIX . 'orders_total');
+
+ define('TABLE_SERVICES', DB_TABLE_PREFIX.'services');
+ define('TABLE_SHIPPING', DB_TABLE_PREFIX.'shipping');
+ define('TABLE_SHIPPING_PRODUCTS', DB_TABLE_PREFIX.'shipping_products');
+
## Customers tables
# Master tables
define('TABLE_CUSTOMERS', DB_TABLE_PREFIX . 'customers');
@@ -178,7 +183,7 @@
define('TABLE_NAVIGATION_LINKS_TO_CATEGORIES', DB_TABLE_PREFIX . 'navigation_links_to_categories');
-## Image index
+## Image index
define('TABLE_IMAGES', DB_TABLE_PREFIX . 'images');
/// TOP Not Used for dev
define('TABLE_IMAGES_USED', DB_TABLE_PREFIX . 'images_used');
Added: trunk/catalog/admin/includes/languages/fr_FR/modules/pages/shipping.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/pages/shipping.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/pages/shipping.txt 2012-03-05 10:10:43 UTC (rev 4068)
@@ -0,0 +1,40 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 04/03/2012, 16:07
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['heading title shipping']="Expeditions vers les clients" ;
+
+
+// $lang['tab services briefs']="Details" ;
+// $lang['tab services details']="Commande" ;
+
+/* Action */
+ /* Listing */
+ $lang['table heading shipping id']="n°" ;
+ $lang['table heading order id']="Cmd n°" ;
+ $lang['table heading customers']="Clients" ;
+ $lang['table heading date expedition']="Expd. le" ;
+ $lang['table heading method']="Méthode" ;
+ $lang['table heading status']="Etat" ;
+ $lang['table heading action']="Action" ;
+
+
+ /* mutli */
+ $lang['shipping update n %s']="Appliquer a cette livraison" ;
+ $lang['text info multi notify']="informer le client de ce changement " ;
+ $lang['image modify multi']="Valider" ;
+
+
+
+/* Value list */
+ /* status */
+ $lang['shipping opened']="Ouverte" ;
+ $lang['shipping progress']="En cours" ;
+ $lang['shipping closed']="Cloturé" ;
+?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/modules/pages/adminUsers.php
===================================================================
--- trunk/catalog/admin/includes/modules/pages/adminUsers.php 2012-03-05 10:02:05 UTC (rev 4067)
+++ trunk/catalog/admin/includes/modules/pages/adminUsers.php 2012-03-05 10:10:43 UTC (rev 4068)
@@ -1,10 +1,10 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 28/12/11, 17:28
+ @date 04/03/2012, 17:28
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class adminUsers
@@ -39,12 +39,20 @@
@param string/false
*/
public static $url_redirect=self::FILENAME;
+ /**
+ @param array
+ */
+ public static $modules;
+
/**
class constructor
*/
public function __construct() {
self::$code=__CLASS__;
+
+ sqladminuser::getInstance();
+ self::$modules = sqladminuser::$modules;
}
public function check_action($actions){
@@ -122,7 +130,7 @@
}
if (in_array($_POST['admin_email_address'], $stored_email)) {
- tep_redirect(tep_href_link(self::FILENAME, 'page=' . $page . 'mID=' . $_GET['mID'] . '&error=email&action=edit_member'));
+ tep_redirect(tep_href_link(self::FILENAME, 'page=' . $page . 'mID=' . $_GET['mID'] . '&error=email&action=edit'));
}
else {
$sql_data_array = array('id' => $admin_id,
@@ -240,18 +248,32 @@
public static function load_db_values($ID){
$DB=Database::getInstance();
+
+
$array=sqladminuser::fetch(array('id'=>(int)$ID));
+ self::$modules->load_db_values($ID);
+// print_r(self::$modules);
+
return new objectInfo($array);
}
public function display_view(){
+ $action = self::$action;
switch(self::$action){
+ case 'edit':
+ break;
+
+
default:
- self::tep_get_list();
- return tep_get_include_contents(__CLASS__.'.listing');
+ self::tep_get_list();
+ $action ='listing';
+// return tep_get_include_contents(__CLASS__.'.listing');
}
+
+ /// use master gabarit
+ return MGabCont::CallGab($action,__FUNCTION__,__CLASS__);
}
@@ -289,7 +311,7 @@
$contents[] = array('class' => 'button_nav','text' => tep_image_submit('button_insert.gif', IMAGE_INSERT) . ' <a class="button" href="' . tep_href_link(self::FILENAME) . '">' . IMAGE_CANCEL . '</a>');
break;
- case 'edit_member':
+ case 'edit':
$heading[] = array('text' => __('text info heading new') );
$contents = array('form' => tep_draw_form('newmember', self::$url_redirect, 'action=member_edit&mID=' . self::$mInfo->admin_id, 'post', '', ' name="newmember"'));
@@ -334,9 +356,9 @@
$contents[] = array('text' => '<strong>' . __('text info fullname') . '</strong>' . self::$mInfo->admin_firstname . ' ' . self::$mInfo->admin_lastname);
$contents[] = array('text' => '<strong>' . __('text info email') . '</strong>' . self::$mInfo->admin_email_address);
$contents[] = array('text' => '<strong>' . __('text info group') . '</strong>' . self::$mInfo->admin_groups_name);
- $contents[] = array('text' => '<strong>' . __('text info created') . '</strong>' . self::$mInfo->admin_created);
- $contents[] = array('text' => '<strong>' . __('text info modified') . '</strong>' . self::$mInfo->admin_modified);
- $contents[] = array('text' => '<strong>' . __('text info logdate') . '</strong>' . self::$mInfo->admin_logdate);
+ $contents[] = array('text' => '<strong>' . __('text info created') . '</strong>' . tep_date_short(self::$mInfo->admin_created));
+ $contents[] = array('text' => '<strong>' . __('text info modified') . '</strong>' . tep_date_short(self::$mInfo->admin_modified));
+ $contents[] = array('text' => '<strong>' . __('text info logdate') . '</strong>' . tep_date_short(self::$mInfo->admin_logdate));
$contents[] = array('text' => '<strong>' . __('text info lognum') . '</strong>' . self::$mInfo->admin_lognum);
}
}
Modified: trunk/catalog/includes/database_tables.php
===================================================================
--- trunk/catalog/includes/database_tables.php 2012-03-05 10:02:05 UTC (rev 4067)
+++ trunk/catalog/includes/database_tables.php 2012-03-05 10:10:43 UTC (rev 4068)
@@ -79,10 +79,10 @@
define('TABLE_ORDERS_STATUS_HISTORY', DB_TABLE_PREFIX . 'orders_status_history');
define('TABLE_ORDERS_TOTAL', DB_TABLE_PREFIX . 'orders_total');
+ define('TABLE_SERVICES', DB_TABLE_PREFIX.'services');
+ define('TABLE_SHIPPING', DB_TABLE_PREFIX.'shipping');
+ define('TABLE_SHIPPING_PRODUCTS', DB_TABLE_PREFIX.'shipping_products');
-
- define('TABLE_SERVICES', DB_TABLE_PREFIX.'services');
-
define('TABLE_PRODUCTS', DB_TABLE_PREFIX . 'products');
define('TABLE_PRODUCTS_ATTRIBUTES', DB_TABLE_PREFIX . 'products_attributes');
define('TABLE_PRODUCTS_ATTRIBUTES_DOWNLOAD', DB_TABLE_PREFIX . 'products_attributes_download');
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-05 10:02:15
|
Revision: 4067
http://oscss.svn.sourceforge.net/oscss/?rev=4067&view=rev
Author: oscim
Date: 2012-03-05 10:02:05 +0000 (Mon, 05 Mar 2012)
Log Message:
-----------
ajustement des colonne de la db pour les extra , oubli?\195?\169 lors des commit precendent
Modified Paths:
--------------
trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields.sql
trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields_labels.sql
Modified: trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields.sql
===================================================================
--- trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields.sql 2012-03-05 09:50:47 UTC (rev 4066)
+++ trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields.sql 2012-03-05 10:02:05 UTC (rev 4067)
@@ -15,6 +15,7 @@
CREATE TABLE osc_products_extra_fields (
epf_id int unsigned NOT NULL auto_increment,
epf_order int NOT NULL default 0,
+ epf_input_type tinyint(1) NOT NULL default 0,
epf_status tinyint(1) NOT NULL default 1,
epf_uses_value_list tinyint(1) not null default 0,
epf_advanced_search tinyint(1) not null default 1,
Modified: trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields_labels.sql
===================================================================
--- trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields_labels.sql 2012-03-05 09:50:47 UTC (rev 4066)
+++ trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields_labels.sql 2012-03-05 10:02:05 UTC (rev 4067)
@@ -17,6 +17,9 @@
languages_id int NOT NULL,
epf_label varchar(64),
epf_label_help varchar(160) default NULL COMMENT 'aide contextuelle',
+ epf_format varchar(64) NOT NULL,
+ epf_unity_type_id int(11) NOT NULL,
+ epf_unity_id int(11) NOT NULL,
PRIMARY KEY (epf_id, languages_id)
) DEFAULT CHARSET=utf8;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-05 09:50:53
|
Revision: 4066
http://oscss.svn.sourceforge.net/oscss/?rev=4066&view=rev
Author: oscim
Date: 2012-03-05 09:50:47 +0000 (Mon, 05 Mar 2012)
Log Message:
-----------
correction
Modified Paths:
--------------
trunk/catalog/install/includes/modele/htaccess.txt
Modified: trunk/catalog/install/includes/modele/htaccess.txt
===================================================================
--- trunk/catalog/install/includes/modele/htaccess.txt 2012-03-05 09:49:41 UTC (rev 4065)
+++ trunk/catalog/install/includes/modele/htaccess.txt 2012-03-05 09:50:47 UTC (rev 4066)
@@ -145,6 +145,7 @@
RewriteRule ^(.*)account(_([a-z_]*)).(php|html)$ account.php?action=$3&%{QUERY_STRING} [L,QSA]
RewriteRule ^address_([a-z_]*).php$ account.php?aca_mod=address_book&aca_type=account&aca_action=display_view&%{QUERY_STRING}
+ RewriteRule ^contact.(php|html)$ index.php?d=contact.php&%{QUERY_STRING} [L,QSA]
## Move xxxx.php >> xxx.html
RewriteCond %{REQUEST_FILENAME} !-f
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-05 09:49:52
|
Revision: 4065
http://oscss.svn.sourceforge.net/oscss/?rev=4065&view=rev
Author: oscim
Date: 2012-03-05 09:49:41 +0000 (Mon, 05 Mar 2012)
Log Message:
-----------
Ajout d'un jeu de tva
Modified Paths:
--------------
trunk/catalog/install/includes/sql/mysql/data/91_osc_tax_rates.sql
Modified: trunk/catalog/install/includes/sql/mysql/data/91_osc_tax_rates.sql
===================================================================
--- trunk/catalog/install/includes/sql/mysql/data/91_osc_tax_rates.sql 2012-03-05 09:48:36 UTC (rev 4064)
+++ trunk/catalog/install/includes/sql/mysql/data/91_osc_tax_rates.sql 2012-03-05 09:49:41 UTC (rev 4065)
@@ -12,6 +12,7 @@
--+######################################################################--+
insert into osc_tax_rates (tax_rates_id, tax_zone_id, tax_class_id, tax_priority, tax_rate, tax_description, last_modified, date_added) values ('1', '2', '1', '0', '7.0000', 'FL TAX 7.0%', NULL, NOW());
insert into osc_tax_rates (tax_rates_id, tax_zone_id, tax_class_id, tax_priority, tax_rate, tax_description, last_modified, date_added) values ('2', '1', '2', '1', '19.6000', 'TVA normal', NULL, NOW());
+insert into osc_tax_rates (tax_rates_id, tax_zone_id, tax_class_id, tax_priority, tax_rate, tax_description, last_modified, date_added) values ('3', '1', '3', '2', '7.0000', 'TVA 7%', NULL, NOW());
insert into osc_tax_rates (tax_rates_id, tax_zone_id, tax_class_id, tax_priority, tax_rate, tax_description, last_modified, date_added) values ('4', '1', '3', '2', '5.5000', 'TVA 5.5', NULL, NOW());
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-05 09:48:47
|
Revision: 4064
http://oscss.svn.sourceforge.net/oscss/?rev=4064&view=rev
Author: oscim
Date: 2012-03-05 09:48:36 +0000 (Mon, 05 Mar 2012)
Log Message:
-----------
FS#974
fichier manquant
Added Paths:
-----------
trunk/catalog/admin/includes/gabarit/geo_zones/display_view.listing.gab
Added: trunk/catalog/admin/includes/gabarit/geo_zones/display_view.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/geo_zones/display_view.listing.gab (rev 0)
+++ trunk/catalog/admin/includes/gabarit/geo_zones/display_view.listing.gab 2012-03-05 09:48:36 UTC (rev 4064)
@@ -0,0 +1,35 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 04/03/2012, 16:35
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+?>
+<h3><?php echo __('heading title'); ?></h3>
+
+
+ <div class="button_nav">
+ <?php if (!geo_zones::$action) echo '<a class="button" href="' . tep_href_link(FILENAME_GEO_ZONES, tep_get_all_get_params(array('action','sID')). '&action=new_zone') . '">' .tep_image(DIR_WS_ICONS . 'icon_add_new.png', IMAGE_ICON_INFO).' '. __('image insert new zone') . '</a>'; ?>
+ </div>
+
+ <div class="box_uniq">
+<!-- <div class="box_left"> -->
+ <table class="dataTable">
+ <thead>
+ <tr>
+ <th style="width:20px;"><?php echo __('table heading tax zones type'); ?></th>
+ <th style="width:20px;"><?php echo __('table heading tax zones grp'); ?></th>
+ <th><?php echo __('table heading tax zones'); ?></th>
+ <th><?php echo __('table heading tax zones desc'); ?></th>
+ <th><?php echo __('table heading nbr sub'); ?></th>
+ <th class="tright"><?php echo __('table heading action'); ?></th>
+ </tr>
+ </thead>
+ <tbody>
+ <!-- AJAX BLOCK -->
+ </tbody>
+ </table>
+</div>
\ No newline at end of file
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-04 21:08:19
|
Revision: 4063
http://oscss.svn.sourceforge.net/oscss/?rev=4063&view=rev
Author: oscim
Date: 2012-03-04 21:08:12 +0000 (Sun, 04 Mar 2012)
Log Message:
-----------
FS#972
activationpar var de conf du profile publique des client/membres
Modified Paths:
--------------
trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modmembres.txt
trunk/catalog/index.php
trunk/catalog/install/includes/sql/mysql/data/91_osc_configuration.sql
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modmembres.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modmembres.txt 2012-03-04 20:52:25 UTC (rev 4062)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modmembres.txt 2012-03-04 21:08:12 UTC (rev 4063)
@@ -86,5 +86,7 @@
$lang['CUSTOMER_FORCE_STRTOUPPER_L']="Force le nom en majscule lors enregistrement" ;
$lang['CUSTOMER_CITY_FORCE_STRTOUPPER_S']="Force le nom de la ville en majscule" ;
$lang['CUSTOMER_CITY_FORCE_STRTOUPPER_L']="Force le nom de la ville en majscule lors enregistrement" ;
+$lang['CUSTOMER_PUBLIC_PROFIL_S']="Active un profil public pour les membres" ;
+$lang['CUSTOMER_PUBLIC_PROFIL_L']="Autorise l'affichage d'un profile public" ;
?>
\ No newline at end of file
Modified: trunk/catalog/index.php
===================================================================
--- trunk/catalog/index.php 2012-03-04 20:52:25 UTC (rev 4062)
+++ trunk/catalog/index.php 2012-03-04 21:08:12 UTC (rev 4063)
@@ -72,7 +72,7 @@
* \section Page Customer public
\note For active public customer page , delete false
*/
- if (false/* isset($_GET['customers_id'])*/ ) {
+ if (_cst_bool('CUSTOMER_PUBLIC_PROFIL') && isset($_GET['customers_id']) ) {
$page->init('customers.php',$language);
$breadcrumb=$page->return_object('breadcrumb');
Modified: trunk/catalog/install/includes/sql/mysql/data/91_osc_configuration.sql
===================================================================
--- trunk/catalog/install/includes/sql/mysql/data/91_osc_configuration.sql 2012-03-04 20:52:25 UTC (rev 4062)
+++ trunk/catalog/install/includes/sql/mysql/data/91_osc_configuration.sql 2012-03-04 21:08:12 UTC (rev 4063)
@@ -336,11 +336,11 @@
insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('SPPC_EMAIL_ALERT_CREAT_ACCOUNT_S', 'SPPC_EMAIL_ALERT_CREAT_ACCOUNT', 'true', 'SPPC_EMAIL_ALERT_CREAT_ACCOUNT_L ', '28', '19', NULL, NOW(), 'tep_value_for_humain', 'tep_cfg_select_option(array(\'true\', \'false\'),', '3');
insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function) values ('MAX_DISPLAY_PRODUCTS_IN_ORDER_HISTORY_BOX_S', 'MAX_DISPLAY_PRODUCTS_IN_ORDER_HISTORY_BOX', '6', 'MAX_DISPLAY_PRODUCTS_IN_ORDER_HISTORY_BOX_L', '28', '20', NULL, NOW(), NULL, NULL);
insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function) values ('MAX_DISPLAY_ORDER_HISTORY_S', 'MAX_DISPLAY_ORDER_HISTORY', '10', 'MAX_DISPLAY_ORDER_HISTORY_L', '28', '21', NULL, NOW(), NULL, NULL);
-insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('CUSTOMER_FORCE_UCWORDS_S', 'CUSTOMER_FORCE_UCWORDS', '6', 'CUSTOMER_FORCE_UCWORDS_L', '28', '20', NULL, NOW(), 'tep_value_for_humain', 'tep_cfg_select_option(array(\'true\', \'false\'),','3');
-insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('CUSTOMER_FORCE_STRTOUPPER_S', 'CUSTOMER_FORCE_STRTOUPPER', '10', 'CUSTOMER_FORCE_STRTOUPPER_L', '28', '21', NULL, NOW(), 'tep_value_for_humain', 'tep_cfg_select_option(array(\'true\', \'false\'),','3');
-insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('CUSTOMER_CITY_FORCE_STRTOUPPER_S', 'CUSTOMER_CITY_FORCE_STRTOUPPER', '10', 'CUSTOMER_CITY_FORCE_STRTOUPPER_L', '28', '21', NULL, NOW(), 'tep_value_for_humain', 'tep_cfg_select_option(array(\'true\', \'false\'),','3');
+insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('CUSTOMER_FORCE_UCWORDS_S', 'CUSTOMER_FORCE_UCWORDS', 'true', 'CUSTOMER_FORCE_UCWORDS_L', '28', '20', NULL, NOW(), 'tep_value_for_humain', 'tep_cfg_select_option(array(\'true\', \'false\'),','3');
+insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('CUSTOMER_FORCE_STRTOUPPER_S', 'CUSTOMER_FORCE_STRTOUPPER', 'true', 'CUSTOMER_FORCE_STRTOUPPER_L', '28', '21', NULL, NOW(), 'tep_value_for_humain', 'tep_cfg_select_option(array(\'true\', \'false\'),','3');
+insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('CUSTOMER_CITY_FORCE_STRTOUPPER_S', 'CUSTOMER_CITY_FORCE_STRTOUPPER', 'true', 'CUSTOMER_CITY_FORCE_STRTOUPPER_L', '28', '21', NULL, NOW(), 'tep_value_for_humain', 'tep_cfg_select_option(array(\'true\', \'false\'),','3');
+insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('CUSTOMER_PUBLIC_PROFIL_S', 'CUSTOMER_PUBLIC_PROFIL', 'true', 'CUSTOMER_PUBLIC_PROFIL_L', '28', '21', NULL, NOW(), 'tep_value_for_humain', 'tep_cfg_select_option(array(\'true\', \'false\'),','3');
-
-- 128 General environement
insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('USE_LOCAL_GENERAT_PDF_S', 'USE_LOCAL_GENERAT_PDF', '10', 'USE_LOCAL_GENERAT_PDF_L', '128', '5', NULL, NOW(), 'tep_value_for_humain', 'tep_cfg_select_option(array(\'true\', \'false\'),','3');
insert into osc_configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function, configuration_type) values ('USE_MODELE_PDF_S', 'USE_MODELE_PDF', 'harry', 'USE_MODELE_PDF_L', '128', '5', NULL, NOW(), NULL, '','2');
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-04 20:52:31
|
Revision: 4062
http://oscss.svn.sourceforge.net/oscss/?rev=4062&view=rev
Author: oscim
Date: 2012-03-04 20:52:25 +0000 (Sun, 04 Mar 2012)
Log Message:
-----------
suppression doublon + reorganise les icones d'actions
Modified Paths:
--------------
trunk/catalog/admin/includes/modules/pages/products.php
Modified: trunk/catalog/admin/includes/modules/pages/products.php
===================================================================
--- trunk/catalog/admin/includes/modules/pages/products.php 2012-03-04 20:36:55 UTC (rev 4061)
+++ trunk/catalog/admin/includes/modules/pages/products.php 2012-03-04 20:52:25 UTC (rev 4062)
@@ -424,14 +424,13 @@
CsrtAction::getFormat('row_action'),
self::$modules->display_ColumnRowAction($products['products_id']) ,
sprintf(CsrtAction::getLink('row_action_right', __('image view public') , 'publiclink'), '', tep_catalog_href_link('index.php', 'products_id=' . $products['products_id'],'SSL', true, 'forceview') ,' target="blank" ' ).
- sprintf(CsrtAction::getLink('row_action_right', IMAGE_COPY_TO, 'copyto'), 'fancy', tep_href_link(self::FILENAME, 'pID=' . $products['products_id'] . '&action=copy_to') ,'' ).
- sprintf(CsrtAction::getLink('row_action_right', IMAGE_EDIT, 'edit'), '', tep_href_link(self::FILENAME, 'pID=' . $products['products_id'] . '&action=new_product') ,'' ).
- sprintf(CsrtAction::getLink('row_action_right', IMAGE_DELETE, 'delete'), 'fancy', tep_href_link(self::FILENAME, 'pID=' . $products['products_id'] . '&action=delete_product') ,'' ).
((_cst_bool('STOCK_CHECK'))
? sprintf(CsrtAction::getLink('row_action_right', __('txt stock') , 'stock'), 'fancyView', tep_href_link(FILENAME_STOCK, 'product_id=' . $products['products_id'].'&origin='.self::FILENAME) ,'' )
: ''
).
- sprintf(CsrtAction::getLink('row_action_right', __('image view public') , 'publiclink'), '', tep_catalog_href_link('product_info.php', 'products_id=' . $products['products_id']) ,' target="blank"' )
+ sprintf(CsrtAction::getLink('row_action_right', IMAGE_COPY_TO, 'copyto'), 'fancy', tep_href_link(self::FILENAME, 'pID=' . $products['products_id'] . '&action=copy_to') ,'' ).
+ sprintf(CsrtAction::getLink('row_action_right', IMAGE_EDIT, 'edit'), '', tep_href_link(self::FILENAME, 'pID=' . $products['products_id'] . '&action=new_product') ,'' ).
+ sprintf(CsrtAction::getLink('row_action_right', IMAGE_DELETE, 'delete'), 'fancy', tep_href_link(self::FILENAME, 'pID=' . $products['products_id'] . '&action=delete_product') ,'' )
);
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-04 20:37:05
|
Revision: 4061
http://oscss.svn.sourceforge.net/oscss/?rev=4061&view=rev
Author: oscim
Date: 2012-03-04 20:36:55 +0000 (Sun, 04 Mar 2012)
Log Message:
-----------
Correction coquille nommage class driver sqlgeozone, ajustement des fichier correspondant
Ajout d'une page de gestiion de livraison (shipping) et uen page de gestion des services. Configuration et mise en oeuvre des listing et flag. Les page d'edition ne sont pas fonctionnel .
Ajout d une colonne dans la table shipping , et customers
ajustement et correction des icones des menus en css , ajustement des fichier de menu correpondant
restructuration du menu commercial et orders. changement des intitul?\195?\169s en fr
ajustement du dashbord pour la prise en charge des 2 nouveau tableau de bord
Modified Paths:
--------------
trunk/catalog/Documents/admin/data/dashboard.xml
trunk/catalog/admin/includes/boxes/05_customers.php
trunk/catalog/admin/includes/boxes/07_catalog.php
trunk/catalog/admin/includes/boxes/08_cms.php
trunk/catalog/admin/includes/boxes/09_commercial.php
trunk/catalog/admin/includes/boxes/10_orders.php
trunk/catalog/admin/includes/classes/drivers/sqlgeozone.php
trunk/catalog/admin/includes/gabarit/package/display_view.source.edit.gab
trunk/catalog/admin/includes/languages/fr_FR/boxes/05_customers.php
trunk/catalog/admin/includes/languages/fr_FR/boxes/09_commercial.php
trunk/catalog/admin/includes/languages/fr_FR/boxes/10_orders.php
trunk/catalog/admin/includes/modules/account/history.php
trunk/catalog/admin/includes/modules/configuration/modexpedition.php
trunk/catalog/admin/includes/modules/pages/geo_zones.php
trunk/catalog/admin/includes/template/oscss/stylesheet-1.css
trunk/catalog/includes/modules/shipping/flat.php
trunk/catalog/install/includes/sql/mysql/tables/osc_customers.sql
trunk/catalog/install/includes/sql/mysql/tables/osc_shipping.sql
Added Paths:
-----------
trunk/catalog/admin/includes/gabarit/services/
trunk/catalog/admin/includes/gabarit/services/display_view.edit.gab
trunk/catalog/admin/includes/gabarit/shipping/
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/services.txt
trunk/catalog/admin/includes/modules/pages/services.php
trunk/catalog/admin/includes/modules/pages/shipping.php
Modified: trunk/catalog/Documents/admin/data/dashboard.xml
===================================================================
--- trunk/catalog/Documents/admin/data/dashboard.xml 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/Documents/admin/data/dashboard.xml 2012-03-04 20:36:55 UTC (rev 4061)
@@ -12,25 +12,9 @@
</right>
</admin>
- <home>
- <left>
- <widget>Notification</widget>
- <widget>homeStock</widget>
- <widget>dashbordInfo</widget>
- <widget>quickview</widget>
- <widget>orderStats</widget>
- <widget>customerStats</widget>
- <widget>info_connexion</widget>
- </left>
- <right>
- <widget class="graph" querystring="Sales">salesStats</widget>
- <widget>homeNews</widget>
- </right>
- </home>
-
<catalog>
<left>
<widget>homeStock</widget>
@@ -65,7 +49,61 @@
</right>
</commercial>
+ <configuration>
+ <left>
+ <widget>brief_config</widget>
+ </left>
+ <right>
+ <widget>info_connexion</widget>
+ </right>
+ </configuration>
+
+ <config_100>
+ <left>
+ <widget>HelpConfig</widget>
+ </left>
+ <right>
+ <widget>SsMenuConfig</widget>
+ </right>
+ </config_100>
+
+ <config_110>
+ <left>
+ <widget>HelpConfig</widget>
+ </left>
+ <right>
+ <widget>SsMenuConfig</widget>
+ </right>
+ </config_110>
+
+ <config_120>
+ <left>
+ <widget>HelpConfig</widget>
+ </left>
+ <right>
+ <widget>SsMenuConfig</widget>
+ </right>
+ </config_120>
+
+ <config_126>
+ <left>
+ <widget>HelpConfig</widget>
+ </left>
+ <right>
+ <widget>SsMenuConfig</widget>
+ </right>
+ </config_126>
+
+ <config_127>
+ <left>
+ <widget>HelpConfig</widget>
+ </left>
+ <right>
+ <widget>SsMenuConfig</widget>
+ </right>
+ </config_127>
+
<customers>
<left>
<!-- <widget>orderStats</widget> -->
@@ -80,20 +118,25 @@
</customers>
- <orders>
+ <home>
<left>
- <widget>orderLastnews</widget>
- <widget>orderLastshipp</widget>
- <widget>orderLastinvoice</widget>
- <widget>orderStats</widget>
+ <widget>Notification</widget>
+ <widget>homeStock</widget>
+
+
+ <widget>dashbordInfo</widget>
+ <widget>quickview</widget>
+ <widget>orderStats</widget>
+ <widget>customerStats</widget>
+ <widget>info_connexion</widget>
</left>
<right>
<widget class="graph" querystring="Sales">salesStats</widget>
- <widget>orderLastmodified</widget>
- <widget>orderLastservice</widget>
+ <widget>homeNews</widget>
</right>
- </orders>
+ </home>
+
<mail>
<left>
@@ -108,6 +151,31 @@
</right>
</mail>
+ <modules>
+ <left>
+<!-- <widget>packageGeneral</widget> -->
+ <widget>packageRepository</widget>
+ </left>
+ <right>
+<!-- <widget>salesStats</widget> -->
+ </right>
+ </modules>
+
+ <orders>
+ <left>
+ <widget>orderLastnews</widget>
+ <widget>orderLastshipp</widget>
+ <widget>orderLastinvoice</widget>
+ <widget>orderStats</widget>
+ </left>
+ <right>
+ <widget class="graph" querystring="Sales">salesStats</widget>
+ <widget>orderLastmodified</widget>
+ <widget>orderLastservice</widget>
+
+ </right>
+ </orders>
+
<tools>
<left>
<widget>currencies_update_server</widget>
@@ -117,24 +185,26 @@
</right>
</tools>
- <modules>
+ <shipping>
<left>
-<!-- <widget>packageGeneral</widget> -->
- <widget>packageRepository</widget>
+ <widget>orderLastnews</widget>
+ <widget>orderLastshipp</widget>
</left>
<right>
-<!-- <widget>salesStats</widget> -->
+ <widget class="graph" querystring="Sales">salesStats</widget>
</right>
- </modules>
+ </shipping>
- <configuration>
+
+ <services>
<left>
- <widget>brief_config</widget>
+ <widget>orderLastnews</widget>
+ <widget>orderLastservice</widget>
</left>
<right>
- <widget>info_connexion</widget>
+ <widget class="graph" querystring="Sales">salesStats</widget>
</right>
- </configuration>
+ </services>
<system>
<left>
@@ -147,44 +217,4 @@
</right>
</system>
- <config_100>
- <left>
- <widget>HelpConfig</widget>
- </left>
- <right>
- <widget>SsMenuConfig</widget>
- </right>
- </config_100>
- <config_110>
- <left>
- <widget>HelpConfig</widget>
- </left>
- <right>
- <widget>SsMenuConfig</widget>
- </right>
- </config_110>
- <config_120>
- <left>
- <widget>HelpConfig</widget>
- </left>
- <right>
- <widget>SsMenuConfig</widget>
- </right>
- </config_120>
- <config_126>
- <left>
- <widget>HelpConfig</widget>
- </left>
- <right>
- <widget>SsMenuConfig</widget>
- </right>
- </config_126>
- <config_127>
- <left>
- <widget>HelpConfig</widget>
- </left>
- <right>
- <widget>SsMenuConfig</widget>
- </right>
- </config_127>
</root>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/boxes/05_customers.php
===================================================================
--- trunk/catalog/admin/includes/boxes/05_customers.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/boxes/05_customers.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,13 +1,12 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9
- @date 08/06/10, 14:17
+ @version 2.1.1
+ @date 03/03/2012, 17:23
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
- $tabl_link[]= array(FILENAME_CUSTOMERS, 'BOX_CUSTOMERS_CUSTOMERS', 'customers',@$img['customers']);
- $tabl_link[]= array(FILENAME_CUSTOMERS.'?action=new', 'BOX_CUSTOMERS_CUSTOMERS_ADD_NEW', 'customers',@$img['customers']);
- $tabl_link[]= array(FILENAME_RECOVER_CART_SALES, 'BOX_RECOVER_CART_SALES', 'recover_cart_sales',@$img['recover_cart_sales']);
+ $tabl_link[]= array(FILENAME_CUSTOMERS, 'BOX_CUSTOMERS_CUSTOMERS', 'membres',@$img['suppliers']);
+ $tabl_link[]= array(FILENAME_CUSTOMERS.'?action=new', 'BOX_CUSTOMERS_CUSTOMERS_ADD_NEW', 'membres',@$img['suppliers']);
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/boxes/07_catalog.php
===================================================================
--- trunk/catalog/admin/includes/boxes/07_catalog.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/boxes/07_catalog.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,14 +1,14 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9
- @date 19/07/10, 16:25
+ @version 2.1.1
+ @date 03/03/2012, 17:23
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
$tabl_link[]= array(FILENAME_PRODUCTS, 'BOX_CATALOG_PRODUCTS', 'products', @$img['products']);
$tabl_link[]= array(FILENAME_PRODUCTS.'?cPath=&action=new', 'BOX_CATALOG_PRODUCT_ADD', 'product_add', @$img['product_add']);
$tabl_link[]= array(FILENAME_PRODUCTS.'?expected=true', 'BOX_CATALOG_PRODUCTS_EXPECTED', 'products', @$img['products']);
- $tabl_link[]= array(FILENAME_ATTRIBUTES, 'BOX_CATALOG_ATTIBUTES', 'discount_coupon', @$img['discount_coupon']);
+ $tabl_link[]= array(FILENAME_ATTRIBUTES, 'BOX_CATALOG_ATTIBUTES', 'attributes', @$img['attributes']);
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/boxes/08_cms.php
===================================================================
--- trunk/catalog/admin/includes/boxes/08_cms.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/boxes/08_cms.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,14 +1,14 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9
- @date 20/07/10, 17:23
+ @version 2.1.1
+ @date 03/03/2012, 17:23
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
$tabl_link[]= array(FILENAME_CATEGORIES, 'BOX_CATALOG_CATEGORIES', 'categories', @$img['categories']);
$tabl_link[]= array(FILENAME_CMS_CONTENT, 'BOX_CMS_CONTENT', 'cms_content',@$img['cms_content']);
$tabl_link[]= array(FILENAME_NAVIGATION_LINKS, 'BOX_NAVIGATION_LINK', 'nav',@$img['navigation_link']);
- $tabl_link[]= array('editeur/tiny_mce/plugins/tinybrowser/tinybrowser.php?type=image', 'BOX_NAVIGATION_IMAGE', 'nav',@$img['navigation_image']);
+ $tabl_link[]= array('editeur/tiny_mce/plugins/tinybrowser/tinybrowser.php?type=image', 'BOX_NAVIGATION_IMAGE', 'images',@$img['navigation_image']);
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/boxes/09_commercial.php
===================================================================
--- trunk/catalog/admin/includes/boxes/09_commercial.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/boxes/09_commercial.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,13 +1,16 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9
- @date 20/07/10, 19:22
+ @version 2.1.1
+ @date 03/03/2012, 17:23
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
$tabl_link[609]= array('ss_menu', 'BOX_TOOLS_MAIL', 'mail',@$img['mail']);
$tabl_link[609][4][]= array(FILENAME_NEWSLETTERS, 'BOX_TOOLS_NEWSLETTER_MANAGER', 'newsletters',@$img['newsletters']);
$tabl_link[609][4][]= array('newslettersModeles.php', 'BOX_TOOLS_NEWSLETTER_MANAGER_MODELES', 'newsletters',@$img['newsletters']);
+// $tabl_link[609]= array('ss_menu', 'BOX_TOOLS_MAIL', 'mail',@$img['mail']);
+ $tabl_link[]= array(FILENAME_HELD_ORDERS, 'BOX_CUSTOMERS_HELD_ORDERS', 'held_orders',@$img['held_orders']);
+ $tabl_link[]= array(FILENAME_RECOVER_CART_SALES, 'BOX_RECOVER_CART_SALES', 'recover_cart_sales',@$img['recover_cart_sales']);
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/boxes/10_orders.php
===================================================================
--- trunk/catalog/admin/includes/boxes/10_orders.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/boxes/10_orders.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,19 +1,34 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 13/11/11, 15:59
+ @date 03/03/2012, 17:23
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
- $tabl_link[]= array(FILENAME_ORDERS.'?view=thisday', 'BOX_CUSTOMERS_ORDERS_THISDAY', 'orders',@$img['orders']);
- $tabl_link[]= array(FILENAME_ORDERS.'?view=opened', 'BOX_CUSTOMERS_ORDERS_OPENED', 'orders',@$img['orders']);
- $tabl_link[]= array(FILENAME_ORDERS.'?view=nopayed', 'BOX_CUSTOMERS_ORDERS_NOPAYED', 'orders',@$img['orders']);
- $tabl_link[]= array(FILENAME_ORDERS.'?view=allnoclosed', 'BOX_CUSTOMERS_ORDERS_ALLNOCLOSED', 'orders',@$img['orders']);
- $tabl_link[]= array(FILENAME_ORDERS, 'BOX_CUSTOMERS_ORDERS_ALL', 'orders',@$img['orders']);
- if(_cst_bool('RMA_RETURN_PRODUCTS_STATUS')) $tabl_link[]= array(FILENAME_RETURNS, 'BOX_RETURNS_HEADING', 'return',@$img['return']);
- $tabl_link[]= array(FILENAME_HELD_ORDERS, 'BOX_CUSTOMERS_HELD_ORDERS', 'held_orders',@$img['held_orders']);
+ $tabl_link[850]= array('ss_menu', 'BOX_CUSTOMERS_ORDERS', 'orders',@$img['orders']);
+ $tabl_link[850][4][]= array(FILENAME_ORDERS.'?view=thisday', 'BOX_CUSTOMERS_ORDERS_THISDAY', 'orders',@$img['orders']);
+ $tabl_link[850][4][]= array(FILENAME_ORDERS.'?view=opened', 'BOX_CUSTOMERS_ORDERS_OPENED', 'orders',@$img['orders']);
+ $tabl_link[850][4][]= array(FILENAME_ORDERS.'?view=nopayed', 'BOX_CUSTOMERS_ORDERS_NOPAYED', 'orders',@$img['orders']);
+ $tabl_link[850][4][]= array(FILENAME_ORDERS.'?view=allnoclosed', 'BOX_CUSTOMERS_ORDERS_ALLNOCLOSED', 'orders',@$img['orders']);
+ $tabl_link[850][4][]= array(FILENAME_ORDERS, 'BOX_CUSTOMERS_ORDERS_ALL', 'orders',@$img['orders']);
+ if(_cst_bool('RMA_RETURN_PRODUCTS_STATUS'))
+ $tabl_link[850][4][]= array(FILENAME_RETURNS, 'BOX_RETURNS_HEADING', 'return',@$img['return']);
+
+
+ $tabl_link[851]= array('ss_menu', 'BOX_CUSTOMERS_SHIPPING', 'shipping',@$img['shipping']);
+ $tabl_link[851][4][]= array('shipping.php?view=opened', 'BOX_CUSTOMERS_SHIPPING_OPENNED', 'orders',@$img['orders']);
+ $tabl_link[851][4][]= array('shipping.php?view=progress', 'BOX_CUSTOMERS_SHIPPING_PROGRESS', 'orders',@$img['orders']);
+ $tabl_link[851][4][]= array('shipping.php?view=clsed', 'BOX_CUSTOMERS_SHIPPING_CLOSE', 'orders',@$img['orders']);
+
+ if( strlen(TYPE_VIRTUAL_PRODUCTS) >= 1) {
+ $tabl_link[852]= array('ss_menu', 'BOX_CUSTOMERS_SERVICES', 'services',@$img['services']);
+ $tabl_link[852][4][]= array('services.php', 'BOX_CUSTOMERS_SERVICES_ALL', 'services',@$img['services']);
+ $tabl_link[852][4][]= array('services.php?view=opened', 'BOX_CUSTOMERS_SERVICES_ACTIVED', 'services',@$img['services']);
+ $tabl_link[852][4][]= array('services.php?view=closed', 'BOX_CUSTOMERS_SERVICES_INACTIVED', 'services',@$img['services']);
+ }
+
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/classes/drivers/sqlgeozone.php
===================================================================
--- trunk/catalog/admin/includes/classes/drivers/sqlgeozone.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/classes/drivers/sqlgeozone.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,10 +1,10 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 01/11/11, 09:50
+ @date 01/11/12, 09:50
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class geozones
@@ -12,7 +12,7 @@
-Class sqlgeozones
+Class sqlgeozone
implements ModSqlDataDriver{
public static $modules;
@@ -174,8 +174,8 @@
@brief
@return array product empty
*/
- public static function Specimen(){
- $par = array('geo_zone_id' => '',
+ public static function Specimen($shortkey=false){
+ $result = array('geo_zone_id' => '',
'geo_zone_type' => '',
'geo_zone_grp' => '',
'geo_zone_name' => '',
@@ -184,7 +184,7 @@
'last_modified'=>'',
);
- return self::CleanKey($par);
+ return ((!$shortkey)? $result : self::CleanKey($result));
}
@@ -198,7 +198,7 @@
$object= new stdclass();
foreach($array as $key=>$value){
- if( strpos($key,'geo_zone_') ===9)
+ if( strpos($key,'geo_zone_') ===0)
$key=substr($key,9);
$object->$key = $value;
Modified: trunk/catalog/admin/includes/gabarit/package/display_view.source.edit.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/package/display_view.source.edit.gab 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/gabarit/package/display_view.source.edit.gab 2012-03-04 20:36:55 UTC (rev 4061)
@@ -12,7 +12,7 @@
?>
<h3><?php echo __('title heading configuration source repository edit') ?></h3>
-
+ not implemented in this version
<?php echo tep_draw_form('new_product', package::FILENAME, 'type_data=source&action=source_update', 'post'); ?>
<div class="box_uniq block_form">
Added: trunk/catalog/admin/includes/gabarit/services/display_view.edit.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/services/display_view.edit.gab (rev 0)
+++ trunk/catalog/admin/includes/gabarit/services/display_view.edit.gab 2012-03-04 20:36:55 UTC (rev 4061)
@@ -0,0 +1,40 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 04/03/2012, 11:35
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+global $price, $current_theme;
+?>
+<div class="box_uniq block_form main-services">
+
+ <div id="tabs">
+ <ul>
+ <li><a href="#tabs-1"><?php echo __('tab services briefs'); ?></a></li>
+ <li><a href="#tabs-2"><?php echo __('tab services details'); ?></a></li>
+ </ul>
+
+ <div id="tabs-1" class="tabPage">
+
+ not implemented in this version
+ </div>
+
+
+ <div id="tabs-2" class="tabPage">
+ not implemented in this version
+ </div>
+
+ </div>
+
+
+
+ <div class="button_nav">
+ <?php echo tep_js_back(tep_href_link(services::FILENAME), IMAGE_CANCEL);?>
+ </div>
+
+
+</div>
Modified: trunk/catalog/admin/includes/languages/fr_FR/boxes/05_customers.php
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/boxes/05_customers.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/languages/fr_FR/boxes/05_customers.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,15 +1,16 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 09/12/10, 17:23
+ @version 2.1.1
+ @date 03/03/2012, 17:23
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief file languages for boxes menu
*/
-define('BOX_HEADING_CONF_CUSTOMERS',"Clients" );
+define('BOX_HEADING_CONF_CUSTOMERS',"Tiers" );
define('BOX_CUSTOMERS_CUSTOMERS',"Clients/Membres" );
define('BOX_CUSTOMERS_CUSTOMERS_ADD_NEW',"Ajouter un Client" );
-define('BOX_HEADING_CONF_BOX_RECOVER_CART_SALES',"Paniers abandonnés" );
+define('BOX_COMMERCIAL_VENDORS',"Fournisseurs" );
+
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/boxes/09_commercial.php
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/boxes/09_commercial.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/languages/fr_FR/boxes/09_commercial.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,18 +1,20 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 09/12/10, 17:23
+ @version 2.1.1
+ @date 03/03/2012, 17:23
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief file languages for boxes menu
*/
define('BOX_HEADING_CONF_COMMERCIAL',"Commercial" );
-define('BOX_COMMERCIAL_VENDORS',"Fournisseurs" );
+
define('BOX_TOOLS_MAIL',"Email/Newsletter" );
define('BOX_TOOLS_MAIL_NEW',"Envoyez un email" );
define('BOX_TOOLS_NEWSLETTER_MANAGER',"Bulletin d'information" );
define('BOX_TOOLS_NEWSLETTER_MANAGER_MODELES',"Modèle de bulletin" );
+define('BOX_HEADING_CONF_BOX_RECOVER_CART_SALES',"Paniers abandonnés" );
+define('BOX_CUSTOMERS_HELD_ORDERS',"Commandes abandonnées" );
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/boxes/10_orders.php
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/boxes/10_orders.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/languages/fr_FR/boxes/10_orders.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,18 +1,30 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 13/11/11, 15:59
+ @date 03/03/2012, 17:23
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief file languages for boxes menu
*/
-define('BOX_HEADING_CONF_ORDERS',"Commandes" );
+define('BOX_HEADING_CONF_ORDERS',"Metiers" );
+
+define('BOX_CUSTOMERS_ORDERS',"Commandes" );
define('BOX_CUSTOMERS_ORDERS_THISDAY',"Commande du jour" );
define('BOX_CUSTOMERS_ORDERS_ALLNOCLOSED',"Commandes ouvertes" );
define('BOX_CUSTOMERS_ORDERS_ALL',"Toutes les commandes" );
define('BOX_CUSTOMERS_ORDERS_OPENED',"Commandes en traitement" );
define('BOX_CUSTOMERS_ORDERS_NOPAYED',"Commandes en attente" );
-define('BOX_CUSTOMERS_HELD_ORDERS',"Commandes abandonnées" );
+
+
+define('BOX_CUSTOMERS_SHIPPING',"Livraisons" );
+define('BOX_CUSTOMERS_SHIPPING_OPENNED',"Ouvertes" );
+define('BOX_CUSTOMERS_SHIPPING_PROGRESS',"En cours" );
+define('BOX_CUSTOMERS_SHIPPING_CLOSE',"Fermées" );
+
+define('BOX_CUSTOMERS_SERVICES',"Services" );
+define('BOX_CUSTOMERS_SERVICES_ALL',"Tous" );
+define('BOX_CUSTOMERS_SERVICES_ACTIVED',"Activés" );
+define('BOX_CUSTOMERS_SERVICES_INACTIVED',"Inactif" );
?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/modules/pages/services.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/pages/services.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/pages/services.txt 2012-03-04 20:36:55 UTC (rev 4061)
@@ -0,0 +1,28 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 04/03/2012, 16:07
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['heading title services']="Services" ;
+
+
+// $lang['tab services briefs']="Details" ;
+// $lang['tab services details']="Commande" ;
+
+
+/* Listing */
+ $lang['table heading service id']="n°" ;
+ $lang['table heading order id']="Cmd n°" ;
+ $lang['table heading customers']="Clients" ;
+ $lang['table heading date start']="Activé le" ;
+ $lang['table heading auto_retry']="Auto" ;
+ $lang['table heading status']="Etat" ;
+ $lang['table heading action']="Action" ;
+
+
+?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/modules/account/history.php
===================================================================
--- trunk/catalog/admin/includes/modules/account/history.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/modules/account/history.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 01/11/11, 20:02
+ @date 03/03/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class history
@@ -75,7 +75,7 @@
$n = new stdClass();
$n->date = tep_datetime_short($row['date_purchased']);
$n->type = 'order';
- $n->text = sprintf(__('history new commande n %s'), $row['orders_id']);
+ $n->text = sprintf(__('history new commande n %s'), ' <a class="linkdoc" href="'.tep_href_link(FILENAME_ORDERS, 'action=edit&oID='.$row['orders_id']).'">'.$row['orders_id'].'</a> ');
$result[strtotime($row['date_purchased'])]=$n;
}
Modified: trunk/catalog/admin/includes/modules/configuration/modexpedition.php
===================================================================
--- trunk/catalog/admin/includes/modules/configuration/modexpedition.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/modules/configuration/modexpedition.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/09/11, 19:49
+ @date 04/03/2012, 19:49
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class modexpedition
@@ -67,182 +67,184 @@
switch($action){
/**
- @brief save Config base page
+ @brief save Config base page
*/
case 'save_mutli':
- if(tep_not_null($gID) ){
+ if(tep_not_null($gID) ){
- $list=sqlconfiguration::fetch(array('group_id'=> (int)$gID), true);
+ $list=sqlconfiguration::fetch(array('group_id'=> (int)$gID), true);
- if(is_object($list))
- $liste[]=$list;
- else
- $liste=$list;
+ if(is_object($list))
+ $liste[]=$list;
+ else
+ $liste=$list;
- foreach($liste as $row) {
+ foreach($liste as $row) {
- if(isset($_POST['configuration'][$row->key])) {
- $configuration_value = tep_db_prepare_input($_POST['configuration'][$row->key]);
+ if(isset($_POST['configuration'][$row->key])) {
+ $configuration_value = tep_db_prepare_input($_POST['configuration'][$row->key]);
- if( ($res=sqlconfiguration::update(array('key'=>$row->key , 'value'=>tep_db_input($configuration_value) ))) == false)$erreur[]=false;
- else $erreur[]=true;
+ if( ($res=sqlconfiguration::update(array('key'=>$row->key , 'value'=>tep_db_input($configuration_value) ))) == false)$erreur[]=false;
+ else $erreur[]=true;
- }
+ }
- }
+ }
- if(!in_array(false,$erreur)) $messageStack->add_session(SAVE_CONFIG_OK, 'success');
- else $messageStack->add_session(SAVE_CONFIG_NOT_OK, 'error');
+ if(!in_array(false,$erreur)) $messageStack->add_session(SAVE_CONFIG_OK, 'success');
+ else $messageStack->add_session(SAVE_CONFIG_NOT_OK, 'error');
- }
+ }
- tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '#modexpedition-config' ));
+ tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '#modexpedition-config' ));
break;
/**
- @brief Manage shipping zones
+ @brief Manage shipping zones
*/
case 'zones':
+ if(isset($_POST[__CLASS__]['zone']) && is_array($_POST[__CLASS__]['zone']) ){
- if(isset($_POST[__CLASS__]['zone']) && is_array($_POST[__CLASS__]['zone']) ){
+ foreach($_POST[__CLASS__]['zone'] as $key=>$row){
+ $sql_a['id'] = (int)tep_db_prepare_input($key);
+ $sql_a['name'] = tep_db_prepare_input($row);
- foreach($_POST[__CLASS__]['zone'] as $key=>$row){
- $sql_a['id'] = (int)tep_db_prepare_input($key);
- $sql_a['name'] = tep_db_prepare_input($row);
+ sqlgeozone::update($sql_a);
+ }
- sqlgeozone::update($sql_a);
- }
+ }
- }
-
- tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '#modexpedition-zone' ));
+ tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '#modexpedition-zone' ));
break;
/**
- @brief Manage shipping zones
+ @brief Manage shipping zones
*/
case 'modules':
- if(isset($_GET['flag'])){
+ if(isset($_GET['flag'])){
- $mod=tep_db_prepare_input($_GET['mod']);
- $flag=(int)tep_db_prepare_input($_GET['flag']);
+ $mod=tep_db_prepare_input($_GET['mod']);
+ $flag=(int)tep_db_prepare_input($_GET['flag']);
- // call type module
- $typeOri=modulesUtility::GetModttype('shipping');
- // get current value
- $current = sqlconfiguration::fetch(array('key'=>$typeOri->key), true);
+ // call type module
+ $typeOri=modulesUtility::GetModttype('shipping');
+ // get current value
+ $current = sqlconfiguration::fetch(array('key'=>$typeOri->key), true);
- // call
- $type=modulesUtility::LoadModule('shipping',$mod.'.php');
- // force install
- if( $flag ==1 && !$type->content->check()){
- $type->content->remove();
- $type->content->install();
- }
- // force remove
- elseif( $flag == 0 && $type->content->check())
- $type->content->remove();
+ // call
+ $type=modulesUtility::LoadModule('shipping',$mod.'.php');
+ // force install
+ if( $flag ==1 && !$type->content->check()){
+ $type->content->remove();
+ $type->content->install();
+ }
+ // force remove
+ elseif( $flag == 0 && $type->content->check())
+ $type->content->remove();
- // up module
- $r=explode(';',$typeOri->value);
- $result[]=( ($flag ==1 ) ? $mod.'.php;' : '' );
+ // up module
+ $r=explode(';',$typeOri->value);
+ $result[]=( ($flag ==1 ) ? $mod.'.php;' : '' );
- foreach($r as $v)
- if(trim($v) !='')
- if( (
- $flag ==1
- || ($flag == 0 && $v != trim($mod).'.php' )
- )
- && !in_array($v,$result)
- ){
- $result[]=$v;
- }
+ foreach($r as $v)
+ if(trim($v) !='')
+ if( (
+ $flag ==1
+ || ($flag == 0 && $v != trim($mod).'.php' )
+ )
+ && !in_array($v,$result)
+ ){
+ $result[]=$v;
+ }
- sqlconfiguration::update(array('id'=>$current->id, 'value'=>implode(';',$result)) );
+ sqlconfiguration::update(array('id'=>$current->id, 'value'=>implode(';',$result)) );
- tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '#modexpedition-module' ));
- }
+ tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '#modexpedition-module' ));
+ }
break;
case 'modules-edit':
- $mod=tep_db_prepare_input($_GET['mod']);
- // call
- $Mod=modulesUtility::LoadModule('shipping',$mod.'.php');
- $ModCurr = $Mod->content;
- $i=0;
- foreach($ModCurr->keys() as $value){
- $i++;
- $current = sqlconfiguration::fetch(array('key'=>$value));
+ $mod=tep_db_prepare_input($_GET['mod']);
+ // call
+ $Mod=modulesUtility::LoadModule('shipping',$mod.'.php');
+ $ModCurr = $Mod->content;
+ $i=0;
+ foreach($ModCurr->keys() as $value){
+ $i++;
+ $current = sqlconfiguration::fetch(array('key'=>$value));
- $keys_extra[$value]['title'] = $current['configuration_title'];
- $keys_extra[$value]['value'] = $current['configuration_value'];
- $keys_extra[$value]['description'] = $current['configuration_description'];
- $keys_extra[$value]['use_function'] = $current['use_function'];
- $keys_extra[$value]['set_function'] = $current['set_function'];
- }
+ $keys_extra[$value]['title'] = $current['configuration_title'];
+ $keys_extra[$value]['value'] = $current['configuration_value'];
+ $keys_extra[$value]['description'] = $current['configuration_description'];
+ $keys_extra[$value]['use_function'] = $current['use_function'];
+ $keys_extra[$value]['set_function'] = $current['set_function'];
+ }
- self::$moduleEdit = configUtility::FormatEditAuto(array('array'=>$keys_extra));
+ self::$moduleEdit = configUtility::FormatEditAuto(array('array'=>$keys_extra));
break;
/**
- @brief save Config base page
+ @brief save Config base page
*/
case 'modules-save':
- foreach($_POST['configuration'] as $key=>$value) {
+ foreach($_POST['configuration'] as $key=>$value) {
- $configuration_value = tep_db_prepare_input($value);
+ $configuration_value = tep_db_prepare_input($value);
- if( ($res=sqlconfiguration::update(array('key'=>$key , 'value'=>tep_db_input($value) ))) == false)$erreur[]=false;
- else $erreur[]=true;
+ if( ($res=sqlconfiguration::update(array('key'=>$key , 'value'=>tep_db_input($value) ))) == false)$erreur[]=false;
+ else $erreur[]=true;
- }
+ }
- if(!in_array(false,$erreur)) $messageStack->add_session(SAVE_CONFIG_OK, 'success');
- else $messageStack->add_session(SAVE_CONFIG_NOT_OK, 'error');
+ if(!in_array(false,$erreur)) $messageStack->add_session(SAVE_CONFIG_OK, 'success');
+ else $messageStack->add_session(SAVE_CONFIG_NOT_OK, 'error');
- tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '&action=modules-edit&mod='. $_GET['mod'] ));
+ tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $_GET['gID'] . '&action=modules-edit&mod='. $_GET['mod'] ));
break;
}
}
/**
+ @fn load_db_values($Id)
+ @param $Id int
@return array
*/
public function load_db_values($Id){
- $list_edit=array();
- $gID = 7;
+ $list_edit=array();
+ $gID = 7;
- $list=sqlconfiguration::fetch(array('group_id'=> (int)$gID), true);
+ $list=sqlconfiguration::fetch(array('group_id'=> (int)$gID), true);
- foreach($list as $row) {
+ foreach($list as $row) {
- $cfgValue =configUtility::CallExecConfigLine($row->use, $row->key, $row->value);
+ $cfgValue =configUtility::CallExecConfigLine($row->use, $row->key, $row->value);
- if (!empty($row->set)){
- if(strpos($row->set,'(') === false) $row->set.='(';
- eval('$value_field = ' . $row->set . '"' . htmlspecialchars($row->value) . '","'.$row->key.'");');
- }
- else $value_field = tep_draw_input_field('configuration['.$row->key.']', '',$row->value);
+ if (!empty($row->set)){
+ if(strpos($row->set,'(') === false) $row->set.='(';
+ eval('$value_field = ' . $row->set . '"' . htmlspecialchars($row->value) . '","'.$row->key.'");');
+ }
+ else $value_field = tep_draw_input_field('configuration['.$row->key.']', '',$row->value);
- $conf = $row;
- $row->cfgValue=$cfgValue;
- $row->value_field=$value_field;
+ $conf = $row;
+ $row->cfgValue=$cfgValue;
+ $row->value_field=$value_field;
- $list_edit[$row->key]=$conf;
+ $list_edit[$row->key]=$conf;
}
return $list_edit;
}
+
/**
- Appelé dans le header de page
+ @brief Appelé dans le header de page
*/
public static function draw_header(){
?>
@@ -263,11 +265,9 @@
<?php
}
+
/**
- Contenu central
- @param
- @e global $action
- @e global $gparentID
+ @brief Contenu central
*/
public function draw(){
global $action,$gparentID;
@@ -280,9 +280,9 @@
foreach(scan(DIR_FS_CATALOG_MODULES.'shipping/') as $row){
if( substr($row,-3) =='php'){
- $class = substr($row,0, -4);
+ $class = substr($row,0, -4);
- self::$module[]=modulesUtility::LoadModule('shipping', $row);
+ self::$module[]=modulesUtility::LoadModule('shipping', $row);
}
}
Modified: trunk/catalog/admin/includes/modules/pages/geo_zones.php
===================================================================
--- trunk/catalog/admin/includes/modules/pages/geo_zones.php 2012-03-04 14:00:00 UTC (rev 4060)
+++ trunk/catalog/admin/includes/modules/pages/geo_zones.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -1,18 +1,20 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 28/12/11, 15:25
+ @date 04/03/2012, 15:25
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class geo_zones
@brief base manage zone shipping and taxe
*/
-
class geo_zones
- implements ExtModPage, InterfacedTJsonS, InterfaceModule {
+ implements
+ ExtModPage,
+ InterfacedTJsonS,
+ InterfaceModule {
const FILENAME = FILENAME_GEO_ZONES;
@@ -132,7 +134,7 @@
$myarray['grp'] =tep_db_prepare_input($_POST['geo_zone_grp']) ;
- if( ! $new_zone_id =sqlgeozones::create($myarray) )
+ if( ! $new_zone_id =sqlgeozone::create($myarray) )
$messageStack->add_session(__(sprintf('geo_zones error for insert zone %s'), $myarray['name'] ), 'error');
else
$messageStack->add_session(__(sprintf('geo_zones success for insert %s'), ' '.$myarray['name'] ), 'success');
@@ -194,7 +196,7 @@
else
$myarray['grp'] =tep_db_prepare_input($_POST['geo_zone_grp']) ;
- if( ! sqlgeozones::update($myarray) )
+ if( ! sqlgeozone::update($myarray) )
$messageStack->add_session(__(sprintf('geo_zones error for update zone %s'), $zID ), 'error');
else
$messageStack->add_session(__(sprintf('geo_zones success for update %s'), $zID ), 'success');
@@ -214,7 +216,7 @@
case 'deleteconfirm':
$zID = tep_db_prepare_input($_POST['id']);
- if( ! sqlgeozones::delete(array('id'=>$zID)) )
+ if( ! sqlgeozone::delete(array('id'=>$zID)) )
$messageStack->add_session(__(sprintf('geo_zones error for delete zone %s'), $zID ), 'error');
else
$messageStack->add_session(__(sprintf('geo_zones success for delete %s'), $zID ), 'success');
@@ -256,7 +258,7 @@
'type'=>tep_db_prepare_input($_POST['current_type']),
);
- $id = sqlgeozones::create($myarray);
+ $id = sqlgeozone::create($myarray);
foreach($result as $row){
/// create geo to zone
@@ -606,6 +608,7 @@
if(!isset($res) || count($res)==0) $res[]=array('countries_name'=>' ','zone_name'=>' ','action'=>' ');
}
+
return $res;
}
Added: trunk/catalog/admin/includes/modules/pages/services.php
===================================================================
--- trunk/catalog/admin/includes/modules/pages/services.php (rev 0)
+++ trunk/catalog/admin/includes/modules/pages/services.php 2012-03-04 20:36:55 UTC (rev 4061)
@@ -0,0 +1,801 @@
+<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 04/03/2012, 22:42
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+ @class services
+ @brief manage services, listing and edit status
+*/
+
+
+
+class services
+ extends ModTwo /// new abstract class for nextgen module
+ implements
+ InterfaceModule,
+ IntModTwo, /// new interface module for nextgen module
+ InterfacedInnerHtml {
+
+ /**
+ @var const
+ */
+ const FILENAME = 'services.php';
+
+ /**
+ @var array list, utilisé dans les gabarits, list des services
+ */
+ public static $list=array();
+ /**
+ @var object $order
+ */
+ public static $order;
+ /**
+ @var int Id order
+ */
+ public static $oID;
+ /**
+ @var bool $update autorise mise a jour status
+ */
+ public static $update;
+ /**
+ @var array $services_status_array
+ */
+ public static $services_status_array=array();
+ /**
+ @var array $services_statuses
+ */
+ public static $services_statuses=array();
+ /**
+ @var object $oInfo
+ */
+ public static $oInfo;
+ /**
+ @var object $cInfo detail du client
+ */
+ public static $cInfo;
+ /**
+ @var object $export
+ */
+ public static $export;
+ /**
+ @var string $view for select filter view
+ */
+ public static $view;
+ /**
+ @var object internal trans objet method check_action vs display_view
+ */
+ private static $internal;
+ /**
+ @var requis pour generation pdf
+ */
+ public static $file_type_array ;
+
+ /**
+ @brief class constructor
+ */
+ public function __construct() {
+ self::GetConf();
+ }
+
+ /**
+ @brief Load , adjust and define var environement exe for module
+ Is use in module and class abstract for init value config this module
+ */
+ public static function GetConf(){
+ global $languages_id;
+
+ self::$code=__CLASS__;
+
+ self::$action=(isset($_REQUEST['action'])? (string)$_REQUEST['action'] : 'listing' );
+ self::$view=(isset($_REQUEST['view'])? (string)$_REQUEST['view'] : '' );
+ self::$oID=(isset($_REQUEST['oID'])? $_REQUEST['oID'] : '' );
+
+ $status=(isset($_REQUEST['status'])? (string)$_REQUEST['status'] : '' );
+
+ self::$export= new export(__CLASS__);
+
+ /**
+ @remarks define var execution sql in GetDBValue()
+ */
+ if( !isset(self::$InitInfo['adjust']) )
+ self::$InitInfo['adjust']=array(
+ 'languages_id'=>$languages_id,
+ 'page'=>1,
+ 'rowbyp'=>10,
+ 'sOrder'=>'',
+ 'sWhere'=>'',
+ );
+
+
+
+ /**
+ @remarks not load if not first init
+ */
+ if(defined('JSONSTATMENT')) return;
+
+ //! active datatable in ajax, precise les GET necessaire
+ define('JSONSTATMENT', 'mod=page&type='.self::$code.
+ (isset(parent::$action)?'&action='.parent::$action : '' ).
+ (isset(self::$oID)?'&oID='.self::$oID : '' ).
+ (isset(self::$view)?'&view='.self::$view : '' ).
+ (isset($status)?'&status='.$status : '' )
+ );
+
+ //! detail item in ajax
+ define('AJAXSTATMENTDETAIL', 'mod=page&type='.self::$code);
+
+
+ /**
+ @remarks this define col theader title, and ajust html code
+ Just for Edit listing
+ */
+ self::$InitInfo['theader']['listing']=array(
+ 0 =>array('width'=>'2%', 'class'=>'tcenter', 'txt'=>' ' ),
+ 1 =>array('width'=>'2%', 'class'=>'tcenter', 'txt'=>' ' ),
+ 2 =>array('width'=>'8%', 'class'=>'tcenter', 'txt'=>__('table heading service id') ),
+ 3 =>array('width'=>'8%', 'class'=>'tcenter', 'txt'=>__('table heading order id') ),
+ 4 =>array('width'=>'30%','class'=>'tcenter', 'txt'=>__('table heading customers')),
+ 5 =>array('width'=>'10%', 'txt'=>__('table heading date start')),
+// 5 =>array('width'=>'150px','class'=>'tcenter', 'txt'=>__('table heading order total')),
+ 6 =>array('width'=>'8%', 'txt'=>__('table heading auto_retry')),
+ 7 =>array('width'=>'8%', 'txt'=>__('table heading status')),
+// 7 =>array('width'=>'10%', 'txt'=>__('table heading status')),
+ 8 =>array('width'=>'10%','class'=>'row_action', 'txt'=>__('table heading action')),
+ );
+
+// self::$InitInfo['tfooter']['listing']=array(
+// 0 =>array('width'=>'2%', 'class'=>'tcenter', 'txt'=>tep_draw_hidden_field('xx','xxx','','class="search_init" ') ),
+// 1 =>array('width'=>'2%', 'class'=>'tcenter', 'txt'=>tep_draw_hidden_field('xxx','xxx','','class="search_init" ') ),
+// 2 =>array('width'=>'8%', 'class'=>'tcenter', 'txt'=>tep_draw_input_field('o.services_id','services_id',__('table heading order id'),'style="width:98%" class="search_init"') ),
+// 3 =>array('width'=>'40%','class'=>'tcenter', 'txt'=>tep_draw_input_field('o.customers_name','customers_name',__('table heading customers'),'style="width:98%" class="search_init"') ),
+// 4 =>array('width'=>'150px','class'=>'tcenter', 'txt'=>tep_draw_input_field('ot.text','text',__('table heading order total'),'style="width:98%" class="search_init"') ),
+// 5 =>array('width'=>'10%', 'txt'=>tep_draw_input_field('o.date_purchased','date_purchased',__('table heading date purchased'),'style="width:98%" class="search_init"')),
+// 6 =>array('width'=>'8%', 'txt'=>tep_draw_input_field('o.payment_method','payment_method',__('table heading status'),'style="width:98%" class="search_init"')),
+// 7 =>array('width'=>'10%', 'txt'=>tep_draw_input_field('s.status_name','status_name',__('table heading status'),'style="width:98%" class="search_init"')),
+// 8 =>array('width'=>'10%','class'=>'row_action', 'txt'=>' '),
+// );
+
+ /**
+ @remarks this define col in table, and if is possible sort
+ Just for Edit listing
+ */
+ self::$InitInfo['modele']['listing']=array(
+ 0 =>false,
+ 1 =>false,
+ 'services_id'=>true,
+ 'orders_id'=>true,
+ 'customers_id'=>true,
+ 'date_start'=>true,
+ 'auto_retry'=>true,
+ 'status'=>true,
+ 'action' =>false
+ );
+
+
+ $DB=Database::getInstance();
+// self::$services_statuses=array();
+// $services_status_query = $DB->query("select status_id, status_name from " . TABLE_STATUS . " where status_type='services' and language_id = '" . (int)$languages_id . "'");
+// while ($services_status = $services_status_query->fetchAssoc()) {
+// self::$services_statuses[] = array('id' => $services_status['status_id'], 'text' => $services_status['status_name']);
+// self::$services_status_array[$services_status['status_id']] = $services_status['status_name'];
+// }
+
+
+
+
+ global $oscss;
+ $oscss->_add_ext(BO_WISIWYG_SELECTED,'editeur/');
+ echo $oscss->_call(BO_WISIWYG_SELECTED,'_top','comments','800','400');
+
+ return true;
+ }
+
+
+ public function check_action($actions){
+ global $messageStack,$page_module;
+
+ self::$action=$actions;
+
+ self::$internal = new stdClass;
+
+ switch (self::$action) {
+
+ /**
+ @remarks pdf generate for all docs
+ */
+// case 'pdf':
+//
+// if( _cst_bool('USE_LOCAT_GENERAT_PDF') )
+// $messageStack->add_session(__('warning pdf not generat by this core, please adjust configuration'), 'warning');
+// else {
+// $ID=(int)$_REQUEST['id'];
+// $type=$_REQUEST['file_type'] ;
+// global $pdf, $currencies;
+// osCSS_pdf::getInstance();
+//
+// /// force encode for fdpf is in iso8859
+// header("Content-Type: text/html; charset=utf-8");
+// self::$services_statuses = array_merge(tep_get_status_array('services'),array(array('id'=>'','text'=>TEXT_NONE)));
+// self::$file_type_array= osCSS_pdf::get_module();
+//
+// $pdf=osCSS_pdf::OutputInit($type);
+// $DF = new DatasFiles;
+//
+// switch($type){
+// case 'delivery':
+// global $obj_shipping;
+// $obj_shipping = sqlshipping::fetch(array('id'=>$ID), true);
+// $oID = $obj_shipping->services_id;
+// $order = new order($obj_shipping->services_id);
+// break;
+// case 'packingslip':
+// case 'invoice':
+// default:
+// $oID = $ID;
+// $order = new order($ID);
+// }
+//
+// osCSS_pdf::OutputAddPage();
+//
+// include(osCSS_pdf::getPathModele());
+//
+// $file=$DF->GetDoc(osCSS_pdf::GetPdfType(),$ID);
+//
+// if(file_exists($file))
+// unlink($file);
+//
+// $pdf=osCSS_pdf::SaveEnd($file);
+//
+// /// @remarks draw and exit;
+// // $pdf=osCSS_pdf::OutputEnd();
+// }
+// if(!isset($_GET['forceajax']))
+// tep_redirect(tep_href_link(self::FILENAME, 'oID='.$oID.'&action=edit'));
+// break;
+
+ /**
+ @remarks pdf generate
+ */
+// case 'deletefile':
+// $oID=(int)$_REQUEST['oID'];
+// $ID=(int)$_REQUEST['id'];
+// $type=$_REQUEST['file_type'] ;
+//
+// $datadocs=new DatasFiles;
+//
+// if(( $filepath=$datadocs->GetDoc($type, $ID)) && file_exists($filepath))
+// unlink($filepath);
+//
+// if(!isset($_GET['forceajax']))
+// tep_redirect(tep_href_link(self::FILENAME, 'oID='.$oID.'&action=edit'));
+// break;
+
+
+ /**
+ @remarks Action mutliple
+ */
+ case 'multiconfirm':
+ $res=array();
+
+ $status = tep_db_prepare_input(@$_POST['status_multi']);
+// $modeexport = tep_db_prepare_input(@$_POST['modeexport']);
+ $notify =(isset($_POST['notify'])) ? tep_db_prepare_input($_POST['notify']): '';
+ $comments= (isset($_POST['comments'])) ? tep_db_prepare_input($_POST['comments']) :'';
+ if(isset($_POST['action_multi']) && is_array($_POST['action_multi']) ) {
+
+// if(isset($_POST['status_multi'])){
+// foreach($_POST['action_multi'] as $oID )
+// if (up_status_order($oID, array('status'=>$status,'comments'=>'', 'notify'=>$notify, 'comments'=> $comments) ) ) $res[]=true;
+// else $res[]=false;
+// }
+
+
+// if(isset($_POST['modeexport'])){
+//
+// $modeexport=tep_db_prepare_input($_POST['modeexport']);
+// $encodage=tep_db_prepare_input($_POST['encodage']);
+// $export_type=tep_db_prepare_input($_POST['export_type']);
+// $od=array();
+//
+// self::$export->pre_export(array( 'mode' => $modeexport, 'encodage'=>$encodage, 'export_type'=>$export_type, 'page_admin'=>$page_module));
+//
+// foreach($_POST['action_multi'] as $oID ){
+//
+// $order = new order((int)$oID);
+// $qer=tep_db_query("SELECT countries_iso_code_2 FROM " . TABLE_COUNTRIES . " WHERE countries_name='".$order->customer['country']."' ");
+// $c=tep_db_fetch_array($qer);
+//
+// $od[]=array('IDExpedition'=>$oID,
+// 'IDCustomer'=>$order->customer['id'],
+// 'Namecustomer'=>self::$export->decodage($order->customer['name']),
+// 'Compagnycustomer'=>self::$export->decodage($order->customer['company']),
+// 'Streetadress'=>self::$export->decodage($order->delivery['street_address']),
+// 'Streetadress2'=>self::$export->decodage($order->delivery['suburb']) ,
+// 'Cityshipping'=>self::$export->decodage($order->delivery['city']),
+// 'Stateshipping'=>self::$export->decodage($order->customer['state']) ,
+// 'telephone'=>self::$export->decodage($order->customer['telephone']),
+// 'postcode'=>self::$export->decodage($order->delivery['postcode']),
+// 'codecountryiso'=>$c['countries_iso_code_2'],
+// 'weight'=>round($order->info['total_weight'],3),
+// 'Contreremb'=>'');
+// }
+//
+// print self::$export->op_export($od);
+// }
+ }
+
+ if (in_array(false,$res)) $messageStack->add_session(__('success order updated'), 'success');
+ else $messageStack->add_session(__('warning order not updated'), 'warning');
+
+ tep_redirect(tep_href_link(self::FILENAME));
+ break;
+
+
+
+ /**
+ @remarks Adjust Virtual product Service
+ */
+ case 'setflag':
+ $redirect = false;
+ if (isset($_GET['sID'])){
+
+ /// Activate / Desactivate
+ if (isset($_GET['flag']) && ( ($_GET['flag'] == '0') || ($_GET['flag'] == '1') ) ) {
+ $res = sqlservices::fetch(array('id'=>(int)$_GET['sID']), true);
+
+ if($res !=false){
+
+ $myarray = array(
+ 'id'=>(int)$_GET['sID'],
+ 'status'=>(int)$_GET['flag'] ,
+ );
+
+// if(substr($res->date_start,0,4) <'2000')
+// $myarray['date_start']=date('Y-m-d H:i:s') ;
+
+ if( ! sqlservices::update($myarray) ) {
+ self::$internal->status = $res->status;
+ $redirect = true;
+ $messageStack->add_session(__('error order not update status'), 'warning');
+ }
+ else{
+ self::$internal->status = (int)$_GET['flag'] ;
+ if(!isset($_GET['forceajax']))
+ $messageStack->add_session(__('success order update status'), 'success');
+ }
+ }
+ else {
+ $messageStack->add_session(__('error order id not found'), 'warning');
+ $redirect = true;
+ }
+ }
+
+ /// Auto - retry force activate service
+ elseif ( isset($_GET['auto_retry']) && ( ($_GET['auto_retry'] == '0' ) || ($_GET['auto_retry'] == '1') ) ){
+
+ $res = sqlservices::fetch(array('id'=>(int)$_GET['sID']), true);
+
+ if($res !=false){
+
+ $myarray = array(
+ 'id'=>(int)$_GET['sID'],
+ 'auto_retry'=>(int)$_GET['auto_retry'] ,
+ );
+
+ if( ! sqlservices::update($myarray) ){
+ self::$internal->auto_retry = $res->auto_retry;
+ $redirect = true;
+ $messageStack->add_session(__('error order not update auto_retry'), 'warning');
+ }
+ else{
+ self::$internal->auto_retry = (int)$_GET['auto_retry'] ;
+ if(!isset($_GET['forceajax']))
+ $messageStack->add_session(__('success order update auto_retry'), 'success');
+ }
+ }
+ else {
+ $messageStack->add_session(__('error order id not found'), 'warning');
+ $redirect = true;
+ }
+ }
+
+ }
+
+ if(!isset($_GET['forceajax']) || $redirect )
+ tep_redirect(tep_href_link(self::FILENAME, tep_get_all_get_params(array('action','sID','setflag','auto_retry','flag'), false) .'action=edit' ));
+ break;
+
+ }
+
+ return self::$action;
+ }
+
+ /**
+ @fn get_header()
+ @brief load js and call childs module
+ @return no return
+ */
+ public function get_header(){
+ tep_include_file(DIR_WS_JS . "modules/pages/".__CLASS__.".js.php",true);
+
+ /** aca */ //self::$modules->get_header_js();
+
+ }
+
+
+
+ /**
+ @fn ::GetDBValue();
+ @brief return DB value adapted for current action
+ Use self::action for determine switch
+ @return
+ */
+ public static function GetDBValue(){
+ global $languages_id;
+
+ $arg=((func_num_args()>0) ? func_get_args() : array() );
+
+ $DB=Database::getInstance();
+ $res=array();
+
+ switch (self::$action) {
+ case 'export';
+ break;
+
+ case 'edit':
+
+ $res= sqlservices::fetch(array('id'=>(int)self::$oID ), true);
+
+ return $res;
+ break;
+
+
+ case 'new':
+ $select_adress = array();
+
+ $cID = (int)tep_db_prepare_input($_REQUEST['cID']);
+ $res=sqlcustomer::fetch(array('id'=>$cID), true);
+
+ /**
+ @remarks choose address book if active module adress book
+ */
+ if(isset($res->mod['address_book'])) {
+ foreach($res->mod['address_book'] as $row)
+ $select_adress[] = array('id'=>$row->book_id , 'text'=> tep_address_format($row->format_id, $row, false, '', " - ") );
+ }
+ else{
+ $adrr = new stdClass();
+ $adrr->book_id = $res->default_address_id;
+ $adrr->gender = $res->gender;
+ $adrr->company = $res->company;
+ $adrr->company_tax_id = $res->company_tax_id;
+ $adrr->firstname = $res->firstname;
+ $adrr->lastname = $res->lastname;
+ $adrr->street_address = $res->street_address;
+ $adrr->suburb = $res->suburb;
+ $adrr->postcode = $res->postcode;
+ $adrr->city = $res->city;
+ $adrr->state = $res->state;
+ $adrr->country_id = $res->country_id;
+ $adrr->zone_id = $res->zone_id;
+ $adrr->zone_name = $res->zone_name;
+ $adrr->countries_id = $res->countries_id;
+ $adrr->countries_name = $res->countries_name;
+ $adrr->countries_iso_code_2 = $res->countries_iso_code_2;
+ $adrr->format_id = $res->address_format_id;
+
+ $select_adress[] = array('id'=>$adrr->book_id , 'text'=> tep_address_format($adrr->format_id, $adrr, false, '', "\n") );
+ }
+
+
+ $res->select_adress = $select_adress;
+
+ return $res;
+ break;
+
+
+ case 'listing';
+ /**
+ @remarks retrun object load one inventaire
+ */
+ global $query_numrows;
+ $adjust=new objectInfo(self::$InitInfo['adjust']);
+
+
+
+ $wh=' WHERE ';
+ if(self::$view =='opened')
+ $wh .=" status = '1' ";
+ if(self::$view =='closed')
+ $wh .=" status = '0' ";
+
+
+ if(tep_not_null($adjust->sWhere)){
+// $adjust->sWhere=str_replace(
+// array('services_id', 'order_total', 'customers_id', 'services_status_name'),
+// array('o.services_id', ' ot.text', 'o.customers_name', 's.status_name'),
+// $adjust->sWhere
+// );
+
+ $wh .= ( (strlen($wh) >7)? " AND ": "" )." ".$adjust->sWhere." ";
+ }
+
+ if(strlen($wh) <=7)
+ $wh='';
+
+
+ $query_raw = "SELECT DISTINCT s.* FROM " . TABLE_SERVICES . " s JOIN " . TABLE_ORDERS . " o on (o.orders_id = s.orders_id) ".$wh." ORDER BY ".((!empty($adjust->sOrder)) ? $adjust->sOrder : 's.row_id DESC');
+
+ $_split = new splitPageResults($adjust->page, $adjust->rowbyp, $query_raw, $query_numrows);
+
+ $_query = $DB->query($query_raw);
+
+ $res=self::FormatDBValue($_query);
+
+ return $res;
+ break;
+
+ case 'delete';
+ default:
+
+// $services_query_raw = "select distinct o.services_id,o.services_prefix, o.customers_id,o.customers_name, o.payment_method, o.date_purchased, o.last_modified, o.currency, o.currency_value, s.status_name as services_status_name, s.status_color as services_status_color,ot.text as order_total from " . TABLE_ORDERS . " o left join " . TABLE_ORDERS_TOTAL . " ot on (o.services_id = ot.services_id), " . TABLE_STATUS . " s where o.services_status = s.status_id and s.status_type='services' and s.language_id = '" . (int)$languages_id . "' and ot.class = 'ot_total' and o.services_id='".self::$oID."' ";
+
+// $currency_query = $DB->query($services_query_raw);
+
+// return new objectInfo($currency_query->fetchAssoc() );
+
+ }
+ }
+
+
+
+
+ public function display_view(){
+
+ switch (self::$action) {
+
+ /**
+ @remarks Ajax View result
+ */
+ case 'setflag':
+ if(isset($_GET['flag']))
+ return self::GetServiceStatus(array('status'=>(int)self::$internal->status, 'row_id'=>(int)$_GET['sID']), false);
+ elseif(isset($_GET['auto_retry']))
+ return self::GetServiceStatus(array('auto_retry'=>(int)self::$internal->auto_retry, 'row_id'=>(int)$_GET['sID']), false);
+ break;
+
+ /**
+ @remarks Normal View Page
+ */
+ case 'delete':
+ self::$oInfo=self::GetDBValue();
+ return MGabCont::CallGab(parent::$action,__FUNCTION__,__CLASS__);
+ break;
+ case 'multi':
+ return MGabCont::CallGab(parent::$action,__FUNCTION__,__CLASS__);
+ break;
+
+ case 'new':
+ self::$cInfo=self::GetDBValue();
+
+ return MGabCont::CallGab(parent::$action,__FUNCTION__,__CLASS__);
+ break;
+
+ case 'edit':
+ self::$order= self::GetDBValue();
+
+ ...
[truncated message content] |
|
From: <os...@us...> - 2012-03-04 14:00:06
|
Revision: 4060
http://oscss.svn.sourceforge.net/oscss/?rev=4060&view=rev
Author: oscim
Date: 2012-03-04 14:00:00 +0000 (Sun, 04 Mar 2012)
Log Message:
-----------
correction erreur de notice / control mal defini
Modified Paths:
--------------
trunk/catalog/includes/classes/payment.php
Modified: trunk/catalog/includes/classes/payment.php
===================================================================
--- trunk/catalog/includes/classes/payment.php 2012-03-04 13:59:06 UTC (rev 4059)
+++ trunk/catalog/includes/classes/payment.php 2012-03-04 14:00:00 UTC (rev 4060)
@@ -1,10 +1,10 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
- @portion code Copyright (c) 2002 osCommerce
- @package osCSS-2 <www http://www.oscss.org>
- @version 2.1.1
- @date 20/11/11, 22:45
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 21:44
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
\class payment
@@ -45,7 +45,7 @@
public static function getInstance($module=''){
if(self::$_instance == null || ( !empty($module) && empty(self::$selected_module) )) {
- self::$_instance = new self($module);
+ self::$_instance = new self($module);
}
return self::$_instance;
}
@@ -64,14 +64,15 @@
global $payment, $language, $PHP_SELF,$customer_id,$page,$lang;
$include_modules = array();
- if (tep_not_null($module)) {
+ if (tep_not_null($module) && strlen($module)>3) {
self::$selected_module = $module;
foreach(parent::initialise_type('MODULE_PAYMENT_INSTALLED','payment') as $class){
- if($class == $module) $include_modules[] = array('class' => $class, 'file' => $class . '.php');
+ if($class == $module) $include_modules[] = array('class' => $class, 'file' => $class . '.php');
}
- } else {
+ }
+ else {
foreach(parent::initialise_type('MODULE_PAYMENT_INSTALLED','payment') as $class){
- $include_modules[] = array('class' => $class, 'file' => $class . '.php');
+ $include_modules[] = array('class' => $class, 'file' => $class . '.php');
}
}
@@ -115,11 +116,12 @@
section. This should be looked into again post 2.2.
*/
public function update_status() {
- if (is_array($this->mod)) {
+ if (is_array($this->mod) && strlen(self::$selected_module) > 3) {
+// var_dump(self::$selected_module);
if (is_object($GLOBALS[self::$selected_module])) {
- if (method_exists($GLOBALS[self::$selected_module], 'update_status')) {
- $GLOBALS[self::$selected_module]->update_status();
- }
+ if (method_exists($GLOBALS[self::$selected_module], 'update_status')) {
+ $GLOBALS[self::$selected_module]->update_status();
+ }
}
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-04 13:59:15
|
Revision: 4059
http://oscss.svn.sourceforge.net/oscss/?rev=4059&view=rev
Author: oscim
Date: 2012-03-04 13:59:06 +0000 (Sun, 04 Mar 2012)
Log Message:
-----------
remplissage des champs class_payment et class_shippign de la table order
suite correction des module pour la section des checkouts
correction erreur de notice
Modified Paths:
--------------
trunk/catalog/checkout.php
trunk/catalog/checkout_process.php
trunk/catalog/common/classes/order.php
trunk/catalog/includes/classes/checkout_process.php
trunk/catalog/includes/modules/checkout/PrCgu.php
trunk/catalog/includes/modules/checkout/PrConfirmation.php
trunk/catalog/includes/modules/checkout/PrPayment.php
trunk/catalog/includes/modules/checkout/PrShipping.php
Modified: trunk/catalog/checkout.php
===================================================================
--- trunk/catalog/checkout.php 2012-03-04 10:31:05 UTC (rev 4058)
+++ trunk/catalog/checkout.php 2012-03-04 13:59:06 UTC (rev 4059)
@@ -14,7 +14,7 @@
require('includes/application_top.php');
-error_reporting(E_ALL);
+// error_reporting(E_ALL);
//! chargement order
@@ -37,14 +37,14 @@
if(isset($ACA->modules[$Etape])) {
-
+// var_dump($Etape);
$BeforeProcess=$ACA->modules[$Etape]->BeforeProcess();
}
- $page->breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(constant('FILENAME_CHECKOUT_'.strtoupper(substr($Etape, 2))), '', 'SSL'));
- $page->post_init();
+// $page->breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(constant('FILENAME_CHECKOUT_'.strtoupper(substr($Etape, 2))), '', 'SSL'));
+ $page->post_init(false);
$page->javascript->add_framework("ext/jquery/jquery.min.js");
Modified: trunk/catalog/checkout_process.php
===================================================================
--- trunk/catalog/checkout_process.php 2012-03-04 10:31:05 UTC (rev 4058)
+++ trunk/catalog/checkout_process.php 2012-03-04 13:59:06 UTC (rev 4059)
@@ -13,7 +13,10 @@
*/
include('includes/application_top.php');
-
+// error_reporting(E_ALL);
+// echo __FILE__;
+// var_dump(__FILE__, __LINE__, $r);
+// exit;
$page->init(basename(__FILE__),$language);
$aca_modules = new checkout_process();
@@ -53,7 +56,7 @@
Execution ligne suivante si before_process !=false
*/
if ( ($pay_mod = $payment_modules->before_process()) == false ){
-
+// var_dump(__FILE__, __LINE__, $r);
// Search or load order total modules
if( ($order_total_modules=$page->return_object('order_total')) ==false){
$order_total_modules = new order_total;
@@ -64,10 +67,18 @@
*/
$order_totals = $order_total_modules->process();
+// var_dump(__FILE__, __LINE__, $r);
+// var_dump($_SESSION['the_order_id']);;
+// var_dump($_SESSION['the_order_formated']);;
+// var_dump($_SESSION['pre_order_id']);;
+
$res=$aca_modules->preventDuplicate( array('order_totals'=>$order_totals,'order'=>$order) );
+// var_dump($res);
+// var_dump(__FILE__, __LINE__, $r);
$insert_id=$res['the_order_id'];
- } else {
+ }
+ else {
/**
Execution apres le before du module
et traitement des vars
@@ -86,16 +97,24 @@
*/
$aca_modules->after_process();
- $cart->reset(true);
+// var_dump(__FILE__, __LINE__, $r);
+// print_r($insert_id);
+// exit;
+// $cart->reset(true);
// unregister session variables used during checkout
- tep_session_unregister('sendto');
- tep_session_unregister('billto');
- tep_session_unregister('shipping');
- tep_session_unregister('comments');
- tep_session_unregister('coupon');
- tep_session_unregister('coupon_sav');
+// tep_session_unregister('sendto');
+// tep_session_unregister('billto');
+// tep_session_unregister('shipping');
+// tep_session_unregister('comments');
+// tep_session_unregister('coupon');
+// tep_session_unregister('coupon_sav');
+// exit;
+ $ACA =$page->new_class('checkout', '');
+ $ACA->after_process();
+ $cart->reset(true);
+// exit;
tep_redirect(tep_href_link(FILENAME_CHECKOUT_SUCCESS, '', 'SSL'));
require(DIR_WS_INCLUDES . 'application_bottom.php');
Modified: trunk/catalog/common/classes/order.php
===================================================================
--- trunk/catalog/common/classes/order.php 2012-03-04 10:31:05 UTC (rev 4058)
+++ trunk/catalog/common/classes/order.php 2012-03-04 13:59:06 UTC (rev 4059)
@@ -1,10 +1,10 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- \licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ \licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
\portion code Copyright (c) 2002 osCommerce
\package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 01/11/11, 16:07
+ @date 03/03/2012, 16:07
\author oscim <mail aur...@os...> <www http://www.oscim.fr>
\encode UTF-8
\class order
@@ -165,7 +165,8 @@
}
- $this->mod = array( 'class_payment'=> $order['class_payment'],
+ $this->mod = array(
+ 'class_payment'=> $order['class_payment'],
'class_shipping'=> $order['class_shipping']
);
@@ -258,7 +259,7 @@
@brief Call Public specific Environement for Generate checkout page
*/
public function cart() {
- global $customer_id, $sendto, $billto, $cart, $languages_id, $currency, $currencies, $shipping, $payment,$tax_address,$coupon_sav;
+ global $customer_id, $sendto, $billto, $cart, $languages_id, $currency, $currencies, $shipping, $payment,$tax_address,$coupon_sav, $shipping_mod;
$this->content_type = $cart->get_content_type();
@@ -298,10 +299,17 @@
$this->info['payment_method'] = $GLOBALS[$payment]->title;
if ( isset($GLOBALS[$payment]->order_status) && is_numeric($GLOBALS[$payment]->order_status) && ($GLOBALS[$payment]->order_status > 0) ) {
- $this->info['order_status'] = $GLOBALS[$payment]->order_status;
+ $this->info['order_status'] = $GLOBALS[$payment]->order_status;
}
}
+
+
+ $this->mod = array(
+ 'class_payment'=> $payment,
+ 'class_shipping'=> $shipping_mod
+ );
+
$this->customer = array('id' => (int)$customer_id,
'firstname' => $customer_address['customers_firstname'],
'lastname' => $customer_address['customers_lastname'],
Modified: trunk/catalog/includes/classes/checkout_process.php
===================================================================
--- trunk/catalog/includes/classes/checkout_process.php 2012-03-04 10:31:05 UTC (rev 4058)
+++ trunk/catalog/includes/classes/checkout_process.php 2012-03-04 13:59:06 UTC (rev 4059)
@@ -1,10 +1,10 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- \licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
- \portion code Copyright (c) 2002 osCommerce
- \package osCSS-2 <www http://www.oscss.org>
- \version 2.1.0
- \date 15/12/10, 11:33
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 21:44
\author oscim <mail aur...@os...> <www http://www.oscim.fr>
\encode UTF-8
\class checkout_process
@@ -213,16 +213,20 @@
* @param $array array
*/
public function preventDuplicate($array){
- if (tep_session_is_registered('pre_order_id') && !isset($array['pre_order_id']) && !empty($array['pre_order_id']) ) {
+// var_dump(__FUNCTION__, tep_session_is_registered('pre_order_id') && ( !isset($array['pre_order_id']) || !empty($array['pre_order_id']) ) );
+ if (tep_session_is_registered('pre_order_id') && ( !isset($array['pre_order_id']) || !empty($array['pre_order_id']) ) ) {
// var_dump(1);
+ //confirm orders
return $this->process_confirm($_SESSION['pre_order_id']);
}
elseif(self::test_pre_order_id($array['pre_order_id'])){
// var_dump(2);
+ // confirm orders
return $this->process_confirm($array['pre_order_id']);
}
else {
// var_dump(3);
+ // create orders
return $this->process_exe($array['order_totals'],$array['order']);
}
}
@@ -433,7 +437,7 @@
$DB=Database::getInstance();
/// table order
- $order_query = $DB->query("select orders_prefix, customers_id, customers_name, customers_company, customers_street_address, customers_suburb, customers_city, customers_postcode, customers_state, customers_country, customers_telephone, customers_email_address, customers_address_format_id, delivery_name, delivery_company, delivery_street_address, delivery_suburb, delivery_city, delivery_postcode, delivery_state, delivery_country, delivery_address_format_id, billing_name, billing_company, billing_street_address, billing_suburb, billing_city, billing_postcode, billing_state, billing_country, billing_address_format_id, payment_method, cc_type, cc_owner, cc_number, cc_expires, currency, currency_value, date_purchased, orders_status, last_modified, ip_address from " . TABLE_HOLDING_ORDERS . " where orders_id = '" . (int)$pre_order_id . "'");
+ $order_query = $DB->query("select orders_prefix, customers_id, customers_name, customers_company, customers_street_address, customers_suburb, customers_city, customers_postcode, customers_state, customers_country, customers_telephone, customers_email_address, customers_address_format_id, delivery_name, delivery_company, delivery_street_address, delivery_suburb, delivery_city, delivery_postcode, delivery_state, delivery_country, delivery_address_format_id, billing_name, billing_company, billing_street_address, billing_suburb, billing_city, billing_postcode, billing_state, billing_country, billing_address_format_id, payment_method, cc_type, cc_owner, cc_number, cc_expires, currency, currency_value, date_purchased, orders_status, last_modified, ip_address, class_payment, class_shipping from " . TABLE_HOLDING_ORDERS . " where orders_id = '" . (int)$pre_order_id . "'");
$order = $order_query->fetchAssoc();
$sql_data_array = array('holding_origin_id'=>(int)$pre_order_id,
@@ -478,11 +482,15 @@
'billing_postcode' => tep_db_input($order['billing_postcode']),
'billing_state' => tep_db_input($order['billing_state']),
'billing_country' => tep_db_input($order['billing_country']),
- 'billing_address_format_id' => (int)$order['billing_address_format_id']);
+ 'billing_address_format_id' => (int)$order['billing_address_format_id'],
+ 'class_payment' => tep_db_input($order['class_payment']),
+ 'class_shipping' => tep_db_input($order['class_shipping']),
+ );
+
$query=tep_db_perform(TABLE_ORDERS, $sql_data_array);
- $this->the_order_id=$order_id=$query->__get('insertId');
+ self::$Id= $this->the_order_id=$order_id=$query->__get('insertId');
/// table orders_total
$res=$DB->query("Select title, text, value, class, sort_order from ".TABLE_HOLDING_ORDERS_TOTAL." Where orders_id='".(int)$pre_order_id."' ");
@@ -544,13 +552,17 @@
tep_db_query("delete from " . TABLE_CUSTOMERS_BASKET_ATTRIBUTES . " where customers_id = '" . (int)$order['customers_id'] . "'");
}
+
/**
- Before process module ACA
+ Before process module ACA
*/
- $this->in_process_finish();
+ $r = $this->in_process_finish();
+
+
$this->email_confirm_order($order_id);
+
//! RETURN
return array ( 'the_order_id'=>$order_id,
'customer_notification'=>(_cst_bool('SEND_EMAILS')) ? '1' : '0',
@@ -609,7 +621,7 @@
tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], EMAIL_TEXT_SUBJECT, $message_final, STORE_OWNER, EMAIL_FROM);
/// admin notif
- notification::notifInMess('checkout_process','copy '.EMAIL_TEXT_SUBJECT,$message_final,'customers_id='.$order->info['customers_id']);
+ notification::notifInMess('checkout_process','copy '.EMAIL_TEXT_SUBJECT,$message_final,'customers_id='.$order->customer['id']);
}
@@ -626,45 +638,48 @@
$format_prefix='';
$sql_data_array = array('customers_id' => $customer_id,
'orders_prefix' => $format_prefix,
- 'customers_name' => $order->customer['firstname'] . ' ' . $order->customer['lastname'],
- 'customers_company' => (string)$order->customer['company'],
- 'customers_street_address' => (string)$order->customer['street_address'],
- 'customers_suburb' => $order->customer['suburb'],
- 'customers_city' => (string)$order->customer['city'],
- 'customers_postcode' => $order->customer['postcode'],
- 'customers_state' => (string)$order->customer['state'],
- 'customers_country' => $order->customer['country']['title'],
- 'customers_telephone' => $order->customer['telephone'],
- 'customers_email_address' => $order->customer['email_address'],
- 'customers_address_format_id' => $order->customer['format_id'],
- 'delivery_name' => $order->delivery['firstname'] . ' ' . $order->delivery['lastname'],
- 'delivery_company' => $order->delivery['company'],
- 'delivery_street_address' => (string)$order->delivery['street_address'],
- 'delivery_suburb' => $order->delivery['suburb'],
- 'delivery_city' => (string)$order->delivery['city'],
- 'delivery_postcode' => $order->delivery['postcode'],
- 'delivery_state' => $order->delivery['state'],
- 'delivery_country' => $order->delivery['country']['title'],
- 'delivery_address_format_id' => $order->delivery['format_id'],
- 'billing_name' => $order->billing['firstname'] . ' ' . $order->billing['lastname'],
- 'billing_company' => $order->billing['company'],
- 'billing_street_address' => (string)$order->billing['street_address'],
- 'billing_suburb' => $order->billing['suburb'],
- 'billing_city' => (string)$order->billing['city'],
- 'billing_postcode' => $order->billing['postcode'],
- 'billing_state' => $order->billing['state'],
- 'billing_country' => $order->billing['country']['title'],
- 'billing_address_format_id' => $order->billing['format_id'],
- 'payment_method' => $order->info['payment_method'],
- 'cc_type' => $order->info['cc_type'],
- 'cc_owner' => $order->info['cc_owner'],
- 'cc_number' => substr_replace($order->info['cc_number'],"XXXXXXXX",4,8),
- 'cc_expires' => $order->info['cc_expires'],
- 'date_purchased' => $date_purchased,
- 'orders_status' => (int)$order->info['order_status'],
- 'currency' => (string)$order->info['currency'],
- 'currency_value' => $order->info['currency_value'],
- 'ip_address' => tep_get_ip_address(),
+ 'customers_name' => $order->customer['firstname'] . ' ' . $order->customer['lastname'],
+ 'customers_company' => (string)$order->customer['company'],
+ 'customers_street_address' => (string)$order->customer['street_address'],
+ 'customers_suburb' => $order->customer['suburb'],
+ 'customers_city' => (string)$order->customer['city'],
+ 'customers_postcode' => $order->customer['postcode'],
+ 'customers_state' => (string)$order->customer['state'],
+ 'customers_country' => $order->customer['country']['title'],
+ 'customers_telephone' => $order->customer['telephone'],
+ 'customers_email_address' => $order->customer['email_address'],
+ 'customers_address_format_id' => $order->customer['format_id'],
+ 'delivery_name' => $order->delivery['firstname'] . ' ' . $order->delivery['lastname'],
+ 'delivery_company' => $order->delivery['company'],
+ 'delivery_street_address' => (string)$order->delivery['street_address'],
+ 'delivery_suburb' => $order->delivery['suburb'],
+ 'delivery_city' => (string)$order->delivery['city'],
+ 'delivery_postcode' => $order->delivery['postcode'],
+ 'delivery_state' => $order->delivery['state'],
+ 'delivery_country' => $order->delivery['country']['title'],
+ 'delivery_address_format_id' => $order->delivery['format_id'],
+ 'billing_name' => $order->billing['firstname'] . ' ' . $order->billing['lastname'],
+ 'billing_company' => $order->billing['company'],
+ 'billing_street_address' => (string)$order->billing['street_address'],
+ 'billing_suburb' => $order->billing['suburb'],
+ 'billing_city' => (string)$order->billing['city'],
+ 'billing_postcode' => $order->billing['postcode'],
+ 'billing_state' => $order->billing['state'],
+ 'billing_country' => $order->billing['country']['title'],
+ 'billing_address_format_id' => $order->billing['format_id'],
+
+ 'class_payment' => $order->mod['class_payment'],
+ 'class_shipping' => $order->mod['class_shipping'],
+
+ 'cc_type' => $order->info['cc_type'],
+ 'cc_owner' => $order->info['cc_owner'],
+ 'cc_number' => substr_replace($order->info['cc_number'],"XXXXXXXX",4,8),
+ 'cc_expires' => $order->info['cc_expires'],
+ 'date_purchased' => $date_purchased,
+ 'orders_status' => (int)$order->info['order_status'],
+ 'currency' => (string)$order->info['currency'],
+ 'currency_value' => $order->info['currency_value'],
+ 'ip_address' => tep_get_ip_address(),
'total_weight'=>$order->info['total_weight']);
if(empty($update)) tep_db_perform(self::$tables['ORDERS'], $sql_data_array);
Modified: trunk/catalog/includes/modules/checkout/PrCgu.php
===================================================================
--- trunk/catalog/includes/modules/checkout/PrCgu.php 2012-03-04 10:31:05 UTC (rev 4058)
+++ trunk/catalog/includes/modules/checkout/PrCgu.php 2012-03-04 13:59:06 UTC (rev 4059)
@@ -16,7 +16,7 @@
/**
@brief constructor
*/
- function __construct($page){
+ function __construct(){
global $page;
$language = $page->the_var('language');
@@ -29,16 +29,18 @@
/**
@var sort
*/
- $this->sort_order = (defined('MODULE_ACA_CGU_SORT_ORDER')) ? MODULE_ACA_CGU_SORT_ORDER : 3;
+ $this->sort_order = (defined('MODULE_ACA_CGU_SORT_ORDER')) ? MODULE_ACA_CGU_SORT_ORDER : 0;
/**
- @var Active mode module
+ @var Active mode module default: true
*/
$this->enabled = true;
/**
- @var Current step ok
+ @var Current step ok default: false
*/
$this->step = false;
+// tep_session_unregister('conditions');
+
}
@@ -50,31 +52,54 @@
/**
@brief Check module for passed etape control
+ If control is ok, return false
+ If this step display, return true
@note this methode use cart customers for control cgu
*/
public function ChkBeforeProcess($array=array()){
+
// put step ok
- if (tep_session_is_registered('conditions'))
- $this->step = true;
+ if (tep_session_is_registered('conditions')){
+// if($_SESSION['conditions'] == 'true'){
+// $this->step = true;
+ return false;
+// }
+// else{
+// $this->step = true;
+// tep_session_unregister('conditions');
+// }
+ }
+// else
+
return true;
}
/**
@brief Check module for passed etape control
+
@note this methode use cart customers for control cgu
*/
public function BeforeProcess($array=array()){
-// var_dump('BeforeProcess');
-// exit;
+global $page;
if(isset($_POST['conditions'])){
- tep_session_register('conditions');
- $conditions = tep_db_prepare_input($_POST['conditions']);
+// tep_session_register('conditions');
+// $conditions = 'true';
+ $_SESSION['conditions'] = 'true';
- tep_redirect(tep_href_link('checkout.php'/*FILENAME_CHECKOUT_SHIPPING*/, '', 'SSL'));
+ $page->tep_session_close();
+ //! close session
+
+// //! write cache lang (.txt)
+// $page->cache_lang(false);
+//
+// page::StopCacheVar();
+
+ tep_redirect(tep_href_link('checkout.php'/*FILENAME_CHECKOUT_SHIPPING*/,'' /*'step=shipping'*/, 'SSL'));
}
- return true;
+
+ return false;
}
/**
@@ -83,14 +108,39 @@
*/
public function display_view(){
global $cart;
+ $return = array();
+
$v['title']=__("PrCgu tab");
- $v['content']=tep_output_string_protected(tep_get_cms_content('informationBox_conditions',true, '<article><h5 class="CguView">%s</h5><div class="CguView">%s</textarea></article>' ),false,true);
- return new objectInfo($v);
+ $v['content']=tep_output_string_protected(tep_get_cms_content('informationBox_conditions',true, '<article><h5 class="CguView">%s</h5><div class="CguView">%s</textarea></article>' ));
+
+ $return[] = new objectInfo($v);
+
+
+ foreach($cart->get_products() as $row){
+ $pid = tep_get_prid($row['id']);
+ $arr = tep_get_prid_array($row['id']);
+
+ $row['products_id']=$pid;
+ $row['attrib']=$arr;
+ $p = product::get_option_data($row);
+
+ if(isset($p['cgu_id']) && $p['cgu_id'] > 0) {
+ $v['title']=''; //__("PrCgu tab");
+ $v['content']=tep_output_string_protected(tep_get_cms_content($p['cgu_id'],true, '<article><h5 class="CguView">%s</h5><div class="CguView">%s</textarea></article>' ));
+
+ $return[] = new objectInfo($v);
+ }
+
+ }
+
+
+ return $return;
}
/**
- Chargement des db
+ @brief Chargement dans le fin du process complet page checkout_process
+ Delete specifique item in session for process
*/
public function load_db_values($cid){
}
@@ -99,7 +149,7 @@
Chargement dans le fin du process
*/
public function after_process(){
- tep_session_unregister('producteur');
+ tep_session_unregister('conditions');
}
/** implements InterfaceModule depend */
Modified: trunk/catalog/includes/modules/checkout/PrConfirmation.php
===================================================================
--- trunk/catalog/includes/modules/checkout/PrConfirmation.php 2012-03-04 10:31:05 UTC (rev 4058)
+++ trunk/catalog/includes/modules/checkout/PrConfirmation.php 2012-03-04 13:59:06 UTC (rev 4059)
@@ -16,7 +16,7 @@
/**
@brief constructor
*/
- function __construct($page){
+ function __construct(){
global $page;
$language = $page->the_var('language');
@@ -39,11 +39,23 @@
*/
$this->step = false;
+// tep_session_unregister('payment');
+// tep_session_unregister('billto');
+// tep_session_unregister('comments');
+//
+// tep_session_unregister('sendto');
+// tep_session_unregister('shipping');
+//
+// tep_session_unregister('pre_order_id');
+// tep_session_unregister('coupon_sav');
+//
+// tep_session_unregister('conditions');
}
public function ResetProcess($array=array()){
tep_session_unregister('pre_order_id');
+ tep_session_unregister('coupon_sav');
}
@@ -69,19 +81,18 @@
//! mise a jour status payment
$tt=$payment_modules->update_status();
-// var_dump($payment_modules->modules);
if ( is_array($payment_modules->modules)
&& (sizeof($payment_modules->modules) == 1)
&& isset($payment_modules->modules[$payment] )
) {
- $current = $payment_modules->modules[$payment];
+ $current = $payment_modules->modules[$payment];
- if(is_object($current) )
- return true;
+ if(is_object($current) )
+ return true;
- return false;
+ return false;
}
return true;
@@ -93,10 +104,8 @@
*/
public function BeforeProcess($array=array()){
global $cart, $DB, $order, $coupon_sav, $shipping, $sendto , $payment, $page, $order_total_modules, $order_totals, $payment_modules;
-// var_dump($_SESSION);
-// exit;
-// var_dump('BeforeProcess');
+
// if ( (
// is_array($payment_modules->modules)
// && (sizeof($payment_modules->modules) > 1)
@@ -105,8 +114,6 @@
// || (is_object($payment) && ($payment->enabled == false))
// ) {
// // tep_redirect(tep_href_link('checkout.php'/*FILENAME_CHECKOUT_PAYMENT*/, 'step=Payment&error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL'));
-// // var_dump('rate');
-// // exit;
// // return false;
// }
@@ -114,7 +121,7 @@
if (is_array($payment_modules->modules)) {
- $payment_modules->pre_confirmation_check();
+ $payment_modules->pre_confirmation_check();
}
//! chargement payment
@@ -122,40 +129,40 @@
//kgt - discount coupons
if( isset( $coupon_sav ) && is_object( $order->coupon ) ) {
- $order->coupon->verify_code();
- if( $order->coupon->is_errors() ) {
- if( tep_session_is_registered('coupon_sav') ) tep_session_unregister('coupon_sav');
- //!remove the coupon from the session
- tep_redirect( tep_href_link( FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode( implode( ' ', $order->coupon->get_messages() ) ), 'SSL' ) );
- } else {
+ $order->coupon->verify_code();
+ if( $order->coupon->is_errors() ) {
+ if( tep_session_is_registered('coupon_sav') ) tep_session_unregister('coupon_sav');
+ //!remove the coupon from the session
+ tep_redirect( tep_href_link( FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode( implode( ' ', $order->coupon->get_messages() ) ), 'SSL' ) );
+ }
+ else {
- //!if the coupon field is empty, unregister the coupon from the session
- if( tep_session_is_registered('coupon_sav') ) {
+ //!if the coupon field is empty, unregister the coupon from the session
+ if( tep_session_is_registered('coupon_sav') ) {
- //!we had a coupon entered before, so we need to unregister it
- // tep_session_unregister('coupon');
- //!now check to see if we need to recalculate shipping:
- require_once( DIR_WS_CLASSES.'discount_coupon.php' );
- //! redirect to the shipping page to reselect the shipping method
- if( discount_coupon::is_recalc_shipping() ) tep_redirect( tep_href_link( FILENAME_CHECKOUT_SHIPPING, 'error_message=' . urlencode( ENTRY_DISCOUNT_COUPON_SHIPPING_CALC_ERROR ), 'SSL' ) );
- }
- else tep_session_register('coupon_sav');
- }
+ //!we had a coupon entered before, so we need to unregister it
+ // tep_session_unregister('coupon');
+ //!now check to see if we need to recalculate shipping:
+ require_once( DIR_WS_CLASSES.'discount_coupon.php' );
+
+ //! redirect to the shipping page to reselect the shipping method
+ if( discount_coupon::is_recalc_shipping() )
+ tep_redirect( tep_href_link( FILENAME_CHECKOUT_SHIPPING, 'error_message=' . urlencode( ENTRY_DISCOUNT_COUPON_SHIPPING_CALC_ERROR ), 'SSL' ) );
+ }
+ else
+ tep_session_register('coupon_sav');
+ }
}
-// var_dump($page->return_object('order_total'));
-// exit;
//! Search or load order total modules
if( ($order_total_modules=$page->return_object('order_total')) ==false){
-// var_dump('order_total');
-// if(!class_exists('order_total')) require(DIR_WS_CLASSES . 'order_total.php');
- $order_total_modules = new order_total();
- $page->add_object('order_total_modules',$order_total_modules);
+ $order_total_modules = new order_total();
+ $page->add_object('order_total_modules',$order_total_modules);
}
$page->breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'));
- $page->post_init();
+// $page->post_init(false);
$order_totals = $order_total_modules->process();
@@ -168,11 +175,12 @@
$aca_modules = new checkout_process('', 'holding');
$res=$aca_modules->process_exe($order_totals);
- // print_r($res);
+
// Array ( [the_order_id] => 37 [customer_notification] => 1 [total_weight] => 0 [total_tax] => 0 [total_cost] => 187.1 )
+// $pre_order_id=$res['the_order_id'];
$pre_order_id=$res['the_order_id'];
- tep_session_register('pre_order_id');
-
+// tep_session_register('pre_order_id');
+ $_SESSION['pre_order_id'] = $pre_order_id;
return true;
}
@@ -181,10 +189,10 @@
@note this methode use cart customers for draw form cgu
*/
public function display_view(){
- global $cart;
- $v['title']=__("PrCgu tab");
- $v['content']=tep_output_string_protected(tep_get_cms_content('informationBox_conditions',true, '<article><h5 class="CguView">%s</h5><div class="CguView">%s</textarea></article>' ),false,true);
- return new objectInfo($v);
+// global $cart;
+// $v['title']=__("PrCgu tab");
+// $v['content']=tep_output_string_protected(tep_get_cms_content('informationBox_conditions',true, '<article><h5 class="CguView">%s</h5><div class="CguView">%s</textarea></article>' ),false,true);
+// return new objectInfo($v);
}
@@ -195,10 +203,12 @@
}
/**
- Chargement dans le fin du process
+ @brief Chargement dans le fin du process complet page checkout_process
+ Delete specifique item in session for process
*/
public function after_process(){
- tep_session_unregister('producteur');
+ tep_session_unregister('pre_order_id');
+ tep_session_unregister('coupon_sav');
}
/** implements InterfaceModule depend */
Modified: trunk/catalog/includes/modules/checkout/PrPayment.php
===================================================================
--- trunk/catalog/includes/modules/checkout/PrPayment.php 2012-03-04 10:31:05 UTC (rev 4058)
+++ trunk/catalog/includes/modules/checkout/PrPayment.php 2012-03-04 13:59:06 UTC (rev 4059)
@@ -44,7 +44,7 @@
public function ResetProcess($array=array()){
tep_session_unregister('payment');
tep_session_unregister('billto');
- tep_session_register('comments');
+ tep_session_unregister('comments');
}
/**
@@ -59,8 +59,8 @@
// tep_session_unregister('payment');
// unset($payment);
-// var_dump($cartID);
+
//! if there is nothing in the customers cart, redirect them to the shopping cart page
if (!tep_session_is_registered('cart') || $cart->count_contents() < 1)
tep_redirect(tep_href_link(FILENAME_SHOPPING_CART));
@@ -73,7 +73,7 @@
if (isset($cart->cartID) && tep_session_is_registered('cartID')) {
if ($cart->cartID != $cartID)
return false;
-// var_dump('cartID');
+
// // tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'));
}
elseif(isset($cart->cartID) && !tep_session_is_registered('cartID')) {
@@ -84,7 +84,7 @@
// if no shipping method has been selected, redirect the customer to the shipping method selection page
if (!tep_session_is_registered('shipping') && (tep_count_shipping_modules() > 0)){
-// var_dump('shipping');
+
return false;
}
// tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'));
@@ -101,7 +101,6 @@
tep_session_register('billto');
$billto = $customer_default_address_id;
-// var_dump($billto);
}
else {
@@ -109,7 +108,7 @@
$check_address_query = tep_db_query($sql="select count(*) as total from " . TABLE_ADDRESS_BOOK . " where customers_id = '" . (int)$customer_id . "' and address_book_id = '" . (int)$billto . "'");
$check_address = tep_db_fetch_array($check_address_query);
-// var_dump($sql);
+
if ($check_address['total'] != '1') {
$billto = $customer_default_address_id;
if (tep_session_is_registered('payment'))
@@ -122,14 +121,14 @@
if (!tep_session_is_registered('comments'))
tep_session_register('comments');
-// var_dump(tep_session_is_registered('payment') , tep_session_is_registered('billto'));
+
if (tep_session_is_registered('payment') && tep_session_is_registered('billto')){
-// var_dump($_SESSION);
+
$this->step = true;
}
-// var_dump($payment, $this->step);
+
return true;
}
@@ -138,7 +137,7 @@
global $cart, $DB, $order, $sendto, $shipping, $sendto , $module, $page, $payment;
global $total_weight,$total_count, $payment_modules, $selection, $radio_buttons;
-
+ $error = true;
$total_weight = $cart->show_weight();
$total_count = $cart->count_contents();
@@ -153,7 +152,11 @@
$payment_modules = payment::getInstance($payment);
tep_session_register('payment');
+
}
+ else{
+ $error=false;
+ }
if (isset($_POST['comments']) && tep_not_null($_POST['comments'])){
@@ -167,15 +170,18 @@
//! mise a jour status payment
$tt=$payment_modules->update_status();
-// var_dump($payment_modules);
+// if(!$error)
+// tep_redirect(tep_href_link('checkout.php', 'step=confirmation'));
+
+
$page->add_var_page('payment_modules',$payment_modules);
- $page->breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'));
- $page->post_init();
+// $page->breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'));
+ $page->post_init(false);
$page->javascript->add_framework("ext/jquery/jquery.min.js");
@@ -183,8 +189,6 @@
$selection = $payment_modules->selection();
$radio_buttons = 0;
-// if (isset($_POST['payment']))
-// var_dump($_SESSION);
}
@@ -212,10 +216,13 @@
}
/**
- Chargement dans le fin du process
+ @brief Chargement dans le fin du process complet page checkout_process
+ Delete specifique item in session for process
*/
public function after_process(){
- tep_session_unregister('producteur');
+ tep_session_unregister('payment');
+ tep_session_unregister('billto');
+ tep_session_unregister('comments');
}
/** implements InterfaceModule depend */
Modified: trunk/catalog/includes/modules/checkout/PrShipping.php
===================================================================
--- trunk/catalog/includes/modules/checkout/PrShipping.php 2012-03-04 10:31:05 UTC (rev 4058)
+++ trunk/catalog/includes/modules/checkout/PrShipping.php 2012-03-04 13:59:06 UTC (rev 4059)
@@ -44,6 +44,7 @@
public function ResetProcess($array=array()){
tep_session_unregister('sendto');
tep_session_unregister('shipping');
+ tep_session_unregister('shipping_mod');
}
/**
@@ -64,8 +65,6 @@
//! if no shipping destination address was selected, use the customers own address as default
if (!tep_session_is_registered('sendto')) {
-
-
$sendto = $_SESSION['customer_default_address_id']; //$customer_default_address_id;
tep_session_register('sendto');
}
@@ -77,12 +76,13 @@
$check_address = $check_address_query->fetchAssoc();
if ($check_address['total'] != '1') {
- if (tep_session_is_registered('shipping'))
- tep_session_unregister('shipping');
-
+ if (tep_session_is_registered('shipping'))
+ tep_session_unregister('shipping');
+ if (tep_session_is_registered('shipping_mod'))
+ tep_session_unregister('shipping_mod');
}
elseif (tep_session_is_registered('shipping'))
- $this->step = true;
+ $this->step = true;
}
//! register a random ID in the session to check throughout the checkout procedure against alterations in the shopping cart contents
@@ -94,7 +94,10 @@
//! if the order contains only virtual products, forward the customer to the billing page as a shipping address is not needed
if ($order->content_type == 'virtual') {
- if (!tep_session_is_registered('shipping')) tep_session_register('shipping');
+ if (!tep_session_is_registered('shipping'))
+ tep_session_register('shipping');
+ if (tep_session_is_registered('shipping_mod'))
+ tep_session_unregister('shipping_mod');
global $shipping, $sendto;
$shipping = false;
$sendto = false;
@@ -125,14 +128,14 @@
if (_cst_bool('MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING')) {
$pass = false;
switch (MODULE_ORDER_TOTAL_SHIPPING_DESTINATION) {
- case 'national': if ($order->delivery['country_id'] == STORE_COUNTRY) $pass = true; break;
- case 'international': if ($order->delivery['country_id'] != STORE_COUNTRY) $pass = true; break;
- case 'both': $pass = true; break;
+ case 'national': if ($order->delivery['country_id'] == STORE_COUNTRY) $pass = true; break;
+ case 'international': if ($order->delivery['country_id'] != STORE_COUNTRY) $pass = true; break;
+ case 'both': $pass = true; break;
}
$free_shipping = false;
if ( ($pass == true) && ($order->info['total'] >= MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING_OVER) ) {
- $free_shipping = true;
- include(DIR_WS_LANGUAGES . $language . '/modules/order_total/ot_shipping.php');
+ $free_shipping = true;
+ include(DIR_WS_LANGUAGES . $language . '/modules/order_total/ot_shipping.php');
}
}
else $free_shipping = false;
@@ -141,64 +144,73 @@
if ( isset($_POST['action']) && ($_POST['action'] == 'process') ) {
if (!tep_session_is_registered('comments'))
- tep_session_register('comments');
+ tep_session_register('comments');
+
if (tep_not_null($_POST['comments']))
- $comments = tep_db_prepare_input($_POST['comments']);
+ $comments = tep_db_prepare_input($_POST['comments']);
+
if (!tep_session_is_registered('shipping'))
- tep_session_register('shipping');
+ tep_session_register('shipping');
+ if (!tep_session_is_registered('shipping_mod'))
+ tep_session_register('shipping_mod');
if ( (tep_count_shipping_modules() > 0) || ($free_shipping) ) {
- if ( (isset($_POST['shipping'])) && (strpos($_POST['shipping'], '_')) ) {
+ if ( (isset($_POST['shipping'])) && (strpos($_POST['shipping'], '_')) ) {
- $shipping = $_POST['shipping'];
+ $shipping = $_POST['shipping'];
- list($module, $method) = explode('_', $shipping);
+ list($module, $method) = explode('_', $shipping);
- if ( (isset($module)&& is_object( $shipping_modules->modules[$module] )) || ($shipping == 'free_free') ) {
+ if ( (isset($module)&& is_object( $shipping_modules->modules[$module] )) || ($shipping == 'free_free') ) {
- if ($shipping == 'free_free') {
- $quote[0]['methods'][0]['title'] = FREE_SHIPPING_TITLE;
- $quote[0]['methods'][0]['cost'] = '0';
- }
- else {
+ if ($shipping == 'free_free') {
+ $quote[0]['methods'][0]['title'] = FREE_SHIPPING_TITLE;
+ $quote[0]['methods'][0]['cost'] = '0';
+ }
+ else {
- $quote = $shipping_modules->quote($method, $module);
- }
+ $quote = $shipping_modules->quote($method, $module);
+ }
- if (isset($quote['error']))
- tep_session_unregister('shipping');
- else {
- if ( (isset($quote[0]['methods'][0]['title'])) && (isset($quote[0]['methods'][0]['cost'])) ) {
- $shipping = array('id' => $shipping,
- 'title' => (($free_shipping == true) ? $quote[0]['methods'][0]['title'] : $quote[0]['module'] . ' (' . $quote[0]['methods'][0]['title'] . ')'),
- 'cost_ht' => $quote[0]['methods'][0]['cost_ht'],
- 'cost' => $quote[0]['methods'][0]['cost']);
+ if (isset($quote['error']))
+ tep_session_unregister('shipping');
+ else {
- tep_session_register('shipping');
+ $shipping_mod = $module;
+// tep_session_register('shipping_mod');
+ $_SESSION['shipping_mod'] = $shipping_mod;
- $page->tep_session_close();
- tep_redirect(tep_href_link('checkout.php', 'success=ok1', 'SSL'));
-// tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'));
- }
- }
- tep_redirect(tep_href_link('checkout.php', 'success=ok2', 'SSL'));
- }
- else{
- tep_session_unregister('shipping');
- unset($shipping);
- }
- }
+ if ( (isset($quote[0]['methods'][0]['title'])) && (isset($quote[0]['methods'][0]['cost'])) ) {
+ $shipping = array('id' => $shipping,
+ 'title' => (($free_shipping == true) ? $quote[0]['methods'][0]['title'] : $quote[0]['module'] . ' (' . $quote[0]['methods'][0]['title'] . ')'),
+ 'cost_ht' => $quote[0]['methods'][0]['cost_ht'],
+ 'cost' => $quote[0]['methods'][0]['cost']);
+ tep_session_register('shipping');
+
+ $page->tep_session_close();
+ tep_redirect(tep_href_link('checkout.php', 'success=ok1', 'SSL'));
+ // tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'));
+ }
+ }
+ tep_redirect(tep_href_link('checkout.php', 'success=ok2', 'SSL'));
+ }
+ else{
+ tep_session_unregister('shipping');
+ unset($shipping);
+ }
+ }
+
}
else {
- tep_redirect(tep_href_link('checkout.php', 'success=ok3', 'SSL'));
+ tep_redirect(tep_href_link('checkout.php', 'success=ok3', 'SSL'));
// tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'));
}
}
@@ -210,7 +222,7 @@
// var_dump($quotes);
// if no shipping method has been selected, automatically select the cheapest method. if the modules status was changed when none were available, to save on implementing a javascript force-selection method, also automatically select the cheapest shipping method if more than one module is now enabled
- if ( !tep_session_is_registered('shipping') || ( tep_session_is_registered('shipping') && ($shipping == false) && (tep_count_shipping_modules() > 1) ) ){
+ if ( /*!tep_session_is_registered('shipping') ||*/ ( tep_session_is_registered('shipping') && ($shipping == false) && (tep_count_shipping_modules() > 1) ) ){
$shipping = $shipping_modules->cheapest();
tep_session_register('shipping');
}
@@ -248,10 +260,12 @@
}
/**
- Chargement dans le fin du process
+ @brief Chargement dans le fin du process complet page checkout_process
+ Delete specifique item in session for process
*/
public function after_process(){
- tep_session_unregister('producteur');
+ tep_session_unregister('sendto');
+ tep_session_unregister('shipping');
}
/** implements InterfaceModule depend */
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-04 10:31:14
|
Revision: 4058
http://oscss.svn.sourceforge.net/oscss/?rev=4058&view=rev
Author: oscim
Date: 2012-03-04 10:31:05 +0000 (Sun, 04 Mar 2012)
Log Message:
-----------
Amelioratioon du modele harry
correction coquille dans la gestion des documents
amelioration order suite
refonte de la gestion des tirroirs (block depliant) js + css et ajout repere visuel
nombreuses corrections
Modified Paths:
--------------
trunk/catalog/Documents/modeles/pdf/harry/harry.php
trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/delivery.php
trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php
trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/packingslip.php
trunk/catalog/admin/document.php
trunk/catalog/admin/includes/content/configuration.central.inc
trunk/catalog/admin/includes/functions/lib.orders.php
trunk/catalog/admin/includes/gabarit/configuration/moddownloads.listing.gab
trunk/catalog/admin/includes/gabarit/configuration/modmail.listing.gab
trunk/catalog/admin/includes/gabarit/configuration/modseourl.listing.gab
trunk/catalog/admin/includes/gabarit/configuration/modstock.listing.gab
trunk/catalog/admin/includes/gabarit/orders/display_view.edit.gab
trunk/catalog/admin/includes/header.php
trunk/catalog/admin/includes/javascript/modules/pages/orders.js.php
trunk/catalog/admin/includes/languages/fr_FR/modeles/pdf/harry/harry.txt
trunk/catalog/admin/includes/modules/pages/orders.php
trunk/catalog/admin/includes/template/oscss/data/icon_set.xml
trunk/catalog/admin/includes/template/oscss/stylesheet-1.css
trunk/catalog/common/classes/fpdf.php
trunk/catalog/common/classes/osCSS_pdf.php
trunk/catalog/document.php
Modified: trunk/catalog/Documents/modeles/pdf/harry/harry.php
===================================================================
--- trunk/catalog/Documents/modeles/pdf/harry/harry.php 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/Documents/modeles/pdf/harry/harry.php 2012-03-04 10:31:05 UTC (rev 4058)
@@ -7,62 +7,37 @@
@date 28/02/2012, 10:54
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
- @brief Generation des elements d'entete et footer pour les BL et facture
+ @class harry
+ @brief moteur de mise en forme pour les pdf.
*/
-class harry
- extends FPDF {
+class harry
+ extends PDF {
+
+
+ // page
+ public $page_width = 212; // absolute
+ public $page_marge=6;
+
+
+ public $block_marge=3;
+ public $block_padding=5;
+ public $block_interline =4;
+
+ public $line_height = 6;
+
// font
public $font = 'Arial';
// box gray
- // background gray
+ // background gray
public $bg_color_1 = 245;
- // background gray
- public $txt_color_1 = 0;
+ // background gray
+ public $txt_color_1 = 0;
-//Page header
- function RoundedRect($x, $y, $w, $h,$r, $style = '') {
- $k = $this->k;
- $hp = $this->h;
- if($style=='F')
- $op='f';
- elseif($style=='FD' or $style=='DF')
- $op='B';
- else
- $op='S';
- $MyArc = 4/3 * (sqrt(2) - 1);
- $this->_out(sprintf('%.2f %.2f m',($x+$r)*$k,($hp-$y)*$k ));
- $xc = $x+$w-$r ;
- $yc = $y+$r;
- $this->_out(sprintf('%.2f %.2f l', $xc*$k,($hp-$y)*$k ));
-
- $this->_Arc($xc + $r*$MyArc, $yc - $r, $xc + $r, $yc - $r*$MyArc, $xc + $r, $yc);
- $xc = $x+$w-$r ;
- $yc = $y+$h-$r;
- $this->_out(sprintf('%.2f %.2f l',($x+$w)*$k,($hp-$yc)*$k));
- $this->_Arc($xc + $r, $yc + $r*$MyArc, $xc + $r*$MyArc, $yc + $r, $xc, $yc + $r);
- $xc = $x+$r ;
- $yc = $y+$h-$r;
- $this->_out(sprintf('%.2f %.2f l',$xc*$k,($hp-($y+$h))*$k));
- $this->_Arc($xc - $r*$MyArc, $yc + $r, $xc - $r, $yc + $r*$MyArc, $xc - $r, $yc);
- $xc = $x+$r ;
- $yc = $y+$r;
- $this->_out(sprintf('%.2f %.2f l',($x)*$k,($hp-$yc)*$k ));
- $this->_Arc($xc - $r, $yc - $r*$MyArc, $xc - $r*$MyArc, $yc - $r, $xc, $yc - $r);
- $this->_out($op);
- }
-
- function _Arc($x1, $y1, $x2, $y2, $x3, $y3){
- $h = $this->h;
- $this->_out(sprintf('%.2f %.2f %.2f %.2f %.2f %.2f c ', $x1*$this->k, ($h-$y1)*$this->k,
- $x2*$this->k, ($h-$y2)*$this->k, $x3*$this->k, ($h-$y3)*$this->k));
- }
-
-
function Header(){
global $oID;
$date = strftime('%A, %d %B %Y');
@@ -74,73 +49,117 @@
}
function Footer() {
- $y=-8;
+ $y=-12;
$this->SetX(6);
//Arial italic 8
$this->SetFont($this->font,'',6);
$this->SetFillColor($this->bg_color_1);
$this->SetTextColor($this->txt_color_1);
$this->SetY($y);
- $this->MultiCell(198,3,tep_correct_entitie_put_pdf(STORE_LEGAL_INFO),0,'C',true);
+ $this->MultiCell($this->page_width ,3,tep_correct_entitie_put_pdf(STORE_LEGAL_INFO),0,'C',true);
}
- function WriteHTML($html) {
- //Parseur HTML
- $html=str_replace("\n",' ',$html);
- $a=preg_split('/<(.*)>/U',$html,-1,PREG_SPLIT_DELIM_CAPTURE);
- foreach($a as $i=>$e) {
- if($i%2==0) {
- if(isset($this->HREF)) $this->PutLink($this->HREF,$e);
- else $this->Write(5,$e);
- }
- else {
- //Balise
- if($e[0]=='/') $this->CloseTag(strtoupper(substr($e,1)));
- else {
- //Extraction des attributs
- $a2=explode(' ',$e);
- $tag=strtoupper(array_shift($a2));
- $attr=array();
- foreach($a2 as $v)
- if(preg_match('/([^=]*)=["\']?([^"\']*)/',$v,$a3)) $attr[strtoupper($a3[1])]=$a3[2];
- $this->OpenTag($tag,$attr);
- }
- }
- }
- }
+ /**
+ @brief dessine block nom document et numero/reference du document.
+ @note Ce block sera reproduit sur toutes les pages
+ @param $coor_Y int
+ @param $nametype string
+ @param $numref string
+ @return all height block
+ */
+ function DrawTypeAndRef($coor_Y , $nametype, $numref ){
- function OpenTag($tag,$attr){
- //Balise ouvrante
- if($tag=='B' || $tag=='I' || $tag=='U') $this->SetStyle($tag,true);
- if($tag=='A') $this->HREF=$attr['HREF'];
- if($tag=='BR') $this->Ln(5);
- }
- function CloseTag($tag){
- //Balise fermante
- if($tag=='B' || $tag=='I' || $tag=='U') $this->SetStyle($tag,false);
- if($tag=='A') $this->HREF='';
- }
+ $width = 70 ;
+ $all_hauteur_block = 0;
+ $coor_X = ( $this->page_width - $width - $this->page_marge );
- function SetStyle($tag,$enable){
- //Modifie le style et sélectionne la police correspondante
- $this->$tag+=($enable ? 1 : -1);
- $style='';
- foreach(array('B','I','U') as $s)
- if(isset($this->$s) && $this->$s >0) $style.=$s;
- $this->SetFont('',$style);
- }
+ $all_hauteur_block += $hauteur_block =7;
- function PutLink($URL,$txt){
- //Place un hyperlien
- $this->SetTextColor(0,0,255);
- $this->SetStyle('U',true);
- $this->Write(5,$txt,$URL);
- $this->SetStyle('U',false);
- $this->SetTextColor(0);
- }
+ $this->SetFont($this->font,'BI',14);
+ $this->SetTextColor($this->txt_color_1);
+ $this->SetXY($coor_X,$coor_Y);
+ //Draw Order Number Text
+ $this->Cell($width,$hauteur_block, $nametype , 0, 0,"R");
+
+
+ $coor_Y=($coor_Y+$hauteur_block);
+ $all_hauteur_block += $hauteur_block=10;
+
+
+ //Draw Box for Order Number, Date & Payment method
+ $this->SetDrawColor(0);
+ $this->SetLineWidth(0.2);
+ $this->SetFillColor($this->bg_color_1);
+ $this->RoundedRect( $coor_X , $coor_Y, $width , $hauteur_block, 2, 'DF');
+
+
+ $this->SetFont($this->font,'BI',14);
+ $this->SetTextColor($this->txt_color_1);
+
+ $this->SetXY( ($coor_X + $this->block_padding ),$coor_Y);
+ //Draw Order Number Text
+ $this->Cell( ( $width - ( $this->block_padding * 2 ) ),$hauteur_block, $numref, 0, 0,"C");
+
+ // put marge after box
+// $all_hauteur_block +=$this->block_marge;
+
+ return $all_hauteur_block;
+ }
+
+
+ /**
+ @brief draw block adresse and layers
+ @param $coor_Y int
+ @param $addr string
+ @param $label string
+ @param $pos string E: emeteur, D: destinataire
+ @return int hauteur block
+ */
+ function DrawAddresse($coor_Y, $addr, $label ='', $pos = 'E'){
+
+ $midle_page = ( $this->page_width / 2) ; // 2 block d'addresse
+ $width_cell = (
+ (( $midle_page - $this->page_marge ) // marge page
+ - $this->block_marge ) // pour espace entre les block d'adresse
+ );
+ $hauteur_block=27; // hauteur block
+
+ if($pos == 'E') { // left box
+ $coor_X = $this->page_marge;
+ }
+ elseif($pos == 'D') { // right box
+ $coor_X = ( $midle_page + $this->block_marge );
+ }
+
+
+ if(!empty($label)){
+ $this->SetFont($pdf->font,'I',7);
+ $this->Text( ($coor_X + 2),($coor_Y-1), $label );
+ }
+
+ //Draw Box for Address
+ $this->SetDrawColor(0);
+ $this->SetLineWidth(0.2);
+
+ if($pos == 'E')
+ $this->SetFillColor($this->bg_color_1);
+ elseif($pos == 'D')
+ $this->SetFillColor(255);
+
+ $this->RoundedRect($coor_X , $coor_Y, $width_cell , $hauteur_block , 2, 'DF');
+
+ //Draw the address text
+ $this->SetFont($this->font,'B',10);
+ $this->SetTextColor($this->txt_color_1);
+
+ $this->SetXY( ( $coor_X + $this->block_padding ) , ($coor_Y + $this->block_padding) );
+ $this->MultiCell( ($width_cell - ($this->block_padding * 2) ), $this->block_interline , $addr ,0,'L');
+
+ return $hauteur_block;
+ }
}
?>
\ No newline at end of file
Modified: trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/delivery.php
===================================================================
--- trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/delivery.php 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/delivery.php 2012-03-04 10:31:05 UTC (rev 4058)
@@ -7,6 +7,8 @@
@date 01/03/2012, 10:55
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
+ @brief A4 page pdf
+ @subpackage modele harry
*/
@@ -18,214 +20,219 @@
$le_Y=0;
-$marge_block=3;
-$padding_block=5;
+$block_marge=3;
+$block_padding=5;
// Add the first page
$pdf->AddPage();
- /**
- EOB -- header
- */
- $le_Y=($le_Y+$marge_block);
- $hauteur_block=11;
- $pdf->SetFont($pdf->font,'BI',15);
- $pdf->SetTextColor($pdf->txt_color_1);
- $pdf->SetXY(155,$le_Y);
- //Draw Order Number Text
- $pdf->Cell(48,$hauteur_block, __('dl print doc type delivery') , 0, 0,"R");
+/**
+ EOB -- header
+*/
+ $le_Y=$pdf->block_marge;
+ $hauteur_block = $pdf->DrawTypeAndRef($le_Y , tep_correct_entitie_put_pdf(__('dl print doc type delivery')) , 'BL-'.$obj_shipping->row_id );
- $le_Y=($le_Y+$hauteur_block);
- $hauteur_block=11;
- //Draw Box for Order Number, Date & Payment method
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor($pdf->bg_color_1);
- $pdf->RoundedRect(155, $le_Y, 48, $hauteur_block, 2, 'DF');
+ /// add other info
+ $pdf->SetFont($pdf->font,'I',9);
+ $width = 70 ;
+ $coor_X = ( $pdf->page_width - $width - $pdf->page_marge );
+ $le_Y=($le_Y+$hauteur_block);
- $pdf->SetFont($pdf->font,'BI',15);
- $pdf->SetTextColor($pdf->txt_color_1);
+ $pdf->SetXY($coor_X,$le_Y);
+ $pdf->Cell($width,$pdf->line_height, sprintf(__('dl print doc date order %s'), tep_date_short($order->info['date_purchased'])), 0, 0,"R");
- $pdf->SetXY(155,$le_Y);
- //Draw Order Number Text
- $temp = tep_correct_entitie_put_pdf(__('dl print packingslip ordernr'));
- $pdf->Cell(48,$hauteur_block, 'BL-'.$obj_shipping->row_id, 0, 0,"C");
+/**
+ EOF -- header
+*/
- $pdf->SetFont($pdf->font,'BI',10);
- $le_Y=($le_Y+$hauteur_block);
- $pdf->SetXY(155,$le_Y);
- $pdf->Cell(48,$hauteur_block, sprintf(__('dl print doc date order %s'), tep_date_short($order->info['date_purchased'])) , 0, 0,"R");
- /**
- EOF -- header
- */
/**
EOB -- subheader
*/
- $le_Y=($le_Y+$hauteur_block);
- $hauteur_block=11;
+ $le_Y=($le_Y+$pdf->line_height);
+ $hauteur_block= $pdf->line_height ;
//Draw Box for Order Number, Date & Payment method
$pdf->SetDrawColor(0);
$pdf->SetLineWidth(0.2);
$pdf->SetFillColor($pdf->bg_color_1);
- $pdf->RoundedRect(100, $le_Y, 103, ($hauteur_block*2), 2, 'DF');
+ $pdf->RoundedRect( ( $pdf->page_width / 2)+( $pdf->block_marge ) , $le_Y, (( $pdf->page_width /2) - ( $pdf->block_marge + $pdf->page_marge) ), ($hauteur_block*3), 2, 'DF');
- $hauteur_block=6;
- $pdf->SetFont($pdf->font,'BI',10);
-// $le_Y=($le_Y+$hauteur_block);
- $pdf->SetXY(101,($le_Y+1));
- $pdf->Cell(103,$hauteur_block, tep_correct_entitie_put_pdf( sprintf(__('dl print doc date expedition %s'), tep_date_short($obj_shipping->date_expedition)) ) , 0, 0,"L");
- $le_Y=($le_Y+$hauteur_block);
- $pdf->SetXY(101,($le_Y+1));
- $pdf->Cell(103,$hauteur_block, tep_correct_entitie_put_pdf( sprintf(__('dl print doc method expedition %s'),$obj_shipping->method) ) , 0, 0,"L");
- $le_Y=($le_Y+$hauteur_block);
- $pdf->SetXY(101,($le_Y+1));
- $pdf->Cell(103,$hauteur_block, tep_correct_entitie_put_pdf( sprintf(__('dl print doc tracking expedition %s'),$obj_shipping->tracking) ) , 0, 0,"L");
+ $pdf->SetTextColor(0);
+ $pdf->SetFont($pdf->font,'',8);
- /**
- EOF -- subheader
- */
+ $hauteur_block= ($hauteur_block -1) ; // force min inter height line
+ $coor_X = ( ( $pdf->page_width / 2)+( $pdf->block_marge ) );
+ $le_Y += 2;
+ $pdf->SetXY( ($coor_X + $pdf->block_padding ) , $le_Y);
+ $pdf->Cell( ($coor_X + $pdf->block_padding ),$hauteur_block, tep_correct_entitie_put_pdf( sprintf(__('dl print doc date expedition %s'), tep_date_short($obj_shipping->date_expedition)) ) , 0, 0,"L");
+ $le_Y += $hauteur_block;
+ $pdf->SetXY( ($coor_X + $pdf->block_padding ) , $le_Y);
+ $pdf->Cell(($coor_X + $pdf->block_padding ),$hauteur_block, tep_correct_entitie_put_pdf( sprintf(__('dl print doc method expedition %s'),$obj_shipping->method) ) , 0, 0,"L");
- /**
- Ligne cesure + marque pliage
- */
- $pdf->Cell(50);
- $pdf->SetY(60);
- $pdf->SetDrawColor(153,153,153);
- $pdf->Cell(197,.1,'',1,1,'L',1);
+ $le_Y += $hauteur_block;
+ $pdf->SetXY( ($coor_X + $pdf->block_padding ) , $le_Y);
+ $pdf->Cell(($coor_X + $pdf->block_padding ),$hauteur_block, tep_correct_entitie_put_pdf( sprintf(__('dl print doc tracking expedition %s'),$obj_shipping->tracking) ) , 0, 0,"L");
/**
- Block de Adresse owner shop
+ EOF -- subheader
*/
- $le_Y=67;
- $hauteur_block=35;
- //Draw Box for Invoice Address
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor($pdf->bg_color_1);
- $pdf->RoundedRect(6, $le_Y, 90, 35, 2, 'DF');
- //Draw the invoice address text
- $pdf->SetFont($pdf->font,'B',10);
- $pdf->SetTextColor($pdf->txt_color_1);
- $pdf->Text(11,77, tep_correct_entitie_put_pdf(__('')));
- $pdf->SetX(0);
- $pdf->SetY(80);
- $pdf->Cell(9);
- $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(STORE_NAME_ADDRESS),0,'L');
+/**
+ EOB -- address
+*/
+ $le_Y=50; // fixe height for view address destinataire dans les enveloppe a fenetres
+
/**
+ Block de Adresse owner shop
+ */
+ $hauteur_block=$pdf->DrawAddresse($le_Y, tep_correct_entitie_put_pdf(STORE_NAME_ADDRESS) , '' , 'E');
+ /**
Block de Adresse customers
*/
+ $hauteur_block=$pdf->DrawAddresse($le_Y, tep_correct_entitie_put_pdf(tep_address_format(1, $order->delivery, '', '', "\n")) , tep_correct_entitie_put_pdf(__('dl entry ship to')) , 'D');
- //Draw Box for Delivery Address
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor(255);
- $pdf->RoundedRect(113, $le_Y, 90, 35, 2, 'DF');
+ /**
+ Ligne cesure + marque pliage
+ */
+ $le_Y = ($le_Y+$hauteur_block+$pdf->block_marge);
+ $pdf->SetY($le_Y);
+ $pdf->SetDrawColor(153,153,153);
+ $pdf->Cell( ($pdf->page_width - ($pdf->page_marge * 2) ) ,.1,'',1,1,'L',1);
- //Draw the invoice delivery address text
- $pdf->SetFont($pdf->font,'B',10);
- $pdf->SetTextColor($pdf->txt_color_1);
- $pdf->Text(117,77,tep_correct_entitie_put_pdf(__('dl entry ship to')));
- $pdf->SetX(0);
- $pdf->SetY(80);
- $pdf->Cell(115);
- $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->delivery, '', '', "\n")),0,'L');
+/**
+ EOF -- address
+*/
/**
Block detail delivery
*/
+
//Fields Name position
-$Y_Fields_Name_position = ($le_Y+$hauteur_block+$marge_block);
+$Y_Fields_Name_position = ($le_Y+ $pdf->block_marge );
$item_count=0;
//Table position, under Fields Name
-$Y_Table_Position = ($Y_Fields_Name_position+6);
+$hauteur_block=5;
+$Y_Table_Position = ($Y_Fields_Name_position+$hauteur_block);
-// output_table_heading_packingslip($Y_Fields_Name_position);
//First create each Field Name
//Gray color filling each Field Name box
$pdf->SetFillColor($pdf->bg_color_1);
//Bold Font for Field Name
- $pdf->SetFont($pdf->font,'B',10);
- $pdf->SetY($Y_Fields_Name_position);
- $pdf->SetX(6);
- $pdf->Cell(9,6,tep_correct_entitie_put_pdf(__('dl table heading qty orders')),1,0,'C',1);
- $pdf->SetX(15);
- $pdf->Cell(9,6,tep_correct_entitie_put_pdf(__('dl table heading qty exedie')),1,0,'C',1);
- $pdf->SetX(24);
- $pdf->Cell(27,6,tep_correct_entitie_put_pdf(__('dl table heading products model')),1,0,'C',1);
- $pdf->SetX(50);
- $pdf->Cell(153,6,tep_correct_entitie_put_pdf(__('dl table heading products')),1,0,'C',1);
+ $pdf->SetFont($pdf->font,'B',8);
+
+ $X_pos = $pdf->page_marge;
+ $pdf->SetXY($X_pos , $Y_Fields_Name_position );
+
+
+
+ $cell_w = 9;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('dl table heading qty orders')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 9;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('dl table heading qty exedie')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 27;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('dl table heading products model')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $last_rows = $cell_w = ( ($pdf->page_width - $pdf->page_marge ) - $X_pos ) ;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('dl table heading products')),1,0,'C',1);
+
+ $pdf->Ln();
+
+
+
+$hauteur_block=$hauteur_block_r=5;
+$cesure = $last_rows;
+
//Show the products information line by line
// for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) {
foreach($order->products as $rows) {
-// print_r($rows);
-// exit;
+
if(in_array($rows['id'], $Prdt )) {
- $hauteur_block=$hauteur_block_r=6;
+// $hauteur_block=$hauteur_block_r=6;
$nbr_l=1;
//. cesure general name produits
- if (strlen($rows['name']) > 40 ) {
- $r=tep_wordwrap($rows['name'], 40);
+ if (strlen($rows['name']) > $cesure ) {
+ $r=tep_wordwrap($rows['name'], $cesure);
$rows['name'] =$r['txt'];
$nbr_l +=$r['nbr'];
}
// concat des attribut de produits sur les nom, avec saut de ligne
if (isset($rows['attributes']) && (($k = sizeof($rows['attributes'])) > 0)) {
for ($j = 0; $j < $k; $j++) {
- $ligne="\n - ".$rows['attributes'][$j]['option'] . ': ' . $rows['attributes'][$j]['value'];
- if (strlen($ligne) > 40 ) {
- $r=tep_wordwrap($ligne, 40);
- $rows['name'] .=$r['txt'];
- $nbr_l +=$r['nbr'];
- } else {
- $rows['name'] .=$ligne;
- $nbr_l +=1;
- }
+ $ligne="\n - ".$rows['attributes'][$j]['option'] . ': ' . $rows['attributes'][$j]['value'];
+ if (strlen($ligne) > $cesure ) {
+ $r=tep_wordwrap($ligne, $cesure);
+ $rows['name'] .=$r['txt'];
+ $nbr_l +=$r['nbr'];
+ } else {
+ $rows['name'] .=$ligne;
+ $nbr_l +=1;
+ }
}
}
- $hauteur_block_r=($nbr_l*$hauteur_block_r);
+ $hauteur_block_r=($nbr_l*$hauteur_block_r);
+
+ $X_pos = $pdf->page_marge;
+
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
+
+
+
+ $pdf->SetFont($pdf->font,'',7);
+
// quantite
- $pdf->SetFont($pdf->font,'',10);
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(6);
- $pdf->MultiCell(9,$hauteur_block_r,$rows['qty'],1,'C');
+ $cell_w = 9 ;
+ $pdf->MultiCell($cell_w,$hauteur_block_r,$rows['qty'],1,'C');
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
// quantite
- $pdf->SetFont($pdf->font,'',10);
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(15);
- $pdf->MultiCell(9,$hauteur_block_r,$Qt[$rows['id']],1,'C');
+ $cell_w = 9 ;
+ $pdf->MultiCell($cell_w,$hauteur_block_r,$Qt[$rows['id']],1,'C');
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
// modele
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(24);
- $pdf->SetFont($pdf->font,'',8);
- $pdf->MultiCell(26,$hauteur_block_r,tep_correct_entitie_put_pdf($rows['model']),1,'C');
+ $cell_w = 27 ;
+ $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($rows['model']),1,'C');
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
// nom product
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(50);
- $pdf->SetFont($pdf->font,'',8);
- $pdf->MultiCell(153,$hauteur_block,tep_correct_entitie_put_pdf($rows['name']),1,'L');
+ $cell_w = $last_rows ;
+ $pdf->MultiCell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf($rows['name']),1,'L');
$Y_Table_Position += $hauteur_block_r;
Modified: trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php
===================================================================
--- trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php 2012-03-04 10:31:05 UTC (rev 4058)
@@ -1,137 +1,74 @@
<?php
/**
- @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
- @portion code Copyright (c) 2002 osCommerce
+ @licence GPL $pdf->page_width 5-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) $pdf->page_width 2 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
@date 01/03/2012, 10:55
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
+ @brief A4 page Invoice pdf
+ @subpackage modele harry
*/
-$le_Y=0;
-$marge_block=3;
-$padding_block=5;
-// Add the first page
-$pdf->AddPage();
+$pdf->AddPage();
- /**
- EOB -- header
- */
- $le_Y=($le_Y+$marge_block);
- $hauteur_block=11;
- $pdf->SetFont($pdf->font,'BI',15);
- $pdf->SetTextColor($pdf->txt_color_1);
+/**
+ EOB -- header
+*/
+ $le_Y=$pdf->block_marge;
- $pdf->SetXY(155,$le_Y);
- //Draw Order Number Text
- $pdf->Cell(48,$hauteur_block, __('iv print doc type invoice') , 0, 0,"R");
+ $hauteur_block = $pdf->DrawTypeAndRef($le_Y , tep_correct_entitie_put_pdf(__('iv print doc type invoice') ) , 'FA-'.$order->info['orders_prefix'].$order->info['facture_id'] );
- $le_Y=($le_Y+$hauteur_block);
- $hauteur_block=11;
- //Draw Box for Order Number, Date & Payment method
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor($pdf->bg_color_1);
- $pdf->RoundedRect(155, $le_Y, 48, $hauteur_block, 2, 'DF');
+ /// add other info
+ $pdf->SetFont($pdf->font,'I',9);
+ $width = 70 ;
+ $coor_X = ( $pdf->page_width - $width - $pdf->page_marge );
+ $le_Y=($le_Y+$hauteur_block);
+ $pdf->SetXY($coor_X,$le_Y);
+ $pdf->Cell($width,$pdf->line_height, sprintf(__('iv print doc date order %s'), tep_date_short($order->info['date_purchased'])) , 0, 0,"R");
- $pdf->SetFont($pdf->font,'BI',15);
- $pdf->SetTextColor($pdf->txt_color_1);
+/**
+ EOF -- header
+*/
- $pdf->SetXY(155,$le_Y);
- //Draw Order Number Text
- $temp = tep_correct_entitie_put_pdf(__('iv print packingslip ordernr'));
- $pdf->Cell(48,$hauteur_block, 'FA-'.$order->info['orders_prefix'].$order->info['facture_id'], 0, 0,"C");
- $pdf->SetFont($pdf->font,'BI',10);
- $le_Y=($le_Y+$hauteur_block);
- $pdf->SetXY(155,$le_Y);
- $pdf->Cell(48,$hauteur_block, sprintf(__('iv print doc date order %s'), tep_date_short($order->info['date_purchased'])) , 0, 0,"R");
- /**
- EOF -- header
- */
+/**
+ EOB -- address
+*/
- /**
- Ligne cesure + marque pliage
- */
- $pdf->Cell(50);
- $pdf->SetY(60);
- $pdf->SetDrawColor(153,153,153);
- $pdf->Cell(197,.1,'',1,1,'L',1);
+ $le_Y=50; // fixe height for view address destinataire dans les enveloppe a fenetres
-
/**
Block de Adresse owner shop
*/
-
- $le_Y=67;
- $hauteur_block=35;
- //Draw Box for Invoice Address
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor($pdf->bg_color_1);
- $pdf->RoundedRect(6, $le_Y, 90, 35, 2, 'DF');
-
- //Draw the invoice address text
- $pdf->SetFont($pdf->font,'B',10);
- $pdf->SetTextColor($pdf->txt_color_1);
- $pdf->Text(11,77, tep_correct_entitie_put_pdf(__('')));
- $pdf->SetX(0);
- $pdf->SetY(80);
- $pdf->Cell(9);
- $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(STORE_NAME_ADDRESS),0,'L');
-
-
+ $hauteur_block=$pdf->DrawAddresse($le_Y, tep_correct_entitie_put_pdf(STORE_NAME_ADDRESS) , '' , 'E');
/**
Block de Adresse customers
*/
+ $hauteur_block=$pdf->DrawAddresse($le_Y, tep_correct_entitie_put_pdf(tep_address_format(1, $order->customer, '', '', "\n")) , tep_correct_entitie_put_pdf(__('iv entry order to')) , 'D');
- //Draw Box for Delivery Address
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor(255);
- $pdf->RoundedRect(113, $le_Y, 90, 35, 2, 'DF');
+ /**
+ Ligne cesure + marque pliage
+ */
+ $le_Y = ($le_Y+$hauteur_block+$pdf->block_marge);
+ $pdf->SetY($le_Y);
+ $pdf->SetDrawColor(153,153,153);
+ $pdf->Cell( ($pdf->page_width - ($pdf->page_marge * 2) ) ,.1,'',1,1,'L',1);
- //Draw the invoice delivery address text
- $pdf->SetFont($pdf->font,'B',10);
- $pdf->SetTextColor($pdf->txt_color_1);
- $pdf->Text(117,77,tep_correct_entitie_put_pdf(__('iv entry order to')));
- $pdf->SetX(0);
- $pdf->SetY(80);
- $pdf->Cell(115);
- $pdf->MultiCell(71, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->customer, '', '', "\n")),0,'L');
-
-
-
-
-
-// if (isset($_POST) && isset($_POST['show_pay_method'])){
/**
- Method payement
+ EOF -- address
*/
- $le_Y=($le_Y+$hauteur_block+$marge_block);
- $hauteur_block=9;
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor($pdf->bg_color_1);
- $pdf->RoundedRect(6, $le_Y, 197, $hauteur_block, 2, 'DF');
- $pdf->Text(10,($le_Y+6),tep_correct_entitie_put_pdf(sprintf(__('iv entry payment method %s') , $order->info['payment_method'])), 0, 0, 'R');
-// }
-
-
-
-
-
/**
Block detail commande
*/
@@ -140,69 +77,77 @@
//Fields Name position
-$Y_Fields_Name_position = ($le_Y+$hauteur_block+$marge_block);
+$Y_Fields_Name_position = ($le_Y+$pdf->block_marge);
$item_count=0;
//Table position, under Fields Name
-$Y_Table_Position = ($Y_Fields_Name_position+6);
+$hauteur_block=5;
+$Y_Table_Position = ($Y_Fields_Name_position+$hauteur_block);
//First create each Field Name
//Gray color filling each Field Name box
$pdf->SetFillColor($pdf->bg_color_1);
//Bold Font for Field Name
- $pdf->SetFont($pdf->font,'B',10);
- $pdf->SetY($Y_Fields_Name_position);
+ $pdf->SetFont($pdf->font,'B',8);
- $X_pos = 6;
- $pdf->SetX($X_pos);
- $cell_w = 9;
- $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading qty orders')),1,0,'C',1);
+ $X_pos = $pdf->page_marge;
+ $pdf->SetXY($X_pos , $Y_Fields_Name_position );
+
+
+ $cell_w = 25;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('iv table heading products model')),1,0,'C',1);
+
$X_pos +=$cell_w;
$pdf->SetX($X_pos);
- $cell_w = 25;
- $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading products model')),1,0,'C',1);
+ $cell_w = 86;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('iv table heading products')),1,0,'C',1);
$X_pos +=$cell_w;
$pdf->SetX($X_pos);
- $cell_w = 83;
- $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading products')),1,0,'C',1);
+ $cell_w = 9;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('iv table heading qty orders')),1,0,'C',1);
$X_pos +=$cell_w;
$pdf->SetX($X_pos);
$cell_w = 20;
- $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading price excluding tax')),1,0,'C',1);
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('iv table heading price excluding tax')),1,0,'C',1);
$X_pos +=$cell_w;
$pdf->SetX($X_pos);
$cell_w = 20;
- $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading price including tax')),1,0,'C',1);
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('iv table heading price including tax')),1,0,'C',1);
$X_pos +=$cell_w;
$pdf->SetX($X_pos);
$cell_w = 20;
- $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading total excluding tax')),1,0,'C',1);
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('iv table heading total excluding tax')),1,0,'C',1);
$X_pos +=$cell_w;
$pdf->SetX($X_pos);
$cell_w = 20;
- $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading total including tax')),1,0,'C',1);
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('iv table heading total including tax')),1,0,'C',1);
$pdf->Ln();
+
+
+$hauteur_block=$hauteur_block_r=5;
+$cesure = 84;
+
+
//Show the products information line by line
for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) {
- $hauteur_block=$hauteur_block_r=6;
$nbr_l=1;
//. cesure general name produits
- if (strlen($order->products[$i]['name']) > 40 ) {
- $r=tep_wordwrap($order->products[$i]['name'], 40);
+ if (strlen($order->products[$i]['name']) > $cesure ) {
+ $r=tep_wordwrap($order->products[$i]['name'], $cesure);
$order->products[$i]['name'] =$r['txt'];
$nbr_l +=$r['nbr'];
}
@@ -210,8 +155,8 @@
if (isset($order->products[$i]['attributes']) && (($k = sizeof($order->products[$i]['attributes'])) > 0)) {
for ($j = 0; $j < $k; $j++) {
$ligne="\n - ".$order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value'];
- if (strlen($ligne) > 40 ) {
- $r=tep_wordwrap($ligne, 40);
+ if (strlen($ligne) > $cesure ) {
+ $r=tep_wordwrap($ligne, $cesure);
$order->products[$i]['name'] .=$r['txt'];
$nbr_l +=$r['nbr'];
} else {
@@ -222,24 +167,25 @@
}
- $hauteur_block_r=($nbr_l*$hauteur_block_r);
- $X_pos = 6;
+ $hauteur_block_r=($nbr_l*$hauteur_block);
+ $X_pos = $pdf->page_marge;
+
$pdf->SetXY( $X_pos , $Y_Table_Position);
-// qty
- $cell_w = 9;
- $pdf->SetFont($pdf->font,'',10);
- $pdf->MultiCell($cell_w,$hauteur_block_r,$order->products[$i]['qty'],1,'C');
+/*
$X_pos +=$cell_w;
- $pdf->SetXY( $X_pos , $Y_Table_Position);
+ $pdf->SetXY( $X_pos , $Y_Table_Position);*/
+
+ $pdf->SetFont($pdf->font,'',7);
+
// modele
$cell_w = 25 ;
- $pdf->SetFont($pdf->font,'',8);
+
$pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($order->products[$i]['model']),1,'C');
@@ -247,35 +193,42 @@
$pdf->SetXY( $X_pos , $Y_Table_Position);
// name
- $cell_w = 83 ;
+ $cell_w = 86 ;
+ $pdf->MultiCell($cell_w ,$hauteur_block, tep_correct_entitie_put_pdf($order->products[$i]['name']),1,'L');
+
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
+
$pdf->SetFont($pdf->font,'',8);
- $pdf->MultiCell($cell_w ,$hauteur_block,tep_correct_entitie_put_pdf($order->products[$i]['name']),1,'L');
+// qty
+ $cell_w = 9;
+ $pdf->MultiCell($cell_w,$hauteur_block_r,$order->products[$i]['qty'],1,'R');
$X_pos +=$cell_w;
$pdf->SetXY( $X_pos , $Y_Table_Position);
// totaux / prix
$cell_w = 20;
- $pdf->SetFont($pdf->font,'',10);
- $pdf->MultiCell($cell_w ,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format($order->products[$i]['final_price'], true, $order->info['currency'], $order->info['currency_value']), false),1,'C');
+ $pdf->MultiCell($cell_w ,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format($order->products[$i]['final_price'], true, $order->info['currency'], $order->info['currency_value']), false),1,'R');
$X_pos +=$cell_w;
$pdf->SetXY( $X_pos , $Y_Table_Position);
$cell_w = 20;
- $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']), true, $order->info['currency'], $order->info['currency_value']), false),1,'C');
+ $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']), true, $order->info['currency'], $order->info['currency_value']), false),1,'R');
$X_pos +=$cell_w;
$pdf->SetXY( $X_pos , $Y_Table_Position);
$cell_w = 20;
- $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format($order->products[$i]['final_price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']), false),1,'C');
+ $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format($order->products[$i]['final_price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']), false),1,'R');
$X_pos +=$cell_w;
$pdf->SetXY( $X_pos , $Y_Table_Position);
$cell_w = 20;
- $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']) * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']), false),1,'C');
+ $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']) * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']), false),1,'R');
/* Check for product line overflow*/
$item_count++;
@@ -292,36 +245,60 @@
}
+
+
+// if (isset($_POST) && isset($_POST['show_pay_method'])){
+/**
+ Method payement
+*/
+
+// $hauteur_block=9;
+// $pdf->SetDrawColor(0);
+// $pdf->SetLineWidth(0.2);
+// $pdf->SetFillColor($pdf->bg_color_1);
+// $pdf->RoundedRect(6, $le_Y, ($pdf->page_width/2.2) , $hauteur_block, 2, 'DF');
+// $pdf->Text(10,($le_Y+6),tep_correct_entitie_put_pdf(sprintf(__('iv entry payment method %s') , $order->info['payment_method'])), 0, 0, 'R');
+ $le_Y=($Y_Table_Position+$pdf->block_marge);
+ $pdf->SetXY(6, $le_Y);
+ $pdf->MultiCell(94,$hauteur_block, tep_correct_entitie_put_pdf(sprintf(__('iv entry payment method %s') , $order->info['payment_method'])) ,1,'L');
+// }
+
+
+
// Order Totals
+ $Y_Table_Position = ($Y_Table_Position+$pdf->block_marge);
for ($i = 0, $n = sizeof($order->totals); $i < $n; $i++) {
- $Y_Table_Position +=5;
- $pdf->SetY($Y_Table_Position );
- $pdf->SetX(36);
+
+
+ $pdf->SetXY(106 , $Y_Table_Position);
$temp = substr ($order->totals[$i]['text'],0 ,3);
- $pdf->MultiCell(130,6,tep_correct_entitie_put_pdf($order->totals[$i]['title'],true) ,0,'R');
- $pdf->SetY($Y_Table_Position );
- $pdf->SetX(146);
- $pdf->MultiCell(54,6, tep_correct_entitie_put_pdf($order->totals[$i]['text'],false),0,'R');
+ $pdf->MultiCell(60,$hauteur_block,tep_correct_entitie_put_pdf($order->totals[$i]['title'],true) ,1,'R');
+
+ $pdf->SetXY(166 , $Y_Table_Position);
+ $pdf->MultiCell(40,$hauteur_block, tep_correct_entitie_put_pdf($order->totals[$i]['text'],false),1,'R');
+
+ $Y_Table_Position +=5;
}
+/*
if (isset($_POST) && isset($_POST['show_pay_method'])){
$DB=Database::getInstance();
$innum = $orders['orders_prefix'].$orders['orders_id'];
$orders_comments_query = $DB->query("select comments,date_added from " . TABLE_ORDERS_STATUS_HISTORY . " where orders_id = '$innum' order by date_added");
if ($orders_comments_query->__get('NumRows')>0) {
- $Y_Table_Position=($Y_Table_Position+$marge_block);
+ $Y_Table_Position=($Y_Table_Position+$pdf->block_marge);
while ($orders_comments = $orders_comments_query->fectAssoc()) {
if(tep_not_null($orders_comments['comments'])){
- $pdf->SetFont($pdf->font,'',10);
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(6);
- $pdf->MultiCell(35,6,date(TEXT_ORDER_FORMAT, strtotime($orders_comments['date_added'])),0,'C');
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(41);
- $pdf->MultiCell(100,6,tep_correct_entitie_put_pdf("Comments: " . $orders_comments['comments']),0,'C');
- $Y_Table_Position += 5;
+ $pdf->SetFont($pdf->font,'',10);
+ $pdf->SetY($Y_Table_Position);
+ $pdf->SetX(6);
+ $pdf->MultiCell(35,6,date(TEXT_ORDER_FORMAT, strtotime($orders_comments['date_added'])),0,'C');
+ $pdf->SetY($Y_Table_Position);
+ $pdf->SetX(41);
+ $pdf->MultiCell(100,6,tep_correct_entitie_put_pdf("Comments: " . $orders_comments['comments']),0,'C');
+ $Y_Table_Position += 5;
}
}
}
-}
+}*/
?>
\ No newline at end of file
Modified: trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/packingslip.php
===================================================================
--- trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/packingslip.php 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/packingslip.php 2012-03-04 10:31:05 UTC (rev 4058)
@@ -7,186 +7,189 @@
@date 01/03/2012, 10:55
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
+ @brief A4 page pdf
+ @subpackage modele harry
*/
-$le_Y=0;
-$marge_block=3;
-$padding_block=5;
-// Add the first page
$pdf->AddPage();
- /**
- EOB -- header
- */
- $le_Y=($le_Y+$marge_block);
- $hauteur_block=11;
- $pdf->SetFont($pdf->font,'BI',15);
- $pdf->SetTextColor($pdf->txt_color_1);
+/**
+ EOB -- header
+*/
+ $le_Y=$pdf->block_marge;
- $pdf->SetXY(155,$le_Y);
- //Draw Order Number Text
- $pdf->Cell(48,$hauteur_block, __('ps print doc type packingslip') , 0, 0,"R");
+ $hauteur_block = $pdf->DrawTypeAndRef($le_Y , tep_correct_entitie_put_pdf(__('ps print doc type packingslip') ) , 'BC-'.$order->info['orders_prefix'].$order->info['orders_id'] );
- $le_Y=($le_Y+$hauteur_block);
- $hauteur_block=11;
- //Draw Box for Order Number, Date & Payment method
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor($pdf->bg_color_1);
- $pdf->RoundedRect(155, $le_Y, 48, $hauteur_block, 2, 'DF');
+ /// add other info
+ $pdf->SetFont($pdf->font,'I',9);
+ $width = 70 ;
+ $coor_X = ( $pdf->page_width - $width - $pdf->page_marge );
+ $le_Y=($le_Y+$hauteur_block);
+ $pdf->SetXY($coor_X,$le_Y);
+ $pdf->Cell($width,$pdf->line_height, sprintf(__('ps print doc date order %s'), tep_date_short($order->info['date_purchased'])) , 0, 0,"R");
- $pdf->SetFont($pdf->font,'BI',15);
- $pdf->SetTextColor($pdf->txt_color_1);
+/**
+ EOF -- header
+*/
- $pdf->SetXY(155,$le_Y);
- //Draw Order Number Text
- $temp = tep_correct_entitie_put_pdf(__('ps print packingslip ordernr'));
- $pdf->Cell(48,$hauteur_block, 'BC-'.$order->info['orders_prefix'].$order->info['orders_id'], 0, 0,"C");
- $pdf->SetFont($pdf->font,'BI',10);
- $le_Y=($le_Y+$hauteur_block);
- $pdf->SetXY(155,$le_Y);
- $pdf->Cell(48,$hauteur_block, sprintf(__('ps print doc date order %s'), tep_date_short($order->info['date_purchased'])) , 0, 0,"R");
- /**
- EOF -- header
- */
+/**
+ EOB -- address
+*/
+ $le_Y=50; // fixe height for view address destinataire dans les enveloppe a fenetres
/**
- Ligne cesure + marque pliage
+ Block de Adresse owner shop
*/
- $pdf->Cell(50);
- $pdf->SetY(60);
- $pdf->SetDrawColor(153,153,153);
- $pdf->Cell(197,.1,'',1,1,'L',1);
-
-
+ $hauteur_block=$pdf->DrawAddresse($le_Y, tep_correct_entitie_put_pdf(STORE_NAME_ADDRESS) , '' , 'E');
/**
- Block de Adresse owner shop
+ Block de Adresse customers
*/
+ $hauteur_block=$pdf->DrawAddresse($le_Y, tep_correct_entitie_put_pdf(tep_address_format(1, $order->delivery, '', '', "\n")) , tep_correct_entitie_put_pdf(__('ps entry ship to')) , 'D');
- $le_Y=67;
- $hauteur_block=35;
- //Draw Box for Invoice Address
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor($pdf->bg_color_1);
- $pdf->RoundedRect(6, $le_Y, 90, 35, 2, 'DF');
-
- //Draw the invoice address text
- $pdf->SetFont($pdf->font,'B',10);
- $pdf->SetTextColor($pdf->txt_color_1);
- $pdf->Text(11,77, tep_correct_entitie_put_pdf(__('')));
- $pdf->SetX(0);
- $pdf->SetY(80);
- $pdf->Cell(9);
- $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(STORE_NAME_ADDRESS),0,'L');
-
-
/**
- Block de Adresse customers
+ Ligne cesure + marque pliage
*/
+ $le_Y = ($le_Y+$hauteur_block+$pdf->block_marge);
+ $pdf->SetY($le_Y);
+ $pdf->SetDrawColor(153,153,153);
+ $pdf->Cell( ($pdf->page_width - ($pdf->page_marge * 2) ) ,.1,'',1,1,'L',1);
- //Draw Box for Delivery Address
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor(255);
- $pdf->RoundedRect(113, $le_Y, 90, 35, 2, 'DF');
+/**
+ EOF -- address
+*/
- //Draw the invoice delivery address text
- $pdf->SetFont($pdf->font,'B',10);
- $pdf->SetTextColor($pdf->txt_color_1);
- $pdf->Text(117,77,tep_correct_entitie_put_pdf(__('ps entry ship to')));
- $pdf->SetX(0);
- $pdf->SetY(80);
- $pdf->Cell(115);
- $pdf->MultiCell(71, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->delivery, '', '', "\n")),0,'L');
-
/**
Method payement
*/
- $le_Y=($le_Y+$hauteur_block+$marge_block);
+ $le_Y=($le_Y +$pdf->block_marge );
$hauteur_block=9;
$pdf->SetDrawColor(0);
$pdf->SetLineWidth(0.2);
$pdf->SetFillColor($pdf->bg_color_1);
- $pdf->RoundedRect(6, $le_Y, 197, $hauteur_block, 2, 'DF');
+ $pdf->RoundedRect(6, $le_Y, ($pdf->page_width - ($pdf->page_marge * 2) ) , $hauteur_block, 2, 'DF');
$pdf->Text(10,($le_Y+6),tep_correct_entitie_put_pdf(sprintf(__('ps entry payment method %s') , $order->info['payment_method'])), 0, 0, 'R');
+
+
/**
Block detail commande
*/
+
+
//Fields Name position
-$Y_Fields_Name_position = ($le_Y+$hauteur_block+$marge_block);
+$Y_Fields_Name_position = ($le_Y+ $pdf->block_marge + $hauteur_block );
$item_count=0;
//Table position, under Fields Name
-$Y_Table_Position = ($Y_Fields_Name_position+6);
+$hauteur_block=5;
+$Y_Table_Position = ($Y_Fields_Name_position+$hauteur_block);
-// output_table_heading_packingslip($Y_Fields_Name_position);
+
//First create each Field Name
//Gray color filling each Field Name box
$pdf->SetFillColor($pdf->bg_color_1);
//Bold Font for Field Name
- $pdf->SetFont($pdf->font,'B',10);
- $pdf->SetY($Y_Fields_Name_position);
- $pdf->SetX(6);
- $pdf->Cell(9,6,tep_correct_entitie_put_pdf(__('ps table heading qty orders')),1,0,'C',1);
- $pdf->SetX(15);
- $pdf->Cell(25,6,tep_correct_entitie_put_pdf(__('ps table heading products model')),1,0,'C',1);
- $pdf->SetX(40);
- $pdf->Cell(163,6,tep_correct_entitie_put_pdf(__('ps table heading products')),1,0,'C',1);
+ $pdf->SetFont($pdf->font,'B',8);
+
+ $X_pos = $pdf->page_marge;
+ $pdf->SetXY($X_pos , $Y_Fields_Name_position );
+
+
+
+ $cell_w = 9;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('ps table heading qty orders')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 25;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('ps table heading products model')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $last_rows = $cell_w = ( ($pdf->page_width - $pdf->page_marge ) - $X_pos ) ;
+ $pdf->Cell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf(__('ps table heading products')),1,0,'C',1);
+
+
+ $pdf->Ln();
+
+
+
+$hauteur_block=$hauteur_block_r=5;
+$cesure = $last_rows;
+
+
//Show the products information line by line
for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) {
- $hauteur_block=$hauteur_block_r=6;
+// $hauteur_block=$hauteur_block_r=6;
$nbr_l=1;
- //. cesure general name produits
- if (strlen($order->products[$i]['name']) > 40 ) {
- $r=tep_wordwrap($order->products[$i]['name'], 40);
+
+ //. cesure general name produits
+ if (strlen($order->products[$i]['name']) > $cesure ) {
+ $r=tep_wordwrap($order->products[$i]['name'], $cesure);
$order->products[$i]['name'] =$r['txt'];
$nbr_l +=$r['nbr'];
}
// concat des attribut de produits sur les nom, avec saut de ligne
if (isset($order->products[$i]['attributes']) && (($k = sizeof($order->products[$i]['attributes'])) > 0)) {
for ($j = 0; $j < $k; $j++) {
- $ligne="\n - ".$order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value'];
- if (strlen($ligne) > 40 ) {
- $r=tep_wordwrap($ligne, 40);
- $order->products[$i]['name'] .=$r['txt'];
- $nbr_l +=$r['nbr'];
- } else {
- $order->products[$i]['name'] .=$ligne;
- $nbr_l +=1;
- }
+ $ligne="\n - ".$order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value'];
+ if (strlen($ligne) > $cesure ) {
+ $r=tep_wordwrap($ligne, $cesure);
+ $order->products[$i]['name'] .=$r['txt'];
+ $nbr_l +=$r['nbr'];
+ } else {
+ $order->products[$i]['name'] .=$ligne;
+ $nbr_l +=1;
+ }
}
}
- $hauteur_block_r=($nbr_l*$hauteur_block_r);
+// $hauteur_block_r=($nbr_l*$hauteur_block_r);
+
+
+ $hauteur_block_r=($nbr_l*$hauteur_block);
+
+ $X_pos = $pdf->page_marge;
+
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
+
+
+
+ $pdf->SetFont($pdf->font,'',7);
+
+
+
// quantite
- $pdf->SetFont($pdf->font,'',10);
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(6);
- $pdf->MultiCell(9,$hauteur_block_r,$order->products[$i]['qty'],1,'C');
+ $cell_w = 9 ;
+ $pdf->MultiCell($cell_w,$hauteur_block_r,$order->products[$i]['qty'],1,'C');
+
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
// modele
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(15);
- $pdf->SetFont($pdf->font,'',8);
- $pdf->MultiCell(25,$hauteur_block_r,tep_correct_entitie_put_pdf($order->products[$i]['model']),1,'C');
+ $cell_w = 25 ;
+ $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($order->products[$i]['model']),1,'C');
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
// nom product
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(40);
- $pdf->SetFont($pdf->font,'',8);
- $pdf->MultiCell(163,$hauteur_block,tep_correct_entitie_put_pdf($order->products[$i]['name']),1,'L');
+ $cell_w = $last_rows ;
+ $pdf->MultiCell($cell_w,$hauteur_block,tep_correct_entitie_put_pdf($order->products[$i]['name']),1,'L');
$Y_Table_Position += $hauteur_block_r;
Modified: trunk/catalog/admin/document.php
===================================================================
--- trunk/catalog/admin/document.php 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/admin/document.php 2012-03-04 10:31:05 UTC (rev 4058)
@@ -1,16 +1,15 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/09/11, 16:26
+ @date 03/03/2012, 16:26
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
require('includes/application_top.php');
-
switch((string)$_REQUEST['mod']){
/**
@brief Traitement des images
@@ -67,7 +66,8 @@
@brief Traitement des pdf
*/
case 'delivery':
- if(( $filepath=DatasFiles::GetDoc('delivery', $_REQUEST['id'])) && file_exists(DIR_FS_ROOT_DOCS.$filepath)) {
+ new DatasFiles();
+ if(( $filepath=DatasFiles::GetDoc('delivery', $_REQUEST['id'])) && file_exists($filepath)) {
//We send to a browser
header('Content-Type: application/pdf');
// header('Content-Length: '.strlen($this->buffer));
@@ -76,12 +76,14 @@
header('Pragma: public');
ini_set('zlib.output_compression','0');
- readfile(DIR_FS_ROOT_DOCS.$filepath);
+ readfile($filepath);
}
break;
case 'packingslip':
- if(( $filepath=DatasFiles::GetDoc('packingslip', $_REQUEST['id'])) && file_exists(DIR_FS_ROOT_DOCS.$filepath)) {
+ new DatasFiles();
+
+ if(( $filepath=DatasFiles::GetDoc('packingslip', $_REQUEST['id'])) && file_exists($filepath)) {
//We send to a browser
header('Content-Type: application/pdf');
// header('Content-Length: '.strlen($this->buffer));
@@ -90,12 +92,13 @@
header('Pragma: public');
ini_set('zlib.output_compression','0');
- readfile(DIR_FS_ROOT_DOCS.$filepath);
+ readfile($filepath);
}
break;
case 'invoice':
- if(( $filepath=DatasFiles::GetDoc('invoices', $_REQUEST['id'])) && file_exists(DIR_FS_ROOT_DOCS.$filepath)) {
+ new DatasFiles();
+ if(( $filepath=DatasFiles::GetDoc('invoices', $_REQUEST['id'])) && file_exists($filepath)) {
//We send to a browser
header('Content-Type: application/pdf');
// header('Content-Length: '.strlen($this->buffer));
@@ -104,7 +107,7 @@
header('Pragma: public');
ini_set('zlib.output_compression','0');
- readfile(DIR_FS_ROOT_DOCS.$filepath);
+ readfile($filepath);
}
break;
Modified: trunk/catalog/admin/includes/content/configuration.central.inc
===================================================================
--- trunk/catalog/admin/includes/content/configuration.central.inc 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/admin/includes/content/configuration.central.inc 2012-03-04 10:31:05 UTC (rev 4058)
@@ -4,7 +4,7 @@
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/02/2012, 22:00
+ @date 04/03/2012, 20:05
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief content for pages configuration
@@ -28,9 +28,9 @@
<?php echo tep_draw_form('configuration', FILENAME_CONFIGURATION, 'gparentID=' . $gparentID.'&gID=' . $gID . '&action=save_mutli') ?>
<div class="box_left">
- <ul class="block_form">
+ <ul class="block_form tirroirs">
<?php foreach($list_edit as $row) { ?>
- <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
+ <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>" class="Ctrtirroir"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
<div class="block_input tirroir">
<label><?php if (tep_not_null(__($row->description)))echo __($row->description); ?></label>
Modified: trunk/catalog/admin/includes/functions/lib.orders.php
===================================================================
--- trunk/catalog/admin/includes/functions/lib.orders.php 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/admin/includes/functions/lib.orders.php 2012-03-04 10:31:05 UTC (rev 4058)
@@ -30,7 +30,7 @@
@brief Gestion des evolution du status d'une commandes
@param $oID int
@param $status int
- @param array post array(status,comments, notify, notify_comments, comments )
+ @param array post array(status,comments, notify, comments )
*/
function up_status_order($oID,$status, $post){
global $language, $orders_status_array, $messageStack;
@@ -51,7 +51,6 @@
$messageStack->add_session(__('success order update status'), 'success');
if ($notify) {
- $notify_comments = '';
$myarray = array(
Modified: trunk/catalog/admin/includes/gabarit/configuration/moddownloads.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/moddownloads.listing.gab 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/admin/includes/gabarit/configuration/moddownloads.listing.gab 2012-03-04 10:31:05 UTC (rev 4058)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/09/11, 20:05
+ @date 04/03/2012, 20:05
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief mise en forme de la gestion du stock
@@ -45,19 +45,19 @@
<h4 class="block_field-title"><?php echo __('moddownloads legend other') ?></h4>
- <ul class="block_input">
- <?php foreach(moddownloads::$list as $row)
- if(!in_array($row->key,array('DOWNLOAD_ENABLED')) ) { ?>
- <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
+ <ul class="block_input tirroirs">
+ <?php foreach(moddownloads::$list as $row)
+ if(!in_array($row->key,array('DOWNLOAD_ENABLED')) ) { ?>
+ <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>" class="Ctrtirroir"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
- <div class="block_input tirroir">
- <label><?php echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
- </li>
- <?php } ?>
+ <div class="block_input tirroir">
+ <label><?php echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
+ </li>
+ <?php } ?>
</ul>
</fieldset>
Modified: trunk/catalog/admin/includes/gabarit/configuration/modmail.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/modmail.listing.gab 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/admin/includes/gabarit/configuration/modmail.listing.gab 2012-03-04 10:31:05 UTC (rev 4058)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/09/11, 20:05
+ @date 04/03/2012, 20:05
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief mise en forme de la gestion du stock
@@ -54,20 +54,20 @@
<?php /** option de la gestion de stock, disponible que ci value precendente a true */ ?>
<?php if(modmail::$list['EMAIL_TRANSPORT']->value =='smtp'): ?>
- <ul class="block_input">
- <?php foreach(modmail::$list as $row)
- if(substr($row->key,0,4) =='SMTP') { ?>
- <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
+ <ul class="block_input tirroirs">
+ <?php foreach(modmail::$list as $row)
+ if(substr($row->key,0,4) =='SMTP') { ?>
+ <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>" class="Ctrtirroir"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
- <div class="block_input tirroir">
- <label><?php echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
- </li>
- <?php } ?>
- </ul>
+ <div class="block_input tirroir">
+ <label><?php echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
+ </li>
+ <?php } ?>
+ </ul>
<?php endif; ?>
</fieldset>
Modified: trunk/catalog/admin/includes/gabarit/configuration/modseourl.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/modseourl.listing.gab 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/admin/includes/gabarit/configuration/modseourl.listing.gab 2012-03-04 10:31:05 UTC (rev 4058)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/09/11, 20:05
+ @date 04/03/2012, 20:05
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief mise en forme de la gestion du stock
@@ -29,10 +29,10 @@
<legend title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></legend>
<div class="block_input">
- <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
+ <label><?php if (tep_not_null($row->description))echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
</div>
</p>
@@ -45,22 +45,21 @@
<h4 class="block_field-title"><?php echo __('modseourl legend seo') ?></h4>
<?php /** option de la gestion de stock, disponible que ci value precendente a true */ ?>
- <ul class="block_input">
- <?php foreach(modseourl::$list as $row)
- if( !in_array($row->key,array('SEO_ENABLED',)) ) { ?>
- <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
+ <ul class="block_input tirrois">
+ <?php foreach(modseourl::$list as $row)
+ if( !in_array($row->key,array('SEO_ENABLED',)) ) { ?>
+ <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>" class="Ctrtirroir"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
- <div class="block_input tirroir">
- <label><?php echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
- </li>
- <?php } ?>
- </ul>
+ <div class="block_input tirroir">
+ <label><?php echo __($row->description); ?></label>
+ <p>
+ <?php echo $row->value_field ; ?>
+ </p>
+ </div>
+ </li>
+ <?php } ?>
+ </ul>
-
<?php endif; ?>
</fieldset>
Modified: trunk/catalog/admin/includes/gabarit/configuration/modstock.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/modstock.listing.gab 2012-03-03 07:57:10 UTC (rev 4057)
+++ trunk/catalog/admin/includes/gabarit/configuration/modstock.listing.gab 2012-03-04 10:31:05 UTC (rev 4058)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 22/09/11, 20:05
+ @date 04/03/2012, 20:05
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@brief mise en forme de la gestion du stock
@@ -45,19 +45,19 @@
<fieldset class="block_field">
<legend class="block_field-title"><?php echo __('heading manage general option stock') ?></legend>
- <ul class="block_input">
- <?php foreach(modstock::$list as $row)
- if(strpos($row->key,'ATTRIBUTE')===false && !in_array($row->key,array('STOCK_CHECK')) ) { ?>
- <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
+ <ul class="block_input tirroirs">
+ <?php foreach(modstock::$list as $row)
+ if(strpos($row->key,'ATTRIBUTE')===false && !in_array($row->key,array('STOCK_CHECK')) ) { ?>
+ <li id="nav_<?php echo $row->key ?>"><h5 title="<?php echo '('.$row->key.' - ' . $row->set . ')'; ?>" class="Ctrtirroir"><?php echo __($row->title). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></h5>
- <div class="block_input tirroir">
- <label><?php echo __($row->description); ?></label>
- <p>
- <?php echo $row->value_field ; ?>
- </p>
- </div>
- </li>
- <?php } ?>
+ <div class="block_input tirroir">
+ <label><?php echo __($row->description); ?></label>
+ <p>
+ <?php echo $r...
[truncated message content] |
|
From: <os...@us...> - 2012-03-03 07:57:18
|
Revision: 4057
http://oscss.svn.sourceforge.net/oscss/?rev=4057&view=rev
Author: oscim
Date: 2012-03-03 07:57:10 +0000 (Sat, 03 Mar 2012)
Log Message:
-----------
correction coquille
report de la suite des widgets
Modified Paths:
--------------
trunk/catalog/admin/includes/languages/fr_FR/boxes/01_configuration.php
trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsExpected.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/homeStock.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastmodified.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastnews.txt
trunk/catalog/admin/includes/widget/ProductsExpected.php
trunk/catalog/admin/includes/widget/homeStock.php
trunk/catalog/admin/includes/widget/orderLastmodified.php
trunk/catalog/admin/includes/widget/orderLastnews.php
trunk/catalog/common/classes/DatasFiles.php
Added Paths:
-----------
trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsLastAdded.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsLastModified.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastservice.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastshipp.txt
trunk/catalog/admin/includes/widget/ProductsLastAdded.php
trunk/catalog/admin/includes/widget/ProductsLastModified.php
trunk/catalog/admin/includes/widget/orderLastservice.php
trunk/catalog/admin/includes/widget/orderLastshipp.php
Modified: trunk/catalog/admin/includes/languages/fr_FR/boxes/01_configuration.php
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/boxes/01_configuration.php 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/admin/includes/languages/fr_FR/boxes/01_configuration.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 23/10/11, 17:06
+ @date 02/03/2012, 17:06
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -62,4 +62,6 @@
define('BOX_HEADING_CONF_TITLE_BOX_CONFIGURATION_ENVIRONEMENT',"Environement" );
define('BOX_HEADING_CONF_CONFIGURATION_ORDERS',"Option des commandes" );
+
+define('BOX_HEADING_CONF_BOX_CONFIGURATION_ABONNEMENT',"Option des Abonnements" );
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsExpected.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsExpected.txt 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsExpected.txt 2012-03-03 07:57:10 UTC (rev 4057)
@@ -1,12 +1,17 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9
- @date 13/08/10, 09:54
+ @version 2.1.1
+ @date 0203/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
-$lang['products expected']="Produits à venir" ;
-$lang['products expected number ']="Nombre de produits en attente" ;
+$lang['products expected title %s']="Produits à venir ( x %s)" ;
+
+$lang['ProductsExpected box reference']="Réf." ;
+$lang['ProductsExpected box name']="Produits" ;
+$lang['ProductsExpected box date']="Publié le " ;
+$lang['ProductsExpected box status']="Etat" ;
?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsLastAdded.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsLastAdded.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsLastAdded.txt 2012-03-03 07:57:10 UTC (rev 4057)
@@ -0,0 +1,17 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 0203/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['ProductsLastAdded heading']="dernier produits ajouté" ;
+
+$lang['ProductsLastAdded box reference']="Réf." ;
+$lang['ProductsLastAdded box name']="Produits" ;
+$lang['ProductsLastAdded box date']="ajouté le" ;
+$lang['ProductsLastAdded box status']="Etat" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsLastModified.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsLastModified.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/ProductsLastModified.txt 2012-03-03 07:57:10 UTC (rev 4057)
@@ -0,0 +1,17 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 0203/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['ProductsLastModified heading']="dernier produits modifiés" ;
+
+$lang['ProductsLastModified box reference']="Réf." ;
+$lang['ProductsLastModified box name']="Produits" ;
+$lang['ProductsLastModified box date']="modifié le" ;
+$lang['ProductsLastModified box status']="Etat" ;
+?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/widget/homeStock.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/homeStock.txt 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/homeStock.txt 2012-03-03 07:57:10 UTC (rev 4057)
@@ -1,11 +1,17 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9h
- @date 06/06/10, 15:49
+ @version 2.1.1
+ @date 0203/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
-$lang['heading stock']="Suivi de stock d'alerte" ;
+$lang['heading stock %s']="Suivi de stock d'alerte (x %s)" ;
+
+$lang['homeStock box reference']="Réf." ;
+$lang['homeStock box name']="Produits" ;
+$lang['homeStock box stock']="Stock" ;
+$lang['homeStock box status']="Etat" ;
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastmodified.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastmodified.txt 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastmodified.txt 2012-03-03 07:57:10 UTC (rev 4057)
@@ -1,15 +1,16 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 01/11/11, 20:02
+ @date 0203/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
$lang['orderLastmodified box title']="Les dernière commandes modifiées" ;
$lang['orderLastmodified box reference']="Réf." ;
+$lang['orderLastmodified box docs']="Doc." ;
$lang['orderLastmodified box customers']="Clients" ;
$lang['orderLastmodified box date']="date" ;
$lang['orderLastmodified box status']="Etat" ;
Modified: trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastnews.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastnews.txt 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastnews.txt 2012-03-03 07:57:10 UTC (rev 4057)
@@ -1,15 +1,16 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 01/11/11, 20:02
+ @date 0203/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
$lang['orderLastnews box title']="Les nouvelles commandes" ;
$lang['orderLastnews box reference']="Réf." ;
+$lang['orderLastnews box docs']="Doc." ;
$lang['orderLastnews box customers']="Clients" ;
$lang['orderLastnews box date']="date" ;
$lang['orderLastnews box status']="Etat" ;
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastservice.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastservice.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastservice.txt 2012-03-03 07:57:10 UTC (rev 4057)
@@ -0,0 +1,18 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 0203/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['orderLastservice box title']="Les derniers services" ;
+$lang['orderLastservice box reference']="Réf." ;
+$lang['orderLastservice box docs']="Doc." ;
+$lang['orderLastservice box customers']="Clients" ;
+$lang['orderLastservice box date']="date" ;
+$lang['orderLastservice box date start']="depuis" ;
+$lang['orderLastservice box status']="Etat" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastshipp.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastshipp.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastshipp.txt 2012-03-03 07:57:10 UTC (rev 4057)
@@ -0,0 +1,17 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 0203/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['orderLastshipp box title']="Les dernières expeditions" ;
+$lang['orderLastshipp box reference']="Réf." ;
+$lang['orderLastshipp box docs']="Doc." ;
+$lang['orderLastshipp box customers']="Clients" ;
+$lang['orderLastshipp box date']="date" ;
+$lang['orderLastshipp box status']="Etat" ;
+?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/widget/ProductsExpected.php
===================================================================
--- trunk/catalog/admin/includes/widget/ProductsExpected.php 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/admin/includes/widget/ProductsExpected.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -1,22 +1,42 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9
- @date 13/08/10, 09:54
+ @version 2.1.1
+ @date 0203/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
+global $languages_id;
+
$DB=Database::getInstance();
-$query=$DB->query("SELECT distinct p.products_id,pd.products_name FROM " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd WHERE p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' AND p.products_date_available IS NOT NULL ");
-$res=$query->fetchAllAssoc();
+$_query=$DB->query("SELECT distinct p.*,pd.products_name FROM " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd WHERE p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' AND p.products_date_available IS NOT NULL ");
+
+
+if( !$_query->__get('numRows') )
+ return false;
+
+$res = $_query->fetchAllAssoc();
?>
<div id="<?php echo __FILE__ ?>" class="<?php echo $widg['class'] ?>" >
- <h3><?php echo '<a href="' . tep_href_link(FILENAME_PRODUCTS, 'expected=true', 'NONSSL') . '">'. __('products expected') .'</a>';?></h3>
- <p><?php echo __('products expected number ').count($res); ?></p>
- <ul class="spacer">
- <?php foreach($res as $item): ?>
- <li><a href="<?php echo tep_href_link(FILENAME_PRODUCTS, 'pID='.$item['products_id'].'&action=edit') ?>" ><?php echo $item['products_name'] ?></li>
- <?php endforeach; ?>
- </ul>
+ <h3><?php echo '<a href="' . tep_href_link(FILENAME_PRODUCTS, 'expected=true', 'NONSSL') . '">'. sprintf( __('products expected title %s'),count($res) ) .'</a>';?></h3>
+
+<table class="dataTableBase">
+ <tr>
+ <th><?php echo __('ProductsExpected box reference'); ?></th>
+ <th><?php echo __('ProductsExpected box name'); ?></th>
+ <th><?php echo __('ProductsExpected box date'); ?></th>
+ <th><?php echo __('ProductsExpected box status'); ?></th>
+ </tr>
+ <?php foreach($res as $row) : ?>
+ <tr>
+ <td><strong><a href="<?php echo tep_href_link(FILENAME_PRODUCTS, 'pID='.$row['products_id'].'&action=edit') ?>"><?php echo $row['products_id'] ?></strong></td>
+ <td style="width:200px;"><?php echo $row['products_name'] ?></td>
+ <td><?php echo tep_date_short($row['products_date_available']) ?></td>
+ <td><?php echo $row['products_status'] ?></td>
+ </tr>
+ <?php endforeach; ?>
+</table>
+
</div>
\ No newline at end of file
Added: trunk/catalog/admin/includes/widget/ProductsLastAdded.php
===================================================================
--- trunk/catalog/admin/includes/widget/ProductsLastAdded.php (rev 0)
+++ trunk/catalog/admin/includes/widget/ProductsLastAdded.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -0,0 +1,42 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 0203/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+global $languages_id;
+
+$DB=Database::getInstance();
+$_query=$DB->query("SELECT distinct p.*,pd.products_name FROM " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd WHERE p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' ORDER BY p.products_date_added DESC LIMIT 7");
+
+
+if( !$_query->__get('numRows') )
+ return false;
+
+$res = $_query->fetchAllAssoc();
+?>
+<div id="<?php echo __FILE__ ?>" class="<?php echo $widg['class'] ?>" >
+ <h3><?php echo __('ProductsLastAdded heading') ;?></h3>
+
+<table class="dataTableBase">
+ <tr>
+ <th><?php echo __('ProductsLastAdded box reference'); ?></th>
+ <th><?php echo __('ProductsLastAdded box name'); ?></th>
+ <th><?php echo __('ProductsLastAdded box date'); ?></th>
+ <th><?php echo __('ProductsLastAdded box status'); ?></th>
+ </tr>
+ <?php foreach($res as $row) : ?>
+ <tr>
+ <td class="tcenter"><strong><a href="<?php echo tep_href_link(FILENAME_PRODUCTS, 'pID='.$row['products_id'].'&action=edit') ?>"><?php echo $row['products_id'] ?></strong></td>
+ <td style="width:200px;"><?php echo $row['products_name'] ?></td>
+ <td class="tcenter"><?php echo tep_date_short($row['products_date_added']) ?></td>
+ <td class="tcenter"><?php echo $row['products_status'] ?></td>
+ </tr>
+ <?php endforeach; ?>
+</table>
+
+</div>
\ No newline at end of file
Added: trunk/catalog/admin/includes/widget/ProductsLastModified.php
===================================================================
--- trunk/catalog/admin/includes/widget/ProductsLastModified.php (rev 0)
+++ trunk/catalog/admin/includes/widget/ProductsLastModified.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -0,0 +1,42 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 0203/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+global $languages_id;
+
+$DB=Database::getInstance();
+$_query=$DB->query("SELECT distinct p.*,pd.products_name FROM " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd WHERE p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' ORDER BY p.products_last_modified DESC LIMIT 7");
+
+
+if( !$_query->__get('numRows') )
+ return false;
+
+$res = $_query->fetchAllAssoc();
+?>
+<div id="<?php echo __FILE__ ?>" class="<?php echo $widg['class'] ?>" >
+ <h3><?php echo __('ProductsLastModified heading');?></h3>
+
+<table class="dataTableBase">
+ <tr>
+ <th><?php echo __('ProductsLastModified box reference'); ?></th>
+ <th><?php echo __('ProductsLastModified box name'); ?></th>
+ <th><?php echo __('ProductsLastModified box date'); ?></th>
+ <th><?php echo __('ProductsLastModified box status'); ?></th>
+ </tr>
+ <?php foreach($res as $row) : ?>
+ <tr>
+ <td class="tcenter"><strong><a href="<?php echo tep_href_link(FILENAME_PRODUCTS, 'pID='.$row['products_id'].'&action=edit') ?>"><?php echo $row['products_id'] ?></strong></td>
+ <td style="width:200px;"><?php echo $row['products_name'] ?></td>
+ <td class="tcenter"><?php echo tep_date_short($row['products_last_modified']) ?></td>
+ <td><?php echo $row['products_status'] ?></td>
+ </tr>
+ <?php endforeach; ?>
+</table>
+
+</div>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/widget/homeStock.php
===================================================================
--- trunk/catalog/admin/includes/widget/homeStock.php 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/admin/includes/widget/homeStock.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -4,7 +4,7 @@
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 06/01/12, 11:36
+ @date 0203/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -21,17 +21,26 @@
return false;
?>
<div id="homeStock" class="<?php echo $widg['class'] ?>">
- <h3><a href="<?php echo tep_href_link(FILENAME_STATS,'module=stats_low_stock_attrib') ?>"><?php echo __('heading stock') ;?></a></h3>
+ <h3><a href="<?php echo tep_href_link(FILENAME_STATS,'module=stats_low_stock_attrib') ?>"><?php printf(__('heading stock %s'), count($l)) ;?></a></h3>
- <ul>
- <?php foreach(@$l as $p) : ?>
- <?php if(isset($p['option']) && is_array($p['option'])) { ?>
- <li><?php echo htmlspecialchars($p['products_name'].' '.implode(' ,',$p['option'])) ;?> <strong> <?php echo 'x '.$p['option_stock'] ?> </strong> </li>
- <?php } else { ?>
- <li><?php echo htmlspecialchars($p['products_name']) ;?> <strong> <?php echo 'x '.$p['stock'] ?> </strong></li>
- <?php } ?>
- <?php if($i++ > 8) {echo '....'; break;} endforeach; ?>
- </ul>
+ <table class="dataTableBase">
+ <tr>
+ <th><?php echo __('homeStock box reference'); ?></th>
+ <th><?php echo __('homeStock box name'); ?></th>
+ <th><?php echo __('homeStock box stock'); ?></th>
+ </tr>
+ <?php $i = 0; foreach($l as $p) : $i++; if($i>7) break; ?>
+ <tr>
+ <td class="tcenter"><strong><a href="<?php echo tep_href_link(FILENAME_PRODUCTS, 'pID='.$p['products_id'].'&action=edit') ?>"><?php echo $p['products_id'] ?></strong></td>
+ <?php if(isset($p['option']) && is_array($p['option'])) : ?>
+ <td style="width:200px;"><?php echo htmlspecialchars($p['products_name'].' '.implode(' ,',$p['option'])) ?></td>
+ <td><?php echo $p['option_stock'] ?></td>
+ <?php else : ?>
+ <td style="width:200px;"><?php echo htmlspecialchars($p['products_name']) ?></td>
+ <td class="tcenter"><?php echo $p['stock'] ?></td>
+ <?php endif; ?>
+ </tr>
+ <?php endforeach; ?>
+ </table>
- <div class="separator"></div>
</div>
Modified: trunk/catalog/admin/includes/widget/orderLastmodified.php
===================================================================
--- trunk/catalog/admin/includes/widget/orderLastmodified.php 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/admin/includes/widget/orderLastmodified.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -1,21 +1,27 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 01/11/11, 20:02
+ @date 0203/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
$_query = tep_db_query("SELECT o.*, status_name FROM " . TABLE_ORDERS . " o LEFT JOIN " . TABLE_STATUS . " s ON(s.status_id=o.orders_status AND status_type='orders' AND language_id = '" . $languages_id . "') ORDER BY last_modified DESC LIMIT 5");
+
+if( !$_query->__get('numRows') )
+ return false;
+
+$datadocs=new DatasFiles;
?>
<div id="orderLastmodified" class="<?php echo $widg['class'] ?>">
<h3><?php echo __('orderLastmodified box title'); ?></h3>
<table class="dataTableBase">
<tr>
<th><?php echo __('orderLastmodified box reference'); ?></th>
+ <th><?php echo __('orderLastmodified box docs'); ?></th>
<th><?php echo __('orderLastmodified box customers'); ?></th>
<th><?php echo __('orderLastmodified box date'); ?></th>
<th><?php echo __('orderLastmodified box status'); ?></th>
@@ -23,6 +29,11 @@
<?php foreach($_query->fetchAllAssoc() as $row) : ?>
<tr>
<td><strong><a href="<?php echo tep_href_link(FILENAME_ORDERS, 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['orders_prefix'].$row['orders_id'] ?></strong></td>
+ <td>
+ <?php if(( $filepath=$datadocs->GetDoc('packingslip', $row['orders_id'] )) && file_exists($filepath)): ?>
+ <a href="<?php echo tep_href_link('document.php', 'mod=packingslip&id='. $row['orders_id']) ?>"><?php echo basename($filepath) ?></a>
+ <?php endif; ?>
+ </td>
<td style="width:200px;"><?php echo tep_customers_row_action($row['customers_id'], array()) ?></td>
<td><?php echo tep_date_short($row['last_modified']) ?></td>
<td><?php echo $row['status_name'] ?></td>
Modified: trunk/catalog/admin/includes/widget/orderLastnews.php
===================================================================
--- trunk/catalog/admin/includes/widget/orderLastnews.php 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/admin/includes/widget/orderLastnews.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -1,21 +1,27 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 01/11/11, 20:02
+ @date 0203/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
$_query = tep_db_query("SELECT o.*, status_name FROM " . TABLE_ORDERS . " o LEFT JOIN " . TABLE_STATUS . " s ON(s.status_id=o.orders_status AND status_type='orders' AND language_id = '" . $languages_id . "') ORDER BY date_purchased DESC LIMIT 5");
+
+if( !$_query->__get('numRows') )
+ return false;
+
+$datadocs=new DatasFiles;
?>
<div id="orderLastnews" class="<?php echo $widg['class'] ?>">
<h3><?php echo __('orderLastnews box title'); ?></h3>
<table class="dataTableBase">
<tr>
<th><?php echo __('orderLastnews box reference'); ?></th>
+ <th><?php echo __('orderLastnews box docs'); ?></th>
<th><?php echo __('orderLastnews box customers'); ?></th>
<th><?php echo __('orderLastnews box date'); ?></th>
<th><?php echo __('orderLastnews box status'); ?></th>
@@ -23,6 +29,11 @@
<?php foreach($_query->fetchAllAssoc() as $row) : ?>
<tr>
<td><strong><a href="<?php echo tep_href_link(FILENAME_ORDERS, 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['orders_prefix'].$row['orders_id'] ?></strong></td>
+ <td>
+ <?php if(( $filepath=$datadocs->GetDoc('packingslip', $row['orders_id'] )) && file_exists($filepath)): ?>
+ <a href="<?php echo tep_href_link('document.php', 'mod=packingslip&id='. $row['orders_id']) ?>"><?php echo basename($filepath) ?></a>
+ <?php endif; ?>
+ </td>
<td style="width:200px;"><?php echo tep_customers_row_action($row['customers_id'], array()) ?></td>
<td><?php echo tep_date_short($row['date_purchased']) ?></td>
<td><?php echo $row['status_name'] ?></td>
Added: trunk/catalog/admin/includes/widget/orderLastservice.php
===================================================================
--- trunk/catalog/admin/includes/widget/orderLastservice.php (rev 0)
+++ trunk/catalog/admin/includes/widget/orderLastservice.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -0,0 +1,41 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 0203/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+if(!defined('TABLE_SERVICES'))
+ return false;
+
+$_query = tep_db_query("SELECT s.*, s.row_id as service_id FROM " . TABLE_SERVICES . " s JOIN " . TABLE_ORDERS . " o ON(s.orders_id=o.orders_id) ORDER BY date_added DESC LIMIT 5");
+
+if( !$_query->__get('numRows') )
+ return false;
+
+$datadocs=new DatasFiles;
+?>
+<div id="orderLastservice" class="<?php echo $widg['class'] ?>">
+<h3><?php echo __('orderLastservice box title'); ?></h3>
+<table class="dataTableBase">
+ <tr>
+ <th><?php echo __('orderLastservice box reference'); ?></th>
+ <th><?php echo __('orderLastservice box customers'); ?></th>
+ <th><?php echo __('orderLastservice box date'); ?></th>
+ <th><?php echo __('orderLastservice box date start'); ?></th>
+ <th><?php echo __('orderLastservice box status'); ?></th>
+ </tr>
+ <?php foreach($_query->fetchAllAssoc() as $row) : ?>
+ <tr>
+ <td><strong><a href="<?php echo tep_href_link(FILENAME_ORDERS, 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['service_id'] ?></strong></td>
+ <td style="width:200px;"><?php echo tep_customers_row_action($row['customers_id'], array()) ?></td>
+ <td><?php echo tep_date_short($row['date_added']) ?></td>
+ <td><?php echo tep_date_short($row['date_start']) ?></td>
+ <td><?php echo $row['status'] ?></td>
+ </tr>
+ <?php endforeach; ?>
+</table>
+</div>
\ No newline at end of file
Added: trunk/catalog/admin/includes/widget/orderLastshipp.php
===================================================================
--- trunk/catalog/admin/includes/widget/orderLastshipp.php (rev 0)
+++ trunk/catalog/admin/includes/widget/orderLastshipp.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -0,0 +1,45 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 0203/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+
+if(!defined('TABLE_SERVICES'))
+ return false;
+$_query = tep_db_query("SELECT o.*, s.*, s.row_id as shipping_id FROM " . TABLE_ORDERS . " o JOIN " . TABLE_SHIPPING . " s ON(s.orders_id=o.orders_id) ORDER BY date_expedition DESC LIMIT 5");
+
+if( !$_query->__get('numRows') )
+ return false;
+
+$datadocs=new DatasFiles;
+?>
+<div id="orderLastshipp" class="<?php echo $widg['class'] ?>">
+<h3><?php echo __('orderLastshipp box title'); ?></h3>
+<table class="dataTableBase">
+ <tr>
+ <th><?php echo __('orderLastshipp box reference'); ?></th>
+ <th><?php echo __('orderLastshipp box docs'); ?></th>
+ <th><?php echo __('orderLastshipp box customers'); ?></th>
+ <th><?php echo __('orderLastshipp box date'); ?></th>
+ <th><?php echo __('orderLastshipp box status'); ?></th>
+ </tr>
+ <?php foreach($_query->fetchAllAssoc() as $row) : ?>
+ <tr>
+ <td class="tcenter"><strong><a href="<?php echo tep_href_link(FILENAME_ORDERS, 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['shipping_id'] ?></strong></td>
+ <td>
+ <?php if(( $filepath=$datadocs->GetDoc('delivery', $row['shipping_id'] )) && file_exists($filepath)): ?>
+ <a href="<?php echo tep_href_link('document.php', 'mod=delivery&id='. $row['shipping_id']) ?>"><?php echo basename($filepath) ?></a>
+ <?php endif; ?>
+ </td>
+ <td style="width:200px;"><?php echo tep_customers_row_action($row['customers_id'], array()) ?></td>
+ <td><?php echo tep_date_short($row['date_expedition']) ?></td>
+ <td><?php //echo $row['status_name'] ?></td>
+ </tr>
+ <?php endforeach; ?>
+</table>
+</div>
\ No newline at end of file
Modified: trunk/catalog/common/classes/DatasFiles.php
===================================================================
--- trunk/catalog/common/classes/DatasFiles.php 2012-03-02 22:31:47 UTC (rev 4056)
+++ trunk/catalog/common/classes/DatasFiles.php 2012-03-03 07:57:10 UTC (rev 4057)
@@ -1,9 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 19/09/11, 11:40
+ @date 0203/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class DatasFiles
@@ -42,12 +43,10 @@
Class DatasFiles{
- static public $DataDoc = 'docs/';
+ static public $DataDoc ='';
-
-
function __construct(){
- self::$DataDoc = DIR_FS_ROOT_DOCS . self::$DataDoc ;
+ if(empty(self::$DataDoc)) self::$DataDoc = DIR_FS_ROOT_DOCS . 'docs/';
}
@@ -214,6 +213,7 @@
$pathid=self::PathForId($id);
$type=self::SpecificType(self::ConvertType($type));
+
$path = self::InitFolder($type->folder);
if(!file_exists($path.$pathid))
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-02 22:31:54
|
Revision: 4056
http://oscss.svn.sourceforge.net/oscss/?rev=4056&view=rev
Author: oscim
Date: 2012-03-02 22:31:47 +0000 (Fri, 02 Mar 2012)
Log Message:
-----------
correction erreur notice php
Modified Paths:
--------------
trunk/catalog/admin/includes/gabarit/customers/display_view.inline.gab
trunk/catalog/admin/includes/modules/pages/products.php
trunk/catalog/common/classes/seo_url.php
trunk/catalog/includes/classes/drivers/data/product.php
Modified: trunk/catalog/admin/includes/gabarit/customers/display_view.inline.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/customers/display_view.inline.gab 2012-03-02 17:40:31 UTC (rev 4055)
+++ trunk/catalog/admin/includes/gabarit/customers/display_view.inline.gab 2012-03-02 22:31:47 UTC (rev 4056)
@@ -1,15 +1,16 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 07/02/11, 08:52
+ @version 2.1.1
+ @date 02/02/2012, 08:52
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
$contents=array();
global $currencies;
+
?>
<tr>
<td>
@@ -37,7 +38,11 @@
</li>
<li>
<span class="label text"><?php echo __('text info lang customers') ?> </span>
- <span class="input text"> <?php echo customers::$cInfo->customers_language ?></span>
+ <span class="input text">
+ <?php foreach (tep_get_languages() as $row) { if(customers::$cInfo->customers_language == $row['id']) ?>
+ <?php echo tep_language_image( $row['directory'] . '/images/' . $row['image'], $row['name']) . ' '.$row['name'] ?>
+ <?php } ?>
+ </span>
</li>
</ul>
</div>
Modified: trunk/catalog/admin/includes/modules/pages/products.php
===================================================================
--- trunk/catalog/admin/includes/modules/pages/products.php 2012-03-02 17:40:31 UTC (rev 4055)
+++ trunk/catalog/admin/includes/modules/pages/products.php 2012-03-02 22:31:47 UTC (rev 4056)
@@ -4,7 +4,7 @@
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 01/01/12, 09:44
+ @date 03/03/12, 09:44
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -139,29 +139,6 @@
self::$action=$actionss;
$DB=Database::getInstance();
- // begin Extra Product Fields
- $epf_query = $DB->query("select e.epf_id, e.epf_uses_value_list, e.epf_show_parent_chain, e.epf_size, l.epf_label, l.languages_id, l.epf_active_for_language from " . TABLE_PRODUCTS_EXTRA_FIELDS . " e join " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " l where e.epf_status and (e.epf_id = l.epf_id) order by e.epf_order");
- $epf = array();
- $xfields = array();
- while ($e = tep_db_fetch_array($epf_query)) { // retrieve all active extra fields for all languages
- $field = 'extra_value' . ($e['epf_uses_value_list'] ? '_id' : '') . $e['epf_id'];
- $epf[] = array('id' => $e['epf_id'],
- 'label' => $e['epf_label'],
- 'uses_list' => $e['epf_uses_value_list'],
- 'show_chain' => $e['epf_show_parent_chain'],
- 'size' => $e['epf_size'],
- 'language' => $e['languages_id'],
- 'language_active' => $e['epf_active_for_language'],
- 'field' => $field);
- if (!in_array( $field, $xfields))
- $xfields[] = $field; // build list of distinct fields
- }
- // end Extra Product Fields
-
-
-
-
-
self::$actions['action'] = self::$action;
self::$actions['display_file']='';
self::$actions['action_class']=(isset($_GET['action_class']))? $_GET['action_class'] : '';
Modified: trunk/catalog/common/classes/seo_url.php
===================================================================
--- trunk/catalog/common/classes/seo_url.php 2012-03-02 17:40:31 UTC (rev 4055)
+++ trunk/catalog/common/classes/seo_url.php 2012-03-02 22:31:47 UTC (rev 4056)
@@ -484,7 +484,7 @@
if($p2[0] =='d' && substr($p2[1],-3) =='php')
$p2[1] = substr($p2[1],0,-4);
- $p3[$p2[0]]=$p2[1];
+ $p3[$p2[0]]=(isset($p2[1])? $p2[1] : '' );
}
@@ -502,8 +502,9 @@
switch ($key){
- case (in_array($key, $check0)):
+ case (in_array((string)$key, (array)$check0)):
$key = $this->reg_anchors[$key];
+
case (in_array($key, $check)):
$function = 'GetName_'.$key;
@@ -519,7 +520,7 @@
$this->ValidateName($url, $arflip[$key], $value, $connection, $separator);
}
- break;
+ break;
default:
$container[$key] = @$value;
Modified: trunk/catalog/includes/classes/drivers/data/product.php
===================================================================
--- trunk/catalog/includes/classes/drivers/data/product.php 2012-03-02 17:40:31 UTC (rev 4055)
+++ trunk/catalog/includes/classes/drivers/data/product.php 2012-03-02 22:31:47 UTC (rev 4056)
@@ -404,6 +404,7 @@
public static function GetEFValue($epfid,$values, $languages_id, $separator = ', '){
$DB=Database::getInstance();
$val = '';
+ $s='';
$a = explode(',',$values);
foreach($a as $r)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-02 17:40:41
|
Revision: 4055
http://oscss.svn.sourceforge.net/oscss/?rev=4055&view=rev
Author: oscim
Date: 2012-03-02 17:40:31 +0000 (Fri, 02 Mar 2012)
Log Message:
-----------
Ajout de nombreux widget et finition des tableau de bord
Complement des fichiers de langues incomplets
correction coquille php/html/css
normalisation du code
mise a niveau de dashboard
Modified Paths:
--------------
trunk/catalog/Documents/admin/data/dashboard.xml
trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php
trunk/catalog/admin/includes/classes/customerUtility.php
trunk/catalog/admin/includes/database_tables.php
trunk/catalog/admin/includes/filenames.php
trunk/catalog/admin/includes/gabarit/newsletters/display_view.edit.gab
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/index.txt
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/newsletters.txt
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/newslettersModeles.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/homeStats.txt
trunk/catalog/admin/includes/modules/pages/adminAccount.php
trunk/catalog/admin/includes/modules/pages/newsletters.php
trunk/catalog/admin/includes/modules/pages/newslettersModeles.php
trunk/catalog/admin/includes/template/oscss/stylesheet-1.css
trunk/catalog/includes/classes/checkout_process.php
Added Paths:
-----------
trunk/catalog/admin/includes/gabarit/adminAccount/
trunk/catalog/admin/includes/gabarit/adminAccount/display_view.page.gab
trunk/catalog/admin/includes/languages/fr_FR/widget/AdminGroupsNew.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/AdminUsersModified.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/AdminUsersNew.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/ContentLastModified.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/ContentLastNew.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/CustomerLastModified.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/CustomerLastNew.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersLastModified.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersLastNew.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersModelesLastModified.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersModelesLastNew.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersWizzard.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastinvoice.txt
trunk/catalog/admin/includes/widget/AdminGroupsNew.php
trunk/catalog/admin/includes/widget/AdminUsersModified.php
trunk/catalog/admin/includes/widget/AdminUsersNew.php
trunk/catalog/admin/includes/widget/ContentLastModified.php
trunk/catalog/admin/includes/widget/ContentLastNew.php
trunk/catalog/admin/includes/widget/CustomerLastModified.php
trunk/catalog/admin/includes/widget/CustomerLastNew.php
trunk/catalog/admin/includes/widget/NewslettersLastModified.php
trunk/catalog/admin/includes/widget/NewslettersLastNew.php
trunk/catalog/admin/includes/widget/NewslettersModelesLastModified.php
trunk/catalog/admin/includes/widget/NewslettersModelesLastNew.php
trunk/catalog/admin/includes/widget/NewslettersWizzard.php
trunk/catalog/admin/includes/widget/orderLastinvoice.php
Removed Paths:
-------------
trunk/catalog/admin/includes/gabarit/adminAccount.page.gab
Modified: trunk/catalog/Documents/admin/data/dashboard.xml
===================================================================
--- trunk/catalog/Documents/admin/data/dashboard.xml 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/Documents/admin/data/dashboard.xml 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,5 +1,17 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<root>
+
+ <admin>
+ <left>
+ <widget>AdminUsersNew</widget>
+ <widget>AdminUsersModified</widget>
+ </left>
+ <right>
+ <widget>AdminGroupsNew</widget>
+ <widget>AdminGroupsModified</widget>
+ </right>
+ </admin>
+
<home>
<left>
<widget>Notification</widget>
@@ -22,52 +34,79 @@
<catalog>
<left>
<widget>homeStock</widget>
- <widget>ProductsExpected</widget>
+ <widget>ProductsExpected</widget>
+
</left>
<right>
- <widget class="graph" querystring="Sales">salesStats</widget>
+
+ <widget>ProductsLastAdded</widget>
+
+ <widget>ProductsLastModified</widget>
</right>
</catalog>
<cms>
<left>
- <widget>quickview</widget>
+ <widget>ContentLastNew</widget>
+ <widget>ContentLastModified</widget>
</left>
<right>
-<!-- <widget>salesStats</widget> -->
+ <widget>quickview</widget>
</right>
</cms>
<commercial>
<left>
-<!-- <widget>homeStock</widget> -->
+ <widget>NewslettersWizzard</widget>
+ <widget>NewslettersLastSend</widget>
</left>
<right>
<!-- <widget>salesStats</widget> -->
</right>
</commercial>
+
+ <customers>
+ <left>
+<!-- <widget>orderStats</widget> -->
+<!-- <widget>customerStats</widget> -->
+ <widget>CustomerLastNew</widget>
+ <widget>CustomerLastModified</widget>
+ </left>
+ <right>
+ <widget class="graph" querystring="NewCustomers">NewCustomersStats</widget>
+<!-- <widget class="graph" querystring="Sales">salesStats</widget> -->
+ </right>
+ </customers>
+
+
<orders>
<left>
<widget>orderLastnews</widget>
- <widget>orderStats</widget>
+ <widget>orderLastshipp</widget>
+ <widget>orderLastinvoice</widget>
+ <widget>orderStats</widget>
</left>
<right>
+ <widget class="graph" querystring="Sales">salesStats</widget>
<widget>orderLastmodified</widget>
+ <widget>orderLastservice</widget>
+
</right>
</orders>
-
- <customers>
+ <mail>
<left>
- <widget>orderStats</widget>
- <widget>customerStats</widget>
+ <widget>NewslettersWizzard</widget>
+ <widget>NewslettersLastSend</widget>
+ <widget>NewslettersLastNew</widget>
+ <widget>NewslettersLastModified</widget>
</left>
<right>
- <widget class="graph" querystring="NewCustomers">NewCustomersStats</widget>
- <widget class="graph" querystring="Sales">salesStats</widget>
+ <widget>NewslettersModelesLastNew</widget>
+ <widget>NewslettersModelesLastModified</widget>
</right>
- </customers>
+ </mail>
<tools>
<left>
@@ -97,6 +136,17 @@
</right>
</configuration>
+ <system>
+ <left>
+ <widget>brief_config</widget>
+ <widget>homeStats</widget>
+ </left>
+ <right>
+ <widget>currencies_update_server</widget>
+ <widget>info_connexion</widget>
+ </right>
+ </system>
+
<config_100>
<left>
<widget>HelpConfig</widget>
Modified: trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php
===================================================================
--- trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php 2012-03-02 17:40:31 UTC (rev 4055)
@@ -45,7 +45,7 @@
$pdf->SetXY(155,$le_Y);
//Draw Order Number Text
$temp = tep_correct_entitie_put_pdf(__('iv print packingslip ordernr'));
- $pdf->Cell(48,$hauteur_block, 'FA-'.$order->info['orders_prefix'].$order->info['orders_id'], 0, 0,"C");
+ $pdf->Cell(48,$hauteur_block, 'FA-'.$order->info['orders_prefix'].$order->info['facture_id'], 0, 0,"C");
$pdf->SetFont($pdf->font,'BI',10);
$le_Y=($le_Y+$hauteur_block);
Modified: trunk/catalog/admin/includes/classes/customerUtility.php
===================================================================
--- trunk/catalog/admin/includes/classes/customerUtility.php 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/classes/customerUtility.php 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,10 +1,10 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 18/11/11, 13:41
+ @date 02/03/2012, 13:41
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class customerUtility
@@ -177,9 +177,9 @@
$lg = $row;
$nom= /*tep_image(DIR_WS_CATALOG_LANGUAGES . $lg['directory'] . '/images/' . $lg['image'], $lg['name']) .' ' . */$customers_values['customers_firstname'] . ' ' . $customers_values['customers_lastname'];
- $action= '<a href="'.tep_mailto($customers_values['customers_email_address'],$origin).'">'.tep_image(DIR_WS_ICONS.'icon_custom_mail.png',TXT_MINIF_EMAIL).'</a> '
- .'<a href="'.tep_href_link(FILENAME_CUSTOMERS,'cID=' . $customers_id. '&origin='.urlencode($origin) ).'&action=edit">'.tep_image(DIR_WS_ICONS.'icon_custom_edit.png',TXT_MINIF_DETAIL).'</a> '
- .'<a href="'.tep_href_link(FILENAME_STATS,'module=stats_customers').'">'.tep_image(DIR_WS_ICONS.'icon_stats.png',TXT_MINIF_STATS_BUY).'</a> '
+ $action= '<a href="'.tep_mailto($customers_values['customers_email_address'],$origin).'">'.tep_image(DIR_WS_ICONS.'icon_custom_mail.png',TXT_MINIF_EMAIL, 12,12).'</a> '
+ .'<a href="'.tep_href_link(FILENAME_CUSTOMERS,'cID=' . $customers_id. '&origin='.urlencode($origin) ).'&action=edit">'.tep_image(DIR_WS_ICONS.'icon_custom_edit.png',TXT_MINIF_DETAIL, 12,12).'</a> '
+ .'<a href="'.tep_href_link(FILENAME_STATS,'module=stats_customers').'">'.tep_image(DIR_WS_ICONS.'icon_stats.png',TXT_MINIF_STATS_BUY , 12,12).'</a> '
.$action_supp;
return sprintf($format,$nom, $action);
}
Modified: trunk/catalog/admin/includes/database_tables.php
===================================================================
--- trunk/catalog/admin/includes/database_tables.php 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/database_tables.php 2012-03-02 17:40:31 UTC (rev 4055)
@@ -11,7 +11,8 @@
## Admin begin
## Specific table for manage BO
- define('TABLE_ADMIN', DB_TABLE_PREFIX . 'admin_users');
+ define('TABLE_ADMIN', DB_TABLE_PREFIX . 'admin_users'); /// TODO obsolete
+ define('TABLE_ADMIN_USERS', DB_TABLE_PREFIX . 'admin_users');
define('TABLE_ADMIN_GROUPS', DB_TABLE_PREFIX . 'admin_groups');
define('TABLE_ADMIN_NOTIFICATION', DB_TABLE_PREFIX.'admin_notification');
define('TABLE_CIP', DB_TABLE_PREFIX . 'admin_cip');
Modified: trunk/catalog/admin/includes/filenames.php
===================================================================
--- trunk/catalog/admin/includes/filenames.php 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/filenames.php 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 11/02/11, 09:48
+ @version 2.1.1
+ @date 02/03/2012, 09:48
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -44,7 +44,10 @@
define('FILENAME_MAIL', 'mail.php');
define('FILENAME_MODULES', 'modules.php');
define('FILENAME_NAVIGATION_LINKS', 'navigation_links.php');
+
define('FILENAME_NEWSLETTERS', 'newsletters.php');
+define('FILENAME_NEWSLETTERS_MODELES', 'newslettersModeles.php');
+
define('FILENAME_ORDERS', 'orders.php');
define('FILENAME_PACKAGE', 'package.php');
define('FILENAME_PASSWORD_FORGOTTEN', 'password_forgotten.php');
Copied: trunk/catalog/admin/includes/gabarit/adminAccount/display_view.page.gab (from rev 4054, trunk/catalog/admin/includes/gabarit/adminAccount.page.gab)
===================================================================
--- trunk/catalog/admin/includes/gabarit/adminAccount/display_view.page.gab (rev 0)
+++ trunk/catalog/admin/includes/gabarit/adminAccount/display_view.page.gab 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,91 @@
+<?php
+/**
+ @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 28/12/11, 18:20
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+ @brief content admin account detail
+*/
+?>
+<h3><?php echo __('heading title'); ?></h3>
+<div class="block_form">
+ <div id="tabs">
+ <ul>
+ <li><a href="#tabs-1"><?php echo __('tab account generic'); ?></a></li>
+ <li><a href="#tabs-2"><?php echo __('tab account apparence'); ?></a></li>
+ <li><a href="#tabs-8"><?php echo __('tab account tools links'); ?></a></li>
+ <li><a href="#tabs-9"><?php echo __('tab account edit'); ?></a></li>
+ </ul>
+
+
+ <div id="tabs-1" class="tabPage">
+ <div >
+ <?php
+ if ((adminAccount::$myAccount->admin_lognum <= 1) ) printf(__('text info intro default first time'), adminAccount::$myAccount->admin_firstname);
+
+ /* Liens d'initalisation du menu */
+ echo '<br /><br />'.__('init menu admin').' <a class="button" href="'.tep_href_link(FILENAME_ADMIN_ACCOUNT,'action=init_menu').'">'.__('image init menu').'</a><br /><br />';
+ ?>
+
+ <h4><?php echo __(' Choix du la langue votre environement');?></h4>
+ <?php echo tep_draw_form('languages', adminAccount::FILENAME, '', 'get') ?>
+ <p><?php echo tep_draw_pull_down_menu('language', language::ArrayPullDown(false, false), language::LangueSelected(), 'onchange="this.form.submit();"')?></p>
+ </form>
+
+
+ <h4><?php echo __('text heading cookie');?></h4>
+ <p><?php echo __('text detail cookie');?></p>
+
+ <?php echo tep_draw_form('cookie_correps', adminAccount::FILENAME, 'action=cookie', 'post') ?>
+ <p><?php echo tep_image_submit('', ((adminAccount::$myAccount->cookieCorress)? __('cookie inactive') : __('cookie active')) ) ?></p>
+ </form>
+
+ <div class="separator"></div>
+ </div>
+ </div>
+
+ <div id="tabs-2" class="tabPage">
+ <?php echo tep_draw_form('menutheme', adminAccount::FILENAME, '', 'get', ' ') ?>
+ <fieldset class="block_field">
+ <legend><?php echo __('choix du theme de votre environement');?></legend>
+ <?php foreach(adminAccount::theme_xml('') as $theme) :?>
+ <ul class="inline">
+ <li style="display:block"><?php echo unhtmlentities($theme->picture) ?></li>
+ <li><?php echo unhtmlentities($theme->statut) ?></li>
+ <li><?php echo unhtmlentities($theme->id) ?></li>
+ </ul>
+ <?php endforeach; ?>
+ </fieldset>
+ </form>
+ <div class="separator"></div>
+ </div>
+ <div id="tabs-8" class="tabPage">
+ <div class="block_field">
+ <h4><?php echo __('heading tools links user') ?></h4>
+
+ <p class="block_input"><?php echo __('rss tools links user'); ?></p>
+ <ul class="block_input">
+ <?php foreach(scan(DIR_WS_INCLUDES.'rss/') as $item):
+ if(substr($item, -3) =='php') :
+ if( (_cst_bool('STOCK_CHECK') && preg_match("#(stock)#i", $item)) || !preg_match("#(stock)#i", $item) ): ?>
+ <li><a href="<?php echo tep_href_link('rss.php','box='.substr($item,0, -4)) ; ?>"> <?php echo tep_href_link('rss.php','box='.substr($item,0, -4)) ?></a></li>
+ <?php endif; ?>
+ <?php endif; endforeach; ?>
+ </ul>
+ <div class="separator"></div>
+ </div>
+ </div>
+
+ <div id="tabs-9" class="tabPage">
+ <?php echo adminAccount::get_right_bar() ?>
+ <div class="separator"></div>
+ </div>
+
+ </div>
+
+</div>
+
+
Deleted: trunk/catalog/admin/includes/gabarit/adminAccount.page.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/adminAccount.page.gab 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/gabarit/adminAccount.page.gab 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,91 +0,0 @@
-<?php
-/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
- @portion code Copyright (c) 2002 osCommerce
- @package osCSS-2 <www http://www.oscss.org>
- @version 2.1.1
- @date 28/12/11, 18:20
- @author oscim <mail aur...@os...> <www http://www.oscim.fr>
- @encode UTF-8
- @brief content admin account detail
-*/
-?>
-<h3><?php echo __('heading title'); ?></h3>
-<div class="block_form">
- <div id="tabs">
- <ul>
- <li><a href="#tabs-1"><?php echo __('tab account generic'); ?></a></li>
- <li><a href="#tabs-2"><?php echo __('tab account apparence'); ?></a></li>
- <li><a href="#tabs-8"><?php echo __('tab account tools links'); ?></a></li>
- <li><a href="#tabs-9"><?php echo __('tab account edit'); ?></a></li>
- </ul>
-
-
- <div id="tabs-1" class="tabPage">
- <div >
- <?php
- if ((adminAccount::$myAccount->admin_lognum <= 1) ) printf(__('text info intro default first time'), adminAccount::$myAccount->admin_firstname);
-
- /* Liens d'initalisation du menu */
- echo '<br /><br />'.__('init menu admin').' <a class="button" href="'.tep_href_link(FILENAME_ADMIN_ACCOUNT,'action=init_menu').'">'.__('image init menu').'</a><br /><br />';
- ?>
-
- <h4><?php echo __(' Choix du la langue votre environement');?></h4>
- <?php echo tep_draw_form('languages', adminAccount::FILENAME, '', 'get') ?>
- <p><?php echo tep_draw_pull_down_menu('language', language::ArrayPullDown(false, false), language::LangueSelected(), 'onchange="this.form.submit();"')?></p>
- </form>
-
-
- <h4><?php echo __('text heading cookie');?></h4>
- <p><?php echo __('text detail cookie');?></p>
-
- <?php echo tep_draw_form('cookie_correps', adminAccount::FILENAME, 'action=cookie', 'post') ?>
- <p><?php echo tep_image_submit('', ((adminAccount::$myAccount->cookieCorress)? __('cookie inactive') : __('cookie active')) ) ?></p>
- </form>
-
- <div class="separator"></div>
- </div>
- </div>
-
- <div id="tabs-2" class="tabPage">
- <?php echo tep_draw_form('menutheme', adminAccount::FILENAME, '', 'get', ' ') ?>
- <fieldset class="block_field">
- <legend><?php echo __('choix du theme de votre environement');?></legend>
- <?php foreach(adminAccount::theme_xml('') as $theme) :?>
- <ul class="inline">
- <li style="display:block"><?php echo unhtmlentities($theme->picture) ?></li>
- <li><?php echo unhtmlentities($theme->statut) ?></li>
- <li><?php echo unhtmlentities($theme->id) ?></li>
- </ul>
- <?php endforeach; ?>
- </fieldset>
- </form>
- <div class="separator"></div>
- </div>
- <div id="tabs-8" class="tabPage">
- <div class="block_field">
- <h4><?php echo __('heading tools links user') ?></h4>
-
- <p class="block_input"><?php echo __('rss tools links user'); ?></p>
- <ul class="block_input">
- <?php foreach(scan(DIR_WS_INCLUDES.'rss/') as $item):
- if(substr($item, -3) =='php') :
- if( (_cst_bool('STOCK_CHECK') && preg_match("#(stock)#i", $item)) || !preg_match("#(stock)#i", $item) ): ?>
- <li><a href="<?php echo tep_href_link('rss.php','box='.substr($item,0, -4)) ; ?>"> <?php echo tep_href_link('rss.php','box='.substr($item,0, -4)) ?></a></li>
- <?php endif; ?>
- <?php endif; endforeach; ?>
- </ul>
- <div class="separator"></div>
- </div>
- </div>
-
- <div id="tabs-9" class="tabPage">
- <?php echo adminAccount::get_right_bar() ?>
- <div class="separator"></div>
- </div>
-
- </div>
-
-</div>
-
-
Modified: trunk/catalog/admin/includes/gabarit/newsletters/display_view.edit.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/newsletters/display_view.edit.gab 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/gabarit/newsletters/display_view.edit.gab 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 20/03/11, 20:48
+ @version 2.1.1
+ @date 02/03/2012, 20:48
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -13,80 +13,81 @@
<h3><?php echo __('heading title') ?></h3>
<?php echo tep_draw_form('newsletter', newsletters::FILENAME, 'action='.((newsletters::$action == 'edit')?'update' : 'insert') , 'post' ); ?>
- <div class="box_left">
- <p><?php if (newsletters::$action == 'edit') echo tep_draw_hidden_field('newsletter_id', '', newsletters::$nID); ?></p>
- <div id="tabs">
- <ul>
- <li><a href="#tabs-1"><?php echo __('text tab content') ?></a></li>
- <li><a href="#tabs-2"><?php echo __('text tab module') ?></a></li>
- </ul>
+ <div class="box_left">
+ <p><?php if (newsletters::$action == 'edit') echo tep_draw_hidden_field('newsletter_id', '', newsletters::$nID); ?></p>
+ <div id="tabs">
+ <ul>
+ <li><a href="#tabs-1"><?php echo __('text tab content') ?></a></li>
+<!-- <li><a href="#tabs-2"><?php //echo __('text tab module') ?></a></li> -->
+ </ul>
- <div id="tabs-1">
- <fieldset class="block_field">
- <p class="block_input">
- <label for="p_format"><?php echo __('text newsletter format'); ?></label>
- <?php echo tep_draw_pull_down_menu('p_format', array(array('id'=>'HTML', 'text'=>'html'),array('id'=>'TEXT', 'text'=>'text')), (isset($_POST['customer']) ? $_POST['customer'] : ''));?><br />
- </p>
+ <div id="tabs-1">
+ <fieldset class="block_field">
+ <p class="block_input">
+ <label for="p_format"><?php echo __('text newsletter format'); ?></label>
+ <?php echo tep_draw_pull_down_menu('p_format', array(array('id'=>'HTML', 'text'=>'html'),array('id'=>'TEXT', 'text'=>'text')), (isset($_POST['customer']) ? $_POST['customer'] : ''));?><br />
+ </p>
- <p class="block_input">
- <label for="title" title="<?php echo __('text newsletter title help') ; ?>"> <?php echo __('text newsletter title') . tep_image(DIR_WS_ICONS.'icon_help.gif'); ?></label>
- <?php echo tep_draw_input_field('title', '', newsletters::$nInfo->title, '', true); ?>
- </p>
- <div class="block_input">
- <label for="content" title="<?php echo __('text newsletter content help') ; ?>" ><?php echo tep_image(DIR_WS_ICONS.'icon_help.gif');?></label>
- <?php echo $oscss->_call(BO_WISIWYG_SELECTED,'_draw','content','600','400',newsletters::$nInfo->content); ?>
- <div>
- </fieldset>
- <br style="clear:both" />
- </div>
+ <p class="block_input">
+ <label for="title" title="<?php echo __('text newsletter title help') ; ?>"> <?php echo __('text newsletter title') . tep_image(DIR_WS_ICONS.'icon_help.gif'); ?></label>
+ <?php echo tep_draw_input_field('title', '', newsletters::$nInfo->title, '', true); ?>
+ </p>
- <div id="tabs-2">
+ <div class="block_input">
+ <label for="content" title="<?php echo __('text newsletter content help') ; ?>" ><?php echo tep_image(DIR_WS_ICONS.'icon_help.gif');?></label>
+ <?php echo $oscss->_call(BO_WISIWYG_SELECTED,'_draw','content','600','400',newsletters::$nInfo->content); ?>
+ <div>
+ </fieldset>
+ <br style="clear:both" />
+ </div>
- <?php print_r(NewslettersChargeur:: $module); ?>
- </div>
- <br style="clear:both" />
- </div>
- </div>
+<!-- <div id="tabs-2">
+ <?php //print_r(NewslettersChargeur:: $module); ?>
+ </div>-->
+ <br style="clear:both" />
+ </div>
+ </div>
+
<div class="box_right">
<fieldset class="block_field">
<legend><?php echo __('text newsletter module'); ?></legend>
- <p class="block_input">
- <label for="module" title="<?php echo __('text newsletter module help') ; ?>" ><?php echo tep_image(DIR_WS_ICONS.'icon_help.gif'); ?> </label>
- <?php echo tep_draw_pull_down_menu('module', newsletters::list_module_newsletters(), newsletters::$nInfo->module); ?>
- </p>
+ <p class="block_input">
+ <label for="module" title="<?php echo __('text newsletter module help') ; ?>" ><?php echo tep_image(DIR_WS_ICONS.'icon_help.gif'); ?> </label>
+ <?php echo tep_draw_pull_down_menu('module', newsletters::list_module_newsletters(), newsletters::$nInfo->module); ?>
+ </p>
+ </fieldset>
+ <fieldset class="block_field">
+ <legend><?php echo __('text newsletter modele'); ?></legend>
+ <p class="block_input">
+ <label for="module" title="<?php echo __('text newsletter modele help') ; ?>" ><?php echo tep_image(DIR_WS_ICONS.'icon_help.gif'); ?> </label>
+ <?php echo tep_draw_pull_down_menu('modele_id', newsletters::list_modele_newsletters(), newsletters::$nInfo->modele_id); ?>
+ </p>
</fieldset>
- <fieldset class="block_field">
- <legend><?php echo __('text newsletter modele'); ?></legend>
- <p class="block_input">
- <label for="module" title="<?php echo __('text newsletter modele help') ; ?>" ><?php echo tep_image(DIR_WS_ICONS.'icon_help.gif'); ?> </label>
- <?php echo tep_draw_pull_down_menu('modele_id', newsletters::list_modele_newsletters(), newsletters::$nInfo->modele_id); ?>
- </p>
- </fieldset>
<fieldset class="block_field">
<legend><?php echo __('text newsletter replace'); ?></legend>
- <div class="block_input">
- <?php echo __('text newsletter replace in mail'); ?>
- <ul>
- <?php foreach(newsletters::$TagReplace as $type=>$list): ?>
- <li>
- <?php echo __('type tag text '.$type ) ?>
- <ul>
- <?php foreach($list as $tag): ?>
- <li><?php echo $tag .' : '.__('tag text '.$tag ) ?></li>
- <?php endforeach; ?>
- </ul>
- </li>
- <?php endforeach; ?>
- </ul>
- </div>
+ <div class="block_input">
+ <?php echo __('text newsletter replace in mail'); ?>
+ <ul>
+ <?php foreach(newsletters::$TagReplace as $type=>$list): ?>
+ <li>
+ <?php echo __('type tag text '.$type ) ?>
+ <ul>
+ <?php foreach($list as $tag): ?>
+ <li><?php echo $tag .' : '.__('tag text '.$tag ) ?></li>
+ <?php endforeach; ?>
+ </ul>
+ </li>
+ <?php endforeach; ?>
+ </ul>
+ </div>
</fieldset>
<div class="button_nav">
<?php echo ((newsletters::$action == 'new') ? tep_image_submit('button_save.gif', IMAGE_SAVE) : tep_image_submit('button_update.gif', IMAGE_UPDATE));
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/pages/index.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/pages/index.txt 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/pages/index.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,21 +1,25 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 25/10/11, 11:00
+ @date 02/03/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
$lang['heading title ']="Bienvenue sur osCSS" ;
$lang['heading title index']="Bienvenue sur osCSS" ;
$lang['heading title customers']="Aperçu clients et commandes" ;
-$lang['heading title catalog']="Aperçu des produits" ;
-$lang['heading title cms']="Aperçu des contenus" ;
-$lang['heading title commercial']="Aperçu" ;
+$lang['heading title catalog']="Tableau de bord des produits" ;
+$lang['heading title cms']="Tableau de bord de vos contenus" ;
+$lang['heading title commercial']="Tableau de bord commercial" ;
$lang['heading title tools']="Aperçu" ;
$lang['heading title modules']="Aperçu" ;
-$lang['heading title configuration']="Aperçu de la configuration" ;
+$lang['heading title configuration']="Tableau de bord de la configuration" ;
+$lang['heading title mail']="Tableau de bord campagne emailling" ;
+$lang['heading title orders']="Tableau de bord des commandes" ;
+$lang['heading title admin']="Tableau de bord des utilisateurs et groupes privés" ;
$lang['heading title config_100']="Configuration de l'apparence" ;
$lang['heading title config_110']="Configuration de base" ;
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/pages/newsletters.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/pages/newsletters.txt 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/pages/newsletters.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 23/03/11, 16:05
+ @version 2.1.1
+ @date 02/03/2012, 16:05
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -12,84 +12,86 @@
$lang['text info heading delete newsletters']="Suppression du bulletin d'informations" ;
/* Listing */
-$lang['table heading newsletters']="Bulletin d informations";
-$lang['table heading size']="Taille";
-$lang['table heading module']="Module";
-$lang['table heading sent']="Envoyée";
-$lang['table heading status']="Statut";
-$lang['table heading action']="Action";
-$lang['table heading nbr send']="Envoi";
-$lang['text newsletter format']="Format de l'Email";
-$lang['text newsletter module titre']="Type d'envoi";
-$lang['text newsletter module']="Module :";
-$lang['text newsletter module help']="Ce choix vous permet de définir le type de communication souhaité, un bulletin d'information d'ordre générale (newsletter), ou la communication sur un ou plusieurs produits ciblés (products notifications)";
-$lang['text newsletter title']="Sujet du bulletin d'informations : ";
-$lang['text newsletter title help']="Le sujet du mail";
-$lang['text newsletter content']="Contenu : ";
-$lang['text newsletter content help']="Vous pouvez utiliser les formats html ou texte. Si la boutique est réglée pour des Email au format texte, alors le contenu sera converti, si vous placez des images, assurez vous qu'elles soient accessibles d'internet";
-$lang['text newsletter date added']="Date d'ajout : ";
-$lang['text newsletter date sent']="Date d'envoi : ";
-$lang['text info delete intro']="Êtes-vous sûr de vouloir supprimer ce bulletin d'informations ?";
-$lang['text please wait']="Merci de patienter .. envois en cours ..<br /><br />Merci de ne pas interrompre ce traitement !";
-$lang['text finished sending emails']="Fini.. courrier électronique envoyé !";
-$lang['error newsletter title']="Erreur : Titre du bulletin d'informations requis";
-$lang['error newsletter module']="Erreur : Module bulletin d'informations requis";
-$lang['error remove unlocked newsletter']="Erreur : Merci de fermer le bulletin d'informations avant de le supprimer.";
-$lang['error edit unlocked newsletter']="Erreur : Merci de fermer le bulletin d'informations avant de l'éditer.";
-$lang['error send unlocked newsletter']="Erreur : Merci de fermer le bulletin d'informations avant de l'envoyer.";
+ $lang['table heading newsletters']="Bulletin d informations";
+ $lang['table heading size']="Taille";
+ $lang['table heading module']="Module";
+ $lang['table heading sent']="Envoyée";
+ $lang['table heading status']="Statut";
+ $lang['table heading action']="Action";
+ $lang['table heading nbr send']="Envoi";
+ $lang['text newsletter format']="Format de l'Email";
+ $lang['text newsletter module titre']="Type d'envoi";
+ $lang['text newsletter module']="Module :";
+ $lang['text newsletter module help']="Ce choix vous permet de définir le type de communication souhaité, un bulletin d'information d'ordre générale (newsletter), ou la communication sur un ou plusieurs produits ciblés (products notifications)";
+ $lang['text newsletter title']="Sujet du bulletin d'informations : ";
+ $lang['text newsletter title help']="Le sujet du mail";
+ $lang['text newsletter content']="Contenu : ";
+ $lang['text newsletter content help']="Vous pouvez utiliser les formats html ou texte. Si la boutique est réglée pour des Email au format texte, alors le contenu sera converti, si vous placez des images, assurez vous qu'elles soient accessibles d'internet";
+ $lang['text newsletter date added']="Date d'ajout : ";
+ $lang['text newsletter date sent']="Date d'envoi : ";
+ $lang['text info delete intro']="Êtes-vous sûr de vouloir supprimer ce bulletin d'informations ?";
+ $lang['text please wait']="Merci de patienter .. envois en cours ..\n\n Merci de ne pas interrompre ce traitement !";
+ $lang['text finished sending emails']="Fini.. courrier électronique envoyé !";
+ $lang['error newsletter title']="Erreur : Titre du bulletin d'informations requis";
+ $lang['error newsletter module']="Erreur : Module bulletin d'informations requis";
+ $lang['error remove unlocked newsletter']="Erreur : Merci de fermer le bulletin d'informations avant de le supprimer.";
+ $lang['error edit unlocked newsletter']="Erreur : Merci de fermer le bulletin d'informations avant de l'éditer.";
+ $lang['error send unlocked newsletter']="Erreur : Merci de fermer le bulletin d'informations avant de l'envoyer.";
/* inline */
-$lang['text info number send number count']="nbr envoyé / nbr d'envoi :";
-$lang['text inline newsletter opened']="nbr ouvert / nbr d'envoi :";
-$lang['text inline newsletter click']="nbr click / nbr d'envoi :";
-$lang['text inline newsletter view_online']="nbr ouvert en ligne / nbr ouvert :";
-$lang['text inline newsletter moyn opened']="Moyenne ouverture :";
-$lang['text inline newsletter moyn click']="Moyenne de click :";
-$lang['text inline newsletter moyn view_online']="Moyenne ouvert en ligne :";
+ $lang['text info number send number count']="nbr envoyé / nbr d'envoi :";
+ $lang['text inline newsletter opened']="nbr ouvert / nbr d'envoi :";
+ $lang['text inline newsletter click']="nbr click / nbr d'envoi :";
+ $lang['text inline newsletter view_online']="nbr ouvert en ligne / nbr ouvert :";
+ $lang['text inline newsletter moyn opened']="Moyenne ouverture :";
+ $lang['text inline newsletter moyn click']="Moyenne de click :";
+ $lang['text inline newsletter moyn view_online']="Moyenne ouvert en ligne :";
/* Edit */
-$lang['text newsletter replace']="Remplacement ";
-$lang['text newsletter replace in mail']="Vous pouver utiliser les mot clefs ci-dessous, ils seront remplacés par leur valeur";
-$lang['type tag text user']="les tags associé aux clients";
-$lang['tag text [GENDER]']="Le genre , (Mr/Mme)";
-$lang['tag text [LASTNAME]']="Le prenom";
-$lang['tag text [POSTNAME]']="Le nom";
-$lang['tag text [DATE_CREATED]']="date de creation du compte";
-$lang['tag text [LAST_LOGON]']="derniere connexion";
-$lang['tag text [FIDELITY_POINTS]']="Les points de cet uitlisateur";
+ $lang['text tab content']="Edition";
+ $lang['text tab module']="Apercu";
+ $lang['text newsletter replace']="Remplacement ";
+ $lang['text newsletter replace in mail']="Vous pouver utiliser les mot clefs ci-dessous, ils seront remplacés par leur valeur";
+ $lang['type tag text user']="les tags associé aux clients";
+ $lang['tag text [GENDER]']="Le genre , (Mr/Mme)";
+ $lang['tag text [LASTNAME]']="Le prenom";
+ $lang['tag text [POSTNAME]']="Le nom";
+ $lang['tag text [DATE_CREATED]']="date de creation du compte";
+ $lang['tag text [LAST_LOGON]']="derniere connexion";
+ $lang['tag text [FIDELITY_POINTS]']="Les points de cet uitlisateur";
/* Preview */
-$lang['text info preview newsletters']="Aperçu du bulletin";
+ $lang['text info preview newsletters']="Aperçu du bulletin";
/* Send */
-$lang['text info send newsletters']="Aperçu ";
-$lang['text titre info']="Resumé";
-$lang['text count customers']="nbr envoyé(s)/nbr d'envoi ";
-$lang['text bulletin numb']="Numéro:";
-$lang['text module']="Module: ";
-$lang['text titre mail']="Sujet: ";
-$lang['text titre view']="Aperçu du contenu : ";
+ $lang['text info send newsletters']="Aperçu ";
+ $lang['text titre info']="Resumé";
+ $lang['text count customers']="nbr envoyé(s)/nbr d'envoi ";
+ $lang['text bulletin numb']="Numéro:";
+ $lang['text module']="Module: ";
+ $lang['text titre mail']="Sujet: ";
+ $lang['text titre view']="Aperçu du contenu : ";
/* Sendtest */
-$lang['heading newsletter sendtest email']="Email(s) de test ";
-$lang['txt sendtest email']="Email séparé par des virgules. Les emails doivent représenter des Emails valides dans la table des clients";
+ $lang['heading newsletter sendtest email']="Email(s) de test ";
+ $lang['txt sendtest email']="Email séparé par des virgules. Les emails doivent représenter des Emails valides dans la table des clients";
-$lang['image new newsletter']="Créer un bulletin";
-$lang['image send']="Envoyer";
-$lang['image send test']="Envoi de test";
-$lang['image cancel']="retour";
-$lang['text info number send number count ']="Nombre d'envoi / nombre à envoyé";
+ $lang['image new newsletter']="Créer un bulletin";
+ $lang['image send']="Envoyer";
+ $lang['image send test']="Envoi de test";
+ $lang['image cancel']="retour";
+ $lang['text info number send number count ']="Nombre d'envoi / nombre à envoyé";
-$lang['text template']="Choix du gabarit";
-$lang['text tpl aucun']="aucun";
-$lang['err txt email off']="Le service est désactivé dans la configuration de votre boutique";
-$lang['err txt email txt strict']="Le service d'Email au format html est désactivé, tous les Emails seront envoyés au format texte";
+ $lang['text template']="Choix du gabarit";
+ $lang['text tpl aucun']="aucun";
+ $lang['err txt email off']="Le service est désactivé dans la configuration de votre boutique";
+ $lang['err txt email txt strict']="Le service d'Email au format html est désactivé, tous les Emails seront envoyés au format texte";
/* Generic in mail */
-$lang['text view online %s']="Si vous ne visualisez pas correctement cet Email <a href=\"%s\" >Cliquez ici</a>";
+ $lang['text view online %s']="Si vous ne visualisez pas correctement cet Email <a href=\"%s\" >Cliquez ici</a>";
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/pages/newslettersModeles.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/pages/newslettersModeles.txt 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/pages/newslettersModeles.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 23/03/11, 15:58
+ @version 2.1.1
+ @date 02/03/2012, 20:02
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -22,8 +22,8 @@
$lang['text newsletter module titre']="Type d'envoi" ;
$lang['text newsletter module']="Module :" ;
$lang['text newsletter module help']="Ce choix vous permet de définir le type de communication souhaité, un bulletin d'information d'ordre générale (newsletter), ou la communication sur un ou plusieurs produits ciblés (products notifications)" ;
-$lang['text newsletter title']="Sujet du bulletin d'informations : " ;
-$lang['text newsletter title help']="Le sujet du mail" ;
+$lang['text newsletter title']="Nom du modèle : " ;
+$lang['text newsletter title help']="Le nom sera utilisé a chque fois que vous devrez choisir un modèle. il est donc important que celui-ci soit explicite!" ;
$lang['text newsletter content']="Contenu : " ;
$lang['text newsletter content help']="Vous pouvez utiliser les formats html ou texte. Si la boutique est réglée pour des Email au format texte, alors le contenu sera converti, si vous placez des images, assurez vous qu'elles soient accessibles d'internet" ;
$lang['text newsletter date added']="Date d'ajout : " ;
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/AdminGroupsNew.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/AdminGroupsNew.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/AdminGroupsNew.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,17 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['AdminGroupsNew heading']="Groupes d'utilisateurs" ;
+
+$lang['AdminGroupsNew box reference']="Réf." ;
+$lang['AdminGroupsNew box title']="Nom" ;
+$lang['AdminGroupsNew box nbr_users']="utilisateurs" ;
+
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/AdminUsersModified.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/AdminUsersModified.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/AdminUsersModified.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,18 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['AdminUsersModified heading']="Derniers utilisateurs modifiés" ;
+
+$lang['AdminUsersModified box reference']="Réf." ;
+$lang['AdminUsersModified box title']="Nom" ;
+$lang['AdminUsersModified box date']="Crées le" ;
+$lang['AdminUsersModified box status']="Etat" ;
+
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/AdminUsersNew.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/AdminUsersNew.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/AdminUsersNew.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,18 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['AdminUsersNew heading']="Derniers utilisateurs modifiés" ;
+
+$lang['AdminUsersNew box reference']="Réf." ;
+$lang['AdminUsersNew box title']="Nom" ;
+$lang['AdminUsersNew box date']="Crées le" ;
+$lang['AdminUsersNew box status']="Etat" ;
+
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/ContentLastModified.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/ContentLastModified.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/ContentLastModified.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,17 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['ContentLastModified heading']="Dernière page cms modifiées" ;
+
+$lang['ContentLastModified box reference']="Réf." ;
+$lang['ContentLastModified box customers']="titre" ;
+$lang['ContentLastModified box date']="modifié le" ;
+$lang['ContentLastModified box status']="Etat" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/ContentLastNew.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/ContentLastNew.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/ContentLastNew.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,17 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['ContentLastNew heading']="Nouvelles page cms" ;
+
+$lang['ContentLastNew box reference']="Réf." ;
+$lang['ContentLastNew box customers']="titre" ;
+$lang['ContentLastNew box date']="créer le" ;
+$lang['ContentLastNew box status']="Etat" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/CustomerLastModified.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/CustomerLastModified.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/CustomerLastModified.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,17 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['CustomerLastModified heading']="Derniers clients modifié" ;
+
+$lang['CustomerLastModified box reference']="Réf." ;
+$lang['CustomerLastModified box customers']="Nom" ;
+$lang['CustomerLastModified box date']="inscrit le" ;
+$lang['CustomerLastModified box status']="Etat" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/CustomerLastNew.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/CustomerLastNew.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/CustomerLastNew.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,17 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['CustomerLastNew heading']="Nouveaux Clients" ;
+
+$lang['CustomerLastNew box reference']="Réf." ;
+$lang['CustomerLastNew box customers']="Nom" ;
+$lang['CustomerLastNew box date']="inscrit le" ;
+$lang['CustomerLastNew box status']="Etat" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersLastModified.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersLastModified.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersLastModified.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,18 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['NewslettersLastModified heading']="Dernières campagnes emailling modifiées" ;
+
+$lang['NewslettersLastModified box reference']="Réf." ;
+$lang['NewslettersLastModified box title']="Titre" ;
+$lang['NewslettersLastModified box date']="Modifiées le" ;
+$lang['NewslettersLastModified box status']="Etat" ;
+$lang['NewslettersLastModified box send']="Déjà envoyé" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersLastNew.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersLastNew.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersLastNew.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,18 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['NewslettersLastNew heading']="Dernières campagnes emailling crées" ;
+
+$lang['NewslettersLastNew box reference']="Réf." ;
+$lang['NewslettersLastNew box title']="Titre" ;
+$lang['NewslettersLastNew box date']="Crées le" ;
+$lang['NewslettersLastNew box status']="Etat" ;
+$lang['NewslettersLastNew box send']="Déjà envoyé" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersModelesLastModified.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersModelesLastModified.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersModelesLastModified.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,18 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['NewslettersModelesLastModified heading']="Derniers modèles de campagne modifiés" ;
+
+$lang['NewslettersModelesLastModified box reference']="Réf." ;
+$lang['NewslettersModelesLastModified box title']="Nom" ;
+$lang['NewslettersModelesLastModified box date']="Modifié le" ;
+$lang['NewslettersModelesLastModified box status']="Etat" ;
+
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersModelesLastNew.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersModelesLastNew.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersModelesLastNew.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,18 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['NewslettersModelesLastNew heading']="Derniers modèles de campagne crées" ;
+
+$lang['NewslettersModelesLastNew box reference']="Réf." ;
+$lang['NewslettersModelesLastNew box title']="Nom" ;
+$lang['NewslettersModelesLastNew box date']="Créer le" ;
+$lang['NewslettersModelesLastNew box status']="Etat" ;
+
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersWizzard.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersWizzard.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/NewslettersWizzard.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,24 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 02/03/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['NewslettersWizzard heading']="Assistant campagne emailling" ;
+
+$lang['NewslettersWizzard model']="Utilisation d'un modéle" ;
+$lang['NewslettersWizzard model text link page %s']="Créer un %s afin d'habiller votre campagne, et re-utiliser celui-ci à travers vos différentes campagnes. " ;
+$lang['NewslettersWizzard modelName text']=" modéle " ;
+
+$lang['NewslettersWizzard campaign create']="Créer votre 1ere campagne" ;
+$lang['NewslettersWizzard campaign create text link page %s']="Créer une %s. choissiez votre modéle, et le type de public choisi. " ;
+$lang['NewslettersWizzard campaign text']=" campagne " ;
+
+$lang['NewslettersWizzard campaign send']="Envoyer votre 1ere campagne" ;
+$lang['NewslettersWizzard campaign send text link page %s']="Une fois votre première campagne crée, il est necessaire de %s celle ci, pour permettre l'affichage du bouton d'action 'envoyer'. choissiez votre modéle, et le type de public choisi. " ;
+$lang['NewslettersWizzard send text']=" verouiller " ;
+?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/widget/homeStats.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/homeStats.txt 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/homeStats.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,9 +1,9 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9
- @date 06/06/10, 15:49
+ @version 2.1.1
+ @date 02/03/2012, 15:49
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -13,4 +13,5 @@
$lang['Accelerator : ']="Accelerator : " ;
$lang['environment']="Environment" ;
$lang['base de donnee']="Base de donnée" ;
+$lang['text oscss version']="Version d'osCSS installé" ;
?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastinvoice.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastinvoice.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastinvoice.txt 2012-03-02 17:40:31 UTC (rev 4055)
@@ -0,0 +1,17 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 0203/2012, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['orderLastinvoice box title']="Les dernières commande facturé" ;
+$lang['orderLastinvoice box reference']="Réf." ;
+$lang['orderLastinvoice box docs']="Doc." ;
+$lang['orderLastinvoice box customers']="Clients" ;
+$lang['orderLastinvoice box date']="date" ;
+$lang['orderLastinvoice box status']="Etat" ;
+?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/modules/pages/adminAccount.php
===================================================================
--- trunk/catalog/admin/includes/modules/pages/adminAccount.php 2012-03-01 23:03:40 UTC (rev 4054)
+++ trunk/catalog/admin/includes/modules/pages/adminAccount.php 2012-03-02 17:40:31 UTC (rev 4055)
@@ -1,10 +1,10 @@
<?php if (!defined('HTTP_SERVER')) die('You can not access this file directly!');
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 10/12/11, 17:28
+ @date 02/03/2012, 17:28
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
@class adminAccount
@@ -51,11 +51,12 @@
public function __construct() {
self::$code=__CLASS__;
- include_once(DIR_WS_FUNCTIONS.'password_funcs.php');
-
global $language;
$oscss=oscss_cstr::getInstance();
$oscss->pile_file_lang(DIR_FS_ADMIN.DIR_WS_LANGUAGES.$language.'/modules/configuration/adminUser.txt');
+
+ sqladminuser::getInstance();
+ self::$modules = sqladminuser::$modules;
}
public function check_action($actions){
@@ -68,68 +69,68 @@
switch(self::$action){
case 'check_password':
- $check_pass_query = $DB->query("select admin_password as confirm_password from " . TABLE_ADMIN . " where admin_id = '" . $_POST['id_info'] . "'");
- $check_pass = $check_pass_query->fetchAssoc();
+ $check_pass_query = $DB->query("select admin_password as confirm_password from " . TABLE_ADMIN . " where admin_id = '" . $_POST['id_info'] . "'");
+ $check_pass = $check_pass_query->fetchAssoc();
- // Check that password is good
- if (!PasswordUtility::validate_password($_POST['password_confirmation'], $check_pass['confirm_password'])) {
- tep_redirect(tep_href_link(self::FILENAME, 'action=check_account&error=password'));
- } else {
- //$confirm = 'confirm_account';
- tep_session_register('confirm_account');
- tep_redirect(tep_href_link(self::FILENAME, 'action=edit_member'));
- }
+ // Check that password is good
+ if (!PasswordUtility::validate_password($_POST['password_confirmation'], $check_pass['confirm_password'])) {
+ tep_redirect(tep_href_link(self::FILENAME, 'action=check_account&error=password'));
+ } else {
+ //$confirm = 'confirm_account';
+ tep_session_register('confirm_account');
+ tep_redirect(tep_href_link(self::FILENAME, 'action=edit_member'));
+ }
break;
case 'edit_member':
- parent::$url_redirect=self::FILENAME;
+ parent::$url_redirect=self::FILENAME;
break;
case 'member_edit':
- parent::$url_redirect=self::FILENAME;
- parent::check_action(self::$action);
+ parent::$url_redirect=self::FILENAME;
+ parent::check_action(self::$action);
break;
case 'update_password':
- $pass0= tep_db_prepare_input($_POST['password_']);
- $pass1= tep_db_prepare_input($_POST['password_confirmation']);
+ $pass0= tep_db_prepare_input($_POST['password_']);
+ $pass1= tep_db_prepare_input($_POST['password_confirmation']);
- if(strcmp($pass0,$pass1)==0){
- $DB->query("update " . TABLE_ADMIN . " set admin_password='".PasswordUtility::encrypt_password($pass0)."' where admin_id = '" . $_POST['id_info'] . "'");
+ if(strcmp($pass0,$pass1)==0){
+ $DB->query("update " . TABLE_ADMIN . " set admin_password='".PasswordUtility::encrypt_password($pass0)."' where admin_id = '" . $_POST['id_info'] . "'");
- $_query = $DB->query("select * from " . TABLE_ADMIN . " where admin_id = '" . $_POST['id_info'] . "'");
- $res = $_query->fetchAssoc();
+ $_query = $DB->query("select * from " . TABLE_ADMIN . " where admin_id = '" . $_POST['id_info'] . "'");
+ $res = $_query->fetchAssoc();
- $myarray = array(
- 'email_use_html'=>(bool)_cst_bool('EMAIL_USE_HTML'),
- 'links'=>HTTP_SERVER . DIR_WS_ADMIN,
- 'admin_firstname'=>$res['admin_firstname'],
- 'admin_email_address'=>$res['admin_email_address'],
- 'url_openid'=>$res['url_openid'],
- 'hiddenPassword'=>$pass0,
- 'message'=>''
- );
- $message_final=tep_post_prepare_email('admin_members.tpl',$language,$myarray);
- tep_mail($_POST['admin_firstname'] . ' ' . $res['admin_lastname'], $res['admin_email_address'],__('email text subject'), $message_final);
+ $myarray = array(
+ 'email_use_html'=>(bool)_cst_bool('EMAIL_USE_HTML'),
+ 'links'=>HTTP_SERVER . DIR_WS_ADMIN,
+ 'admin_firstname'=>$res['admin_firstname'],
+ 'admin_email_address'=>$res['admin_email_address'],
+ 'url_openid'=>$res['url_openid'],
+ 'hiddenPassword'=>$pass...
[truncated message content] |
|
From: <os...@us...> - 2012-03-01 23:03:47
|
Revision: 4054
http://oscss.svn.sourceforge.net/oscss/?rev=4054&view=rev
Author: oscim
Date: 2012-03-01 23:03:40 +0000 (Thu, 01 Mar 2012)
Log Message:
-----------
amelioration ergonomie et gestion des commandes
meilleur prise en charge des actions associ?\195?\169 au changement de status (comments, pdf )
ajout action suppression d'un pdf
correction bug
nettoyage et mise a niveau du code de la lib.orders.php
Modified Paths:
--------------
trunk/catalog/admin/includes/classes/drivers/sqlorder.php
trunk/catalog/admin/includes/classes/productUtility.php
trunk/catalog/admin/includes/functions/lib.orders.php
trunk/catalog/admin/includes/gabarit/orders/display_view.edit.gab
trunk/catalog/admin/includes/javascript/modules/pages/orders.js.php
trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/orders.txt
trunk/catalog/admin/includes/modules/pages/orders.php
trunk/catalog/admin/includes/template/oscss/data/icon_set.xml
Modified: trunk/catalog/admin/includes/classes/drivers/sqlorder.php
===================================================================
--- trunk/catalog/admin/includes/classes/drivers/sqlorder.php 2012-03-01 18:00:56 UTC (rev 4053)
+++ trunk/catalog/admin/includes/classes/drivers/sqlorder.php 2012-03-01 23:03:40 UTC (rev 4054)
@@ -107,7 +107,7 @@
@note le tableau fournis ($option) Doit correspondre a la forme des orders !!! idem Specimen
*/
public static function update($option){
-
+error_reporting(E_ALL);
self::getInstance();
/**
@@ -130,12 +130,14 @@
$status = (int)$option['status'];
if( ! isset($option['post']) )
- return __('no post');
- else
$post = $option['post'];
+ if(isset($option['comments']))
+ self::$comment[] = $option['comments'];
+ $notif = (( isset($option['notify']) && $option['notify'] )? true : false );
+
/// update billing address
if(isset($option['billing'])) {
@@ -198,7 +200,7 @@
}
-
+ /// prise en charge des module externe payment/shipping
if(isset($option['mod']) && is_array($option['mod']) ) {
foreach($option['mod'] as $key=>$row)
@@ -243,6 +245,47 @@
}
+ /// Adjust process for status
+ if($status>0)
+ $new_st = substr((int)$status,0,1);
+ else
+ $new_st = $status;
+
+ switch($new_st){
+ case DEFAULT_ORDERS_STATUS_PAYED:
+ $_query = tep_db_query("select count(*) as _id from " . TABLE_ORDERS . " where facture_id IS NOT NULL ");
+ $res_id=tep_db_fetch_array($_query);
+ $sql_data_array['facture_id'] = ((int)$res_id['_id'] +1) ;
+
+ self::$comment[] = __('orders update and factured');
+ break;
+ case DEFAULT_ORDERS_STATUS_ANNULATE:
+ $sql_data_array['orders_date_finished']= 'NOW()';
+
+ if(isset($option['cid']))
+ $cid = $option['cid'];
+ else {
+ $check_status_query = tep_db_query("select customers_id from " . TABLE_ORDERS . " where orders_id = '" . (int)$id . "'");
+ $check = tep_db_fetch_array($check_status_query);
+ $cid = $check['customers_id'];
+ }
+
+// if(isset($option['restock']))
+ tep_products_restock($id,$cid);
+
+ self::$comment[] = __('orders annulate and products restocked');
+
+ break;
+ case DEFAULT_ORDERS_STATUS_COMPLETED:
+ //! cloture commande
+ $sql_data_array['orders_date_finished']= 'NOW()';
+ break;
+ case DEFAULT_ORDERS_STATUS_ID:
+ default:
+
+ }
+
+
if(count($sql_data_array) > 0){
$sql_data_array['last_modified'] = 'NOW()';
@@ -257,9 +300,8 @@
/// Child module, Call After Update process
self::$modules->after_update($id);
+ self::AddOrderHistory($id, $status , $notif, implode("\n\r", self::$comment) );
- self::AddOrderHistory($id, $status , 0/*$notif*/, implode("<br />", self::$comment) );
-
if($error !=false)
return false;
else
@@ -324,9 +366,9 @@
foreach($res->fetchAllAssoc() as $resarray){
- $result = new order((int)tep_db_input($resarray['id']));
+ $result = new order((int)tep_db_input($resarray['id']));
- $array[]= ((!$shortkey)? $result : self::CleanKey($result));
+ $array[]= ((!$shortkey)? $result : self::CleanKey($result));
}
return $array;
Modified: trunk/catalog/admin/includes/classes/productUtility.php
===================================================================
--- trunk/catalog/admin/includes/classes/productUtility.php 2012-03-01 18:00:56 UTC (rev 4053)
+++ trunk/catalog/admin/includes/classes/productUtility.php 2012-03-01 23:03:40 UTC (rev 4054)
@@ -394,7 +394,7 @@
if (!empty($customers_id)){
/* Element modulaire aca */
if (!is_object($products_modules)) {
- require_once (DIR_WS_MODULES.'pages/products.php');
+// require_once (DIR_WS_MODULES.'pages/products.php');
$products_modules = new productsACA();
}
$products_modules->products_restock($order['products_id'],$customers_id,$order['products_quantity'],($order['products_quantity'] *$order['final_price'] ) );
Modified: trunk/catalog/admin/includes/functions/lib.orders.php
===================================================================
--- trunk/catalog/admin/includes/functions/lib.orders.php 2012-03-01 18:00:56 UTC (rev 4053)
+++ trunk/catalog/admin/includes/functions/lib.orders.php 2012-03-01 23:03:40 UTC (rev 4054)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 20/10/11, 22:36
+ @date 01/03/2012, 22:36
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -27,45 +27,40 @@
/**
- Gestion des evolution du status d'une commandes
- @package oscss-major
- @author oscim <mail a...@os... /><web http://www.oscim.fr />
- @param
- @a array post array(status,comments, notify, notify_comments, comments )
+ @brief Gestion des evolution du status d'une commandes
+ @param $oID int
+ @param $status int
+ @param array post array(status,comments, notify, notify_comments, comments )
*/
-function up_status_order($oID,$post){
- global $language, $orders_status_array;
+function up_status_order($oID,$status, $post){
+ global $language, $orders_status_array, $messageStack;
$_oID = tep_db_prepare_input($oID);
$status = tep_db_prepare_input($post['status']);
$comments = tep_db_prepare_input($post['comments']);
+ $notify = (isset($_POST['notify']) && ($post['notify'] == 'on')) ? true : false ;
$check_status_query = tep_db_query("select customers_id, customers_name, customers_email_address, orders_status, date_purchased, ip_address from " . TABLE_ORDERS . " where orders_id = '" . (int)$_oID . "'");
$check_status = tep_db_fetch_array($check_status_query);
if ( ($check_status['orders_status'] != $status) || tep_not_null($comments)) {
- if((int)DEFAULT_ORDERS_STATUS_COMPLETED ===(int)$status){
- $_query = tep_db_query("select count(*) as _id from " . TABLE_ORDERS . " where orders_date_finished IS NOT NULL ");
- $res_id=tep_db_fetch_array($_query);
- //! cloture commande
- tep_db_query("update " . TABLE_ORDERS . " set orders_status = '" . tep_db_input($status) . "', last_modified = now(), orders_date_finished = now(), facture_id='".((int)$res_id['_id'] +1)."' where orders_id = '" . (int)$_oID . "'");
- }else
- tep_db_query("update " . TABLE_ORDERS . " set orders_status = '" . tep_db_input($status) . "', last_modified = now() where orders_id = '" . (int)$_oID . "'");
- $customer_notified = '0';
- if (isset($_POST['notify']) && ($post['notify'] == 'on')) {
+ if(!sqlorder::update(array('id'=> (int)$_oID, 'status'=> tep_db_input($status), 'notify'=>$notify , 'comments'=>$comments )))
+ $messageStack->add_session(__('error order not update status'), 'warning');
+ else
+ $messageStack->add_session(__('success order update status'), 'success');
+
+ if ($notify) {
$notify_comments = '';
- if (isset($_POST['notify_comments']) && ($post['notify_comments'] == 'on')) {
- $notify_comments = $comments . "\n\n";
- }
+
$myarray = array(
'mail_sent_to'=>$check_status['customers_email_address'],
'from'=>STORE_OWNER,
'subject'=>'',
'_oID'=>$_oID,
'date_purchased'=>tep_date_long($check_status['date_purchased']),
- 'notify_comments'=>$notify_comments,
+ 'notify_comments'=>$comments,
'_ostatus'=>$orders_status_array[$status],
'_oLinks'=>tep_catalog_href_link(FILENAME_CATALOG_ACCOUNT_HISTORY_INFO, 'order_id=' . $_oID, 'SSL'),
'email_use_html'=>_cst_bool('EMAIL_USE_HTML'),
@@ -74,14 +69,17 @@
$message_final=tep_post_prepare_email('orders.tpl',$language,$myarray);
- if( tep_mail($check_status['customers_name'], $check_status['customers_email_address'], EMAIL_TEXT_SUBJECT, $message_final) !=false) $customer_notified = '1';
+ if( tep_mail($check_status['customers_name'], $check_status['customers_email_address'], EMAIL_TEXT_SUBJECT, $message_final) !=false) /*$customer_notified = '1';*/
+ $messageStack->add_session(sprintf(__('success email notify customers %'), $check_status['customers_email_address']) , 'success');
+ else
+ sqlorder::AddOrderHistory($oID, tep_db_input($status) , 0, __('error process notify customers'));
}
- tep_db_query("insert into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, comments) values ('" . (int)$_oID . "', '" . tep_db_input($status) . "', now(), '" . tep_db_input($customer_notified) . "', '" . tep_db_input($comments) . "')");
return true;
}
- else return null;
+ else
+ return false;
}
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/gabarit/orders/display_view.edit.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/orders/display_view.edit.gab 2012-03-01 18:00:56 UTC (rev 4053)
+++ trunk/catalog/admin/includes/gabarit/orders/display_view.edit.gab 2012-03-01 23:03:40 UTC (rev 4054)
@@ -299,6 +299,8 @@
</div>
+
+ <?php /** DEtail commande */ ?>
<div id="tabs-2" class="tabPage">
<?php echo tep_draw_form('status_form', orders::FILENAME,'oID='.orders::$oID.'&action=update_order', 'post', ' class="block_form"'); ?>
@@ -382,9 +384,11 @@
</tbody>
</table>
- <div class="button_nav">
- <?php echo tep_image_submit('button_update.gif', IMAGE_UPDATE); ?>
- </div>
+ <?php if( !in_array(orders::$order->info['orders_status_id'], array(DEFAULT_ORDERS_STATUS_COMPLETED, DEFAULT_ORDERS_STATUS_ANNULATE ) ) ): ?>
+ <div class="button_nav">
+ <?php echo tep_image_submit('button_update.gif', IMAGE_UPDATE); ?>
+ </div>
+ <?php endif; ?>
</fieldset>
</form>
</div>
@@ -416,7 +420,7 @@
<tr>
<td><?php echo $item['date_added']; ?></td>
<td class="tcenter"><?php echo $item['customer_notified']; ?></td>
- <td class="tcenter" style="width:40px; background:<?php echo orders::$order->lasthistory['color'] ?> url('includes/template/<?php echo $current_theme ?>/img/<?php echo $_SESSION['login_groups_id'] ?>/bg_graph.png') bottom left repeat-y;"><?php echo $item['orders_status']; ?></td>
+ <td class="tcenter" style="width:40px; background:<?php echo $item['color'] ?> url('includes/template/<?php echo $current_theme ?>/img/<?php echo $_SESSION['login_groups_id'] ?>/bg_graph.png') bottom left repeat-y;"><?php echo $item['orders_status']; ?></td>
<td><?php echo unhtmlentities($item['comments']); ?></td>
</tr>
<?php endforeach; ?>
@@ -629,13 +633,14 @@
<th><?php echo __('order table pdf heading file') ?></th>
<th><?php echo __('order table pdf heading weight') ?></th>
<th><?php echo __('order table pdf heading date') ?></th>
+ <th> </th>
</tr>
</thead>
<tr>
- <th colspan="2"><?php echo IMAGE_ORDERS_PACKINGSLIP ?></th>
- <th><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('page_admin','action')).'action=pdf&forceview=pdf&file_type=packingslip&id='.$_GET['oID']) . '" >' . __('pdf generate') . '</a>' ; ?></th>
+ <th colspan="3"><?php echo IMAGE_ORDERS_PACKINGSLIP ?></th>
+ <th></th>
</tr>
<?php if(( $filepath=$datadocs->GetDoc('packingslip', $_GET['oID'])) && file_exists($filepath)): ?>
@@ -643,12 +648,18 @@
<td><a href="<?php echo tep_href_link('document.php', 'mod=packingslip&id='.$_GET['oID']) ?>"><?php echo basename($filepath) ?></a></td>
<td><?php echo round((filesize($filepath)/1000),1).' Ko' ; ?></td>
<td><?php echo tep_datetime_short(date('Y-m-d H:i:s',filemtime($filepath))) ; ?></td>
+ <td><?php echo sprintf(CsrtAction::getLink('row_action_right', IMAGE_DELETE, 'trash'), '', tep_href_link(orders::FILENAME, 'file_type=packingslip&action=deletefile&id='.$_GET['oID'].'&oID='.$_GET['oID']) ,'' ) ; ?></td>
</tr>
+ <?php else: ?>
+ <tr>
+ <td colspan="3"> </td>
+ <td><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('page_admin','action')).'action=pdf&forceview=pdf&file_type=packingslip&id='.$_GET['oID']) . '" >' . __('pdf generate') . '</a>' ; ?> </td>
+ </tr>
<?php endif; ?>
<tr>
- <th colspan="2"><?php echo __('image orders delivery') ?></th>
+ <th colspan="3"><?php echo __('image orders delivery') ?></th>
<th></th>
</tr>
@@ -659,10 +670,11 @@
<td><a href="<?php echo tep_href_link('document.php', 'mod=delivery&id='.$ashipping->row_id) ?>"><?php echo basename($filepath) ?></a></td>
<td><?php echo round((filesize($filepath)/1000),1).' Ko' ; ?></td>
<td><?php echo tep_datetime_short(date('Y-m-d H:i:s',filemtime($filepath))) ; ?></td>
+ <td><?php echo sprintf(CsrtAction::getLink('row_action_right', IMAGE_DELETE, 'trash'), '', tep_href_link(orders::FILENAME, 'file_type=delivery&action=deletefile&id='.$ashipping->row_id.'&oID='.$_GET['oID']) ,'' ) ; ?></td>
</tr>
<?php else: ?>
<tr>
- <td colspan="2"> </td>
+ <td colspan="3"> </td>
<td><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('page_admin','action')).'action=pdf&forceview=pdf&file_type=delivery&id='.$ashipping->row_id) . '" >' . __('pdf generate') . '</a>' ; ?> </td>
</tr>
<?php endif; ?>
@@ -670,17 +682,23 @@
<?php endforeach ?>
- <tr>
- <th colspan="2"><?php echo IMAGE_ORDERS_INVOICE ?></th>
- <th><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('page_admin','action','forceview')).'action=pdf&forceview=pdf&file_type=invoice&id='.$_GET['oID']) . '">' . __('pdf generate') . '</a>' ; ?></th>
- </tr>
+ <tr>
+ <th colspan="3"><?php echo IMAGE_ORDERS_INVOICE ?></th>
+ <th> </th>
+ </tr>
<?php if(( $filepath=$datadocs->GetDoc('invoices', $_GET['oID'])) && file_exists($filepath)): ?>
<tr>
<td><a href="<?php echo tep_href_link('document.php', 'mod=invoice&id='.$_GET['oID']) ?>"><?php echo basename($filepath) ?></a></td>
<td><?php echo round((filesize($filepath)/1000),1).' Ko' ; ?></td>
<td><?php echo tep_datetime_short(date('Y-m-d H:i:s',filemtime($filepath))) ; ?></td>
+ <td><?php echo sprintf(CsrtAction::getLink('row_action_right', IMAGE_DELETE, 'trash'), '', tep_href_link(orders::FILENAME, 'file_type=invoice&action=deletefile&id='.$_GET['oID'].'&oID='.$_GET['oID']) ,'' ) ; ?></td>
</tr>
+ <?php else: ?>
+ <tr>
+ <td colspan="3"> </td>
+ <td><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(orders::FILENAME , tep_get_all_get_params(array('page_admin','action','forceview')).'action=pdf&forceview=pdf&file_type=invoice&id='.$_GET['oID']) . '">' . __('pdf generate') . '</a>' ; ?></td>
+ </tr>
<?php endif; ?>
</table>
@@ -693,12 +711,4 @@
</div>
- <div class="button_action">
- <?php echo '<a class="button" href="' . tep_href_link(FILENAME_BATCH_PRINT, tep_get_all_get_params(array('page_admin','action','forceview')).'forceview=pdf&file_type=invoice&action=exe') . '">' . IMAGE_ORDERS_INVOICE . '</a>'.
- '<a class="button" href="' . tep_href_link(FILENAME_BATCH_PRINT, tep_get_all_get_params(array('page_admin','action')).'forceview=pdf&file_type=packingslip&action=exe') . '" onclick="window.open(this.href); return false;">' . IMAGE_ORDERS_PACKINGSLIP . '</a>';
- ; ?>
- </div>
-
-
-
</div>
Modified: trunk/catalog/admin/includes/javascript/modules/pages/orders.js.php
===================================================================
--- trunk/catalog/admin/includes/javascript/modules/pages/orders.js.php 2012-03-01 18:00:56 UTC (rev 4053)
+++ trunk/catalog/admin/includes/javascript/modules/pages/orders.js.php 2012-03-01 23:03:40 UTC (rev 4054)
@@ -10,7 +10,12 @@
*/
error_reporting(E_ALL);
?>
-<?php if (orders::$action == 'edit'): ?>
+<?php if (orders::$action == 'edit'):
+
+ tep_include_file (DIR_WS_TEMPLATE."jquery.validate.css",true);
+ tep_include_file ("includes/javascript/jquery.validate.min.js",true);
+
+?>
<script type="text/javascript"><!--
function disabled(inputs){$(inputs).css.display='none';}
function activ(inputs){$(inputs).css.display='inline';}
@@ -27,25 +32,25 @@
// you might want to adjust to get the right result
/* END CONFIG */
- $("a.screenshot").hover(function(e){
- this.t = this.title;
- this.title = "";
- var c = (this.t != "") ? "<br/>" + this.t : "";
- $("body").append("<p id='screenshot'><img src='"+ this.rel +"' alt='url preview' />"+ c +"</p>");
- $("#screenshot")
- .css("top",(e.pageY - xOffset) + "px")
- .css("left",(e.pageX + yOffset) + "px")
- .fadeIn("fast");
- },
- function(){
- this.title = this.t;
- $("#screenshot").remove();
- });
- $("a.screenshot").mousemove(function(e){
- $("#screenshot")
- .css("top",(e.pageY - xOffset) + "px")
- .css("left",(e.pageX + yOffset) + "px");
- });
+ $("a.screenshot").hover(function(e){
+ this.t = this.title;
+ this.title = "";
+ var c = (this.t != "") ? "<br/>" + this.t : "";
+ $("body").append("<p id='screenshot'><img src='"+ this.rel +"' alt='url preview' />"+ c +"</p>");
+ $("#screenshot")
+ .css("top",(e.pageY - xOffset) + "px")
+ .css("left",(e.pageX + yOffset) + "px")
+ .fadeIn("fast");
+ },
+ function(){
+ this.title = this.t;
+ $("#screenshot").remove();
+ });
+ $("a.screenshot").mousemove(function(e){
+ $("#screenshot")
+ .css("top",(e.pageY - xOffset) + "px")
+ .css("left",(e.pageX + yOffset) + "px");
+ });
};
@@ -71,6 +76,31 @@
});
});
+
+
+
+ // validate signup form on keyup and submit for shipping
+ $(function(){
+ $("#add_deliv").validate({
+ rules: {
+ shipping_tracing_number: {
+ required: true,
+ minlength: 3
+ },
+ },
+ messages: {
+ shipping_tracing_number: {
+ required: " <?php echo addslashes(__('js alert numero expedition')) ?>",
+ minlength: " <?php echo addslashes(__('your numero must consist of at least 3 characters')) ?>"
+ },
+ errorElement: "span",
+ errorPlacement: function(error, element) {
+ error.appendTo( element.parent());
+ },
+ onkeyup: true
+ });
+ });
+
//--></script>
<style type="text/css">
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt 2012-03-01 18:00:56 UTC (rev 4053)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt 2012-03-01 23:03:40 UTC (rev 4054)
@@ -26,17 +26,19 @@
XXXX_L description longue
*/
$lang['DEFAULT_ORDERS_STATUS_ID_S']="Commande Payée" ;
-$lang['DEFAULT_ORDERS_STATUS_ID_L']="définir le statut d'une commande payés." ;
+$lang['DEFAULT_ORDERS_STATUS_ID_L']="definir le statut d'une commande payés." ;
$lang['DEFAULT_ORDERS_STATUS_ID_S']="État par défaut pour une nouvelle commande" ;
$lang['DEFAULT_ORDERS_STATUS_ID_L']="Quand une nouvelle commande est créée, ce statut de commande lui sera assigné." ;
-$lang['DEFAULT_ORDERS_STATUS_COMPLETED_S']="Commande Clôturé" ;
-$lang['DEFAULT_ORDERS_STATUS_COMPLETED_L']="définir le statut final d'une commande livre" ;
+$lang['DEFAULT_ORDERS_STATUS_COMPLETED_S']="Commande Cloturé" ;
+$lang['DEFAULT_ORDERS_STATUS_COMPLETED_L']="definir le statut final d'une commande livre" ;
+$lang['DEFAULT_ORDERS_STATUS_PAYED_S']="Commande payés" ;
+$lang['DEFAULT_ORDERS_STATUS_PAYED_L']="definir le statut final d'une commande payés. Lors d'une mise à jour dans un status payés, construit la numerotation de facture est effecctué, et celle ci est creer" ;
$lang['DEFAULT_ORDERS_STATUS_ID_S']="Commande annulée" ;
-$lang['DEFAULT_ORDERS_STATUS_ID_L']="définir le statut d'une commande annule." ;
+$lang['DEFAULT_ORDERS_STATUS_ID_L']="definir le statut d'une commande annule." ;
$lang['ORDERS_NUMBER_PREFIX_S']="Préfixe numéro commande" ;
-$lang['ORDERS_NUMBER_PREFIX_L']="Indiquer le préfixe des numéros de commande le chiffre précise le nombre de chiffre du numéro; ex: 'ym-5'(1005-00001); Laissez vide si vous ne voulez pas de préfixe." ;
+$lang['ORDERS_NUMBER_PREFIX_L']="Indiquer le préfixe des numéros de commande le chiffre precise le nombre de chiffre du numéro; ex: 'ym-5'(1005-00001); Laissez vide si vous ne voulez pas de préfixe." ;
$lang['USE_LOCAL_GENERAT_ORDER_REF_S']="Référence des commandes" ;
-$lang['USE_LOCAL_GENERAT_ORDER_REF_L']="Utiliser la numérotation interne, ou laisser un outils externe prendre en charge cette référence. Celle ci ne sera donc disponible ci-après la prise en compte par l'outil tiers de la commande. Coté public, le numéro générique interne est utilisé en attente de référence" ;
+$lang['USE_LOCAL_GENERAT_ORDER_REF_L']="Utiliser la numerotaion interne, ou laisser un outils externe prendre en charge cette référence. Celle ci ne sera donc disponible qu'apres la prise en compte par l'outil tiers de la commande. Coté public, le numero generic interne est utilisé en attente de reference" ;
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/pages/orders.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/pages/orders.txt 2012-03-01 18:00:56 UTC (rev 4053)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/pages/orders.txt 2012-03-01 23:03:40 UTC (rev 4054)
@@ -119,9 +119,10 @@
$lang['legend contact customers']="Contact" ;
$lang['legend update order history']="Mise à jour" ;
-$lang['pdf generate']="Generer" ;
+$lang['image orders delivery']="Bon de livraison" ;
+
/* PDF */
$lang['qty orders']="Cmd" ;
$lang['qty exedie']="Exp" ;
Modified: trunk/catalog/admin/includes/modules/pages/orders.php
===================================================================
--- trunk/catalog/admin/includes/modules/pages/orders.php 2012-03-01 18:00:56 UTC (rev 4053)
+++ trunk/catalog/admin/includes/modules/pages/orders.php 2012-03-01 23:03:40 UTC (rev 4054)
@@ -244,12 +244,31 @@
$pdf=osCSS_pdf::SaveEnd($file);
/// @remarks draw and exit;
- $pdf=osCSS_pdf::OutputEnd();
+// $pdf=osCSS_pdf::OutputEnd();
- tep_redirect(tep_href_link(self::FILENAME, 'oID='.$oID.'&action=edit'));
+ if(!isset($_GET['forceajax']))
+ tep_redirect(tep_href_link(self::FILENAME, 'oID='.$oID.'&action=edit'));
break;
/**
+ @remarks pdf generate
+ */
+ case 'deletefile':
+ $oID=(int)$_REQUEST['oID'];
+ $ID=(int)$_REQUEST['id'];
+ $type=$_REQUEST['file_type'] ;
+
+ $datadocs=new DatasFiles;
+
+ if(( $filepath=$datadocs->GetDoc($type, $ID)) && file_exists($filepath))
+ unlink($filepath);
+
+ if(!isset($_GET['forceajax']))
+ tep_redirect(tep_href_link(self::FILENAME, 'oID='.$oID.'&action=edit'));
+ break;
+
+
+ /**
@remarks Action mutliple
*/
case 'multiconfirm':
@@ -315,9 +334,39 @@
*/
case 'update_order':
$oID=(int)$_GET['oID'];
- if (up_status_order($oID, $_POST) ) $messageStack->add_session(__('success order updated'), 'success');
- else $messageStack->add_session(__('warning order not updated'), 'warning');
+ $status = tep_db_prepare_input($_POST['status']);
+ if (up_status_order($oID, $status , $_POST) ){
+// $messageStack->add_session(__('success order updated'), 'success');
+
+ switch($status){
+ case DEFAULT_ORDERS_STATUS_PAYED:
+ if(_cst_bool('USE_LOCAL_GENERAT_PDF')) {
+ $_GET['forceajax'] = true;
+ $_REQUEST['id'] = $oID;
+ $_REQUEST['file_type'] = 'invoice';
+ self::check_action('pdf');
+ self::$action=$actions;
+ }
+ break;
+ case DEFAULT_ORDERS_STATUS_ANNULATE:
+ break;
+ case DEFAULT_ORDERS_STATUS_COMPLETED:
+ break;
+ case DEFAULT_ORDERS_STATUS_ID:
+ default:
+ if(_cst_bool('USE_LOCAL_GENERAT_PDF')) {
+ $_GET['forceajax'] = true;
+ $_REQUEST['id'] = $oID;
+ $_REQUEST['file_type'] = 'packingslip';
+ self::check_action('pdf');
+ self::$action=$actions;
+ }
+ }
+ }
+ else
+ $messageStack->add_session(__('warning order not updated'), 'warning');
+
tep_redirect(tep_href_link(self::FILENAME, 'oID='.$oID.'&action=edit'));
break;
@@ -425,14 +474,23 @@
foreach($_POST['shipping_qt'] as $k=>$row)
if($row > 0) $array['products'][] = array('products_id'=>$k , 'qt'=>$row) ;
- switch((string)$_GET['method']){
- case 'add':
- $res = sqlshipping::create($array);
- break;
- }
+ if(count($array['products'])>0)
+ switch((string)$_GET['method']){
+ case 'add':
+ $res = sqlshipping::create($array);
+ if(_cst_bool('USE_LOCAL_GENERAT_PDF')) {
+ $_GET['forceajax'] = true;
+ $_REQUEST['id'] = $res;
+ $_REQUEST['file_type'] = 'delivery';
+ self::check_action('pdf');
+ self::$action=$actions;
+ }
+ break;
+ }
+
// adjust date update
- sqlorder::update(array('id'=>$oID));
+// sqlorder::update(array('id'=>$oID, 'status'=>DEFAULT_ORDERS_STATUS_EXPED 'comments'=>__('expeditions')));
tep_redirect(tep_href_link(self::FILENAME, 'oID='.$oID.'&action=edit'));
break;
@@ -553,7 +611,7 @@
$res= sqlorder::fetch(array('id'=>self::$oID));
$res->history=self::load_status_history((int)self::$oID);
- $res->lasthistory=$res->history[(count($res->history)-1)];
+ $res->lasthistory=$res->history[0];
$res->service = array();
$res->pshipping = array();
@@ -564,8 +622,7 @@
*/
foreach($res->products as $rows){
$pdt_db_arr[$rows['rowid']] = $rows;
-// print_r($rows);
-// exit;
+
/// No physical
if(in_array($rows['type'], explode(',', TYPE_VIRTUAL_PRODUCTS)) ){
@@ -586,26 +643,25 @@
/// physical
else {
- $sql="SELECT cc.* , cp.orders_products_id as products_id , cp.qt_expedie as qt ".
+ $sql="SELECT cp.orders_products_id as products_id , SUM(cp.qt_expedie) as qt ".
" FROM ".TABLE_SHIPPING." cc ".
" LEFT JOIN ".TABLE_SHIPPING_PRODUCTS." cp ON (cc.row_id = cp.shipping_id) ".
" WHERE cc.orders_id = '".(int)self::$oID ."' AND cp.orders_products_id = '".$rows['rowid']."' ".
+ " GROUP BY orders_products_id ";
" ORDER BY row_id DESC";
$_query2 = $DB->query($sql);
- $activ_add=array();
+
$qt = 0;
-
-
if($_query2->__get('numRows')){
foreach($_query2->fetchAllAssoc() as $result){
- $qt += (int)$result['qt'];
+ $qt = (int)$result['qt'];
+ $result['qt_expedie'] = $qt;
+ $result['qt_orders'] = $rows['qty'];
+ $robj = new objectInfo(array_merge($rows,$result));
+ $activ_add[] = ( ( (int)$rows['qty'] == $qt) ? false : true );
+ $res->pshipping[]=$robj;
}
- $result['qt_expedie'] = $qt;
- $result['qt_orders'] = $rows['qty'];
- $robj = new objectInfo(array_merge($rows,$result));
- $activ_add[] = ( ( (int)@$robj->qty - (int)@$robj->qt_expedie) == 0 ) ? false : true;
- $res->pshipping[]=$robj;
}
else{
$rows['qt_expedie'] = 0;
@@ -616,6 +672,7 @@
}
}
+
$result4 = sqlshipping::fetch(array('orders_id'=>(int)self::$oID ), true);
if(is_array($result4))
@@ -623,9 +680,6 @@
else
$res->allshipping[] = $result4;
-// foreach($rows)
-
-
$res->display_service = (count($res->service) <= 0 )? false : true;
$res->display_shipping = (count($res->pshipping) <= 0 )? false : true;
$res->display_shipping_add = (in_array(true, $activ_add))? true : false;
Modified: trunk/catalog/admin/includes/template/oscss/data/icon_set.xml
===================================================================
--- trunk/catalog/admin/includes/template/oscss/data/icon_set.xml 2012-03-01 18:00:56 UTC (rev 4053)
+++ trunk/catalog/admin/includes/template/oscss/data/icon_set.xml 2012-03-01 23:03:40 UTC (rev 4054)
@@ -30,6 +30,7 @@
<noedit>icon_view.png</noedit>
<preview>previews.png</preview>
<view>icon_view.png</view>
+ <trash>icon_trash.gif</trash>
<!-- <recup_order>
</recup_order> -->
<remove>remove.gif</remove>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-01 18:01:07
|
Revision: 4053
http://oscss.svn.sourceforge.net/oscss/?rev=4053&view=rev
Author: oscim
Date: 2012-03-01 18:00:56 +0000 (Thu, 01 Mar 2012)
Log Message:
-----------
ajustement css
correction
Modified Paths:
--------------
trunk/catalog/admin/includes/gabarit/customers/address_book/inline.edit.gab
trunk/catalog/admin/includes/template/oscss/stylesheet-1.css
Modified: trunk/catalog/admin/includes/gabarit/customers/address_book/inline.edit.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/customers/address_book/inline.edit.gab 2012-03-01 16:18:36 UTC (rev 4052)
+++ trunk/catalog/admin/includes/gabarit/customers/address_book/inline.edit.gab 2012-03-01 18:00:56 UTC (rev 4053)
@@ -21,9 +21,9 @@
<?php if(!$processed) echo tep_result_up_field(address_book::$cInfo,'customers_gender','tep_view_gender_human','', true, true);
else {
echo '<ul class="inline">' . "\n" .
- '<li class="inline">' . tep_draw_radio_field('customers_gender', 'm', 'm', true, address_book::$cInfo->customers_gender) . ' ' . MALE . '' . '</li>' . "\n ".
- '<li class="inline">' . tep_draw_radio_field('customers_gender', 'f', 'f', false, address_book::$cInfo->customers_gender) . ' ' . FEMALE . '' . '</li>' . "\n" .
- '<li class="inline">' . tep_draw_radio_field('customers_gender', 'l', 'l', false, address_book::$cInfo->customers_gender) . ' ' . MLLE . '' . '</li>' . "\n" .
+ '<li class="inline">' . tep_draw_radio_field('customers_gender', 'm', 'm', true, @address_book::$cInfo->customers_gender) . ' ' . MALE . '' . '</li>' . "\n ".
+ '<li class="inline">' . tep_draw_radio_field('customers_gender', 'f', 'f', false, @address_book::$cInfo->customers_gender) . ' ' . FEMALE . '' . '</li>' . "\n" .
+ '<li class="inline">' . tep_draw_radio_field('customers_gender', 'l', 'l', false, @address_book::$cInfo->customers_gender) . ' ' . MLLE . '' . '</li>' . "\n" .
'</ul>' . "\n";
} ?>
</div>
Modified: trunk/catalog/admin/includes/template/oscss/stylesheet-1.css
===================================================================
--- trunk/catalog/admin/includes/template/oscss/stylesheet-1.css 2012-03-01 16:18:36 UTC (rev 4052)
+++ trunk/catalog/admin/includes/template/oscss/stylesheet-1.css 2012-03-01 18:00:56 UTC (rev 4053)
@@ -43,7 +43,7 @@
/* popup form by fancy */
#fancybox-inner h3 { background: none repeat scroll 0 0 black; color: white; font-weight: normal; height: 21px; left: 0; line-height: 20px; padding: 0; position: absolute; text-align: center; text-shadow: none; top: 0; width: 100%;}
-#fancybox-inner form {margin:0; padding:0; position: relative;top:20px;min-height: 90%;}
+#fancybox-inner form {margin:0; padding:0; position: relative;top:20px;min-height: 90%;padding: 0 0 30px;}
#fancybox-inner form h3{ top: -25px;}
#fancybox-inner fieldset { margin: 5px; padding:5pxem; border:none; }
#fancybox-inner fieldset label { width: 100%; line-height: 18px; margin-right: 10px; display:inline-block; text-align: left; padding: 0 0 2px 0;}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-01 16:18:43
|
Revision: 4052
http://oscss.svn.sourceforge.net/oscss/?rev=4052&view=rev
Author: oscim
Date: 2012-03-01 16:18:36 +0000 (Thu, 01 Mar 2012)
Log Message:
-----------
coquille
Modified Paths:
--------------
trunk/catalog/admin/includes/content/aca.top.inc
Modified: trunk/catalog/admin/includes/content/aca.top.inc
===================================================================
--- trunk/catalog/admin/includes/content/aca.top.inc 2012-03-01 15:58:39 UTC (rev 4051)
+++ trunk/catalog/admin/includes/content/aca.top.inc 2012-03-01 16:18:36 UTC (rev 4052)
@@ -79,14 +79,14 @@
$aca_modules = new AcaFactory($actions['action_type']);
- $post_exe=false;
+ $post_exe=true;
}
/**
A module has asked to privately take care of this action, check if class and method exist and run it.
*/
if ($post_exe && (isset($aca_modules->modules[$actions['action_class']])) && ($box=$aca_modules->modules[$actions['action_class']]->check_action($actions)) !=false)
if (!empty($actions['action_method']) && method_exists($aca_modules->modules[$actions['action_class']],$actions['action_method'] )){
- $box = new box;
+ $box = array();
$box=$aca_modules->modules[$actions['action_class']]->$actions['action_method']($box,(int)$ID);
}
if ($post_exe && (isset($aca_modules->modules[$actions['action_class']])) )
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-03-01 15:58:51
|
Revision: 4051
http://oscss.svn.sourceforge.net/oscss/?rev=4051&view=rev
Author: oscim
Date: 2012-03-01 15:58:39 +0000 (Thu, 01 Mar 2012)
Log Message:
-----------
Amelioration template pdf harry et lifting de la mise en forme
Ajout d'une class pour la mise en forme de harry, et prise en charge d'une class pour struturer les modeles pdf
report de la creation des pdf ds la class order, et modification du processus qui lors de la creation d'un pdf, ne force pas le telechargement
amelioration de la gestion des livraison et correction de coquille
ajoutd 'un bon d'expediotion dans harry
ajustement du fichier documnt pour la prise en charge des BL
Ajustement des class de common pour la prise en charge des BL
Modified Paths:
--------------
trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php
trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/packingslip.php
trunk/catalog/admin/document.php
trunk/catalog/admin/includes/classes/drivers/sqlorder.php
trunk/catalog/admin/includes/gabarit/orders/display_view.edit.gab
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/orders.txt
trunk/catalog/admin/includes/modules/pages/orders.php
trunk/catalog/common/classes/DatasFiles.php
trunk/catalog/common/classes/osCSS_pdf.php
trunk/catalog/common/functions/pdf_output.php
Added Paths:
-----------
trunk/catalog/Documents/modeles/pdf/harry/harry.php
trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/delivery.php
trunk/catalog/admin/includes/languages/fr_FR/modeles/pdf/harry/harry.txt
Added: trunk/catalog/Documents/modeles/pdf/harry/harry.php
===================================================================
--- trunk/catalog/Documents/modeles/pdf/harry/harry.php (rev 0)
+++ trunk/catalog/Documents/modeles/pdf/harry/harry.php 2012-03-01 15:58:39 UTC (rev 4051)
@@ -0,0 +1,146 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 28/02/2012, 10:54
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+ @brief Generation des elements d'entete et footer pour les BL et facture
+*/
+
+class harry
+ extends FPDF {
+ // font
+ public $font = 'Arial';
+
+ // box gray
+
+ // background gray
+ public $bg_color_1 = 245;
+ // background gray
+ public $txt_color_1 = 0;
+
+
+//Page header
+ function RoundedRect($x, $y, $w, $h,$r, $style = '') {
+ $k = $this->k;
+ $hp = $this->h;
+ if($style=='F')
+ $op='f';
+ elseif($style=='FD' or $style=='DF')
+ $op='B';
+ else
+ $op='S';
+
+ $MyArc = 4/3 * (sqrt(2) - 1);
+ $this->_out(sprintf('%.2f %.2f m',($x+$r)*$k,($hp-$y)*$k ));
+ $xc = $x+$w-$r ;
+ $yc = $y+$r;
+ $this->_out(sprintf('%.2f %.2f l', $xc*$k,($hp-$y)*$k ));
+
+ $this->_Arc($xc + $r*$MyArc, $yc - $r, $xc + $r, $yc - $r*$MyArc, $xc + $r, $yc);
+ $xc = $x+$w-$r ;
+ $yc = $y+$h-$r;
+ $this->_out(sprintf('%.2f %.2f l',($x+$w)*$k,($hp-$yc)*$k));
+ $this->_Arc($xc + $r, $yc + $r*$MyArc, $xc + $r*$MyArc, $yc + $r, $xc, $yc + $r);
+ $xc = $x+$r ;
+ $yc = $y+$h-$r;
+ $this->_out(sprintf('%.2f %.2f l',$xc*$k,($hp-($y+$h))*$k));
+ $this->_Arc($xc - $r*$MyArc, $yc + $r, $xc - $r, $yc + $r*$MyArc, $xc - $r, $yc);
+ $xc = $x+$r ;
+ $yc = $y+$r;
+ $this->_out(sprintf('%.2f %.2f l',($x)*$k,($hp-$yc)*$k ));
+ $this->_Arc($xc - $r, $yc - $r*$MyArc, $xc - $r*$MyArc, $yc - $r, $xc, $yc - $r);
+ $this->_out($op);
+ }
+
+ function _Arc($x1, $y1, $x2, $y2, $x3, $y3){
+ $h = $this->h;
+ $this->_out(sprintf('%.2f %.2f %.2f %.2f %.2f %.2f c ', $x1*$this->k, ($h-$y1)*$this->k,
+ $x2*$this->k, ($h-$y2)*$this->k, $x3*$this->k, ($h-$y3)*$this->k));
+ }
+
+
+ function Header(){
+ global $oID;
+ $date = strftime('%A, %d %B %Y');
+ //Logo + link shop
+ $this->Image(LOGO_SHOP_FOR_PRINT,5,10,50,0,'',HTTP_SERVER.DIR_WS_CATALOG);
+
+
+
+ }
+
+ function Footer() {
+ $y=-8;
+ $this->SetX(6);
+ //Arial italic 8
+ $this->SetFont($this->font,'',6);
+ $this->SetFillColor($this->bg_color_1);
+ $this->SetTextColor($this->txt_color_1);
+ $this->SetY($y);
+ $this->MultiCell(198,3,tep_correct_entitie_put_pdf(STORE_LEGAL_INFO),0,'C',true);
+ }
+
+ function WriteHTML($html) {
+ //Parseur HTML
+ $html=str_replace("\n",' ',$html);
+ $a=preg_split('/<(.*)>/U',$html,-1,PREG_SPLIT_DELIM_CAPTURE);
+ foreach($a as $i=>$e) {
+ if($i%2==0) {
+ if(isset($this->HREF)) $this->PutLink($this->HREF,$e);
+ else $this->Write(5,$e);
+ }
+ else {
+ //Balise
+ if($e[0]=='/') $this->CloseTag(strtoupper(substr($e,1)));
+ else {
+ //Extraction des attributs
+ $a2=explode(' ',$e);
+ $tag=strtoupper(array_shift($a2));
+ $attr=array();
+ foreach($a2 as $v)
+ if(preg_match('/([^=]*)=["\']?([^"\']*)/',$v,$a3)) $attr[strtoupper($a3[1])]=$a3[2];
+
+ $this->OpenTag($tag,$attr);
+ }
+ }
+ }
+ }
+
+ function OpenTag($tag,$attr){
+ //Balise ouvrante
+ if($tag=='B' || $tag=='I' || $tag=='U') $this->SetStyle($tag,true);
+ if($tag=='A') $this->HREF=$attr['HREF'];
+ if($tag=='BR') $this->Ln(5);
+ }
+
+ function CloseTag($tag){
+ //Balise fermante
+ if($tag=='B' || $tag=='I' || $tag=='U') $this->SetStyle($tag,false);
+ if($tag=='A') $this->HREF='';
+ }
+
+ function SetStyle($tag,$enable){
+ //Modifie le style et sélectionne la police correspondante
+ $this->$tag+=($enable ? 1 : -1);
+ $style='';
+ foreach(array('B','I','U') as $s)
+ if(isset($this->$s) && $this->$s >0) $style.=$s;
+
+ $this->SetFont('',$style);
+ }
+
+ function PutLink($URL,$txt){
+ //Place un hyperlien
+ $this->SetTextColor(0,0,255);
+ $this->SetStyle('U',true);
+ $this->Write(5,$txt,$URL);
+ $this->SetStyle('U',false);
+ $this->SetTextColor(0);
+ }
+
+}
+?>
\ No newline at end of file
Added: trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/delivery.php
===================================================================
--- trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/delivery.php (rev 0)
+++ trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/delivery.php 2012-03-01 15:58:39 UTC (rev 4051)
@@ -0,0 +1,245 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 01/03/2012, 10:55
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+
+
+foreach($obj_shipping->products as $row){
+ $Qt[$row->products_id] = $row->qt_expedie;
+ $Prdt[] = $row->products_id;
+}
+
+
+
+$le_Y=0;
+$marge_block=3;
+$padding_block=5;
+
+// Add the first page
+$pdf->AddPage();
+
+
+ /**
+ EOB -- header
+ */
+ $le_Y=($le_Y+$marge_block);
+ $hauteur_block=11;
+ $pdf->SetFont($pdf->font,'BI',15);
+ $pdf->SetTextColor($pdf->txt_color_1);
+
+ $pdf->SetXY(155,$le_Y);
+ //Draw Order Number Text
+ $pdf->Cell(48,$hauteur_block, __('dl print doc type delivery') , 0, 0,"R");
+
+
+ $le_Y=($le_Y+$hauteur_block);
+ $hauteur_block=11;
+ //Draw Box for Order Number, Date & Payment method
+ $pdf->SetDrawColor(0);
+ $pdf->SetLineWidth(0.2);
+ $pdf->SetFillColor($pdf->bg_color_1);
+ $pdf->RoundedRect(155, $le_Y, 48, $hauteur_block, 2, 'DF');
+
+
+ $pdf->SetFont($pdf->font,'BI',15);
+ $pdf->SetTextColor($pdf->txt_color_1);
+
+ $pdf->SetXY(155,$le_Y);
+ //Draw Order Number Text
+ $temp = tep_correct_entitie_put_pdf(__('dl print packingslip ordernr'));
+ $pdf->Cell(48,$hauteur_block, 'BL-'.$obj_shipping->row_id, 0, 0,"C");
+
+ $pdf->SetFont($pdf->font,'BI',10);
+ $le_Y=($le_Y+$hauteur_block);
+ $pdf->SetXY(155,$le_Y);
+ $pdf->Cell(48,$hauteur_block, sprintf(__('dl print doc date order %s'), tep_date_short($order->info['date_purchased'])) , 0, 0,"R");
+
+ /**
+ EOF -- header
+ */
+
+ /**
+ EOB -- subheader
+ */
+
+ $le_Y=($le_Y+$hauteur_block);
+ $hauteur_block=11;
+ //Draw Box for Order Number, Date & Payment method
+ $pdf->SetDrawColor(0);
+ $pdf->SetLineWidth(0.2);
+ $pdf->SetFillColor($pdf->bg_color_1);
+ $pdf->RoundedRect(100, $le_Y, 103, ($hauteur_block*2), 2, 'DF');
+
+
+ $hauteur_block=6;
+ $pdf->SetFont($pdf->font,'BI',10);
+// $le_Y=($le_Y+$hauteur_block);
+ $pdf->SetXY(101,($le_Y+1));
+ $pdf->Cell(103,$hauteur_block, tep_correct_entitie_put_pdf( sprintf(__('dl print doc date expedition %s'), tep_date_short($obj_shipping->date_expedition)) ) , 0, 0,"L");
+ $le_Y=($le_Y+$hauteur_block);
+ $pdf->SetXY(101,($le_Y+1));
+ $pdf->Cell(103,$hauteur_block, tep_correct_entitie_put_pdf( sprintf(__('dl print doc method expedition %s'),$obj_shipping->method) ) , 0, 0,"L");
+ $le_Y=($le_Y+$hauteur_block);
+ $pdf->SetXY(101,($le_Y+1));
+ $pdf->Cell(103,$hauteur_block, tep_correct_entitie_put_pdf( sprintf(__('dl print doc tracking expedition %s'),$obj_shipping->tracking) ) , 0, 0,"L");
+
+ /**
+ EOF -- subheader
+ */
+
+
+
+
+ /**
+ Ligne cesure + marque pliage
+ */
+ $pdf->Cell(50);
+ $pdf->SetY(60);
+ $pdf->SetDrawColor(153,153,153);
+ $pdf->Cell(197,.1,'',1,1,'L',1);
+
+
+ /**
+ Block de Adresse owner shop
+ */
+
+ $le_Y=67;
+ $hauteur_block=35;
+ //Draw Box for Invoice Address
+ $pdf->SetDrawColor(0);
+ $pdf->SetLineWidth(0.2);
+ $pdf->SetFillColor($pdf->bg_color_1);
+ $pdf->RoundedRect(6, $le_Y, 90, 35, 2, 'DF');
+
+ //Draw the invoice address text
+ $pdf->SetFont($pdf->font,'B',10);
+ $pdf->SetTextColor($pdf->txt_color_1);
+ $pdf->Text(11,77, tep_correct_entitie_put_pdf(__('')));
+ $pdf->SetX(0);
+ $pdf->SetY(80);
+ $pdf->Cell(9);
+ $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(STORE_NAME_ADDRESS),0,'L');
+
+
+ /**
+ Block de Adresse customers
+ */
+
+ //Draw Box for Delivery Address
+ $pdf->SetDrawColor(0);
+ $pdf->SetLineWidth(0.2);
+ $pdf->SetFillColor(255);
+ $pdf->RoundedRect(113, $le_Y, 90, 35, 2, 'DF');
+
+ //Draw the invoice delivery address text
+ $pdf->SetFont($pdf->font,'B',10);
+ $pdf->SetTextColor($pdf->txt_color_1);
+ $pdf->Text(117,77,tep_correct_entitie_put_pdf(__('dl entry ship to')));
+ $pdf->SetX(0);
+ $pdf->SetY(80);
+ $pdf->Cell(115);
+ $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->delivery, '', '', "\n")),0,'L');
+
+
+
+/**
+ Block detail delivery
+*/
+//Fields Name position
+$Y_Fields_Name_position = ($le_Y+$hauteur_block+$marge_block);
+$item_count=0;
+//Table position, under Fields Name
+$Y_Table_Position = ($Y_Fields_Name_position+6);
+
+// output_table_heading_packingslip($Y_Fields_Name_position);
+
+ //First create each Field Name
+ //Gray color filling each Field Name box
+ $pdf->SetFillColor($pdf->bg_color_1);
+ //Bold Font for Field Name
+ $pdf->SetFont($pdf->font,'B',10);
+ $pdf->SetY($Y_Fields_Name_position);
+ $pdf->SetX(6);
+ $pdf->Cell(9,6,tep_correct_entitie_put_pdf(__('dl table heading qty orders')),1,0,'C',1);
+ $pdf->SetX(15);
+ $pdf->Cell(9,6,tep_correct_entitie_put_pdf(__('dl table heading qty exedie')),1,0,'C',1);
+ $pdf->SetX(24);
+ $pdf->Cell(27,6,tep_correct_entitie_put_pdf(__('dl table heading products model')),1,0,'C',1);
+ $pdf->SetX(50);
+ $pdf->Cell(153,6,tep_correct_entitie_put_pdf(__('dl table heading products')),1,0,'C',1);
+
+//Show the products information line by line
+// for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) {
+foreach($order->products as $rows) {
+// print_r($rows);
+// exit;
+ if(in_array($rows['id'], $Prdt )) {
+ $hauteur_block=$hauteur_block_r=6;
+ $nbr_l=1;
+ //. cesure general name produits
+ if (strlen($rows['name']) > 40 ) {
+ $r=tep_wordwrap($rows['name'], 40);
+ $rows['name'] =$r['txt'];
+ $nbr_l +=$r['nbr'];
+ }
+ // concat des attribut de produits sur les nom, avec saut de ligne
+ if (isset($rows['attributes']) && (($k = sizeof($rows['attributes'])) > 0)) {
+ for ($j = 0; $j < $k; $j++) {
+ $ligne="\n - ".$rows['attributes'][$j]['option'] . ': ' . $rows['attributes'][$j]['value'];
+ if (strlen($ligne) > 40 ) {
+ $r=tep_wordwrap($ligne, 40);
+ $rows['name'] .=$r['txt'];
+ $nbr_l +=$r['nbr'];
+ } else {
+ $rows['name'] .=$ligne;
+ $nbr_l +=1;
+ }
+ }
+ }
+ $hauteur_block_r=($nbr_l*$hauteur_block_r);
+ // quantite
+ $pdf->SetFont($pdf->font,'',10);
+ $pdf->SetY($Y_Table_Position);
+ $pdf->SetX(6);
+ $pdf->MultiCell(9,$hauteur_block_r,$rows['qty'],1,'C');
+
+ // quantite
+ $pdf->SetFont($pdf->font,'',10);
+ $pdf->SetY($Y_Table_Position);
+ $pdf->SetX(15);
+ $pdf->MultiCell(9,$hauteur_block_r,$Qt[$rows['id']],1,'C');
+
+ // modele
+ $pdf->SetY($Y_Table_Position);
+ $pdf->SetX(24);
+ $pdf->SetFont($pdf->font,'',8);
+ $pdf->MultiCell(26,$hauteur_block_r,tep_correct_entitie_put_pdf($rows['model']),1,'C');
+
+ // nom product
+ $pdf->SetY($Y_Table_Position);
+ $pdf->SetX(50);
+ $pdf->SetFont($pdf->font,'',8);
+ $pdf->MultiCell(153,$hauteur_block,tep_correct_entitie_put_pdf($rows['name']),1,'L');
+
+ $Y_Table_Position += $hauteur_block_r;
+
+ /* Check for product line overflow*/
+ $item_count++;
+ if ((is_long($item_count / 32) && $i >= 20) || ($i == 20)){
+ $pdf->AddPage();
+ //Fields Name position
+ $Y_Fields_Name_position = 125;
+ //Table position, under Fields Name
+ $Y_Table_Position = 70;
+ output_table_heading($Y_Table_Position-$hauteur_block_r);
+ if ($i == 20) $item_count = 1;
+ }
+ }
+}
+?>
\ No newline at end of file
Modified: trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php
===================================================================
--- trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php 2012-02-29 09:26:27 UTC (rev 4050)
+++ trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/invoice.php 2012-03-01 15:58:39 UTC (rev 4051)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9
- @date 16/06/10, 10:54
+ @version 2.1.1
+ @date 01/03/2012, 10:55
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -14,100 +14,188 @@
// Add the first page
$pdf->AddPage();
-/**
-Ligne + titre doc
-*/
-$pdf->Cell(50);
-$pdf->SetY(60);
-$pdf->SetDrawColor(153,153,153);
-$pdf->Cell(15,.1,'',1,1,'L',1);
-$pdf->SetFont('Arial','BI',15);
-$pdf->SetTextColor(153,153,153);
-$pdf->Text(22,61.5,tep_correct_entitie_put_pdf(PRINT_INVOICE_HEADING));
-$pdf->SetY(60);
-$pdf->SetDrawColor(153,153,153);
-$pdf->Cell(38);
-$pdf->Cell(160,.1,'',1,1,'L',1);
-/**
-Block des Adresse client
-*/
-$le_Y=67;
-$hauteur_block=35;
-//Draw Box for Invoice Address
-$pdf->SetDrawColor(0);
-$pdf->SetLineWidth(0.2);
-$pdf->SetFillColor(245);
-$pdf->RoundedRect(6, $le_Y, 90, $hauteur_block, 2, 'DF');
-//Draw the invoice address text
-$pdf->SetFont('Arial','B',10);
-$pdf->SetTextColor(0);
-$pdf->Text(11,77, tep_correct_entitie_put_pdf(ENTRY_SOLD_TO) );
-$pdf->SetX(0);
-$pdf->SetY(80);
-$pdf->Cell(9);
-$pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->customer, '', '', "\n")),0,'L');
+ /**
+ EOB -- header
+ */
+ $le_Y=($le_Y+$marge_block);
+ $hauteur_block=11;
+ $pdf->SetFont($pdf->font,'BI',15);
+ $pdf->SetTextColor($pdf->txt_color_1);
-//Draw Box for Delivery Address
-$pdf->SetDrawColor(0);
-$pdf->SetLineWidth(0.2);
-$pdf->SetFillColor(255);
-$pdf->RoundedRect(108, $le_Y, 90, $hauteur_block, 2, 'DF');
+ $pdf->SetXY(155,$le_Y);
+ //Draw Order Number Text
+ $pdf->Cell(48,$hauteur_block, __('iv print doc type invoice') , 0, 0,"R");
-//Draw the invoice delivery address text
-$pdf->SetFont('Arial','B',10);
-$pdf->SetTextColor(0);
-$pdf->Text(113,77,tep_correct_entitie_put_pdf(ENTRY_SHIP_TO));
-$pdf->SetX(0);
-$pdf->SetY(80);
-$pdf->Cell(111);
-$pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->delivery, '', '', "\n")),0,'L');
+ $le_Y=($le_Y+$hauteur_block);
+ $hauteur_block=11;
+ //Draw Box for Order Number, Date & Payment method
+ $pdf->SetDrawColor(0);
+ $pdf->SetLineWidth(0.2);
+ $pdf->SetFillColor($pdf->bg_color_1);
+ $pdf->RoundedRect(155, $le_Y, 48, $hauteur_block, 2, 'DF');
-/**
-Block order id et date
-*/
-$le_Y=($le_Y+$hauteur_block+$marge_block);
-$hauteur_block=11;
-//Draw Box for Order Number, Date & Payment method
-$pdf->SetDrawColor(0);
-$pdf->SetLineWidth(0.2);
-$pdf->SetFillColor(245);
-$pdf->RoundedRect(6, $le_Y, 192, $hauteur_block, 2, 'DF');
-//Draw Order Number Text
-$temp = tep_correct_entitie_put_pdf(PRINT_INVOICE_ORDERNR);
-$pdf->Text(10,113, $temp . $order->info['orders_prefix'].$orders['orders_id']);
-//Draw Date of Order Text
-$temp = tep_correct_entitie_put_pdf (PRINT_INVOICE_DATE);
-$pdf->Text(130,113,$temp . tep_correct_entitie_put_pdf(tep_date_short($order->info['date_purchased'])));
+ $pdf->SetFont($pdf->font,'BI',15);
+ $pdf->SetTextColor($pdf->txt_color_1);
+ $pdf->SetXY(155,$le_Y);
+ //Draw Order Number Text
+ $temp = tep_correct_entitie_put_pdf(__('iv print packingslip ordernr'));
+ $pdf->Cell(48,$hauteur_block, 'FA-'.$order->info['orders_prefix'].$order->info['orders_id'], 0, 0,"C");
+
+ $pdf->SetFont($pdf->font,'BI',10);
+ $le_Y=($le_Y+$hauteur_block);
+ $pdf->SetXY(155,$le_Y);
+ $pdf->Cell(48,$hauteur_block, sprintf(__('iv print doc date order %s'), tep_date_short($order->info['date_purchased'])) , 0, 0,"R");
+
+ /**
+ EOF -- header
+ */
+
+ /**
+ Ligne cesure + marque pliage
+ */
+ $pdf->Cell(50);
+ $pdf->SetY(60);
+ $pdf->SetDrawColor(153,153,153);
+ $pdf->Cell(197,.1,'',1,1,'L',1);
+
+
+ /**
+ Block de Adresse owner shop
+ */
+
+ $le_Y=67;
+ $hauteur_block=35;
+ //Draw Box for Invoice Address
+ $pdf->SetDrawColor(0);
+ $pdf->SetLineWidth(0.2);
+ $pdf->SetFillColor($pdf->bg_color_1);
+ $pdf->RoundedRect(6, $le_Y, 90, 35, 2, 'DF');
+
+ //Draw the invoice address text
+ $pdf->SetFont($pdf->font,'B',10);
+ $pdf->SetTextColor($pdf->txt_color_1);
+ $pdf->Text(11,77, tep_correct_entitie_put_pdf(__('')));
+ $pdf->SetX(0);
+ $pdf->SetY(80);
+ $pdf->Cell(9);
+ $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(STORE_NAME_ADDRESS),0,'L');
+
+
+ /**
+ Block de Adresse customers
+ */
+
+ //Draw Box for Delivery Address
+ $pdf->SetDrawColor(0);
+ $pdf->SetLineWidth(0.2);
+ $pdf->SetFillColor(255);
+ $pdf->RoundedRect(113, $le_Y, 90, 35, 2, 'DF');
+
+ //Draw the invoice delivery address text
+ $pdf->SetFont($pdf->font,'B',10);
+ $pdf->SetTextColor($pdf->txt_color_1);
+ $pdf->Text(117,77,tep_correct_entitie_put_pdf(__('iv entry order to')));
+ $pdf->SetX(0);
+ $pdf->SetY(80);
+ $pdf->Cell(115);
+ $pdf->MultiCell(71, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->customer, '', '', "\n")),0,'L');
+
+
+
+
+
+// if (isset($_POST) && isset($_POST['show_pay_method'])){
/**
-Method payement
+ Method payement
*/
-if (isset($_POST) && isset($_POST['show_pay_method'])){
-$le_Y=($le_Y+$hauteur_block+$marge_block);
-$hauteur_block=11;
+ $le_Y=($le_Y+$hauteur_block+$marge_block);
+ $hauteur_block=9;
+ $pdf->SetDrawColor(0);
+ $pdf->SetLineWidth(0.2);
+ $pdf->SetFillColor($pdf->bg_color_1);
+ $pdf->RoundedRect(6, $le_Y, 197, $hauteur_block, 2, 'DF');
+ $pdf->Text(10,($le_Y+6),tep_correct_entitie_put_pdf(sprintf(__('iv entry payment method %s') , $order->info['payment_method'])), 0, 0, 'R');
-$pdf->SetDrawColor(0);
-$pdf->SetLineWidth(0.2);
-$pdf->SetFillColor(245);
-$pdf->RoundedRect(6, $le_Y, 192, $hauteur_block, 2, 'DF');
-$pdf->Text(10,127,tep_correct_entitie_put_pdf(ENTRY_PAYMENT_METHOD . ' ' . $order->info['payment_method']), 0, 0, 'R');
-}
+// }
+
+
+
+
+
+
+
+
/**
Block detail commande
*/
+
+
+
+
//Fields Name position
$Y_Fields_Name_position = ($le_Y+$hauteur_block+$marge_block);
$item_count=0;
//Table position, under Fields Name
$Y_Table_Position = ($Y_Fields_Name_position+6);
-output_table_heading($Y_Fields_Name_position);
+ //First create each Field Name
+ //Gray color filling each Field Name box
+ $pdf->SetFillColor($pdf->bg_color_1);
+ //Bold Font for Field Name
+ $pdf->SetFont($pdf->font,'B',10);
+ $pdf->SetY($Y_Fields_Name_position);
+
+ $X_pos = 6;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 9;
+ $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading qty orders')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 25;
+ $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading products model')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 83;
+ $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading products')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 20;
+ $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading price excluding tax')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 20;
+ $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading price including tax')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 20;
+ $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading total excluding tax')),1,0,'C',1);
+
+ $X_pos +=$cell_w;
+ $pdf->SetX($X_pos);
+
+ $cell_w = 20;
+ $pdf->Cell($cell_w,6,tep_correct_entitie_put_pdf(__('iv table heading total including tax')),1,0,'C',1);
+ $pdf->Ln();
+
+
//Show the products information line by line
for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) {
$hauteur_block=$hauteur_block_r=6;
@@ -123,46 +211,72 @@
for ($j = 0; $j < $k; $j++) {
$ligne="\n - ".$order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value'];
if (strlen($ligne) > 40 ) {
- $r=tep_wordwrap($ligne, 40);
- $order->products[$i]['name'] .=$r['txt'];
- $nbr_l +=$r['nbr'];
+ $r=tep_wordwrap($ligne, 40);
+ $order->products[$i]['name'] .=$r['txt'];
+ $nbr_l +=$r['nbr'];
} else {
- $order->products[$i]['name'] .=$ligne;
- $nbr_l +=1;
+ $order->products[$i]['name'] .=$ligne;
+ $nbr_l +=1;
}
}
}
+
+
$hauteur_block_r=($nbr_l*$hauteur_block_r);
+ $X_pos = 6;
+
+
+
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
// qty
- $pdf->SetFont('Arial','',10);
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(6);
- $pdf->MultiCell(9,$hauteur_block_r,$order->products[$i]['qty'],1,'C');
+ $cell_w = 9;
+ $pdf->SetFont($pdf->font,'',10);
+ $pdf->MultiCell($cell_w,$hauteur_block_r,$order->products[$i]['qty'],1,'C');
+
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
// modele
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(15);
- $pdf->SetFont('Arial','',8);
- $pdf->MultiCell(25,$hauteur_block_r,tep_correct_entitie_put_pdf($order->products[$i]['model']),1,'C');
+ $cell_w = 25 ;
+ $pdf->SetFont($pdf->font,'',8);
+ $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($order->products[$i]['model']),1,'C');
+
+
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
// name
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(40);
- $pdf->SetFont('Arial','',8);
- $pdf->MultiCell(78,$hauteur_block,tep_correct_entitie_put_pdf($order->products[$i]['name']),1,'L');
+ $cell_w = 83 ;
+ $pdf->SetFont($pdf->font,'',8);
+ $pdf->MultiCell($cell_w ,$hauteur_block,tep_correct_entitie_put_pdf($order->products[$i]['name']),1,'L');
+
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
// totaux / prix
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(118);
- $pdf->SetFont('Arial','',10);
- $pdf->MultiCell(20,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format($order->products[$i]['final_price'], true, $order->info['currency'], $order->info['currency_value'])),1,'C');
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(138);
- $pdf->MultiCell(20,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']), true, $order->info['currency'], $order->info['currency_value'])),1,'C');
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(158);
- $pdf->MultiCell(20,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format($order->products[$i]['final_price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value'])),1,'C');
- $pdf->SetY($Y_Table_Position);
- $pdf->SetX(178);
- $pdf->MultiCell(20,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']) * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value'])),1,'C');
+ $cell_w = 20;
+ $pdf->SetFont($pdf->font,'',10);
+ $pdf->MultiCell($cell_w ,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format($order->products[$i]['final_price'], true, $order->info['currency'], $order->info['currency_value']), false),1,'C');
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
+ $cell_w = 20;
+ $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']), true, $order->info['currency'], $order->info['currency_value']), false),1,'C');
+
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
+ $cell_w = 20;
+ $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format($order->products[$i]['final_price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']), false),1,'C');
+
+ $X_pos +=$cell_w;
+ $pdf->SetXY( $X_pos , $Y_Table_Position);
+
+ $cell_w = 20;
+ $pdf->MultiCell($cell_w,$hauteur_block_r,tep_correct_entitie_put_pdf($currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']) * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']), false),1,'C');
+
/* Check for product line overflow*/
$item_count++;
if ((is_long($item_count / 32) && $i >= 20) || ($i == 20)){
@@ -187,7 +301,7 @@
$pdf->MultiCell(130,6,tep_correct_entitie_put_pdf($order->totals[$i]['title'],true) ,0,'R');
$pdf->SetY($Y_Table_Position );
$pdf->SetX(146);
- $pdf->MultiCell(50,6, tep_correct_entitie_put_pdf($order->totals[$i]['text'],false),0,'R');
+ $pdf->MultiCell(54,6, tep_correct_entitie_put_pdf($order->totals[$i]['text'],false),0,'R');
}
if (isset($_POST) && isset($_POST['show_pay_method'])){
@@ -198,7 +312,7 @@
$Y_Table_Position=($Y_Table_Position+$marge_block);
while ($orders_comments = $orders_comments_query->fectAssoc()) {
if(tep_not_null($orders_comments['comments'])){
- $pdf->SetFont('Arial','',10);
+ $pdf->SetFont($pdf->font,'',10);
$pdf->SetY($Y_Table_Position);
$pdf->SetX(6);
$pdf->MultiCell(35,6,date(TEXT_ORDER_FORMAT, strtotime($orders_comments['date_added'])),0,'C');
Modified: trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/packingslip.php
===================================================================
--- trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/packingslip.php 2012-02-29 09:26:27 UTC (rev 4050)
+++ trunk/catalog/Documents/modeles/pdf/harry/publicCustomers/packingslip.php 2012-03-01 15:58:39 UTC (rev 4051)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
- @version 2.0.9
- @date 16/06/10, 10:55
+ @version 2.1.1
+ @date 01/03/2012, 10:55
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -16,85 +16,111 @@
// Add the first page
$pdf->AddPage();
-/**
- Ligne + titre doc
-*/
- $pdf->Cell(50);
- $pdf->SetY(60);
- $pdf->SetDrawColor(153,153,153);
- $pdf->Cell(15,.1,'',1,1,'L',1);
- $pdf->SetFont('Arial','BI',15);
- $pdf->SetTextColor(153,153,153);
- $pdf->Text(22,61.5,tep_correct_entitie_put_pdf(PRINT_PACKINGSLIP_HEADING));
- $pdf->SetY(60);
- $pdf->SetDrawColor(153,153,153);
- $pdf->Cell(65);
- $pdf->Cell(126.6,.1,'',1,1,'L',1);
-/**
- Block des Adresse client
-*/
+ /**
+ EOB -- header
+ */
+ $le_Y=($le_Y+$marge_block);
+ $hauteur_block=11;
+ $pdf->SetFont($pdf->font,'BI',15);
+ $pdf->SetTextColor($pdf->txt_color_1);
+
+ $pdf->SetXY(155,$le_Y);
+ //Draw Order Number Text
+ $pdf->Cell(48,$hauteur_block, __('ps print doc type packingslip') , 0, 0,"R");
+
+
+ $le_Y=($le_Y+$hauteur_block);
+ $hauteur_block=11;
+ //Draw Box for Order Number, Date & Payment method
+ $pdf->SetDrawColor(0);
+ $pdf->SetLineWidth(0.2);
+ $pdf->SetFillColor($pdf->bg_color_1);
+ $pdf->RoundedRect(155, $le_Y, 48, $hauteur_block, 2, 'DF');
+
+
+ $pdf->SetFont($pdf->font,'BI',15);
+ $pdf->SetTextColor($pdf->txt_color_1);
+
+ $pdf->SetXY(155,$le_Y);
+ //Draw Order Number Text
+ $temp = tep_correct_entitie_put_pdf(__('ps print packingslip ordernr'));
+ $pdf->Cell(48,$hauteur_block, 'BC-'.$order->info['orders_prefix'].$order->info['orders_id'], 0, 0,"C");
+
+ $pdf->SetFont($pdf->font,'BI',10);
+ $le_Y=($le_Y+$hauteur_block);
+ $pdf->SetXY(155,$le_Y);
+ $pdf->Cell(48,$hauteur_block, sprintf(__('ps print doc date order %s'), tep_date_short($order->info['date_purchased'])) , 0, 0,"R");
+
+ /**
+ EOF -- header
+ */
+
+
+
+ /**
+ Ligne cesure + marque pliage
+ */
+ $pdf->Cell(50);
+ $pdf->SetY(60);
+ $pdf->SetDrawColor(153,153,153);
+ $pdf->Cell(197,.1,'',1,1,'L',1);
+
+
+ /**
+ Block de Adresse owner shop
+ */
+
$le_Y=67;
$hauteur_block=35;
//Draw Box for Invoice Address
$pdf->SetDrawColor(0);
$pdf->SetLineWidth(0.2);
- $pdf->SetFillColor(245);
+ $pdf->SetFillColor($pdf->bg_color_1);
$pdf->RoundedRect(6, $le_Y, 90, 35, 2, 'DF');
//Draw the invoice address text
- $pdf->SetFont('Arial','B',10);
- $pdf->SetTextColor(0);
- $pdf->Text(11,77, tep_correct_entitie_put_pdf(ENTRY_SOLD_TO));
+ $pdf->SetFont($pdf->font,'B',10);
+ $pdf->SetTextColor($pdf->txt_color_1);
+ $pdf->Text(11,77, tep_correct_entitie_put_pdf(__('')));
$pdf->SetX(0);
$pdf->SetY(80);
$pdf->Cell(9);
- $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->customer, '', '', "\n")),0,'L');
+ $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(STORE_NAME_ADDRESS),0,'L');
+
+ /**
+ Block de Adresse customers
+ */
+
//Draw Box for Delivery Address
$pdf->SetDrawColor(0);
$pdf->SetLineWidth(0.2);
$pdf->SetFillColor(255);
- $pdf->RoundedRect(108, $le_Y, 90, 35, 2, 'DF');
+ $pdf->RoundedRect(113, $le_Y, 90, 35, 2, 'DF');
//Draw the invoice delivery address text
- $pdf->SetFont('Arial','B',10);
- $pdf->SetTextColor(0);
- $pdf->Text(113,77,tep_correct_entitie_put_pdf(ENTRY_SHIP_TO));
+ $pdf->SetFont($pdf->font,'B',10);
+ $pdf->SetTextColor($pdf->txt_color_1);
+ $pdf->Text(117,77,tep_correct_entitie_put_pdf(__('ps entry ship to')));
$pdf->SetX(0);
$pdf->SetY(80);
- $pdf->Cell(111);
- $pdf->MultiCell(70, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->delivery, '', '', "\n")),0,'L');
+ $pdf->Cell(115);
+ $pdf->MultiCell(71, 3.3, tep_correct_entitie_put_pdf(tep_address_format(1, $order->delivery, '', '', "\n")),0,'L');
-/**
- Block id commande et date
-*/
- $le_Y=($le_Y+$hauteur_block+$marge_block);
- $hauteur_block=11;
- //Draw Box for Order Number, Date & Payment method
- $pdf->SetDrawColor(0);
- $pdf->SetLineWidth(0.2);
- $pdf->SetFillColor(245);
- $pdf->RoundedRect(6, $le_Y, 192, $hauteur_block, 2, 'DF');
- //Draw Order Number Text
- $temp = tep_correct_entitie_put_pdf(PRINT_PACKINGSLIP_ORDERNR);
- $pdf->Text(10,113, $temp . $order->info['orders_prefix'].$orders['orders_id']);
- //Draw Date of Order Text
- $temp = tep_correct_entitie_put_pdf(PRINT_INVOICE_DATE);
- $pdf->Text(130,113,$temp . tep_date_short($order->info['date_purchased']));
/**
Method payement
*/
$le_Y=($le_Y+$hauteur_block+$marge_block);
- $hauteur_block=11;
+ $hauteur_block=9;
$pdf->SetDrawColor(0);
$pdf->SetLineWidth(0.2);
- $pdf->SetFillColor(245);
- $pdf->RoundedRect(6, $le_Y, 192, $hauteur_block, 2, 'DF');
- $pdf->Text(10,127,tep_correct_entitie_put_pdf(ENTRY_PAYMENT_METHOD . ' ' . $order->info['payment_method']), 0, 0, 'R');
+ $pdf->SetFillColor($pdf->bg_color_1);
+ $pdf->RoundedRect(6, $le_Y, 197, $hauteur_block, 2, 'DF');
+ $pdf->Text(10,($le_Y+6),tep_correct_entitie_put_pdf(sprintf(__('ps entry payment method %s') , $order->info['payment_method'])), 0, 0, 'R');
/**
@@ -106,7 +132,20 @@
//Table position, under Fields Name
$Y_Table_Position = ($Y_Fields_Name_position+6);
-output_table_heading_packingslip($Y_Fields_Name_position);
+// output_table_heading_packingslip($Y_Fields_Name_position);
+ //First create each Field Name
+ //Gray color filling each Field Name box
+ $pdf->SetFillColor($pdf->bg_color_1);
+ //Bold Font for Field Name
+ $pdf->SetFont($pdf->font,'B',10);
+ $pdf->SetY($Y_Fields_Name_position);
+ $pdf->SetX(6);
+ $pdf->Cell(9,6,tep_correct_entitie_put_pdf(__('ps table heading qty orders')),1,0,'C',1);
+ $pdf->SetX(15);
+ $pdf->Cell(25,6,tep_correct_entitie_put_pdf(__('ps table heading products model')),1,0,'C',1);
+ $pdf->SetX(40);
+ $pdf->Cell(163,6,tep_correct_entitie_put_pdf(__('ps table heading products')),1,0,'C',1);
+
//Show the products information line by line
for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) {
$hauteur_block=$hauteur_block_r=6;
@@ -133,21 +172,21 @@
}
$hauteur_block_r=($nbr_l*$hauteur_block_r);
// quantite
- $pdf->SetFont('Arial','',10);
+ $pdf->SetFont($pdf->font,'',10);
$pdf->SetY($Y_Table_Position);
$pdf->SetX(6);
$pdf->MultiCell(9,$hauteur_block_r,$order->products[$i]['qty'],1,'C');
// modele
$pdf->SetY($Y_Table_Position);
$pdf->SetX(15);
- $pdf->SetFont('Arial','',8);
+ $pdf->SetFont($pdf->font,'',8);
$pdf->MultiCell(25,$hauteur_block_r,tep_correct_entitie_put_pdf($order->products[$i]['model']),1,'C');
// nom product
$pdf->SetY($Y_Table_Position);
$pdf->SetX(40);
- $pdf->SetFont('Arial','',8);
- $pdf->MultiCell(158,$hauteur_block,tep_correct_entitie_put_pdf($order->products[$i]['name']),1,'L');
+ $pdf->SetFont($pdf->font,'',8);
+ $pdf->MultiCell(163,$hauteur_block,tep_correct_entitie_put_pdf($order->products[$i]['name']),1,'L');
$Y_Table_Position += $hauteur_block_r;
Modified: trunk/catalog/admin/document.php
===================================================================
--- trunk/catalog/admin/document.php 2012-02-29 09:26:27 UTC (rev 4050)
+++ trunk/catalog/admin/document.php 2012-03-01 15:58:39 UTC (rev 4051)
@@ -66,31 +66,45 @@
/**
@brief Traitement des pdf
*/
+ case 'delivery':
+ if(( $filepath=DatasFiles::GetDoc('delivery', $_REQUEST['id'])) && file_exists(DIR_FS_ROOT_DOCS.$filepath)) {
+ //We send to a browser
+ header('Content-Type: application/pdf');
+ // header('Content-Length: '.strlen($this->buffer));
+ header('Content-Disposition: inline; filename="'.basename($filepath).'"');
+ header('Cache-Control: private, max-age=0, must-revalidate');
+ header('Pragma: public');
+ ini_set('zlib.output_compression','0');
+
+ readfile(DIR_FS_ROOT_DOCS.$filepath);
+ }
+ break;
+
case 'packingslip':
if(( $filepath=DatasFiles::GetDoc('packingslip', $_REQUEST['id'])) && file_exists(DIR_FS_ROOT_DOCS.$filepath)) {
- //We send to a browser
- header('Content-Type: application/pdf');
- // header('Content-Length: '.strlen($this->buffer));
- header('Content-Disposition: inline; filename="'.basename($filepath).'"');
- header('Cache-Control: private, max-age=0, must-revalidate');
- header('Pragma: public');
- ini_set('zlib.output_compression','0');
+ //We send to a browser
+ header('Content-Type: application/pdf');
+ // header('Content-Length: '.strlen($this->buffer));
+ header('Content-Disposition: inline; filename="'.basename($filepath).'"');
+ header('Cache-Control: private, max-age=0, must-revalidate');
+ header('Pragma: public');
+ ini_set('zlib.output_compression','0');
- readfile(DIR_FS_ROOT_DOCS.$filepath);
+ readfile(DIR_FS_ROOT_DOCS.$filepath);
}
break;
case 'invoice':
if(( $filepath=DatasFiles::GetDoc('invoices', $_REQUEST['id'])) && file_exists(DIR_FS_ROOT_DOCS.$filepath)) {
- //We send to a browser
- header('Content-Type: application/pdf');
- // header('Content-Length: '.strlen($this->buffer));
- header('Content-Disposition: inline; filename="'.basename($filepath).'"');
- header('Cache-Control: private, max-age=0, must-revalidate');
- header('Pragma: public');
- ini_set('zlib.output_compression','0');
+ //We send to a browser
+ header('Content-Type: application/pdf');
+ // header('Content-Length: '.strlen($this->buffer));
+ header('Content-Disposition: inline; filename="'.basename($filepath).'"');
+ header('Cache-Control: private, max-age=0, must-revalidate');
+ header('Pragma: public');
+ ini_set('zlib.output_compression','0');
- readfile(DIR_FS_ROOT_DOCS.$filepath);
+ readfile(DIR_FS_ROOT_DOCS.$filepath);
}
break;
Modified: trunk/catalog/admin/includes/classes/drivers/sqlorder.php
===================================================================
--- trunk/catalog/admin/includes/classes/drivers/sqlorder.php 2012-02-29 09:26:27 UTC (rev 4050)
+++ trunk/catalog/admin/includes/classes/drivers/sqlorder.php 2012-03-01 15:58:39 UTC (rev 4051)
@@ -163,37 +163,37 @@
$row = new objectInfo($option['delivery']);
if(!isset($row->activate) || empty($row->activate) )
- $shipping = false ;
+ $shipping = false ;
else
- $shipping = true ;
+ $shipping = true ;
if($shipping){
- $sql_data_array['delivery_name'] = (string)(!empty($row->name)) ? tep_db_prepare_input($row->name) : '' ;
- $sql_data_array['delivery_company'] = (string)(!empty($row->company)) ? tep_db_prepare_input($row->company) : '' ;
- $sql_data_array['delivery_street_address'] = (string)(!empty($row->street_address)) ? tep_db_prepare_input($row->street_address) : '' ;
- $sql_data_array['delivery_suburb'] = (string)(!empty($row->suburb)) ? tep_db_prepare_input($row->suburb) : '' ;
- $sql_data_array['delivery_city'] = (string)(!empty($row->city)) ? tep_db_prepare_input($row->city) : '' ;
- $sql_data_array['delivery_postcode'] = (string)(!empty($row->postcode)) ? tep_db_prepare_input($row->postcode) : '' ;
- $sql_data_array['delivery_state'] = (string)(!empty($row->state)) ? tep_db_prepare_input($row->state) : '' ;
- $sql_data_array['delivery_country'] = (string)(!empty($row->country)) ? worldUtility::get_country_name($row->country) : '' ;
- $sql_data_array['delivery_address_format_id'] = (int)(!empty($row->format_id)) ? tep_db_prepare_input($row->format_id) : worldUtility::GetCountryFormatAddress($row->country) ;
+ $sql_data_array['delivery_name'] = (string)(!empty($row->name)) ? tep_db_prepare_input($row->name) : '' ;
+ $sql_data_array['delivery_company'] = (string)(!empty($row->company)) ? tep_db_prepare_input($row->company) : '' ;
+ $sql_data_array['delivery_street_address'] = (string)(!empty($row->street_address)) ? tep_db_prepare_input($row->street_address) : '' ;
+ $sql_data_array['delivery_suburb'] = (string)(!empty($row->suburb)) ? tep_db_prepare_input($row->suburb) : '' ;
+ $sql_data_array['delivery_city'] = (string)(!empty($row->city)) ? tep_db_prepare_input($row->city) : '' ;
+ $sql_data_array['delivery_postcode'] = (string)(!empty($row->postcode)) ? tep_db_prepare_input($row->postcode) : '' ;
+ $sql_data_array['delivery_state'] = (string)(!empty($row->state)) ? tep_db_prepare_input($row->state) : '' ;
+ $sql_data_array['delivery_country'] = (string)(!empty($row->country)) ? worldUtility::get_country_name($row->country) : '' ;
+ $sql_data_array['delivery_address_format_id'] = (int)(!empty($row->format_id)) ? tep_db_prepare_input($row->format_id) : worldUtility::GetCountryFormatAddress($row->country) ;
- self::$comment[] = __('orders inline comment update delivery address');
+ self::$comment[] = __('orders inline comment update delivery address');
}
else {
- // force reset data
- $sql_data_array['delivery_name'] = (string) '' ;
- $sql_data_array['delivery_company'] = (string) '' ;
- $sql_data_array['delivery_street_address'] = (string) '' ;
- $sql_data_array['delivery_suburb'] = (string) '' ;
- $sql_data_array['delivery_city'] = (string) '' ;
- $sql_data_array['delivery_postcode'] = (string)'' ;
- $sql_data_array['delivery_state'] = (string) '' ;
- $sql_data_array['delivery_country'] = (string) '' ;
- $sql_data_array['delivery_address_format_id'] = (int)0 ;
+ // force reset data
+ $sql_data_array['delivery_name'] = (string) '' ;
+ $sql_data_array['delivery_company'] = (string) '' ;
+ $sql_data_array['delivery_street_address'] = (string) '' ;
+ $sql_data_array['delivery_suburb'] = (string) '' ;
+ $sql_data_array['delivery_city'] = (string) '' ;
+ $sql_data_array['delivery_postcode'] = (string)'' ;
+ $sql_data_array['delivery_state'] = (string) '' ;
+ $sql_data_array['delivery_country'] = (string) '' ;
+ $sql_data_array['delivery_address_format_id'] = (int)0 ;
- self::$comment[] = __('orders inline comment delete delivery address');
+ self::$comment[] = __('orders inline comment delete delivery address');
}
}
@@ -202,43 +202,43 @@
if(isset($option['mod']) && is_array($option['mod']) ) {
foreach($option['mod'] as $key=>$row)
- switch($key){
- case 'payment':
- $sql_data_array['class_payment'] = (string)$row ;
- $sql_data_array['payment_method'] = (string)( (isset(self::$modules_type->payment->modules[$row]->txt_in_order ))? self::$modules_type->payment->modules[$row]->txt_in_order : self::$modules_type->payment->modules[$row]->title );
+ switch($key){
+ case 'payment':
+ $sql_data_array['class_payment'] = (string)$row ;
+ $sql_data_array['payment_method'] = (string)( (isset(self::$modules_type->payment->modules[$row]->txt_in_order ))? self::$modules_type->payment->modules[$row]->txt_in_order : self::$modules_type->payment->modules[$row]->title );
- /// force check and save module payment selected
- self::$modules_type->payment->modules[$row]->load_post_values($post);
+ /// force check and save module payment selected
+ self::$modules_type->payment->modules[$row]->load_post_values($post);
- self::$modules_type->payment->modules[$row]->after_update($id);
-/**
- TODO Add in history
-*/
- self::$comment[] = __('orders inline comment update method payment');
- break;
- case 'shipping':
+ self::$modules_type->payment->modules[$row]->after_update($id);
+ /**
+ TODO Add in history
+ */
+ self::$comment[] = __('orders inline comment update method payment');
+ break;
+ case 'shipping':
- /**
- TODO Add no methode force
- */
-// if($shipping) {
- $sql_data_array['class_shipping'] = (string)$row ;
+ /**
+ TODO Add no methode force
+ */
+ // if($shipping) {
+ $sql_data_array['class_shipping'] = (string)$row ;
- /// force check and save module payment selected
- self::$modules_type->shipping->modules[$row]->load_post_values($post);
+ /// force check and save module payment selected
+ self::$modules_type->shipping->modules[$row]->load_post_values($post);
- self::$modules_type->shipping->modules[$row]->after_update($id);
+ self::$modules_type->shipping->modules[$row]->after_update($id);
- /**
- TODO Add in history
- */
- self::$comment[] = __('orders inline comment update method delivery');
-// }
-// else
-// // $sql_data_array['class_shipping'] = (string)'';
+ /**
+ TODO Add in history
+ */
+ self::$comment[] = __('orders inline comment update method delivery');
+ // }
+ // else
+ // // $sql_data_array['class_shipping'] = (string)'';
- break;
- }
+ break;
+ }
}
@@ -260,52 +260,6 @@
self::AddOrderHistory($id, $status , 0/*$notif*/, implode("<br />", self::$comment) );
-// $list_languages=tep_get_languages();
-//
-// $sql_data_array = $option['sqlarray'];
-//
-// $sql_data_array['last_modified'] = 'now()';
-// $sql_data_array['sort_order'] = (!empty($post['sort_order'])) ? tep_db_prepare_input((int)$post['sort_order']) : 0 ;
-// $sql_data_array['parent_id'] = (!empty($sql_data_array['parent_id'])) ? tep_db_prepare_input((int)$sql_data_array['parent_id']) : 0 ;
-// $sql_data_array['categories_cpath'] = categorieUtility::get_generated_category_path_ids($id,'category');
-// $sql_data_array['categories_status'] = (!empty($post['categories_status'])) ? tep_db_prepare_input((int)$post['categories_status']) : 0 ;
-// $sql_data_array['categories_hidden'] = (!empty($post['categories_hidden'])) ? tep_db_prepare_input((int)$post['categories_hidden']) : 0 ;
-
-
- // Put post value
-// self::$modules->load_post_values($post);
-
-// $sql_data_array=array_merge($sql_data_array, (array) self::$modules->get_update_table_categories($sql_data_array) );
-//
-//
-
-//
-// $categories_name_array = $post['categories_name'];
-// $categories_desc_array = $post['categories_description'];
-//
-//
-// for ($i=0, $n=sizeof($list_languages); $i<$n; $i++) {
-//
-// $language_id = (int)$list_languages[$i]['id'];
-// $sql_data_array = array('categories_name' => tep_db_prepare_input($categories_name_array[$language_id]),
-// 'categories_description'=>tep_db_prepare_input($categories_desc_array[$language_id]));
-//
-// $tabl=self::$modules->get_update_table_categories_description ($list_languages[$i]['id']);
-// $sql_data_array = array_merge($sql_data_array, $tabl);
-//
-// tep_db_perform(TABLE_CATEGORIES_DESCRIPTION, $sql_data_array, 'update', "categories_id = '" . $id . "' and language_id = '" . $language_id . "'");
-//
-// }
-//
-// // if ( !empty($_FILES['categories_image']['tmp_name']) ) {
-// // $categories_image = new upload('categories_image', DIR_FS_CATALOG_IMAGES);
-// // tep_db_query("update " . TABLE_CATEGORIES . " set categories_image = '" . tep_db_input($categories_image->filename) . "' where categories_id = '" . (int)$categories_id . "'");
-// // }
-
-
-
-
-
if($error !=false)
return false;
else
@@ -455,17 +409,7 @@
$par = array(
'orders_id'=>'',
-// 'configuration_key',
-// 'configuration_title',
-// 'configuration_value',
-// 'configuration_description',
-// 'configuration_group_id',
-// 'sort_order',
-// 'date_added',
-// 'last_modified',
-// 'use',
-// 'set',
-'info' => Array
+ 'info' => Array
(
'orders_id' => '',
'orders_prefix' => '',
@@ -494,7 +438,7 @@
),
- 'totals' => Array
+ 'totals' => Array
(
// '0' => Array
// (
@@ -516,7 +460,7 @@
),
- 'products' => Array
+ 'products' => Array
(
'0' => Array
(
@@ -551,7 +495,7 @@
),
- 'customer' => Array
+ 'customer' => Array
(
'id' => '',
'name' => '',
@@ -568,7 +512,7 @@
'email_address' => '',
),
- 'delivery' => Array
+ 'delivery' => Array
(
'name' =>'',
'company' =>'',
@@ -581,9 +525,9 @@
'format_id' => '',
),
- 'content_type' =>'',
- 'coupon' =>'',
- 'billing' => Array
+ 'content_type' =>'',
+ 'coupon' =>'',
+ 'billing' => Array
(
'name' =>'',
'company' =>'',
@@ -596,7 +540,7 @@
'format_id' => '',
),
- 'history' => Array
+ 'history' => Array
(
// '0' => Array
// (
@@ -608,7 +552,7 @@
),
- 'lasthistory' => Array
+ 'lasthistory' => Array
(
// 'date_added' => 10/11/2011 16:05:05
// 'customer_notified' => <img src="images/icons/tick.gif" alt="Vrai" width="16" height="16" title="Vrai" />
Modified: trunk/catalog/admin/includes/gabarit/orders/display_view.edit.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/orders/display_view.edit.gab 2012-02-29 09:26:27 UTC (rev 4050)
+++ trunk/catalog/admin/includes/gabarit/orders/display_view.edit.gab 2012-03-01 15:58:39 UTC (rev 4051)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
- @date 01/11/11, 11:35
+ @date 01/03/2012, 11:35
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
*/
@@ -432,54 +432,44 @@
<?php if(orders::$order->allshipping !=false): ?>
- <ul>
+ <table class="dataTableBase orders shipping allshipping">
+ <thead>
+ <tr>
+ <th><?php echo __('table heading id'); ?></th>
+ <th><?php echo __('table heading date expedition'); ?></th>
+ <th><?php echo __('table heading tracking number'); ?></th>
+ <th><?php echo __('table heading methode'); ?></th>
+ </tr>
+ </thead>
+ <tbody>
<?php $i = 0; foreach (orders::$order->allshipping as $ashipping): $i++; /*print_r($ashipping);*/?>
- <li>
- <h5>
- <span class="text date dateexpedition">
- <?php echo sprintf(__('text shipping expedie le %s'), tep_datetime_short($ashipping->date_expedition) ); ?>
- </span>
+ <?php if(isset($ashipping->row_id)): ?>
+ <tr>
+ <td class="tcenter">
+ <?php echo $ashipping->row_id; ?>
+ </td>
+ <td class="tcenter">
+ <?php echo tep_datetime_short($ashipping->date_expedition); ?>
+ </td>
- <span class="text tracking">
- <?php echo sprintf(__('text shipping tracking n %s'),'<a href="'.$ashipping->tracking_url.'" >'.$ashipping->tracking.'</a>'); ?>
- </span>
+ <td class="tcenter">
+ <?php echo '<a href="'.$ashipping->tracking_url.'" target="blank">'.$ashipping->tracking.'</a>'; ?>
+ </td>
- <span class="text date method">
- <?php echo $ashipping->method; ?>
- </span>
- </h5>
-
- <table class="dataTableBase orders shipping allshipping">
- <thead>
- <tr>
- <th><?php echo __('table heading id'); ?></th>
- <th><?php echo __('table heading products'); ?></th>
- <th><?php echo __('table heading quantity deja expedie'); ?></th>
- </tr>
- </thead>
- <tbody>
- <?php $i = 0; foreach ($ashipping->products as $pshipping): $i++; /*print_r($pshipping);*/?>
- <td class="tcenter"><?php echo $pshipping->products_id ?></td>
- <td class="tleft">
- <span class="fleft">
- <a href="#" class="screenshot" rel="<?php echo tep_href_link('document.php', 'mod=img&typ=product&w=200&h=200&id='.$pshipping->products_id) ?>">
- <?php echo $pshipping->products_name ?>
- </a>
- </td>
- <td class="tcenter">
- <?php echo $pshipping->qt_expedie ?>
- </td>
- <?php endforeach; ?>
- </tbody>
- </table>
-
- </li>
+ <td class="tcenter">
+ <?php echo $ashipping->method; ?>
+ </td>
+ </tr>
+ <?php endif; ?>
<?php endforeach; ?>
- </ul>
+ </tbody>
+ </table>
<?php endif; ?>
<br />
+ <div>
+ <h4><?php echo __('heading form expedition'); ?></h4>
<!-- DEB Form add expedition -->
<?php echo tep_draw_form('add_deliv', orders::FILENAME,'oID='.orders::$oID.'&action=shipping&method=add', 'post', ' class="block_form"'); ?>
<table class="dataTableBase orders">
@@ -545,6 +535,7 @@
<?php echo tep_image_submit('button_update.gif', IMAGE_UPDATE); ?>
</div>
<?php endif; ?>
+ </div>
<!-- END Form add expedition -->
</form>
@@ -619,55 +610,84 @@
-<?php
+
+ <div class="main-orders block fleft w_50 padd_w">
+ </div>
+
+
+ <?php
/**
DRAW BLOCK DOCS EXISTS OR LINK PDF CREATE
*/
-?>
+ $datadocs=new DatasFiles; ?>
<div class="main-orders block fleft w_50 padd_w">
- <h4><?php echo __('heading documents') ?></h4>
+ <h4><?php echo __('heading documents') ?></h4>
- <table class="main-orders docs">
- <thead>
- <tr>
- <th><?php echo __('order table pdf heading file') ?></th>
- <th><?php echo __('order table pdf heading weight') ?></th>
- <th><?php echo __('order table pdf heading date') ?></th>
- </tr>
- </thead>
+ <table class="main-orders docs">
+ <thead>
+ <tr>
+ <th><?php echo __('order table pdf heading file') ?></th>
+ <th><?php echo __('order table pdf heading weight') ?></th>
+ <th><?php echo __('order table pdf heading date') ?></th>
+ </tr>
+ </thead>
- <?php $datadocs=new DatasFiles; ?>
- <tr>
- <th colspan="2"><?php echo IMAGE_ORDERS_PACKINGSLIP ?></th>
- <th><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(FILENAME_BATCH_PRINT, tep_get_all_get_params(array('page_admin','action')).'forceview=pdf&file_type=packingslip&action=exe') . '" onclick="window.open(this.href); return false;">' . __('pdf generate') . '</a>' ; ?></th>
- </tr>
- <?php if(( $filepath=$datadocs->GetDoc('packingslip', $_GET['oID'])) && file_exists($filepath)): ?>
- <tr>
- <td><a href="<?php echo tep_href_link('document.php', 'mod=packingslip&id='.$_GET['oID']) ?>"><?php echo basename($filepath) ?></a></td>
- <td><?php echo round((filesize($filepath)/1000),1).' Ko' ; ?></td>
- <td><?php echo tep_datetime_short(date('Y-m-d H:i:s',filemtime($filepath))) ; ?></td>
- </tr>
- <?php endif; ?>
+ <tr>
+ <th colspan="2"><?php echo IMAGE_ORDERS_PACKINGSLIP ?></th>
+ <th><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('page_admin','action')).'action=pdf&forceview=pdf&file_type=packingslip&id='.$_GET['oID']) . '" >' . __('pdf generate') . '</a>' ; ?></th>
+ </tr>
- <tr>
- <th colspan="2"><?php echo IMAGE_ORDERS_INVOICE ?></th>
- <th><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(FILENAME_BATCH_PRINT, tep_get_all_get_params(array('page_admin','action','forceview')).'forceview=pdf&file_type=invoice&action=exe') . '">' . __('pdf generate') . '</a>' ; ?></th>
- </tr>
+ <?php if(( $filepath=$datadocs->GetDoc('packingslip', $_GET['oID'])) && file_exists($filepath)): ?>
+ <tr>
+ <td><a href="<?php echo tep_href_link('document.php', 'mod=packingslip&id='.$_GET['oID']) ?>"><?php echo basename($filepath) ?></a></td>
+ <td><?php echo round((filesize($filepath)/1000),1).' Ko' ; ?></td>
+ <td><?php echo tep_datetime_short(date('Y-m-d H:i:s',filemtime($filepath))) ; ?></td>
+ </tr>
+ <?php endif; ?>
- <?php if(( $filepath=$datadocs->GetDoc('invoices', $_GET['oID'])) && file_exists($filepath)): ?>
- <tr>
- <td><a href="<?php echo tep_href_link('document.php', 'mod=invoice&id='.$_GET['oID']) ?>"><?php echo basename($filepath) ?></a></td>
- <td><?php echo round((filesize($filepath)/1000),1).' Ko' ; ?></td>
- <td><?php echo tep_datetime_short(date('Y-m-d H:i:s',filemtime($filepath))) ; ?></td>
- </tr>
- <?php endif; ?>
- </table>
- </div>
+ <tr>
+ <th colspan="2"><?php echo __('image orders delivery') ?></th>
+ <th></th>
+ </tr>
+ <?php $i = 0; foreach (orders::$order->allshipping as $ashipping): $i++; /*print_r($ashipping);*/?>
+ <?php if(isset($ashipping->row_id)): ?>
+ <?php if(( $filepath=$datadocs->GetDoc('delivery', $ashipping->row_id)) && file_exists($filepath)): ?>
+ <tr>
+ <td><a href="<?php echo tep_href_link('document.php', 'mod=delivery&id='.$ashipping->row_id) ?>"><?php echo basename($filepath) ?></a></td>
+ <td><?php echo round((filesize($filepath)/1000),1).' Ko' ; ?></td>
+ <td><?php echo tep_datetime_short(date('Y-m-d H:i:s',filemtime($filepath))) ; ?></td>
+ </tr>
+ <?php else: ?>
+ <tr>
+ <td colspan="2"> </td>
+ <td><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('page_admin','action')).'action=pdf&forceview=pdf&file_type=delivery&id='.$ashipping->row_id) . '" >' . __('pdf generate') . '</a>' ; ?> </td>
+ </tr>
+ <?php endif; ?>
+ <?php endif; ?>
+ <?php endforeach ?>
+ <tr>
+ <th colspan="2"><?php echo IMAGE_ORDERS_INVOICE ?></th>
+ <th><?php if(_cst_bool('USE_LOCAL_GENERAT_PDF')) echo '<a class="button" href="' . tep_href_link(FILENAME_ORDERS, tep_get_all_get_params(array('page_admin','action','forceview')).'action=pdf&forceview=pdf&file_type=invoice&id='.$_GET['oID']) . '">' . __('pdf generate') . '</a>' ; ?></th>
+ </tr>
+
+ <?php if(( $filepath=$datadocs->GetDoc('invoices', $_GET['oID'])) && file_exists($filepath)): ?>
+ <tr>
+ <td><a href="<?php echo tep_href_link('document.php', 'mod=invoice&id='.$_GET['oID']) ?>"><?php echo basename($filepath) ?></a></td>
+ <td><?php echo round((filesize($filepath)/1000),1).' Ko' ; ?></td>
+ <td><?php echo tep_datetime_short(date('Y-m-d H:i:s',filemtime($filepath))) ; ?></td>
+ </tr>
+ <?php endif; ?>
+
+ </table>
+ </div>
+
+
+
<div class="button_nav">
<?php echo tep_js_back(tep_href_link(orders::FILENAME), IMAGE_CANCEL);?>
</div>
Added: trunk/catalog/admin/includes/languages/fr_FR/modeles/pdf/harry/harry.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modeles/pdf/harry/harry.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/modeles/pdf/harry/harry.txt 2012-03-01 15:58:39 UTC (rev 4051)
@@ -0,0 +1,46 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 01/03/2012, 23:07
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['dl print doc type delivery']="Bon de Livraison" ;
+$lang['dl print doc date expedition %s']="date d'expedition : %s" ;
+$lang['dl print doc date order %s']="date de commande : %s" ;
+$lang['dl print doc method expedition %s']="Mèthode : %s" ;
+$lang['dl print doc tracking expedition %s']="tracking n° : %s" ;
+$lang['dl entry ship to']="Livraison à :" ;
+$lang['dl table heading qty orders']="Cmd" ;
+$lang['dl table heading qty exedie']="Exp" ;
+$lang['dl table heading products model']="Modéle" ;
+$lang['dl table heading products']="Produit" ;
+
+
+$lang['ps print doc type packingslip']="Bon de Commande" ;
+$lang['ps print doc date order %s']="date de commande : %s" ;
+$lang['ps entry ship to']="Livraison à :" ;
+$lang['ps entry payment method %s']="Mode de paiment : %s" ;
+$lang['ps table heading qty orders']="Cmd" ;
+$lang['ps table heading products model']="Modéle" ;
+$lang['ps table heading products']="Produit" ;
+$lang['ps table heading qty orders']="Cmd" ;
+$lang['ps table heading products model']="Modéle" ;
+$lang['ps table heading products']="Produit" ;
+
+
+$lang['iv print doc type invoice']="Facture" ;
+$lang['iv print doc date order %s']="date de commande : %s" ;
+$lang['iv entry order to']="Facturé à :" ;
+$lang['iv entry payment method %s']="Payé par : %s" ;
+$lang['iv table heading qty orders']="Qté." ;
+$lang['iv table heading products model']="Modéle" ;
+$lang['iv table heading products']="Produit" ;
+$lang['iv table heading price excluding tax']="HT" ;
+$lang['iv table heading price including tax']="TTC" ;
+$lang['iv table heading total excluding tax']="tot. HT" ;
+$lang['iv table heading total including tax']="tot. TTC" ;
+
+?>
\ No newline at end of file
...
[truncated message content] |
|
From: <os...@us...> - 2012-02-29 09:26:37
|
Revision: 4050
http://oscss.svn.sourceforge.net/oscss/?rev=4050&view=rev
Author: oscim
Date: 2012-02-29 09:26:27 +0000 (Wed, 29 Feb 2012)
Log Message:
-----------
correction coquille traitement du listing
Modified Paths:
--------------
trunk/catalog/admin/includes/modules/pages/orders.php
Modified: trunk/catalog/admin/includes/modules/pages/orders.php
===================================================================
--- trunk/catalog/admin/includes/modules/pages/orders.php 2012-02-28 22:06:21 UTC (rev 4049)
+++ trunk/catalog/admin/includes/modules/pages/orders.php 2012-02-29 09:26:27 UTC (rev 4050)
@@ -69,6 +69,10 @@
@var object internal trans objet method check_action vs display_view
*/
private static $internal;
+ /**
+ @var requis pour generation pdf
+ */
+ public static $file_type_array ;
/**
@brief class constructor
@@ -90,19 +94,21 @@
self::$view=(isset($_REQUEST['view'])? (string)$_REQUEST['view'] : 'opened' );
self::$oID=(isset($_REQUEST['oID'])? $_REQUEST['oID'] : '' );
+ $status=(isset($_REQUEST['status'])? (string)$_REQUEST['status'] : '' );
self::$export= new export(__CLASS__);
/**
@remarks define var execution sql in GetDBValue()
*/
- self::$InitInfo['adjust']=array(
- 'languages_id'=>$languages_id,
- 'page'=>1,
- 'rowbyp'=>10,
- 'sOrder'=>'',
- 'sWhere'=>'',
- );
+ if( !isset(self::$InitInfo['adjust']) )
+ self::$InitInfo['adjust']=array(
+ 'languages_id'=>$languages_id,
+ 'page'=>1,
+ 'rowbyp'=>10,
+ 'sOrder'=>'',
+ 'sWhere'=>'',
+ );
@@ -115,7 +121,8 @@
define('JSONSTATMENT', 'mod=page&type='.self::$code.
(isset(parent::$action)?'&action='.parent::$action : '' ).
(isset(self::$oID)?'&oID='.self::$oID : '' ).
- (isset(self::$view)?'&view='.self::$view : '' )
+ (isset(self::$view)?'&view='.self::$view : '' ).
+ (isset($status)?'&status='.$status : '' )
);
//! detail item in ajax
@@ -196,6 +203,40 @@
switch (self::$action) {
/**
+ @remarks pdf generate
+ */
+ case 'pdf':
+ $oID=(int)$_REQUEST['oID'];
+ $type=$_REQUEST['file_type'] ;
+ global $pdf, $currencies;
+ osCSS_pdf::getInstance();
+
+ self::$orders_statuses = array_merge(tep_get_status_array('orders'),array(array('id'=>'','text'=>TEXT_NONE)));
+ self::$file_type_array= osCSS_pdf::get_module();
+
+ $pdf=osCSS_pdf::OutputInit($type);
+ $DF = new DatasFiles;
+
+
+ $order = new order($oID);
+
+ osCSS_pdf::OutputAddPage();
+
+ include(osCSS_pdf::getPathModele());
+
+ $file=$DF->GetDoc(osCSS_pdf::GetPdfType(),$oID);
+
+ if(file_exists($file))
+ unlink($file);
+
+ $pdf=osCSS_pdf::SaveEnd($file);
+
+ /// @remarks draw and exit;
+ $pdf=osCSS_pdf::OutputEnd();
+
+ break;
+
+ /**
@remarks Action mutliple
*/
case 'multiconfirm':
@@ -373,15 +414,11 @@
switch((string)$_GET['method']){
case 'add':
-
-// print_r($array);
-// exit;
- $res = sqlshipping::create($array);
-// var_dump($res);
-// exit;
+ $res = sqlshipping::create($array);
break;
}
+
tep_redirect(tep_href_link(self::FILENAME, 'oID='.$oID.'&action=edit'));
break;
@@ -399,7 +436,7 @@
if($res !=false){
$myarray = array(
- 'id'=>(int)$_GET['sID'],
+ 'id'=>(int)$_GET['sID'],
'status'=>(int)$_GET['flag'] ,
);
@@ -431,7 +468,7 @@
if($res !=false){
$myarray = array(
- 'id'=>(int)$_GET['sID'],
+ 'id'=>(int)$_GET['sID'],
'auto_retry'=>(int)$_GET['auto_retry'] ,
);
@@ -573,7 +610,7 @@
else
$res->allshipping[] = $result4;
// }
-
+
$res->display_service = (count($res->service) <= 0 )? false : true;
$res->display_shipping = (count($res->pshipping) <= 0 )? false : true;
$res->display_shipping_add = (!in_array(true, $activ_add))? false : true;
@@ -633,20 +670,18 @@
global $query_numrows;
$adjust=new objectInfo(self::$InitInfo['adjust']);
-
+// var_dump($adjust->sWhere);
+// exit;
if(tep_not_null($adjust->sWhere)){
- $adjust->sWhere=str_replace(array('orders_id',
- 'order_total',
- 'customers_id',
- 'orders_status_name'),
- array('o.orders_id',
- ' ot.text',
- 'o.customers_name',
- 's.status_name'),
- $adjust->sWhere);
+ $adjust->sWhere=str_replace(
+ array('orders_id', 'order_total', 'customers_id', 'orders_status_name'),
+ array('o.orders_id', ' ot.text', 'o.customers_name', 's.status_name'),
+ $adjust->sWhere
+ );
}
-
+// var_dump($adjust->sWhere);
+// exit;
$wh='';
if(self::$view =='opened')
$wh .=" AND SUBSTRING(o.orders_status,1,2) >= '".DEFAULT_ORDERS_STATUS_ID."' AND SUBSTRING(o.orders_status,1,2) < '".DEFAULT_ORDERS_STATUS_COMPLETED."' ";
@@ -852,9 +887,8 @@
@brief load listing array, for use format retrun by JSON
*/
public static function tep_get_list($page=1,$rowbyp=10,$sOrder='',$sWhere='',$options=''){
-
/// @remarks force load conf
- self::GetConf();
+ self::GetConf();
$res=array();
@@ -872,7 +906,13 @@
return self::$list=self::CheckResult($res);
}
+ public static function tep_get_modele(){
+ self::GetConf();
+ $action=(empty(self::$action)? 'listing' :self::$action);
+ return (isset(self::$InitInfo['modele'][$action]) ? self::$InitInfo['modele'][$action] : array() );
+ }
+
/**
@brief Redefine Parent method
*/
@@ -937,9 +977,9 @@
/**
@brief falg for activate / desactivate and indicate current status for service(virtual product)
- @param $row array current rows
+ @param $row array current rows
@param $justlink boolean for mode return
- @return string
+ @return string
link for action ($justlink=true)
or full html entite "a" normlised by current template
*/
@@ -987,9 +1027,9 @@
/**
- @brief test if exist order id
+ @brief test if exist order id
@param $oID int order id
- @return false | true
+ @return false | true
*/
private static function test_oID($oID){
global $messageStack;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-02-28 22:06:28
|
Revision: 4049
http://oscss.svn.sourceforge.net/oscss/?rev=4049&view=rev
Author: oscim
Date: 2012-02-28 22:06:21 +0000 (Tue, 28 Feb 2012)
Log Message:
-----------
ajout widget pour le suivi des commandes
correction template
Modified Paths:
--------------
trunk/catalog/Documents/admin/data/dashboard.xml
trunk/catalog/install/data/templates/appareil_photo/electronix/cfg/configuration.php
Added Paths:
-----------
trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastmodified.txt
trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastnews.txt
trunk/catalog/admin/includes/widget/orderLastmodified.php
trunk/catalog/admin/includes/widget/orderLastnews.php
Modified: trunk/catalog/Documents/admin/data/dashboard.xml
===================================================================
--- trunk/catalog/Documents/admin/data/dashboard.xml 2012-02-28 17:02:38 UTC (rev 4048)
+++ trunk/catalog/Documents/admin/data/dashboard.xml 2012-02-28 22:06:21 UTC (rev 4049)
@@ -47,6 +47,17 @@
</right>
</commercial>
+ <orders>
+ <left>
+ <widget>orderLastnews</widget>
+ <widget>orderStats</widget>
+ </left>
+ <right>
+ <widget>orderLastmodified</widget>
+ </right>
+ </orders>
+
+
<customers>
<left>
<widget>orderStats</widget>
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastmodified.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastmodified.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastmodified.txt 2012-02-28 22:06:21 UTC (rev 4049)
@@ -0,0 +1,16 @@
+<?php
+/**
+ @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 01/11/11, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['orderLastmodified box title']="Les dernière commandes modifiées" ;
+$lang['orderLastmodified box reference']="Réf." ;
+$lang['orderLastmodified box customers']="Clients" ;
+$lang['orderLastmodified box date']="date" ;
+$lang['orderLastmodified box status']="Etat" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastnews.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastnews.txt (rev 0)
+++ trunk/catalog/admin/includes/languages/fr_FR/widget/orderLastnews.txt 2012-02-28 22:06:21 UTC (rev 4049)
@@ -0,0 +1,16 @@
+<?php
+/**
+ @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 01/11/11, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+$lang['orderLastnews box title']="Les nouvelles commandes" ;
+$lang['orderLastnews box reference']="Réf." ;
+$lang['orderLastnews box customers']="Clients" ;
+$lang['orderLastnews box date']="date" ;
+$lang['orderLastnews box status']="Etat" ;
+?>
\ No newline at end of file
Added: trunk/catalog/admin/includes/widget/orderLastmodified.php
===================================================================
--- trunk/catalog/admin/includes/widget/orderLastmodified.php (rev 0)
+++ trunk/catalog/admin/includes/widget/orderLastmodified.php 2012-02-28 22:06:21 UTC (rev 4049)
@@ -0,0 +1,32 @@
+<?php
+/**
+ @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 01/11/11, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+
+$_query = tep_db_query("SELECT o.*, status_name FROM " . TABLE_ORDERS . " o LEFT JOIN " . TABLE_STATUS . " s ON(s.status_id=o.orders_status AND status_type='orders' AND language_id = '" . $languages_id . "') ORDER BY last_modified DESC LIMIT 5");
+?>
+<div id="orderLastmodified" class="<?php echo $widg['class'] ?>">
+<h3><?php echo __('orderLastmodified box title'); ?></h3>
+<table class="dataTableBase">
+ <tr>
+ <th><?php echo __('orderLastmodified box reference'); ?></th>
+ <th><?php echo __('orderLastmodified box customers'); ?></th>
+ <th><?php echo __('orderLastmodified box date'); ?></th>
+ <th><?php echo __('orderLastmodified box status'); ?></th>
+ </tr>
+ <?php foreach($_query->fetchAllAssoc() as $row) : ?>
+ <tr>
+ <td><strong><a href="<?php echo tep_href_link(FILENAME_ORDERS, 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['orders_prefix'].$row['orders_id'] ?></strong></td>
+ <td style="width:200px;"><?php echo tep_customers_row_action($row['customers_id'], array()) ?></td>
+ <td><?php echo tep_date_short($row['last_modified']) ?></td>
+ <td><?php echo $row['status_name'] ?></td>
+ </tr>
+ <?php endforeach; ?>
+</table>
+</div>
\ No newline at end of file
Added: trunk/catalog/admin/includes/widget/orderLastnews.php
===================================================================
--- trunk/catalog/admin/includes/widget/orderLastnews.php (rev 0)
+++ trunk/catalog/admin/includes/widget/orderLastnews.php 2012-02-28 22:06:21 UTC (rev 4049)
@@ -0,0 +1,32 @@
+<?php
+/**
+ @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 01/11/11, 20:02
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+
+$_query = tep_db_query("SELECT o.*, status_name FROM " . TABLE_ORDERS . " o LEFT JOIN " . TABLE_STATUS . " s ON(s.status_id=o.orders_status AND status_type='orders' AND language_id = '" . $languages_id . "') ORDER BY date_purchased DESC LIMIT 5");
+?>
+<div id="orderLastnews" class="<?php echo $widg['class'] ?>">
+<h3><?php echo __('orderLastnews box title'); ?></h3>
+<table class="dataTableBase">
+ <tr>
+ <th><?php echo __('orderLastnews box reference'); ?></th>
+ <th><?php echo __('orderLastnews box customers'); ?></th>
+ <th><?php echo __('orderLastnews box date'); ?></th>
+ <th><?php echo __('orderLastnews box status'); ?></th>
+ </tr>
+ <?php foreach($_query->fetchAllAssoc() as $row) : ?>
+ <tr>
+ <td><strong><a href="<?php echo tep_href_link(FILENAME_ORDERS, 'oID='.$row['orders_id'].'&action=edit') ?>"><?php echo $row['orders_prefix'].$row['orders_id'] ?></strong></td>
+ <td style="width:200px;"><?php echo tep_customers_row_action($row['customers_id'], array()) ?></td>
+ <td><?php echo tep_date_short($row['date_purchased']) ?></td>
+ <td><?php echo $row['status_name'] ?></td>
+ </tr>
+ <?php endforeach; ?>
+</table>
+</div>
\ No newline at end of file
Modified: trunk/catalog/install/data/templates/appareil_photo/electronix/cfg/configuration.php
===================================================================
--- trunk/catalog/install/data/templates/appareil_photo/electronix/cfg/configuration.php 2012-02-28 17:02:38 UTC (rev 4048)
+++ trunk/catalog/install/data/templates/appareil_photo/electronix/cfg/configuration.php 2012-02-28 22:06:21 UTC (rev 4049)
@@ -51,18 +51,13 @@
ResetConfigKey('MODULE_ACCOUNT_INSTALLED_BO');
ResetConfigKey('MODULE_GENERIC_INSTALLED');
-addConfigModule('MODULE_ACAPRO_INSTALLED', 'attributeManager.php');
addConfigModule('MODULE_ACAPRO_INSTALLED', 'desc_base.php');
-addConfigModule('MODULE_ACAPRO_INSTALLED_BO', 'attributeManager.php');
addConfigModule('MODULE_ACAPRO_INSTALLED_BO', 'desc_base.php');
addConfigModule('MODULE_ACAPRO_INSTALLED_BO', 'header_tags.php');
addConfigModule('MODULE_ACCOUNT_INSTALLED', 'address_book.php');
-addConfigModule('MODULE_ACCOUNT_INSTALLED', 'account_extra.php');
addConfigModule('MODULE_ACCOUNT_INSTALLED', 'history.php');
addConfigModule('MODULE_ACCOUNT_INSTALLED_BO', 'history.php');
addConfigModule('MODULE_ACCOUNT_INSTALLED_BO', 'address_book.php');
-addConfigModule('MODULE_ACCOUNT_INSTALLED_BO', 'sppc_cust_force.php');
-addConfigModule('MODULE_GENERIC_INSTALLED', 'banner.php');
addConfigModule('MODULE_GENERIC_INSTALLED', 'cat_home.php');
//! Update plugin sinatlled vs CIP
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-02-28 17:03:00
|
Revision: 4048
http://oscss.svn.sourceforge.net/oscss/?rev=4048&view=rev
Author: oscim
Date: 2012-02-28 17:02:38 +0000 (Tue, 28 Feb 2012)
Log Message:
-----------
correction fr
Modified Paths:
--------------
trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/orders.txt
trunk/catalog/admin/includes/languages/fr_FR/modules/pages/products.txt
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt 2012-02-28 15:10:45 UTC (rev 4047)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modorder.txt 2012-02-28 17:02:38 UTC (rev 4048)
@@ -26,17 +26,17 @@
XXXX_L description longue
*/
$lang['DEFAULT_ORDERS_STATUS_ID_S']="Commande Payée" ;
-$lang['DEFAULT_ORDERS_STATUS_ID_L']="definir le statut d'une commande payés." ;
+$lang['DEFAULT_ORDERS_STATUS_ID_L']="définir le statut d'une commande payés." ;
$lang['DEFAULT_ORDERS_STATUS_ID_S']="État par défaut pour une nouvelle commande" ;
$lang['DEFAULT_ORDERS_STATUS_ID_L']="Quand une nouvelle commande est créée, ce statut de commande lui sera assigné." ;
-$lang['DEFAULT_ORDERS_STATUS_COMPLETED_S']="Commande Cloturé" ;
-$lang['DEFAULT_ORDERS_STATUS_COMPLETED_L']="definir le statut final d'une commande livre" ;
+$lang['DEFAULT_ORDERS_STATUS_COMPLETED_S']="Commande Clôturé" ;
+$lang['DEFAULT_ORDERS_STATUS_COMPLETED_L']="définir le statut final d'une commande livre" ;
$lang['DEFAULT_ORDERS_STATUS_ID_S']="Commande annulée" ;
-$lang['DEFAULT_ORDERS_STATUS_ID_L']="definir le statut d'une commande annule." ;
+$lang['DEFAULT_ORDERS_STATUS_ID_L']="définir le statut d'une commande annule." ;
$lang['ORDERS_NUMBER_PREFIX_S']="Préfixe numéro commande" ;
-$lang['ORDERS_NUMBER_PREFIX_L']="Indiquer le préfixe des numéros de commande le chiffre precise le nombre de chiffre du numéro; ex: 'ym-5'(1005-00001); Laissez vide si vous ne voulez pas de préfixe." ;
+$lang['ORDERS_NUMBER_PREFIX_L']="Indiquer le préfixe des numéros de commande le chiffre précise le nombre de chiffre du numéro; ex: 'ym-5'(1005-00001); Laissez vide si vous ne voulez pas de préfixe." ;
$lang['USE_LOCAL_GENERAT_ORDER_REF_S']="Référence des commandes" ;
-$lang['USE_LOCAL_GENERAT_ORDER_REF_L']="Utiliser la numerotaion interne, ou laisser un outils externe prendre en charge cette référence. Celle ci ne sera donc disponible qu'apres la prise en compte par l'outil tiers de la commande. Coté public, le numero generic interne est utilisé en attente de reference" ;
+$lang['USE_LOCAL_GENERAT_ORDER_REF_L']="Utiliser la numérotation interne, ou laisser un outils externe prendre en charge cette référence. Celle ci ne sera donc disponible ci-après la prise en compte par l'outil tiers de la commande. Coté public, le numéro générique interne est utilisé en attente de référence" ;
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/pages/orders.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/pages/orders.txt 2012-02-28 15:10:45 UTC (rev 4047)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/pages/orders.txt 2012-02-28 17:02:38 UTC (rev 4048)
@@ -14,7 +14,7 @@
$lang['heading title status']="Statut :" ;
$lang['heading documents']="Documents" ;
-$lang['tab orders briefs']="Details" ;
+$lang['tab orders briefs']="Détails" ;
$lang['tab orders details']="Commande" ;
$lang['tab orders history']="Suivi" ;
$lang['tab orders shipping']="Livraisons" ;
@@ -29,7 +29,7 @@
$lang['table heading status']="Statut" ;
$lang['table heading id']="Id" ;
$lang['table heading action']="Action" ;
-$lang['table heading quantity']="Qté." ;
+$lang['table heading quantity']="Q té." ;
$lang['table heading products model']="Modèle" ;
$lang['table heading products']="Produits" ;
$lang['table heading tax']="Taxe" ;
@@ -46,8 +46,8 @@
$lang['table heading revival']="Alerte" ;
$lang['table heading current status']="Statut" ;
$lang['table heading auto_retry']="Auto-renouvellement" ;
-$lang['table heading quantity a expedie']="Reste à expedié" ;
-$lang['table heading quantity deja expedie']="Déjà expedié" ;
+$lang['table heading quantity a expedie']="Reste à expédié" ;
+$lang['table heading quantity deja expedie']="Déjà expédié" ;
$lang['table heading quantity in order']="Commande" ;
$lang['entry customer']="Client" ;
@@ -77,16 +77,16 @@
$lang['entry email address']="Email : " ;
$lang['entry shipping address actived']="Utilisation d'une adresse de livraison" ;
-$lang['text shipping expedie le %s']="Expedié le : %s" ;
+$lang['text shipping expedie le %s']="Expédié le : %s" ;
$lang['text shipping tracking n %s']="N° suivi : %s" ;
$lang['heading title search name']="Nom : " ;
$lang['heading title search montant']="Montant : " ;
-$lang['entry shipping new expedition details']="Detail de l'expedition " ;
-$lang['label shipping tracking number']="Numéro d'expedition : " ;
-$lang['label shipping tracking url']="Url de suivi : " ;
+$lang['entry shipping new expedition details']="Détail de l'expédition " ;
+$lang['label shipping tracking number']="Numéro d'expédition : " ;
+$lang['label shipping tracking url']="URL de suivi : " ;
$lang['not this status']="Sauf " ;
$lang['txt all']="Choix " ;
@@ -96,7 +96,7 @@
$lang['text info multi notify']="Notifier les clients" ;
$lang['text info multi action detail']="Changer les status pour : " ;
$lang['text info multi heading upload order']="Actions multiples " ;
-$lang['image modify multi']="Executer " ;
+$lang['image modify multi']="Exécuter " ;
$lang['text info heading delete order']="Supprimer la commande" ;
$lang['text info delete intro']="Êtes-vous sûr de vouloir supprimer cette commande ?" ;
@@ -120,18 +120,18 @@
$lang['pdf generate']="Generer" ;
$lang['error order not update address']="Erreur : adresse de la commande non mise à jour" ;
-$lang['success order update address']="Succes, mise à jour de l'adresse de la commande" ;
+$lang['success order update address']="Suces, mise à jour de l'adresse de la commande" ;
-$lang['error order not update mod']="Erreur : methode de la commande non mise à jour" ;
-$lang['success order update mod']="Succes, mise à jour de la méthode" ;
+$lang['error order not update mod']="Erreur : méthode de la commande non mise à jour" ;
+$lang['success order update mod']="Suces, mise à jour de la méthode" ;
$lang['error order not update status']="Erreur : statut de ce service non mis à jour" ;
-$lang['success order update status']="Succes, mise à jour du statut de ce service" ;
+$lang['success order update status']="Succès, mise à jour du statut de ce service" ;
$lang['error order not update auto_retry']="Erreur : auto-renouvellement du service non mis à jour" ;
-$lang['success order update auto_retry']="Succes, mise à jour de l'auto-renouvellement du service" ;
+$lang['success order update auto_retry']="Succès, mise à jour de l'auto-renouvellement du service" ;
$lang['error order does not exist']="Erreur : La commande n'existe pas." ;
$lang['success order updated']="Succès : La commande est mise à jour avec succès." ;
$lang['warning order not updated']="Attention : Aucune modification n'a été effectuée. La commande n'a pas été mise à jour." ;
-$lang['success order delete']="Supression de la commande effectué" ;
-$lang['error order not delete']="Erreur lors de la suppresion de la commande" ;
+$lang['success order delete']="Suppression de la commande effectué" ;
+$lang['error order not delete']="Erreur lors de la suppression de la commande" ;
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/pages/products.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/pages/products.txt 2012-02-28 15:10:45 UTC (rev 4047)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/pages/products.txt 2012-02-28 17:02:38 UTC (rev 4048)
@@ -113,8 +113,8 @@
$lang['text info copy to intro']="Veuillez choisir une nouvelle catégorie dans laquelle vous souhaitez copier ce produit" ;
$lang['text info heading copy to']="Copier vers" ;
- $lang['create products in new link categorie for %s']="Copie reussie du produit" ;
- $lang['error for create products in new link categorie for %s']="Erreur lors de la copie du porduit" ;
+ $lang['create products in new link categorie for %s']="Copie réussie du produit" ;
+ $lang['error for create products in new link categorie for %s']="Erreur lors de la copie du produit" ;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-02-28 15:10:57
|
Revision: 4047
http://oscss.svn.sourceforge.net/oscss/?rev=4047&view=rev
Author: oscim
Date: 2012-02-28 15:10:45 +0000 (Tue, 28 Feb 2012)
Log Message:
-----------
suite correction extra
finalisation integration champs mutli-mono langue dans les valeurs
gestion des champs a valeur mutliple et exploitation de la table productextra_fields_values
report de l'affichage des champs extra egenric dans la page produits
ajustement des table extra
finition des moduel d'admin de gestion des extra pour les produit et les clients
finition des page de gestion / configuration des extra produit et client
Modified Paths:
--------------
trunk/catalog/admin/includes/classes/productUtility.php
trunk/catalog/admin/includes/gabarit/customers/display_view.edit.gab
trunk/catalog/admin/includes/gabarit/customers/display_view.listing.gab
trunk/catalog/admin/includes/modules/account/account_extra.php
trunk/catalog/admin/includes/modules/products/products_extra.php
trunk/catalog/common/classes/ExtraUtility.php
trunk/catalog/includes/classes/drivers/data/product.php
trunk/catalog/includes/functions/general.php
trunk/catalog/install/data/templates/appareil_photo/2cShopHtml5Oscim/includes/content/account_edit.php
trunk/catalog/install/data/templates/appareil_photo/2cShopHtml5Oscim/includes/content/product_info.php
trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields.sql
trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields_labels.sql
trunk/catalog/install/includes/sql/mysql/tables/osc_products_to_products_extra_fields.sql
Added Paths:
-----------
trunk/catalog/includes/languages/fr_FR/modules/products/products_extra.txt
Modified: trunk/catalog/admin/includes/classes/productUtility.php
===================================================================
--- trunk/catalog/admin/includes/classes/productUtility.php 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/admin/includes/classes/productUtility.php 2012-02-28 15:10:45 UTC (rev 4047)
@@ -21,7 +21,7 @@
$uprid = $prid;
if ( (is_array($params)) && (!strstr($prid, '{')) ) {
while (list($option, $value) = each($params)) {
- $uprid = $uprid . '{' . $option . '}' . $value;
+ $uprid = $uprid . '{' . $option . '}' . $value;
}
}
@@ -157,13 +157,13 @@
public static function get_product_extra_value($epf_id, $product_id, $language_id) {
if(is_int($epf_id)|| (int)$epf_id ==$epf_id)
- $epf_query = tep_db_query("select e.epf_id, e.epf_uses_value_list, l.epf_active_for_language from " . TABLE_PRODUCTS_EXTRA_FIELDS . " e join " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " l ON e.epf_id = l.epf_id where e.epf_id = '" . (int)$epf_id."'");
+ $epf_query = tep_db_query("select e.epf_id, e.epf_input_type, l.epf_active_for_language from " . TABLE_PRODUCTS_EXTRA_FIELDS . " e join " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " l ON e.epf_id = l.epf_id where e.epf_id = '" . (int)$epf_id."'");
else
- $epf_query = tep_db_query("select e.epf_id, e.epf_uses_value_list, l.epf_active_for_language from " . TABLE_PRODUCTS_EXTRA_FIELDS . " e join " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " l ON e.epf_id = l.epf_id where e.epf_key = '" . $epf_id."'");
+ $epf_query = tep_db_query("select e.epf_id, e.epf_input_type, l.epf_active_for_language from " . TABLE_PRODUCTS_EXTRA_FIELDS . " e join " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " l ON e.epf_id = l.epf_id where e.epf_key = '" . $epf_id."'");
$e = tep_db_fetch_array($epf_query);
if($e['epf_active_for_language']==1) {
- $field = "extra_value" . ($e['epf_uses_value_list'] ? '_id' : '') . $e['epf_id'];
+ $field = "extra_value" . ($e['epf_input_type'] ? '_id' : '') . $e['epf_id'];
$product_query = tep_db_query("select " . $field . " from " . TABLE_PRODUCTS_DESCRIPTION . " where products_id = '" . (int)$product_id . "' and language_id = '" . (int)$language_id . "'");
$product = tep_db_fetch_array($product_query);
return $product[$field];
@@ -213,7 +213,7 @@
$sql = tep_db_query("select epf_value, value_id from " . TABLE_PRODUCTS_EXTRA_FIELDS_VALUES . " where epf_id = " . (int)$epf_id . " and languages_id = " . (int)$languages_id . " and parent_id = " . (int)$parent_id . " order by sort_order, epf_value");
while ($v = tep_db_fetch_array($sql)) {
$value_array[] = array('id' => $v['value_id'], 'text' => $indent . $v['epf_value']);
- $value_array = tep_build_epf_pulldown($epf_id, $languages_id, $value_array, $v['value_id'], $indent . '·');
+ $value_array = self::build_epf_pulldown($epf_id, $languages_id, $value_array, $v['value_id'], $indent . '·');
}
return $value_array;
}
@@ -276,15 +276,15 @@
@package oscss
@author OscssTeam
*/
-// public static function set_product_status($products_id, $status) {
-// if ($status == '1') {
-// return tep_db_query("update " . TABLE_PRODUCTS . " set products_status = '1', products_last_modified = now() where products_id = '" . (int)$products_id . "'");
-// } elseif ($status == '0') {
-// return tep_db_query("update " . TABLE_PRODUCTS . " set products_status = '0', products_last_modified = now() where products_id = '" . (int)$products_id . "'");
-// } else {
-// return -1;
-// }
-// }
+ public static function set_product_status($products_id, $status) {
+ if ($status == '1') {
+ return tep_db_query("update " . TABLE_PRODUCTS . " set products_status = '1', products_last_modified = now() where products_id = '" . (int)$products_id . "'");
+ } elseif ($status == '0') {
+ return tep_db_query("update " . TABLE_PRODUCTS . " set products_status = '0', products_last_modified = now() where products_id = '" . (int)$products_id . "'");
+ } else {
+ return -1;
+ }
+ }
/**
@fn remove_product($product_id)
Modified: trunk/catalog/admin/includes/gabarit/customers/display_view.edit.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/customers/display_view.edit.gab 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/admin/includes/gabarit/customers/display_view.edit.gab 2012-02-28 15:10:45 UTC (rev 4047)
@@ -1,6 +1,6 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
@@ -94,14 +94,14 @@
<fieldset class="block_field">
<legend><?php echo __('category options'); ?></legend>
- <p class="block_input input-one">
- <label for="customers_newsletter"><?php echo __('entry newsletter'); ?></label>
- <?php echo (customers::$processed == true)? customers::tep_view_news_human(customers::$cInfo->customers_newsletter).tep_draw_hidden_field('customers_newsletter') : tep_draw_pull_down_menu('customers_newsletter', customers::$newsletter_array, ((customers::$cInfo->customers_newsletter == '1') ? '1' : '0')) ; ?>
- </p>
- <p class="block_input input-one">
- <label for="global_product_notifications"><?php echo __('entry product notification'); ?></label>
- <?php echo (customers::$processed == true)? customers::tep_view_news_human(customers::$cInfo->global_product_notifications).tep_draw_hidden_field('global_product_notifications') : tep_draw_pull_down_menu('global_product_notifications', customers::$newsletter_array, ((customers::$cInfo->global_product_notifications == '1') ? '1' : '0')) ; ?>
- </p>
+ <p class="block_input input-one">
+ <label for="customers_newsletter"><?php echo __('entry newsletter'); ?></label>
+ <?php echo (customers::$processed == true)? customers::tep_view_news_human(customers::$cInfo->customers_newsletter).tep_draw_hidden_field('customers_newsletter') : tep_draw_pull_down_menu('customers_newsletter', customers::$newsletter_array, ((customers::$cInfo->customers_newsletter == '1') ? '1' : '0')) ; ?>
+ </p>
+ <p class="block_input input-one">
+ <label for="global_product_notifications"><?php echo __('entry product notification'); ?></label>
+ <?php echo (customers::$processed == true)? customers::tep_view_news_human(customers::$cInfo->global_product_notifications).tep_draw_hidden_field('global_product_notifications') : tep_draw_pull_down_menu('global_product_notifications', customers::$newsletter_array, ((customers::$cInfo->global_product_notifications == '1') ? '1' : '0')) ; ?>
+ </p>
</fieldset>
<div class="separator"></div>
</div>
Modified: trunk/catalog/admin/includes/gabarit/customers/display_view.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/customers/display_view.listing.gab 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/admin/includes/gabarit/customers/display_view.listing.gab 2012-02-28 15:10:45 UTC (rev 4047)
@@ -1,6 +1,6 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@portion code Copyright (c) 2002 osCommerce
@package osCSS-2 <www http://www.oscss.org>
@version 2.1.1
Modified: trunk/catalog/admin/includes/modules/account/account_extra.php
===================================================================
--- trunk/catalog/admin/includes/modules/account/account_extra.php 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/admin/includes/modules/account/account_extra.php 2012-02-28 15:10:45 UTC (rev 4047)
@@ -72,49 +72,42 @@
@brief methode call by sqlcustomer, and process after update master table customers
*/
public function after_update($customers_id) {
-// global $customers_id;
+
//! This function returns an array with variables to update into TABLE_ADDRESS_BOOK
tep_db_query("delete from " . TABLE_CUSTOMERS_TO_EXTRA_FIELDS . " where customers_id=" . (int)$customers_id);
- $extra_fields_query = tep_db_query("select ce.fields_id , fields_input_type as type from " . TABLE_EXTRA_FIELDS . " ce where ce.fields_status=1 AND fields_special_mod='' ");
-// print_r(($_POST));
+ $extra_fields_query = tep_db_query("select ce.fields_id as id, fields_input_type as type from " . TABLE_EXTRA_FIELDS . " ce where ce.fields_status=1 AND fields_special_mod='' ");
$val='';
while($extra_fields = tep_db_fetch_array($extra_fields_query)) {
- switch((int)$extra_fields['type']) {
+ $val = array();
+ $obj = new stdClass();
- case 6: // select mutli
- case 7: // checkbox mutli
- case 3: // checkbox
- $cnt = 1;
- foreach($_POST['fields_' . $extra_fields['fields_id']] as $k=>$item) {
- if($item =='on' ) $val .= $k.',';
- }
- break;
+ $obj->id = $extra_fields['id'];
+ $obj->type = $extra_fields['type'];
+ $obj->active_value_language = 0;
+ $result = ExtraUtility::GetPostValueFormFields($obj);
+ if(!is_array($result))
+ $val[] = $result;
+ else
+ $val = $result;
+ foreach($val as $lid=>$text){
- case 0: // classic
- case 1: // textarea
- case 2: // radio
- case 4: // select
- case 5: // hidden
- default:
- $val = ( (isset($_POST['fields_' . $extra_fields['fields_id']])) ? tep_db_prepare_input($_POST['fields_' . $extra_fields['fields_id']]) : '') ;
- }
+ $sql_data_array = array(
+ 'customers_id' => (int)$customers_id,
+ 'fields_id' => $obj->id,
+ 'value' => $text,
+// 'languages_id' => (($obj->active_value_language > 0) ? $lid : 0 ) ,
+ );
-
- $sql_data_array = array(
- 'customers_id' => (int)$customers_id,
- 'fields_id' => $extra_fields['fields_id'],
- 'value' => $val
- );
-
- tep_db_perform(TABLE_CUSTOMERS_TO_EXTRA_FIELDS, $sql_data_array);
+ tep_db_perform(TABLE_CUSTOMERS_TO_EXTRA_FIELDS, $sql_data_array);
+ }
}
-// exit;
+
return array();
}
@@ -175,6 +168,7 @@
$robj->input_value = $value;
$robj->input_format = $extra_fields['format'];
$robj->required_status = $extra_fields['fields_required_status'];
+ $robj->active_value_language = 0;
$robj->values_list = explode("\n", $extra_fields['fields_input_value']);
$robj->select_values = array();
Modified: trunk/catalog/admin/includes/modules/products/products_extra.php
===================================================================
--- trunk/catalog/admin/includes/modules/products/products_extra.php 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/admin/includes/modules/products/products_extra.php 2012-02-28 15:10:45 UTC (rev 4047)
@@ -73,7 +73,7 @@
$obj->type = $extra_fields['type'];
$obj->active_value_language = $extra_fields['active_value_language'];
- $result = ExtraUtility::GetValueFormFields($obj);
+ $result = ExtraUtility::GetPostValueFormFields($obj);
if(!is_array($result))
$val[] = $result;
else
Modified: trunk/catalog/common/classes/ExtraUtility.php
===================================================================
--- trunk/catalog/common/classes/ExtraUtility.php 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/common/classes/ExtraUtility.php 2012-02-28 15:10:45 UTC (rev 4047)
@@ -60,12 +60,12 @@
}
/**
- @fn GetValueFormFields($rows)
- @brief extract value for all input extra fileds in forms
+ @fn GetPostValueFormFields($rows)
+ @brief extract value for all input extra fileds in forms but respect type and retrun id for multiple result
@param $rows object detail current row
@return string value
*/
- public static function GetValueFormFields($rows){
+ public static function GetPostValueFormFields($rows){
switch((int)$rows->type ) {
case 6: // select mutli
@@ -95,10 +95,10 @@
case 5: // hidden
default:
// print_r($_POST);
- if($rows->active_value_language)
+ if($rows->active_value_language){
foreach($_POST['fields_' . $rows->id] as $k=>$v)
- $val[$k] = ( (!empty($v)) ? tep_db_prepare_input($v) : '') ;
-
+ $val[$k] = ( (!empty($v)) ? tep_db_prepare_input($v) : '') ;
+ }
else
$val = ( (isset($_POST['fields_' . $rows->id])) ? tep_db_prepare_input($_POST['fields_' . $rows->id]) : '') ;
}
@@ -192,17 +192,7 @@
return $input;
}
- public static function DisplayLangs($input){
-// <fieldset class="tabs_lang block_field">
- $s .='<ul>'."\n";
- for ($i=0, $n=sizeof($languages); $i<$n; $i++) {
- $s .='<li><a href="#products_name-' . ($i+1).'" >' . tep_language_image ( $languages[$i]['directory'] . '/images/' . $languages[$i]['image'], $languages[$i]['name']) . ' ' . $languages[$i]['name'] . '</a></li>'."\n";
- }
-
- $s .='</ul>'."\n";
- }
-
/**
@fn GetInputType ($id=0, $name=false)
@brief retrun array for pulldownmenu or array selected by arg id
@@ -254,5 +244,43 @@
elseif((int)$id<0)
return $r;
}
+
+
+
+ /**
+ @brief create htlm row line
+ @param $obj detail current rows
+ @param $edit boolean true = no edit; false : edit
+ @param $format html string put in rows
+ */
+ public static function DisplayRow($robj, $edit=true, $format = '<p class="block_input input-one">%s</p>'){
+
+ $label = self::FormatLabels($robj, $edit);
+
+ $input = self::FormatFields($robj, $edit);
+
+ return str_replace(
+ array('%label%', '%input%', '%unit%'),
+ array($label, $input, '') ,
+ sprintf($format , ( (!empty($robj->input_format))?$robj->input_format : '%label% %input% %unit%') )
+ ) ;
+ }
+
+
+
+ /**
+ Not used , just for dev !!!
+ */
+ public static function DisplayLangs($input){
+// <fieldset class="tabs_lang block_field">
+ $s .='<ul>'."\n";
+
+ for ($i=0, $n=sizeof($languages); $i<$n; $i++) {
+ $s .='<li><a href="#products_name-' . ($i+1).'" >' . tep_language_image ( $languages[$i]['directory'] . '/images/' . $languages[$i]['image'], $languages[$i]['name']) . ' ' . $languages[$i]['name'] . '</a></li>'."\n";
+ }
+
+ $s .='</ul>'."\n";
+ }
+
}
?>
\ No newline at end of file
Modified: trunk/catalog/includes/classes/drivers/data/product.php
===================================================================
--- trunk/catalog/includes/classes/drivers/data/product.php 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/includes/classes/drivers/data/product.php 2012-02-28 15:10:45 UTC (rev 4047)
@@ -342,7 +342,7 @@
else {
$DB=Database::getInstance();
$array=array();
- $epf_query = $DB->query("SELECT e.epf_id, e.epf_input_type,e.epf_key, epf_show_in_listing, epf_advanced_search, e.epf_active_value_language , l.epf_label, p2epf.products_extra_fields_value as value FROM " . TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS . " p2epf , " . TABLE_PRODUCTS_EXTRA_FIELDS . " e JOIN " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " l ON e.epf_id = l.epf_id WHERE p2epf.products_extra_fields_id=e.epf_id AND products_id = '" . (int)$product_id . "' AND l.languages_id='".self::$lg_id."' AND epf_special_mod='' ");
+ $epf_query = $DB->query("SELECT e.epf_id, e.epf_input_type,e.epf_key, epf_show_in_listing, epf_advanced_search, e.epf_active_value_language , l.epf_label, l.epf_format as input_format, p2epf.products_extra_fields_value as value FROM " . TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS . " p2epf , " . TABLE_PRODUCTS_EXTRA_FIELDS . " e JOIN " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " l ON e.epf_id = l.epf_id WHERE p2epf.products_extra_fields_id=e.epf_id AND products_id = '" . (int)$product_id . "' AND l.languages_id='".self::$lg_id."' AND epf_special_mod='' ");
while( $e = $epf_query->fetchAssoc() ) {
@@ -350,14 +350,36 @@
$val = $DB->query( $sql ="SELECT p2epf.products_extra_fields_value as value FROM " . TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS . " p2epf WHERE p2epf.products_extra_fields_id=".$e['epf_id']." AND products_id = '" . (int)$product_id . "' AND languages_id='". (($e['epf_active_value_language']==1)? self::$lg_id : 0)."' ");
$result = $val->fetchAssoc();
- $name = $result['value'];
+ switch((int)$e['epf_input_type'] ) {
+ case 6: // select mutli
+ case 7: // checkbox mutli
+ case 3: // checkbox
+ $val = self::GetEFValue($e['epf_id'] ,$result['value'] , (($e['epf_active_value_language']==1)? self::$lg_id : 0) );
+ break;
+
+ case 0: // classic
+ case 1: // textarea
+ case 2: // radio
+ case 4: // select
+ case 5: // hidden
+ default:
+ $val = $result['value'];
+ }
+
+
$array[ (!empty($e['epf_key'])?$e['epf_key'] :$e['epf_id']) ]=new objectInfo( array(
'label'=>(string)$e['epf_label'],
- 'value' => $name,
+ 'name'=>(string)$e['epf_label'], // obsolete
+ 'value' => $val, // obsolete
+ 'input_value' => $val,
'epf_key'=>(string)$e['epf_key'],
- 'epf_id'=>(int)$e['epf_id'],
+ 'epf_id'=>(int)$e['epf_id'], // obsolete
+ 'id'=>(int)$e['epf_id'],
'epf_show_in_listing'=>(int)$e['epf_show_in_listing'],
+ 'input_type'=>(int)$e['epf_input_type'],
+ 'input_format'=>$e['input_format'],
+ 'required_status'=>0,
// 'epf_advanced_search'=>(int)$e['epf_advanced_search']
) );
@@ -371,6 +393,31 @@
return $array;
}
+ /**
+ @fn GetEFValue($epfid,$values, $languages_id, $separator = ', ')
+ @brief get in db for extract all value for EF stocked in id value and not string
+ @param $epfid int
+ @param $values string (id, id,...)
+ @param $languages_id int or 0 for value not multi language
+ @param $separator seperator result
+ */
+ public static function GetEFValue($epfid,$values, $languages_id, $separator = ', '){
+ $DB=Database::getInstance();
+ $val = '';
+
+ $a = explode(',',$values);
+ foreach($a as $r)
+ if(!empty($r))$val .=$r.",";
+
+ $val = $DB->query( $sql ="SELECT epf_value as value FROM " . TABLE_PRODUCTS_EXTRA_FIELDS_VALUES . " p2epf WHERE value_id IN (".substr($val, 0, -1).") AND epf_id = '" . (int)$epfid . "' AND languages_id='".(int) $languages_id."' ORDER BY sort_order ");
+ $result = $val->fetchAllAssoc();
+
+ foreach($result as $r)
+ $s .=$r .$separator;
+
+ return substr($s, 0, -1);
+ }
+
/**
Construct a category path to the product
// TABLES: products_to_categories
@@ -458,36 +505,35 @@
if (is_array($attributes) && count($attributes)>0) {
reset($attributes);
while (list($option, $value) = each($attributes)) {
- $attribute_price_query = tep_db_query("select options_values_price, price_prefix from " . TABLE_PRODUCTS_ATTRIBUTES . " where products_id = '" . (int)$products_id . "' and options_id = '" . (int)$option . "' and options_values_id = '" . (int)$value . "'");
+ $attribute_price_query = tep_db_query("select options_values_price, price_prefix from " . TABLE_PRODUCTS_ATTRIBUTES . " where products_id = '" . (int)$products_id . "' and options_id = '" . (int)$option . "' and options_values_id = '" . (int)$value . "'");
+ $attribute_price = tep_db_fetch_array($attribute_price_query);
- $attribute_price = tep_db_fetch_array($attribute_price_query);
+ switch($attribute_price['price_prefix']){
+ case 'x':
+ $show_price = 0.0 + ( $price_prod * (float)$attribute_price['options_values_price']) - $price_prod ;
+ break;
+ case '/':
+ if($attribute_price['options_values_price']<=0) $attribute_price['options_values_price'] = 1;
+ $show_price = 0.0 + $price_prod - ($price_prod / $attribute_price['options_values_price']);
+ break;
+ case '+':
+ $show_price = 0.0 + $attribute_price['options_values_price'];
+ break;
+ case '-':
+ $show_price = 0.0 - $attribute_price['options_values_price'];
+ break;
+ // case '=':
+ // $show_price = 0.0 + $attribute_price['options_values_price'];
+ // break;
+ default:
+ $show_price = 0.0 ;
+ }
- switch($attribute_price['price_prefix']){
- case 'x':
- $show_price = 0.0 + ( $price_prod * (float)$attribute_price['options_values_price']) - $price_prod ;
- break;
- case '/':
- if($attribute_price['options_values_price']<=0) $attribute_price['options_values_price'] = 1;
- $show_price = 0.0 + $price_prod - ($price_prod / $attribute_price['options_values_price']);
- break;
- case '+':
- $show_price = 0.0 + $attribute_price['options_values_price'];
- break;
- case '-':
- $show_price = 0.0 - $attribute_price['options_values_price'];
- break;
-// case '=':
-// $show_price = 0.0 + $attribute_price['options_values_price'];
-// break;
- default:
- $show_price = 0.0 ;
- }
-
- if ($show_price > 0)
- $attrib_price += $show_price;
- else
- $attrib_price -= $show_price;
+ if ($show_price > 0)
+ $attrib_price += $show_price;
+ else
+ $attrib_price -= $show_price;
}
}
return self::$array_data[$products_id]->product_attribut_price[$uprid] =$attrib_price;
@@ -505,9 +551,9 @@
if (is_array($attributes) && count($attributes)>0) {
reset($attributes);
while (list($option, $value) = each($attributes)) {
- $attribute_price_query = tep_db_query("select options_values_weight from " . TABLE_PRODUCTS_ATTRIBUTES . " where products_id = '" . (int)$products_id . "' and options_id = '" . (int)$option . "' and options_values_id = '" . (int)$value . "'");
- $attribute_price = tep_db_fetch_array($attribute_price_query);
- $attributes_weight += $attribute_price['options_values_weight'];
+ $attribute_price_query = tep_db_query("select options_values_weight from " . TABLE_PRODUCTS_ATTRIBUTES . " where products_id = '" . (int)$products_id . "' and options_id = '" . (int)$option . "' and options_values_id = '" . (int)$value . "'");
+ $attribute_price = tep_db_fetch_array($attribute_price_query);
+ $attributes_weight += $attribute_price['options_values_weight'];
}
}
@@ -567,7 +613,7 @@
\brief Force mise en forme via class absctarction des modules de produits, type products
*/
abstract class AbstractProduct {
- // Force la classe étendue é définir cette méthode
+ // Force la classe étendue à définir cette méthode
abstract protected function display_view($pID,$class='');
abstract protected function load_db_values($pID);
abstract protected function get_header($action='');
Modified: trunk/catalog/includes/functions/general.php
===================================================================
--- trunk/catalog/includes/functions/general.php 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/includes/functions/general.php 2012-02-28 15:10:45 UTC (rev 4047)
@@ -849,12 +849,7 @@
}
- $label = ExtraUtility::FormatLabels($robj, false);
-
- $input = ExtraUtility::FormatFields($robj, false);
-
-
- $extra_fields_string .= str_replace( array('%label%', '%input%'), array($label, $input) , '<p class="block_input input-one">'.$extra_fields['format'].'</p>' ) ;
+ $extra_fields_string .=ExtraUtility::DisplayRow($robj, false);
}
}
return $extra_fields_string;
Added: trunk/catalog/includes/languages/fr_FR/modules/products/products_extra.txt
===================================================================
--- trunk/catalog/includes/languages/fr_FR/modules/products/products_extra.txt (rev 0)
+++ trunk/catalog/includes/languages/fr_FR/modules/products/products_extra.txt 2012-02-28 15:10:45 UTC (rev 4047)
@@ -0,0 +1,14 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 21/02/2012, 23:13
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+ @sub-package desc_base
+*/
+$lang['extra fields']="Autres" ;
+$lang['category extra fields']="Champs supplémentaires" ;
+?>
\ No newline at end of file
Modified: trunk/catalog/install/data/templates/appareil_photo/2cShopHtml5Oscim/includes/content/account_edit.php
===================================================================
--- trunk/catalog/install/data/templates/appareil_photo/2cShopHtml5Oscim/includes/content/account_edit.php 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/install/data/templates/appareil_photo/2cShopHtml5Oscim/includes/content/account_edit.php 2012-02-28 15:10:45 UTC (rev 4047)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@subpackage 2cShopHtml5Oscim
@package osCSS-2 <www http://www.oscss.org>
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
- @date 16/09/10, 21:54
+ @date 28/02/2012, 21:54
@encode UTF-8
*/
$account = $page->_call('customer','the_customer');
@@ -85,9 +85,9 @@
<fieldset class="account">
<legend><?php echo CATEGORY_EXTRA_FIELDS ?></legend>
- <!-- // BOF Customers extra fields -->
+ <!-- // BOF Customers Generic extra fields -->
<?php echo tep_get_extra_fields($customer_id, $languages_id)?>
- <!-- // EOF Customers extra fields -->
+ <!-- // EOF Customers Generic extra fields -->
</fieldset>
Modified: trunk/catalog/install/data/templates/appareil_photo/2cShopHtml5Oscim/includes/content/product_info.php
===================================================================
--- trunk/catalog/install/data/templates/appareil_photo/2cShopHtml5Oscim/includes/content/product_info.php 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/install/data/templates/appareil_photo/2cShopHtml5Oscim/includes/content/product_info.php 2012-02-28 15:10:45 UTC (rev 4047)
@@ -1,10 +1,10 @@
<?php
/**
- @licence GPL 2005-2011 The osCSS developers - osCSS Open Source E-commerce
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
@subpackage 2cShopHtml5Oscim
@package osCSS-2 <www http://www.oscss.org>
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
- @date 16/09/10, 21:54
+ @date 28/02/2012, 21:54
@encode UTF-8
@brief Page content for view detail products
@@ -18,9 +18,6 @@
//! element module aca class
$module=$page->_call('product','ret_modules');
$i=1;
-
-
-
?>
<header>
@@ -73,6 +70,15 @@
</figure>
<?php } ?>
+ <div class="ExtraFields">
+ <ul>
+ <?php foreach($product_info['extra'] as $k=>$row): /*print_r($row);*/?>
+ <li><?php echo ExtraUtility::DisplayRow($row, true, '%s'); ?></li>
+ <?php endforeach; ?>
+ </ul>
+ </div>
+
+
<div id="productInfoSpec">
<p class="productModel"><?php echo $product_info['products_model']; ?></p>
<p id="price_master" class="productPrice"><?php echo print_products_price_rv($product_info); ?></p>
@@ -81,7 +87,7 @@
<?php if (_test_bool($product_info['action']['buy'])): ?>
<?php echo tep_draw_form('cart_quantity', tep_href_link(FILENAME_PRODUCT_INFO, tep_get_all_get_params(array('action')) . 'action=add_product')); ?>
- <?php /** Aca Attribute Products */ if(isset($module['attributeManager'])) echo $module['attributeManager']->display_view_master($product_info['products_id']);?>
+ <?php /** Aca Attribute Products */ if(isset($module['Abonnement'])) echo $module['Abonnement']->display_view_master($product_info['products_id']);?>
<p class="formQt"><?php echo TEXT_PREFIX_QTY.tep_draw_input_field('products_quantity', 'products_quantity', '1', 'size="2"'); ?></p>
<p class="formBt">
Modified: trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields.sql
===================================================================
--- trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields.sql 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields.sql 2012-02-28 15:10:45 UTC (rev 4047)
@@ -23,6 +23,7 @@
epf_use_as_meta_keyword tinyint(1) not null default 0,
epf_use_to_restrict_listings tinyint(1) not null default 0,
epf_show_parent_chain tinyint(1) not null default 0,
+ epf_active_value_language tinyint(1) not null default 0,
epf_key varchar(40) default NULL COMMENT 'key de config pour plus de souplesse',
epf_admin int(1) NOT NULL default '1' COMMENT 'dispo uniquement admin',
epf_special_mod varchar(30) default NULL COMMENT 'flag module proprietaire',
Modified: trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields_labels.sql
===================================================================
--- trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields_labels.sql 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/install/includes/sql/mysql/tables/osc_products_extra_fields_labels.sql 2012-02-28 15:10:45 UTC (rev 4047)
@@ -16,7 +16,6 @@
epf_id int unsigned NOT NULL,
languages_id int NOT NULL,
epf_label varchar(64),
- epf_active_for_language tinyint(1) not null default 1,
epf_label_help varchar(160) default NULL COMMENT 'aide contextuelle',
PRIMARY KEY (epf_id, languages_id)
) DEFAULT CHARSET=utf8;
Modified: trunk/catalog/install/includes/sql/mysql/tables/osc_products_to_products_extra_fields.sql
===================================================================
--- trunk/catalog/install/includes/sql/mysql/tables/osc_products_to_products_extra_fields.sql 2012-02-28 09:31:40 UTC (rev 4046)
+++ trunk/catalog/install/includes/sql/mysql/tables/osc_products_to_products_extra_fields.sql 2012-02-28 15:10:45 UTC (rev 4047)
@@ -15,6 +15,7 @@
CREATE TABLE osc_products_to_products_extra_fields (
products_id int(11) NOT NULL default '0',
products_extra_fields_id int(11) NOT NULL default '0',
+ languages_id int NOT NULL default '0' comment 'not use external key in table languages',
products_extra_fields_value text,
PRIMARY KEY (products_id,products_extra_fields_id)
) DEFAULT CHARSET=utf8;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <os...@us...> - 2012-02-28 09:31:49
|
Revision: 4046
http://oscss.svn.sourceforge.net/oscss/?rev=4046&view=rev
Author: oscim
Date: 2012-02-28 09:31:40 +0000 (Tue, 28 Feb 2012)
Log Message:
-----------
FS895
Modified Paths:
--------------
trunk/catalog/ext/jquery/jquery.min.js
Modified: trunk/catalog/ext/jquery/jquery.min.js
===================================================================
--- trunk/catalog/ext/jquery/jquery.min.js 2012-02-28 09:21:53 UTC (rev 4045)
+++ trunk/catalog/ext/jquery/jquery.min.js 2012-02-28 09:31:40 UTC (rev 4046)
@@ -1,18 +1,4 @@
-/*!
- * jQuery JavaScript Library v1.6.2
- * http://jquery.com/
- *
- * Copyright 2011, John Resig
- * Dual licensed under the MIT or GPL Version 2 licenses.
- * http://jquery.org/license
- *
- * Includes Sizzle.js
- * http://sizzlejs.com/
- * Copyright 2011, The Dojo Foundation
- * Released under the MIT, BSD, and GPL Licenses.
- *
- * Date: Thu Jun 30 14:16:56 2011 -0400
- */
-(function(a,b){function cv(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cs(a){if(!cg[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){ch||(ch=c.createElement("iframe"),ch.frameBorder=ch.width=ch.height=0),b.appendChild(ch);if(!ci||!ch.createElement)ci=(ch.contentWindow||ch.contentDocument).document,ci.write((c.compatMode==="CSS1Compat"?"<!doctype html>":"")+"<html><body>"),ci.close();d=ci.createElement(a),ci.body.appendChild(d),e=f.css(d,"display"),b.removeChild(ch)}cg[a]=e}return cg[a]}function cr(a,b){var c={};f.each(cm.concat.apply([],cm.slice(0,b)),function(){c[this]=a});return c}function cq(){cn=b}function cp(){setTimeout(cq,0);return cn=f.now()}function cf(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ce(){try{return new a.XMLHttpRequest}catch(b){}}function b$(a,c){a.dataFilter&&(c=a.dataFilter(c,a.dataType));var d=a.dataTypes,e={},g,h,i=d.length,j,k=d[0],l,m,n,o,p;for(g=1;g<i;g++){if(g===1)for(h in a.converters)typeof h=="string"&&(e[h.toLowerCase()]=a.converters[h]);l=k,k=d[g];if(k==="*")k=l;else if(l!=="*"&&l!==k){m=l+" "+k,n=e[m]||e["* "+k];if(!n){p=b;for(o in e){j=o.split(" ");if(j[0]===l||j[0]==="*"){p=e[j[1]+" "+k];if(p){o=e[o],o===!0?n=p:p===!0&&(n=o);break}}}}!n&&!p&&f.error("No conversion from "+m.replace(" "," to ")),n!==!0&&(c=n?n(c):p(o(c)))}}return c}function bZ(a,c,d){var e=a.contents,f=a.dataTypes,g=a.responseFields,h,i,j,k;for(i in g)i in d&&(c[g[i]]=d[i]);while(f[0]==="*")f.shift(),h===b&&(h=a.mimeType||c.getResponseHeader("content-type"));if(h)for(i in e)if(e[i]&&e[i].test(h)){f.unshift(i);break}if(f[0]in d)j=f[0];else{for(i in d){if(!f[0]||a.converters[i+" "+f[0]]){j=i;break}k||(k=i)}j=j||k}if(j){j!==f[0]&&f.unshift(j);return d[j]}}function bY(a,b,c,d){if(f.isArray(b))f.each(b,function(b,e){c||bC.test(a)?d(a,e):bY(a+"["+(typeof e=="object"||f.isArray(e)?b:"")+"]",e,c,d)});else if(!c&&b!=null&&typeof b=="object")for(var e in b)bY(a+"["+e+"]",b[e],c,d);else d(a,b)}function bX(a,c,d,e,f,g){f=f||c.dataTypes[0],g=g||{},g[f]=!0;var h=a[f],i=0,j=h?h.length:0,k=a===bR,l;for(;i<j&&(k||!l);i++)l=h[i](c,d,e),typeof l=="string"&&(!k||g[l]?l=b:(c.dataTypes.unshift(l),l=bX(a,c,d,e,l,g)));(k||!l)&&!g["*"]&&(l=bX(a,c,d,e,"*",g));return l}function bW(a){return function(b,c){typeof b!="string"&&(c=b,b="*");if(f.isFunction(c)){var d=b.toLowerCase().split(bN),e=0,g=d.length,h,i,j;for(;e<g;e++)h=d[e],j=/^\+/.test(h),j&&(h=h.substr(1)||"*"),i=a[h]=a[h]||[],i[j?"unshift":"push"](c)}}}function bA(a,b,c){var d=b==="width"?a.offsetWidth:a.offsetHeight,e=b==="width"?bv:bw;if(d>0){c!=="border"&&f.each(e,function(){c||(d-=parseFloat(f.css(a,"padding"+this))||0),c==="margin"?d+=parseFloat(f.css(a,c+this))||0:d-=parseFloat(f.css(a,"border"+this+"Width"))||0});return d+"px"}d=bx(a,b,b);if(d<0||d==null)d=a.style[b]||0;d=parseFloat(d)||0,c&&f.each(e,function(){d+=parseFloat(f.css(a,"padding"+this))||0,c!=="padding"&&(d+=parseFloat(f.css(a,"border"+this+"Width"))||0),c==="margin"&&(d+=parseFloat(f.css(a,c+this))||0)});return d+"px"}function bm(a,b){b.src?f.ajax({url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(be,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)}function bl(a){f.nodeName(a,"input")?bk(a):"getElementsByTagName"in a&&f.grep(a.getElementsByTagName("input"),bk)}function bk(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function bj(a){return"getElementsByTagName"in a?a.getElementsByTagName("*"):"querySelectorAll"in a?a.querySelectorAll("*"):[]}function bi(a,b){var c;if(b.nodeType===1){b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase();if(c==="object")b.outerHTML=a.outerHTML;else if(c!=="input"||a.type!=="checkbox"&&a.type!=="radio"){if(c==="option")b.selected=a.defaultSelected;else if(c==="input"||c==="textarea")b.defaultValue=a.defaultValue}else a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value);b.removeAttribute(f.expando)}}function bh(a,b){if(b.nodeType===1&&!!f.hasData(a)){var c=f.expando,d=f.data(a),e=f.data(b,d);if(d=d[c]){var g=d.events;e=e[c]=f.extend({},d);if(g){delete e.handle,e.events={};for(var h in g)for(var i=0,j=g[h].length;i<j;i++)f.event.add(b,h+(g[h][i].namespace?".":"")+g[h][i].namespace,g[h][i],g[h][i].data)}}}}function bg(a,b){return f.nodeName(a,"table")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function W(a,b,c){b=b||0;if(f.isFunction(b))return f.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return f.grep(a,function(a,d){return a===b===c});if(typeof b=="string"){var d=f.grep(a,function(a){return a.nodeType===1});if(R.test(b))return f.filter(b,d,!c);b=f.filter(b,d)}return f.grep(a,function(a,d){return f.inArray(a,b)>=0===c})}function V(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function N(a,b){return(a&&a!=="*"?a+".":"")+b.replace(z,"`").replace(A,"&")}function M(a){var b,c,d,e,g,h,i,j,k,l,m,n,o,p=[],q=[],r=f._data(this,"events");if(!(a.liveFired===this||!r||!r.live||a.target.disabled||a.button&&a.type==="click")){a.namespace&&(n=new RegExp("(^|\\.)"+a.namespace.split(".").join("\\.(?:.*\\.)?")+"(\\.|$)")),a.liveFired=this;var s=r.live.slice(0);for(i=0;i<s.length;i++)g=s[i],g.origType.replace(x,"")===a.type?q.push(g.selector):s.splice(i--,1);e=f(a.target).closest(q,a.currentTarget);for(j=0,k=e.length;j<k;j++){m=e[j];for(i=0;i<s.length;i++){g=s[i];if(m.selector===g.selector&&(!n||n.test(g.namespace))&&!m.elem.disabled){h=m.elem,d=null;if(g.preType==="mouseenter"||g.preType==="mouseleave")a.type=g.preType,d=f(a.relatedTarget).closest(g.selector)[0],d&&f.contains(h,d)&&(d=h);(!d||d!==h)&&p.push({elem:h,handleObj:g,level:m.level})}}}for(j=0,k=p.length;j<k;j++){e=p[j];if(c&&e.level>c)break;a.currentTarget=e.elem,a.data=e.handleObj.data,a.handleObj=e.handleObj,o=e.handleObj.origHandler.apply(e.elem,arguments);if(o===!1||a.isPropagationStopped()){c=e.level,o===!1&&(b=!1);if(a.isImmediatePropagationStopped())break}}return b}}function K(a,c,d){var e=f.extend({},d[0]);e.type=a,e.originalEvent={},e.liveFired=b,f.event.handle.call(c,e),e.isDefaultPrevented()&&d[0].preventDefault()}function E(){return!0}function D(){return!1}function m(a,c,d){var e=c+"defer",g=c+"queue",h=c+"mark",i=f.data(a,e,b,!0);i&&(d==="queue"||!f.data(a,g,b,!0))&&(d==="mark"||!f.data(a,h,b,!0))&&setTimeout(function(){!f.data(a,g,b,!0)&&!f.data(a,h,b,!0)&&(f.removeData(a,e,!0),i.resolve())},0)}function l(a){for(var b in a)if(b!=="toJSON")return!1;return!0}function k(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(j,"$1-$2").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNaN(d)?i.test(d)?f.parseJSON(d):d:parseFloat(d)}catch(g){}f.data(a,c,d)}else d=b}return d}var c=a.document,d=a.navigator,e=a.location,f=function(){function J(){if(!e.isReady){try{c.documentElement.doScroll("left")}catch(a){setTimeout(J,1);return}e.ready()}}var e=function(a,b){return new e.fn.init(a,b,h)},f=a.jQuery,g=a.$,h,i=/^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/\d/,n=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,o=/^[\],:{}\s]*$/,p=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,q=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,r=/(?:^|:|,)(?:\s*\[)+/g,s=/(webkit)[ \/]([\w.]+)/,t=/(opera)(?:.*version)?[ \/]([\w.]+)/,u=/(msie) ([\w.]+)/,v=/(mozilla)(?:.*? rv:([\w.]+))?/,w=/-([a-z])/ig,x=function(a,b){return b.toUpperCase()},y=d.userAgent,z,A,B,C=Object.prototype.toString,D=Object.prototype.hasOwnProperty,E=Array.prototype.push,F=Array.prototype.slice,G=String.prototype.trim,H=Array.prototype.indexOf,I={};e.fn=e.prototype={constructor:e,init:function(a,d,f){var g,h,j,k;if(!a)return this;if(a.nodeType){this.context=this[0]=a,this.length=1;return this}if(a==="body"&&!d&&c.body){this.context=c,this[0]=c.body,this.selector=a,this.length=1;return this}if(typeof a=="string"){a.charAt(0)!=="<"||a.charAt(a.length-1)!==">"||a.length<3?g=i.exec(a):g=[null,a,null];if(g&&(g[1]||!d)){if(g[1]){d=d instanceof e?d[0]:d,k=d?d.ownerDocument||d:c,j=n.exec(a),j?e.isPlainObject(d)?(a=[c.createElement(j[1])],e.fn.attr.call(a,d,!0)):a=[k.createElement(j[1])]:(j=e.buildFragment([g[1]],[k]),a=(j.cacheable?e.clone(j.fragment):j.fragment).childNodes);return e.merge(this,a)}h=c.getElementById(g[2]);if(h&&h.parentNode){if(h.id!==g[2])return f.find(a);this.length=1,this[0]=h}this.context=c,this.selector=a;return this}return!d||d.jquery?(d||f).find(a):this.constructor(d).find(a)}if(e.isFunction(a))return f.ready(a);a.selector!==b&&(this.selector=a.selector,this.context=a.context);return e.makeArray(a,this)},selector:"",jquery:"1.6.2",length:0,size:function(){return this.length},toArray:function(){return F.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=this.constructor();e.isArray(a)?E.apply(d,a):e.merge(d,a),d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")");return d},each:function(a,b){return e.each(this,a,b)},ready:function(a){e.bindReady(),A.done(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(F.apply(this,arguments),"slice",F.call(arguments).join(","))},map:function(a){return this.pushStack(e.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:E,sort:[].sort,splice:[].splice},e.fn.init.prototype=e.fn,e.extend=e.fn.extend=function(){var a,c,d,f,g,h,i=arguments[0]||{},j=1,k=arguments.length,l=!1;typeof i=="boolean"&&(l=i,i=arguments[1]||{},j=2),typeof i!="object"&&!e.isFunction(i)&&(i={}),k===j&&(i=this,--j);for(;j<k;j++)if((a=arguments[j])!=null)for(c in a){d=i[c],f=a[c];if(i===f)continue;l&&f&&(e.isPlainObject(f)||(g=e.isArray(f)))?(g?(g=!1,h=d&&e.isArray(d)?d:[]):h=d&&e.isPlainObject(d)?d:{},i[c]=e.extend(l,h,f)):f!==b&&(i[c]=f)}return i},e.extend({noConflict:function(b){a.$===e&&(a.$=g),b&&a.jQuery===e&&(a.jQuery=f);return e},isReady:!1,readyWait:1,holdReady:function(a){a?e.readyWait++:e.ready(!0)},ready:function(a){if(a===!0&&!--e.readyWait||a!==!0&&!e.isReady){if(!c.body)return setTimeout(e.ready,1);e.isReady=!0;if(a!==!0&&--e.readyWait>0)return;A.resolveWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!A){A=e._Deferred();if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",B,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",B),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&J()}}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a&&typeof a=="object"&&"setInterval"in a},isNaN:function(a){return a==null||!m.test(a)||isNaN(a)},type:function(a){return a==null?String(a):I[C.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;if(a.constructor&&!D.call(a,"constructor")&&!D.call(a.constructor.prototype,"isPrototypeOf"))return!1;var c;for(c in a);return c===b||D.call(a,c)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw a},parseJSON:function(b){if(typeof b!="string"||!b)return null;b=e.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(o.test(b.replace(p,"@").replace(q,"]").replace(r,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(b,c,d){a.DOMParser?(d=new DOMParser,c=d.parseFromString(b,"text/xml")):(c=new ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b)),d=c.documentElement,(!d||!d.nodeName||d.nodeName==="parsererror")&&e.error("Invalid XML: "+b);return c},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(w,x)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var f,g=0,h=a.length,i=h===b||e.isFunction(a);if(d){if(i){for(f in a)if(c.apply(a[f],d)===!1)break}else for(;g<h;)if(c.apply(a[g++],d)===!1)break}else if(i){for(f in a)if(c.call(a[f],f,a[f])===!1)break}else for(;g<h;)if(c.call(a[g],g,a[g++])===!1)break;return a},trim:G?function(a){return a==null?"":G.call(a)}:function(a){return a==null?"":(a+"").replace(k,"").replace(l,"")},makeArray:function(a,b){var c=b||[];if(a!=null){var d=e.type(a);a.length==null||d==="string"||d==="function"||d==="regexp"||e.isWindow(a)?E.call(c,a):e.merge(c,a)}return c},inArray:function(a,b){if(H)return H.call(b,a);for(var c=0,d=b.length;c<d;c++)if(b[c]===a)return c;return-1},merge:function(a,c){var d=a.length,e=0;if(typeof c.length=="number")for(var f=c.length;e<f;e++)a[d++]=c[e];else while(c[e]!==b)a[d++]=c[e++];a.length=d;return a},grep:function(a,b,c){var d=[],e;c=!!c;for(var f=0,g=a.length;f<g;f++)e=!!b(a[f],f),c!==e&&d.push(a[f]);return d},map:function(a,c,d){var f,g,h=[],i=0,j=a.length,k=a instanceof e||j!==b&&typeof j=="number"&&(j>0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i<j;i++)f=c(a[i],i,d),f!=null&&(h[h.length]=f);else for(g in a)f=c(a[g],g,d),f!=null&&(h[h.length]=f);return h.concat.apply([],h)},guid:1,proxy:function(a,c){if(typeof c=="string"){var d=a[c];c=a,a=d}if(!e.isFunction(a))return b;var f=F.call(arguments,2),g=function(){return a.apply(c,f.concat(F.call(arguments)))};g.guid=a.guid=a.guid||g.guid||e.guid++;return g},access:function(a,c,d,f,g,h){var i=a.length;if(typeof c=="object"){for(var j in c)e.access(a,j,c[j],f,g,d);return a}if(d!==b){f=!h&&f&&e.isFunction(d);for(var k=0;k<i;k++)g(a[k],c,f?d.call(a[k],k,g(a[k],c)):d,h);return a}return i?g(a[0],c):b},now:function(){return(new Date).getTime()},uaMatch:function(a){a=a.toLowerCase();var b=s.exec(a)||t.exec(a)||u.exec(a)||a.indexOf("compatible")<0&&v.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},sub:function(){function a(b,c){return new a.fn.init(b,c)}e.extend(!0,a,this),a.superclass=this,a.fn=a.prototype=this(),a.fn.constructor=a,a.sub=this.sub,a.fn.init=function(d,f){f&&f instanceof e&&!(f instanceof a)&&(f=a(f));return e.fn.init.call(this,d,f,b)},a.fn.init.prototype=a.fn;var b=a(c);return a},browser:{}}),e.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(a,b){I["[object "+b+"]"]=b.toLowerCase()}),z=e.uaMatch(y),z.browser&&(e.browser[z.browser]=!0,e.browser.version=z.version),e.browser.webkit&&(e.browser.safari=!0),j.test(" ")&&(k=/^[\s\xA0]+/,l=/[\s\xA0]+$/),h=e(c),c.addEventListener?B=function(){c.removeEventListener("DOMContentLoaded",B,!1),e.ready()}:c.attachEvent&&(B=function(){c.readyState==="complete"&&(c.detachEvent("onreadystatechange",B),e.ready())});return e}(),g="done fail isResolved isRejected promise then always pipe".split(" "),h=[].slice;f.extend({_Deferred:function(){var a=[],b,c,d,e={done:function(){if(!d){var c=arguments,g,h,i,j,k;b&&(k=b,b=0);for(g=0,h=c.length;g<h;g++)i=c[g],j=f.type(i),j==="array"?e.done.apply(e,i):j==="function"&&a.push(i);k&&e.resolveWith(k[0],k[1])}return this},resolveWith:function(e,f){if(!d&&!b&&!c){f=f||[],c=1;try{while(a[0])a.shift().apply(e,f)}finally{b=[e,f],c=0}}return this},resolve:function(){e.resolveWith(this,arguments);return this},isResolved:function(){return!!c||!!b},cancel:function(){d=1,a=[];return this}};return e},Deferred:function(a){var b=f._Deferred(),c=f._Deferred(),d;f.extend(b,{then:function(a,c){b.done(a).fail(c);return this},always:function(){return b.done.apply(b,arguments).fail.apply(this,arguments)},fail:c.done,rejectWith:c.resolveWith,reject:c.resolve,isRejected:c.isResolved,pipe:function(a,c){return f.Deferred(function(d){f.each({done:[a,"resolve"],fail:[c,"reject"]},function(a,c){var e=c[0],g=c[1],h;f.isFunction(e)?b[a](function(){h=e.apply(this,arguments),h&&f.isFunction(h.promise)?h.promise().then(d.resolve,d.reject):d[g](h)}):b[a](d[g])})}).promise()},promise:function(a){if(a==null){if(d)return d;d=a={}}var c=g.length;while(c--)a[g[c]]=b[g[c]];return a}}),b.done(c.cancel).fail(b.cancel),delete b.cancel,a&&a.call(b,b);return b},when:function(a){function i(a){return function(c){b[a]=arguments.length>1?h.call(arguments,0):c,--e||g.resolveWith(g,h.call(b,0))}}var b=arguments,c=0,d=b.length,e=d,g=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred();if(d>1){for(;c<d;c++)b[c]&&f.isFunction(b[c].promise)?b[c].promise().then(i(c),g.reject):--e;e||g.resolveWith(g,b)}else g!==a&&g.resolveWith(g,d?[a]:[]);return g.promise()}}),f.support=function(){var a=c.createElement("div"),b=c.documentElement,d,e,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u;a.setAttribute("className","t"),a.innerHTML=" <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>",d=a.getElementsByTagName("*"),e=a.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=a.getElementsByTagName("input")[0],k={leadingWhitespace:a.firstChild.nodeType===3,tbody:!a.getElementsByTagName("tbody").length,htmlSerialize:!!a.getElementsByTagName("link").length,style:/top/.test(e.getAttribute("style")),hrefNormalized:e.getAttribute("href")==="/a",opacity:/^0.55$/.test(e.style.opacity),cssFloat:!!e.style.cssFloat,checkOn:i.value==="on",optSelected:h.selected,getSetAttribute:a.className!=="t",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},i.checked=!0,k.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,k.optDisabled=!h.disabled;try{delete a.test}catch(v){k.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function(){k.noCloneEvent=!1}),a.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),k.radioValue=i.value==="t",i.setAttribute("checked","checked"),a.appendChild(i),l=c.createDocumentFragment(),l.appendChild(a.firstChild),k.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",m=c.getElementsByTagName("body")[0],o=c.createElement(m?"div":"body"),p={visibility:"hidden",width:0,height:0,border:0,margin:0},m&&f.extend(p,{position:"absolute",left:-1e3,top:-1e3});for(t in p)o.style[t]=p[t];o.appendChild(a),n=m||b,n.insertBefore(o,n.firstChild),k.appendChecked=i.checked,k.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,k.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="<div style='width:4px;'></div>",k.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="<table><tr><td style='padding:0;border:0;display:none'></td><td>t</td></tr></table>",q=a.getElementsByTagName("td"),u=q[0].offsetHeight===0,q[0].style.display="",q[1].style.display="none",k.reliableHiddenOffsets=u&&q[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(j=c.createElement("div"),j.style.width="0",j.style.marginRight="0",a.appendChild(j),k.reliableMarginRight=(parseInt((c.defaultView.getComputedStyle(j,null)||{marginRight:0}).marginRight,10)||0)===0),o.innerHTML="",n.removeChild(o);if(a.attachEvent)for(t in{submit:1,change:1,focusin:1})s="on"+t,u=s in a,u||(a.setAttribute(s,"return;"),u=typeof a[s]=="function"),k[t+"Bubbles"]=u;o=l=g=h=m=j=a=i=null;return k}(),f.boxModel=f.support.boxModel;var i=/^(?:\{.*\}|\[.*\])$/,j=/([a-z])([A-Z])/g;f.extend({cache:{},uuid:0,expando:"jQuery"+(f.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){a=a.nodeType?f.cache[a[f.expando]]:a[f.expando];return!!a&&!l(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g=f.expando,h=typeof c=="string",i,j=a.nodeType,k=j?f.cache:a,l=j?a[f.expando]:a[f.expando]&&f.expando;if((!l||e&&l&&!k[l][g])&&h&&d===b)return;l||(j?a[f.expando]=l=++f.uuid:l=f.expando),k[l]||(k[l]={},j||(k[l].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?k[l][g]=f.extend(k[l][g],c):k[l]=f.extend(k[l],c);i=k[l],e&&(i[g]||(i[g]={}),i=i[g]),d!==b&&(i[f.camelCase(c)]=d);if(c==="events"&&!i[c])return i[g]&&i[g].events;return h?i[f.camelCase(c)]||i[c]:i}},removeData:function(b,c,d){if(!!f.acceptData(b)){var e=f.expando,g=b.nodeType,h=g?f.cache:b,i=g?b[f.expando]:f.expando;if(!h[i])return;if(c){var j=d?h[i][e]:h[i];if(j){delete j[c];if(!l(j))return}}if(d){delete h[i][e];if(!l(h[i]))return}var k=h[i][e];f.support.deleteExpando||h!=a?delete h[i]:h[i]=null,k?(h[i]={},g||(h[i].toJSON=f.noop),h[i][e]=k):g&&(f.support.deleteExpando?delete b[f.expando]:b.removeAttribute?b.removeAttribute(f.expando):b[f.expando]=null)}},_data:function(a,b,c){return f.data(a,b,c,!0)},acceptData:function(a){if(a.nodeName){var b=f.noData[a.nodeName.toLowerCase()];if(b)return b!==!0&&a.getAttribute("classid")===b}return!0}}),f.fn.extend({data:function(a,c){var d=null;if(typeof a=="undefined"){if(this.length){d=f.data(this[0]);if(this[0].nodeType===1){var e=this[0].attributes,g;for(var h=0,i=e.length;h<i;h++)g=e[h].name,g.indexOf("data-")===0&&(g=f.camelCase(g.substring(5)),k(this[0],g,d[g]))}}return d}if(typeof a=="object")return this.each(function(){f.data(this,a)});var j=a.split(".");j[1]=j[1]?"."+j[1]:"";if(c===b){d=this.triggerHandler("getData"+j[1]+"!",[j[0]]),d===b&&this.length&&(d=f.data(this[0],a),d=k(this[0],a,d));return d===b&&j[1]?this.data(j[0]):d}return this.each(function(){var b=f(this),d=[j[0],c];b.triggerHandler("setData"+j[1]+"!",d),f.data(this,a,c),b.triggerHandler("changeData"+j[1]+"!",d)})},removeData:function(a){return this.each(function(){f.removeData(this,a)})}}),f.extend({_mark:function(a,c){a&&(c=(c||"fx")+"mark",f.data(a,c,(f.data(a,c,b,!0)||0)+1,!0))},_unmark:function(a,c,d){a!==!0&&(d=c,c=a,a=!1);if(c){d=d||"fx";var e=d+"mark",g=a?0:(f.data(c,e,b,!0)||1)-1;g?f.data(c,e,g,!0):(f.removeData(c,e,!0),m(c,d,"mark"))}},queue:function(a,c,d){if(a){c=(c||"fx")+"queue";var e=f.data(a,c,b,!0);d&&(!e||f.isArray(d)?e=f.data(a,c,f.makeArray(d),!0):e.push(d));return e||[]}},dequeue:function(a,b){b=b||"fx";var c=f.queue(a,b),d=c.shift(),e;d==="inprogress"&&(d=c.shift()),d&&(b==="fx"&&c.unshift("inprogress"),d.call(a,function(){f.dequeue(a,b)})),c.length||(f.removeData(a,b+"queue",!0),m(a,b,"queue"))}}),f.fn.extend({queue:function(a,c){typeof a!="string"&&(c=a,a="fx");if(c===b)return f.queue(this[0],a);return this.each(function(){var b=f.queue(this,a,c);a==="fx"&&b[0]!=="inprogress"&&f.dequeue(this,a)})},dequeue:function(a){return this.each(function(){f.dequeue(this,a)})},delay:function(a,b){a=f.fx?f.fx.speeds[a]||a:a,b=b||"fx";return this.queue(b,function(){var c=this;setTimeout(function(){f.dequeue(c,b)},a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,c){function m(){--h||d.resolveWith(e,[e])}typeof a!="string"&&(c=a,a=b),a=a||"fx";var d=f.Deferred(),e=this,g=e.length,h=1,i=a+"defer",j=a+"queue",k=a+"mark",l;while(g--)if(l=f.data(e[g],i,b,!0)||(f.data(e[g],j,b,!0)||f.data(e[g],k,b,!0))&&f.data(e[g],i,f._Deferred(),!0))h++,l.done(m);m();return d.promise()}});var n=/[\n\t\r]/g,o=/\s+/,p=/\r/g,q=/^(?:button|input)$/i,r=/^(?:button|input|object|select|textarea)$/i,s=/^a(?:rea)?$/i,t=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,u=/\:|^on/,v,w;f.fn.extend({attr:function(a,b){return f.access(this,a,b,!0,f.attr)},removeAttr:function(a){return this.each(function(){f.removeAttr(this,a)})},prop:function(a,b){return f.access(this,a,b,!0,f.prop)},removeProp:function(a){a=f.propFix[a]||a;return this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){var b,c,d,e,g,h,i;if(f.isFunction(a))return this.each(function(b){f(this).addClass(a.call(this,b,this.className))});if(a&&typeof a=="string"){b=a.split(o);for(c=0,d=this.length;c<d;c++){e=this[c];if(e.nodeType===1)if(!e.className&&b.length===1)e.className=a;else{g=" "+e.className+" ";for(h=0,i=b.length;h<i;h++)~g.indexOf(" "+b[h]+" ")||(g+=b[h]+" ");e.className=f.trim(g)}}}return this},removeClass:function(a){var c,d,e,g,h,i,j;if(f.isFunction(a))return this.each(function(b){f(this).removeClass(a.call(this,b,this.className))});if(a&&typeof a=="string"||a===b){c=(a||"").split(o);for(d=0,e=this.length;d<e;d++){g=this[d];if(g.nodeType===1&&g.className)if(a){h=(" "+g.className+" ").replace(n," ");for(i=0,j=c.length;i<j;i++)h=h.replace(" "+c[i]+" "," ");g.className=f.trim(h)}else g.className=""}}return this},toggleClass:function(a,b){var c=typeof a,d=typeof b=="boolean";if(f.isFunction(a))return this.each(function(c){f(this).toggleClass(a.call(this,c,this.className,b),b)});return this.each(function(){if(c==="string"){var e,g=0,h=f(this),i=b,j=a.split(o);while(e=j[g++])i=d?i:!h.hasClass(e),h[i?"addClass":"removeClass"](e)}else if(c==="undefined"||c==="boolean")this.className&&f._data(this,"__className__",this.className),this.className=this.className||a===!1?"":f._data(this,"__className__")||""})},hasClass:function(a){var b=" "+a+" ";for(var c=0,d=this.length;c<d;c++)if((" "+this[c].className+" ").replace(n," ").indexOf(b)>-1)return!0;return!1},val:function(a){var c,d,e=this[0];if(!arguments.length){if(e){c=f.valHooks[e.nodeName.toLowerCase()]||f.valHooks[e.type];if(c&&"get"in c&&(d=c.get(e,"value"))!==b)return d;d=e.value;return typeof d=="string"?d.replace(p,""):d==null?"":d}return b}var g=f.isFunction(a);return this.each(function(d){var e=f(this),h;if(this.nodeType===1){g?h=a.call(this,d,e.val()):h=a,h==null?h="":typeof h=="number"?h+="":f.isArray(h)&&(h=f.map(h,function(a){return a==null?"":a+""})),c=f.valHooks[this.nodeName.toLowerCase()]||f.valHooks[this.type];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h}})}}),f.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c=a.selectedIndex,d=[],e=a.options,g=a.type==="select-one";if(c<0)return null;for(var h=g?c:0,i=g?c+1:e.length;h<i;h++){var j=e[h];if(j.selected&&(f.support.optDisabled?!j.disabled:j.getAttribute("disabled")===null)&&(!j.parentNode.disabled||!f.nodeName(j.parentNode,"optgroup"))){b=f(j).val();if(g)return b;d.push(b)}}if(g&&!d.length&&e.length)return f(e[c]).val();return d},set:function(a,b){var c=f.makeArray(b);f(a).find("option").each(function(){this.selected=f.inArray(f(this).val(),c)>=0}),c.length||(a.selectedIndex=-1);return c}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attrFix:{tabindex:"tabIndex"},attr:function(a,c,d,e){var g=a.nodeType;if(!a||g===3||g===8||g===2)return b;if(e&&c in f.attrFn)return f(a)[c](d);if(!("getAttribute"in a))return f.prop(a,c,d);var h,i,j=g!==1||!f.isXMLDoc(a);j&&(c=f.attrFix[c]||c,i=f.attrHooks[c],i||(t.test(c)?i=w:v&&c!=="className"&&(f.nodeName(a,"form")||u.test(c))&&(i=v)));if(d!==b){if(d===null){f.removeAttr(a,c);return b}if(i&&"set"in i&&j&&(h=i.set(a,d,c))!==b)return h;a.setAttribute(c,""+d);return d}if(i&&"get"in i&&j&&(h=i.get(a,c))!==null)return h;h=a.getAttribute(c);return h===null?b:h},removeAttr:function(a,b){var c;a.nodeType===1&&(b=f.attrFix[b]||b,f.support.getSetAttribute?a.removeAttribute(b):(f.attr(a,b,""),a.removeAttributeNode(a.getAttributeNode(b))),t.test(b)&&(c=f.propFix[b]||b)in a&&(a[c]=!1))},attrHooks:{type:{set:function(a,b){if(q.test(a.nodeName)&&a.parentNode)f.error("type property can't be changed");else if(!f.support.radioValue&&b==="radio"&&f.nodeName(a,"input")){var c=a.value;a.setAttribute("type",b),c&&(a.value=c);return b}}},tabIndex:{get:function(a){var c=a.getAttributeNode("tabIndex");return c&&c.specified?parseInt(c.value,10):r.test(a.nodeName)||s.test(a.nodeName)&&a.href?0:b}},value:{get:function(a,b){if(v&&f.nodeName(a,"button"))return v.get(a,b);return b in a?a.value:null},set:function(a,b,c){if(v&&f.nodeName(a,"button"))return v.set(a,b,c);a.value=b}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(a,c,d){var e=a.nodeType;if(!a||e===3||e===8||e===2)return b;var g,h,i=e!==1||!f.isXMLDoc(a);i&&(c=f.propFix[c]||c,h=f.propHooks[c]);return d!==b?h&&"set"in h&&(g=h.set(a,d,c))!==b?g:a[c]=d:h&&"get"in h&&(g=h.get(a,c))!==b?g:a[c]},propHooks:{}}),w={get:function(a,c){return f.prop(a,c)?c.toLowerCase():b},set:function(a,b,c){var d;b===!1?f.removeAttr(a,c):(d=f.propFix[c]||c,d in a&&(a[d]=!0),a.setAttribute(c,c.toLowerCase()));return c}},f.support.getSetAttribute||(f.attrFix=f.propFix,v=f.attrHooks.name=f.attrHooks.title=f.valHooks.button={get:function(a,c){var d;d=a.getAttributeNode(c);return d&&d.nodeValue!==""?d.nodeValue:b},set:function(a,b,c){var d=a.getAttributeNode(c);if(d){d.nodeValue=b;return b}}},f.each(["width","height"],function(a,b){f.attrHooks[b]=f.extend(f.attrHooks[b],{set:function(a,c){if(c===""){a.setAttribute(b,"auto");return c}}})})),f.support.hrefNormalized||f.each(["href","src","width","height"],function(a,c){f.attrHooks[c]=f.extend(f.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return d===null?b:d}})}),f.support.style||(f.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=""+b}}),f.support.optSelected||(f.propHooks.selected=f.extend(f.propHooks.selected,{get:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}})),f.support.checkOn||f.each(["radio","checkbox"],function(){f.valHooks[this]={get:function(a){return a.getAttribute("value")===null?"on":a.value}}}),f.each(["radio","checkbox"],function(){f.valHooks[this]=f.extend(f.valHooks[this],{set:function(a,b){if(f.isArray(b))return a.checked=f.inArray(f(a).val(),b)>=0}})});var x=/\.(.*)$/,y=/^(?:textarea|input|select)$/i,z=/\./g,A=/ /g,B=/[^\w\s.|`]/g,C=function(a){return a.replace(B,"\\$&")};f.event={add:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){if(d===!1)d=D;else if(!d)return;var g,h;d.handler&&(g=d,d=g.handler),d.guid||(d.guid=f.guid++);var i=f._data(a);if(!i)return;var j=i.events,k=i.handle;j||(i.events=j={}),k||(i.handle=k=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.handle.apply(k.elem,arguments):b}),k.elem=a,c=c.split(" ");var l,m=0,n;while(l=c[m++]){h=g?f.extend({},g):{handler:d,data:e},l.indexOf(".")>-1?(n=l.split("."),l=n.shift(),h.namespace=n.slice(0).sort().join(".")):(n=[],h.namespace=""),h.type=l,h.guid||(h.guid=d.guid);var o=j[l],p=f.event.special[l]||{};if(!o){o=j[l]=[];if(!p.setup||p.setup.call(a,e,n,k)===!1)a.addEventListener?a.addEventListener(l,k,!1):a.attachEvent&&a.attachEvent("on"+l,k)}p.add&&(p.add.call(a,h),h.handler.guid||(h.handler.guid=d.guid)),o.push(h),f.event.global[l]=!0}a=null}},global:{},remove:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){d===!1&&(d=D);var g,h,i,j,k=0,l,m,n,o,p,q,r,s=f.hasData(a)&&f._data(a),t=s&&s.events;if(!s||!t)return;c&&c.type&&(d=c.handler,c=c.type);if(!c||typeof c=="string"&&c.charAt(0)==="."){c=c||"";for(h in t)f.event.remove(a,h+c);return}c=c.split(" ");while(h=c[k++]){r=h,q=null,l=h.indexOf(".")<0,m=[],l||(m=h.split("."),h=m.shift(),n=new RegExp("(^|\\.)"+f.map(m.slice(0).sort(),C).join("\\.(?:.*\\.)?")+"(\\.|$)")),p=t[h];if(!p)continue;if(!d){for(j=0;j<p.length;j++){q=p[j];if(l||n.test(q.namespace))f.event.remove(a,r,q.handler,j),p.splice(j--,1)}continue}o=f.event.special[h]||{};for(j=e||0;j<p.length;j++){q=p[j];if(d.guid===q.guid){if(l||n.test(q.namespace))e==null&&p.splice(j--,1),o.remove&&o.remove.call(a,q);if(e!=null)break}}if(p.length===0||e!=null&&p.length===1)(!o.teardown||o.teardown.call(a,m)===!1)&&f.removeEvent(a,h,s.handle),g=null,delete t[h]}if(f.isEmptyObject(t)){var u=s.handle;u&&(u.elem=null),delete s.events,delete s.handle,f.isEmptyObject(s)&&f.removeData(a,b,!0)}}},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(c,d,e,g){var h=c.type||c,i=[],j;h.indexOf("!")>=0&&(h=h.slice(0,-1),j=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.
-shift(),i.sort());if(!!e&&!f.event.customEvent[h]||!!f.event.global[h]){c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.exclusive=j,c.namespace=i.join("."),c.namespace_re=new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)");if(g||!e)c.preventDefault(),c.stopPropagation();if(!e){f.each(f.cache,function(){var a=f.expando,b=this[a];b&&b.events&&b.events[h]&&f.event.trigger(c,d,b.handle.elem)});return}if(e.nodeType===3||e.nodeType===8)return;c.result=b,c.target=e,d=d!=null?f.makeArray(d):[],d.unshift(c);var k=e,l=h.indexOf(":")<0?"on"+h:"";do{var m=f._data(k,"handle");c.currentTarget=k,m&&m.apply(k,d),l&&f.acceptData(k)&&k[l]&&k[l].apply(k,d)===!1&&(c.result=!1,c.preventDefault()),k=k.parentNode||k.ownerDocument||k===c.target.ownerDocument&&a}while(k&&!c.isPropagationStopped());if(!c.isDefaultPrevented()){var n,o=f.event.special[h]||{};if((!o._default||o._default.call(e.ownerDocument,c)===!1)&&(h!=="click"||!f.nodeName(e,"a"))&&f.acceptData(e)){try{l&&e[h]&&(n=e[l],n&&(e[l]=null),f.event.triggered=h,e[h]())}catch(p){}n&&(e[l]=n),f.event.triggered=b}}return c.result}},handle:function(c){c=f.event.fix(c||a.event);var d=((f._data(this,"events")||{})[c.type]||[]).slice(0),e=!c.exclusive&&!c.namespace,g=Array.prototype.slice.call(arguments,0);g[0]=c,c.currentTarget=this;for(var h=0,i=d.length;h<i;h++){var j=d[h];if(e||c.namespace_re.test(j.namespace)){c.handler=j.handler,c.data=j.data,c.handleObj=j;var k=j.handler.apply(this,g);k!==b&&(c.result=k,k===!1&&(c.preventDefault(),c.stopPropagation()));if(c.isImmediatePropagationStopped())break}}return c.result},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(a){if(a[f.expando])return a;var d=a;a=f.Event(d);for(var e=this.props.length,g;e;)g=this.props[--e],a[g]=d[g];a.target||(a.target=a.srcElement||c),a.target.nodeType===3&&(a.target=a.target.parentNode),!a.relatedTarget&&a.fromElement&&(a.relatedTarget=a.fromElement===a.target?a.toElement:a.fromElement);if(a.pageX==null&&a.clientX!=null){var h=a.target.ownerDocument||c,i=h.documentElement,j=h.body;a.pageX=a.clientX+(i&&i.scrollLeft||j&&j.scrollLeft||0)-(i&&i.clientLeft||j&&j.clientLeft||0),a.pageY=a.clientY+(i&&i.scrollTop||j&&j.scrollTop||0)-(i&&i.clientTop||j&&j.clientTop||0)}a.which==null&&(a.charCode!=null||a.keyCode!=null)&&(a.which=a.charCode!=null?a.charCode:a.keyCode),!a.metaKey&&a.ctrlKey&&(a.metaKey=a.ctrlKey),!a.which&&a.button!==b&&(a.which=a.button&1?1:a.button&2?3:a.button&4?2:0);return a},guid:1e8,proxy:f.proxy,special:{ready:{setup:f.bindReady,teardown:f.noop},live:{add:function(a){f.event.add(this,N(a.origType,a.selector),f.extend({},a,{handler:M,guid:a.handler.guid}))},remove:function(a){f.event.remove(this,N(a.origType,a.selector),a)}},beforeunload:{setup:function(a,b,c){f.isWindow(this)&&(this.onbeforeunload=c)},teardown:function(a,b){this.onbeforeunload===b&&(this.onbeforeunload=null)}}}},f.removeEvent=c.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){a.detachEvent&&a.detachEvent("on"+b,c)},f.Event=function(a,b){if(!this.preventDefault)return new f.Event(a,b);a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||a.returnValue===!1||a.getPreventDefault&&a.getPreventDefault()?E:D):this.type=a,b&&f.extend(this,b),this.timeStamp=f.now(),this[f.expando]=!0},f.Event.prototype={preventDefault:function(){this.isDefaultPrevented=E;var a=this.originalEvent;!a||(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){this.isPropagationStopped=E;var a=this.originalEvent;!a||(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=E,this.stopPropagation()},isDefaultPrevented:D,isPropagationStopped:D,isImmediatePropagationStopped:D};var F=function(a){var b=a.relatedTarget,c=!1,d=a.type;a.type=a.data,b!==this&&(b&&(c=f.contains(this,b)),c||(f.event.handle.apply(this,arguments),a.type=d))},G=function(a){a.type=a.data,f.event.handle.apply(this,arguments)};f.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){f.event.special[a]={setup:function(c){f.event.add(this,b,c&&c.selector?G:F,a)},teardown:function(a){f.event.remove(this,b,a&&a.selector?G:F)}}}),f.support.submitBubbles||(f.event.special.submit={setup:function(a,b){if(!f.nodeName(this,"form"))f.event.add(this,"click.specialSubmit",function(a){var b=a.target,c=b.type;(c==="submit"||c==="image")&&f(b).closest("form").length&&K("submit",this,arguments)}),f.event.add(this,"keypress.specialSubmit",function(a){var b=a.target,c=b.type;(c==="text"||c==="password")&&f(b).closest("form").length&&a.keyCode===13&&K("submit",this,arguments)});else return!1},teardown:function(a){f.event.remove(this,".specialSubmit")}});if(!f.support.changeBubbles){var H,I=function(a){var b=a.type,c=a.value;b==="radio"||b==="checkbox"?c=a.checked:b==="select-multiple"?c=a.selectedIndex>-1?f.map(a.options,function(a){return a.selected}).join("-"):"":f.nodeName(a,"select")&&(c=a.selectedIndex);return c},J=function(c){var d=c.target,e,g;if(!!y.test(d.nodeName)&&!d.readOnly){e=f._data(d,"_change_data"),g=I(d),(c.type!=="focusout"||d.type!=="radio")&&f._data(d,"_change_data",g);if(e===b||g===e)return;if(e!=null||g)c.type="change",c.liveFired=b,f.event.trigger(c,arguments[1],d)}};f.event.special.change={filters:{focusout:J,beforedeactivate:J,click:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(c==="radio"||c==="checkbox"||f.nodeName(b,"select"))&&J.call(this,a)},keydown:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(a.keyCode===13&&!f.nodeName(b,"textarea")||a.keyCode===32&&(c==="checkbox"||c==="radio")||c==="select-multiple")&&J.call(this,a)},beforeactivate:function(a){var b=a.target;f._data(b,"_change_data",I(b))}},setup:function(a,b){if(this.type==="file")return!1;for(var c in H)f.event.add(this,c+".specialChange",H[c]);return y.test(this.nodeName)},teardown:function(a){f.event.remove(this,".specialChange");return y.test(this.nodeName)}},H=f.event.special.change.filters,H.focus=H.beforeactivate}f.support.focusinBubbles||f.each({focus:"focusin",blur:"focusout"},function(a,b){function e(a){var c=f.event.fix(a);c.type=b,c.originalEvent={},f.event.trigger(c,null,c.target),c.isDefaultPrevented()&&a.preventDefault()}var d=0;f.event.special[b]={setup:function(){d++===0&&c.addEventListener(a,e,!0)},teardown:function(){--d===0&&c.removeEventListener(a,e,!0)}}}),f.each(["bind","one"],function(a,c){f.fn[c]=function(a,d,e){var g;if(typeof a=="object"){for(var h in a)this[c](h,d,a[h],e);return this}if(arguments.length===2||d===!1)e=d,d=b;c==="one"?(g=function(a){f(this).unbind(a,g);return e.apply(this,arguments)},g.guid=e.guid||f.guid++):g=e;if(a==="unload"&&c!=="one")this.one(a,d,e);else for(var i=0,j=this.length;i<j;i++)f.event.add(this[i],a,g,d);return this}}),f.fn.extend({unbind:function(a,b){if(typeof a=="object"&&!a.preventDefault)for(var c in a)this.unbind(c,a[c]);else for(var d=0,e=this.length;d<e;d++)f.event.remove(this[d],a,b);return this},delegate:function(a,b,c,d){return this.live(b,c,d,a)},undelegate:function(a,b,c){return arguments.length===0?this.unbind("live"):this.die(b,null,c,a)},trigger:function(a,b){return this.each(function(){f.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0])return f.event.trigger(a,b,this[0],!0)},toggle:function(a){var b=arguments,c=a.guid||f.guid++,d=0,e=function(c){var e=(f.data(this,"lastToggle"+a.guid)||0)%d;f.data(this,"lastToggle"+a.guid,e+1),c.preventDefault();return b[e].apply(this,arguments)||!1};e.guid=c;while(d<b.length)b[d++].guid=c;return this.click(e)},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});var L={focus:"focusin",blur:"focusout",mouseenter:"mouseover",mouseleave:"mouseout"};f.each(["live","die"],function(a,c){f.fn[c]=function(a,d,e,g){var h,i=0,j,k,l,m=g||this.selector,n=g?this:f(this.context);if(typeof a=="object"&&!a.preventDefault){for(var o in a)n[c](o,d,a[o],m);return this}if(c==="die"&&!a&&g&&g.charAt(0)==="."){n.unbind(g);return this}if(d===!1||f.isFunction(d))e=d||D,d=b;a=(a||"").split(" ");while((h=a[i++])!=null){j=x.exec(h),k="",j&&(k=j[0],h=h.replace(x,""));if(h==="hover"){a.push("mouseenter"+k,"mouseleave"+k);continue}l=h,L[h]?(a.push(L[h]+k),h=h+k):h=(L[h]||h)+k;if(c==="live")for(var p=0,q=n.length;p<q;p++)f.event.add(n[p],"live."+N(h,m),{data:d,selector:m,handler:e,origType:h,origHandler:e,preType:l});else n.unbind("live."+N(h,m),e)}return this}}),f.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error".split(" "),function(a,b){f.fn[b]=function(a,c){c==null&&(c=a,a=null);return arguments.length>0?this.bind(b,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0)}),function(){function u(a,b,c,d,e,f){for(var g=0,h=d.length;g<h;g++){var i=d[g];if(i){var j=!1;i=i[a];while(i){if(i.sizcache===c){j=d[i.sizset];break}if(i.nodeType===1){f||(i.sizcache=c,i.sizset=g);if(typeof b!="string"){if(i===b){j=!0;break}}else if(k.filter(b,[i]).length>0){j=i;break}}i=i[a]}d[g]=j}}}function t(a,b,c,d,e,f){for(var g=0,h=d.length;g<h;g++){var i=d[g];if(i){var j=!1;i=i[a];while(i){if(i.sizcache===c){j=d[i.sizset];break}i.nodeType===1&&!f&&(i.sizcache=c,i.sizset=g);if(i.nodeName.toLowerCase()===b){j=i;break}i=i[a]}d[g]=j}}}var a=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d=0,e=Object.prototype.toString,g=!1,h=!0,i=/\\/g,j=/\W/;[0,0].sort(function(){h=!1;return 0});var k=function(b,d,f,g){f=f||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return f;var i,j,n,o,q,r,s,t,u=!0,w=k.isXML(d),x=[],y=b;do{a.exec(""),i=a.exec(y);if(i){y=i[3],x.push(i[1]);if(i[2]){o=i[3];break}}}while(i);if(x.length>1&&m.exec(b))if(x.length===2&&l.relative[x[0]])j=v(x[0]+x[1],d);else{j=l.relative[x[0]]?[d]:k(x.shift(),d);while(x.length)b=x.shift(),l.relative[b]&&(b+=x.shift()),j=v(b,j)}else{!g&&x.length>1&&d.nodeType===9&&!w&&l.match.ID.test(x[0])&&!l.match.ID.test(x[x.length-1])&&(q=k.find(x.shift(),d,w),d=q.expr?k.filter(q.expr,q.set)[0]:q.set[0]);if(d){q=g?{expr:x.pop(),set:p(g)}:k.find(x.pop(),x.length===1&&(x[0]==="~"||x[0]==="+")&&d.parentNode?d.parentNode:d,w),j=q.expr?k.filter(q.expr,q.set):q.set,x.length>0?n=p(j):u=!1;while(x.length)r=x.pop(),s=r,l.relative[r]?s=x.pop():r="",s==null&&(s=d),l.relative[r](n,s,w)}else n=x=[]}n||(n=j),n||k.error(r||b);if(e.call(n)==="[object Array]")if(!u)f.push.apply(f,n);else if(d&&d.nodeType===1)for(t=0;n[t]!=null;t++)n[t]&&(n[t]===!0||n[t].nodeType===1&&k.contains(d,n[t]))&&f.push(j[t]);else for(t=0;n[t]!=null;t++)n[t]&&n[t].nodeType===1&&f.push(j[t]);else p(n,f);o&&(k(o,h,f,g),k.uniqueSort(f));return f};k.uniqueSort=function(a){if(r){g=h,a.sort(r);if(g)for(var b=1;b<a.length;b++)a[b]===a[b-1]&&a.splice(b--,1)}return a},k.matches=function(a,b){return k(a,null,null,b)},k.matchesSelector=function(a,b){return k(b,null,null,[a]).length>0},k.find=function(a,b,c){var d;if(!a)return[];for(var e=0,f=l.order.length;e<f;e++){var g,h=l.order[e];if(g=l.leftMatch[h].exec(a)){var j=g[1];g.splice(1,1);if(j.substr(j.length-1)!=="\\"){g[1]=(g[1]||"").replace(i,""),d=l.find[h](g,b,c);if(d!=null){a=a.replace(l.match[h],"");break}}}}d||(d=typeof b.getElementsByTagName!="undefined"?b.getElementsByTagName("*"):[]);return{set:d,expr:a}},k.filter=function(a,c,d,e){var f,g,h=a,i=[],j=c,m=c&&c[0]&&k.isXML(c[0]);while(a&&c.length){for(var n in l.filter)if((f=l.leftMatch[n].exec(a))!=null&&f[2]){var o,p,q=l.filter[n],r=f[1];g=!1,f.splice(1,1);if(r.substr(r.length-1)==="\\")continue;j===i&&(i=[]);if(l.preFilter[n]){f=l.preFilter[n](f,j,d,i,e,m);if(!f)g=o=!0;else if(f===!0)continue}if(f)for(var s=0;(p=j[s])!=null;s++)if(p){o=q(p,f,s,j);var t=e^!!o;d&&o!=null?t?g=!0:j[s]=!1:t&&(i.push(p),g=!0)}if(o!==b){d||(j=i),a=a.replace(l.match[n],"");if(!g)return[];break}}if(a===h)if(g==null)k.error(a);else break;h=a}return j},k.error=function(a){throw"Syntax error, unrecognized expression: "+a};var l=k.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(?:(['"])(.*?)\3|(#?(?:[\w\u00c0-\uFFFF\-]|\\.)*)|)|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\(\s*(even|odd|(?:[+\-]?\d+|(?:[+\-]?\d*)?n\s*(?:[+\-]\s*\d+)?))\s*\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(a){return a.getAttribute("href")},type:function(a){return a.getAttribute("type")}},relative:{"+":function(a,b){var c=typeof b=="string",d=c&&!j.test(b),e=c&&!d;d&&(b=b.toLowerCase());for(var f=0,g=a.length,h;f<g;f++)if(h=a[f]){while((h=h.previousSibling)&&h.nodeType!==1);a[f]=e||h&&h.nodeName.toLowerCase()===b?h||!1:h===b}e&&k.filter(b,a,!0)},">":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!j.test(b)){b=b.toLowerCase();for(;e<f;e++){c=a[e];if(c){var g=c.parentNode;a[e]=g.nodeName.toLowerCase()===b?g:!1}}}else{for(;e<f;e++)c=a[e],c&&(a[e]=d?c.parentNode:c.parentNode===b);d&&k.filter(b,a,!0)}},"":function(a,b,c){var e,f=d++,g=u;typeof b=="string"&&!j.test(b)&&(b=b.toLowerCase(),e=b,g=t),g("parentNode",b,f,a,e,c)},"~":function(a,b,c){var e,f=d++,g=u;typeof b=="string"&&!j.test(b)&&(b=b.toLowerCase(),e=b,g=t),g("previousSibling",b,f,a,e,c)}},find:{ID:function(a,b,c){if(typeof b.getElementById!="undefined"&&!c){var d=b.getElementById(a[1]);return d&&d.parentNode?[d]:[]}},NAME:function(a,b){if(typeof b.getElementsByName!="undefined"){var c=[],d=b.getElementsByName(a[1]);for(var e=0,f=d.length;e<f;e++)d[e].getAttribute("name")===a[1]&&c.push(d[e]);return c.length===0?null:c}},TAG:function(a,b){if(typeof b.getElementsByTagName!="undefined")return b.getElementsByTagName(a[1])}},preFilter:{CLASS:function(a,b,c,d,e,f){a=" "+a[1].replace(i,"")+" ";if(f)return a;for(var g=0,h;(h=b[g])!=null;g++)h&&(e^(h.className&&(" "+h.className+" ").replace(/[\t\n\r]/g," ").indexOf(a)>=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(i,"")},TAG:function(a,b){return a[1].replace(i,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||k.error(a[0]),a[2]=a[2].replace(/^\+|\s*/g,"");var b=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0,a[3]=b[3]-0}else a[2]&&k.error(a[0]);a[0]=d++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(i,"");!f&&l.attrMap[g]&&(a[1]=l.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(i,""),a[2]==="~="&&(a[4]=" "+a[4]+" ");return a},PSEUDO:function(b,c,d,e,f){if(b[1]==="not")if((a.exec(b[3])||"").length>1||/^\w/.test(b[3]))b[3]=k(b[3],null,null,c);else{var g=k.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(l.match.POS.test(b[0])||l.match.CHILD.test(b[0]))return!0;return b},POS:function(a){a.unshift(!0);return a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){a.parentNode&&a.parentNode.selectedIndex;return a.selected===!0},parent:function(a){return!!a.firstChild},empty:function(a){return!a.firstChild},has:function(a,b,c){return!!k(c[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){var b=a.getAttribute("type"),c=a.type;return a.nodeName.toLowerCase()==="input"&&"text"===c&&(b===c||b===null)},radio:function(a){return a.nodeName.toLowerCase()==="input"&&"radio"===a.type},checkbox:function(a){return a.nodeName.toLowerCase()==="input"&&"checkbox"===a.type},file:function(a){return a.nodeName.toLowerCase()==="input"&&"file"===a.type},password:function(a){return a.nodeName.toLowerCase()==="input"&&"password"===a.type},submit:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"submit"===a.type},image:function(a){return a.nodeName.toLowerCase()==="input"&&"image"===a.type},reset:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"reset"===a.type},button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&"button"===a.type||b==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},focus:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b){return b===0},last:function(a,b,c,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,c){return b<c[3]-0},gt:function(a,b,c){return b>c[3]-0},nth:function(a,b,c){return c[3]-0===b},eq:function(a,b,c){return c[3]-0===b}},filter:{PSEUDO:function(a,b,c,d){var e=b[1],f=l.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||k.getText([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h<i;h++)if(g[h]===a)return!1;return!0}k.error(e)},CHILD:function(a,b){var c=b[1],d=a;switch(c){case"only":case"first":while(d=d.previousSibling)if(d.nodeType===1)return!1;if(c==="first")return!0;d=a;case"last":while(d=d.nextSibling)if(d.nodeType===1)return!1;return!0;case"nth":var e=b[2],f=b[3];if(e===1&&f===0)return!0;var g=b[0],h=a.parentNode;if(h&&(h.sizcache!==g||!a.nodeIndex)){var i=0;for(d=h.firstChild;d;d=d.nextSibling)d.nodeType===1&&(d.nodeIndex=++i);h.sizcache=g}var j=a.nodeIndex-f;return e===0?j===0:j%e===0&&j/e>=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var c=b[1],d=l.attrHandle[c]?l.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":f==="="?e===g:f==="*="?e.indexOf(g)>=0:f==="~="?(" "+e+" ").indexOf(g)>=0:g?f==="!="?e!==g:f==="^="?e.indexOf(g)===0:f==="$="?e.substr(e.length-g.length)===g:f==="|="?e===g||e.substr(0,g.length+1)===g+"-":!1:e&&d!==!1},POS:function(a,b,c,d){var e=b[2],f=l.setFilters[e];if(f)return f(a,c,b,d)}}},m=l.match.POS,n=function(a,b){return"\\"+(b-0+1)};for(var o in l.match)l.match[o]=new RegExp(l.match[o].source+/(?![^\[]*\])(?![^\(]*\))/.source),l.leftMatch[o]=new RegExp(/(^(?:.|\r|\n)*?)/.source+l.match[o].source.replace(/\\(\d+)/g,n));var p=function(a,b){a=Array.prototype.slice.call(a,0);if(b){b.push.apply(b,a);return b}return a};try{Array.prototype.slice.call(c.documentElement.childNodes,0)[0].nodeType}catch(q){p=function(a,b){var c=0,d=b||[];if(e.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var f=a.length;c<f;c++)d.push(a[c]);else for(;a[c];c++)d.push(a[c]);return d}}var r,s;c.documentElement.compareDocumentPosition?r=function(a,b){if(a===b){g=!0;return 0}if(!a.compareDocumentPosition||!b.compareDocumentPosition)return a.compareDocumentPosition?-1:1;return a.compareDocumentPosition(b)&4?-1:1}:(r=function(a,b){if(a===b){g=!0;return 0}if(a.sourceIndex&&b.sourceIndex)return a.sourceIndex-b.sourceIndex;var c,d,e=[],f=[],h=a.parentNode,i=b.parentNode,j=h;if(h===i)return s(a,b);if(!h)return-1;if(!i)return 1;while(j)e.unshift(j),j=j.parentNode;j=i;while(j)f.unshift(j),j=j.parentNode;c=e.length,d=f.length;for(var k=0;k<c&&k<d;k++)if(e[k]!==f[k])return s(e[k],f[k]);return k===c?s(a,f[k],-1):s(e[k],b,1)},s=function(a,b,c){if(a===b)return c;var d=a.nextSibling;while(d){if(d===b)return-1;d=d.nextSibling}return 1}),k.getText=function(a){var b="",c;for(var d=0;a[d];d++)c=a[d],c.nodeType===3||c.nodeType===4?b+=c.nodeValue:c.nodeType!==8&&(b+=k.getText(c.childNodes));return b},function(){var a=c.createElement("div"),d="script"+(new Date).getTime(),e=c.documentElement;a.innerHTML="<a name='"+d+"'/>",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(l.find.ID=function(a,c,d){if(typeof c.getElementById!="undefined"&&!d){var e=c.getElementById(a[1]);return e?e.id===a[1]||typeof e.getAttributeNode!="undefined"&&e.getAttributeNode("id").nodeValue===a[1]?[e]:b:[]}},l.filter.ID=function(a,b){var c=typeof a.getAttributeNode!="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&c&&c.nodeValue===b}),e.removeChild(a),e=a=null}(),function(){var a=c.createElement("div");a.appendChild(c.createComment("")),a.getElementsByTagName("*").length>0&&(l.find.TAG=function(a,b){var c=b.getElementsByTagName(a[1]);if(a[1]==="*"){var d=[];for(var e=0;c[e];e++)c[e].nodeType===1&&d.push(c[e]);c=d}return c}),a.innerHTML="<a href='#'></a>",a.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(l.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=k,b=c.createElement("div"),d="__sizzle__";b.innerHTML="<p class='TEST'></p>";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){k=function(b,e,f,g){e=e||c;if(!g&&!k.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return p(e.getElementsByTagName(b),f);if(h[2]&&l.find.CLASS&&e.getElementsByClassName)return p(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return p([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return p([],f);if(i.id===h[3])return p([i],f)}try{return p(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var m=e,n=e.getAttribute("id"),o=n||d,q=e.parentNode,r=/^\s*[+~]/.test(b);n?o=o.replace(/'/g,"\\$&"):e.setAttribute("id",o),r&&q&&(e=e.parentNode);try{if(!r||q)return p(e.querySelectorAll("[id='"+o+"'] "+b),f)}catch(s){}finally{n||m.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)k[e]=a[e];b=null}}(),function(){var a=c.documentElement,b=a.matchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.msMatchesSelector;if(b){var d=!b.call(c.createElement("div"),"div"),e=!1;try{b.call(c.documentElement,"[test!='']:sizzle")}catch(f){e=!0}k.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!k.isXML(a))try{if(e||!l.match.PSEUDO.test(c)&&!/!=/.test(c)){var f=b.call(a,c);if(f||!d||a.document&&a.document.nodeType!==11)return f}}catch(g){}return k(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="<div class='test e'></div><div class='test'></div>";if(!!a.getElementsByClassName&&a.getElementsByClassName("e").length!==0){a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;l.order.splice(1,0,"CLASS"),l.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?k.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?k.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:k.contains=function(){return!1},k.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var v=function(a,b){var c,d=[],e="",f=b.nodeType?[b]:b;while(c=l.match.PSEUDO.exec(a))e+=c[0],a=a.replace(l.match.PSEUDO,"");a=l.relative[a]?a+"*":a;for(var g=0,h=f.length;g<h;g++)k(a,f[g],d);return k.filter(e,d)};f.find=k,f.expr=k.selectors,f.expr[":"]=f.expr.filters,f.unique=k.uniqueSort,f.text=k.getText,f.isXMLDoc=k.isXML,f.contains=k.contains}();var O=/Until$/,P=/^(?:parents|prevUntil|prevAll)/,Q=/,/,R=/^.[^:#\[\.,]*$/,S=Array.prototype.slice,T=f.expr.match.POS,U={children:!0,contents:!0,next:!0,prev:!0};f.fn.extend({find:function(a){var b=this,c,d;if(typeof a!="string")return f(a).filter(function(){for(c=0,d=b.length;c<d;c++)if(f.contains(b[c],this))return!0});var e=this.pushStack("","find",a),g,h,i;for(c=0,d=this.length;c<d;c++){g=e.length,f.find(a,this[c],e);if(c>0)for(h=g;h<e.length;h++)for(i=0;i<g;i++)if(e[i]===e[h]){e.splice(h--,1);break}}return e},has:function(a){var b=f(a);return this.filter(function(){for(var a=0,c=b.length;a<c;a++)if(f.contains(this,b[a]))return!0})},not:function(a){return this.pushStack(W(this,a,!1),"not",a)},filter:function(a){return this.pushStack(W(this,a,!0),"filter",a)},is:function(a){return!!a&&(typeof a=="string"?f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h,i,j={},k=1;if(g&&a.length){for(d=0,e=a.length;d<e;d++)i=a[d],j[i]||(j[i]=T.test(i)?f(i,b||this.context):i);while(g&&g.ownerDocument&&g!==b){for(i in j)h=j[i],(h.jquery?h.index(g)>-1:f(g).is(h))&&c.push({selector:i,elem:g,level:k});g=g.parentNode,k++}}return c}var l=T.test(a)||typeof a!="string"?f(a,b||this.context):0;for(d=0,e=this.length;d<e;d++){g=this[d];while(g){if(l?l.index(g)>-1:f.find.matchesSelector(g,a)){c.push(g);break}g=g.parentNode;if(!g||!g.ownerDocument||g===b||g.nodeType===11)break}}c=c.length>1?f.unique(c):c;return this.pushStack(c,"closest",a)},index:function(a){if(!a||typeof a=="string")return f.inArray(this[0],a?f(a):this.parent().children());return f.inArray(a.jquery?a[0]:a,this)},add:function(a,b){var c=typeof a=="string"?f(a,b):f.makeArray(a&&a.nodeType?[a]:a),d=f.merge(this.get(),c);return this.pushStack(V(c[0])||V(d[0])?d:f.unique(d))},andSelf:function(){return this.add(this.prevObject)}}),f.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return f.dir(a,"parentNode")},parentsUntil:function(a,b,c){return f.dir(a,"parentNode",c)},next:function(a){return f.nth(a,2,"nextSibling")},prev:function(a){return f.nth(a,2,"previousSibling")},nextAll:function(a){return f.dir(a,"nextSibling")},prevAll:function(a){return f.dir(a,"previousSibling")},nextUntil:function(a,b,c){return f.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return f.dir(a,"previousSibling",c)},siblings:function(a){return f.sibling(a.parentNode.firstChild,a)},children:function(a){return f.sibling(a.firstChild)},contents:function(a){return f.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:f.makeArray(a.childNodes)}},function(a,b){f.fn[a]=function(c,d){var e=f.map(this,b,c),g=S.call(arguments);O.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!U[a]?f.unique(e):e,(this.length>1||Q.test(d))&&P.test(a)&&(e=e.reverse());return this.pushStack(e,a,g.join(","))}}),f.extend({filter:function(a,b,c){c&&(a=":not("+a+")");return b.length===1?f.find.matchesSelector(b[0],a)?[b[0]]:[]:f.find.matches(a,b)},dir:function(a,c,d){var e=[],g=a[c];while(g&&g.nodeType!==9&&(d===b||g.nodeType!==1||!f(g).is(d)))g.nodeType===1&&e.push(g),g=g[c];return e},nth:function(a,b,c,d){b=b||1;var e=0;for(;a;a=a[c])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var X=/ jQuery\d+="(?:\d+|null)"/g,Y=/^\s+/,Z=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>...
[truncated message content] |
|
From: <os...@us...> - 2012-02-28 09:22:05
|
Revision: 4045
http://oscss.svn.sourceforge.net/oscss/?rev=4045&view=rev
Author: oscim
Date: 2012-02-28 09:21:53 +0000 (Tue, 28 Feb 2012)
Log Message:
-----------
suite centralisation et evolution des exxtra pour les client et les produits
Modified Paths:
--------------
trunk/catalog/admin/includes/classes/drivers/sqlproductsextrafields.php
trunk/catalog/admin/includes/gabarit/configuration/modcustextra/draw.edit.gab
trunk/catalog/admin/includes/gabarit/configuration/modcustextra/draw.listing.gab
trunk/catalog/admin/includes/gabarit/configuration/modprodextra/draw.label.listing.gab
trunk/catalog/admin/includes/gabarit/configuration/modprodextra/draw.label.new.gab
trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modcustextra.txt
trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modprodextra.txt
trunk/catalog/admin/includes/modules/account/account_extra.php
trunk/catalog/admin/includes/modules/configuration/modcustextra.php
trunk/catalog/admin/includes/modules/configuration/modprodextra.php
trunk/catalog/common/classes/ExtraUtility.php
trunk/catalog/includes/classes/drivers/data/product.php
Added Paths:
-----------
trunk/catalog/admin/includes/gabarit/products/products_extra/
trunk/catalog/admin/includes/gabarit/products/products_extra/display_edit.edit.gab
trunk/catalog/admin/includes/modules/products/products_extra.php
Modified: trunk/catalog/admin/includes/classes/drivers/sqlproductsextrafields.php
===================================================================
--- trunk/catalog/admin/includes/classes/drivers/sqlproductsextrafields.php 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/classes/drivers/sqlproductsextrafields.php 2012-02-28 09:21:53 UTC (rev 4045)
@@ -39,7 +39,7 @@
$sql_data_array['epf_order'] =(isset($option['order']))? tep_db_prepare_input($option['order']) : 0 ;
$sql_data_array['epf_status'] =(isset($option['status']))? tep_db_prepare_input($option['status']) : 0;
- $sql_data_array['epf_uses_value_list'] =(isset($option['uses_value_list'])) ? tep_db_prepare_input($option['uses_value_list']) : 0;
+ $sql_data_array['epf_input_type'] =(isset($option['input_type'])) ? tep_db_prepare_input($option['input_type']) : 0;
$sql_data_array['epf_advanced_search'] =(isset($option['advanced_search']))? tep_db_prepare_input($option['advanced_search']): 0;
$sql_data_array['epf_show_in_listing'] = (isset($option['show_in_listing'])) ? tep_db_prepare_input($option['show_in_listing']): 0;
$sql_data_array['epf_use_as_meta_keyword'] =(isset($option['use_as_meta_keyword']))? tep_db_prepare_input($option['use_as_meta_keyword']): 0;
@@ -47,12 +47,12 @@
$sql_data_array['epf_admin'] =(isset($option['admin']))? tep_db_prepare_input($option['admin']) : 0;
if(isset($option['size'])) $sql_data_array['epf_size'] = tep_db_prepare_input($option['size']);
- if(isset($option['show_parent_chain'])) $sql_data_array['epf_show_parent_chain'] = tep_db_prepare_input($option['show_parent_chain']);
- if(isset($option['key'])) $sql_data_array['epf_key'] = tep_db_prepare_input($option['key']);
- if(isset($option['special_mod'])) $sql_data_array['epf_special_mod'] = tep_db_prepare_input($option['special_mod']);
+ if(isset($option['show_parent_chain'])) $sql_data_array['epf_show_parent_chain'] = tep_db_prepare_input($option['show_parent_chain']);
+ if(isset($option['key'])) $sql_data_array['epf_key'] = tep_db_prepare_input($option['key']);
+ if(isset($option['special_mod'])) $sql_data_array['epf_special_mod'] = tep_db_prepare_input($option['special_mod']);
+ if(isset($option['active_value_language'])) $sql_data_array['epf_active_value_language'] = tep_db_prepare_input($option['active_value_language']);
-
$res=tep_db_perform(TABLE_PRODUCTS_EXTRA_FIELDS, $sql_data_array);
if(!$res)
@@ -63,6 +63,8 @@
/**
@brief update ligne in table configuration
+ @note for update key, use new_key in key array $option
+ this key is use in where clause
*/
public static function update($option){
self::getInstance();
@@ -79,17 +81,18 @@
if(isset($option['order']))$sql_data_array['epf_order'] = tep_db_prepare_input($option['order']);
if(isset($option['status'])) $sql_data_array['epf_status'] = tep_db_prepare_input($option['status']);
- if(isset($option['uses_value_list'])) $sql_data_array['epf_uses_value_list'] = tep_db_prepare_input($option['uses_value_list']);
+// if(isset($option['uses_value_list'])) $sql_data_array['epf_input_type'] = tep_db_prepare_input($option['uses_value_list']);
if(isset($option['advanced_search'])) $sql_data_array['epf_advanced_search'] = tep_db_prepare_input($option['advanced_search']);
if(isset($option['show_in_listing']))$sql_data_array['epf_show_in_listing'] = tep_db_prepare_input($option['show_in_listing']);
- if(isset($option['size'])) $sql_data_array['epf_size'] = tep_db_prepare_input($option['size']);
- if(isset($option['use_as_meta_keyword'])) $sql_data_array['epf_use_as_meta_keyword'] = tep_db_prepare_input($option['use_as_meta_keyword']);
- if(isset($option['use_to_restrict_listings'])) $sql_data_array['epf_use_to_restrict_listings'] = tep_db_prepare_input($option['use_to_restrict_listings']);
- if(isset($option['show_parent_chain']))$sql_data_array['epf_show_parent_chain'] = tep_db_prepare_input($option['show_parent_chain']);
- if(isset($option['key'])) $sql_data_array['epf_key'] = tep_db_prepare_input($option['key']);
- if(isset($option['admin'])) $sql_data_array['epf_admin'] = tep_db_prepare_input($option['admin']);
- if(isset($option['special_mod'])) $sql_data_array['epf_special_mod'] = tep_db_prepare_input($option['special_mod']);
-
+ if(isset($option['size'])) $sql_data_array['epf_size'] = tep_db_prepare_input($option['size']);
+ if(isset($option['use_as_meta_keyword'])) $sql_data_array['epf_use_as_meta_keyword'] = tep_db_prepare_input($option['use_as_meta_keyword']);
+ if(isset($option['use_to_restrict_listings'])) $sql_data_array['epf_use_to_restrict_listings'] = tep_db_prepare_input($option['use_to_restrict_listings']);
+ if(isset($option['show_parent_chain'])) $sql_data_array['epf_show_parent_chain'] = tep_db_prepare_input($option['show_parent_chain']);
+ if(isset($option['new_key'])) $sql_data_array['epf_key'] = tep_db_prepare_input($option['new_key']);
+ if(isset($option['admin'])) $sql_data_array['epf_admin'] = (string)tep_db_prepare_input($option['admin']);
+ if(isset($option['special_mod'])) $sql_data_array['epf_special_mod'] = tep_db_prepare_input($option['special_mod']);
+ if(isset($option['active_value_language'])) $sql_data_array['epf_active_value_language'] = tep_db_prepare_input($option['active_value_language']);
+// print_r($option);
$res=tep_db_perform(TABLE_PRODUCTS_EXTRA_FIELDS, $sql_data_array, 'update' , substr($where,3) );
return $res;
@@ -133,6 +136,7 @@
// " LEFT JOIN " . TABLE_IMAGES_USED . " g ON (a.rowid=g.rowid) ".
" WHERE ".substr($sql,3);
+// echo $sql;
$res=$DB->query($sql);
$num = $res->__get('numRows');
@@ -176,7 +180,9 @@
// depend tables
sqlproductsextrafieldslabels::delete(array('id'=>$row['epf_id']));
+ sqlproductsextrafieldsvalues::delete(array('id'=>$row['epf_id']));
+
$DB->query($s="DELETE FROM " . TABLE_PRODUCTS_EXTRA_FIELDS ." WHERE ". substr($sql,3) );
return true;
@@ -187,19 +193,21 @@
@return array product empty
*/
public static function Specimen($shortkey=false){
- $par = array('epf_id' => '',
- 'epf_order' => '',
- 'epf_status' => '',
- 'epf_uses_value_list' => '',
- 'epf_advanced_search' => '',
- 'epf_show_in_listing' => '',
- 'epf_size' => '',
- 'epf_use_as_meta_keyword' => '',
- 'epf_use_to_restrict_listings' => '',
- 'epf_show_parent_chain' => '',
- 'epf_key' => '',
- 'epf_admin' => '',
- 'epf_special_mod' => '',
+ $par = array(
+ 'epf_id' => 0,
+ 'epf_order' => 5,
+ 'epf_status' => 0,
+ 'epf_input_type' => 0,
+ 'epf_advanced_search' => '',
+ 'epf_show_in_listing' => '',
+ 'epf_size' => 0,
+ 'epf_use_as_meta_keyword' => '',
+ 'epf_use_to_restrict_listings' => '',
+ 'epf_show_parent_chain' => '',
+ 'epf_active_value_language' => 0,
+ 'epf_key' => '',
+ 'epf_admin' => 0,
+ 'epf_special_mod' => '',
);
return ((!$shortkey)? $par : self::CleanKey($par));
@@ -256,7 +264,7 @@
$sql_data_array['epf_id'] = tep_db_prepare_input($option['id']);
$sql_data_array['languages_id'] =(isset($option['languages_id']))? tep_db_prepare_input($option['languages_id']) : 0;
- $sql_data_array['epf_active_for_language'] =(isset($option['active_for_language']))? tep_db_prepare_input($option['active_for_language']): 0;
+// $sql_data_array['epf_active_for_language'] =(isset($option['active_for_language']))? tep_db_prepare_input($option['active_for_language']): 0;
$sql_data_array['epf_label'] =(isset($option['label'])) ? tep_db_prepare_input($option['label']) : '';
$sql_data_array['epf_format'] =(isset($option['format']))? tep_db_prepare_input($option['format']): '%label% %input%';
@@ -289,7 +297,7 @@
if($where=='')
return false;
- if(isset($option['active_for_language'])) $sql_data_array['epf_active_for_language'] = tep_db_prepare_input($option['active_for_language']);
+// if(isset($option['active_for_language'])) $sql_data_array['epf_active_for_language'] = tep_db_prepare_input($option['active_for_language']);
if(isset($option['label'])) $sql_data_array['epf_label'] = tep_db_prepare_input($option['label']);
if(isset($option['format'])) $sql_data_array['epf_format'] = tep_db_prepare_input($option['format']);
if(isset($option['label_help'])) $sql_data_array['epf_label_help'] = tep_db_prepare_input($option['label_help']);
@@ -384,12 +392,12 @@
*/
public static function Specimen($shortkey=false){
$par = array(
- 'epf_id' => '',
- 'languages_id' => '',
- 'epf_label' => '',
- 'epf_active_for_language' => '',
- 'epf_label_help' => '',
- 'epf_format' => '',
+ 'epf_id' => 0,
+ 'languages_id' => 0,
+ 'epf_label' => '',
+// 'epf_active_for_language' => false,
+ 'epf_label_help' => '',
+ 'epf_format' => '%label% %input% %unit%',
);
return ((!$shortkey)? $par : self::CleanKey($par));
@@ -416,4 +424,195 @@
}
}
+
+
+
+
+class sqlproductsextrafieldsvalues
+ implements ModSqlDataDriver{
+
+ public static $modules;
+
+ protected static $_instance;
+
+ protected function __construct(){
+ }
+
+
+ public static function getInstance() {
+ if(self::$_instance == null) self::$_instance = new self();
+ return self::$_instance;
+ }
+
+
+ /**
+ @brief create new ligne in table configuration
+ */
+ public static function create($option){
+ self::getInstance();
+
+ if(!isset($option['epf_id']))
+ return 'epf_id';
+
+ $sql_data_array['epf_id'] = tep_db_prepare_input($option['id']);
+ $sql_data_array['languages_id'] =(isset($option['languages_id']))? tep_db_prepare_input($option['languages_id']) : 0;
+
+
+ $sql_data_array['epf_value'] =(isset($option['value'])) ? tep_db_prepare_input($option['value']) : '';
+ $sql_data_array['parent_id'] =(isset($option['parent_id']))? tep_db_prepare_input($option['parent_id']): 0;
+ $sql_data_array['sort_order'] =(isset($option['sort_order'])) ? tep_db_prepare_input($option['sort_order']) :0;
+
+
+ $res=tep_db_perform(TABLE_PRODUCTS_EXTRA_FIELDS_VALUES, $sql_data_array);
+
+ if(!$res)
+ return $res;
+ else
+ return $res->__get('insertId');
+ }
+
+ /**
+ @brief update ligne in table configuration
+ */
+ public static function update($option){
+ self::getInstance();
+
+ if(!isset($option['epf_id']))
+ return false;
+
+ $sql ='';
+ if(isset($option['id'])) $sql .="AND value_id = '".(int)$option['id']."' ";
+ if(isset($option['epf_id'])) $sql .="AND epf_id = '".(int)$option['epf_id']."' ";
+ if(isset($option['languages_id'])) $sql .="AND languages_id = '".(int)$option['languages_id']."' ";
+ if(isset($option['parent_id'])) $sql .="AND parent_id = '".(int)$option['parent_id']."' ";
+
+ if($sql=='')
+ return false;
+
+
+ if(isset($option['value'])) $sql_data_array['epf_value'] = tep_db_prepare_input($option['value']);
+ if(isset($option['sort_order'])) $sql_data_array['sort_order'] = tep_db_prepare_input($option['sort_order']);
+
+
+ $res=tep_db_perform(TABLE_PRODUCTS_EXTRA_FIELDS_VALUES, $sql_data_array, 'update' , substr($sql,3) );
+
+ return $res;
+ }
+
+ /**
+ @brief load ligne in table configuration
+ @param option array
+ id => row id int (configuration_id)
+ key => string key (configuration_key)
+ group_id => group_id int (configuration_group_id)
+ @param $shortkey use cleankey for return short key
+ @return
+
+ object(stdClass)[13]
+ public 'id' => string '1' (length=1)
+
+ OR
+ array(
+ object(stdClass)[13]
+ ...
+ object(stdClass)[13]
+ ..
+ )
+
+ */
+ public static function fetch($option,$shortkey=false){
+ self::getInstance();
+ $DB=Database::getInstance();
+
+ $sql ="";
+ if(isset($option['id'])) $sql .="AND value_id = '".(int)$option['id']."' ";
+ if(isset($option['epf_id'])) $sql .="AND epf_id = '".(int)$option['epf_id']."' ";
+ if(isset($option['languages_id'])) $sql .="AND languages_id = '".(int)$option['languages_id']."' ";
+ if(isset($option['parent_id'])) $sql .="AND parent_id = '".(int)$option['parent_id']."' ";
+
+
+ if($sql=='')
+ return false;
+
+
+ $sql="SELECT * FROM " . TABLE_PRODUCTS_EXTRA_FIELDS_VALUES . " a ".
+ " WHERE ".substr($sql,3)." ORDER BY sort_order ASC";
+
+ $res=$DB->query($sql);
+
+ $num = $res->__get('numRows');
+
+ if($num == 1){
+ $result=$res->fetchAssoc();
+ return ((!$shortkey)? $result : self::CleanKey($result));
+ }
+ elseif($num > 1){
+ $array=array();
+
+ foreach($res->fetchAllAssoc() as $result)
+ $array[]= ((!$shortkey)? $result : self::CleanKey($result));
+
+ return $array;
+ }
+
+ return false;
+ }
+
+ /**
+ @brief delete row
+ */
+ public static function delete($option){
+ self::getInstance();
+ $DB=Database::getInstance();
+
+ $sql ="";
+
+ if(isset($option['id'])) $sql .="AND value_id = '".(int)$option['id']."' ";
+ if(isset($option['epf_id'])) $sql .="AND epf_id = '".(int)$option['epf_id']."' ";
+ if(isset($option['languages_id'])) $sql .="AND languages_id = '".(int)$option['languages_id']."' ";
+ if(isset($option['parent_id'])) $sql .="AND parent_id = '".(int)$option['parent_id']."' ";
+
+ if(strlen($sql) < 5)
+ return false;
+
+ $DB->query($s="DELETE FROM " . TABLE_PRODUCTS_EXTRA_FIELDS_VALUES ." WHERE ". substr($sql,3) );
+
+ return true;
+ }
+
+ /**
+ @brief
+ @return array product empty
+ */
+ public static function Specimen($shortkey=false){
+ $par = array(
+ 'value_id' => 0 ,
+ 'epf_id' => 0,
+ 'languages_id' => 0,
+ 'parent_id' => 0,
+ 'sort_order' => 0,
+ 'epf_value' => '',
+ );
+
+ return ((!$shortkey)? $par : self::CleanKey($par));
+ }
+
+
+
+ /**
+ @fn CleanKey()
+ @brief Clean string name key
+ */
+ private static function CleanKey($array){
+ self::getInstance();
+ $object= new stdclass();
+
+ foreach($array as $key=>$value){
+ $object->$key = $value;
+ }
+
+ return $object;
+ }
+
+}
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/gabarit/configuration/modcustextra/draw.edit.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/modcustextra/draw.edit.gab 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/gabarit/configuration/modcustextra/draw.edit.gab 2012-02-28 09:21:53 UTC (rev 4045)
@@ -7,7 +7,7 @@
@date 22/02/2012, 15:46
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
@encode UTF-8
- @brief form for add and manage extra field for customers
+ @brief form for add and manage extra field for customers
*/
global $languages;
?>
Modified: trunk/catalog/admin/includes/gabarit/configuration/modcustextra/draw.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/modcustextra/draw.listing.gab 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/gabarit/configuration/modcustextra/draw.listing.gab 2012-02-28 09:21:53 UTC (rev 4045)
@@ -46,8 +46,8 @@
<?php foreach(modcustextra::$list as $fields): ?>
<tr class="dataTableRow <?php if(isset( modcustextra::$fInfo) && is_object( modcustextra::$fInfo) && modcustextra::$fInfo->fields_id == modcustextra::$cID) echo "Selected" ?>" >
<td><?php echo $fields->fields_name; ?></td>
- <td><?php echo modcustextra::get_item_type($fields->fields_input_type, true); ?></td>
- <td><?php echo modcustextra::get_item_visibility($fields->fields_admin, true); ?></td>
+ <td><?php echo ExtraUtility::GetInputType($fields->fields_input_type, true); ?></td>
+ <td><?php echo ExtraUtility::GetInputVisibility($fields->fields_admin, true); ?></td>
<td><?php echo $fields->fields_group_class; ?></td>
<td class="tcenter">
<?php echo modcustextra::get_item_status($fields); ?>
Modified: trunk/catalog/admin/includes/gabarit/configuration/modprodextra/draw.label.listing.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/modprodextra/draw.label.listing.gab 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/gabarit/configuration/modprodextra/draw.label.listing.gab 2012-02-28 09:21:53 UTC (rev 4045)
@@ -26,19 +26,19 @@
<table class="dataTable">
<thead>
<tr>
- <th><?php echo __('TABLE_HEADING_ID'); ?></th>
- <th><?php echo __('TABLE_HEADING_LABEL'); ?></th>
- <th class="tright"><?php echo __('TABLE_HEADING_ORDER'); ?></th>
- <th class="tcenter"><?php echo __('TABLE_HEADING_STATUS'); ?></th>
- <th class="tcenter"><?php echo __('TABLE_HEADING_USE_ADMIN'); ?></th>
- <th class="tcenter"><?php echo __('TABLE_HEADING_SPE_MODULE'); ?></th>
- <th class="row_action"><?php echo __('table heading action'); ?></th>
+ <th><?php echo __('TABLE_HEADING_ID'); ?></th>
+ <th><?php echo __('TABLE_HEADING_LABEL'); ?></th>
+ <th class="tright"><?php echo __('TABLE_HEADING_ORDER'); ?></th>
+ <th class="tcenter"><?php echo __('TABLE_HEADING_STATUS'); ?></th>
+ <th class="tcenter"><?php echo __('table heading visibility'); ?></th>
+ <th class="tcenter"><?php echo __('table heading type'); ?></th>
+ <th class="tcenter"><?php echo __('TABLE_HEADING_SPE_MODULE'); ?></th>
+ <th class="row_action"><?php echo __('table heading action'); ?></th>
</tr>
</thead>
<tbody>
- <?php foreach(modprodextra::$list as $epf) {
- if ($epf->epf_id == modprodextra::$eid) $selected = $epf; ?>
- <tr class="dataTableRow <?php if ($epf->epf_id == modprodextra::$eid) echo "Selected" ; ?>">
+ <?php foreach(modprodextra::$list as $epf) {?>
+ <tr class="dataTableRow">
<td class="dataTableContent"><?php echo $epf->epf_id; ?></td>
<td class="dataTableContent">
<?php $label_query = tep_db_query("select languages_id, epf_label from " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " where (epf_id = " . (int)$epf->epf_id . ") ");
@@ -52,9 +52,13 @@
<?php echo modprodextra::get_item_status($epf); ?>
</td>
<td class="tcenter">
- <?php echo modprodextra::get_item_admin($epf); ?>
+ <?php echo ExtraUtility::GetInputVisibility($epf->epf_admin, true); ?>
</td>
<td class="tcenter">
+ <?php echo ExtraUtility::GetInputType ($epf->epf_input_type, true ); ?>
+ </td>
+
+ <td class="tcenter">
<?php echo $epf->epf_special_mod ?>
</td>
<td class="row_action">
Modified: trunk/catalog/admin/includes/gabarit/configuration/modprodextra/draw.label.new.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/configuration/modprodextra/draw.label.new.gab 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/gabarit/configuration/modprodextra/draw.label.new.gab 2012-02-28 09:21:53 UTC (rev 4045)
@@ -21,16 +21,27 @@
- <p class="block_input">
- <label><?php echo __('ENTRY_VALUE_LIST') ?></label>
- <?php echo tep_draw_radio_field('value_list','value_list', '1',(((int)modprodextra::$cInfo['epf_uses_value_list']==1)? true : false)) . ' ' .__('TEXT_YES'). ' ' . tep_draw_radio_field('value_list','value_list', '0',(((int)modprodextra::$cInfo['epf_uses_value_list']==0)? true : false)) . ' ' .__('TEXT_NO'); ?>
- </p>
+ <div class="block_input">
+ <label><?php echo __('entry type input') ?></label>
+ <?php //echo tep_draw_radio_field('value_list','value_list', '1',(((int)modprodextra::$cInfo->epf_uses_value_list==1)? true : false)) . ' ' .__('TEXT_YES'). ' ' . tep_draw_radio_field('value_list','value_list', '0',(((int)modprodextra::$cInfo->epf_uses_value_list==0)? true : false)) . ' ' .__('TEXT_NO'); ?>
+ <ul>
+ <li><?php echo tep_draw_radio_field('epf_input_type','epf_input_type', 0, (modprodextra::$cInfo->epf_input_type==0) ? true : false) . __('entry list type input') ?></li>
+ <li><?php echo tep_draw_radio_field('epf_input_type','epf_input_type', 1, (modprodextra::$cInfo->epf_input_type==1) ? true : false) . __('entry list type textarea') ?></li>
+ <li><?php echo tep_draw_radio_field('epf_input_type','epf_input_type', 2, (modprodextra::$cInfo->epf_input_type==2) ? true : false) . __('entry list type radio') ?></li>
+ <li><?php echo tep_draw_radio_field('epf_input_type','epf_input_type', 3, (modprodextra::$cInfo->epf_input_type==3) ? true : false) . __('entry list type checkbox') ?></li>
+ <li><?php echo tep_draw_radio_field('epf_input_type','epf_input_type', 7, (modprodextra::$cInfo->epf_input_type==7) ? true : false) . __('entry list type checkbox multi') ?></li>
+ <li><?php echo tep_draw_radio_field('epf_input_type','epf_input_type', 4, (modprodextra::$cInfo->epf_input_type==4) ? true : false) . __('entry list type select') ?></li>
+ <li><?php echo tep_draw_radio_field('epf_input_type','epf_input_type', 6, (modprodextra::$cInfo->epf_input_type==6) ? true : false) . __('entry list type select mutli') ?></li>
+ <li><?php echo tep_draw_radio_field('epf_input_type','epf_input_type', 5, (modprodextra::$cInfo->epf_input_type==5) ? true : false) . __('entry list type hidden') ?></li>
+ </ul>
+ </div>
+
<p class="block_input">
<label for="epf_active_for_language" title="<?php echo __('ENTRY_ACTIVE_HELP') ?>"><?php echo __('ENTRY_ACTIVE'). tep_image(DIR_WS_ICONS . 'icon_help.gif'); ?></label>
- <?php echo tep_draw_radio_field('epf_active_for_language' ,'epf_active_for_language' , '1', (((int)modprodextra::$cInfo['epf_active_for_language']==1)? true : false) ) . ' ' . __('TEXT_YES') .
- ' ' . tep_draw_radio_field('epf_active_for_language' ,'epf_active_for_language', '0', (((int)modprodextra::$cInfo['epf_active_for_language']==0)? true : false) ) . ' ' . __('TEXT_NO'); ?>
+ <?php echo tep_draw_radio_field('epf_active_for_language' ,'epf_active_for_language' , '1', (((int)modprodextra::$cInfo->epf_active_for_language==1)? true : false) ) . ' ' . __('TEXT_YES') .
+ ' ' . tep_draw_radio_field('epf_active_for_language' ,'epf_active_for_language', '0', (((int)modprodextra::$cInfo->epf_active_for_language==0)? true : false) ) . ' ' . __('TEXT_NO'); ?>
</p>
Added: trunk/catalog/admin/includes/gabarit/products/products_extra/display_edit.edit.gab
===================================================================
--- trunk/catalog/admin/includes/gabarit/products/products_extra/display_edit.edit.gab (rev 0)
+++ trunk/catalog/admin/includes/gabarit/products/products_extra/display_edit.edit.gab 2012-02-28 09:21:53 UTC (rev 4045)
@@ -0,0 +1,19 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 28/02/2012, 18:12
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+global $languages_id;
+?>
+
+<div class="block_input">
+ <fieldset class="block_field">
+ <legend><?php echo __('category extra fields') ?></legend>
+ <?php echo products_extra::get_extra_fields(products_extra::$pID,$languages_id) ?>
+ </fieldset>
+</div>
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modcustextra.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modcustextra.txt 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modcustextra.txt 2012-02-28 09:21:53 UTC (rev 4045)
@@ -72,6 +72,6 @@
$lang['entry list type checkbox']="Case à cocher" ;
$lang['entry list type checkbox multi']="Case à cocher (choix multiple)" ;
$lang['entry list type select']="Liste de selection" ;
- $lang['entry list type select mutli']="Liste de selection (choix multiple)" ;
+ $lang['entry list type select multi']="Liste de selection (choix multiple)" ;
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modprodextra.txt
===================================================================
--- trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modprodextra.txt 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/languages/fr_FR/modules/configuration/modprodextra.txt 2012-02-28 09:21:53 UTC (rev 4045)
@@ -20,18 +20,24 @@
$lang['TABLE_HEADING_VALUE']="Valeur" ;
$lang['TABLE_HEADING_PARENT']="Parent" ;
$lang['table heading action']="Action" ;
+ $lang['table heading visibility']="Visibilité" ;
+ $lang['table heading type']="Type" ;
/* labels Edit / new */
$lang['heading new']="Creer un nouveau champ" ;
$lang['heading edit']="Edite un champ existant" ;
+ $lang['tab advanced extra field']="Réglages avancés" ;
+ $lang['tab base extra field']="Caractéristiques" ;
+
$lang['entry label']="Label: " ;
$lang['entry label help']="Label: " ;
$lang['entry label format']="Format : " ;
$lang['entry label format help']="Le format vous permet de definir l'ordonancement du label et du champs lors de l'affichage de ce champs " ;
$lang['entry search']="Actif dans la recherche: " ;
$lang['entry search help']="Rend actif ce champ dans la recherche avancée " ;
+ $lang['entry type input']="Type de champ : " ;
$lang['ENTRY_ACTIVE']="Mode language : " ;
$lang['ENTRY_ACTIVE_HELP']="Ce champs contient une valeur internationalisable , une par langue. Aussi vous pourrez insérer une valeur personnalisée par langue" ;
@@ -43,8 +49,8 @@
$lang['ENTRY_USE_ADMIN']="Special pour admin uniquement: " ;
$lang['ENTRY_SPECIFIQUE_MODULE']="Propriétaire: " ;
$lang['ENTRY_SPECIFIQUE_MODULE_HELP']="Nom du module qui est propriétaire de ce champ. Valeur non listée " ;
- $lang['ENTRY_VALUE_LIST']="Uses A List Of Values: " ;
+
$lang['ENTRY_LISTING']="Voir dans les listings: " ;
$lang['ENTRY_SIZE']="Max caratères " ;
$lang['ENTRY_SIZE_HELP']="Le nombre maximun autorisé dans le champ (ignored if field uses value list): " ;
@@ -68,9 +74,8 @@
$lang['text delete value']="Vous êtes sûr de vouloir supprimer cette valeur de la liste des valeur de ce champ" ;
-$lang['text yes']="Actif" ;
-$lang['text no']="Inactif" ;
+
$lang['BUTTON_NEW']="Créer un nouveau champ" ;
$lang['BUTTON_EDIT_VALUES']="Éditer la liste des valeurs" ;
$lang['BUTTON_VALUE_ADD_LIST']="Ajouter une valeur à la liste " ;
@@ -102,4 +107,19 @@
$lang['WARNING_VALUE_USED']="Nombre de colonne : " ;
$lang['ERROR_VALUE']="Erreur value : " ;
+
+
+
+$lang['text yes']="Actif" ;
+$lang['text no']="Inactif" ;
+
+/* entry list */
+ $lang['entry list type input']="Champ classique" ;
+ $lang['entry list type textarea']="Champ texte" ;
+ $lang['entry list type radio']="Bouton radio" ;
+ $lang['entry list type hidden']="Champ caché" ;
+ $lang['entry list type checkbox']="Case à cocher" ;
+ $lang['entry list type checkbox multi']="Case à cocher (choix multiple)" ;
+ $lang['entry list type select']="Liste de selection" ;
+ $lang['entry list type select multi']="Liste de selection (choix multiple)" ;
?>
\ No newline at end of file
Modified: trunk/catalog/admin/includes/modules/account/account_extra.php
===================================================================
--- trunk/catalog/admin/includes/modules/account/account_extra.php 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/modules/account/account_extra.php 2012-02-28 09:21:53 UTC (rev 4045)
@@ -52,7 +52,7 @@
while($extra_fields = tep_db_fetch_array($extra_fields_query)){
/**
-TODO Prendre en charge le type de champs pour le control
+TODO Prendre en charge le type de champs pour le control
*/
if(strlen($_POST['fields_' . $extra_fields['fields_id']])<$extra_fields['fields_size'])
throw new Exception(sprintf('entry extra fields (%s) error length %s',$extra_fields['fields_name'],$extra_fields['fields_size']) );
@@ -100,9 +100,9 @@
case 1: // textarea
case 2: // radio
case 4: // select
- case 5: // hidden
- default:
- $val = ( (isset($_POST['fields_' . $extra_fields['fields_id']])) ? tep_db_prepare_input($_POST['fields_' . $extra_fields['fields_id']]) : '') ;
+ case 5: // hidden
+ default:
+ $val = ( (isset($_POST['fields_' . $extra_fields['fields_id']])) ? tep_db_prepare_input($_POST['fields_' . $extra_fields['fields_id']]) : '') ;
}
@@ -145,7 +145,7 @@
public static function get_extra_fields($customer_id,$languages_id){
- // ne liste que les champs qui n'appartiennent pas a un modules precis
+ // ne liste que les champs qui n'appartiennent pas a un modules precis
$extra_fields_query = tep_db_query("select ce.fields_id, ce.fields_input_type, ce.fields_input_value, ce.fields_required_status, cei.fields_name,cei.fields_format as format, ce.fields_status, ce.fields_input_type from " . TABLE_EXTRA_FIELDS . " ce, " . TABLE_EXTRA_FIELDS_LABELS . " cei where ce.fields_status=1 and cei.fields_id=ce.fields_id and cei.languages_id =" . $languages_id." and fields_special_mod='' order by ce.fields_group_class");
$extra_fields_string = '';
@@ -172,7 +172,7 @@
$robj->id = (int) $extra_fields['fields_id'];
$robj->name = (string) $extra_fields['fields_name'];
$robj->input_type = (int) $extra_fields['fields_input_type'];
- $robj->input_value = $value;
+ $robj->input_value = $value;
$robj->input_format = $extra_fields['format'];
$robj->required_status = $extra_fields['fields_required_status'];
Modified: trunk/catalog/admin/includes/modules/configuration/modcustextra.php
===================================================================
--- trunk/catalog/admin/includes/modules/configuration/modcustextra.php 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/modules/configuration/modcustextra.php 2012-02-28 09:21:53 UTC (rev 4045)
@@ -79,10 +79,10 @@
$fields_id = tep_db_prepare_input(self::$cID);
$sql_data_array['id']=$fields_id;
}
-
+
if (! sqlcustomersextrafileds::fetch($sql_data_array) )
$fields_id = sqlcustomersextrafileds::create($sql_data_array);
- else
+ else
sqlcustomersextrafileds::update( $sql_data_array );
foreach( tep_get_languages() as $rows){
@@ -105,7 +105,7 @@
break;
/**
- @remarks quick action
+ @remarks quick action
*/
case 'deleteconfirm':
$fields_id = tep_db_prepare_input(self::$cID);
@@ -120,7 +120,7 @@
break;
/**
- @remarks quick action
+ @remarks quick action
*/
case 'setflag':
if(isset($_GET['flag']) )
@@ -268,53 +268,9 @@
'</a>';
}
- /**
- @brief retrun array for pulldownmenu or array selected by arg id
- @param $id int (-1:all, 0...9: type)
- */
- public static function get_item_visibility($id=0, $name=false){
- $r = array(
- array('id'=>0,'text'=>__('visible BO and FO')) ,
- array('id'=>1,'text'=>__('uniquement admin')) ,
- array('id'=>2,'text'=>__('hidden')) ,
- array('id'=>3,'text'=>__('public'))
- );
- if((int)$id>=0){
- foreach($r as $row)
- if($row['id'] == $id){
- if($name) return $row['text'];
- else return $row;
- }
- }
- elseif((int)$id<0)
- return $r;
- }
- /**
- @brief retrun array for pulldownmenu or array selected by arg id
- @param $id int (-1:all, 0...9: type)
- */
- public static function get_item_type($id=0, $name=false){
- $r = array(
- array('id'=>0,'text'=>__('entry list type input') ) ,
- array('id'=>1,'text'=>__('entry list type textarea')) ,
- array('id'=>2,'text'=>__('entry list type radio')) ,
- array('id'=>3,'text'=>__('entry list type checkbox')) ,
- array('id'=>4,'text'=>__('entry list type select')) ,
- array('id'=>5,'text'=>__('entry list type hidden')) ,
- );
- if((int)$id >=0){
- foreach($r as $row)
- if($row['id'] == $id){
- if($name) return $row['text'];
- else return $row;
- }
- }
- elseif((int)$id<0)
- return $r;
- }
public static function get_customers_extra_fields_name($fields_id, $language_id) {
$fields_query = tep_db_query("select fields_name from " . TABLE_EXTRA_FIELDS_LABELS . " where fields_id = '" . (int)$fields_id . "' and languages_id = '" . (int)$language_id . "'");
Modified: trunk/catalog/admin/includes/modules/configuration/modprodextra.php
===================================================================
--- trunk/catalog/admin/includes/modules/configuration/modprodextra.php 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/admin/includes/modules/configuration/modprodextra.php 2012-02-28 09:21:53 UTC (rev 4045)
@@ -76,13 +76,16 @@
$messages = array();
$error = false;
switch ($action) {
+
+
case 'insert':
try{
- if (!isset($_POST['value_list']))
- throw new Exception(ERROR_ENTRY_REQUIRED . ENTRY_VALUE_LIST);
- $value_list = ($_POST['value_list'] == '0') ? 0 : 1;
+// if (!isset($_POST['epf_input_type']))
+// throw new Exception(__('error entry required') . __('input type required'));
+ $value_list =(int)$_POST['epf_input_type'];
+
$lactive = ($_POST['epf_active_for_language'] == '0') ? 0 : 1;
}
catch(Exception $e){
@@ -91,20 +94,23 @@
}
- self::$eid = sqlproductsextrafields::create(array('uses_value_list' => $value_list));
+ self::$eid = sqlproductsextrafields::create(array('input_type' => $value_list, 'status'=>0));
tep_redirect(tep_href_link(self::FILENAME,FILENAME_CFG_34.'&action=edit&eid=' . self::$eid));
break;
+
+
+
case 'update': // validate form
- $query = tep_db_query("select epf_size, epf_uses_value_list from " . TABLE_PRODUCTS_EXTRA_FIELDS . " where epf_id = " . (int)self::$eid);
- $field_info = tep_db_fetch_array($query); // retrieve original field information
+// $query = tep_db_query("select epf_size, epf_input_type from " . TABLE_PRODUCTS_EXTRA_FIELDS . " where epf_id = " . (int)self::$eid);
+// $field_info = tep_db_fetch_array($query); // retrieve original field information
+ $field_info = sqlproductsextrafields::fetch(array('id'=>(int)self::$eid));
try{
- if (!isset($_POST['status'])) throw new Exception(ERROR_ENTRY_REQUIRED . ENTRY_ACTIVATE_NOW);
- $status = ($_POST['status'] == '0') ? 0 : 1;
+
$order = (isset($_POST['sort_order'])) ? tep_db_prepare_input($_POST['sort_order']) : 0;
$epf_admin = (isset($_POST['epf_admin'])) ? tep_db_prepare_input($_POST['epf_admin']) : 0;
$epf_special_mod = (isset($_POST['epf_special_mod'])) ? tep_db_prepare_input($_POST['epf_special_mod']) : '';
@@ -121,7 +127,7 @@
if (!isset($_POST['size'])) throw new Exception(ERROR_ENTRY_REQUIRED . TEXT_SIZE);
$size = ($_POST['size'] == '0') ? 0 : (int)$_POST['size'];
- $uses_list = $field_info['epf_uses_value_list'];
+ $uses_list = $field_info['epf_input_type'];
if ($uses_list === 0) { // size required only if not using value list
if (!isset($_POST['size'])) throw new Exception(ERROR_ENTRY_REQUIRED . TEXT_SIZE);
$size = tep_db_prepare_input($_POST['size']);
@@ -139,18 +145,22 @@
}
// if (!isset($_POST['epf_active_for_language'])) throw new Exception(ERROR_ENTRY_REQUIRED . ENTRY_ACTIVE );
- $lactive = (!isset($_POST['epf_active_for_language'])) ? 0 : 1;
+ $lactive = (!isset($_POST['active_value_language'])) ? 0 : 1;
+ sqlproductsextrafields::Specimen();
+ $specimen = sqlproductsextrafieldslabels::Specimen();
+
+
$labels = array();
$active = false;
for ($i=0, $n=sizeof($languages); $i<$n; $i++) {
$labels[$languages[$i]['id']] = array(
- 'active' => $lactive,
- 'label' => ((isset($_POST['label_' . $languages[$i]['id']])) ? tep_db_prepare_input($_POST['label_' . $languages[$i]['id']]) : '' ),
- 'format'=>((isset($_POST['format_' . $languages[$i]['id']])) ? tep_db_prepare_input($_POST['format_' . $languages[$i]['id']]) : '' )
- );
+ 'label' => ((isset($_POST['label_' . $languages[$i]['id']])) ? tep_db_prepare_input($_POST['label_' . $languages[$i]['id']]) : $specimen['epf_label'] ),
+ 'format'=>((isset($_POST['format_' . $languages[$i]['id']])) ? tep_db_prepare_input($_POST['format_' . $languages[$i]['id']]) : $specimen['epf_format'] )
+ );
}
+
// if no active languages
$epf_key= (isset($_POST['epf_key'])) ? tep_db_prepare_input($_POST['epf_key']) : md5($_POST['label_'.$language_id]);
}
@@ -166,23 +176,22 @@
$label_query = tep_db_query("select * from " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " where epf_id=" . (int)self::$eid);
-
$data_array = array(
- 'id'=>(int)self::$eid,
- 'order' => (int)$order,
- 'status' => $status,
- 'advanced_search' => $search,
- 'show_in_listing' => $listing,
- 'size' => $size,
- 'use_as_meta_keyword' => $meta,
- 'use_to_restrict_listings' => $restrict,
- 'show_parent_chain' => $chain,
- 'key' => $epf_key,
- 'admin' => $epf_admin,
- 'special_mod' => $epf_special_mod
- );
+ 'id'=>(int)self::$eid,
+ 'order' => (int)$order,
+ 'advanced_search' => $search,
+ 'show_in_listing' => $listing,
+ 'size' => $size,
+ 'use_as_meta_keyword' => $meta,
+ 'use_to_restrict_listings' => $restrict,
+ 'show_parent_chain' => $chain,
+ 'new_key' => $epf_key,
+ 'admin' => (int)$epf_admin,
+ 'special_mod' => $epf_special_mod,
+ 'active_value_language'=>$lactive,
+ );
- sqlproductsextrafields::update($data_array);
+ sqlproductsextrafields::update($data_array);
$DB = Database::getInstance();
@@ -229,7 +238,7 @@
tep_db_query('delete from ' . TABLE_PRODUCTS_EXTRA_FIELDS_VALUES . ' where epf_id = ' . (int)self::$eid);
tep_db_query('delete from ' . TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS . ' where products_extra_fields_id = ' . (int)self::$eid);
- sqlproductsextrafields::delete(array('id'=> (int)self::$eid));
+ sqlproductsextrafields::delete(array('id'=> (int)self::$eid));
tep_redirect(tep_href_link(FILENAME_CONFIGURATION, tep_get_all_get_params(array('action','confirm','eid'),false)));
}
@@ -244,7 +253,7 @@
*/
case 'setflag':
if(isset($_GET['flag']) ){
- if (!is_numeric($_GET['flag']) || (($_GET['flag'] != 0) && ($_GET['flag'] != 1))) break; // skip if flag not properly set
+ if (($_GET['flag'] != 0) && ($_GET['flag'] != 1)) break; // skip if flag not properly set
if( sqlproductsextrafields::update(array('id'=> (int)self::$eid , 'status'=>(int)$_GET['flag'] )) )
$messageStack->add_session(
@@ -259,23 +268,7 @@
else
$messageStack->add_session(__('error for update extra fileds'), 'error');
}
- elseif(isset($_GET['flag_admin']) ){
- if (!is_numeric($_GET['flag_admin']) || (($_GET['flag_admin'] != 0) && ($_GET['flag_admin'] != 1))) break; // skip if flag not properly set
- if(sqlproductsextrafields::update(array('id'=> (int)self::$eid , 'admin'=>(int)$_GET['flag_admin'] )) )
- $messageStack->add_session(
- sprintf(
- __('success for update extra fileds; this fileds is %s'),
- ( ($_GET['flag_admin']==1)
- ? 'specific admin'
- : 'global front and backend'
- )
- )
- , 'success');
- else
- $messageStack->add_session(__('error for update extra fileds'), 'error');
- }
-
if(!isset($_GET['forceajax']))
tep_redirect(tep_href_link(FILENAME_CONFIGURATION, tep_get_all_get_params(array('action','flag_spe','flag_admin','flag'),false)));
break;
@@ -368,7 +361,7 @@
$current_label = $query['epf_label'];
if ($current_label == '') { // if invalid label get first matching label and use that information
- $query = tep_db_fetch_array(tep_db_query("select l.epf_label, l.epf_format, l.languages_id, l.epf_id from " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " l join " . TABLE_PRODUCTS_EXTRA_FIELDS . " e where e.epf_id = l.epf_id and l.epf_active_for_language and e.epf_uses_value_list order by e.epf_order"));
+ $query = tep_db_fetch_array(tep_db_query("select l.epf_label, l.epf_format, l.languages_id, l.epf_id from " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " l join " . TABLE_PRODUCTS_EXTRA_FIELDS . " e where e.epf_id = l.epf_id and l.epf_active_for_language and e.epf_input_type order by e.epf_order"));
$current_label = $query['epf_label'];
$eid = $query['epf_id'];
$lid = $query['languages_id'];
@@ -415,34 +408,40 @@
@remarks label edit
*/
case 'edit':
- $query = tep_db_query("select * from " . TABLE_PRODUCTS_EXTRA_FIELDS . " where epf_id = " . (int)self::$eid);
- $this->field = tep_db_fetch_array($query);
- $label_query = tep_db_query("select * from " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " where epf_id = " . (int)self::$eid);
- $this->field['epf_active_for_language']=0;
- $epf_label = array();
- while ($label = tep_db_fetch_array($label_query)) {
- $this->epf_label[$label['languages_id']] = $label;
- $this->field['epf_active_for_language'] =$label['epf_active_for_language'];
- }
+ $fields=sqlproductsextrafields::fetch(array('id'=>(int)self::$eid ));
- $languages = tep_get_languages();
- for ($i=0, $n=sizeof($languages); $i<$n; $i++){
- if(!isset($this->epf_label[$languages[$i]['id']])) {
- $this->epf_label[$languages[$i]['id']]['epf_label'] ='';
- $this->field['epf_active_for_language']=false;
- }
- }
+ $r = sqlproductsextrafieldslabels::fetch(array('id'=>(int)self::$eid));
+ if(!isset($r[0]))
+ $result[] = $r ;
+ else
+ $result = $r ;
+
+ foreach($result as $row)
+ $fields['lg'][$row['languages_id']] = new objectInfo($row);
+
+ return new objectInfo($fields);
break;
/**
@remarks label new
*/
case 'new':
+ $fields=sqlproductsextrafields::Specimen();
- $this->field=sqlproductsextrafields::Specimen();
+ foreach( tep_get_languages() as $rows){
+ $language_id = $rows['id'];
+ $fields['lg'][$language_id] = new objectInfo(sqlproductsextrafieldslabels::Specimen());
+ }
+
+
+ return new objectInfo($fields);
break;
+ /**
+ @remarks default listing all extra
+ */
+ case 'listing':
default:
$languages = tep_get_languages();
self::$lang = array();
@@ -472,7 +471,7 @@
*/
private static function load_for_delete(){
global $languages,$action;
- $query = tep_db_query("select epf_uses_value_list as uses_list from " . TABLE_PRODUCTS_EXTRA_FIELDS . " where epf_id = " . (int)self::$eid);
+ $query = tep_db_query("select epf_input_type as uses_list from " . TABLE_PRODUCTS_EXTRA_FIELDS . " where epf_id = " . (int)self::$eid);
$field_info = tep_db_fetch_array($query);
self::$pInfo=new objectInfo($field_info);
@@ -482,11 +481,11 @@
for ($i=0, $n=sizeof($languages); $i<$n; $i++) {
$label_query = tep_db_query("select * from " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " where epf_id = " . (int)self::$eid . " and languages_id = " . (int)$languages[$i]['id']. " and epf_active_for_language='1' ");
if(tep_db_num_rows($label_query) >0){
- $label = tep_db_fetch_array($label_query);
- $check_query = tep_db_query("select count(products_id) as total from " . TABLE_PRODUCTS_DESCRIPTION . " where language_id = " . (int)$languages[$i]['id'] . " and " . ($field_info['uses_list'] ? $field . " > 0" : "length(" . $field . ") > 0"));
- $check = tep_db_fetch_array($check_query);
- $used += $check['total']; // total how many descriptions use this field
- echo '<p>' . sprintf(TEXT_FIELD_DATA, $languages[$i]['name'], $label['epf_label'], $check['total']) . "</p>\n";
+ $label = tep_db_fetch_array($label_query);
+ $check_query = tep_db_query("select count(products_id) as total from " . TABLE_PRODUCTS_DESCRIPTION . " where language_id = " . (int)$languages[$i]['id'] . " and " . ($field_info['uses_list'] ? $field . " > 0" : "length(" . $field . ") > 0"));
+ $check = tep_db_fetch_array($check_query);
+ $used += $check['total']; // total how many descriptions use this field
+ echo '<p>' . sprintf(TEXT_FIELD_DATA, $languages[$i]['name'], $label['epf_label'], $check['total']) . "</p>\n";
}
}
self::$pInfo->used=$used;
@@ -518,8 +517,6 @@
case 'setflag':
if(isset($_GET['flag']) )
echo self::get_item_status(new objectInfo(array('epf_status'=>(int)$_GET['flag'], 'epf_id'=>(int)$_GET['eID'])) );
- elseif(isset($_GET['flag_admin']) )
- echo self::get_item_admin(new objectInfo(array('epf_admin'=>(int)$_GET['flag_admin'], 'epf_id'=>(int)$_GET['eID'])) );
break;
@@ -546,12 +543,9 @@
case 'new':
case 'edit':
-
global $list, $languages,$action;
- $this->load_db_values();
+ self::$cInfo = $this->load_db_values();
- self::$cInfo=$this->field;
- self::$pInfo = $this->epf_label;
$gab = 'label.'.$action;
break;
@@ -585,7 +579,7 @@
return sprintf(
CsrtAction::getFormat('row_action'),
'' ,
- (($item->epf_uses_value_list)? sprintf(CsrtAction::getLink('row_action_right', IMAGE_EDIT, 'edit'), '', tep_href_link(self::FILENAME,FILENAME_CFG_34.'&eid=' . $item->epf_id . '&action=' . 'value_listing' ) ,'' ) :'').
+ (($item->epf_input_type)? sprintf(CsrtAction::getLink('row_action_right', IMAGE_EDIT, 'edit'), '', tep_href_link(self::FILENAME,FILENAME_CFG_34.'&eid=' . $item->epf_id . '&action=' . 'value_listing' ) ,'' ) :'').
sprintf(CsrtAction::getLink('row_action_right', IMAGE_EDIT, 'edit'), '', tep_href_link(self::FILENAME,FILENAME_CFG_34.'&eid=' . $item->epf_id . '&action=edit') ,'' ).
sprintf(CsrtAction::getLink('row_action_right', IMAGE_DELETE, 'delete'), 'fancy', tep_href_link(self::FILENAME, FILENAME_CFG_34.'&eid=' . $item->epf_id . '&action=delete') ,'' )
);
@@ -612,8 +606,8 @@
@param $item arrau , detail ligne
*/
public static function get_item_status($item){
- $exclude=array('action','pID','forceajax','type','class','function','funct', 'mod','flag');
- $query_s='action=setflag&eID=' . $item->epf_id.'&flag=';
+ $exclude=array('action','eid','forceajax','type','class','function','funct', 'mod','flag');
+ $query_s='action=setflag&eid=' . $item->epf_id.'&flag=';
return '<a class="ajaxinline" href="' . tep_href_link(self::FILENAME, tep_get_all_get_params($exclude).$query_s.(($item->epf_status == '1')? '0' : '1') ) . '">'.
sprintf(
@@ -624,26 +618,9 @@
'</a>';
}
- /**
- @brief get_item_action($item)
- @brief content col action
- @param $item arrau , detail ligne
- */
- public static function get_item_admin($item){
- $exclude=array('action','pID','forceajax','type','class','function','funct', 'mod','flag_admin');
- $query_s='action=setflag&eID=' . $item->epf_id.'&flag_admin=';
- return '<a class="ajaxinline" href="' . tep_href_link(self::FILENAME, tep_get_all_get_params($exclude).$query_s.(($item->epf_admin == '1')? '0' : '1') ) . '">'.
- sprintf(
- CsrtAction::getFormat('row_flag'),
- (int)$item->epf_admin,
- ( ($item->epf_admin == '1')? IMAGE_ICON_STATUS_GREEN : IMAGE_ICON_STATUS_RED)
- ).
- '</a>';
- }
-
/** SPECIFIQUE */
/**
Added: trunk/catalog/admin/includes/modules/products/products_extra.php
===================================================================
--- trunk/catalog/admin/includes/modules/products/products_extra.php (rev 0)
+++ trunk/catalog/admin/includes/modules/products/products_extra.php 2012-02-28 09:21:53 UTC (rev 4045)
@@ -0,0 +1,292 @@
+<?php
+/**
+ @licence GPL 2005-2012 The osCSS developers - osCSS Open Source E-commerce
+ @portion code Copyright (c) 2002 osCommerce
+ @package osCSS-2 <www http://www.oscss.org>
+ @version 2.1.1
+ @date 22/02/2012, 09:10
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+ @class products_extra
+ @brief This module is use generic fields, not use for fields content one owner (for epf_special_mod is null )
+*/
+
+class products_extra
+ implements InterfaceModule{
+ /**
+ @var object
+ */
+ public static $cInfo;
+ /**
+ @var int
+ */
+ public static $pID;
+
+ /**
+ @brief constructor
+ */
+ function __construct(){
+ $this->code = __CLASS__;
+ $this->title = __('products extra');
+ $this->description = __('products extra info') ;
+ $this->sort_order = (defined('MODULE_ACA_PRO_EXTRA_SORT_ORDER')) ? MODULE_ACA_PRO_EXTRA_SORT_ORDER : 0;
+ $this->enabled = true;
+
+ self::$cInfo = new objectInfo(array());
+
+ // force load sqlproductsextrafields
+ sqlproductsextrafields::Specimen();
+ }
+
+
+
+ public function delete_account ($id){
+ tep_db_query("delete from " . TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS . " where products_id=" . (int)$id);
+ }
+
+ /**
+ @brief copie products
+ */
+ public function duplicate_product($pid_src, $pid_new){
+ $DB=Database::getInstance();
+
+ return true;
+ }
+
+
+ /**
+ @brief methode call by sqlcustomer, and process after update master table customers
+ */
+ public function after_update($products_id) {
+
+ //! This function returns an array with variables to update into TABLE_ADDRESS_BOOK
+ tep_db_query("delete from " . TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS . " where products_id=" . (int)$products_id);
+
+
+ $extra_fields_query = tep_db_query("select ce.epf_id as id, epf_input_type as type, epf_active_value_language as active_value_language from " . TABLE_PRODUCTS_EXTRA_FIELDS . " ce where ce.epf_status=1 AND epf_special_mod='' ");
+
+ while($extra_fields = tep_db_fetch_array($extra_fields_query)) {
+ $val = array();
+ $obj = new stdClass();
+
+ $obj->id = $extra_fields['id'];
+ $obj->type = $extra_fields['type'];
+ $obj->active_value_language = $extra_fields['active_value_language'];
+
+ $result = ExtraUtility::GetValueFormFields($obj);
+ if(!is_array($result))
+ $val[] = $result;
+ else
+ $val = $result;
+
+ foreach($val as $lid=>$text){
+ $sql_data_array = array(
+ 'products_id' => (int)$products_id,
+ 'products_extra_fields_id' => $extra_fields['id'],
+ 'products_extra_fields_value' => $text,
+ 'languages_id' => (($obj->active_value_language > 0) ? $lid : 0 ) ,
+ );
+
+ tep_db_perform(TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS, $sql_data_array);
+ }
+ }
+// exit;
+ return array();
+ }
+
+ /**
+ @brief action methode
+ */
+ public function check_action($actions){
+ global $languages_id;
+ $action=$actions['action'];
+ $messageStack=messageStack::getInstance();
+
+// switch($action){
+// case 'insert':
+// case 'update':
+// try{
+// // BOF Customers extra fields
+// $extra_fields_query = tep_db_query("select * from " . TABLE_PRODUCTS_EXTRA_FIELDS . " ce, " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " cei WHERE ce.epf_status=1 and ce.fields_required_status=1 and cei.epf_id=ce.epf_id and cei.languages_id ='". $languages_id ."' AND epf_special_mod='' ");
+// while($extra_fields = tep_db_fetch_array($extra_fields_query)){
+//
+// /**
+// TODO Prendre en charge le type de champs pour le control
+// */
+// if(strlen($_POST['fields_' . $extra_fields['epf_id']])<$extra_fields['fields_size'])
+// throw new Exception(sprintf('entry extra fields (%s) error length %s',$extra_fields['fields_name'],$extra_fields['fields_size']) );
+// }
+//
+// }catch(Exception $e){
+// $messageStack->add_session($e->getMessage(), 'error');
+// // self::$error=true;
+// }
+// break;
+// }
+
+ return $actions;
+ }
+
+
+
+ public function load_db_values($pID) {
+// self::$cInfo->objectInfo($customers);
+ }
+
+ public function load_post_values ($post) {
+ self::$cInfo->objectInfo($post);
+ }
+
+
+ public function display_edit(&$contents, $product_id) {
+ global $languages_id;
+
+ self::$pID =$product_id;
+ $contents[]= array('title'=> __('extra fields'),
+ 'text'=> tep_get_include_contents('products/'.__CLASS__.'/'.__FUNCTION__.'.edit') );
+
+ }
+
+
+
+
+ public static function get_extra_fields($products_id,$languages_id){
+
+ // ne liste que les champs qui n'appartiennent pas a un modules precis
+
+ $sql = "SELECT
+ ce.epf_id as id,
+ ce.epf_input_type as type,
+ cei.epf_label as title ,
+ cei.epf_format as format,
+ ce.epf_active_value_language as active_value_language,
+ ce.epf_status
+ FROM " . TABLE_PRODUCTS_EXTRA_FIELDS . " ce
+ LEFT JOIN " . TABLE_PRODUCTS_EXTRA_FIELDS_LABELS . " cei ON (cei.epf_id=ce.epf_id AND cei.languages_id =" . $languages_id.")
+ WHERE ce.epf_status=1 and epf_special_mod=''
+ ORDER BY ce.epf_order ";
+
+
+ $extra_fields_query = tep_db_query($sql);
+ $extra_fields_string = '';
+
+ if(tep_db_num_rows($extra_fields_query)>0){
+
+ while($extra_fields = tep_db_fetch_array($extra_fields_query)){
+
+ $value='';
+ $input ='';
+
+
+ if(isset($products_id)){
+
+ $sql = "SELECT products_extra_fields_value as value, languages_id ".
+ " FROM " . TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS .
+ " WHERE products_id='" . $products_id . "' AND products_extra_fields_id='" . $extra_fields['id']."' ";
+ if( (int) $extra_fields['active_value_language'] == 0)
+ $sql .=" AND languages_id ='0' ";
+
+
+ $value_query = tep_db_query($sql);
+ $value_info = $value_query->fetchAllAssoc();
+
+ foreach($value_info as $row) {
+ if((int)$row['languages_id'] ==0) $value = $row['value'];
+ else
+ $value[$row['languages_id']] = $row['value'];
+ }
+
+ }
+
+ $robj = new stdClass();
+ $robj->id = (int) $extra_fields['id'];
+ $robj->name = (string) $extra_fields['title'];
+ $robj->input_type = (int) $extra_fields['type'];
+ $robj->input_value = $value;
+ $robj->input_format = $extra_fields['format'];
+ $robj->required_status = 0 ;
+ $robj->active_value_language = $extra_fields['active_value_language'] ;
+
+ if( in_array( $extra_fields['type'], array(2, 3, 7, 4, 6 )) ) {
+ $robj->values_list = array();
+ $robj->select_values = array();
+
+ $list_value = sqlproductsextrafieldsvalues::fetch(array('epf_id'=>$extra_fields['id'], 'languages_id'=>$languages_id ) );
+
+
+ foreach($list_value as $item){
+
+ $robj->values_list[$item['value_id']] = $item['epf_value'];
+
+ $robj->select_values[] = array('id' => $item['value_id'], 'text' => $item['epf_value']);
+ }
+ }
+
+ if( (int) $extra_fields['active_value_language'] == 0) {
+
+ $label = ExtraUtility::FormatLabels($robj, false);
+ $input = ExtraUtility::FormatFields($robj, false);
+
+ $extra_fields_string .= str_replace( array('%label%', '%input%', '%unit%'), array($label, $input, '') , '<p class="block_input input-one">'.$extra_fields['format'].'</p>' ) ;
+
+ }
+ else {
+
+ $extra_fields_string .='<fieldset class="tabs_lang block_field"><ul>'."\n";
+ $languages = tep_get_languages();
+ for ($i=0, $n=sizeof($languages); $i<$n; $i++) {
+
+
+ $extra_fields_string .='<li><a href="#ExFieldsTabs-'. $robj->id . '-' . ($i+1).'" >' . tep_language_image ( $languages[$i]['directory'] . '/images/' . $languages[$i]['image'], $languages[$i]['name']) . ' ' . $languages[$i]['name'] . '</a></li>'."\n";
+ }
+
+ $extra_fields_string .='</ul>'."\n";
+
+ $extra_fields_string .='<ul>'."\n";
+
+ for ($i=0, $n=sizeof($languages); $i<$n; $i++) {
+ $robj->input_value = ((isset($value[$languages[$i]['id']])) ? $value[$languages[$i]['id']] : '' );
+ $robj->languages_id = $languages[$i]['id'];
+
+ $label = ExtraUtility::FormatLabels($robj, false);
+ $input = ExtraUtility::FormatFields($robj, false);
+
+ $extra_fields_string .='<li id="ExFieldsTabs-'. $robj->id . '-' . ($i+1).'" >'.str_replace( array('%label%', '%input%', '%unit%'), array($label, $input, '') , '<p class="block_input input-one">'.$extra_fields['format'].'</p>' ).'</li>'."\n";
+ }
+ $extra_fields_string .='</ul></fieldset>'."\n";
+ }
+
+ }
+
+ }
+
+ return $extra_fields_string;
+ }
+
+
+
+
+/** Functions for modules administration */
+ function check() {
+ if (!isset($this->_check)) {
+ $check_query = tep_db_query("select configuration_value from " . TABLE_CONFIGURATION . " where configuration_key = 'MODULE_ACA_ACCOUNT_EXTRA_INSTALLED'");
+ $this->_check = tep_db_num_rows($check_query);
+ }
+ return $this->_check;
+ }
+
+ function install() {
+ tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added,configuration_type) values ('".addslashes(__("Ordre de tri"))."', 'MODULE_ACA_PRO_EXTRA_SORT_ORDER', '0', '".addslashes(__("Ordre de tri, dans l'affichage"))."', '1', '0', now(),1)");
+ }
+
+ function remove() {
+ foreach($this->keys as $key)
+ tep_db_query(" delete from" . TABLE_CONFIGURATION . " WHERE configuration_key='".$key."' limit 1");
+ }
+
+ function keys() {
+ return array('MODULE_ACA_PRO_EXTRA_SORT_ORDER');
+ }
+}
+
+?>
\ No newline at end of file
Modified: trunk/catalog/common/classes/ExtraUtility.php
===================================================================
--- trunk/catalog/common/classes/ExtraUtility.php 2012-02-26 11:55:35 UTC (rev 4044)
+++ trunk/catalog/common/classes/ExtraUtility.php 2012-02-28 09:21:53 UTC (rev 4045)
@@ -17,17 +17,22 @@
*/
protected static $required = '<span class="inputRequirement"> * </span>';
-
+ /**
+ @fn CheckFormFields($rows, $value)
+ @brief test and check value for all input extra fileds in forms
+ @param $rows object detail current row
+ @return string value
+ */
public static function CheckFormFields($rows, $value){
- // if required , the value must be present
+ // if required , the val...
[truncated message content] |