From 7c2e817088e096f5b69471730f55f7a94da82db0 Mon Sep 17 00:00:00 2001
From: Tevin <tingquanren@163.com>
Date: Tue, 21 Mar 2023 16:19:52 +0800
Subject: [PATCH] 允许关闭mock,使用post请求本地模拟接口

---
 bases/HostBoot.js |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/bases/HostBoot.js b/bases/HostBoot.js
index 12f98bc..83aefda 100644
--- a/bases/HostBoot.js
+++ b/bases/HostBoot.js
@@ -14,6 +14,7 @@
      */
     constructor() {
         this._data = {
+            mockOff: Tools.getUrlParam('mock') === 'off',
             // 可用主机列表
             hostList: {
                 ...project.host.hosts,
@@ -193,6 +194,9 @@
      */
     isOnMock() {
         if (this.isDevMod()) {
+            if (this._data.mockOff) {
+                return false;
+            }
             return this.getHostName() === 'lc';
         } else {
             return false;

--
Gitblit v1.9.1