ALTER TABLE `z_user_info`
	CHANGE COLUMN `id` `id` INT(11) NOT NULL AUTO_INCREMENT FIRST,
	CHANGE COLUMN `user_id` `user_id` INT(11) NOT NULL DEFAULT '0' AFTER `id`,
	ADD INDEX `user_id` (`user_id`);
ALTER TABLE `z_user_keywords`
	ADD INDEX `user_id` (`user_id`);
ALTER TABLE `z_user_login_log`
	ADD INDEX `user_id` (`user_id`);
ALTER TABLE `z_user_sales_report`
	ADD INDEX `user_id` (`user_id`);
INSERT INTO `z_seo_tpl` (`id`, `base_name`, `create_time`, `var_descript`) VALUES (151, '搜索页的SEO模板', 1399631106, '商店名称: {shop_name}<br />\r\n当前域名: {domain}<br />\r\n分类名称: {category_name}<br />\r\n搜索名称: {search_name}<br />\r\n当前页码: {page}');

ALTER TABLE `z_offer`
	ADD COLUMN `coupon_type` TINYINT(1) UNSIGNED NOT NULL DEFAULT '0' COMMENT '优惠券类型#0默认#1通用类型' AFTER `user_group_id`;

ALTER TABLE `z_coupon`
	ADD INDEX `user_id` (`user_id`),
	ADD INDEX `offer_id` (`offer_id`);

CREATE TABLE `z_coupon_user` (
	`id` INT(11) NOT NULL AUTO_INCREMENT,
	`user_id` INT(11) NULL DEFAULT '0',
	`offer_id` INT(11) NULL DEFAULT '0',
	`using_time` INT(11) NOT NULL DEFAULT '0',
	`order_id` INT(11) NOT NULL DEFAULT '0',
	PRIMARY KEY (`id`),
	INDEX `user_id` (`user_id`),
	INDEX `offer_id` (`offer_id`)
)
COMMENT='通用优惠券用户关联'
ENGINE=MyISAM;

ALTER TABLE `z_offer`
	CHANGE COLUMN `prefix` `prefix` VARCHAR(100) NULL DEFAULT '' AFTER `offer_kind`;

ALTER TABLE `z_shipping` ADD `listorder` int(11) NOT NULL DEFAULT '0' COMMENT '排序';

INSERT INTO `z_mail_tpl` (`base_name`, `create_time`, `descript`, `var_descript`) VALUES ('回复留言发给会员', 1400496790, '管理员后台回复留言发邮件给会员', 'message');

INSERT INTO `z_task_stage` (`id`, `base_name`, `task_id`, `listorder`, `remark`, `create_time`, `update_time`) VALUES (14, '回复留言发给会员', 1, 0, '', 1400498142, 0);
INSERT INTO `z_event` (`id`, `base_name`, `codeno`, `event_type`, `is_order_cond`, `trigger_type`, `trigger_time`, `email_tpl_id`, `msg_tpl_id`, `sms_tpl_id`, `is_coupon`, `create_time`, `update_time`, `start_time`, `end_time`, `status`, `task_id`) VALUES (15, '回复留言发给会员', 'message_reply_tip', 1, 0, 1, 1400498249, 22, 22, 0, 0, 1400498249, 0, 0, 0, 1, 14);

INSERT INTO `z_admin_menu` (`base_name`, `parent_id`, `m`, `c`, `a`, `data`, `level`, `listorder`, `display`, `class`, `lang_key`, `has_sun`, `isopen`) VALUES ('自定义URL', 505, 'admin', 'urlAlisa', 'list', '', 3, 0, 1, 'allocation', 'urlAlisa', 0, 0);

ALTER TABLE `z_goods_category`
	ADD COLUMN `seo_tpl_id` INT(11) NOT NULL DEFAULT '0' COMMENT '分类SEO模板' AFTER `diy_param`,
	ADD COLUMN `seo_goods_tpl_id` INT(11) NOT NULL DEFAULT '0' COMMENT '分类产品SEO模板' AFTER `seo_tpl_id`;

alter table `z_order_remark` modify column remark_type int(4) COMMENT '订单状态';

