From 3fd85aa09d8c6ba036ab0b9398655d5b5aa8a307 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Mon, 2 Sep 2019 18:54:59 +0800 Subject: [PATCH] 1 --- webapp/controller/ActivityController.class.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/webapp/controller/ActivityController.class.php b/webapp/controller/ActivityController.class.php index bfbdbc8..8597a04 100644 --- a/webapp/controller/ActivityController.class.php +++ b/webapp/controller/ActivityController.class.php @@ -769,8 +769,9 @@ class ActivityController{ //redpack201908191405_xxxxx protected function getOrderId($accountid) { + $mysql_conf = getMysqlConfig(crc32($accountid)); $conn = $this->getMysql($accountid); - $orderid_pre = 'redpack' . strftime('%y%m%d%H%M%S'); + $orderid_pre = 'rp' . strftime('%y%m%d%H%M%S'); $ret = $conn->execScript("INSERT INTO orderidx(createtime) VALUES(:createtime);", array( 'createtime' => time() @@ -782,7 +783,7 @@ class ActivityController{ if (empty($row)) { die(); } - $orderid = $orderid_pre . 'idx' . $row[0]; + $orderid = $orderid_pre . 'db' . $mysql_conf['instance_id'] . 'idx' . $row[0]; return $orderid; }