apply plugin: 'com.android.application'

android {
    flavorDimensions 'version'
    compileSdkVersion 30
    buildToolsVersion "30.0.1"

    defaultConfig {
        applicationId "com.dbs.mplus.fatima"
        minSdkVersion 24
        targetSdkVersion 30
        versionCode 4
        versionName "4"

        multiDexEnabled true
//        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }

    signingConfigs {
        release {
            storeFile file('fatima.jks') // 기준은 App 폴더 기준이다.
            storePassword "#3wnffkdl#"
            keyAlias "fatima"
            keyPassword "#3wnffkdl#"
        }
    }

    buildTypes {
        debug {
            buildConfigField "String", "NAME_SPACE", "\"http://tempuri.org/\""
            minifyEnabled false
            proguardFile 'proguard-rules.pro'
            ndk {
                abiFilters "armeabi-v7a", "armeabi" // includes ARM SO files only, so no x86 SO file
            }
        }
        release {
            //            signingConfig signingConfigs.release
            buildConfigField "String", "originalPackageName", "\"com.dbs.mplus.fatima\""
            buildConfigField "String", "NAME_SPACE", "\"http://tempuri.org/\""
            minifyEnabled false
            proguardFile 'proguard-rules.pro'
//            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
            ndk {
                abiFilters "armeabi-v7a", "armeabi" // includes ARM SO files only, so no x86 SO file
            }
        }
    }

    productFlavors {
        product {
            buildConfigField "String", "originalPackageName", "\"com.dbs.mplus.fatima\""
            buildConfigField "String", "CONSENT_SERVER_URL", "\"http://172.16.10.192/\""
            buildConfigField "String", "CONSENT_SERVER_URL", "\"https://consent.fatima.or.kr/\""
//            buildConfigField "String", "CONSENT_EFORM_SERVER_URL", "\"https://eform.fatima.or.kr/eformservice.aspx/\""
            buildConfigField "String", "INST_CD", "\"111\""
            manifestPlaceholders = [appLabel: "파티마병원"]
        }

        dev {
            applicationIdSuffix ".dev"
            buildConfigField "String", "originalPackageName", "\"com.dbs.mplus.fatima\""
//            buildConfigField "String", "CONSENT_SERVER_URL", "\"http://192.168.43.170/\""
            buildConfigField "String", "CONSENT_SERVER_URL", "\"http://192.168.100.124:8070/\""
//            buildConfigField "String", "CONSENT_EFORM_SERVER_URL", "\"http://192.168.43.170:8070/eformservice.aspx/\""
            buildConfigField "String", "CONSENT_EFORM_SERVER_URL", "\"http://192.168.100.124:8090/eformservice.aspx/\""
            buildConfigField "String", "INST_CD", "\"111\""
            manifestPlaceholders = [appLabel: "파티마병원 교육"]
        }
    }

}

repositories {
    maven { url 'https://oss.sonatype.org/content/repositories/ksoap2-android-releases/' }
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])

    implementation 'androidx.appcompat:appcompat:1.2.0'
    implementation 'androidx.constraintlayout:constraintlayout:2.0.1'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'androidx.test.ext:junit:1.1.2'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
    implementation 'com.google.code.ksoap2-android:ksoap2-android:3.6.4'
    implementation 'com.github.ybq:Android-SpinKit:1.2.0'
    implementation 'gun0912.ted:tedpermission:2.0.0'
    implementation 'com.squareup.picasso:picasso:2.71828'
    implementation 'com.github.chrisbanes:PhotoView:2.0.0'
    implementation 'androidx.recyclerview:recyclerview:1.1.0'
}
