[ Index ]
 

Code source de Zen Cart E-Commerce Shopping Cart 1.3.7.1

Accédez au Source d'autres logiciels libres

Classes | Fonctions | Variables | Constantes | Tables

title

Body

[fermer]

/zc_install/sql/ -> mysql_upgrade_zencart_136_to_137.sql (source)

   1  #

   2  # * This SQL script upgrades the core Zen Cart database structure from v1.3.6 to v1.3.7

   3  # *

   4  # * @package Installer

   5  # * @access private

   6  # * @copyright Copyright 2003-2006 Zen Cart Development Team

   7  # * @copyright Portions Copyright 2003 osCommerce

   8  # * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0

   9  # * @version $Id: mysql_upgrade_zencart_136_to_137.sql 5480 2006-12-30 19:36:16Z drbyte $

  10  #

  11  
  12  ############ IMPORTANT INSTRUCTIONS ###############

  13  #

  14  # * Zen Cart uses the zc_install/index.php program to do database upgrades

  15  # * This SQL script is intended to be used by running zc_install 

  16  # * It is *not* recommended to simply run these statements manually via any other means

  17  # * ie: not via phpMyAdmin or via the Install SQL Patch tool in Zen Cart admin

  18  # * The zc_install program catches possible problems and also handles table-prefixes automatically

  19  # * 

  20  # * To use the zc_install program to do your database upgrade:

  21  # * a. Upload the NEWEST zc_install folder to your server

  22  # * b. Surf to zc_install/index.php via your browser

  23  # * c. On the System Inspection page, scroll to the bottom and click on Database Upgrade

  24  # *    NOTE: do NOT click on the "Install" button, because that will erase your database.

  25  # * d. On the Database Upgrade screen, you'll be presented with a list of checkboxes for

  26  # *    various Zen Cart versions, with the recommended upgrades already pre-selected.

  27  # * e. Verify the checkboxes, then scroll down and enter your Zen Cart Admin username

  28  # *    and password, and then click on the Upgrade button.

  29  # * f. If any errors occur, you will be notified.  Some warnings can be ignored.

  30  # * g. When done, you'll be taken to the Finished page.

  31  #

  32  #####################################################

  33  
  34  
  35  ## CONFIGURATION TABLE

  36  UPDATE configuration set configuration_description = 'Enable the Breadcrumb Trail Links?<br />0= OFF<br />1= ON<br />2= Off for Home Page Only', set_function = 'zen_cfg_select_option(array(\'0\', \'1\', \'2\'), ' WHERE configuration_key = 'DEFINE_BREADCRUMB_STATUS';
  37  INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ('Use split-login page', 'USE_SPLIT_LOGIN_MODE', 'False', 'The login page can be displayed in two modes: Split or Vertical.<br />In Split mode, the create-account options are accessed by clicking a button to get to the create-account page.  In Vertical mode, the create-account input fields are all displayed inline, below the login field, making one less click for the customer to create their account.<br />Default: False', '19', '121', 'zen_cfg_select_option(array(\'True\', \'False\'), ', now());
  38  
  39  ## PP EC

  40  ALTER TABLE customers ADD customers_paypal_payerid VARCHAR(20) NOT NULL default '' AFTER customers_referral;
  41  ALTER TABLE customers ADD customers_paypal_ec TINYINT(1) UNSIGNED DEFAULT 0 NOT NULL AFTER customers_paypal_payerid;
  42  ALTER TABLE paypal CHANGE txn_type txn_type varchar(32) NOT NULL default '';
  43  INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ('Credit Card Enable Status - SOLO', 'CC_ENABLED_SOLO', '0', 'Accept SOLO Card 0= off 1= on', '17', '8', 'zen_cfg_select_option(array(\'0\', \'1\'), ', now());
  44  INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ('Credit Card Enable Status - Switch', 'CC_ENABLED_SWITCH', '0', 'Accept SWITCH Card 0= off 1= on', '17', '9', 'zen_cfg_select_option(array(\'0\', \'1\'), ', now());
  45  INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ('Credit Card Enable Status - Maestro', 'CC_ENABLED_MAESTRO', '0', 'Accept MAESTRO Card 0= off 1= on', '17', '10', 'zen_cfg_select_option(array(\'0\', \'1\'), ', now());
  46  
  47  #this one was missed in the 1.3.6 fresh-installs (was okay for upgrades):

  48  # it will likely trigger a warning because upgrades to 1.3.6 will already have this.

  49  INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function) values ('Define Page-Not-Found Status', 'DEFINE_PAGE_NOT_FOUND_STATUS', '1', 'Enable the Defined Page-Not-Found Text from define-pages?<br />0= Define Text OFF<br />1= Define Text ON', '25', '67', now(), now(), NULL, 'zen_cfg_select_option(array(\'0\', \'1\'),');
  50  
  51  
  52  #############

  53  
  54  #### VERSION UPDATE COMMANDS

  55  ## THE FOLLOWING 2 SECTIONS SHOULD BE THE "LAST" ITEMS IN THE FILE, so that if the upgrade fails prematurely, the version info is not updated.

  56  ##The following updates the version HISTORY to store the prior version's info (Essentially "moves" the prior version info from the "project_version" to "project_version_history" table

  57  #NEXT_X_ROWS_AS_ONE_COMMAND:3

  58  INSERT INTO project_version_history (project_version_key, project_version_major, project_version_minor, project_version_patch, project_version_date_applied, project_version_comment)
  59  SELECT project_version_key, project_version_major, project_version_minor, project_version_patch1 as project_version_patch, project_version_date_applied, project_version_comment
  60  FROM project_version;
  61  
  62  ## Now set to new version

  63  UPDATE project_version SET project_version_major='1', project_version_minor='3.7', project_version_patch1='', project_version_patch1_source='', project_version_patch2='', project_version_patch2_source='', project_version_comment='Version Update 1.3.6->1.3.7', project_version_date_applied=now() WHERE project_version_key = 'Zen-Cart Main';
  64  UPDATE project_version SET project_version_major='1', project_version_minor='3.7', project_version_patch1='', project_version_patch1_source='', project_version_patch2='', project_version_patch2_source='', project_version_comment='Version Update 1.3.6->1.3.7', project_version_date_applied=now() WHERE project_version_key = 'Zen-Cart Database';
  65  
  66  
  67  #####  END OF UPGRADE SCRIPT



Généré le : Mon Nov 26 16:45:43 2007 par Balluche grâce à PHPXref 0.7
  Clicky Web Analytics