guarantee-lsq 9 месяцев назад
Родитель
Сommit
9c1a2e79f0
1 измененных файлов с 3 добавлено и 1 удалено
  1. 3 1
      platform-dao/src/main/resources/mapper/store/SpareStoreMapper.xml

+ 3 - 1
platform-dao/src/main/resources/mapper/store/SpareStoreMapper.xml

@@ -139,7 +139,9 @@ sparestore.min_stock
         (
         SELECT
         sparestore.spare_id,
-        SUM( num ) AS totalStock
+        any_value(sparestore.min_stock) maxStock,
+        any_value(sparestore.max_stock) minStock,
+        SUM( any_value(num) ) AS totalStock
         FROM
         t_spare_store sparestore
         <where>