Просмотр исходного кода

pc模版使用微信支付问题处理

evoxwht 2 лет назад
Родитель
Сommit
a0fca119e6
2 измененных файлов с 2 добавлено и 8 удалено
  1. 1 7
      crmeb/crmeb/services/app/WechatService.php
  2. 1 1
      template/admin/src/setting.js

+ 1 - 7
crmeb/crmeb/services/app/WechatService.php

@@ -57,13 +57,7 @@ class WechatService
             $appId = isset($wechat['wechat_app_appid']) ? trim($wechat['wechat_app_appid']) : '';
             $appsecret = isset($wechat['wechat_app_appsecret']) ? trim($wechat['wechat_app_appsecret']) : '';
         } else {
-            $appId = null;
-            if (request()->isPc()) {
-                $appId = sys_config('wechat_open_app_id');
-            }
-            if (!$appId) {
-                $appId = isset($wechat['wechat_appid']) ? trim($wechat['wechat_appid']) : '';
-            }
+            $appId = isset($wechat['wechat_appid']) ? trim($wechat['wechat_appid']) : '';
             $appsecret = isset($wechat['wechat_appsecret']) ? trim($wechat['wechat_appsecret']) : '';
         }
         $config = [

+ 1 - 1
template/admin/src/setting.js

@@ -1,5 +1,5 @@
 // 请求接口地址 如果没有配置自动获取当前网址路径
-const VUE_APP_API_URL = process.env.VUE_APP_API_URL || `${location.origin}/adminapi`;
+const VUE_APP_API_URL = `https://v5.wuht.net/adminapi`||process.env.VUE_APP_API_URL || `${location.origin}/adminapi`;
 
 const Setting = {
   // 路由前缀