ALTER TABLE `z_api_sns`  CHANGE COLUMN `api_param` `api_param` TEXT NULL DEFAULT NULL COMMENT '接口类型' AFTER `api_type`;

ALTER TABLE `z_credit_detail`
	ADD INDEX `user_id` (`user_id`);

ALTER TABLE `z_user_cart` ADD `language_id` int(11) NOT NULL DEFAULT '0' COMMENT '语言ID';
ALTER TABLE `z_user_favorite` ADD `language_id` int(11) NOT NULL DEFAULT '0' COMMENT '语言ID';
ALTER TABLE `z_user_keywords` ADD `language_id` int(11) NOT NULL DEFAULT '0' COMMENT '语言ID';

ALTER TABLE `z_language`
	ADD COLUMN `alias_domain` TEXT NULL DEFAULT NULL COMMENT '域名别名' AFTER `domain_name`;

ALTER TABLE `z_credit_setting`  ADD COLUMN `is_spec` TINYINT(1) UNSIGNED NOT NULL DEFAULT '1' COMMENT '是否可以叠加优惠#0不可叠加 #1可叠加' AFTER `create_time`;

#------------------------ 模板商城升级之后更新的sql

alter ignore table z_article_language add unique index zhcart_article_id_u (article_id,language_id);
alter ignore table z_article_category_language add unique index zhcart_article_category_id_u (article_category_id,language_id);
alter ignore table z_goods_tag_language add unique index zhcart_goods_tag_id_u (goods_tag_id,language_id);
alter ignore table z_brand_language add unique index zhcart_brand_id_u (brand_id,language_id);
alter ignore table z_insurance_language add unique index zhcart_insurance_id_u (insurance_id,language_id);
alter ignore table z_mail_tpl_language add unique index zhcart_mail_tpl_id_u (mail_tpl_id,language_id);
alter ignore table z_nav_page_language add unique index zhcart_nav_page_id_u (nav_page_id,language_id);
alter ignore table z_nav_language add unique index zhcart_nav_id_u (nav_id,language_id);
alter ignore table z_offer_language add unique index zhcart_offer_id_u (offer_id,language_id);
alter ignore table z_payment_language add unique index zhcart_payment_id_u (payment_id,language_id);
alter ignore table z_property_language add unique index zhcart_property_id_u (property_id,language_id);
alter ignore table z_seo_tpl_language add unique index zhcart_seo_tpl_id_u (seo_tpl_id,language_id);
alter ignore table z_shipping_language add unique index zhcart_shipping_id_u (shipping_id,language_id);
alter ignore table z_user_group_language add unique index zhcart_user_group_id_u (user_group_id,language_id);
alter ignore table z_goods_language add unique index zhcart_goods_id_u (goods_id,language_id);

ALTER TABLE `z_search_keywords` ADD FULLTEXT ( `base_name`);

alter ignore table z_topic_tag_language add unique index zhcart_topic_tag_id_u (topic_tag_id,language_id);
alter ignore table z_goods_category_language add unique index zhcart_goods_category_id_u (goods_category_id,language_id);
alter ignore table z_topic_language add unique index zhcart_topic_id_u (topic_id,language_id);

ALTER TABLE `z_goods_category`
	ADD COLUMN `status` TINYINT(1) NOT NULL DEFAULT '1' COMMENT '0#不显示1#显示' AFTER `seo_goods_tpl_id`;

alter table `z_goods` modify column discount decimal(4,2) NOT NULL DEFAULT 10 COMMENT '折扣';
alter table `z_special_offer` modify column discount decimal(4,2) NOT NULL DEFAULT 10 COMMENT '折扣';

ALTER TABLE `z_payment`
	CHANGE COLUMN `base_name` `base_name` VARCHAR(50) NULL DEFAULT NULL COMMENT '基准名字' AFTER `id`;

alter ignore table z_goods_self_rel add unique index zhcart_goods_id_u (goods_id,goods_rel_id);

ALTER TABLE `z_special_offer_shipping_rel` ADD `goods_id` int(11) NOT NULL DEFAULT '0' COMMENT '产品ID';

alter ignore table z_special_offer_shipping_rel add unique index zhcart_goods_id_u (goods_id,shipping_id);

