From 3ccff7173fb73322f7785d8eaedc90a1b5d8765d Mon Sep 17 00:00:00 2001
From: wjc <1243177876@qq.com>
Date: 星期二, 10 十二月 2024 22:44:03 +0800
Subject: [PATCH] 2024年12月10日22:43:59

---
 app/build.gradle |   79 +++++++++++++++++++++++++++++----------
 1 files changed, 59 insertions(+), 20 deletions(-)

diff --git a/app/build.gradle b/app/build.gradle
index 894436e..4c24bb6 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -1,5 +1,7 @@
 plugins {
     id 'com.android.application'
+    // 娣诲姞濡備笅閰嶇疆(鍗庝负鏋佸厜鎺ㄩ��)
+    id 'com.huawei.agconnect'
 }
 //蹇呴』閰嶇疆uni
 def mfph = [
@@ -22,18 +24,18 @@
             keyPassword '85521566'
         }
     }
-    compileSdk 30
+    compileSdkVersion 34
     defaultConfig {
         applicationId "com.hdl.photovoltaic"
-        minSdk 23
-        targetSdk 30
-        versionCode 1
-        versionName "1.1.3"//鐗堟湰瑙勫垯1.1鏄骇鍝佸姛鑳借凯浠g敤鐨�,鏈�鍚庝竴浣�1鏄垜浠慨澶峛ug鐢ㄧ殑
+        minSdkVersion 23
+        targetSdkVersion 34
+        versionCode 2
+        versionName "1.5.1"//鐗堟湰瑙勫垯1.3鏄骇鍝佸姛鑳借凯浠g敤鐨�,鏈�鍚庝竴浣�0鏄垜浠慨澶峛ug鐢ㄧ殑
         testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
         multiDexEnabled true
         manifestPlaceholders = mfph
         ndk {
-            abiFilters 'x86', 'armeabi-v7a', "arm64-v8a" //涓嶆敮鎸乤rmeabi
+            abiFilters 'armeabi-v7a', "arm64-v8a" //涓嶆敮鎸乤rmeabi
         }
 
         manifestPlaceholders = [
@@ -54,9 +56,15 @@
 //                VIVO_APPKEY : "vivo鐨凙PPKEY",
 //                VIVO_APPID : "vivo鐨凙PPID",
 //                HONOR_APPID : "Honor鐨凙PP ID",
+//                MEIZU_APPKEY : "MZ-榄呮棌鐨凙PPKEY",
+//                MEIZU_APPID : "110098313",
 
         ]
 
+    }
+    // 淇濊瘉鍏朵粬鐨刲ib娌℃湁琚玴reDex
+    dexOptions {
+        preDexLibraries = false
     }
     repositories {
         flatDir {
@@ -69,18 +77,26 @@
         //noCompress 'foo', 'bar'
         ignoreAssetsPattern "!.svn:!.git:.*:!CVS:!thumbs.db:!picasa.ini:!*.scc:*~"
     }
+//    lintOptions {
+//        checkReleaseBuilds false
+//        // Or, if you prefer, you can continue to check for errors in release builds,
+//        // but continue the build even when errors are found:
+//        abortOnError false
+//    }
+
+
     /**
      * 鎵撳寘鑷姩鍛藉悕
      */
     android.applicationVariants.configureEach { variant ->
         variant.outputs.configureEach {
-            outputFileName = "photovoltaic_${name}_v${versionName}_${generateTime()}.apk"
+            outputFileName = "photovoltaic_v${versionName}_${generateTime()}_${getEnvironmentVersion(2)}.apk"
         }
     }
 
     buildTypes {
         release {
-            minifyEnabled false
+            minifyEnabled false //寮�鍚贩娣�
             proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
             signingConfig signingConfigs.release
         }
@@ -103,6 +119,20 @@
     return new Date().format("yyyyMMddHHmm")
 }
 
+//鐜鐗堟湰鍙凤細姝ょ増鏈彿鐢ㄤ簬鏍囨敞褰撳墠鐗堟湰鐨勮蒋浠跺浜庡摢涓紑鍙戦樁娈碉紝褰撹蒋浠惰繘鍏ュ埌鍙︿竴涓樁娈垫椂闇�瑕佷慨鏀规鐗堟湰鍙枫��
+static String getEnvironmentVersion(int environmentVersionValue) {
+    if (environmentVersionValue == 1) {
+        return "dev"//寮�鍙戦樁娈电増鏈��(涓�鑸笉鍚戝閮ㄥ彂甯冿紝bug浼氭瘮杈冨锛屽姛鑳戒篃涓嶅叏锛屼竴鑸彧鏈夊紑鍙戜汉鍛樹娇鐢ㄣ��)
+    } else if (environmentVersionValue == 2) {
+        return "test"//娴嬭瘯闃舵鐗堟湰銆�(杩欎釜闃舵鐗堟湰浼氶厤鍚堟祴璇曚汉鍛樹慨澶峛ug锛岀洿鍒版弧瓒冲彂甯冩潯浠躲��)
+    } else if (environmentVersionValue == 3) {
+        return "beta"//鍏祴闃舵鐗堟湰銆�(鍏紑娴嬭瘯鐗堟湰锛屼竴鑸槸鍐呮祴閫氳繃鐨勶紝涓昏浼氭湁"绮変笣鐢ㄦ埛"浣跨敤浣撻獙銆�)
+    } else if (environmentVersionValue == 4) {
+        return "release"
+//鍙戝竷闃舵鐗堟湰銆�(璇ョ増鏈剰鍛�"鏈�缁堢増鏈�"锛屽湪鍓嶉潰鐗堟湰鐨勪竴绯诲垪娴嬭瘯鐗堜箣鍚庯紝缁堝綊浼氭湁涓�涓寮忕増鏈紝鏄渶缁堜氦浠樼敤鎴蜂娇鐢ㄧ殑涓�涓増鏈�傝鐗堟湰鏈夋椂涔熺О涓烘爣鍑嗙増銆備竴鑸儏鍐典笅锛孯elease涓嶄細浠ュ崟璇嶅舰寮忓嚭鐜板湪杞欢灏侀潰涓娿��)
+    }
+}
+
 dependencies {
 
     implementation fileTree(include: ['*.jar', '*.aar'], dir: 'libs')
@@ -113,14 +143,18 @@
     implementation 'androidx.navigation:navigation-fragment:2.3.5'
     implementation 'androidx.navigation:navigation-ui:2.3.5'
     implementation 'androidx.legacy:legacy-support-v4:1.0.0'
-
+    //鏃堕棿搴�
+    implementation project(path: ':pickerview')
+    //鍥捐〃搴�
+    implementation project(path: ':aa_chart_core')
     //鍥藉鍒楄〃鍜屾墜鏈哄尯鍙峰簱
     implementation project(path: ':countrypicker')
     //浜岀淮鐮佸簱
     implementation project(path: ':third-zxing')
-    //Link鏈湴搴�
-    implementation project(path: ':HDLLinkLocalSdk')
-//    implementation project(path: ':HDLLinkPMSdk')
+    //Link鏈湴搴擄紙鍦ㄧ嚎渚濊禆缃戠粶搴擄級
+    implementation 'com.hdl.android:pmsdk:1.0.9'
+    implementation 'com.hdl.android:debugsdk:1.0.65'
+//    implementation project(path:':sdk')
 
     testImplementation 'junit:junit:4.13.2'
     androidTestImplementation 'androidx.test.ext:junit:1.1.3'
@@ -132,12 +166,16 @@
 
     //Eventbus浜嬩欢鍙戝竷涓庢帴鏀�
     implementation 'org.greenrobot:eventbus:3.3.1'
-    //灞忓箷閫傞厤
+    //灞忓箷閫傞厤搴�
     implementation 'com.github.JessYanCoding:AndroidAutoSize:v1.2.1'
 
+
     //鍥剧墖鍔犺浇搴�
-    implementation 'com.github.bumptech.glide:glide:4.12.0'
+    implementation 'com.github.bumptech.glide:glide:4.13.0'
     annotationProcessor 'com.github.bumptech.glide:compiler:4.12.0'
+
+    //娣诲姞StatusBarUtil鐨勪緷璧� 鐘舵�佹爮閫傞厤
+    implementation 'com.jaeger.statusbarutil:library:1.5.1'
 
 
     //********UniSDK蹇呴』娣诲姞鐨勪緷璧� start********
@@ -167,11 +205,12 @@
     implementation 'cn.jiguang.sdk:joperate:2.0.2'
 
 
-//    //鑻ヤ笉闆嗘垚鍘傚晢閫氶亾锛屽彲鐩存帴璺宠繃浠ヤ笅渚濊禆
-//    // 鏋佸厜鍘傚晢鎻掍欢鐗堟湰涓庢帴鍏� JPush 鐗堟湰淇濇寔涓�鑷达紝涓嬪悓
-//    // 鎺ュ叆鍗庝负鍘傚晢
-//    implementation 'com.huawei.hms:push:6.9.0.300'
-//    implementation 'cn.jiguang.sdk.plugin:huawei:5.0.3'
+    //鑻ヤ笉闆嗘垚鍘傚晢閫氶亾锛屽彲鐩存帴璺宠繃浠ヤ笅渚濊禆
+    // 鏋佸厜鍘傚晢鎻掍欢鐗堟湰涓庢帴鍏� JPush 鐗堟湰淇濇寔涓�鑷达紝涓嬪悓
+    // 鎺ュ叆鍗庝负鍘傚晢
+    implementation 'com.huawei.hms:push:6.9.0.300'
+    implementation 'cn.jiguang.sdk.plugin:huawei:5.0.3'
+    implementation 'com.huawei.agconnect:agconnect-core:1.9.1.301'
 //    // 鎺ュ叆 FCM 鍘傚晢
 //    implementation 'com.google.firebase:firebase-messaging:23.1.2'
 //    implementation 'cn.jiguang.sdk.plugin:fcm:5.0.3'
@@ -200,6 +239,6 @@
 //    濡傛灉閫夋嫨鐨勫巶鍟嗛�氶亾鍖呭惈浜� Huawei 鍘傚晢閫氶亾鍜� FCM 鍘傚晢閫氶亾锛屽垯闇�瑕侀澶栨墽琛屼互涓嬫搷浣滐紝鑻ユ湭閫夋嫨鍙拷鐣ユ湰姝ラ銆�
 //    FCM锛氬湪 Firebase 涓婂垱寤哄拰 JPush 涓婂悓鍖呭悕鐨勫緟鍙戝竷搴旂敤锛屽垱寤哄畬鎴愬悗涓嬭浇璇ュ簲鐢ㄧ殑 google-services.json 閰嶇疆鏂囦欢骞舵坊鍔犲埌搴旂敤鐨� module 鐩綍涓嬨��
 //    Huawei锛氬湪 Huawei 涓婂垱寤哄拰 JPush 涓婂悓鍖呭悕鐨勫緟鍙戝竷搴旂敤锛屽垱寤哄畬鎴愬悗涓嬭浇璇ュ簲鐢ㄧ殑 agconnect-services.json 閰嶇疆鏂囦欢骞舵坊鍔犲埌搴旂敤鐨� module 鐩綍涓嬨��
-
+    //鍙互浣跨敤CardView缁勪欢鏉ヤ负瑙嗗浘璁剧疆闃村奖鏁堟灉
 
 }
\ No newline at end of file

--
Gitblit v1.8.0