Событие печати, смена адреса, иконки

This commit is contained in:
Халимов Рустам
2026-04-17 16:23:52 +03:00
parent cea3f4d669
commit 8c00d1376d
20 changed files with 95 additions and 26 deletions
+4 -4
View File
@@ -1,7 +1,6 @@
package core.network
import android.content.Context
import android.content.SharedPreferences
import com.google.gson.Gson
import core.domain.model.FeaturesConfig
import core.domain.model.ServerConfigModel
@@ -13,12 +12,12 @@ class ServerConfig @Inject constructor(
private val context: Context,
private val gson: Gson
) {
private val prefs: SharedPreferences = context.getSharedPreferences("server_settings", Context.MODE_PRIVATE)
private val prefs = context.getSharedPreferences("server_config_prefs", Context.MODE_PRIVATE)
companion object {
const val DEFAULT_BASE_URL = "https://your-api.com/api/"
private const val KEY_BASE_URL = "base_url"
private const val KEY_CONFIG_DATA = "config_data"
private const val KEY_CONFIG_DATA = "server_config_data"
private const val DEFAULT_BASE_URL = "" // Пустой по умолчанию
}
fun getBaseUrl(): String {
@@ -48,3 +47,4 @@ class ServerConfig @Inject constructor(
return feature(getServerConfig().features)
}
}