ALTER TABLE `z_order` ADD `is_email_unpaid`  tinyint(2) UNSIGNED NOT NULL DEFAULT '0' COMMENT '催款邮件';
ALTER TABLE `z_order` ADD `is_email_paid`  tinyint(2) UNSIGNED NOT NULL DEFAULT '0' COMMENT '收款邮件';

ALTER TABLE `z_order` ADD `is_email_ship`  tinyint(2) UNSIGNED NOT NULL DEFAULT '0' COMMENT '物流单号邮件';

ALTER TABLE `z_growth_event` ADD `formula_value`  int(11) UNSIGNED NOT NULL DEFAULT '0' ;

ALTER TABLE `z_growth_event` ADD `growth_type`  tinyint(2) UNSIGNED NOT NULL DEFAULT '0' ;

ALTER TABLE `z_shipping`  CHANGE COLUMN `area_id` `area_id` INT(11) NOT NULL DEFAULT '0' COMMENT '区域ID 特殊#0全部区域 -1没有区域' AFTER `base_name`;

ALTER TABLE `z_brand`  CHANGE COLUMN `listorder` `listorder` INT(11) NOT NULL DEFAULT '0' COMMENT '排序' AFTER `image`;

ALTER TABLE `z_goods_language`
	CHANGE COLUMN `listorder` `listorder` INT(11) UNSIGNED NOT NULL DEFAULT '0' AFTER `up_time`;

ALTER TABLE `z_goods_tag`
	CHANGE COLUMN `listorder` `listorder` INT(11) NULL DEFAULT '0' COMMENT '排序' AFTER `tip_text`;

ALTER TABLE `z_theme`
	CHANGE COLUMN `sql_num` `sql_num` INT(11) UNSIGNED NOT NULL DEFAULT '0' COMMENT '执行sql文件数' AFTER `code`;

ALTER TABLE `z_topic`
	CHANGE COLUMN `listorder` `listorder` INT(11) UNSIGNED NOT NULL DEFAULT '0' COMMENT '排序' AFTER `status`;

ALTER TABLE `z_topic_language`
	CHANGE COLUMN `listorder` `listorder` INT(11) UNSIGNED NOT NULL DEFAULT '0' COMMENT '排序' AFTER `status`;

ALTER TABLE `z_topic_tag`
	CHANGE COLUMN `listorder` `listorder` INT(11) UNSIGNED NOT NULL DEFAULT '0' COMMENT '排序' AFTER `status`;

ALTER TABLE `z_topic_tag_language`
	CHANGE COLUMN `listorder` `listorder` INT(11) UNSIGNED NOT NULL DEFAULT '0' AFTER `status`;

ALTER TABLE `z_shipping_language`
	CHANGE COLUMN `shipping_id` `shipping_id` INT(11) NOT NULL DEFAULT '0' COMMENT '配送方式ID' AFTER `detail`,
	CHANGE COLUMN `language_id` `language_id` INT(11) NOT NULL DEFAULT '0' COMMENT '语言ID' AFTER `shipping_id`;

create index zhcart_search_num on z_search_keywords(search_num, listorder)
ALTER TABLE `z_search_keywords`  DROP INDEX `zhcart_search_num`;
ALTER TABLE `z_search_keywords`  ADD INDEX `listorder_search_num` (`listorder`, `search_num`);

ALTER TABLE `z_sku`  DROP INDEX `sku_code`;
ALTER TABLE `z_sku`  ADD INDEX `sku_code` (`sku_code`);

ALTER TABLE `z_goods_category`  DROP INDEX `path_id`;
ALTER TABLE `z_goods_category`  ADD UNIQUE INDEX `path_id` (`path_id`);

ALTER TABLE `z_goods`  ADD INDEX `special_offer_id` (`special_offer_id`);

insert into `z_growth_event` (base_name,type,growth,codeno,`status`) values('用户评论审核通过赠送50成长值',10,50,'goods_comment_sent_growth',1);
ALTER TABLE `z_special_offer` ADD `image` varchar(255);
ALTER TABLE `z_credit_cond` ADD `status`  tinyint(2) UNSIGNED NOT NULL DEFAULT '0';

