Browse Source

最大值

shish 2 years ago
parent
commit
6d5576c94c
1 changed files with 1 additions and 8 deletions
  1. 1 8
      biz-ghs/custom/classes/CustomClass.php

+ 1 - 8
biz-ghs/custom/classes/CustomClass.php

@@ -61,14 +61,7 @@ class CustomClass extends BaseClass
     public static function createSeatSn($mainId)
     {
         $max = Custom::find(['mainId' => $mainId])->max('seatSn');
-        echo $max;die;
-        $info = self::getByCondition(['mainId' => $mainId], true, 'seatSn DESC');
-        $new = 1;
-        if (!empty($info)) {
-            $old = $info->seatSn;
-            $new = bcadd($old, 1);
-            echo $info->id.' '.$old.' '.$new;die;
-        }
+        $new = bcadd($max, 1);
         return $new;
     }