wjc
2023-06-14 bed9201624d77443c6151f47d34191c84ffc0256
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
plugins {
    id 'com.android.application'
}
//必须配置uni
def mfph = [
        //宿主包名
        "apk.applicationId": "com.hdl.photovoltaic",
]
 
android {
    compileSdk 32
 
    defaultConfig {
        applicationId "com.hdl.photovoltaic"
        minSdk 23
        targetSdk 32
        versionCode 1
        versionName "1.0"
 
        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
        multiDexEnabled true
        manifestPlaceholders = mfph
        ndk {
            abiFilters 'x86', 'armeabi-v7a', "arm64-v8a" //不支持armeabi
        }
 
    }
    //此处配置必须添加 否则无法正确运行uni
    aaptOptions {
        additionalParameters '--auto-add-overlay'
        //noCompress 'foo', 'bar'
        ignoreAssetsPattern "!.svn:!.git:.*:!CVS:!thumbs.db:!picasa.ini:!*.scc:*~"
    }
    repositories {
        flatDir {
            dirs 'libs'
        }
    }
 
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
        }
    }
 
    buildFeatures {
        viewBinding true
    }
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
}
 
dependencies {
 
    implementation fileTree(include: ['*.jar', '*.aar'], dir: 'libs')
 
    implementation 'androidx.appcompat:appcompat:1.3.0'
    implementation 'com.google.android.material:material:1.4.0'
    implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
    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: ':third-zxing')
    testImplementation 'junit:junit:4.13.2'
    androidTestImplementation 'androidx.test.ext:junit:1.1.3'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
//    implementation 'org.greenrobot:eventbus:3.0.0'
    implementation 'com.hdl.hdlhttp:hxhttp:1.0.4'
 
 
    //********UniSDK必须添加的依赖 start********
    implementation "androidx.recyclerview:recyclerview:1.0.0"
    implementation 'com.alibaba:fastjson:1.2.66'//必须集成,fastjson功能需要
    implementation 'com.facebook.fresco:fresco:2.5.0'//必须集成,图片加载需要
    implementation 'com.facebook.fresco:animated-gif:2.5.0'//必须集成,图片加载需要
    implementation 'com.facebook.fresco:webpsupport:2.5.0'
    implementation 'com.facebook.fresco:animated-webp:2.5.0'
    implementation 'com.github.bumptech.glide:glide:4.9.0'//必须集成,图片加载需要
    implementation 'com.android.support:multidex:1.0.3'
    implementation 'androidx.webkit:webkit:1.3.0'//3.6.15版本之后 必须集成,用来支持暗黑模式
    //********UniSDK必须添加的依赖 end********
 
 
}