diff --git a/Application/Base/Service/PromoteCoinRecordService.class.php b/Application/Base/Service/PromoteCoinRecordService.class.php index 1f0ec9c6c..764a1abea 100644 --- a/Application/Base/Service/PromoteCoinRecordService.class.php +++ b/Application/Base/Service/PromoteCoinRecordService.class.php @@ -19,7 +19,7 @@ class PromoteCoinRecordService { } public function createRecord($params) { - $sn = date('YmdHis').strtoupper(md5(json_encode($params) . 'PromoteCoinRecord' . rand(0, 99999))); + $sn = date('YmdHis').strtoupper(substr(md5(json_encode($params) . 'PromoteCoinRecord' . rand(0, 99999)), 8, 16)); $data = [ 'sn' => $sn, 'type' => $params['type'], diff --git a/Application/Base/Service/PromoteCoinService.class.php b/Application/Base/Service/PromoteCoinService.class.php index 76f3f247a..c44182018 100644 --- a/Application/Base/Service/PromoteCoinService.class.php +++ b/Application/Base/Service/PromoteCoinService.class.php @@ -34,7 +34,7 @@ class PromoteCoinService { if (isset($params['sn'])) { $sn = $params['sn']; } else { - $sn = date('YmdHis').strtoupper(md5(json_encode($params) . 'PromoteCoin' . rand(0, 99999))); + $sn = date('YmdHis').strtoupper(substr(md5(json_encode($params) . 'PromoteCoin' . rand(0, 99999)), 8, 16)); } $data = []; $data['sn'] = $sn;