DELETE FROM `z_event` WHERE (`id`=10) LIMIT 1

alter table `z_sku` modify column codeno varchar(50) COMMENT 'sku编号';
ALTER TABLE `z_sku`	ADD INDEX `codeno` (`codeno`);
ALTER TABLE `z_goods_category` ADD `nav_page_id`  int(11) NOT NULL DEFAULT '0';

CREATE TABLE `z_country_state` (
	`id` INT(10) NULL AUTO_INCREMENT,
	`base_name` VARCHAR(200) NULL DEFAULT '',
	`state_code_2` CHAR(2) NULL DEFAULT '',
	`state_code_3` CHAR(3) NULL DEFAULT '',
	`chinese_name` VARCHAR(200) NULL DEFAULT '',
	`listorder` INT(11) NULL DEFAULT '0',
	`status` TINYINT(1) NULL DEFAULT '1',
	`country_id` INT(11) NULL DEFAULT '0',
	PRIMARY KEY (`id`),
	INDEX `country_id` (`country_id`)
)
COMMENT='州/省'
COLLATE='utf8_general_ci'
ENGINE=MyISAM
ROW_FORMAT=DEFAULT

alter table `z_goods_tag` modify column `listorder`  int(11) UNSIGNED NOT NULL DEFAULT '0';
alter table `z_payment` modify column `listorder`  int(11) UNSIGNED NOT NULL DEFAULT '0';
ALTER TABLE `z_api_sns` ADD `listorder`  int(11) UNSIGNED NOT NULL DEFAULT '0';

INSERT INTO `z_event` VALUES ('16', '推荐会员首次付款成功', 'recommend_user_first_pay_after', '1', '0', '1', '1409046225', '23', '0', '0', '1', '1400498249', '0', '0', '0', '1', '14');

insert into `z_growth_event` (base_name,type,growth,codeno,`status`) values('推荐会员首次付款成功赠送200成长值',11,200,'recommend_user_first_pay_sent',1);
ALTER TABLE `z_user_address`  CHANGE COLUMN `last_name` `last_name` VARCHAR(128) NULL DEFAULT '' COMMENT '姓氏' AFTER `first_name`;

-- 频道开始
ALTER TABLE `z_goods_category`
	ADD COLUMN `is_channel` INT(11) NOT NULL DEFAULT '0' COMMENT '是否频道 , 0#不显示1#显示' AFTER `nav_page_id`,
	ADD COLUMN `is_channel_sys_tag` INT(11) NOT NULL DEFAULT '0' COMMENT '是否分类 , 0#不显示1#显示' AFTER `is_channel`,
	ADD COLUMN `channel_category_ids` varchar(128) NULL DEFAULT '' COMMENT '' AFTER `is_channel_sys_tag`;

CREATE TABLE IF NOT EXISTS `z_channel_tag` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `category_id` int(11) NOT NULL COMMENT '标签ID',
  `base_name` varchar(50) CHARACTER SET utf8 NOT NULL COMMENT '名称',
  `status` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '状态#1启用#0关闭',
  `listorder` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '排序',
  `create_time` int(11) unsigned NOT NULL DEFAULT '0',
  `update_time` int(11) unsigned NOT NULL DEFAULT '0',
  PRIMARY KEY (`id`)
) ENGINE=MyIsAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

CREATE TABLE IF NOT EXISTS `z_channel_tag_goods_rel` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `category_id` int(11) unsigned NOT NULL DEFAULT '0',
  `channel_tag_id` int(11) unsigned NOT NULL,
  `goods_id` int(11) unsigned NOT NULL,
  `listorder` int(11) unsigned NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=MyIsAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;


CREATE TABLE IF NOT EXISTS `z_channel_tag_language` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `language_id` int(11) unsigned NOT NULL COMMENT '站点ID',
  `channel_tag_id` int(11) NOT NULL COMMENT '频道ID',
  `base_name` varchar(50) CHARACTER SET utf8 NOT NULL COMMENT '名称',
  `status` tinyint(1) unsigned zerofill NOT NULL COMMENT '状态',
  PRIMARY KEY (`id`)
) ENGINE=MyIsAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

-- 频道结束



--组合销售开始

