From 010bd56a610755229ec8e3d6326688133f5bd737 Mon Sep 17 00:00:00 2001 From: eason Date: Thu, 9 Aug 2018 14:10:11 +0800 Subject: [PATCH] fix --- src/db/modify.sql | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/src/db/modify.sql b/src/db/modify.sql index 0e4cc4745..50f6f75c6 100644 --- a/src/db/modify.sql +++ b/src/db/modify.sql @@ -684,4 +684,30 @@ INSERT INTO `sys_configs` VALUES ('payment.ali.per_order_limit', 10000,null); update sys_clients set contact_phone = concat('+61',contact_phone) where create_time >'2018-06-01' and source = 4 +ALTER TABLE `log_clearing_detail` +ADD COLUMN `total_cashback` decimal(16,3) NOT NULL DEFAULT 0 COMMENT '返现总额(2018-04-21开始计算)' AFTER `tax_amount`, +DEFAULT CHARACTER SET DEFAULT; + +ALTER TABLE `log_clearing` +ADD COLUMN `total_charge` decimal(16,3) NOT NULL DEFAULT 0 COMMENT '总手续费' AFTER `royalpay_charge`, +ADD COLUMN `charge_cashback` decimal(16,3) NOT NULL DEFAULT 0 COMMENT '返现' AFTER `total_charge`; + + +ALTER TABLE `pmt_custom_reports` +ADD COLUMN `report_serial` varchar(50) NOT NULL FIRST , +ADD COLUMN `serial_no` int NULL DEFAULT 0 AFTER `report_id`, +ADD COLUMN `custom_target` varchar(30) NOT NULL AFTER `custom`, +DROP PRIMARY KEY, +DROP INDEX `client_id` , +ADD INDEX `client_id` (`client_id`) USING HASH , +DROP INDEX `order_id` , +ADD INDEX `order_id` (`order_id`) USING HASH , +DROP INDEX `channel` , +ADD INDEX `channel` (`channel`) USING HASH , +ADD INDEX `report_id` (`report_id`) USING HASH ; + + +update pmt_custom_reports set report_serial=uuid(); + +alter pmt_custom_reports add PRIMARY key (report_serial); alter table sys_org add COLUMN `state` varchar(20) DEFAULT NULL COMMENT '州 (使用标准码 NSW,QLD,WA,VIC,ACT,NT,TAS,SA)'; \ No newline at end of file