From 828da0e797e318230b9f86322e8bf932c3c83a5f Mon Sep 17 00:00:00 2001 From: 王智 <wz@bronet.cn> Date: Mon, 7 Sep 2020 09:57:09 +0800 Subject: [PATCH] baoxiu --- application/api/controller/Index.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/application/api/controller/Index.php b/application/api/controller/Index.php index d3fe971..26f44e1 100644 --- a/application/api/controller/Index.php +++ b/application/api/controller/Index.php @@ -242,7 +242,7 @@ class Index extends Api if (empty($arr[3])) { $num = '001'; } else { - if (strstr($arr[3], '00')&&$arr[3]<100) { + if (strstr($arr[3], '00') && $arr[3] < 100) { $str = substr($arr[3], 2); if ($str == 9) { $num = '0' . '10'; @@ -250,7 +250,8 @@ class Index extends Api $str2 = $str + 1; $num = '00' . $str2; } - } elseif (strstr($arr[3], '0')) { + } + if (strstr($arr[3], '0')) { $str = substr($arr[3], 1); if ($str == 99) { $num = '100'; @@ -258,7 +259,8 @@ class Index extends Api $str2 = $str + 1; $num = '0' . $str2; } - } elseif (strlen($arr[3] > 2)) { + } + if (strlen($arr[3] > 2)) { $num = $arr[3] + 1; } } -- libgit2 0.24.0