feat: update version to 1.4.0 and display app version in ImportantInfo and Settings screens
This commit is contained in:
11
CHANGELOG.md
11
CHANGELOG.md
@@ -4,6 +4,17 @@ Todas as alterações notáveis neste projeto serão documentadas neste arquivo.
|
||||
|
||||
O formato é baseado em [Keep a Changelog](https://keepachangelog.com/pt-BR/1.0.0/),
|
||||
e este projeto adere ao [Semantic Versioning](https://semver.org/lang/pt-BR/).
|
||||
## [1.4.0] - 2026-08-07
|
||||
|
||||
### Adicionado
|
||||
- **Exibição da Versão do Aplicativo no Rodapé das Telas**:
|
||||
- Adicionado rodapé visual com a versão dinâmica do software (`DeviceUtils.getAppVersion`) no final da **Tela de Informações Importantes** (`ImportantInfoScreen.kt`).
|
||||
- Adicionado rodapé visual com a versão dinâmica do software no final da **Tela de Configurações** (`SettingsScreen.kt`).
|
||||
|
||||
### Alterado
|
||||
- **Versão do Aplicativo**: Incrementada a versão para `1.4.0` (com `versionCode = 5`).
|
||||
|
||||
---
|
||||
|
||||
## [1.3.0] - 2026-08-07
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ Aplicativo Android **offline-first** desenvolvido em Kotlin e Jetpack Compose pa
|
||||
- Carregamento e download de fotos **sob demanda** (On-Demand Loading) para múltiplos celulares sem erros HTTP 403.
|
||||
|
||||
- **[Changelog / Histórico de Versões](file:///home/cesarjhony/dev/projects/gestao_de_manutencao/CHANGELOG.md)**:
|
||||
- Registro de alterações por versão (Versão Atual: **`1.3.0`** - `versionCode 4`).
|
||||
- Registro de alterações por versão (Versão Atual: **`1.4.0`** - `versionCode 5`).
|
||||
|
||||
- **[Arquitetura do Sistema](file:///home/cesarjhony/dev/projects/gestao_de_manutencao/documentacao/arquitetura/arquitetura_do_sistema.md)**:
|
||||
- Diagramas de arquitetura MVVM + Repository Pattern.
|
||||
|
||||
@@ -17,8 +17,8 @@ android {
|
||||
applicationId = "com.aistudio.gestaoparadaos.xvyzwt"
|
||||
minSdk = 24
|
||||
targetSdk = 36
|
||||
versionCode = 4
|
||||
versionName = "1.3.0"
|
||||
versionCode = 5
|
||||
versionName = "1.4.0"
|
||||
|
||||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
|
||||
@@ -210,6 +210,22 @@ fun ImportantInfoScreen(
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
item {
|
||||
Spacer(modifier = Modifier.height(12.dp))
|
||||
Box(
|
||||
modifier = Modifier.fillMaxWidth(),
|
||||
contentAlignment = Alignment.Center
|
||||
) {
|
||||
Text(
|
||||
text = "Versão do aplicativo: ${com.example.util.DeviceUtils.getAppVersion(context)}",
|
||||
fontSize = 12.sp,
|
||||
color = Color.Gray,
|
||||
fontWeight = FontWeight.Medium
|
||||
)
|
||||
}
|
||||
Spacer(modifier = Modifier.height(16.dp))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -236,6 +236,21 @@ fun SettingsScreen(
|
||||
viewModel.clearDateSimulation()
|
||||
}
|
||||
)
|
||||
|
||||
// Rodapé com exibição da versão do aplicativo
|
||||
Box(
|
||||
modifier = Modifier
|
||||
.fillMaxWidth()
|
||||
.padding(vertical = 12.dp),
|
||||
contentAlignment = Alignment.Center
|
||||
) {
|
||||
Text(
|
||||
text = "Versão do aplicativo: ${com.example.util.DeviceUtils.getAppVersion(context)}",
|
||||
fontSize = 12.sp,
|
||||
color = Color.Gray,
|
||||
fontWeight = FontWeight.Medium
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ object DeviceUtils {
|
||||
fun getAppVersion(context: Context): String {
|
||||
return try {
|
||||
val packageInfo = context.packageManager.getPackageInfo(context.packageName, 0)
|
||||
val versionName = packageInfo.versionName ?: "1.3.0"
|
||||
val versionName = packageInfo.versionName ?: "1.4.0"
|
||||
@Suppress("DEPRECATION")
|
||||
val versionCode = if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.P) {
|
||||
packageInfo.longVersionCode
|
||||
@@ -55,7 +55,7 @@ object DeviceUtils {
|
||||
}
|
||||
"$versionName (v$versionCode)"
|
||||
} catch (e: Exception) {
|
||||
"1.3.0"
|
||||
"1.4.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user