Преглед изворни кода

库存管理--库存对比优化,修改有错误不导入,导入modal框加刷新按钮

haozi пре 5 година
родитељ
комит
fffdfa4122
2 измењених фајлова са 29 додато и 29 уклоњено
  1. 25 25
      app/Services/InventoryCompareService.php
  2. 4 4
      public/js/app.js

+ 25 - 25
app/Services/InventoryCompareService.php

@@ -145,6 +145,31 @@ class InventoryCompareService
         if (!$inventoryCompares)return null;
         return $inventoryCompares;
     }
+    private function conditionQueryInventoryCompare(array $param){
+        $differ=$param['differ']??'';
+        if ($differ=='有'){
+            $inventoryCompares = InventoryCompare::query()->with(['owner','commodity'=>function($query){
+                $query->with('barcodes');
+            }])->where('differ','>',0)->orderByDesc('id');
+        }elseif ($differ=='无'){
+            $inventoryCompares = InventoryCompare::query()->with(['owner','commodity'=>function($query){
+                $query->with('barcodes');
+            }])->where('differ','<',0)->orderByDesc('id');
+        }else{
+            $inventoryCompares = InventoryCompare::query()->with(['owner','commodity'=>function($query){
+                $query->with('barcodes');
+            }])->orderByDesc('id');
+        }
+        unset($param['differ']);
+        $columnQueryRules=[
+            'owner_id' => ['multi' => ','],
+            'date_start' => ['alias' => 'created_at' , 'startDate' => ' 00:00:00'],
+            'date_end' => ['alias' => 'created_at' , 'endDate' => ' 23:59:59'],
+            'mission_code' => ['timeLimit' => 20],
+        ];
+        $inventoryCompares = app(QueryService::class)->query($param,$inventoryCompares,$columnQueryRules);
+        return $inventoryCompares;
+    }
 
 
 
@@ -209,29 +234,4 @@ class InventoryCompareService
 //        return $inventoryCompare;
 //    }
 //
-//    private function conditionQueryInventoryCompare(array $param){
-//        $differ=$param['differ']??'';
-//        if ($differ=='有'){
-//            $inventoryCompares = InventoryCompare::query()->with(['owner','commodity'=>function($query){
-//                $query->with('barcodes');
-//            }])->where('differ','>',0)->orderByDesc('id');
-//        }elseif ($differ=='无'){
-//            $inventoryCompares = InventoryCompare::query()->with(['owner','commodity'=>function($query){
-//                $query->with('barcodes');
-//            }])->where('differ','<',0)->orderByDesc('id');
-//        }else{
-//            $inventoryCompares = InventoryCompare::query()->with(['owner','commodity'=>function($query){
-//                $query->with('barcodes');
-//            }])->orderByDesc('id');
-//        }
-//        unset($param['differ']);
-//        $columnQueryRules=[
-//            'owner_id' => ['multi' => ','],
-//            'date_start' => ['alias' => 'created_at' , 'startDate' => ' 00:00:00'],
-//            'date_end' => ['alias' => 'created_at' , 'endDate' => ' 23:59:59'],
-//            'mission_code' => ['timeLimit' => 20],
-//        ];
-//        $inventoryCompares = app(QueryService::class)->query($param,$inventoryCompares,$columnQueryRules);
-//        return $inventoryCompares;
-//    }
 }

+ 4 - 4
public/js/app.js

@@ -2330,7 +2330,7 @@ function fromByteArray (uint8) {
 var BlobBuilder = typeof BlobBuilder !== 'undefined' ? BlobBuilder :
   typeof WebKitBlobBuilder !== 'undefined' ? WebKitBlobBuilder :
   typeof MSBlobBuilder !== 'undefined' ? MSBlobBuilder :
-  typeof MozBlobBuilder !== 'undefined' ? MozBlobBuilder :
+  typeof MozBlobBuilder !== 'undefined' ? MozBlobBuilder : 
   false;
 
 /**
@@ -61974,8 +61974,8 @@ module.exports = tempTip;
 /*! no static exports found */
 /***/ (function(module, exports, __webpack_require__) {
 
-__webpack_require__(/*! D:\Reald\desktop\BsWAS\src\resources\js\app.js */"./resources/js/app.js");
-module.exports = __webpack_require__(/*! D:\Reald\desktop\BsWAS\src\resources\sass\app.scss */"./resources/sass/app.scss");
+__webpack_require__(/*! D:\wamp64\www\bswas\resources\js\app.js */"./resources/js/app.js");
+module.exports = __webpack_require__(/*! D:\wamp64\www\bswas\resources\sass\app.scss */"./resources/sass/app.scss");
 
 
 /***/ }),
@@ -61991,4 +61991,4 @@ module.exports = __webpack_require__(/*! D:\Reald\desktop\BsWAS\src\resources\sa
 
 /***/ })
 
-/******/ });
+/******/ });