From cf4787bc8188cd0acc8a42793730b076742f29c1 Mon Sep 17 00:00:00 2001
From: riku <risaku@163.com>
Date: 星期四, 16 四月 2026 17:37:35 +0800
Subject: [PATCH] 新增现场巡查模块(待完成)

---
 services/baseRequset.js |   24 +++++++++++++++++++-----
 1 files changed, 19 insertions(+), 5 deletions(-)

diff --git a/services/baseRequset.js b/services/baseRequset.js
index faaf70a..1aa6214 100644
--- a/services/baseRequset.js
+++ b/services/baseRequset.js
@@ -2,14 +2,23 @@
 
 function request(fun, hostUrl) {
   const bUrl = hostUrl ? hostUrl : baseUrl;
-  if (fun.params != undefined) {
+  if (
+    !(
+      fun.params == undefined ||
+      fun.params == 'undefined' ||
+      fun.params == null ||
+      fun.params == 'null'
+    )
+  ) {
     var param = '';
     Object.keys(fun.params).forEach(key => {
       var value = fun.params[key];
-      if (param == '') {
-        param += key + '=' + value;
-      } else {
-        param += '&' + key + '=' + value;
+      if (!(value == undefined || value == 'undefined' || value == null || value == 'null')) {
+        if (param == '') {
+          param += key + '=' + value;
+        } else {
+          param += '&' + key + '=' + value;
+        }
       }
     });
     var url = fun.url;
@@ -68,3 +77,8 @@
   fun['method'] = 'PUT';
   return request(fun, hostUrl);
 }
+
+export function _delete(fun, hostUrl) {
+  fun['method'] = 'DELETE';
+  return request(fun, hostUrl);
+}

--
Gitblit v1.9.3