# --------------------------------------------------------
# Host:                         127.0.0.1
# Database:                     test
# Server version:               5.0.45-community-nt
# Server OS:                    Win32
# HeidiSQL version:             5.0.0.3272
# Date/time:                    2014-09-04 08:48:04
# --------------------------------------------------------

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET NAMES utf8 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;

# Dumping structure for table test.z_goods_package_sale
CREATE TABLE IF NOT EXISTS `z_goods_package_sale` (
  `id` int(11) NOT NULL auto_increment COMMENT '组合ID',
  `base_name` varchar(255) default '' COMMENT '名称',
  `goods_id` int(11) NOT NULL default '0' COMMENT '商品ID',
  `create_time` int(11) NOT NULL default '0' COMMENT '创建时间',
  `start_time` int(11) NOT NULL default '0' COMMENT '开始时间',
  `end_time` int(11) NOT NULL default '0' COMMENT '结束时间',
  `listorder` int(11) NOT NULL default '0' COMMENT '排序（数字越小排越前面）',
  `status` tinyint(1) NOT NULL default '0' COMMENT '状态#0关闭1激活',
  PRIMARY KEY  (`id`),
  KEY `goods_id` (`goods_id`),
  KEY `status` (`status`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='组合销售';

# Dumping data for table test.z_goods_package_sale: 0 rows
/*!40000 ALTER TABLE `z_goods_package_sale` DISABLE KEYS */;
/*!40000 ALTER TABLE `z_goods_package_sale` ENABLE KEYS */;


# Dumping structure for table test.z_goods_package_sale_goods_rel
CREATE TABLE IF NOT EXISTS `z_goods_package_sale_goods_rel` (
  `id` int(11) NOT NULL auto_increment COMMENT 'ID',
  `package_sale_id` int(11) NOT NULL default '0' COMMENT '组合销售ID',
  `goods_id` int(11) NOT NULL default '0' COMMENT '商品ID',
  `discount` decimal(10,4) NOT NULL default '10.0000' COMMENT '折扣',
  PRIMARY KEY  (`id`),
  KEY `package_sale_id` (`package_sale_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='组合销售商品关联表';

# Dumping data for table test.z_goods_package_sale_goods_rel: 0 rows
/*!40000 ALTER TABLE `z_goods_package_sale_goods_rel` DISABLE KEYS */;
/*!40000 ALTER TABLE `z_goods_package_sale_goods_rel` ENABLE KEYS */;


# Dumping structure for table test.z_goods_package_sale_language
CREATE TABLE IF NOT EXISTS `z_goods_package_sale_language` (
  `id` int(11) NOT NULL auto_increment COMMENT 'ID',
  `package_sale_id` int(11) NOT NULL default '0' COMMENT '组合销售ID',
  `language_id` int(11) NOT NULL default '0' COMMENT '语言ID',
  `base_name` varchar(255) NOT NULL COMMENT '组合销售名称',
  PRIMARY KEY  (`id`),
  KEY `salemode_id` (`package_sale_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='组合销售多语言表';

# Dumping data for table test.z_goods_package_sale_language: 0 rows
/*!40000 ALTER TABLE `z_goods_package_sale_language` DISABLE KEYS */;
/*!40000 ALTER TABLE `z_goods_package_sale_language` ENABLE KEYS */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;

----组合销售结束

ALTER TABLE `z_goods_category_language`
	ADD COLUMN `channel_detail` TEXT NULL AFTER `detail`;
ALTER TABLE `z_channel_tag_language`  ADD COLUMN `listorder` INT(11) UNSIGNED NULL DEFAULT '0' AFTER `status`;

ALTER TABLE `z_user` ADD INDEX `create_time` (`create_time`);
ALTER TABLE `z_newsletter` ADD INDEX `create_time` (`create_time`);
ALTER TABLE `z_user_favorite` ADD INDEX `create_time` (`create_time`);

# 菜单配置错误或者大小写错误，导致角色访问权限问题，修改后重新提交角色权限。
UPDATE `z_admin_menu` SET m = 'admin' WHERE id=655;
UPDATE `z_admin_menu` SET a = 'itemlist' WHERE id=657;
UPDATE `z_admin_menu` SET a = 'itemadd' WHERE id=658;
UPDATE `z_admin_menu` SET a = 'itemedit' WHERE id=659;
UPDATE `z_admin_menu` SET a = 'itemdel' WHERE id=660;

ALTER TABLE `z_shipping_corp`  ADD COLUMN `codeno` CHAR(20) NULL DEFAULT NULL COMMENT 'ERP唯一物流编号' AFTER `interface_code`;
ALTER TABLE `z_user_address`  ADD COLUMN `address_type` TINYINT(1) NULL DEFAULT '0' COMMENT '#0配送地址 #1账单地址' AFTER `create_time`;
ALTER TABLE `z_order`  ADD COLUMN `billing_address_id` int(11) UNSIGNED NOT NULL DEFAULT '0' COMMENT '账单地址' AFTER `is_email_ship`;
ALTER TABLE `z_payment`  ADD COLUMN `is_billing` TINYINT(1) NOT NULL DEFAULT '0' COMMENT '是否使用账单地址' AFTER `create_time`;

ALTER TABLE z_event_coupon DEFAULT CHARACTER SET utf8; 
alter table z_channel_tag engine = MyISAM DEFAULT CHARACTER SET utf8 COMMENT='频道标签';
alter table z_channel_tag_goods_rel engine = MyISAM DEFAULT CHARACTER SET utf8 COMMENT='频道关联商品表';
alter table z_channel_tag_language engine = MyISAM DEFAULT CHARACTER SET utf8 COMMENT='频道标签多语言表';

#后台用到的
ALTER TABLE `z_channel_tag` ADD INDEX `category_id` (`category_id`);
ALTER TABLE `z_channel_tag_goods_rel` ADD INDEX `channel_tag_id` (`channel_tag_id`);
ALTER TABLE `z_channel_tag_goods_rel` ADD INDEX `zhcart_category_id` (`category_id`,`channel_tag_id`);
ALTER TABLE `z_channel_tag_language` ADD INDEX `channel_tag_id` (`channel_tag_id`);
#前台用到的
ALTER TABLE `z_channel_tag_goods_rel` ADD INDEX `category_id` (`category_id`);
ALTER TABLE `z_channel_tag_language` ADD INDEX `zhcart_language_id` (`language_id`,`status`);

ALTER TABLE `z_special_offer_shipping_rel`  ADD UNIQUE INDEX `shipping_id_goods_id` (`shipping_id`, `goods_id`);

INSERT INTO `z_event` VALUES ('17', '管理员收到付款', 'admin_receive_payment', '1', '0', '1', '1411885816', '33', '0', '0', '0', '1400498249', '0', '0', '0', '1', '14');

ALTER TABLE `z_order_delivery`  ADD COLUMN `sign_time` INT NOT NULL DEFAULT '0' COMMENT '签收时间' AFTER `email`;
ALTER TABLE `z_goods_language`  CHANGE COLUMN `listorder` `listorder` INT(11) NOT NULL DEFAULT '0' AFTER `up_time`;

INSERT INTO `z_task_stage` VALUES ('16', '管理员收到付款', '1', '20', '', '1416794867', '0');
INSERT INTO `z_task_stage` VALUES ('17', '找回密码(发送密码)', '1', '21', '', '1416797573', '0');

INSERT INTO `z_event` VALUES ('18', '找回密码(发送密码)', 'send_password', '1', '0', '1', '1411885816', '34', '0', '0', '0', '1400498249', '0', '0', '0', '1', '17');

alter table `z_order` modify column payment_fee decimal(10,4) DEFAULT 0.0000 COMMENT '第三方收付费';
alter table `z_order` modify column cost_shipping decimal(10,4) DEFAULT 0.0000 COMMENT '运费金额';
alter table `z_order` modify column cost_payment decimal(10,4) DEFAULT 0.0000 COMMENT '小计金额（商品-优惠）';
alter table `z_order` modify column cost_offer decimal(10,4) DEFAULT 0.0000 COMMENT '优惠金额';

ALTER TABLE `z_user_api`  CHANGE COLUMN `api_key` `api_key` VARCHAR(200) NOT NULL COMMENT '第三方唯一ID' AFTER `api_id`;