Initial commit: ContactSync Android app

- SyncAdapter with account type com.bitrix24.contacts.sync
- Two-phase sync: download to Room DB, then import to phone contacts
- FCM push for instant contact addition
- WorkManager: periodic sync (30min) + heartbeat (1h)
- QR code activation (JSON format)
- Event log UI with LiveData
- Auto-update mechanism via version.php
- Duplicate contacts cleanup
- CALLER_IS_SYNCADAPTER optimization for bulk inserts

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-14 10:41:16 +05:00
commit 125010bbe3
51 changed files with 2908 additions and 0 deletions

51
gradle/libs.versions.toml Normal file
View File

@@ -0,0 +1,51 @@
[versions]
agp = "8.5.2"
kotlin = "2.0.10"
coreKtx = "1.13.1"
appcompat = "1.7.0"
material = "1.12.0"
room = "2.6.1"
workmanager = "2.9.1"
retrofit = "2.11.0"
okhttp = "4.12.0"
firebase-bom = "34.11.0"
ksp = "2.0.10-1.0.24"
lifecycle = "2.8.4"
coroutines = "1.8.1"
activity = "1.9.1"
google-services = "4.4.4"
zxing = "4.3.0"
[libraries]
androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "coreKtx" }
androidx-appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "appcompat" }
androidx-activity-ktx = { group = "androidx.activity", name = "activity-ktx", version.ref = "activity" }
material = { group = "com.google.android.material", name = "material", version.ref = "material" }
room-runtime = { group = "androidx.room", name = "room-runtime", version.ref = "room" }
room-ktx = { group = "androidx.room", name = "room-ktx", version.ref = "room" }
room-compiler = { group = "androidx.room", name = "room-compiler", version.ref = "room" }
workmanager = { group = "androidx.work", name = "work-runtime-ktx", version.ref = "workmanager" }
retrofit = { group = "com.squareup.retrofit2", name = "retrofit", version.ref = "retrofit" }
retrofit-gson = { group = "com.squareup.retrofit2", name = "converter-gson", version.ref = "retrofit" }
okhttp = { group = "com.squareup.okhttp3", name = "okhttp", version.ref = "okhttp" }
okhttp-logging = { group = "com.squareup.okhttp3", name = "logging-interceptor", version.ref = "okhttp" }
firebase-bom = { group = "com.google.firebase", name = "firebase-bom", version.ref = "firebase-bom" }
firebase-messaging = { group = "com.google.firebase", name = "firebase-messaging" }
lifecycle-runtime = { group = "androidx.lifecycle", name = "lifecycle-runtime-ktx", version.ref = "lifecycle" }
lifecycle-viewmodel = { group = "androidx.lifecycle", name = "lifecycle-viewmodel-ktx", version.ref = "lifecycle" }
coroutines-core = { group = "org.jetbrains.kotlinx", name = "kotlinx-coroutines-core", version.ref = "coroutines" }
coroutines-android = { group = "org.jetbrains.kotlinx", name = "kotlinx-coroutines-android", version.ref = "coroutines" }
zxing = { group = "com.journeyapps", name = "zxing-android-embedded", version.ref = "zxing" }
[plugins]
android-application = { id = "com.android.application", version.ref = "agp" }
kotlin-android = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
ksp = { id = "com.google.devtools.ksp", version.ref = "ksp" }
google-services = { id = "com.google.gms.google-services", version.ref = "google-services" }

BIN
gradle/wrapper/gradle-wrapper.jar vendored Normal file

Binary file not shown.

View File

@@ -0,0 +1,7 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists