From c91947ce713ecfb98eaebaa4e283619b4042a24c Mon Sep 17 00:00:00 2001
From: zlzw <583819556@qq.com>
Date: Wed, 5 Jun 2024 16:37:24 +0800
Subject: [PATCH] =?UTF-8?q?=E9=85=8D=E7=BD=AE=E5=8C=96=E5=A3=B0=E7=BD=91Ap?=
=?UTF-8?q?pId?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app/src/main/AndroidManifest.xml | 3 +++
.../src/main/java/com/yunbao/common/CommonAppConfig.java | 7 ++++---
config.gradle | 2 ++
3 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index 0b83186e1..adc2c0efc 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -165,6 +165,9 @@
+
diff --git a/common/src/main/java/com/yunbao/common/CommonAppConfig.java b/common/src/main/java/com/yunbao/common/CommonAppConfig.java
index 9f78b5fac..c72a2207d 100644
--- a/common/src/main/java/com/yunbao/common/CommonAppConfig.java
+++ b/common/src/main/java/com/yunbao/common/CommonAppConfig.java
@@ -38,6 +38,7 @@ public class CommonAppConfig {
//是否为插件包模式
public static final boolean IS_PLUGIN_MODEL = getMetaDataBoolean("IS_PLUGIN_MODEL");
public static final String BUILD_TIME = getMetaDataString("BUILD_TIME");
+ public static final boolean IS_SW_RELEASE = getMetaDataBoolean("SW_RELEASE_MODEL");
//外部sd卡
public static final String DCMI_PATH = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DCIM).getAbsolutePath();
@@ -85,10 +86,10 @@ public class CommonAppConfig {
public static final String SWAPPId = "d4a5879524d74c20a7bdd667b0f2ca21";
public static String getSwAppId() {
- if (BuildConfig.DEBUG) {
- return SWAPPId_debug;
- } else {
+ if (IS_SW_RELEASE) {
return SWAPPId;
+ } else {
+ return SWAPPId_debug;
}
}
diff --git a/config.gradle b/config.gradle
index 717d8024b..1bd0a5f16 100644
--- a/config.gradle
+++ b/config.gradle
@@ -17,6 +17,8 @@ ext {
//百度语音识别
+ swReleaseModel : true, //true声网正式服 false测试服
+
baiduAppId : "23774720",
baiduAppKey : "zgCgFhUKEOV7I3ZXDFpTfnRB",