Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2ee7c14e77
|
||
|
|
8d28ee2d6c
|
||
|
|
aee1bd582b
|
||
|
|
8d398db1cb
|
||
|
|
9da65e0725
|
||
|
|
38128d12a0
|
||
|
|
2d7f1b9c2d
|
||
|
|
34ed687234
|
||
|
|
8564f64576
|
||
|
|
c6be8eda6b
|
||
|
|
7904aabbc3
|
||
|
|
e59680e710
|
||
|
|
fff3490719
|
||
|
|
aedefc9010
|
||
|
|
492230faa2
|
||
|
|
488aa9bba6 | ||
|
|
f321eee4f5 | ||
|
|
78da09a312 | ||
|
|
1c6b246ea0 | ||
|
|
f78dc42f44 | ||
|
|
7e7d7face2 | ||
|
|
7ae20373da | ||
|
|
67359d98e0 | ||
|
|
e91fd05bac | ||
|
|
48fa785681 | ||
|
|
16410b7a7a | ||
|
|
367a13a84b | ||
|
|
0d98576b6b | ||
|
|
54481c8dc2 | ||
|
|
0179fdbee7 | ||
|
|
375830a9bd | ||
|
|
373a56a68a | ||
|
|
c487ca644e | ||
|
|
72867a9b5e | ||
|
|
f84d44770d | ||
|
|
bd6ab50859 | ||
|
|
b9e995f30d | ||
|
|
95bdc28336 | ||
|
|
72ba99f4b6 | ||
|
|
42f67dfbe4 | ||
|
|
54ddf69afb | ||
|
|
90b5c7a6e9 | ||
|
|
805a8d0bc4 | ||
|
|
10bf854a50 | ||
|
|
e7a72bef48 |
@@ -23,7 +23,7 @@ jobs:
|
||||
contents: write
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
- uses: actions/checkout@v7
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
@@ -41,7 +41,7 @@ jobs:
|
||||
run: git checkout -B "$BRANCH"
|
||||
|
||||
- name: set up JDK
|
||||
uses: actions/setup-java@v5
|
||||
uses: actions/setup-java@v6
|
||||
with:
|
||||
java-version: 21
|
||||
distribution: "temurin"
|
||||
@@ -49,12 +49,28 @@ jobs:
|
||||
- name: Setup Gradle
|
||||
uses: gradle/actions/setup-gradle@v6
|
||||
|
||||
- name: Run unit tests
|
||||
run: ./gradlew testDebugUnitTest
|
||||
|
||||
- name: Build APK
|
||||
run: |
|
||||
VERSION_CODE=$(git rev-list --count HEAD)
|
||||
VERSION_NAME=$(git describe --tags --always)
|
||||
VERSION_BASE=$(git describe --tags --abbrev=0 | sed 's/^v//')
|
||||
VERSION_DEV=$(git rev-list --count $(git describe --tags --abbrev=0)..HEAD)
|
||||
if [ $VERSION_DEV -gt 0 ]; then
|
||||
VERSION_NAME="${VERSION_BASE}.${VERSION_DEV}"
|
||||
else
|
||||
VERSION_NAME="${VERSION_BASE}"
|
||||
fi
|
||||
./gradlew assembleSignedRelease -PVERSION_CODE=$VERSION_CODE -PVERSION_NAME=$VERSION_NAME
|
||||
|
||||
- name: Upload APK
|
||||
uses: actions/upload-artifact@v7
|
||||
with:
|
||||
path: app/build/outputs/apk/signedRelease/app-signedRelease.apk
|
||||
compression-level: 0
|
||||
archive: false
|
||||
|
||||
- name: Release
|
||||
uses: softprops/action-gh-release@v3
|
||||
if: startsWith(github.ref, 'refs/tags/')
|
||||
|
||||
+66
-11
@@ -1,7 +1,8 @@
|
||||
plugins {
|
||||
id 'com.android.application' version '9.2.1'
|
||||
id 'org.jetbrains.kotlin.plugin.serialization' version '2.4.0'
|
||||
id 'org.jetbrains.kotlin.plugin.compose' version '2.4.0'
|
||||
id 'com.android.application' version '9.3.2'
|
||||
id 'org.jetbrains.kotlin.plugin.serialization' version '2.4.10'
|
||||
id 'org.jetbrains.kotlin.plugin.compose' version '2.4.10'
|
||||
id 'jacoco'
|
||||
}
|
||||
|
||||
android {
|
||||
@@ -16,6 +17,8 @@ android {
|
||||
targetSdk = 37
|
||||
versionName project.hasProperty('VERSION_NAME') ? project.property('VERSION_NAME') : "1.4"
|
||||
versionCode project.hasProperty('VERSION_CODE') ? project.property('VERSION_CODE').toInteger() : 1
|
||||
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
@@ -40,6 +43,7 @@ android {
|
||||
debuggable true
|
||||
initWith(buildTypes.release)
|
||||
signingConfig = signingConfigs.debug
|
||||
enableUnitTestCoverage true
|
||||
}
|
||||
release {
|
||||
minifyEnabled true
|
||||
@@ -69,6 +73,24 @@ android {
|
||||
compose = true
|
||||
}
|
||||
|
||||
testOptions {
|
||||
unitTests {
|
||||
includeAndroidResources = true
|
||||
all {
|
||||
maxParallelForks = 2
|
||||
forkEvery = 50
|
||||
maxHeapSize = "1024m"
|
||||
// Robolectric loads classes through its own sandbox classloader, which leaves them
|
||||
// without a code-source location. Without this JaCoCo skips them entirely and the
|
||||
// report only sees the handful of plain JVM classes.
|
||||
jacoco {
|
||||
includeNoLocationClasses = true
|
||||
excludes = ["jdk.internal.*"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
kotlin {
|
||||
jvmToolchain(21)
|
||||
}
|
||||
@@ -96,21 +118,21 @@ android {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation 'androidx.compose.foundation:foundation:1.11.4'
|
||||
implementation 'androidx.compose.runtime:runtime:1.11.4'
|
||||
implementation 'androidx.compose.foundation:foundation:1.12.0'
|
||||
implementation 'androidx.compose.runtime:runtime:1.12.0'
|
||||
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:2.1.5'
|
||||
|
||||
implementation 'androidx.preference:preference-ktx:1.2.1'
|
||||
implementation 'androidx.work:work-runtime-ktx:2.11.2'
|
||||
|
||||
implementation 'com.google.zxing:core:3.5.4'
|
||||
implementation 'androidx.camera:camera-camera2:1.6.1'
|
||||
implementation 'androidx.camera:camera-lifecycle:1.6.1'
|
||||
implementation 'androidx.camera:camera-view:1.6.1'
|
||||
implementation 'com.github.nextcloud:Android-SingleSignOn:1.1.0'
|
||||
implementation 'androidx.camera:camera-camera2:1.6.2'
|
||||
implementation 'androidx.camera:camera-lifecycle:1.6.2'
|
||||
implementation 'androidx.camera:camera-view:1.6.2'
|
||||
implementation 'com.github.nextcloud:Android-SingleSignOn:1.3.4'
|
||||
implementation 'com.opencsv:opencsv:5.12.0'
|
||||
|
||||
implementation platform('androidx.compose:compose-bom:2026.06.01')
|
||||
implementation platform('androidx.compose:compose-bom:2026.08.00')
|
||||
implementation 'androidx.compose.ui:ui'
|
||||
implementation 'androidx.compose.material:material'
|
||||
implementation 'androidx.compose.material:material-icons-extended'
|
||||
@@ -121,5 +143,38 @@ dependencies {
|
||||
implementation 'androidx.security:security-crypto:1.1.0'
|
||||
implementation 'androidx.lifecycle:lifecycle-viewmodel-compose:2.11.0'
|
||||
implementation "androidx.datastore:datastore-preferences:1.2.1"
|
||||
implementation "com.google.crypto.tink:tink-android:1.22.0"
|
||||
implementation "com.google.crypto.tink:tink-android:1.23.0"
|
||||
|
||||
testImplementation 'junit:junit:4.13.2'
|
||||
testImplementation 'io.mockk:mockk:1.14.11'
|
||||
testImplementation 'org.robolectric:robolectric:4.16.1'
|
||||
testImplementation 'androidx.test:core:1.7.0'
|
||||
testImplementation 'org.jetbrains.kotlinx:kotlinx-coroutines-test:1.11.0'
|
||||
testImplementation 'androidx.compose.ui:ui-test-junit4'
|
||||
|
||||
androidTestImplementation platform('androidx.compose:compose-bom:2026.08.00')
|
||||
androidTestImplementation 'androidx.test.ext:junit:1.3.0'
|
||||
androidTestImplementation 'androidx.test.espresso:espresso-core:3.7.0'
|
||||
androidTestImplementation 'androidx.compose.ui:ui-test-junit4'
|
||||
androidTestImplementation 'io.mockk:mockk-android:1.14.11'
|
||||
debugImplementation 'androidx.compose.ui:ui-test-manifest'
|
||||
}
|
||||
|
||||
tasks.register('jacocoTestReport', JacocoReport) {
|
||||
dependsOn 'testDebugUnitTest'
|
||||
|
||||
reports {
|
||||
xml.required = true
|
||||
html.required = true
|
||||
}
|
||||
|
||||
def fileFilter = ['**/R.class', '**/R$*.class', '**/BuildConfig.*', '**/Manifest*.*', '**/*Test*.*']
|
||||
def debugTree = fileTree(dir: "${project.layout.buildDirectory.asFile.get()}/intermediates/built_in_kotlinc/debug/compileDebugKotlin/classes", excludes: fileFilter)
|
||||
def mainSrc = "${project.projectDir}/src/main/java"
|
||||
|
||||
sourceDirectories.from = files([mainSrc])
|
||||
classDirectories.from = files([debugTree])
|
||||
executionData.from = fileTree(dir: project.layout.buildDirectory.asFile.get(), includes: [
|
||||
'jacoco/testDebugUnitTest.exec', 'outputs/unit_test_code_coverage/debugUnitTest/testDebugUnitTest.exec'
|
||||
])
|
||||
}
|
||||
|
||||
@@ -48,7 +48,7 @@ fun AboutScreen(
|
||||
title = { Text(stringResource(R.string.title_about)) },
|
||||
navigationIcon = {
|
||||
IconButton(onClick = onBack) {
|
||||
Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = null)
|
||||
Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = "Back")
|
||||
}
|
||||
},
|
||||
backgroundColor = MaterialTheme.colors.primary,
|
||||
|
||||
@@ -48,7 +48,7 @@ import java.util.Locale
|
||||
|
||||
class AccountActivity : AppCompatActivity() {
|
||||
|
||||
private val viewModel: AccountViewModel by viewModels()
|
||||
internal val viewModel: AccountViewModel by viewModels()
|
||||
|
||||
companion object {
|
||||
private val TAG = AccountActivity::class.java.simpleName
|
||||
|
||||
@@ -12,6 +12,7 @@ import androidx.activity.viewModels
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.compose.runtime.remember
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import androidx.preference.PreferenceManager
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.launch
|
||||
import kotlinx.coroutines.withContext
|
||||
@@ -33,7 +34,7 @@ import java.util.Calendar
|
||||
|
||||
class EditBillActivity : AppCompatActivity() {
|
||||
|
||||
private val viewModel: EditBillViewModel by viewModels()
|
||||
internal val viewModel: EditBillViewModel by viewModels()
|
||||
private lateinit var db: CowspentSQLiteOpenHelper
|
||||
private lateinit var bill: DBBill
|
||||
private var projectType: ProjectType = ProjectType.LOCAL
|
||||
@@ -151,11 +152,25 @@ class EditBillActivity : AppCompatActivity() {
|
||||
val billIdToDuplicate = intent.getLongExtra(PARAM_BILL_ID_TO_DUPLICATE, 0)
|
||||
val timeNowSeconds = System.currentTimeMillis() / 1000
|
||||
if (billIdToDuplicate == 0L) {
|
||||
bill = DBBill(
|
||||
0, 0, projectId, 0, 0.0, timeNowSeconds,
|
||||
"", DBBill.STATE_ADDED, DBBill.NON_REPEATED,
|
||||
DBBill.PAYMODE_NONE, DBBill.CATEGORY_NONE, "", DBBill.PAYMODE_ID_NONE
|
||||
)
|
||||
val preferences = PreferenceManager.getDefaultSharedPreferences(applicationContext)
|
||||
val fillFromLast = preferences.getBoolean(getString(R.string.pref_key_fill_new_bill_from_last), false)
|
||||
val lastBill = if (fillFromLast) db.getLastBillOfProject(projectId) else null
|
||||
|
||||
if (lastBill != null) {
|
||||
bill = DBBill(
|
||||
0, 0, projectId, lastBill.payerId, 0.0, timeNowSeconds,
|
||||
"", DBBill.STATE_ADDED, lastBill.repeat ?: DBBill.NON_REPEATED,
|
||||
lastBill.paymentMode, lastBill.categoryId, "", lastBill.paymentModeId
|
||||
)
|
||||
bill.billOwers = lastBill.billOwers.map { DBBillOwer(0, 0, it.memberId) }
|
||||
} else {
|
||||
val project = db.getProject(projectId)
|
||||
bill = DBBill(
|
||||
0, 0, projectId, project?.lastPayerId ?: 0, 0.0, timeNowSeconds,
|
||||
"", DBBill.STATE_ADDED, DBBill.NON_REPEATED,
|
||||
DBBill.PAYMODE_NONE, DBBill.CATEGORY_NONE, "", DBBill.PAYMODE_ID_NONE
|
||||
)
|
||||
}
|
||||
} else {
|
||||
val btd = db.getBill(billIdToDuplicate)!!
|
||||
bill = DBBill(
|
||||
@@ -316,7 +331,7 @@ class EditBillActivity : AppCompatActivity() {
|
||||
bill.amount == viewModel.getFinalAmount() &&
|
||||
bill.payerId == viewModel.payerId &&
|
||||
bill.comment == viewModel.getFinalComment() &&
|
||||
bill.repeat == viewModel.repeat &&
|
||||
(bill.repeat ?: DBBill.NON_REPEATED) == viewModel.repeat &&
|
||||
bill.categoryId == viewModel.categoryId &&
|
||||
bill.paymentModeId == viewModel.paymentModeId &&
|
||||
!owersChanged)
|
||||
@@ -324,15 +339,25 @@ class EditBillActivity : AppCompatActivity() {
|
||||
|
||||
private suspend fun saveBill(): Long = withContext(Dispatchers.IO) {
|
||||
val groupedBillIds = intent.getLongArrayExtra(PARAM_GROUPED_BILL_IDS)
|
||||
val isCustomSplit = viewModel.isCustomSplit
|
||||
val splitMode = viewModel.splitMode
|
||||
|
||||
if (isCustomSplit) {
|
||||
val splits: Map<Long, Double> = viewModel.owersCustomSplit.filter { (id, amountStr) ->
|
||||
viewModel.owersSelection[id] == true && (amountStr.replace(',', '.').toDoubleOrNull()
|
||||
?: 0.0) > 0
|
||||
}.mapValues {
|
||||
val uiAmount = it.value.replace(',', '.').toDoubleOrNull() ?: 0.0
|
||||
SupportUtil.round2(uiAmount / viewModel.selectedCurrencyRate)
|
||||
if (splitMode != SplitMode.EVEN) {
|
||||
val splits: Map<Long, Double> = if (splitMode == SplitMode.CUSTOM) {
|
||||
viewModel.owersCustomSplit.filter { (id, amountStr) ->
|
||||
viewModel.owersSelection[id] == true && viewModel.parseAmountFromUi(amountStr) > 0
|
||||
}.mapValues {
|
||||
val uiAmount = viewModel.parseAmountFromUi(it.value)
|
||||
SupportUtil.round2(uiAmount * viewModel.selectedCurrencyRate)
|
||||
}
|
||||
} else { // PERCENT
|
||||
val totalAmount = viewModel.amountAsDouble
|
||||
viewModel.owersPercentSplit.filter { (id, percentStr) ->
|
||||
viewModel.owersSelection[id] == true && viewModel.parseAmountFromUi(percentStr) > 0
|
||||
}.mapValues {
|
||||
val percent = viewModel.parseAmountFromUi(it.value)
|
||||
val uiAmount = SupportUtil.round2(totalAmount * percent / 100.0)
|
||||
SupportUtil.round2(uiAmount * viewModel.selectedCurrencyRate)
|
||||
}
|
||||
}
|
||||
|
||||
if (splits.isEmpty()) return@withContext 0L
|
||||
@@ -405,16 +430,8 @@ class EditBillActivity : AppCompatActivity() {
|
||||
val proj = db.getProject(bill.projectId)
|
||||
if (proj != null) db.syncIfRemote(proj)
|
||||
db.updateProject(
|
||||
bill.projectId,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
viewModel.payerId,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
null
|
||||
projId = bill.projectId,
|
||||
newLastPayerId = viewModel.payerId
|
||||
)
|
||||
|
||||
return@withContext firstSavedId
|
||||
@@ -458,16 +475,8 @@ class EditBillActivity : AppCompatActivity() {
|
||||
newOwersIds.forEach { newBill.billOwers += DBBillOwer(0, 0, it) }
|
||||
val newBillId = db.addBill(newBill)
|
||||
db.updateProject(
|
||||
bill.projectId,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
viewModel.payerId,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
null,
|
||||
null
|
||||
projId = bill.projectId,
|
||||
newLastPayerId = viewModel.payerId
|
||||
)
|
||||
val proj = db.getProject(bill.projectId)
|
||||
if (proj != null) db.syncIfRemote(proj)
|
||||
|
||||
@@ -1,11 +1,13 @@
|
||||
package net.helcel.cowspent.android.bill_edit
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.clickable
|
||||
import androidx.compose.foundation.interaction.MutableInteractionSource
|
||||
import androidx.compose.foundation.layout.*
|
||||
import androidx.compose.foundation.rememberScrollState
|
||||
import androidx.compose.foundation.text.BasicTextField
|
||||
import androidx.compose.foundation.text.KeyboardActions
|
||||
import androidx.compose.foundation.text.KeyboardOptions
|
||||
import androidx.compose.foundation.verticalScroll
|
||||
import androidx.compose.material.*
|
||||
@@ -16,12 +18,18 @@ import androidx.compose.material.icons.filled.*
|
||||
import androidx.compose.runtime.*
|
||||
import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.draw.clip
|
||||
import androidx.compose.ui.draw.scale
|
||||
import androidx.compose.ui.focus.FocusDirection
|
||||
import androidx.compose.ui.focus.FocusRequester
|
||||
import androidx.compose.ui.focus.focusRequester
|
||||
import androidx.compose.ui.graphics.Color
|
||||
import androidx.compose.ui.graphics.SolidColor
|
||||
import androidx.compose.ui.platform.LocalContext
|
||||
import androidx.compose.ui.platform.LocalFocusManager
|
||||
import androidx.compose.ui.res.stringResource
|
||||
import androidx.compose.ui.text.font.FontWeight
|
||||
import androidx.compose.ui.text.input.ImeAction
|
||||
import androidx.compose.ui.text.input.KeyboardType
|
||||
import androidx.compose.ui.text.input.VisualTransformation
|
||||
import androidx.compose.ui.text.style.TextAlign
|
||||
@@ -53,6 +61,13 @@ fun EditBillScreen(
|
||||
) {
|
||||
val canEdit = accessLevel == DBProject.ACCESS_LEVEL_UNKNOWN || accessLevel >= DBProject.ACCESS_LEVEL_PARTICIPANT
|
||||
val context = LocalContext.current
|
||||
val focusRequester = remember { FocusRequester() }
|
||||
|
||||
LaunchedEffect(Unit) {
|
||||
if (viewModel.isNewBill) {
|
||||
focusRequester.requestFocus()
|
||||
}
|
||||
}
|
||||
|
||||
StatefulAlertDialog(
|
||||
state = viewModel.dialogState,
|
||||
@@ -128,7 +143,8 @@ fun EditBillScreen(
|
||||
viewModel = viewModel,
|
||||
canEdit = canEdit,
|
||||
onDateClick = onDateClick,
|
||||
onTimeClick = onTimeClick
|
||||
onTimeClick = onTimeClick,
|
||||
amountFocusRequester = focusRequester
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.height(8.dp))
|
||||
@@ -164,7 +180,8 @@ fun BillBasicInfoSection(
|
||||
viewModel: EditBillViewModel,
|
||||
canEdit: Boolean,
|
||||
onDateClick: () -> Unit,
|
||||
onTimeClick: () -> Unit
|
||||
onTimeClick: () -> Unit,
|
||||
amountFocusRequester: FocusRequester
|
||||
) {
|
||||
Text(
|
||||
text = "GENERAL",
|
||||
@@ -175,29 +192,20 @@ fun BillBasicInfoSection(
|
||||
)
|
||||
|
||||
val context = LocalContext.current
|
||||
val focusManager = LocalFocusManager.current
|
||||
val currencyDialogTitle =
|
||||
stringResource(R.string.currency_dialog_title, viewModel.mainCurrencyName)
|
||||
|
||||
OutlinedTextField(
|
||||
value = viewModel.what,
|
||||
onValueChange = { viewModel.what = it },
|
||||
enabled = canEdit,
|
||||
placeholder = { Text(stringResource(R.string.label_what)) },
|
||||
modifier = Modifier.fillMaxWidth(),
|
||||
leadingIcon = { Icon(Icons.Default.Title, contentDescription = null) }
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.height(8.dp))
|
||||
|
||||
OutlinedTextField(
|
||||
value = viewModel.amount,
|
||||
onValueChange = {
|
||||
viewModel.amount = it
|
||||
onValueChange = { nv->
|
||||
val filteredValue = nv.filter { it in "0123456789.+-*/" }
|
||||
viewModel.amount = filteredValue
|
||||
viewModel.updateSplits()
|
||||
},
|
||||
enabled = canEdit,
|
||||
placeholder = { Text("0") },
|
||||
modifier = Modifier.fillMaxWidth(),
|
||||
modifier = Modifier.fillMaxWidth().focusRequester(amountFocusRequester),
|
||||
leadingIcon = {
|
||||
val currencyToShow = viewModel.selectedCurrencyName.ifEmpty {
|
||||
viewModel.mainCurrencyName.ifEmpty { "$" }
|
||||
@@ -231,7 +239,21 @@ fun BillBasicInfoSection(
|
||||
Icon(Icons.Default.SwapHoriz, contentDescription = "Change Currency")
|
||||
}
|
||||
},
|
||||
keyboardOptions = KeyboardOptions(keyboardType = KeyboardType.Number)
|
||||
keyboardOptions = KeyboardOptions(keyboardType = KeyboardType.Phone, imeAction = ImeAction.Next),
|
||||
keyboardActions = KeyboardActions(onNext = { focusManager.moveFocus(FocusDirection.Next) })
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.height(8.dp))
|
||||
|
||||
OutlinedTextField(
|
||||
value = viewModel.what,
|
||||
onValueChange = { viewModel.what = it },
|
||||
enabled = canEdit,
|
||||
placeholder = { Text(stringResource(R.string.label_what)) },
|
||||
modifier = Modifier.fillMaxWidth(),
|
||||
leadingIcon = { Icon(Icons.Default.Title, contentDescription = null) },
|
||||
keyboardOptions = KeyboardOptions(imeAction = ImeAction.Next),
|
||||
keyboardActions = KeyboardActions(onNext = { focusManager.moveFocus(FocusDirection.Next) })
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.height(8.dp))
|
||||
@@ -357,34 +379,54 @@ fun OwerSelectionSection(
|
||||
)
|
||||
Spacer(Modifier.weight(1f))
|
||||
|
||||
if (viewModel.isCustomSplit) {
|
||||
if (viewModel.splitMode != SplitMode.EVEN) {
|
||||
val diff = viewModel.getDiffSplit()
|
||||
if (abs(diff) > 0.01) {
|
||||
val unit = if (viewModel.splitMode == SplitMode.PERCENT) "%" else ""
|
||||
val diffText =
|
||||
if (diff > 0) "Missing: ${SupportUtil.normalNumberFormat.format(diff)}" else "Excess: ${
|
||||
if (diff > 0) "Missing: ${SupportUtil.normalNumberFormat.format(diff)}$unit" else "Excess: ${
|
||||
SupportUtil.normalNumberFormat.format(-diff)
|
||||
}"
|
||||
}$unit"
|
||||
Text(
|
||||
diffText,
|
||||
color = MaterialTheme.colors.error,
|
||||
fontSize = 12.sp,
|
||||
modifier = Modifier.padding(horizontal = 16.dp)
|
||||
modifier = Modifier.padding(horizontal = 4.dp)
|
||||
)
|
||||
}
|
||||
} else {
|
||||
Text("Even Split", fontSize = 12.sp)
|
||||
}
|
||||
Switch(
|
||||
checked = !viewModel.isCustomSplit,
|
||||
enabled = canEdit,
|
||||
onCheckedChange = {
|
||||
viewModel.isCustomSplit = !it
|
||||
viewModel.updateSplits()
|
||||
},
|
||||
colors = SwitchDefaults.colors(
|
||||
uncheckedThumbColor = MaterialTheme.colors.onSurface,
|
||||
)
|
||||
)
|
||||
|
||||
val splitOptions = listOf(SplitMode.EVEN, SplitMode.CUSTOM, SplitMode.PERCENT)
|
||||
Row(
|
||||
modifier = Modifier
|
||||
.padding(start = 8.dp)
|
||||
.background(MaterialTheme.colors.onSurface.copy(alpha = 0.05f), MaterialTheme.shapes.small)
|
||||
) {
|
||||
splitOptions.forEach { mode ->
|
||||
val isSelected = viewModel.splitMode == mode
|
||||
Box(
|
||||
modifier = Modifier
|
||||
.clip(MaterialTheme.shapes.small)
|
||||
.background(if (isSelected) MaterialTheme.colors.primary else Color.Transparent)
|
||||
.clickable(enabled = canEdit) {
|
||||
viewModel.splitMode = mode
|
||||
viewModel.updateSplits()
|
||||
}
|
||||
.padding(horizontal = 8.dp, vertical = 4.dp)
|
||||
) {
|
||||
Text(
|
||||
text = when (mode) {
|
||||
SplitMode.EVEN -> "="
|
||||
SplitMode.CUSTOM -> "#"
|
||||
SplitMode.PERCENT -> "%"
|
||||
},
|
||||
color = if (isSelected) MaterialTheme.colors.onPrimary else MaterialTheme.colors.onSurface,
|
||||
fontSize = 14.sp,
|
||||
fontWeight = FontWeight.Bold
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
viewModel.members.forEach { member ->
|
||||
@@ -408,23 +450,39 @@ fun OwerSelectionSection(
|
||||
size = 32.dp
|
||||
)
|
||||
Spacer(modifier = Modifier.width(8.dp))
|
||||
Text(member.name, modifier = Modifier.weight(1f))
|
||||
val weightSuffix = if (viewModel.hasDifferentWeights && member.weight != 1.0) {
|
||||
" (x${member.weight.toString().removeSuffix(".0")})"
|
||||
} else ""
|
||||
Text("${member.name}$weightSuffix", modifier = Modifier.weight(1f))
|
||||
|
||||
if (isSelected || viewModel.isCustomSplit) {
|
||||
if (isSelected || viewModel.splitMode != SplitMode.EVEN) {
|
||||
val focusManager = LocalFocusManager.current
|
||||
val interactionSource = remember { MutableInteractionSource() }
|
||||
val value = if (viewModel.splitMode == SplitMode.PERCENT) {
|
||||
viewModel.owersPercentSplit[member.id] ?: ""
|
||||
} else {
|
||||
viewModel.owersCustomSplit[member.id] ?: ""
|
||||
}
|
||||
|
||||
BasicTextField(
|
||||
value = viewModel.owersCustomSplit[member.id] ?: "",
|
||||
onValueChange = {
|
||||
viewModel.owersCustomSplit[member.id] = it
|
||||
viewModel.owersSelection[member.id] = (it != "")
|
||||
value = value,
|
||||
onValueChange = { nv ->
|
||||
val filteredValue = nv.filter { it in "0123456789.+-*/" }
|
||||
if (viewModel.splitMode == SplitMode.PERCENT) {
|
||||
viewModel.owersPercentSplit[member.id] = filteredValue
|
||||
} else {
|
||||
viewModel.owersCustomSplit[member.id] = filteredValue
|
||||
}
|
||||
viewModel.owersSelection[member.id] = (filteredValue != "")
|
||||
},
|
||||
modifier = Modifier
|
||||
.width(80.dp)
|
||||
.height(46.dp),
|
||||
interactionSource = interactionSource,
|
||||
singleLine = true,
|
||||
enabled = viewModel.isCustomSplit && canEdit,
|
||||
keyboardOptions = KeyboardOptions(keyboardType = KeyboardType.Number),
|
||||
enabled = viewModel.splitMode != SplitMode.EVEN && canEdit,
|
||||
keyboardOptions = KeyboardOptions(keyboardType = KeyboardType.Number, imeAction = ImeAction.Next),
|
||||
keyboardActions = KeyboardActions(onNext = { focusManager.moveFocus(FocusDirection.Next) }),
|
||||
cursorBrush = SolidColor(MaterialTheme.colors.onSurface),
|
||||
textStyle = LocalTextStyle.current.copy(
|
||||
textAlign = TextAlign.Right,
|
||||
@@ -432,13 +490,13 @@ fun OwerSelectionSection(
|
||||
),
|
||||
) { innerTextField ->
|
||||
TextFieldDefaults.OutlinedTextFieldDecorationBox(
|
||||
value = viewModel.owersCustomSplit[member.id] ?: "",
|
||||
value = value,
|
||||
visualTransformation = VisualTransformation.None,
|
||||
innerTextField = innerTextField,
|
||||
singleLine = true,
|
||||
enabled = viewModel.isCustomSplit && canEdit,
|
||||
enabled = viewModel.splitMode != SplitMode.EVEN && canEdit,
|
||||
interactionSource = interactionSource,
|
||||
contentPadding = PaddingValues(horizontal = 12.dp, vertical = 0.dp),
|
||||
contentPadding = PaddingValues(horizontal = 8.dp, vertical = 0.dp),
|
||||
colors = TextFieldDefaults.textFieldColors(
|
||||
cursorColor = MaterialTheme.colors.onSurface,
|
||||
backgroundColor = Color.Transparent,
|
||||
@@ -616,19 +674,115 @@ fun BillAdditionalDetailsSection(
|
||||
}
|
||||
|
||||
@SuppressLint("ViewModelConstructorInComposable")
|
||||
@Preview(showBackground = true)
|
||||
@Preview(showBackground = true, name = "Standard Split")
|
||||
@Composable
|
||||
fun EditBillScreenPreview() {
|
||||
MaterialTheme {
|
||||
EditBillScreen(
|
||||
viewModel = EditBillViewModel().apply {
|
||||
what = "Pizza"
|
||||
amount = "12.50"
|
||||
amount = "12.00"
|
||||
mainCurrencyName = "EUR"
|
||||
members = listOf(
|
||||
DBMember(1, 0, 0, "Alice", true, 1.0, 0, null, null, null, null, null),
|
||||
DBMember(2, 0, 0, "Bob", true, 1.0, 0, null, null, null, null, null)
|
||||
)
|
||||
owersSelection[1] = true
|
||||
owersSelection[2] = true
|
||||
updateSplits()
|
||||
},
|
||||
categories = emptyList(),
|
||||
paymentModes = emptyList(),
|
||||
onSave = {},
|
||||
onBack = {},
|
||||
onDateClick = {},
|
||||
onTimeClick = {},
|
||||
onScan = {}
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressLint("ViewModelConstructorInComposable")
|
||||
@Preview(showBackground = true, name = "Weighted Split")
|
||||
@Composable
|
||||
fun EditBillScreenWeightedPreview() {
|
||||
MaterialTheme {
|
||||
EditBillScreen(
|
||||
viewModel = EditBillViewModel().apply {
|
||||
what = "Weighted Pizza"
|
||||
amount = "60.00"
|
||||
mainCurrencyName = "EUR"
|
||||
members = listOf(
|
||||
DBMember(1, 0, 0, "Alice", true, 2.0, 0, null, null, null, null, null),
|
||||
DBMember(2, 0, 0, "Bob", true, 1.0, 0, null, null, null, null, null),
|
||||
DBMember(3, 0, 0, "Charlie", true, 1.0, 0, null, null, null, null, null)
|
||||
)
|
||||
owersSelection[1] = true
|
||||
owersSelection[2] = true
|
||||
owersSelection[3] = true
|
||||
updateSplits()
|
||||
},
|
||||
categories = emptyList(),
|
||||
paymentModes = emptyList(),
|
||||
onSave = {},
|
||||
onBack = {},
|
||||
onDateClick = {},
|
||||
onTimeClick = {},
|
||||
onScan = {}
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressLint("ViewModelConstructorInComposable")
|
||||
@Preview(showBackground = true, name = "Custom Split (#)")
|
||||
@Composable
|
||||
fun EditBillScreenCustomPreview() {
|
||||
MaterialTheme {
|
||||
EditBillScreen(
|
||||
viewModel = EditBillViewModel().apply {
|
||||
what = "Custom Split Pizza"
|
||||
amount = "60.00"
|
||||
mainCurrencyName = "EUR"
|
||||
members = listOf(
|
||||
DBMember(1, 0, 0, "Alice", true, 1.0, 0, null, null, null, null, null),
|
||||
DBMember(2, 0, 0, "Bob", true, 1.0, 0, null, null, null, null, null)
|
||||
)
|
||||
splitMode = SplitMode.CUSTOM
|
||||
owersSelection[1] = true
|
||||
owersSelection[2] = true
|
||||
owersCustomSplit[1] = "40.00"
|
||||
owersCustomSplit[2] = "20.00"
|
||||
},
|
||||
categories = emptyList(),
|
||||
paymentModes = emptyList(),
|
||||
onSave = {},
|
||||
onBack = {},
|
||||
onDateClick = {},
|
||||
onTimeClick = {},
|
||||
onScan = {}
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressLint("ViewModelConstructorInComposable")
|
||||
@Preview(showBackground = true, name = "Percent Split (%)")
|
||||
@Composable
|
||||
fun EditBillScreenPercentPreview() {
|
||||
MaterialTheme {
|
||||
EditBillScreen(
|
||||
viewModel = EditBillViewModel().apply {
|
||||
what = "Percent Split Pizza"
|
||||
amount = "100.00"
|
||||
mainCurrencyName = "EUR"
|
||||
members = listOf(
|
||||
DBMember(1, 0, 0, "Alice", true, 1.0, 0, null, null, null, null, null),
|
||||
DBMember(2, 0, 0, "Bob", true, 1.0, 0, null, null, null, null, null)
|
||||
)
|
||||
splitMode = SplitMode.PERCENT
|
||||
owersSelection[1] = true
|
||||
owersSelection[2] = true
|
||||
owersPercentSplit[1] = "70"
|
||||
owersPercentSplit[2] = "30"
|
||||
},
|
||||
categories = emptyList(),
|
||||
paymentModes = emptyList(),
|
||||
|
||||
@@ -16,6 +16,10 @@ import net.helcel.cowspent.model.DBMember
|
||||
import net.helcel.cowspent.util.SupportUtil
|
||||
import net.helcel.cowspent.util.evalMath
|
||||
|
||||
enum class SplitMode {
|
||||
EVEN, CUSTOM, PERCENT
|
||||
}
|
||||
|
||||
class EditBillViewModel : ViewModel() {
|
||||
var what by mutableStateOf("")
|
||||
var amount by mutableStateOf("")
|
||||
@@ -34,48 +38,75 @@ class EditBillViewModel : ViewModel() {
|
||||
var members by mutableStateOf<List<DBMember>>(emptyList())
|
||||
|
||||
var owersSelection = mutableStateMapOf<Long, Boolean>()
|
||||
var isCustomSplit by mutableStateOf(false)
|
||||
var splitMode by mutableStateOf(SplitMode.EVEN)
|
||||
var owersCustomSplit = mutableStateMapOf<Long, String>()
|
||||
var owersPercentSplit = mutableStateMapOf<Long, String>()
|
||||
|
||||
var dialogState by mutableStateOf<DialogState?>(null)
|
||||
|
||||
val amountAsDouble: Double
|
||||
get() {
|
||||
return parseAmount(amount) ?: try {
|
||||
evalMath(amount.replace(',', '.'))
|
||||
} catch (_: Exception) {
|
||||
0.0
|
||||
}
|
||||
fun parseAmountFromUi(input: String): Double {
|
||||
if (input.isBlank()) return 0.0
|
||||
val sanitized = input.replace(',', '.')
|
||||
// If it contains any math operator, try evalMath first
|
||||
if (sanitized.any { it in "+-*/" }) {
|
||||
try {
|
||||
val result = evalMath(sanitized)
|
||||
if (result != 0.0) return SupportUtil.round2(result)
|
||||
} catch (_: Exception) {}
|
||||
}
|
||||
|
||||
fun getEvenSplit(): Double {
|
||||
val selectedOwersCount = owersSelection.count { it.value }
|
||||
return if (selectedOwersCount > 0) amountAsDouble / selectedOwersCount else 0.0
|
||||
val parsed = parseAmount(input) ?: 0.0
|
||||
return SupportUtil.round2(parsed)
|
||||
}
|
||||
|
||||
val amountAsDouble: Double
|
||||
get() = parseAmountFromUi(amount)
|
||||
|
||||
val hasDifferentWeights: Boolean
|
||||
get() = members.isNotEmpty() && members.any { it.weight != members[0].weight }
|
||||
|
||||
fun updateSplits() {
|
||||
if (!isCustomSplit) {
|
||||
val even = getEvenSplit()
|
||||
val evenStr = if (even == 0.0) "" else SupportUtil.round2(even).toString()
|
||||
if (splitMode == SplitMode.EVEN) {
|
||||
val selectedMembers = members.filter { owersSelection[it.id] == true }
|
||||
val totalWeight = selectedMembers.sumOf { it.weight }
|
||||
val uiAmount = amountAsDouble
|
||||
members.forEach { m ->
|
||||
if (owersSelection[m.id] == true) {
|
||||
owersCustomSplit[m.id] = evenStr
|
||||
val share = if (totalWeight > 0) (uiAmount * m.weight) / totalWeight else 0.0
|
||||
owersCustomSplit[m.id] = if (share == 0.0) "" else SupportUtil.round2(share).toString()
|
||||
} else {
|
||||
owersCustomSplit.remove(m.id)
|
||||
}
|
||||
}
|
||||
} else if (splitMode == SplitMode.PERCENT) {
|
||||
val selectedCount = owersSelection.count { it.value }
|
||||
if (selectedCount > 0) {
|
||||
val evenPercent = 100.0 / selectedCount
|
||||
val evenPercentStr = SupportUtil.round2(evenPercent).toString()
|
||||
members.forEach { m ->
|
||||
if (owersSelection[m.id] == true) {
|
||||
if (owersPercentSplit[m.id].isNullOrEmpty()) {
|
||||
owersPercentSplit[m.id] = evenPercentStr
|
||||
}
|
||||
} else {
|
||||
owersPercentSplit.remove(m.id)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun toggleMember(id: Long, selected: Boolean) {
|
||||
owersSelection[id] = selected
|
||||
if (isCustomSplit) {
|
||||
if (splitMode != SplitMode.EVEN) {
|
||||
if (selected) {
|
||||
if (owersCustomSplit[id].isNullOrEmpty()) {
|
||||
if (splitMode == SplitMode.CUSTOM && owersCustomSplit[id].isNullOrEmpty()) {
|
||||
owersCustomSplit[id] = "0"
|
||||
} else if (splitMode == SplitMode.PERCENT && owersPercentSplit[id].isNullOrEmpty()) {
|
||||
owersPercentSplit[id] = "0"
|
||||
}
|
||||
} else {
|
||||
owersCustomSplit.remove(id)
|
||||
owersPercentSplit.remove(id)
|
||||
}
|
||||
} else {
|
||||
updateSplits()
|
||||
@@ -83,10 +114,17 @@ class EditBillViewModel : ViewModel() {
|
||||
}
|
||||
|
||||
fun getDiffSplit(): Double {
|
||||
val customTotal = owersCustomSplit.entries
|
||||
.filter { owersSelection[it.key] == true }
|
||||
.sumOf { it.value.replace(',', '.').toDoubleOrNull() ?: 0.0 }
|
||||
return amountAsDouble - customTotal
|
||||
return if (splitMode == SplitMode.PERCENT) {
|
||||
val customTotal = owersPercentSplit.entries
|
||||
.filter { owersSelection[it.key] == true }
|
||||
.sumOf { parseAmountFromUi(it.value) }
|
||||
SupportUtil.round2(100.0 - customTotal)
|
||||
} else {
|
||||
val customTotal = owersCustomSplit.entries
|
||||
.filter { owersSelection[it.key] == true }
|
||||
.sumOf { parseAmountFromUi(it.value) }
|
||||
SupportUtil.round2(amountAsDouble - customTotal)
|
||||
}
|
||||
}
|
||||
|
||||
fun getOwersIds(): List<Long> {
|
||||
@@ -142,7 +180,7 @@ class EditBillViewModel : ViewModel() {
|
||||
}
|
||||
|
||||
fun getFinalAmount(): Double {
|
||||
return SupportUtil.round2(amountAsDouble / selectedCurrencyRate)
|
||||
return SupportUtil.round2(amountAsDouble * selectedCurrencyRate)
|
||||
}
|
||||
|
||||
fun getFinalComment(): String {
|
||||
@@ -204,37 +242,38 @@ class EditBillViewModel : ViewModel() {
|
||||
|
||||
owersSelection.clear()
|
||||
owersCustomSplit.clear()
|
||||
owersPercentSplit.clear()
|
||||
|
||||
if (customSplits != null) {
|
||||
isCustomSplit = true
|
||||
splitMode = SplitMode.CUSTOM
|
||||
for (member in members) {
|
||||
val selected = customSplits.containsKey(member.id)
|
||||
owersSelection[member.id] = selected
|
||||
if (selected) {
|
||||
// If we have metadata, the custom splits from DB are also converted.
|
||||
// We should show them as "Original" if possible?
|
||||
// Actually, if we use metadata, we should probably store original splits too,
|
||||
// but for now let's just reverse the rate for display.
|
||||
// Reverse calculation for display: UI Part = DB Part / Rate
|
||||
val dbPart = customSplits[member.id]!!
|
||||
val uiPart = if (selectedCurrencyRate != 1.0) dbPart * selectedCurrencyRate else dbPart
|
||||
val uiPart = if (selectedCurrencyRate != 0.0) dbPart / selectedCurrencyRate else dbPart
|
||||
owersCustomSplit[member.id] = SupportUtil.round2(uiPart).toString()
|
||||
}
|
||||
}
|
||||
} else {
|
||||
// Even split logic
|
||||
splitMode = SplitMode.EVEN
|
||||
val billOwerIds = bill.billOwersIds
|
||||
val selectedCount = billOwerIds.size
|
||||
val selectedMembers = members.filter { billOwerIds.contains(it.id) }
|
||||
val totalWeight = selectedMembers.sumOf { it.weight }
|
||||
|
||||
// Use UI amount for even split calculation
|
||||
val uiAmount = amountAsDouble
|
||||
val evenSplit = if (selectedCount > 0) uiAmount / selectedCount else 0.0
|
||||
val evenSplitStr = if (evenSplit == 0.0) "" else SupportUtil.round2(evenSplit).toString()
|
||||
|
||||
for (member in members) {
|
||||
val selected = billOwerIds.contains(member.id)
|
||||
owersSelection[member.id] = selected
|
||||
if (selected) {
|
||||
owersCustomSplit[member.id] = evenSplitStr
|
||||
val share = if (totalWeight > 0) (uiAmount * member.weight) / totalWeight else 0.0
|
||||
owersCustomSplit[member.id] = if (share == 0.0) "" else SupportUtil.round2(share).toString()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ import net.helcel.cowspent.model.DBBill
|
||||
import net.helcel.cowspent.model.ProjectType
|
||||
|
||||
class LabelBillsActivity : AppCompatActivity() {
|
||||
private val viewModel: LabelBillsViewModel by viewModels()
|
||||
internal val viewModel: LabelBillsViewModel by viewModels()
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
enableEdgeToEdge()
|
||||
|
||||
@@ -15,6 +15,7 @@ import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.graphics.Color
|
||||
import androidx.compose.ui.platform.LocalContext
|
||||
import androidx.compose.ui.platform.testTag
|
||||
import androidx.compose.ui.res.stringResource
|
||||
import androidx.compose.ui.text.font.FontWeight
|
||||
import androidx.compose.ui.text.style.TextAlign
|
||||
@@ -45,7 +46,10 @@ fun LabelBillsScreen(
|
||||
title = { Text(stringResource(R.string.title_label_bills)) },
|
||||
navigationIcon = {
|
||||
IconButton(onClick = onBack) {
|
||||
Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = null)
|
||||
Icon(
|
||||
Icons.AutoMirrored.Filled.ArrowBack,
|
||||
contentDescription = stringResource(R.string.simple_back)
|
||||
)
|
||||
}
|
||||
},
|
||||
backgroundColor = MaterialTheme.colors.primary,
|
||||
@@ -223,7 +227,10 @@ fun BillSummaryCard(bill: DBBill, members: List<DBMember>, remainingCount: Int)
|
||||
fun CategoryButton(icon: String, name: String, onClick: () -> Unit) {
|
||||
OutlinedButton(
|
||||
onClick = onClick,
|
||||
modifier = Modifier.fillMaxWidth().height(60.dp),
|
||||
modifier = Modifier
|
||||
.fillMaxWidth()
|
||||
.height(60.dp)
|
||||
.testTag("CategoryButton_$name"),
|
||||
contentPadding = PaddingValues(2.dp)
|
||||
) {
|
||||
Column(horizontalAlignment = Alignment.CenterHorizontally, verticalArrangement = Arrangement.Center) {
|
||||
|
||||
+25
-112
@@ -7,14 +7,8 @@ import androidx.activity.enableEdgeToEdge
|
||||
import androidx.activity.compose.setContent
|
||||
import androidx.activity.viewModels
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.launch
|
||||
import kotlinx.coroutines.withContext
|
||||
import net.helcel.cowspent.R
|
||||
import net.helcel.cowspent.android.helper.showToast
|
||||
import net.helcel.cowspent.model.DBBill
|
||||
import net.helcel.cowspent.model.DBCurrency
|
||||
import net.helcel.cowspent.model.ProjectType
|
||||
import net.helcel.cowspent.persistence.CowspentSQLiteOpenHelper
|
||||
import net.helcel.cowspent.theme.ThemeUtils
|
||||
@@ -23,9 +17,8 @@ import net.helcel.cowspent.util.ICallback
|
||||
|
||||
class ManageCurrenciesActivity : AppCompatActivity() {
|
||||
|
||||
private val viewModel: ManageCurrenciesViewModel by viewModels()
|
||||
internal val viewModel: ManageCurrenciesViewModel by viewModels()
|
||||
private var db: CowspentSQLiteOpenHelper? = null
|
||||
private var selectedProjectID: Long = -1
|
||||
|
||||
private val editMainCurrencyCallBack: ICallback = object : ICallback {
|
||||
override fun onFinish() {}
|
||||
@@ -47,125 +40,45 @@ class ManageCurrenciesActivity : AppCompatActivity() {
|
||||
enableEdgeToEdge()
|
||||
super.onCreate(savedInstanceState)
|
||||
|
||||
intent.extras?.let {
|
||||
selectedProjectID = it.getLong(EXTRA_PROJECT_ID)
|
||||
}
|
||||
val selectedProjectID = intent.getLongExtra(EXTRA_PROJECT_ID, -1L)
|
||||
if (selectedProjectID == -1L) {
|
||||
Log.e(TAG, "Missing project id")
|
||||
finish()
|
||||
return
|
||||
}
|
||||
|
||||
db = CowspentSQLiteOpenHelper.getInstance(this)
|
||||
|
||||
lifecycleScope.launch {
|
||||
val project = withContext(Dispatchers.IO) { db!!.getProject(selectedProjectID) }
|
||||
viewModel.mainCurrencyName = project?.currencyName?.let { if (it == "null") "" else it } ?: ""
|
||||
updateCurrenciesList()
|
||||
viewModel.projectId = selectedProjectID
|
||||
viewModel.loadCurrencies()
|
||||
|
||||
setContent {
|
||||
ThemeUtils.CowspentTheme {
|
||||
ManageCurrenciesScreen(
|
||||
viewModel = viewModel,
|
||||
onBack = { finish() },
|
||||
onSaveMain = { saveMainCurrency() },
|
||||
onAdd = { addOrUpdateCurrency() },
|
||||
onDelete = { deleteCurrency(it) },
|
||||
onEdit = { startEditing(it) },
|
||||
onCancelEdit = { cancelEditing() }
|
||||
)
|
||||
}
|
||||
db = CowspentSQLiteOpenHelper.getInstance(this)
|
||||
|
||||
setContent {
|
||||
ThemeUtils.CowspentTheme {
|
||||
ManageCurrenciesScreen(
|
||||
viewModel = viewModel,
|
||||
onBack = { finish() },
|
||||
onSaveMain = { saveMainCurrency() },
|
||||
onAdd = { viewModel.addCurrency() },
|
||||
onDelete = { viewModel.deleteCurrency(it.id) },
|
||||
onEdit = { viewModel.startEditing(it) },
|
||||
onCancelEdit = { viewModel.cancelEditing() }
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun saveMainCurrency() {
|
||||
val newMainCurrencyName = viewModel.mainCurrencyName
|
||||
lifecycleScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
db!!.updateProject(
|
||||
selectedProjectID, null, null, null,
|
||||
null, null, newMainCurrencyName,
|
||||
null, null, null
|
||||
)
|
||||
val project = db!!.getProject(selectedProjectID)
|
||||
if (project != null) {
|
||||
db!!.syncIfRemote(project)
|
||||
if (project.type == ProjectType.COSPEND) {
|
||||
withContext(Dispatchers.Main) {
|
||||
if (!db!!.cowspentServerSyncHelper
|
||||
.editRemoteProject(selectedProjectID, project.name, null, null, newMainCurrencyName, editMainCurrencyCallBack)
|
||||
) {
|
||||
showToast(this@ManageCurrenciesActivity, getString(R.string.remote_project_operation_no_network), Toast.LENGTH_LONG)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
withContext(Dispatchers.Main) {
|
||||
showToast(this@ManageCurrenciesActivity, getString(R.string.currency_saved_success), Toast.LENGTH_LONG)
|
||||
}
|
||||
}
|
||||
val project = db?.getProject(viewModel.projectId)
|
||||
if (project != null) {
|
||||
if (project.type == ProjectType.COSPEND) {
|
||||
if (!db!!.cowspentServerSyncHelper.isSyncPossible) {
|
||||
showToast(this, getString(R.string.remote_project_operation_no_network), Toast.LENGTH_LONG)
|
||||
}
|
||||
} else {
|
||||
showToast(this, getString(R.string.currency_saved_success), Toast.LENGTH_LONG)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun addOrUpdateCurrency() {
|
||||
val exchangeRate = try { viewModel.newCurrencyRate.toDouble() } catch (_: Exception) { 0.0 }
|
||||
val currencyName = viewModel.newCurrencyName
|
||||
val editingId = viewModel.editingCurrencyId
|
||||
|
||||
lifecycleScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
if (editingId != null) {
|
||||
db!!.updateCurrency(editingId, currencyName, exchangeRate)
|
||||
val currency = db!!.getCurrency(editingId)
|
||||
if (currency != null) {
|
||||
db!!.setCurrencyStateSync(editingId, DBBill.STATE_EDITED)
|
||||
}
|
||||
} else {
|
||||
val newCurrency = DBCurrency(
|
||||
0, 0, selectedProjectID,
|
||||
currencyName, exchangeRate, DBBill.STATE_ADDED
|
||||
)
|
||||
db!!.addCurrencyAndSync(newCurrency)
|
||||
}
|
||||
}
|
||||
cancelEditing()
|
||||
updateCurrenciesList()
|
||||
}
|
||||
}
|
||||
|
||||
private fun startEditing(currency: DBCurrency) {
|
||||
viewModel.editingCurrencyId = currency.id
|
||||
viewModel.newCurrencyName = currency.name ?: ""
|
||||
viewModel.newCurrencyRate = currency.exchangeRate.toString()
|
||||
}
|
||||
|
||||
private fun cancelEditing() {
|
||||
viewModel.editingCurrencyId = null
|
||||
viewModel.newCurrencyName = ""
|
||||
viewModel.newCurrencyRate = ""
|
||||
}
|
||||
|
||||
private fun deleteCurrency(currency: DBCurrency) {
|
||||
lifecycleScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
db!!.setCurrencyStateSync(currency.id, DBBill.STATE_DELETED)
|
||||
}
|
||||
updateCurrenciesList()
|
||||
}
|
||||
}
|
||||
|
||||
private suspend fun updateCurrenciesList() {
|
||||
val currenciesDB = withContext(Dispatchers.IO) {
|
||||
val list = db!!.getCurrenciesOfProjectWithState(selectedProjectID, DBBill.STATE_ADDED).toMutableList()
|
||||
list.addAll(db!!.getCurrenciesOfProjectWithState(selectedProjectID, DBBill.STATE_EDITED))
|
||||
list.addAll(db!!.getCurrenciesOfProjectWithState(selectedProjectID, DBBill.STATE_OK))
|
||||
list
|
||||
}
|
||||
withContext(Dispatchers.Main) {
|
||||
viewModel.currencies = currenciesDB
|
||||
}
|
||||
viewModel.saveMainCurrency(editMainCurrencyCallBack)
|
||||
}
|
||||
|
||||
override fun onSupportNavigateUp(): Boolean {
|
||||
|
||||
+16
-35
@@ -1,6 +1,7 @@
|
||||
package net.helcel.cowspent.android.currencies
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.app.Application
|
||||
import androidx.compose.foundation.BorderStroke
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.clickable
|
||||
@@ -41,6 +42,8 @@ import androidx.compose.runtime.LaunchedEffect
|
||||
import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.graphics.Color
|
||||
import androidx.compose.ui.platform.LocalContext
|
||||
import androidx.compose.ui.platform.testTag
|
||||
import androidx.compose.ui.res.stringResource
|
||||
import androidx.compose.ui.text.font.FontWeight
|
||||
import androidx.compose.ui.tooling.preview.Preview
|
||||
@@ -48,7 +51,7 @@ import androidx.compose.ui.unit.dp
|
||||
import androidx.compose.ui.unit.sp
|
||||
import kotlinx.coroutines.delay
|
||||
import net.helcel.cowspent.R
|
||||
import net.helcel.cowspent.android.helper.AlertDialog
|
||||
import net.helcel.cowspent.android.helper.StatefulAlertDialog
|
||||
import net.helcel.cowspent.android.helper.formatAmount
|
||||
import net.helcel.cowspent.model.DBCurrency
|
||||
import kotlin.time.Duration.Companion.milliseconds
|
||||
@@ -63,35 +66,10 @@ fun ManageCurrenciesScreen(
|
||||
onEdit: (DBCurrency) -> Unit,
|
||||
onCancelEdit: () -> Unit
|
||||
) {
|
||||
val dialogState = viewModel.dialogState
|
||||
if (dialogState != null) {
|
||||
AlertDialog(
|
||||
showDialog = true,
|
||||
onDismissRequest = { viewModel.dismissDialog() },
|
||||
title = dialogState.title,
|
||||
message = dialogState.message,
|
||||
icon = dialogState.icon,
|
||||
items = dialogState.items,
|
||||
positiveText = dialogState.positiveText,
|
||||
negativeText = dialogState.negativeText,
|
||||
neutralText = dialogState.neutralText,
|
||||
onConfirm = {
|
||||
dialogState.onConfirm?.invoke()
|
||||
viewModel.dismissDialog()
|
||||
},
|
||||
onCancel = {
|
||||
dialogState.onCancel?.invoke()
|
||||
viewModel.dismissDialog()
|
||||
},
|
||||
onNeutral = {
|
||||
dialogState.onNeutral?.invoke()
|
||||
viewModel.dismissDialog()
|
||||
}
|
||||
) {
|
||||
dialogState.onItemSelected?.invoke(it)
|
||||
viewModel.dismissDialog()
|
||||
}
|
||||
}
|
||||
StatefulAlertDialog(
|
||||
state = viewModel.dialogState,
|
||||
onDismissRequest = { viewModel.dismissDialog() }
|
||||
)
|
||||
|
||||
Scaffold(
|
||||
topBar = {
|
||||
@@ -216,7 +194,7 @@ fun ManageCurrenciesScreen(
|
||||
) {
|
||||
Icon(
|
||||
imageVector = if (isEditing) Icons.Default.Done else Icons.Default.Add,
|
||||
contentDescription = null,
|
||||
contentDescription = if (isEditing) "Done" else "Add",
|
||||
tint = if (viewModel.isAddEnabled()) {
|
||||
if (isEditing) MaterialTheme.colors.secondary else MaterialTheme.colors.primary
|
||||
} else MaterialTheme.colors.onSurface.copy(alpha = 0.2f)
|
||||
@@ -274,7 +252,9 @@ fun CurrencyRow(
|
||||
shape = RoundedCornerShape(12.dp),
|
||||
elevation = if (isEditing) 4.dp else 1.dp,
|
||||
border = if (isEditing) BorderStroke(1.dp, MaterialTheme.colors.secondary.copy(alpha = 0.5f)) else null,
|
||||
modifier = Modifier.fillMaxWidth()
|
||||
modifier = Modifier
|
||||
.fillMaxWidth()
|
||||
.testTag("CurrencyRow_${currency.name}")
|
||||
) {
|
||||
Row(
|
||||
modifier = Modifier
|
||||
@@ -304,7 +284,7 @@ fun CurrencyRow(
|
||||
modifier = Modifier.padding(horizontal = 8.dp)
|
||||
)
|
||||
Text(
|
||||
text = formatAmount(currency.exchangeRate),
|
||||
text = formatAmount(if (currency.exchangeRate != 0.0) 1.0 / currency.exchangeRate else 0.0),
|
||||
style = MaterialTheme.typography.body1,
|
||||
fontWeight = FontWeight.ExtraBold,
|
||||
color = if (isEditing) MaterialTheme.colors.secondary else MaterialTheme.colors.onSurface
|
||||
@@ -320,7 +300,7 @@ fun CurrencyRow(
|
||||
IconButton(onClick = onDelete) {
|
||||
Icon(
|
||||
imageVector = Icons.Default.Delete,
|
||||
contentDescription = null,
|
||||
contentDescription = "Delete",
|
||||
tint = MaterialTheme.colors.error.copy(alpha = 0.7f),
|
||||
modifier = Modifier.size(20.dp)
|
||||
)
|
||||
@@ -347,9 +327,10 @@ fun CurrencyRowPreview() {
|
||||
@Preview(showBackground = true)
|
||||
@Composable
|
||||
fun ManageCurrenciesScreenPreview() {
|
||||
val application = LocalContext.current.applicationContext as Application
|
||||
MaterialTheme {
|
||||
ManageCurrenciesScreen(
|
||||
viewModel = ManageCurrenciesViewModel().apply {
|
||||
viewModel = ManageCurrenciesViewModel(application).apply {
|
||||
mainCurrencyName = "EUR"
|
||||
currencies = listOf(
|
||||
DBCurrency(1, 0, 0, "USD", 1.1, 0),
|
||||
|
||||
+111
-2
@@ -1,14 +1,24 @@
|
||||
package net.helcel.cowspent.android.currencies
|
||||
|
||||
import android.app.Application
|
||||
import androidx.compose.runtime.getValue
|
||||
import androidx.compose.runtime.mutableStateOf
|
||||
import androidx.compose.runtime.setValue
|
||||
import androidx.compose.ui.graphics.vector.ImageVector
|
||||
import androidx.lifecycle.ViewModel
|
||||
import androidx.lifecycle.AndroidViewModel
|
||||
import androidx.lifecycle.viewModelScope
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.launch
|
||||
import kotlinx.coroutines.withContext
|
||||
import net.helcel.cowspent.android.helper.DialogState
|
||||
import net.helcel.cowspent.model.DBBill
|
||||
import net.helcel.cowspent.model.DBCurrency
|
||||
import net.helcel.cowspent.model.ProjectType
|
||||
import net.helcel.cowspent.persistence.CowspentSQLiteOpenHelper
|
||||
import net.helcel.cowspent.util.ICallback
|
||||
|
||||
class ManageCurrenciesViewModel : ViewModel() {
|
||||
class ManageCurrenciesViewModel(application: Application) : AndroidViewModel(application) {
|
||||
var projectId: Long = -1
|
||||
var mainCurrencyName by mutableStateOf("")
|
||||
var newCurrencyName by mutableStateOf("")
|
||||
var newCurrencyRate by mutableStateOf("")
|
||||
@@ -19,6 +29,105 @@ class ManageCurrenciesViewModel : ViewModel() {
|
||||
|
||||
var dialogState by mutableStateOf<DialogState?>(null)
|
||||
|
||||
private val db = CowspentSQLiteOpenHelper.getInstance(application)
|
||||
|
||||
fun loadCurrencies() {
|
||||
if (projectId == -1L) return
|
||||
viewModelScope.launch {
|
||||
val project = withContext(Dispatchers.IO) { db.getProject(projectId) }
|
||||
mainCurrencyName = project?.currencyName?.let { if (it == "null") "" else it } ?: ""
|
||||
updateCurrenciesList()
|
||||
}
|
||||
}
|
||||
|
||||
suspend fun updateCurrenciesList() {
|
||||
val currenciesDB = withContext(Dispatchers.IO) {
|
||||
val list = db.getCurrenciesOfProjectWithState(projectId, DBBill.STATE_ADDED).toMutableList()
|
||||
list.addAll(db.getCurrenciesOfProjectWithState(projectId, DBBill.STATE_EDITED))
|
||||
list.addAll(db.getCurrenciesOfProjectWithState(projectId, DBBill.STATE_OK))
|
||||
list
|
||||
}
|
||||
withContext(Dispatchers.Main) {
|
||||
currencies = currenciesDB
|
||||
}
|
||||
}
|
||||
|
||||
fun saveMainCurrency(callback: ICallback) {
|
||||
val newMainCurrencyName = mainCurrencyName
|
||||
viewModelScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
db.updateProject(
|
||||
projId = projectId,
|
||||
newCurrencyName = newMainCurrencyName
|
||||
)
|
||||
val project = db.getProject(projectId)
|
||||
if (project != null) {
|
||||
db.syncIfRemote(project)
|
||||
if (project.type == ProjectType.COSPEND) {
|
||||
withContext(Dispatchers.Main) {
|
||||
if (!db.cowspentServerSyncHelper
|
||||
.editRemoteProject(
|
||||
projId = projectId,
|
||||
newName = project.name,
|
||||
newMainCurrencyName = newMainCurrencyName,
|
||||
callback = callback
|
||||
)
|
||||
) {
|
||||
// Handled by activity showing toast
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun addCurrency() {
|
||||
val uiRate = try { newCurrencyRate.toDouble() } catch (_: Exception) { 0.0 }
|
||||
val exchangeRate = if (uiRate != 0.0) 1.0 / uiRate else 0.0
|
||||
val currencyName = newCurrencyName
|
||||
val editingId = editingCurrencyId
|
||||
|
||||
viewModelScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
if (editingId != null) {
|
||||
db.updateCurrency(editingId, currencyName, exchangeRate)
|
||||
db.setCurrencyStateSync(editingId, DBBill.STATE_EDITED)
|
||||
} else {
|
||||
val newCurrency = DBCurrency(
|
||||
0, 0, projectId,
|
||||
currencyName, exchangeRate, DBBill.STATE_ADDED
|
||||
)
|
||||
db.addCurrencyAndSync(newCurrency)
|
||||
}
|
||||
}
|
||||
cancelEditing()
|
||||
updateCurrenciesList()
|
||||
}
|
||||
}
|
||||
|
||||
fun deleteCurrency(currencyId: Long) {
|
||||
viewModelScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
db.setCurrencyStateSync(currencyId, DBBill.STATE_DELETED)
|
||||
}
|
||||
updateCurrenciesList()
|
||||
}
|
||||
}
|
||||
|
||||
fun startEditing(currency: DBCurrency) {
|
||||
editingCurrencyId = currency.id
|
||||
newCurrencyName = currency.name ?: ""
|
||||
val uiRate = if (currency.exchangeRate != 0.0) 1.0 / currency.exchangeRate else 0.0
|
||||
newCurrencyRate = uiRate.toString()
|
||||
}
|
||||
|
||||
fun cancelEditing() {
|
||||
editingCurrencyId = null
|
||||
newCurrencyName = ""
|
||||
newCurrencyRate = ""
|
||||
}
|
||||
|
||||
fun showDialog(
|
||||
title: String? = null,
|
||||
message: String? = null,
|
||||
|
||||
@@ -61,11 +61,7 @@ fun ColorPicker(
|
||||
var chroma by remember { mutableFloatStateOf(initialLch[1]) }
|
||||
var hue by remember { mutableFloatStateOf(initialLch[2]) }
|
||||
|
||||
val currentColorInt = remember(lightness, chroma, hue) {
|
||||
val color = mLCHtoRBG(lightness,chroma,hue)
|
||||
onColorChanged(color)
|
||||
color
|
||||
}
|
||||
val currentColorInt = remember(lightness, chroma, hue) { mLCHtoRBG(lightness, chroma, hue) }
|
||||
|
||||
val currentColor = Color(currentColorInt)
|
||||
|
||||
@@ -74,8 +70,9 @@ fun ColorPicker(
|
||||
var isHexValid by remember { mutableStateOf(true) }
|
||||
val interactionSource = remember { MutableInteractionSource() }
|
||||
|
||||
// Sync HEX with LCH
|
||||
// Report the colour, and keep the HEX field in step with the LCH sliders.
|
||||
LaunchedEffect(currentColorInt) {
|
||||
onColorChanged(currentColorInt)
|
||||
val newHex = "%06X".format(0xFFFFFF and currentColorInt)
|
||||
if (hexText.uppercase() != newHex) {
|
||||
hexText = newHex
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package net.helcel.cowspent.android.helper
|
||||
|
||||
import android.graphics.*
|
||||
import android.graphics.drawable.Drawable
|
||||
import android.graphics.Color
|
||||
import java.security.MessageDigest
|
||||
import java.security.NoSuchAlgorithmException
|
||||
import java.util.*
|
||||
@@ -11,209 +10,143 @@ import kotlin.math.round
|
||||
import kotlin.math.sqrt
|
||||
|
||||
/**
|
||||
* A Drawable object that draws text (1 character) on top of a circular/filled background.
|
||||
* The color a member's avatar gets, derived from their name.
|
||||
*/
|
||||
class TextDrawable private constructor(
|
||||
private val mText: String,
|
||||
r: Int,
|
||||
g: Int,
|
||||
b: Int,
|
||||
private val mRadius: Float,
|
||||
private val mDisabled: Boolean
|
||||
) : Drawable() {
|
||||
private val mTextPaint: Paint = Paint()
|
||||
private val mBackground: Paint = Paint()
|
||||
private val mDisabledCircle: Paint = Paint()
|
||||
object TextDrawable {
|
||||
private const val INDEX_RED = 0
|
||||
private const val INDEX_GREEN = 1
|
||||
private const val INDEX_BLUE = 2
|
||||
private const val INDEX_HUE = 0
|
||||
private const val INDEX_SATURATION = 1
|
||||
private const val INDEX_LUMINATION = 2
|
||||
|
||||
init {
|
||||
mBackground.style = Paint.Style.FILL
|
||||
mBackground.isAntiAlias = true
|
||||
mBackground.color = Color.rgb(r, g, b)
|
||||
|
||||
if ((r + g + b) / 3 < 220) {
|
||||
mTextPaint.color = Color.WHITE
|
||||
} else {
|
||||
mTextPaint.color = Color.BLACK
|
||||
fun getColorFromName(name: String): Int {
|
||||
return try {
|
||||
val hsl = calculateHSL(name)
|
||||
val rgb = hslToRgb(hsl[0].toFloat(), hsl[1].toFloat(), hsl[2].toFloat(), 1f)
|
||||
Color.rgb(rgb[0], rgb[1], rgb[2])
|
||||
} catch (_: NoSuchAlgorithmException) {
|
||||
Color.WHITE
|
||||
}
|
||||
mTextPaint.textSize = mRadius
|
||||
mTextPaint.isAntiAlias = true
|
||||
mTextPaint.textAlign = Paint.Align.CENTER
|
||||
|
||||
mDisabledCircle.style = Paint.Style.STROKE
|
||||
mDisabledCircle.strokeWidth = mRadius * 0.2f
|
||||
mDisabledCircle.isAntiAlias = true
|
||||
mDisabledCircle.color = Color.DKGRAY
|
||||
}
|
||||
|
||||
override fun draw(canvas: Canvas) {
|
||||
canvas.drawCircle(mRadius, mRadius, mRadius, mBackground)
|
||||
canvas.drawText(
|
||||
mText,
|
||||
mRadius,
|
||||
mRadius - (mTextPaint.descent() + mTextPaint.ascent()) / 2,
|
||||
mTextPaint
|
||||
@Throws(NoSuchAlgorithmException::class)
|
||||
private fun calculateHSL(name: String): IntArray {
|
||||
val result = arrayOf("0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0")
|
||||
val rgb = doubleArrayOf(0.0, 0.0, 0.0)
|
||||
var sat = 70
|
||||
val lum = 68
|
||||
val modulo = 16
|
||||
|
||||
var hash = name.lowercase(Locale.ROOT).replace("[^0-9a-f]".toRegex(), "")
|
||||
if (!hash.matches("^[0-9a-f]{32}$".toRegex())) {
|
||||
hash = md5(hash)
|
||||
}
|
||||
|
||||
for (i in hash.indices) {
|
||||
result[i % modulo] = (result[i % modulo].toInt() + hash.substring(i, i + 1).toInt(16)).toString()
|
||||
}
|
||||
|
||||
for (count in 1 until modulo) {
|
||||
rgb[count % 3] += result[count].toDouble()
|
||||
}
|
||||
|
||||
rgb[INDEX_RED] = rgb[INDEX_RED] % 255
|
||||
rgb[INDEX_GREEN] = rgb[INDEX_GREEN] % 255
|
||||
rgb[INDEX_BLUE] = rgb[INDEX_BLUE] % 255
|
||||
|
||||
val hsl = rgbToHsl(rgb[INDEX_RED], rgb[INDEX_GREEN], rgb[INDEX_BLUE])
|
||||
|
||||
val bright = sqrt(
|
||||
0.299 * rgb[INDEX_RED].pow(2.0) + 0.587 * rgb[INDEX_GREEN].pow(2.0) + 0.114 * rgb[INDEX_BLUE].pow(2.0)
|
||||
)
|
||||
if (mDisabled) {
|
||||
canvas.drawCircle(mRadius, mRadius, mRadius * 0.9f, mDisabledCircle)
|
||||
canvas.drawLine(
|
||||
mRadius * 0.4f,
|
||||
mRadius * 1.6f,
|
||||
mRadius * 1.6f,
|
||||
mRadius * 0.4f,
|
||||
mDisabledCircle
|
||||
)
|
||||
|
||||
if (bright >= 200) {
|
||||
sat = 60
|
||||
}
|
||||
|
||||
return intArrayOf((hsl[INDEX_HUE] * 360).toInt(), sat, lum)
|
||||
}
|
||||
|
||||
override fun setAlpha(alpha: Int) {
|
||||
mTextPaint.alpha = alpha
|
||||
private fun hslToRgb(hParam: Float, sParam: Float, lParam: Float, alpha: Float): IntArray {
|
||||
var h = hParam
|
||||
var s = sParam
|
||||
var l = lParam
|
||||
if (s !in 0.0f..100.0f) {
|
||||
throw IllegalArgumentException("Color parameter outside of expected range - Saturation")
|
||||
}
|
||||
if (l !in 0.0f..100.0f) {
|
||||
throw IllegalArgumentException("Color parameter outside of expected range - Luminance")
|
||||
}
|
||||
if (alpha !in 0.0f..1.0f) {
|
||||
throw IllegalArgumentException("Color parameter outside of expected range - Alpha")
|
||||
}
|
||||
|
||||
h %= 360.0f
|
||||
h /= 360f
|
||||
s /= 100f
|
||||
l /= 100f
|
||||
|
||||
val q = if (l < 0.5) {
|
||||
l * (1 + s)
|
||||
} else {
|
||||
(l + s) - s * l
|
||||
}
|
||||
val p = 2 * l - q
|
||||
val r = round(max(0f, hueToRgb(p, q, h + 1.0f / 3.0f)) * 256).toInt()
|
||||
val g = round(max(0f, hueToRgb(p, q, h)) * 256).toInt()
|
||||
val b = round(max(0f, hueToRgb(p, q, h - 1.0f / 3.0f)) * 256).toInt()
|
||||
return intArrayOf(r, g, b)
|
||||
}
|
||||
|
||||
override fun setColorFilter(cf: ColorFilter?) {
|
||||
mTextPaint.colorFilter = cf
|
||||
private fun hueToRgb(p: Float, q: Float, hParam: Float): Float {
|
||||
var h = hParam
|
||||
if (h < 0) h += 1f
|
||||
if (h > 1) h -= 1f
|
||||
if (6 * h < 1) return p + (q - p) * 6 * h
|
||||
if (2 * h < 1) return q
|
||||
if (3 * h < 2) return p + (q - p) * 6 * (2.0f / 3.0f - h)
|
||||
return p
|
||||
}
|
||||
|
||||
@Deprecated("Deprecated in Java")
|
||||
override fun getOpacity(): Int {
|
||||
return PixelFormat.TRANSLUCENT
|
||||
}
|
||||
|
||||
companion object {
|
||||
private const val INDEX_RED = 0
|
||||
private const val INDEX_GREEN = 1
|
||||
private const val INDEX_BLUE = 2
|
||||
private const val INDEX_HUE = 0
|
||||
private const val INDEX_SATURATION = 1
|
||||
private const val INDEX_LUMINATION = 2
|
||||
|
||||
fun getColorFromName(name: String): Int {
|
||||
return try {
|
||||
val hsl = calculateHSL(name)
|
||||
val rgb = hslToRgb(hsl[0].toFloat(), hsl[1].toFloat(), hsl[2].toFloat(), 1f)
|
||||
Color.rgb(rgb[0], rgb[1], rgb[2])
|
||||
} catch (_: NoSuchAlgorithmException) {
|
||||
Color.WHITE
|
||||
}
|
||||
}
|
||||
|
||||
@Throws(NoSuchAlgorithmException::class)
|
||||
private fun calculateHSL(name: String): IntArray {
|
||||
val result = arrayOf("0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0", "0")
|
||||
val rgb = doubleArrayOf(0.0, 0.0, 0.0)
|
||||
var sat = 70
|
||||
val lum = 68
|
||||
val modulo = 16
|
||||
|
||||
var hash = name.lowercase(Locale.ROOT).replace("[^0-9a-f]".toRegex(), "")
|
||||
if (!hash.matches("^[0-9a-f]{32}$".toRegex())) {
|
||||
hash = md5(hash)
|
||||
}
|
||||
|
||||
for (i in hash.indices) {
|
||||
result[i % modulo] = (result[i % modulo].toInt() + hash.substring(i, i + 1).toInt(16)).toString()
|
||||
}
|
||||
|
||||
for (count in 1 until modulo) {
|
||||
rgb[count % 3] += result[count].toDouble()
|
||||
}
|
||||
|
||||
rgb[INDEX_RED] = rgb[INDEX_RED] % 255
|
||||
rgb[INDEX_GREEN] = rgb[INDEX_GREEN] % 255
|
||||
rgb[INDEX_BLUE] = rgb[INDEX_BLUE] % 255
|
||||
|
||||
val hsl = rgbToHsl(rgb[INDEX_RED], rgb[INDEX_GREEN], rgb[INDEX_BLUE])
|
||||
|
||||
val bright = sqrt(
|
||||
0.299 * rgb[INDEX_RED].pow(2.0) + 0.587 * rgb[INDEX_GREEN].pow(2.0) + 0.114 * rgb[INDEX_BLUE].pow(2.0)
|
||||
)
|
||||
|
||||
if (bright >= 200) {
|
||||
sat = 60
|
||||
}
|
||||
|
||||
return intArrayOf((hsl[INDEX_HUE] * 360).toInt(), sat, lum)
|
||||
}
|
||||
|
||||
private fun hslToRgb(hParam: Float, sParam: Float, lParam: Float, alpha: Float): IntArray {
|
||||
var h = hParam
|
||||
var s = sParam
|
||||
var l = lParam
|
||||
if (s !in 0.0f..100.0f) {
|
||||
throw IllegalArgumentException("Color parameter outside of expected range - Saturation")
|
||||
}
|
||||
if (l !in 0.0f..100.0f) {
|
||||
throw IllegalArgumentException("Color parameter outside of expected range - Luminance")
|
||||
}
|
||||
if (alpha !in 0.0f..1.0f) {
|
||||
throw IllegalArgumentException("Color parameter outside of expected range - Alpha")
|
||||
}
|
||||
|
||||
h %= 360.0f
|
||||
h /= 360f
|
||||
s /= 100f
|
||||
l /= 100f
|
||||
|
||||
val q = if (l < 0.5) {
|
||||
l * (1 + s)
|
||||
} else {
|
||||
(l + s) - s * l
|
||||
}
|
||||
val p = 2 * l - q
|
||||
val r = round(max(0f, hueToRgb(p, q, h + 1.0f / 3.0f)) * 256).toInt()
|
||||
val g = round(max(0f, hueToRgb(p, q, h)) * 256).toInt()
|
||||
val b = round(max(0f, hueToRgb(p, q, h - 1.0f / 3.0f)) * 256).toInt()
|
||||
return intArrayOf(r, g, b)
|
||||
}
|
||||
|
||||
private fun hueToRgb(p: Float, q: Float, hParam: Float): Float {
|
||||
var h = hParam
|
||||
if (h < 0) h += 1f
|
||||
if (h > 1) h -= 1f
|
||||
if (6 * h < 1) return p + (q - p) * 6 * h
|
||||
if (2 * h < 1) return q
|
||||
if (3 * h < 2) return p + (q - p) * 6 * (2.0f / 3.0f - h)
|
||||
return p
|
||||
}
|
||||
|
||||
private fun rgbToHsl(rUntrimmed: Double, gUntrimmed: Double, bUntrimmed: Double): DoubleArray {
|
||||
val r = rUntrimmed / 255
|
||||
val g = gUntrimmed / 255
|
||||
val b = bUntrimmed / 255
|
||||
val max = max(r, max(g, b))
|
||||
val min = r.coerceAtMost(g.coerceAtMost(b))
|
||||
var h = (max + min) / 2
|
||||
val s: Double
|
||||
val l = (max + min) / 2
|
||||
if (max == min) {
|
||||
s = 0.0
|
||||
h = s // achromatic
|
||||
} else {
|
||||
val d = max - min
|
||||
s = if (l > 0.5) d / (2 - max - min) else d / (max + min)
|
||||
when (max) {
|
||||
r -> {
|
||||
h = (g - b) / d + (if (g < b) 6 else 0)
|
||||
}
|
||||
g -> {
|
||||
h = (b - r) / d + 2
|
||||
}
|
||||
b -> {
|
||||
h = (r - g) / d + 4
|
||||
}
|
||||
private fun rgbToHsl(rUntrimmed: Double, gUntrimmed: Double, bUntrimmed: Double): DoubleArray {
|
||||
val r = rUntrimmed / 255
|
||||
val g = gUntrimmed / 255
|
||||
val b = bUntrimmed / 255
|
||||
val max = max(r, max(g, b))
|
||||
val min = r.coerceAtMost(g.coerceAtMost(b))
|
||||
var h = (max + min) / 2
|
||||
val s: Double
|
||||
val l = (max + min) / 2
|
||||
if (max == min) {
|
||||
s = 0.0
|
||||
h = s // achromatic
|
||||
} else {
|
||||
val d = max - min
|
||||
s = if (l > 0.5) d / (2 - max - min) else d / (max + min)
|
||||
when (max) {
|
||||
r -> {
|
||||
h = (g - b) / d + (if (g < b) 6 else 0)
|
||||
}
|
||||
g -> {
|
||||
h = (b - r) / d + 2
|
||||
}
|
||||
b -> {
|
||||
h = (r - g) / d + 4
|
||||
}
|
||||
h /= 6.0
|
||||
}
|
||||
val hsl = DoubleArray(3)
|
||||
hsl[INDEX_HUE] = h
|
||||
hsl[INDEX_SATURATION] = s
|
||||
hsl[INDEX_LUMINATION] = l
|
||||
return hsl
|
||||
h /= 6.0
|
||||
}
|
||||
val hsl = DoubleArray(3)
|
||||
hsl[INDEX_HUE] = h
|
||||
hsl[INDEX_SATURATION] = s
|
||||
hsl[INDEX_LUMINATION] = l
|
||||
return hsl
|
||||
}
|
||||
|
||||
@Throws(NoSuchAlgorithmException::class)
|
||||
private fun md5(string: String): String {
|
||||
val md5 = MessageDigest.getInstance("MD5").digest(string.toByteArray())
|
||||
return md5.joinToString("") { "%02x".format(it) }
|
||||
}
|
||||
@Throws(NoSuchAlgorithmException::class)
|
||||
private fun md5(string: String): String {
|
||||
val md5 = MessageDigest.getInstance("MD5").digest(string.toByteArray())
|
||||
return md5.joinToString("") { "%02x".format(it) }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ import androidx.appcompat.app.AppCompatActivity
|
||||
import net.helcel.cowspent.theme.ThemeUtils
|
||||
|
||||
class LabelManagementActivity : AppCompatActivity() {
|
||||
private val viewModel: LabelManagementViewModel by viewModels()
|
||||
internal val viewModel: LabelManagementViewModel by viewModels()
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
enableEdgeToEdge()
|
||||
|
||||
@@ -3,6 +3,7 @@ package net.helcel.cowspent.android.label
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.clickable
|
||||
import androidx.compose.foundation.layout.*
|
||||
import androidx.compose.ui.window.Dialog
|
||||
import androidx.compose.foundation.lazy.LazyColumn
|
||||
import androidx.compose.foundation.lazy.items
|
||||
import androidx.compose.foundation.rememberScrollState
|
||||
@@ -90,7 +91,7 @@ fun LabelManagementScreenContent(
|
||||
title = { Text(stringResource(R.string.title_labels)) },
|
||||
navigationIcon = {
|
||||
IconButton(onClick = onBack) {
|
||||
Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = null)
|
||||
Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = stringResource(R.string.simple_back))
|
||||
}
|
||||
},
|
||||
backgroundColor = MaterialTheme.colors.primary,
|
||||
@@ -107,7 +108,7 @@ fun LabelManagementScreenContent(
|
||||
showEditDialog = true
|
||||
}
|
||||
}) {
|
||||
Icon(Icons.Default.Add, contentDescription = null)
|
||||
Icon(Icons.Default.Add, contentDescription = "Add Label")
|
||||
}
|
||||
}
|
||||
) { padding ->
|
||||
@@ -267,14 +268,22 @@ fun LabelItem(
|
||||
Spacer(modifier = Modifier.width(32.dp))
|
||||
Text(text = name, modifier = Modifier.weight(1f), style = MaterialTheme.typography.subtitle1)
|
||||
IconButton(onClick = onEdit) {
|
||||
Icon(Icons.Default.Edit, contentDescription = null, tint = MaterialTheme.colors.onSurface.copy(alpha = 0.6f))
|
||||
Icon(Icons.Default.Edit, contentDescription = stringResource(R.string.action_edit), tint = MaterialTheme.colors.onSurface.copy(alpha = 0.6f))
|
||||
}
|
||||
IconButton(onClick = onDelete) {
|
||||
Icon(Icons.Default.Delete, contentDescription = null, tint = MaterialTheme.colors.error.copy(alpha = 0.6f))
|
||||
Icon(Icons.Default.Delete, contentDescription = stringResource(R.string.action_delete), tint = MaterialTheme.colors.error.copy(alpha = 0.6f))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Split into a window and its content, the same way MemberEditDialogContent is.
|
||||
*
|
||||
* A Compose text field inside a Material AlertDialog never reaches idle under Robolectric: the
|
||||
* composition spins in measure/layout until Espresso gives up 60s later, having exhausted the
|
||||
* test heap and taken every later test class in that worker with it. A plain Dialog holding a
|
||||
* Surface behaves, so the dialog body lives there instead - which is also what makes it testable.
|
||||
*/
|
||||
@Composable
|
||||
fun EditLabelDialog(
|
||||
title: String,
|
||||
@@ -283,15 +292,33 @@ fun EditLabelDialog(
|
||||
initialColor: String,
|
||||
onDismiss: () -> Unit,
|
||||
onSave: (String, String, String) -> Unit
|
||||
) {
|
||||
Dialog(onDismissRequest = onDismiss) {
|
||||
EditLabelDialogContent(title, initialName, initialIcon, initialColor, onDismiss, onSave)
|
||||
}
|
||||
}
|
||||
|
||||
@Composable
|
||||
fun EditLabelDialogContent(
|
||||
title: String,
|
||||
initialName: String,
|
||||
initialIcon: String,
|
||||
initialColor: String,
|
||||
onDismiss: () -> Unit,
|
||||
onSave: (String, String, String) -> Unit
|
||||
) {
|
||||
var name by remember { mutableStateOf(initialName) }
|
||||
var icon by remember { mutableStateOf(initialIcon) }
|
||||
var color by remember { mutableStateOf(initialColor) }
|
||||
|
||||
AlertDialog(
|
||||
onDismissRequest = onDismiss,
|
||||
title = { Text(title) },
|
||||
text = {
|
||||
Surface(
|
||||
shape = MaterialTheme.shapes.medium,
|
||||
color = MaterialTheme.colors.surface,
|
||||
contentColor = contentColorFor(MaterialTheme.colors.surface)
|
||||
) {
|
||||
Column(modifier = Modifier.padding(24.dp)) {
|
||||
Text(title, style = MaterialTheme.typography.h6)
|
||||
Spacer(modifier = Modifier.height(16.dp))
|
||||
Column(modifier = Modifier.verticalScroll(rememberScrollState())) {
|
||||
OutlinedTextField(
|
||||
value = name,
|
||||
@@ -315,21 +342,25 @@ fun EditLabelDialog(
|
||||
onColorChanged = { color = String.format("#%06X", 0xFFFFFF and it) }
|
||||
)
|
||||
}
|
||||
},
|
||||
confirmButton = {
|
||||
Button(
|
||||
onClick = { onSave(name, icon, color) },
|
||||
enabled = name.isNotBlank()
|
||||
Spacer(modifier = Modifier.height(16.dp))
|
||||
Row(
|
||||
modifier = Modifier.fillMaxWidth(),
|
||||
horizontalArrangement = Arrangement.End,
|
||||
verticalAlignment = Alignment.CenterVertically
|
||||
) {
|
||||
Text(stringResource(R.string.action_save))
|
||||
}
|
||||
},
|
||||
dismissButton = {
|
||||
TextButton(onClick = onDismiss) {
|
||||
Text(stringResource(R.string.simple_cancel))
|
||||
TextButton(onClick = onDismiss) {
|
||||
Text(stringResource(R.string.simple_cancel))
|
||||
}
|
||||
Spacer(modifier = Modifier.width(8.dp))
|
||||
Button(
|
||||
onClick = { onSave(name, icon, color) },
|
||||
enabled = name.isNotBlank()
|
||||
) {
|
||||
Text(stringResource(R.string.action_save))
|
||||
}
|
||||
}
|
||||
}
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
fun parseColor(colorString: String): Color {
|
||||
|
||||
@@ -4,8 +4,10 @@ import android.annotation.SuppressLint
|
||||
import android.content.Intent
|
||||
import androidx.compose.foundation.layout.Box
|
||||
import androidx.compose.foundation.layout.Column
|
||||
import androidx.compose.foundation.layout.Spacer
|
||||
import androidx.compose.foundation.layout.fillMaxSize
|
||||
import androidx.compose.foundation.layout.fillMaxWidth
|
||||
import androidx.compose.foundation.layout.height
|
||||
import androidx.compose.foundation.layout.padding
|
||||
import androidx.compose.foundation.lazy.LazyColumn
|
||||
import androidx.compose.foundation.lazy.items
|
||||
@@ -291,7 +293,7 @@ fun BillsListScreen(
|
||||
isSearchExpanded = false
|
||||
viewModel.searchQuery = ""
|
||||
}) {
|
||||
Icon(Icons.Default.Close, contentDescription = null, tint = MaterialTheme.colors.onPrimary)
|
||||
Icon(Icons.Default.Close, contentDescription = stringResource(R.string.action_clear_search), tint = MaterialTheme.colors.onPrimary)
|
||||
}
|
||||
}
|
||||
)
|
||||
@@ -320,13 +322,13 @@ fun BillsListScreen(
|
||||
isSearchExpanded = false
|
||||
viewModel.searchQuery = ""
|
||||
}) {
|
||||
Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = null)
|
||||
Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = stringResource(R.string.action_close_search))
|
||||
}
|
||||
} else {
|
||||
IconButton(onClick = {
|
||||
scope.launch { scaffoldState.drawerState.open() }
|
||||
}) {
|
||||
Icon(Icons.Default.Menu, contentDescription = null)
|
||||
Icon(Icons.Default.Menu, contentDescription = stringResource(R.string.action_open_menu))
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -341,7 +343,10 @@ fun BillsListScreen(
|
||||
}
|
||||
}
|
||||
IconButton(onClick = { isSearchExpanded = true }) {
|
||||
Icon(Icons.Default.Search, contentDescription = null)
|
||||
Icon(
|
||||
Icons.Default.Search,
|
||||
contentDescription = stringResource(R.string.action_search)
|
||||
)
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -417,6 +422,9 @@ fun BillsListScreen(
|
||||
is SectionItem -> SectionHeader(item.title)
|
||||
}
|
||||
}
|
||||
item {
|
||||
Spacer(modifier = Modifier.height(64.dp).fillMaxWidth())
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -88,6 +88,7 @@ object BillsListUtils {
|
||||
shareIntent,
|
||||
context.getString(R.string.title_settle)
|
||||
)
|
||||
chooserIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
|
||||
context.startActivity(chooserIntent)
|
||||
}
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ import android.app.SearchManager
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.content.SharedPreferences
|
||||
import android.content.IntentFilter
|
||||
import android.graphics.BitmapFactory
|
||||
import android.net.Uri
|
||||
@@ -18,6 +19,7 @@ import androidx.activity.compose.setContent
|
||||
import androidx.activity.enableEdgeToEdge
|
||||
import androidx.activity.result.contract.ActivityResultContracts
|
||||
import androidx.activity.viewModels
|
||||
import androidx.annotation.VisibleForTesting
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.appcompat.view.ActionMode
|
||||
import androidx.compose.material.icons.Icons
|
||||
@@ -53,7 +55,9 @@ import net.helcel.cowspent.util.CospendClientUtil
|
||||
import net.helcel.cowspent.util.ExportUtil
|
||||
import net.helcel.cowspent.util.ICallback
|
||||
import net.helcel.cowspent.util.IRefreshBillsListCallback
|
||||
import net.helcel.cowspent.util.SyncSettings
|
||||
import net.helcel.cowspent.util.SupportUtil
|
||||
import net.helcel.cowspent.util.VersatileProjectSyncClient
|
||||
import java.io.IOException
|
||||
import java.text.SimpleDateFormat
|
||||
import java.util.Calendar
|
||||
@@ -63,13 +67,16 @@ class BillsListViewActivity :
|
||||
AppCompatActivity(),
|
||||
IRefreshBillsListCallback {
|
||||
|
||||
private val viewModel: BillsListViewModel by viewModels()
|
||||
internal val viewModel: BillsListViewModel by viewModels()
|
||||
|
||||
companion object {
|
||||
var DEBUG = false
|
||||
|
||||
private val TAG = BillsListViewActivity::class.java.simpleName
|
||||
|
||||
// Opening a project only re-syncs it if it has not synced within this window.
|
||||
private const val SELECTED_PROJECT_SYNC_INTERVAL_MS = 60 * 1000L
|
||||
|
||||
private const val SAVED_STATE_NAVIGATION_SELECTION = "navigationSelection"
|
||||
private const val SAVED_STATE_NAVIGATION_OPEN = "navigationOpen"
|
||||
|
||||
@@ -276,7 +283,7 @@ class BillsListViewActivity :
|
||||
labelBillsLauncher.launch(LabelBillsActivity.createIntent(this, selectedProjectId))
|
||||
}
|
||||
},
|
||||
onRefresh = { synchronize(true) }
|
||||
onRefresh = { synchronize(SyncTrigger.MANUAL) }
|
||||
)
|
||||
}
|
||||
}
|
||||
@@ -330,10 +337,7 @@ class BillsListViewActivity :
|
||||
}
|
||||
viewModel.isRefreshing = false
|
||||
|
||||
if (db.cowspentServerSyncHelper.isSyncPossible) {
|
||||
db.cowspentServerSyncHelper.addCallbackPull(syncCallBack)
|
||||
synchronize()
|
||||
}
|
||||
synchronize(SyncTrigger.APP_OPEN)
|
||||
|
||||
registerBroadcastReceiver()
|
||||
updateAvatarInDrawer(CowspentServerSyncHelper.isNextcloudAccountConfigured(this))
|
||||
@@ -347,6 +351,9 @@ class BillsListViewActivity :
|
||||
} catch (_: RuntimeException) {
|
||||
if (DEBUG) Log.d(TAG, "RECEIVER PROBLEM, let's ignore it...")
|
||||
}
|
||||
// The helper outlives the activity, and it only drains its pull callbacks when a task
|
||||
// starts; drop ours so a paused activity is not retained by it.
|
||||
db.cowspentServerSyncHelper.removeCallbackPull(syncCallBack)
|
||||
isActivityVisible = false
|
||||
}
|
||||
|
||||
@@ -373,7 +380,7 @@ class BillsListViewActivity :
|
||||
navigationSelection = Category(null, null)
|
||||
refreshLists(true)
|
||||
|
||||
synchronize()
|
||||
synchronize(SyncTrigger.PROJECT_OPEN)
|
||||
}
|
||||
|
||||
fun onManageProjectClick(projectId: Long) {
|
||||
@@ -401,12 +408,14 @@ class BillsListViewActivity :
|
||||
lifecycleScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
db.deleteProject(projectId)
|
||||
PreferenceManager.getDefaultSharedPreferences(applicationContext)
|
||||
.edit { remove(lastProjectSyncKey(projectId)) }
|
||||
val dbProjects = db.projects
|
||||
if (dbProjects.isNotEmpty()) setSelectedProject(dbProjects[0].id) else setSelectedProject(0)
|
||||
}
|
||||
setupDrawerProjects()
|
||||
refreshLists()
|
||||
synchronize()
|
||||
synchronize(SyncTrigger.PROJECT_OPEN)
|
||||
val projectNameString = proj.name.ifEmpty { proj.remoteId }
|
||||
showToast(this@BillsListViewActivity, getString(R.string.remove_project_confirmation, projectNameString))
|
||||
}
|
||||
@@ -421,22 +430,34 @@ class BillsListViewActivity :
|
||||
lifecycleScope.launch {
|
||||
val proj = withContext(Dispatchers.IO) { db.getProject(projectId) } ?: return@launch
|
||||
val isArchiving = !proj.isArchived
|
||||
|
||||
val newArchivedTs = if (isArchiving) System.currentTimeMillis() / 1000 else 0L
|
||||
|
||||
|
||||
val localArchivedTs = if (isArchiving) System.currentTimeMillis() / 1000 else 0L
|
||||
val remoteArchivedTs = if (isArchiving) {
|
||||
localArchivedTs
|
||||
} else {
|
||||
VersatileProjectSyncClient.REMOTE_ARCHIVED_TS_UNSET
|
||||
}
|
||||
|
||||
withContext(Dispatchers.IO) {
|
||||
db.updateProject(
|
||||
projId = projectId,
|
||||
newName = null,
|
||||
newEmail = null,
|
||||
newPassword = null,
|
||||
newLastPayerId = null,
|
||||
newLastSyncedTimestamp = null,
|
||||
newCurrencyName = null,
|
||||
newDeletionDisabled = null,
|
||||
newMyAccessLevel = null,
|
||||
newBearerToken = null,
|
||||
newArchivedTs = newArchivedTs
|
||||
newArchivedTs = localArchivedTs
|
||||
)
|
||||
}
|
||||
|
||||
if (!proj.isLocal) {
|
||||
db.cowspentServerSyncHelper.editRemoteProject(
|
||||
projId = projectId,
|
||||
newArchivedTs = remoteArchivedTs,
|
||||
callback = object : ICallback {
|
||||
override fun onFinish() {}
|
||||
override fun onFinish(result: String, message: String) {
|
||||
if (message.isNotEmpty()) {
|
||||
showToast(this@BillsListViewActivity, getString(R.string.error_sync, message))
|
||||
}
|
||||
}
|
||||
override fun onScheduled() {}
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
@@ -739,31 +760,73 @@ class BillsListViewActivity :
|
||||
}
|
||||
}
|
||||
|
||||
private fun synchronize(manual: Boolean = false) {
|
||||
/**
|
||||
* What prompted a sync. Only [APP_OPEN] may refresh the account and every project, and only
|
||||
* then when the SyncOnOpen interval has elapsed; the other triggers touch the selected
|
||||
* project alone.
|
||||
*/
|
||||
@VisibleForTesting
|
||||
internal enum class SyncTrigger { APP_OPEN, PROJECT_OPEN, MANUAL }
|
||||
|
||||
@VisibleForTesting
|
||||
internal fun synchronize(trigger: SyncTrigger) {
|
||||
val preferences = PreferenceManager.getDefaultSharedPreferences(applicationContext)
|
||||
val offlineMode = preferences.getBoolean(getString(R.string.pref_key_offline_mode), false)
|
||||
if (offlineMode && !manual) {
|
||||
return
|
||||
}
|
||||
// isSyncPossible is networkConnected && !offlineMode, so offline mode is already covered
|
||||
// here - including for a manual refresh, which cannot currently override it.
|
||||
if (!db.cowspentServerSyncHelper.isSyncPossible) return
|
||||
|
||||
val selectedProjectId = preferences.getLong("selected_project", 0)
|
||||
val now = System.currentTimeMillis()
|
||||
|
||||
// The account and all-projects refresh belongs to opening the app, throttled by the
|
||||
// SyncOnOpen interval so that resuming within the interval does not repeat it.
|
||||
val intervalMinutes = SyncSettings.intervalMinutes(applicationContext)
|
||||
val lastAccountSync = preferences.getLong(getString(R.string.pref_key_last_account_sync_timestamp), 0L)
|
||||
val accountSyncDue = trigger == SyncTrigger.APP_OPEN &&
|
||||
now - lastAccountSync > intervalMinutes * 60 * 1000L
|
||||
|
||||
lifecycleScope.launch {
|
||||
val remoteProjects = withContext(Dispatchers.IO) { db.projects }
|
||||
.filter { !it.isLocal && !it.isArchived }
|
||||
|
||||
if (db.cowspentServerSyncHelper.isSyncPossible) {
|
||||
viewModel.isRefreshing = true
|
||||
val selectedProjectId = PreferenceManager.getDefaultSharedPreferences(applicationContext).getLong("selected_project", 0)
|
||||
if (selectedProjectId != 0L) {
|
||||
lifecycleScope.launch {
|
||||
val proj = withContext(Dispatchers.IO) { db.getProject(selectedProjectId) }
|
||||
if (proj != null && !proj.isLocal) {
|
||||
db.cowspentServerSyncHelper.addCallbackPull(syncCallBack)
|
||||
db.cowspentServerSyncHelper.scheduleSync(false, selectedProjectId)
|
||||
} else viewModel.isRefreshing = false
|
||||
db.cowspentServerSyncHelper.addCallbackPull(syncCallBack)
|
||||
|
||||
val started = if (accountSyncDue) {
|
||||
if (CowspentServerSyncHelper.isNextcloudAccountConfigured(applicationContext)) {
|
||||
db.cowspentServerSyncHelper.runAccountProjectsSync()
|
||||
}
|
||||
} else viewModel.isRefreshing = false
|
||||
if (CowspentServerSyncHelper.isNextcloudAccountConfigured(applicationContext)) {
|
||||
db.cowspentServerSyncHelper.runAccountProjectsSync()
|
||||
remoteProjects.count {
|
||||
val scheduled = db.cowspentServerSyncHelper.scheduleSync(false, it, false) != null
|
||||
if (scheduled) markProjectSynced(preferences, it.id, now)
|
||||
scheduled
|
||||
}
|
||||
} else {
|
||||
val selectedProj = remoteProjects.find { it.id == selectedProjectId }
|
||||
val lastSync = preferences.getLong(lastProjectSyncKey(selectedProjectId), 0L)
|
||||
val due = trigger == SyncTrigger.MANUAL ||
|
||||
now - lastSync > SELECTED_PROJECT_SYNC_INTERVAL_MS
|
||||
if (selectedProj != null && due &&
|
||||
db.cowspentServerSyncHelper.scheduleSync(
|
||||
false, selectedProj, trigger == SyncTrigger.MANUAL
|
||||
) != null
|
||||
) {
|
||||
markProjectSynced(preferences, selectedProj.id, now)
|
||||
1
|
||||
} else 0
|
||||
}
|
||||
|
||||
// Only a task that actually started reports back through syncCallBack, so clear
|
||||
// the indicator here when none did - nothing else would.
|
||||
if (started == 0) viewModel.isRefreshing = false
|
||||
}
|
||||
}
|
||||
|
||||
private fun lastProjectSyncKey(projectId: Long) = "lastProjectSyncTimestamp_$projectId"
|
||||
private fun markProjectSynced(preferences: SharedPreferences, projectId: Long, at: Long) {
|
||||
preferences.edit { putLong(lastProjectSyncKey(projectId), at) }
|
||||
}
|
||||
|
||||
private fun registerBroadcastReceiver() {
|
||||
val filter = IntentFilter().apply {
|
||||
addAction(MainConstants.BROADCAST_PROJECT_SYNC_FAILED)
|
||||
@@ -803,7 +866,7 @@ class BillsListViewActivity :
|
||||
refreshLists()
|
||||
}
|
||||
MainConstants.BROADCAST_SYNC_PROJECT -> {
|
||||
synchronize()
|
||||
synchronize(SyncTrigger.PROJECT_OPEN)
|
||||
}
|
||||
MainConstants.BROADCAST_NETWORK_AVAILABLE -> {
|
||||
}
|
||||
@@ -831,7 +894,7 @@ class BillsListViewActivity :
|
||||
refreshLists()
|
||||
if (db.cowspentServerSyncHelper.isSyncPossible) {
|
||||
db.cowspentServerSyncHelper.addCallbackPull(syncCallBack)
|
||||
synchronize()
|
||||
synchronize(SyncTrigger.PROJECT_OPEN)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,8 +17,6 @@ object MainConstants {
|
||||
const val BROADCAST_AVATAR_UPDATED = "net.helcel.cowspent.broadcast.avatar_updated"
|
||||
const val BROADCAST_AVATAR_UPDATED_MEMBER = "net.helcel.cowspent.broadcast.avatar_updated_for_member"
|
||||
|
||||
const val MAIN_CHANNEL_ID = 1234567890
|
||||
|
||||
const val PARAM_DIALOG_CONTENT = "net.helcel.cowspent.PARAM_DIALOG_CONTENT"
|
||||
const val PARAM_PROJECT_TO_SELECT = "net.helcel.cowspent.PARAM_PROJECT_TO_SELECT"
|
||||
|
||||
|
||||
@@ -114,7 +114,7 @@ object ProjectImportHelper {
|
||||
}
|
||||
else -> 0
|
||||
}
|
||||
val payerName = if (columns.containsKey("payer_name")) line[columns["payer_name"]!!] else ""
|
||||
val payerName = if (columns.containsKey("payer_name")) line[columns["payer_name"]!!].trim() else ""
|
||||
val payerWeight = if (columns.containsKey("payer_weight")) line[columns["payer_weight"]!!].toDouble() else 1.0
|
||||
val owersStr = if (columns.containsKey("owers")) line[columns["owers"]!!] else ""
|
||||
val payerActive = columns.containsKey("payer_active") && line[columns["payer_active"]!!] == "1"
|
||||
@@ -122,8 +122,10 @@ object ProjectImportHelper {
|
||||
val pmId = if (columns.containsKey("paymentmodeid") && line[columns["paymentmodeid"]!!].isNotEmpty()) line[columns["paymentmodeid"]!!].toLong() else 0L
|
||||
val pm = if (columns.containsKey("paymentmode")) line[columns["paymentmode"]!!] else null
|
||||
|
||||
membersActive[payerName] = payerActive
|
||||
membersWeight[payerName] = payerWeight
|
||||
if (payerName.isNotEmpty()) {
|
||||
membersActive[payerName] = payerActive
|
||||
membersWeight[payerName] = payerWeight
|
||||
}
|
||||
|
||||
if (owersStr.trim().isEmpty()) {
|
||||
onError(context.getString(R.string.import_error_owers, row))
|
||||
@@ -132,10 +134,10 @@ object ProjectImportHelper {
|
||||
|
||||
if (what != "deleteMeIfYouWant") {
|
||||
billRemoteIdToOwerStr[row.toLong()] = owersStr
|
||||
val owersArray = owersStr.split(", ").filter { it.isNotEmpty() }
|
||||
val owersArray = owersStr.split(",").map { it.trim() }.filter { it.isNotEmpty() }
|
||||
for (ower in owersArray) {
|
||||
if (!membersWeight.containsKey(ower.trim())) {
|
||||
membersWeight[ower.trim()] = 1.0
|
||||
if (!membersWeight.containsKey(ower)) {
|
||||
membersWeight[ower] = 1.0
|
||||
}
|
||||
}
|
||||
bills.add(DBBill(0, row.toLong(), 0, 0, amount, timestamp, what, DBBill.STATE_OK, "n", pm, catId, comment, pmId))
|
||||
@@ -149,6 +151,9 @@ object ProjectImportHelper {
|
||||
|
||||
val memberNameToId = mutableMapOf<String, Long>()
|
||||
val pid = db.addProject(DBProject(0, projectRemoteId, "", projectRemoteId, null, null, null, ProjectType.LOCAL, 0L, mainCurrencyName, false, DBProject.ACCESS_LEVEL_UNKNOWN, null))
|
||||
// addProject only inserts a subset of the row, currency not among it, so the main
|
||||
// currency the file declared has to be written separately or it is lost.
|
||||
if (mainCurrencyName != null) db.updateProject(pid, newCurrencyName = mainCurrencyName)
|
||||
|
||||
val pmRemoteToLocal = mutableMapOf<Long, Long>()
|
||||
paymentModes.forEach {
|
||||
@@ -171,8 +176,8 @@ object ProjectImportHelper {
|
||||
val localCatId = catRemoteToLocal[b.categoryId] ?: 0L
|
||||
val localPmId = pmRemoteToLocal[b.paymentModeId] ?: 0L
|
||||
val billId = db.addBill(DBBill(0, 0, pid, payerId, b.amount, b.timestamp, b.what, DBBill.STATE_OK, b.repeat, b.paymentMode, localCatId, b.comment, localPmId))
|
||||
billRemoteIdToOwerStr[b.remoteId]?.split(", ")?.filter { it.isNotEmpty() }?.forEach { ower ->
|
||||
memberNameToId[ower.trim()]?.let { owerId -> db.addBillower(billId, owerId) }
|
||||
billRemoteIdToOwerStr[b.remoteId]?.split(",")?.map { it.trim() }?.filter { it.isNotEmpty() }?.forEach { ower ->
|
||||
memberNameToId[ower]?.let { owerId -> db.addBillower(billId, owerId) }
|
||||
}
|
||||
}
|
||||
onSuccess(pid)
|
||||
|
||||
@@ -10,10 +10,8 @@ import androidx.activity.compose.setContent
|
||||
import androidx.activity.result.contract.ActivityResultContracts
|
||||
import androidx.activity.viewModels
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import androidx.preference.PreferenceManager
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.launch
|
||||
import kotlinx.coroutines.runBlocking
|
||||
import kotlinx.coroutines.withContext
|
||||
import net.helcel.cowspent.R
|
||||
@@ -31,7 +29,7 @@ import net.helcel.cowspent.android.project.ProjectImportHelper
|
||||
|
||||
class NewProjectActivity : AppCompatActivity() {
|
||||
|
||||
private val viewModel: NewProjectViewModel by viewModels()
|
||||
internal val viewModel: NewProjectViewModel by viewModels()
|
||||
private lateinit var db: CowspentSQLiteOpenHelper
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
@@ -57,9 +55,6 @@ class NewProjectActivity : AppCompatActivity() {
|
||||
.setAction(Intent.ACTION_GET_CONTENT)
|
||||
importFileLauncher.launch(Intent.createChooser(intent, "Select a file"))
|
||||
},
|
||||
onChooseFromNextcloud = {
|
||||
chooseFromNextcloud()
|
||||
},
|
||||
onOkPressed = { onPressOk() },
|
||||
onBack = { finish() },
|
||||
onFieldsChanged = { updateAuthStatus() }
|
||||
@@ -130,19 +125,6 @@ class NewProjectActivity : AppCompatActivity() {
|
||||
}
|
||||
}
|
||||
|
||||
private fun chooseFromNextcloud() {
|
||||
lifecycleScope.launch {
|
||||
val accountProjects = withContext(Dispatchers.IO) { db.accountProjects }
|
||||
if (accountProjects.isEmpty()) {
|
||||
showToast(getString(R.string.choose_account_project_dialog_impossible), Toast.LENGTH_LONG)
|
||||
return@launch
|
||||
}
|
||||
|
||||
viewModel.nextcloudProjects = accountProjects
|
||||
viewModel.showNextcloudProjectDialog = true
|
||||
}
|
||||
}
|
||||
|
||||
private fun updateAuthStatus() {
|
||||
val url = getFormattedUrl()
|
||||
val fakeProj = DBProject(
|
||||
@@ -154,19 +136,7 @@ class NewProjectActivity : AppCompatActivity() {
|
||||
viewModel.isAuthenticatedAccount = db.cowspentServerSyncHelper.canCreateAuthenticatedProject(fakeProj)
|
||||
}
|
||||
|
||||
private fun onPressOk() {
|
||||
val type = viewModel.projectType
|
||||
val todoCreate = viewModel.whatTodoIsCreate
|
||||
val url = getFormattedUrl()
|
||||
|
||||
val fakeProj = DBProject(
|
||||
0, "", "", "", url,
|
||||
"", 0L, type, 0L,
|
||||
null, false, DBProject.ACCESS_LEVEL_UNKNOWN,
|
||||
""
|
||||
)
|
||||
createProject()
|
||||
}
|
||||
private fun onPressOk() = createProject()
|
||||
|
||||
private fun getFormattedUrl(): String {
|
||||
var url = viewModel.projectUrl.trim()
|
||||
|
||||
@@ -3,7 +3,6 @@ package net.helcel.cowspent.android.project.create
|
||||
import android.annotation.SuppressLint
|
||||
import androidx.compose.foundation.layout.*
|
||||
import androidx.compose.foundation.rememberScrollState
|
||||
import androidx.compose.foundation.selection.selectable
|
||||
import androidx.compose.foundation.verticalScroll
|
||||
import androidx.compose.material.*
|
||||
import androidx.compose.material.icons.Icons
|
||||
@@ -31,7 +30,6 @@ fun NewProjectScreen(
|
||||
viewModel: NewProjectViewModel,
|
||||
onScanQrCode: () -> Unit,
|
||||
onImportFile: () -> Unit,
|
||||
onChooseFromNextcloud: () -> Unit,
|
||||
onOkPressed: () -> Unit,
|
||||
onBack: () -> Unit,
|
||||
onFieldsChanged: () -> Unit
|
||||
@@ -224,40 +222,6 @@ fun NewProjectScreen(
|
||||
)
|
||||
}
|
||||
|
||||
if (viewModel.showNextcloudProjectDialog) {
|
||||
AlertDialog(
|
||||
onDismissRequest = { viewModel.showNextcloudProjectDialog = false },
|
||||
title = { Text(stringResource(R.string.choose_account_project_dialog_title)) },
|
||||
text = {
|
||||
Column {
|
||||
viewModel.nextcloudProjects.forEach { project ->
|
||||
Row(
|
||||
Modifier
|
||||
.fillMaxWidth()
|
||||
.selectable(
|
||||
selected = false,
|
||||
onClick = {
|
||||
viewModel.projectId = project.remoteId
|
||||
viewModel.projectUrl = project.ncUrl
|
||||
viewModel.showNextcloudProjectDialog = false
|
||||
}
|
||||
)
|
||||
.padding(16.dp)
|
||||
) {
|
||||
Text(text = project.name)
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
confirmButton = {},
|
||||
dismissButton = {
|
||||
TextButton(onClick = { viewModel.showNextcloudProjectDialog = false }) {
|
||||
Text(stringResource(R.string.simple_cancel))
|
||||
}
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
if (viewModel.isCreatingRemoteProject) {
|
||||
AlertDialog(
|
||||
onDismissRequest = { },
|
||||
@@ -337,7 +301,6 @@ fun NewProjectScreenPreview() {
|
||||
},
|
||||
onScanQrCode = {},
|
||||
onImportFile = {},
|
||||
onChooseFromNextcloud = {},
|
||||
onOkPressed = {},
|
||||
onBack = {},
|
||||
onFieldsChanged = {}
|
||||
|
||||
@@ -5,7 +5,6 @@ import androidx.compose.runtime.getValue
|
||||
import androidx.compose.runtime.mutableStateOf
|
||||
import androidx.compose.runtime.setValue
|
||||
import androidx.lifecycle.ViewModel
|
||||
import net.helcel.cowspent.model.DBAccountProject
|
||||
import net.helcel.cowspent.model.ProjectType
|
||||
|
||||
class NewProjectViewModel : ViewModel() {
|
||||
@@ -33,8 +32,6 @@ class NewProjectViewModel : ViewModel() {
|
||||
var isAuthenticatedAccount by mutableStateOf(false)
|
||||
|
||||
var showAuthWarningDialog by mutableStateOf(false)
|
||||
var showNextcloudProjectDialog by mutableStateOf(false)
|
||||
var nextcloudProjects by mutableStateOf<List<DBAccountProject>>(emptyList())
|
||||
|
||||
var isCreatingRemoteProject by mutableStateOf(false)
|
||||
var errorDialogMessage by mutableStateOf<String?>(null)
|
||||
|
||||
@@ -3,8 +3,8 @@ package net.helcel.cowspent.android.project.edit
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import android.widget.Toast
|
||||
import androidx.activity.enableEdgeToEdge
|
||||
import androidx.activity.compose.setContent
|
||||
import androidx.activity.enableEdgeToEdge
|
||||
import androidx.activity.viewModels
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
@@ -13,17 +13,16 @@ import kotlinx.coroutines.launch
|
||||
import kotlinx.coroutines.withContext
|
||||
import net.helcel.cowspent.R
|
||||
import net.helcel.cowspent.android.helper.showToast
|
||||
import net.helcel.cowspent.android.main.MainConstants
|
||||
import net.helcel.cowspent.model.DBProject
|
||||
import net.helcel.cowspent.persistence.CowspentSQLiteOpenHelper
|
||||
import net.helcel.cowspent.theme.ThemeUtils
|
||||
import net.helcel.cowspent.util.ICallback
|
||||
import net.helcel.cowspent.util.SupportUtil
|
||||
import net.helcel.cowspent.android.main.MainConstants
|
||||
|
||||
|
||||
class EditProjectActivity : AppCompatActivity() {
|
||||
|
||||
private val viewModel: EditProjectViewModel by viewModels()
|
||||
internal val viewModel: EditProjectViewModel by viewModels()
|
||||
private lateinit var db: CowspentSQLiteOpenHelper
|
||||
private lateinit var project: DBProject
|
||||
|
||||
@@ -56,39 +55,44 @@ class EditProjectActivity : AppCompatActivity() {
|
||||
}
|
||||
|
||||
private fun onSave() {
|
||||
when (viewModel.validate()) {
|
||||
EditProjectViewModel.ValidationError.EMPTY_NAME -> {
|
||||
showToast(this, getString(R.string.error_invalid_project_name), Toast.LENGTH_LONG)
|
||||
return
|
||||
}
|
||||
EditProjectViewModel.ValidationError.INVALID_EMAIL -> {
|
||||
showToast(this, getString(R.string.error_invalid_email), Toast.LENGTH_LONG)
|
||||
return
|
||||
}
|
||||
null -> Unit
|
||||
}
|
||||
|
||||
val changes = viewModel.changesFrom(project)
|
||||
if (!changes.any) {
|
||||
showToast(this, getString(R.string.project_edition_no_change), Toast.LENGTH_LONG)
|
||||
return
|
||||
}
|
||||
|
||||
val currentPwd = viewModel.password
|
||||
val newPwd = viewModel.newPassword
|
||||
val newName = viewModel.name
|
||||
val newEmail = viewModel.email
|
||||
|
||||
if (newName.isEmpty()) {
|
||||
showToast(this, getString(R.string.error_invalid_project_name), Toast.LENGTH_LONG)
|
||||
return
|
||||
}
|
||||
if (newEmail.isNotEmpty() && !SupportUtil.isValidEmail(newEmail)) {
|
||||
showToast(this, getString(R.string.error_invalid_email), Toast.LENGTH_LONG)
|
||||
return
|
||||
}
|
||||
|
||||
val nameChanged = newName != project.name
|
||||
val emailChanged = newEmail != project.email
|
||||
val pwdChanged = newPwd != project.password
|
||||
val currentPwdChanged = currentPwd != project.password
|
||||
|
||||
if (!nameChanged && !emailChanged && !pwdChanged && !currentPwdChanged) {
|
||||
showToast(this, getString(R.string.project_edition_no_change), Toast.LENGTH_LONG)
|
||||
return
|
||||
}
|
||||
val nameChanged = changes.name
|
||||
val emailChanged = changes.email
|
||||
val pwdChanged = changes.newPassword
|
||||
val currentPwdChanged = changes.currentPassword
|
||||
|
||||
if (project.isLocal) {
|
||||
val targetPwd = if (pwdChanged) newPwd else currentPwd
|
||||
lifecycleScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
db.updateProject(
|
||||
project.id, newName, newEmail, targetPwd,
|
||||
null, project.type, null,
|
||||
null, null,
|
||||
null, null
|
||||
projId = project.id,
|
||||
newName = newName,
|
||||
newEmail = newEmail,
|
||||
newPassword = targetPwd,
|
||||
projectType = project.type
|
||||
)
|
||||
}
|
||||
closeOnEdit(project.id)
|
||||
@@ -103,18 +107,21 @@ class EditProjectActivity : AppCompatActivity() {
|
||||
project.password = currentPwd
|
||||
lifecycleScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
db.updateProject(project.id, null, null, currentPwd, null, project.type, null, null, null, null, null)
|
||||
db.updateProject(
|
||||
projId = project.id,
|
||||
newPassword = currentPwd,
|
||||
projectType = project.type
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!db.cowspentServerSyncHelper.editRemoteProject(
|
||||
project.id,
|
||||
newName,
|
||||
newEmail,
|
||||
if (pwdChanged) newPwd else null,
|
||||
null,
|
||||
editCallBack
|
||||
projId = project.id,
|
||||
newName = newName,
|
||||
newEmail = newEmail,
|
||||
newPassword = if (pwdChanged) newPwd else null,
|
||||
callback = editCallBack
|
||||
)
|
||||
) {
|
||||
showToast(this, getString(R.string.remote_project_operation_no_network), Toast.LENGTH_LONG)
|
||||
@@ -124,10 +131,9 @@ class EditProjectActivity : AppCompatActivity() {
|
||||
lifecycleScope.launch {
|
||||
withContext(Dispatchers.IO) {
|
||||
db.updateProject(
|
||||
project.id, null, null, currentPwd,
|
||||
null, project.type, null,
|
||||
null, null,
|
||||
null, null
|
||||
projId = project.id,
|
||||
newPassword = currentPwd,
|
||||
projectType = project.type
|
||||
)
|
||||
}
|
||||
closeOnEdit(project.id)
|
||||
|
||||
@@ -7,6 +7,7 @@ import androidx.compose.ui.graphics.vector.ImageVector
|
||||
import androidx.lifecycle.ViewModel
|
||||
import net.helcel.cowspent.android.helper.DialogState
|
||||
import net.helcel.cowspent.model.DBProject
|
||||
import net.helcel.cowspent.util.SupportUtil
|
||||
|
||||
class EditProjectViewModel : ViewModel() {
|
||||
var name by mutableStateOf("")
|
||||
@@ -17,6 +18,31 @@ class EditProjectViewModel : ViewModel() {
|
||||
|
||||
var dialogState by mutableStateOf<DialogState?>(null)
|
||||
|
||||
enum class ValidationError { EMPTY_NAME, INVALID_EMAIL }
|
||||
|
||||
fun validate(): ValidationError? = when {
|
||||
name.isBlank() -> ValidationError.EMPTY_NAME
|
||||
email.isNotEmpty() && !SupportUtil.isValidEmail(email) -> ValidationError.INVALID_EMAIL
|
||||
else -> null
|
||||
}
|
||||
|
||||
data class Changes(
|
||||
val name: Boolean,
|
||||
val email: Boolean,
|
||||
val newPassword: Boolean,
|
||||
val currentPassword: Boolean
|
||||
) {
|
||||
val any: Boolean get() = name || email || newPassword || currentPassword
|
||||
}
|
||||
|
||||
fun changesFrom(project: DBProject) = Changes(
|
||||
name = name != project.name,
|
||||
// initFromProject maps a null or "null" email to "", so treat those as unchanged
|
||||
email = email != project.email && !(email.isEmpty() && project.email == null),
|
||||
newPassword = newPassword != project.password,
|
||||
currentPassword = password != project.password
|
||||
)
|
||||
|
||||
fun showDialog(
|
||||
title: String? = null,
|
||||
message: String? = null,
|
||||
|
||||
@@ -12,6 +12,7 @@ import androidx.compose.material.icons.Icons
|
||||
import androidx.compose.runtime.*
|
||||
import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.platform.testTag
|
||||
import androidx.compose.ui.res.stringResource
|
||||
import androidx.compose.ui.text.font.FontWeight
|
||||
import androidx.compose.ui.text.input.KeyboardCapitalization
|
||||
@@ -100,6 +101,7 @@ fun MemberEditDialogContent(
|
||||
.fillMaxWidth()
|
||||
.clickable { isActivated = !isActivated }
|
||||
.padding(vertical = 8.dp)
|
||||
.testTag("member_activated_row")
|
||||
) {
|
||||
Icon(
|
||||
imageVector = Icons.Default.Block,
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ import net.helcel.cowspent.theme.ThemeUtils
|
||||
|
||||
class MemberManagementActivity : AppCompatActivity() {
|
||||
|
||||
private val viewModel: MemberManagementViewModel by viewModels()
|
||||
internal val viewModel: MemberManagementViewModel by viewModels()
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
enableEdgeToEdge()
|
||||
|
||||
@@ -20,6 +20,7 @@ import androidx.compose.material.IconButton
|
||||
import androidx.compose.material.MaterialTheme
|
||||
import androidx.compose.material.RadioButton
|
||||
import androidx.compose.material.Scaffold
|
||||
import androidx.compose.material.Slider
|
||||
import androidx.compose.material.Switch
|
||||
import androidx.compose.material.SwitchDefaults
|
||||
import androidx.compose.material.Text
|
||||
@@ -30,6 +31,7 @@ import androidx.compose.material.icons.automirrored.filled.ArrowBack
|
||||
import androidx.compose.material.icons.filled.AccountCircle
|
||||
import androidx.compose.material.icons.filled.Archive
|
||||
import androidx.compose.material.icons.filled.Brightness2
|
||||
import androidx.compose.material.icons.filled.Group
|
||||
import androidx.compose.material.icons.filled.Info
|
||||
import androidx.compose.material.icons.filled.Palette
|
||||
import androidx.compose.material.icons.filled.Sync
|
||||
@@ -49,13 +51,16 @@ import androidx.compose.ui.res.stringResource
|
||||
import androidx.compose.ui.text.font.FontWeight
|
||||
import androidx.compose.ui.tooling.preview.Preview
|
||||
import androidx.compose.ui.unit.dp
|
||||
import kotlin.math.roundToInt
|
||||
import androidx.core.content.edit
|
||||
import androidx.preference.PreferenceManager
|
||||
import net.helcel.cowspent.R
|
||||
import net.helcel.cowspent.android.helper.ColorPicker
|
||||
import net.helcel.cowspent.persistence.CowspentSQLiteOpenHelper
|
||||
import net.helcel.cowspent.persistence.CowspentServerSyncHelper
|
||||
import net.helcel.cowspent.util.ColorUtils
|
||||
import net.helcel.cowspent.util.Cowspent
|
||||
import net.helcel.cowspent.util.SyncSettings
|
||||
|
||||
@Composable
|
||||
fun SettingsScreen(
|
||||
@@ -80,22 +85,31 @@ fun SettingsScreen(
|
||||
val keyOfflineMode = stringResource(R.string.pref_key_offline_mode)
|
||||
val keyShowArchived = stringResource(R.string.pref_key_show_archived)
|
||||
val keyBetaFeatures = stringResource(R.string.pref_key_beta_features)
|
||||
val keyStatsIncludeDeactivated = stringResource(R.string.pref_key_stats_include_deactivated)
|
||||
val keyAutoSyncOnOpen = stringResource(R.string.pref_key_auto_sync_on_open)
|
||||
val keyFillNewBillFromLast = stringResource(R.string.pref_key_fill_new_bill_from_last)
|
||||
val keyLastAccountSync = stringResource(R.string.pref_key_last_account_sync_timestamp)
|
||||
|
||||
val isNextcloudConfigured = CowspentServerSyncHelper.isNextcloudAccountConfigured(context)
|
||||
|
||||
// States for preferences
|
||||
var nightMode by remember(keyNightMode) {
|
||||
mutableStateOf(sharedPreferences.getString(keyNightMode, "-1") ?: "-1")
|
||||
}
|
||||
|
||||
var colorMode by remember(keyColorMode, keyUseServerColor, keyUseSystemColor) {
|
||||
mutableStateOf(sharedPreferences.getString(keyColorMode, null) ?: run {
|
||||
val useServer = sharedPreferences.getBoolean(keyUseServerColor, true)
|
||||
var colorMode by remember(keyColorMode, keyUseServerColor, keyUseSystemColor, isNextcloudConfigured) {
|
||||
val savedMode = sharedPreferences.getString(keyColorMode, null)
|
||||
val mode = savedMode ?: run {
|
||||
val useServer = sharedPreferences.getBoolean(keyUseServerColor, false)
|
||||
val useSystem = sharedPreferences.getBoolean(keyUseSystemColor, true)
|
||||
when {
|
||||
useServer -> "server"
|
||||
useServer && isNextcloudConfigured -> "server"
|
||||
useSystem -> "system"
|
||||
else -> "manual"
|
||||
}
|
||||
})
|
||||
}
|
||||
// Fallback to system if server is selected but not configured
|
||||
mutableStateOf(if (mode == "server" && !isNextcloudConfigured) "system" else mode)
|
||||
}
|
||||
|
||||
// Apply theme globally only when leaving settings to avoid flickering/restarts during selection
|
||||
@@ -117,6 +131,24 @@ fun SettingsScreen(
|
||||
var betaFeatures by remember(keyBetaFeatures) {
|
||||
mutableStateOf(sharedPreferences.getBoolean(keyBetaFeatures, false))
|
||||
}
|
||||
var fillNewBillFromLast by remember(keyFillNewBillFromLast) {
|
||||
mutableStateOf(sharedPreferences.getBoolean(keyFillNewBillFromLast, false))
|
||||
}
|
||||
var statsIncludeDeactivated by remember(keyStatsIncludeDeactivated) {
|
||||
mutableStateOf(sharedPreferences.getBoolean(keyStatsIncludeDeactivated, false))
|
||||
}
|
||||
|
||||
val syncIntervals = SyncSettings.INTERVAL_CHOICES_MINUTES
|
||||
val syncIntervalLabels = listOf(
|
||||
stringResource(R.string.pref_value_sync_1m),
|
||||
stringResource(R.string.pref_value_sync_10m),
|
||||
stringResource(R.string.pref_value_sync_1h),
|
||||
stringResource(R.string.pref_value_sync_1d)
|
||||
)
|
||||
|
||||
var syncInterval by remember(keyAutoSyncOnOpen) {
|
||||
mutableIntStateOf(SyncSettings.intervalMinutes(context))
|
||||
}
|
||||
|
||||
Scaffold(
|
||||
topBar = {
|
||||
@@ -124,7 +156,7 @@ fun SettingsScreen(
|
||||
title = { Text(stringResource(R.string.action_settings)) },
|
||||
navigationIcon = {
|
||||
IconButton(onClick = onBack) {
|
||||
Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = null)
|
||||
Icon(Icons.AutoMirrored.Filled.ArrowBack, contentDescription = "Back")
|
||||
}
|
||||
},
|
||||
backgroundColor = MaterialTheme.colors.primary,
|
||||
@@ -181,15 +213,19 @@ fun SettingsScreen(
|
||||
}
|
||||
)
|
||||
|
||||
val colorModeEntries = buildMap {
|
||||
put("system", stringResource(R.string.pref_value_color_system))
|
||||
if (isNextcloudConfigured) {
|
||||
put("server", stringResource(R.string.pref_value_color_server))
|
||||
}
|
||||
put("manual", stringResource(R.string.pref_value_color_manual))
|
||||
}
|
||||
|
||||
SettingsListPreference(
|
||||
title = stringResource(R.string.settings_color_mode),
|
||||
icon = Icons.Default.Palette,
|
||||
value = colorMode,
|
||||
entries = mapOf(
|
||||
"system" to stringResource(R.string.pref_value_color_system),
|
||||
"server" to stringResource(R.string.pref_value_color_server),
|
||||
"manual" to stringResource(R.string.pref_value_color_manual)
|
||||
),
|
||||
entries = colorModeEntries,
|
||||
onValueChange = { mode ->
|
||||
colorMode = mode
|
||||
sharedPreferences.edit {
|
||||
@@ -259,6 +295,51 @@ fun SettingsScreen(
|
||||
}
|
||||
)
|
||||
|
||||
if (betaFeatures) {
|
||||
SettingsSwitchPreference(
|
||||
title = stringResource(R.string.settings_fill_new_bill_from_last),
|
||||
summary = stringResource(R.string.settings_fill_new_bill_from_last_summary),
|
||||
icon = Icons.Default.Info,
|
||||
checked = fillNewBillFromLast,
|
||||
onCheckedChange = {
|
||||
fillNewBillFromLast = it
|
||||
sharedPreferences.edit {
|
||||
putBoolean(keyFillNewBillFromLast, it)
|
||||
}
|
||||
}
|
||||
)
|
||||
|
||||
SettingsSwitchPreference(
|
||||
title = stringResource(R.string.settings_stats_include_deactivated),
|
||||
icon = Icons.Default.Group,
|
||||
checked = statsIncludeDeactivated,
|
||||
onCheckedChange = {
|
||||
statsIncludeDeactivated = it
|
||||
sharedPreferences.edit {
|
||||
putBoolean(keyStatsIncludeDeactivated, it)
|
||||
}
|
||||
}
|
||||
)
|
||||
|
||||
SettingsSliderPreference(
|
||||
title = stringResource(R.string.settings_auto_sync_on_open),
|
||||
summary = stringResource(R.string.settings_auto_sync_on_open_summary),
|
||||
icon = Icons.Default.Sync,
|
||||
value = syncInterval,
|
||||
values = syncIntervals,
|
||||
labels = syncIntervalLabels,
|
||||
onValueChange = { newInterval ->
|
||||
// Slider reports every drag delta, not just the snapped steps.
|
||||
if (newInterval != syncInterval) {
|
||||
syncInterval = newInterval
|
||||
sharedPreferences.edit {
|
||||
putInt(keyAutoSyncOnOpen, newInterval)
|
||||
}
|
||||
}
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
SettingsPreference(
|
||||
title = stringResource(R.string.title_about),
|
||||
icon = Icons.Default.Info,
|
||||
@@ -372,13 +453,7 @@ fun SettingsListPreference(
|
||||
),
|
||||
verticalAlignment = Alignment.CenterVertically
|
||||
) {
|
||||
RadioButton(
|
||||
selected = (key == value),
|
||||
onClick = {
|
||||
onValueChange(key)
|
||||
showDialog = false
|
||||
}
|
||||
)
|
||||
RadioButton(selected = (key == value), onClick = null)
|
||||
Spacer(Modifier.width(8.dp))
|
||||
Text(text = label)
|
||||
}
|
||||
@@ -441,6 +516,47 @@ fun SettingsColorPreference(
|
||||
}
|
||||
}
|
||||
|
||||
@Composable
|
||||
fun SettingsSliderPreference(
|
||||
title: String,
|
||||
summary: String? = null,
|
||||
icon: Any? = null,
|
||||
value: Int,
|
||||
values: List<Int>,
|
||||
labels: List<String>,
|
||||
onValueChange: (Int) -> Unit
|
||||
) {
|
||||
Column(
|
||||
modifier = Modifier
|
||||
.fillMaxWidth()
|
||||
.padding(16.dp, 8.dp)
|
||||
) {
|
||||
Row(verticalAlignment = Alignment.CenterVertically) {
|
||||
SettingsIcon(icon)
|
||||
Spacer(modifier = Modifier.width(32.dp))
|
||||
Column(modifier = Modifier.weight(1f)) {
|
||||
Text(text = title, style = MaterialTheme.typography.subtitle1)
|
||||
if (summary != null) {
|
||||
Text(text = summary, style = MaterialTheme.typography.caption)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
val currentIndex = values.indexOf(value).coerceAtLeast(0)
|
||||
val steps = (values.size - 2).coerceAtLeast(0)
|
||||
|
||||
Column(modifier = Modifier.padding(start = 56.dp, top = 8.dp)) {
|
||||
Slider(
|
||||
value = currentIndex.toFloat(),
|
||||
onValueChange = { onValueChange(values[it.roundToInt()]) },
|
||||
valueRange = 0f..(values.size - 1).toFloat(),
|
||||
steps = steps
|
||||
)
|
||||
Text(text = labels[currentIndex], style = MaterialTheme.typography.caption, fontWeight = FontWeight.Bold, color = MaterialTheme.colors.primary)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Composable
|
||||
fun SettingsIcon(icon: Any?) {
|
||||
Box(modifier = Modifier.size(24.dp), contentAlignment = Alignment.Center) {
|
||||
|
||||
@@ -121,17 +121,19 @@ fun ProjectSankeyDiagram(
|
||||
val catMap = mutableMapOf<Long, Double>()
|
||||
|
||||
activeBills.forEach { bill ->
|
||||
val totalWeight = bill.billOwers.sumOf { membersMap[it.memberId]?.weight ?: 1.0 }
|
||||
val totalWeight = bill.billOwers.sumOf { membersMap[it.memberId]?.weight ?: 0.0 }
|
||||
if (totalWeight > 0) {
|
||||
if (selectedMemberId == -1L) {
|
||||
catMap[bill.categoryId] = (catMap[bill.categoryId] ?: 0.0) + bill.amount
|
||||
bill.billOwers.forEach { bo ->
|
||||
val weight = membersMap[bo.memberId]?.weight ?: 1.0
|
||||
spentMap[bo.memberId] = (spentMap[bo.memberId] ?: 0.0) + (bill.amount / totalWeight) * weight
|
||||
if (membersMap.containsKey(bo.memberId)) {
|
||||
val weight = membersMap[bo.memberId]?.weight ?: 0.0
|
||||
spentMap[bo.memberId] = (spentMap[bo.memberId] ?: 0.0) + (bill.amount / totalWeight) * weight
|
||||
}
|
||||
}
|
||||
} else {
|
||||
bill.billOwers.find { it.memberId == selectedMemberId }?.let { bo ->
|
||||
val weight = membersMap[bo.memberId]?.weight ?: 1.0
|
||||
val weight = membersMap[bo.memberId]?.weight ?: 0.0
|
||||
catMap[bill.categoryId] = (catMap[bill.categoryId] ?: 0.0) + (bill.amount / totalWeight) * weight
|
||||
spentMap[selectedMemberId] = (spentMap[selectedMemberId] ?: 0.0) + (bill.amount / totalWeight) * weight
|
||||
}
|
||||
@@ -344,7 +346,9 @@ private fun SankeyContent(
|
||||
scope.launch { topFocalIndex.animateTo(index.toFloat(), spring(Spring.DampingRatioLowBouncy, Spring.StiffnessLow)) }
|
||||
} else Modifier), contentAlignment = Alignment.Center) {
|
||||
Column(modifier = Modifier.fillMaxSize().background(color = member?.let { Color(it.r ?: 128, it.g ?: 128, it.b ?: 128) } ?: Color.Gray, shape = RoundedCornerShape(10.dp)), horizontalAlignment = Alignment.CenterHorizontally, verticalArrangement = Arrangement.Center) {
|
||||
Text(text = member?.name ?: "???", color = Color.White, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis, textAlign = TextAlign.Center, modifier = Modifier.wrapContentWidth(unbounded = true))
|
||||
if (wDp >= 32.dp) {
|
||||
Text(text = member?.name ?: "???", color = Color.White, fontWeight = FontWeight.Bold, maxLines = 1, overflow = TextOverflow.Ellipsis, textAlign = TextAlign.Center, modifier = Modifier.wrapContentWidth(unbounded = true))
|
||||
}
|
||||
if (wDp >= 40.dp) Text(text = formatShortValue(amount), fontSize = 12.sp, color = Color.White.copy(alpha = 0.9f), textAlign = TextAlign.Center)
|
||||
}
|
||||
}
|
||||
@@ -382,7 +386,9 @@ private fun SankeyContent(
|
||||
scope.launch { bottomFocalIndex.animateTo(index.toFloat(), spring(Spring.DampingRatioLowBouncy, Spring.StiffnessLow)) }
|
||||
} else Modifier), contentAlignment = Alignment.Center) {
|
||||
Column(modifier = Modifier.fillMaxSize().background(color = category?.color?.let { try { Color(it.toColorInt()) } catch (_: Exception) { Color(0xFF999999) } } ?: Color(0xFF999999), shape = RoundedCornerShape(10.dp)), horizontalAlignment = Alignment.CenterHorizontally, verticalArrangement = Arrangement.Center) {
|
||||
Text(text = category?.icon ?: "❔", fontSize = 20.sp, textAlign = TextAlign.Center, modifier = Modifier.wrapContentWidth(unbounded = true))
|
||||
if (wDp >= 24.dp) {
|
||||
Text(text = category?.icon ?: "❔", fontSize = 20.sp, textAlign = TextAlign.Center, modifier = Modifier.wrapContentWidth(unbounded = true))
|
||||
}
|
||||
if (wDp >= 40.dp) Text(text = formatShortValue(amount), fontSize = 12.sp, color = Color.White.copy(alpha = 0.9f), textAlign = TextAlign.Center)
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -47,7 +47,7 @@ class ProjectStatisticsActivity : AppCompatActivity() {
|
||||
}
|
||||
|
||||
companion object {
|
||||
private const val EXTRA_PROJECT_ID = "extra_project_id"
|
||||
internal const val EXTRA_PROJECT_ID = "extra_project_id"
|
||||
|
||||
fun createIntent(context: Context, projectId: Long): Intent {
|
||||
return Intent(context, ProjectStatisticsActivity::class.java).apply {
|
||||
|
||||
@@ -40,6 +40,8 @@ fun ProjectStatisticsScreen(
|
||||
"Sankey"
|
||||
)
|
||||
|
||||
val keyStatsIncludeDeactivated = stringResource(R.string.pref_key_stats_include_deactivated)
|
||||
|
||||
Scaffold(
|
||||
topBar = {
|
||||
TopAppBar(
|
||||
@@ -103,7 +105,11 @@ fun ProjectStatisticsScreen(
|
||||
val bills = db.getBillsOfProject(proj.id)
|
||||
val categories = db.getCategories(proj.id)
|
||||
val paymentModes = db.getPaymentModes(proj.id)
|
||||
StatisticsData(members, bills, categories, paymentModes)
|
||||
|
||||
val includeDeactivated = prefs.getBoolean(keyStatsIncludeDeactivated, false)
|
||||
val filteredMembers = if (includeDeactivated) members else members.filter { it.isActivated }
|
||||
|
||||
StatisticsData(filteredMembers, bills, categories, paymentModes)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -3,8 +3,8 @@ package net.helcel.cowspent.android.statistics
|
||||
import android.app.DatePickerDialog
|
||||
import android.content.Context
|
||||
import androidx.compose.foundation.layout.*
|
||||
import androidx.compose.foundation.lazy.LazyColumn
|
||||
import androidx.compose.foundation.lazy.items
|
||||
import androidx.compose.foundation.rememberScrollState
|
||||
import androidx.compose.foundation.verticalScroll
|
||||
import androidx.compose.material.*
|
||||
import androidx.compose.material.icons.Icons
|
||||
import androidx.compose.material.icons.filled.*
|
||||
@@ -285,9 +285,18 @@ fun ProjectStatisticsTable(
|
||||
|
||||
Spacer(modifier = Modifier.height(4.dp))
|
||||
|
||||
LazyColumn(modifier = Modifier.weight(1f)) {
|
||||
items(stats.memberStats) { m ->
|
||||
Row(modifier = Modifier.fillMaxWidth().padding(vertical = 12.dp, horizontal = 8.dp), verticalAlignment = Alignment.CenterVertically) {
|
||||
Column(
|
||||
modifier = Modifier
|
||||
.weight(1f)
|
||||
.verticalScroll(rememberScrollState())
|
||||
) {
|
||||
stats.memberStats.forEach { m ->
|
||||
Row(
|
||||
modifier = Modifier
|
||||
.fillMaxWidth()
|
||||
.padding(vertical = 12.dp, horizontal = 8.dp),
|
||||
verticalAlignment = Alignment.CenterVertically
|
||||
) {
|
||||
Text(m.name, modifier = Modifier.weight(2f), color = MaterialTheme.colors.onSurface, fontWeight = FontWeight.Medium)
|
||||
|
||||
Text(
|
||||
|
||||
@@ -12,7 +12,6 @@ enum class ProjectType(val id: String) {
|
||||
}
|
||||
}
|
||||
|
||||
@JvmStatic
|
||||
fun getTypeById(id: String?): ProjectType? {
|
||||
return reverseMap[id]
|
||||
}
|
||||
|
||||
@@ -7,6 +7,7 @@ import android.database.Cursor
|
||||
import android.database.sqlite.SQLiteDatabase
|
||||
import android.database.sqlite.SQLiteOpenHelper
|
||||
import android.text.TextUtils
|
||||
import androidx.annotation.VisibleForTesting
|
||||
import androidx.annotation.WorkerThread
|
||||
import androidx.preference.PreferenceManager
|
||||
import net.helcel.cowspent.R
|
||||
@@ -271,12 +272,18 @@ class CowspentSQLiteOpenHelper private constructor(val context: Context) :
|
||||
}
|
||||
|
||||
fun updateProject(
|
||||
projId: Long, newName: String?, newEmail: String?,
|
||||
newPassword: String?, newLastPayerId: Long?,
|
||||
newLastSyncedTimestamp: Long?,
|
||||
newCurrencyName: String?, newDeletionDisabled: Boolean?,
|
||||
newMyAccessLevel: Int?, newBearerToken: String?,
|
||||
newArchivedTs: Long? = null
|
||||
projId: Long,
|
||||
newName: String? = null,
|
||||
newEmail: String? = null,
|
||||
newPassword: String? = null,
|
||||
newLastPayerId: Long? = null,
|
||||
newLastSyncedTimestamp: Long? = null,
|
||||
newCurrencyName: String? = null,
|
||||
newDeletionDisabled: Boolean? = null,
|
||||
newMyAccessLevel: Int? = null,
|
||||
newBearerToken: String? = null,
|
||||
newArchivedTs: Long? = null,
|
||||
projectType: ProjectType? = null
|
||||
) {
|
||||
val db = writableDatabase
|
||||
val values = ContentValues()
|
||||
@@ -290,47 +297,7 @@ class CowspentSQLiteOpenHelper private constructor(val context: Context) :
|
||||
if (newDeletionDisabled != null) values.put(key_deletionDisabled, if (newDeletionDisabled) 1 else 0)
|
||||
if (newMyAccessLevel != null) values.put(key_myAccessLevel, newMyAccessLevel)
|
||||
if (newArchivedTs != null) values.put(key_archived, newArchivedTs)
|
||||
if (values.size() > 0) {
|
||||
db.update(table_projects, values, "$key_id = ?", arrayOf(projId.toString()))
|
||||
}
|
||||
}
|
||||
|
||||
fun updateProject(
|
||||
projId: Long, newName: String?, newEmail: String?,
|
||||
newPassword: String?, newLastPayerId: Long?,
|
||||
projectType: ProjectType, newLastSyncedTimestamp: Long?,
|
||||
newCurrencyName: String?, newDeletionDisabled: Boolean?,
|
||||
newMyAccessLevel: Int?, newBearerToken: String?,
|
||||
newArchivedTs: Long? = null
|
||||
) {
|
||||
val db = writableDatabase
|
||||
updateProject(
|
||||
projId, newName, newEmail, newPassword, newLastPayerId, projectType,
|
||||
newLastSyncedTimestamp, newCurrencyName, newDeletionDisabled, newMyAccessLevel,
|
||||
newBearerToken, newArchivedTs, db
|
||||
)
|
||||
}
|
||||
|
||||
private fun updateProject(
|
||||
projId: Long, newName: String?, newEmail: String?,
|
||||
newPassword: String?, newLastPayerId: Long?,
|
||||
projectType: ProjectType, newLastSyncedTimestamp: Long?,
|
||||
newCurrencyName: String?, newDeletionDisabled: Boolean?,
|
||||
newMyAccessLevel: Int?, newBearerToken: String?,
|
||||
newArchivedTs: Long?, db: SQLiteDatabase
|
||||
) {
|
||||
val values = ContentValues()
|
||||
if (newName != null) values.put(key_name, newName)
|
||||
if (newEmail != null) values.put(key_email, newEmail)
|
||||
if (newPassword != null) SecureStorage.savePasswordSync(context, "ProjectPassword_$projId", newPassword)
|
||||
if (newBearerToken != null) values.put(key_bearer_token, newBearerToken)
|
||||
if (newLastPayerId != null) values.put(key_lastPayerId, newLastPayerId)
|
||||
if (newLastSyncedTimestamp != null) values.put(key_lastSyncTimestamp, newLastSyncedTimestamp)
|
||||
if (newCurrencyName != null) values.put(key_currencyName, newCurrencyName)
|
||||
if (newDeletionDisabled != null) values.put(key_deletionDisabled, if (newDeletionDisabled) 1 else 0)
|
||||
if (newMyAccessLevel != null) values.put(key_myAccessLevel, newMyAccessLevel)
|
||||
if (newArchivedTs != null) values.put(key_archived, newArchivedTs)
|
||||
values.put(key_type, projectType.id)
|
||||
if (projectType != null) values.put(key_type, projectType.id)
|
||||
if (values.size() > 0) {
|
||||
db.update(table_projects, values, "$key_id = ?", arrayOf(projId.toString()))
|
||||
}
|
||||
@@ -424,8 +391,8 @@ class CowspentSQLiteOpenHelper private constructor(val context: Context) :
|
||||
|
||||
fun getActivatedMembersOfProject(projId: Long): List<DBMember> {
|
||||
return getMembersCustom(
|
||||
"$key_projectid = ? AND $key_activated = 1",
|
||||
arrayOf(projId.toString()),
|
||||
"$key_projectid = ? AND $key_activated = 1 AND $key_state != ?",
|
||||
arrayOf(projId.toString(), DBBill.STATE_DELETED.toString()),
|
||||
"$key_name ASC"
|
||||
)
|
||||
}
|
||||
@@ -591,74 +558,67 @@ class CowspentSQLiteOpenHelper private constructor(val context: Context) :
|
||||
return if (bills.isEmpty()) null else bills[0]
|
||||
}
|
||||
|
||||
fun getLastBillOfProject(projectId: Long): DBBill? {
|
||||
val list = getBillsCustom(
|
||||
"$key_projectid = ? AND $key_state != ?",
|
||||
arrayOf(projectId.toString(), DBBill.STATE_DELETED.toString()),
|
||||
"$key_id DESC LIMIT 1"
|
||||
)
|
||||
return if (list.isEmpty()) null else list[0]
|
||||
}
|
||||
|
||||
@WorkerThread
|
||||
fun searchBills(query: CharSequence?, projectId: Long): List<DBBill> {
|
||||
val andWhere: MutableList<String> = ArrayList()
|
||||
val args: MutableList<String> = ArrayList()
|
||||
andWhere.add("($key_projectid = $projectId)")
|
||||
andWhere.add("($key_projectid = ?)")
|
||||
args.add(projectId.toString())
|
||||
andWhere.add("($key_state != ${DBBill.STATE_DELETED})")
|
||||
if (query != null) {
|
||||
args.add("%$query%")
|
||||
var whereStr = "($key_what LIKE ?"
|
||||
if (SupportUtil.isDouble(query.toString())) {
|
||||
whereStr += " OR ($key_amount <= (? + 10) AND $key_amount >= (? - 10))"
|
||||
args.add(query.toString())
|
||||
args.add(query.toString())
|
||||
|
||||
val terms = query?.toString()?.split("\\s+".toRegex())?.filter { it.isNotEmpty() }.orEmpty()
|
||||
if (terms.isNotEmpty()) {
|
||||
val memberIdsByName = getMembersOfProject(projectId, null)
|
||||
.associateBy({ it.name.lowercase(Locale.ROOT) }, { it.id })
|
||||
// Every clause appends its arguments as it is built, so args stay in the same order
|
||||
// as the placeholders they bind to.
|
||||
for (term in terms) {
|
||||
andWhere.add(memberClause(term, memberIdsByName, args) ?: textClause(term, args))
|
||||
}
|
||||
val members = getMembersOfProject(projectId, null)
|
||||
val memberNames: MutableList<String> = ArrayList()
|
||||
val memberIds: MutableList<Long> = ArrayList()
|
||||
for (m in members) {
|
||||
memberNames.add(m.name.lowercase(Locale.ROOT))
|
||||
memberIds.add(m.id)
|
||||
}
|
||||
val queryStr = query.toString()
|
||||
val words = queryStr.split("\\s+".toRegex()).dropLastWhile { it.isEmpty() }.toTypedArray()
|
||||
var nameSql = ""
|
||||
for (word in words) {
|
||||
if (word.startsWith("+")) {
|
||||
val nameQuery = word.replace("^\\+".toRegex(), "")
|
||||
val memberIndex = memberNames.indexOf(nameQuery.lowercase(Locale.ROOT))
|
||||
if (memberIndex != -1) {
|
||||
val searchMemberId = memberIds[memberIndex]
|
||||
nameSql += "($key_payer_id=?) AND "
|
||||
args.add(searchMemberId.toString())
|
||||
}
|
||||
}
|
||||
if (word.startsWith("-")) {
|
||||
val nameQuery = word.replace("^-".toRegex(), "")
|
||||
val memberIndex = memberNames.indexOf(nameQuery.lowercase(Locale.ROOT))
|
||||
if (memberIndex != -1) {
|
||||
val searchMemberId = memberIds[memberIndex]
|
||||
val joinOwer = "select $table_bills.$key_id from $table_bills inner join $table_billowers " +
|
||||
"where $key_member_id=? and $table_bills.$key_id=$table_billowers.$key_billId"
|
||||
nameSql += "($key_id IN ($joinOwer)) AND "
|
||||
args.add(searchMemberId.toString())
|
||||
}
|
||||
}
|
||||
if (word.startsWith("@")) {
|
||||
val nameQuery = word.replace("^@".toRegex(), "")
|
||||
val memberIndex = memberNames.indexOf(nameQuery.lowercase(Locale.ROOT))
|
||||
if (memberIndex != -1) {
|
||||
val searchMemberId = memberIds[memberIndex]
|
||||
nameSql += "( ($key_payer_id=?) OR "
|
||||
args.add(searchMemberId.toString())
|
||||
val joinOwer = "select $table_bills.$key_id from $table_bills inner join $table_billowers " +
|
||||
"where $key_member_id=? and $table_bills.$key_id=$table_billowers.$key_billId"
|
||||
nameSql += "($key_id IN ($joinOwer)) ) AND "
|
||||
args.add(searchMemberId.toString())
|
||||
}
|
||||
}
|
||||
}
|
||||
if (nameSql != "") {
|
||||
nameSql = nameSql.replace(" AND $".toRegex(), "")
|
||||
whereStr += " OR ($nameSql)"
|
||||
}
|
||||
whereStr += ")"
|
||||
andWhere.add(whereStr)
|
||||
}
|
||||
val order = "$key_timestamp DESC"
|
||||
return getBillsCustom(TextUtils.join(" AND ", andWhere), args.toTypedArray(), order)
|
||||
return getBillsCustom(TextUtils.join(" AND ", andWhere), args.toTypedArray(), "$key_timestamp DESC")
|
||||
}
|
||||
|
||||
/** Clause for a `+name`/`-name`/`@name` term, or null when the term names no member. */
|
||||
private fun memberClause(term: String, memberIdsByName: Map<String, Long>, args: MutableList<String>): String? {
|
||||
val prefix = term.first()
|
||||
if (prefix != '+' && prefix != '-' && prefix != '@') return null
|
||||
val memberId = memberIdsByName[term.substring(1).lowercase(Locale.ROOT)] ?: return null
|
||||
val owedByMember = "SELECT $table_bills.$key_id FROM $table_bills INNER JOIN $table_billowers " +
|
||||
"WHERE $key_member_id = ? AND $table_bills.$key_id = $table_billowers.$key_billId"
|
||||
args.add(memberId.toString())
|
||||
return when (prefix) {
|
||||
'+' -> "($key_payer_id = ?)"
|
||||
'-' -> "($key_id IN ($owedByMember))"
|
||||
else -> {
|
||||
args.add(memberId.toString())
|
||||
"(($key_payer_id = ?) OR ($key_id IN ($owedByMember)))"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/** Clause matching a free text term against the description, the comment and the amount. */
|
||||
private fun textClause(term: String, args: MutableList<String>): String {
|
||||
val needle = "%" + term.replace("\\", "\\\\").replace("%", "\\%").replace("_", "\\_") + "%"
|
||||
args.add(needle)
|
||||
args.add(needle)
|
||||
var clause = "(($key_what LIKE ? ESCAPE '\\') OR ($key_comment LIKE ? ESCAPE '\\')"
|
||||
if (SupportUtil.isDouble(term)) {
|
||||
clause += " OR ($key_amount <= (? + $AMOUNT_SEARCH_TOLERANCE) AND " +
|
||||
"$key_amount >= (? - $AMOUNT_SEARCH_TOLERANCE))"
|
||||
args.add(term)
|
||||
args.add(term)
|
||||
}
|
||||
return "$clause)"
|
||||
}
|
||||
|
||||
@WorkerThread
|
||||
@@ -1265,6 +1225,9 @@ class CowspentSQLiteOpenHelper private constructor(val context: Context) :
|
||||
)
|
||||
private const val default_order = "$key_id DESC"
|
||||
|
||||
/** Half width of the window a numeric search term matches, in project currency. */
|
||||
private const val AMOUNT_SEARCH_TOLERANCE = 10
|
||||
|
||||
@Volatile
|
||||
private var instance: CowspentSQLiteOpenHelper? = null
|
||||
|
||||
@@ -1274,5 +1237,15 @@ class CowspentSQLiteOpenHelper private constructor(val context: Context) :
|
||||
instance ?: CowspentSQLiteOpenHelper(context.applicationContext).also { instance = it }
|
||||
}
|
||||
}
|
||||
|
||||
@VisibleForTesting
|
||||
fun setInstance(helper: CowspentSQLiteOpenHelper?) {
|
||||
instance = helper
|
||||
}
|
||||
|
||||
@VisibleForTesting
|
||||
fun resetInstance() {
|
||||
instance = null
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,13 +1,11 @@
|
||||
package net.helcel.cowspent.persistence
|
||||
|
||||
import android.content.ComponentName
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.content.ServiceConnection
|
||||
import android.content.SharedPreferences
|
||||
import android.net.ConnectivityManager
|
||||
import android.os.IBinder
|
||||
import android.util.Log
|
||||
import androidx.annotation.VisibleForTesting
|
||||
import androidx.core.content.edit
|
||||
import androidx.core.graphics.toColorInt
|
||||
import androidx.preference.PreferenceManager
|
||||
@@ -29,6 +27,7 @@ import net.helcel.cowspent.android.account.AccountActivity
|
||||
import net.helcel.cowspent.android.main.BillsListViewActivity
|
||||
import net.helcel.cowspent.android.main.MainConstants
|
||||
import net.helcel.cowspent.model.DBBill
|
||||
import net.helcel.cowspent.model.DBMember
|
||||
import net.helcel.cowspent.model.DBProject
|
||||
import net.helcel.cowspent.model.ProjectType
|
||||
import net.helcel.cowspent.util.CospendClientUtil.LoginStatus
|
||||
@@ -48,24 +47,6 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
private val preferences: SharedPreferences = PreferenceManager.getDefaultSharedPreferences(dbHelper.context)
|
||||
private var networkConnected = false
|
||||
|
||||
private val certService = object : ServiceConnection {
|
||||
override fun onServiceConnected(componentName: ComponentName, iBinder: IBinder) {
|
||||
if (isSyncPossible) {
|
||||
val lastId = PreferenceManager.getDefaultSharedPreferences(dbHelper.context).getLong("selected_project", 0)
|
||||
if (lastId != 0L) {
|
||||
val proj = dbHelper.getProject(lastId)
|
||||
if (proj != null) {
|
||||
appContext.sendBroadcast(Intent(MainConstants.BROADCAST_SYNC_PROJECT))
|
||||
appContext.sendBroadcast(Intent(MainConstants.BROADCAST_NETWORK_AVAILABLE))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun onServiceDisconnected(p0: ComponentName?) {
|
||||
}
|
||||
}
|
||||
|
||||
private var syncActive = false
|
||||
private var syncAccountProjectsActive = false
|
||||
|
||||
@@ -77,29 +58,49 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
updateNetworkStatus()
|
||||
}
|
||||
|
||||
@Throws(Throwable::class)
|
||||
protected fun finalize() {
|
||||
appContext.unbindService(certService)
|
||||
}
|
||||
|
||||
val isSyncPossible: Boolean
|
||||
get() {
|
||||
updateNetworkStatus()
|
||||
return networkConnected
|
||||
val offlineMode = preferences.getBoolean(appContext.getString(R.string.pref_key_offline_mode), false)
|
||||
return networkConnected && !offlineMode
|
||||
}
|
||||
|
||||
fun addCallbackPull(callback: ICallback) {
|
||||
callbacksPull.add(callback)
|
||||
// Callers register on every resume but the list is only drained when a task actually
|
||||
// starts, so refuse duplicates rather than letting the same callback pile up.
|
||||
if (!callbacksPull.contains(callback)) {
|
||||
callbacksPull.add(callback)
|
||||
}
|
||||
}
|
||||
|
||||
fun scheduleSync(onlyLocalChanges: Boolean, projId: Long): SyncTask? {
|
||||
Log.d(TAG, "Sync requested (${if (onlyLocalChanges) "onlyLocalChanges" else "full"}; ${if (syncActive) "sync active" else "sync NOT active"}) ...")
|
||||
fun removeCallbackPull(callback: ICallback) {
|
||||
callbacksPull.remove(callback)
|
||||
}
|
||||
|
||||
fun scheduleSync(onlyLocalChanges: Boolean, projId: Long, forceFullSync: Boolean = false): SyncTask? =
|
||||
scheduleSync(onlyLocalChanges, projId, forceFullSync) { dbHelper.getProject(projId) }
|
||||
|
||||
/**
|
||||
* Overload for callers that already hold the project. Resolving one by id costs a query plus
|
||||
* a blocking DataStore read and an AEAD decrypt in getProjectFromCursor, which adds up when
|
||||
* scheduling a sync for every project at app open.
|
||||
*/
|
||||
fun scheduleSync(onlyLocalChanges: Boolean, project: DBProject, forceFullSync: Boolean = false): SyncTask? =
|
||||
scheduleSync(onlyLocalChanges, project.id, forceFullSync) { project }
|
||||
|
||||
private fun scheduleSync(
|
||||
onlyLocalChanges: Boolean,
|
||||
projId: Long,
|
||||
forceFullSync: Boolean,
|
||||
resolveProject: () -> DBProject?
|
||||
): SyncTask? {
|
||||
Log.d(TAG, "Sync requested (${if (onlyLocalChanges) "onlyLocalChanges" else "full"}; ${if (syncActive) "sync active" else "sync NOT active"}; forceFullSync=$forceFullSync) ...")
|
||||
updateNetworkStatus()
|
||||
if (isSyncPossible && (!syncActive || onlyLocalChanges)) {
|
||||
val project = dbHelper.getProject(projId)
|
||||
val project = resolveProject()
|
||||
if (project != null) {
|
||||
Log.d(TAG, "... starting now")
|
||||
val syncTask = SyncTask(onlyLocalChanges, project)
|
||||
val syncTask = SyncTask(onlyLocalChanges, project, forceFullSync)
|
||||
syncTask.addCallbacks(callbacksPush)
|
||||
callbacksPush = ArrayList()
|
||||
if (!onlyLocalChanges) {
|
||||
@@ -137,7 +138,25 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
}
|
||||
}
|
||||
|
||||
inner class SyncTask(private val onlyLocalChanges: Boolean, private val project: DBProject) {
|
||||
/** The server's ids for the things a bill points at, mapped to their local row ids. */
|
||||
private class RemoteIdMaps(
|
||||
val members: Map<Long, Long>,
|
||||
val categories: Map<Long, Long>,
|
||||
val paymentModes: Map<Long, Long>
|
||||
)
|
||||
|
||||
/** One pull of the bills endpoint. */
|
||||
private class RemoteBills(
|
||||
val bills: List<DBBill>,
|
||||
/**
|
||||
* Every bill id the server holds. Only the complete fetch reports this; after a paged
|
||||
* walk it is empty, and nothing may be deleted locally on the strength of it.
|
||||
*/
|
||||
val allIds: List<Long>,
|
||||
val syncTimestamp: Long?
|
||||
)
|
||||
|
||||
inner class SyncTask(private val onlyLocalChanges: Boolean, private val project: DBProject, private val forceFullSync: Boolean = false) {
|
||||
private val callbacks: MutableList<ICallback> = ArrayList()
|
||||
private var nextcloudClient: NextcloudClient? = null
|
||||
private var client: VersatileProjectSyncClient? = null
|
||||
@@ -529,298 +548,37 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Brings the local copy of the project in line with the server: its own row, then each of
|
||||
* its collections, then its bills. Each step is applied as it goes, so a failure part way
|
||||
* through leaves the earlier steps written - the next sync picks up where this one stopped.
|
||||
*/
|
||||
private fun pullRemoteChanges(): LoginStatus {
|
||||
Log.d(TAG, "pullRemoteChanges($project)")
|
||||
val lastETag: String? = null
|
||||
val lastModified: Long = 0
|
||||
return try {
|
||||
val projResponse = client!!.getProject(project, lastModified, lastETag)
|
||||
Log.d(TAG,projResponse.toString())
|
||||
val name = projResponse.name
|
||||
Log.i(TAG, "AAA getProjectInfo, project name: $name")
|
||||
val email = projResponse.email
|
||||
val currencyName = projResponse.currencyName
|
||||
val deletionDisabled = projResponse.deletionDisabled
|
||||
val myAccessLevel = projResponse.myAccessLevel
|
||||
val archivedTs = projResponse.archivedTs
|
||||
val projResponse = client!!.getProject(project, 0, null)
|
||||
|
||||
if (project.name == "" || name != project.name || project.email == null || project.email == "" || project.isDeletionDisabled != deletionDisabled || project.myAccessLevel != myAccessLevel || project.archivedTs != archivedTs || (project.currencyName == null) || (currencyName != project.currencyName) || email != project.email
|
||||
) {
|
||||
Log.d(TAG, "update local project : $project")
|
||||
project.name = name
|
||||
project.currencyName = currencyName
|
||||
project.isDeletionDisabled = deletionDisabled
|
||||
project.myAccessLevel = myAccessLevel
|
||||
project.archivedTs = archivedTs
|
||||
dbHelper.updateProject(
|
||||
projId = project.id,
|
||||
newName = name,
|
||||
newEmail = email,
|
||||
newPassword = null,
|
||||
newLastPayerId = null,
|
||||
newLastSyncedTimestamp = null,
|
||||
newCurrencyName = currencyName,
|
||||
newDeletionDisabled = deletionDisabled,
|
||||
newMyAccessLevel = myAccessLevel,
|
||||
newBearerToken = null,
|
||||
newArchivedTs = archivedTs ?: 0L
|
||||
)
|
||||
}
|
||||
updateLocalProject(projResponse)
|
||||
syncPaymentModes(projResponse)
|
||||
syncCategories(projResponse)
|
||||
syncCurrencies(projResponse)
|
||||
val remoteMembersByRemoteId = syncMembers(projResponse)
|
||||
|
||||
val remotePaymentModes = projResponse.getPaymentModes(project.id)
|
||||
val remotePaymentModesByRemoteId = remotePaymentModes.associateBy { it.remoteId }
|
||||
// Bills arrive with the server's ids for their member, category and payment mode,
|
||||
// so the maps have to be built after those collections are in place.
|
||||
val idMaps = buildRemoteIdMaps()
|
||||
|
||||
for (pm in remotePaymentModes) {
|
||||
val localPaymentMode = dbHelper.getPaymentMode(pm.remoteId, project.id)
|
||||
if (localPaymentMode == null) {
|
||||
Log.d(TAG, "Add local pm : $pm")
|
||||
dbHelper.addPaymentMode(pm)
|
||||
} else {
|
||||
if (pm.name == localPaymentMode.name &&
|
||||
pm.color == localPaymentMode.color &&
|
||||
pm.icon == localPaymentMode.icon
|
||||
) {
|
||||
Log.d(TAG, "Nothing to do for pm : $localPaymentMode")
|
||||
} else {
|
||||
Log.d(TAG, "Update local pm : $pm")
|
||||
dbHelper.updatePaymentMode(localPaymentMode.id, pm.name, pm.icon, pm.color)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
val localPaymentModes = dbHelper.getPaymentModes(project.id)
|
||||
for (localPaymentMode in localPaymentModes) {
|
||||
if (localPaymentMode.state == DBBill.STATE_OK && !remotePaymentModesByRemoteId.containsKey(localPaymentMode.remoteId)) {
|
||||
dbHelper.deletePaymentMode(localPaymentMode.id)
|
||||
Log.d(TAG, "Delete local pm : $localPaymentMode")
|
||||
}
|
||||
}
|
||||
|
||||
val remoteCategories = projResponse.getCategories(project.id)
|
||||
val remoteCategoriesByRemoteId = remoteCategories.associateBy { it.remoteId }
|
||||
|
||||
for (c in remoteCategories) {
|
||||
if (c.remoteId == DBBill.CATEGORY_REIMBURSEMENT) continue
|
||||
val localCategory = dbHelper.getCategory(c.remoteId, project.id)
|
||||
if (localCategory == null) {
|
||||
Log.d(TAG, "Add local category : $c")
|
||||
dbHelper.addCategory(c)
|
||||
} else {
|
||||
if (c.name == localCategory.name &&
|
||||
c.color == localCategory.color &&
|
||||
c.icon == localCategory.icon
|
||||
) {
|
||||
Log.d(TAG, "Nothing to do for category : $localCategory")
|
||||
} else {
|
||||
Log.d(TAG, "Update local category : $c")
|
||||
dbHelper.updateCategory(localCategory.id, c.name, c.icon, c.color)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
val localCategories = dbHelper.getCategories(project.id)
|
||||
for (localCategory in localCategories) {
|
||||
if (localCategory.state == DBBill.STATE_OK && !remoteCategoriesByRemoteId.containsKey(localCategory.remoteId)) {
|
||||
dbHelper.deleteCategory(localCategory.id)
|
||||
Log.d(TAG, "Delete local category : $localCategory")
|
||||
}
|
||||
}
|
||||
|
||||
val remoteCurrencies = projResponse.getCurrencies(project.id)
|
||||
val remoteCurrenciesByRemoteId = remoteCurrencies.associateBy { it.remoteId }
|
||||
|
||||
for (c in remoteCurrencies) {
|
||||
val localCurrency = dbHelper.getCurrency(c.remoteId, project.id)
|
||||
if (localCurrency == null) {
|
||||
Log.d(TAG, "Add local currency : $c")
|
||||
dbHelper.addCurrency(c)
|
||||
} else {
|
||||
if (c.name == localCurrency.name &&
|
||||
c.exchangeRate == localCurrency.exchangeRate
|
||||
) {
|
||||
Log.d(TAG, "Nothing to do for currency : $localCurrency")
|
||||
} else {
|
||||
Log.d(TAG, "Update local currency : $c")
|
||||
dbHelper.updateCurrency(localCurrency.id, c.name, c.exchangeRate)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
val localCurrencies = dbHelper.getCurrencies(project.id)
|
||||
for (localCurrency in localCurrencies) {
|
||||
if (localCurrency.state == DBBill.STATE_OK && !remoteCurrenciesByRemoteId.containsKey(localCurrency.remoteId)) {
|
||||
dbHelper.deleteCurrency(localCurrency.id)
|
||||
Log.d(TAG, "Delete local currency : $localCurrencies")
|
||||
}
|
||||
}
|
||||
|
||||
val remoteMembers = projResponse.getMembers(project.id)
|
||||
val remoteMembersByRemoteId = remoteMembers.associateBy { it.remoteId }
|
||||
|
||||
for (m in remoteMembers) {
|
||||
val localMember = dbHelper.getMember(m.remoteId, project.id)
|
||||
if (localMember == null) {
|
||||
Log.d(TAG, "Add local member : $m")
|
||||
val mid = dbHelper.addMember(m)
|
||||
if (!m.ncUserId.isNullOrEmpty()) {
|
||||
updateMemberAvatar(mid)
|
||||
}
|
||||
} else {
|
||||
val ncUserIdChanged = (
|
||||
(m.ncUserId == null && localMember.ncUserId != null) ||
|
||||
(m.ncUserId != null && localMember.ncUserId == null) ||
|
||||
(m.ncUserId != null && m.ncUserId != localMember.ncUserId)
|
||||
)
|
||||
Log.e("PULLREMOTE", "member NC user id : ${localMember.ncUserId} => ${m.ncUserId} ID changed $ncUserIdChanged")
|
||||
if (ncUserIdChanged && m.ncUserId == null) {
|
||||
m.ncUserId = ""
|
||||
}
|
||||
if (m.name == localMember.name &&
|
||||
m.weight == localMember.weight &&
|
||||
m.isActivated == localMember.isActivated &&
|
||||
((m.r == null && m.g == null && m.b == null) ||
|
||||
(m.r == localMember.r && m.g == localMember.g && m.b == localMember.b)) &&
|
||||
!ncUserIdChanged
|
||||
) {
|
||||
Log.d(TAG, "Nothing to do for member : $localMember")
|
||||
if (!localMember.ncUserId.isNullOrEmpty() && localMember.avatar.isNullOrEmpty()) {
|
||||
Log.d(TAG, "except updating avatar")
|
||||
updateMemberAvatar(localMember.id)
|
||||
}
|
||||
} else {
|
||||
Log.d(TAG, "Update local member : $m")
|
||||
var r = m.r
|
||||
var g = m.g
|
||||
var b = m.b
|
||||
if (m.r == null && m.g == null && m.b == null) {
|
||||
r = localMember.r
|
||||
g = localMember.g
|
||||
b = localMember.b
|
||||
}
|
||||
val needAvatarUpdate = (ncUserIdChanged && !m.ncUserId.isNullOrEmpty())
|
||||
val newAvatar = if (ncUserIdChanged) "" else null
|
||||
dbHelper.updateMember(
|
||||
localMember.id, m.name, m.weight,
|
||||
m.isActivated, null, null,
|
||||
r, g, b, m.ncUserId, newAvatar
|
||||
)
|
||||
if (needAvatarUpdate) {
|
||||
Log.e("PLOP", "pullremote : update member avatar")
|
||||
updateMemberAvatar(localMember.id)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
val dbMembers = dbHelper.getMembersOfProject(project.id, null)
|
||||
val memberRemoteIdToId = dbMembers.associate { it.remoteId to it.id }
|
||||
|
||||
val dbCategories = dbHelper.getCategories(project.id)
|
||||
val categoriesRemoteIdToId = dbCategories.associate { it.remoteId to it.id }.toMutableMap()
|
||||
// Map hardcoded constants to their local IDs if they exist in DB, else to themselves
|
||||
categoriesRemoteIdToId[DBBill.CATEGORY_REIMBURSEMENT] = DBBill.CATEGORY_REIMBURSEMENT
|
||||
dbCategories.filter { it.remoteId < 0 }.forEach { categoriesRemoteIdToId[it.remoteId] = it.id }
|
||||
|
||||
val dbPaymentModes = dbHelper.getPaymentModes(project.id)
|
||||
val paymentModesRemoteIdToId = dbPaymentModes.associate { it.remoteId to it.id }.toMutableMap()
|
||||
dbPaymentModes.filter { it.remoteId < 0 }.forEach { paymentModesRemoteIdToId[it.remoteId] = it.id }
|
||||
|
||||
val billsResponse = client!!.getBills(project)
|
||||
val isIHM = project.type == ProjectType.IHATEMONEY
|
||||
val serverSyncTimestamp = if (isIHM) 0L else billsResponse.syncTimestamp
|
||||
val remoteBills: List<DBBill> = if (isIHM) {
|
||||
billsResponse.getBillsIHM(project.id, memberRemoteIdToId, categoriesRemoteIdToId, paymentModesRemoteIdToId)
|
||||
} else {
|
||||
billsResponse.getBillsCospend(project.id, memberRemoteIdToId, categoriesRemoteIdToId, paymentModesRemoteIdToId)
|
||||
}
|
||||
val remoteAllBillIds: List<Long> = if (isIHM) {
|
||||
remoteBills.map { it.remoteId }
|
||||
} else {
|
||||
billsResponse.allBillIds
|
||||
}
|
||||
|
||||
val remoteBillsByRemoteId = remoteBills.associateBy { it.remoteId }
|
||||
val localBills = dbHelper.getBillsOfProject(project.id)
|
||||
val localBillsByRemoteId = localBills.associateBy { it.remoteId }
|
||||
val pulled = fetchRemoteBills(idMaps, localBillsByRemoteId)
|
||||
|
||||
for (remoteBill in remoteBills) {
|
||||
if (!localBillsByRemoteId.containsKey(remoteBill.remoteId)) {
|
||||
dbHelper.addBill(remoteBill)
|
||||
nbPulledNewBills++
|
||||
newBillsDialogText += "+ ${remoteBill.what}\n"
|
||||
} else {
|
||||
val localBill = localBillsByRemoteId[remoteBill.remoteId]!!
|
||||
if (hasChanged(localBill, remoteBill)) {
|
||||
dbHelper.updateBill(
|
||||
localBill.id, null, remoteBill.payerId,
|
||||
remoteBill.amount, remoteBill.timestamp,
|
||||
remoteBill.what, DBBill.STATE_OK, remoteBill.repeat,
|
||||
remoteBill.paymentMode, remoteBill.paymentModeId,
|
||||
remoteBill.categoryId, remoteBill.comment
|
||||
)
|
||||
nbPulledUpdatedBills++
|
||||
updatedBillsDialogText += "✏ ${remoteBill.what}\n"
|
||||
} else {
|
||||
Log.d(TAG, "Nothing to do for bill : $localBill")
|
||||
}
|
||||
|
||||
val localBillOwersByIds = localBill.billOwers.associateBy { it.memberId }
|
||||
val remoteBillOwersByIds = remoteBill.billOwers.associateBy { it.memberId }
|
||||
|
||||
for (rbo in remoteBill.billOwers) {
|
||||
if (!localBillOwersByIds.containsKey(rbo.memberId)) {
|
||||
dbHelper.addBillower(localBill.id, rbo.memberId)
|
||||
Log.d(TAG, "Add local billOwer : $rbo")
|
||||
}
|
||||
}
|
||||
for (lbo in localBill.billOwers) {
|
||||
if (!remoteBillOwersByIds.containsKey(lbo.memberId)) {
|
||||
dbHelper.deleteBillOwer(lbo.id)
|
||||
Log.d(TAG, "Delete local billOwer : $lbo")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (project.type == ProjectType.COSPEND || project.type == ProjectType.IHATEMONEY) {
|
||||
for (localBill in localBills) {
|
||||
if (!remoteAllBillIds.contains(localBill.remoteId)) {
|
||||
dbHelper.deleteBill(localBill.id)
|
||||
nbPulledDeletedBills++
|
||||
deletedBillsDialogText += "🗑 ${localBill.what}\n"
|
||||
Log.d(TAG, "Delete local bill : $localBill")
|
||||
}
|
||||
}
|
||||
} else {
|
||||
for (localBill in localBills) {
|
||||
if (!remoteBillsByRemoteId.containsKey(localBill.remoteId)) {
|
||||
dbHelper.deleteBill(localBill.id)
|
||||
nbPulledDeletedBills++
|
||||
deletedBillsDialogText += "🗑 ${localBill.what}\n"
|
||||
Log.d(TAG, "Delete local bill : $localBill")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
val localMembers = dbHelper.getMembersOfProject(project.id, null)
|
||||
for (localMember in localMembers) {
|
||||
if (!remoteMembersByRemoteId.containsKey(localMember.remoteId)) {
|
||||
if (dbHelper.getBillsOfMember(localMember.id).isEmpty()
|
||||
&& dbHelper.getBillowersOfMember(localMember.id).isEmpty()
|
||||
) {
|
||||
dbHelper.deleteMember(localMember.id)
|
||||
Log.d(TAG, "Delete local member : $localMember")
|
||||
} else {
|
||||
Log.d(TAG, "WARNING local member : ${localMember.name} does not exist remotely but is still involved in some bills")
|
||||
}
|
||||
}
|
||||
}
|
||||
applyRemoteBills(pulled.bills, localBillsByRemoteId)
|
||||
deleteVanishedBills(pulled, localBills)
|
||||
deleteVanishedMembers(remoteMembersByRemoteId)
|
||||
|
||||
dbHelper.updateProject(
|
||||
project.id, null, null,
|
||||
null, null, serverSyncTimestamp,
|
||||
null, null, null,
|
||||
null
|
||||
projId = project.id,
|
||||
newLastSyncedTimestamp = pulled.syncTimestamp
|
||||
)
|
||||
LoginStatus.OK
|
||||
} catch (_: ServerResponse.NotModifiedException) {
|
||||
@@ -844,6 +602,394 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
LoginStatus.REQ_FAILED
|
||||
}
|
||||
}
|
||||
private fun updateLocalProject(projResponse: ServerResponse.ProjectResponse) {
|
||||
val name = projResponse.name
|
||||
val email = projResponse.email
|
||||
val currencyName = projResponse.currencyName
|
||||
val deletionDisabled = projResponse.deletionDisabled
|
||||
val myAccessLevel = projResponse.myAccessLevel
|
||||
val archivedTs = projResponse.archivedTs
|
||||
|
||||
val unchanged = project.name.isNotEmpty() &&
|
||||
name == project.name &&
|
||||
!project.email.isNullOrEmpty() &&
|
||||
email == project.email &&
|
||||
project.isDeletionDisabled == deletionDisabled &&
|
||||
project.myAccessLevel == myAccessLevel &&
|
||||
project.archivedTs == archivedTs &&
|
||||
project.currencyName != null &&
|
||||
currencyName == project.currencyName
|
||||
if (unchanged) return
|
||||
|
||||
Log.d(TAG, "update local project : $project")
|
||||
project.name = name
|
||||
project.currencyName = currencyName
|
||||
project.isDeletionDisabled = deletionDisabled
|
||||
project.myAccessLevel = myAccessLevel
|
||||
project.archivedTs = archivedTs
|
||||
dbHelper.updateProject(
|
||||
projId = project.id,
|
||||
newName = name,
|
||||
newEmail = email,
|
||||
newPassword = null,
|
||||
newLastPayerId = null,
|
||||
newLastSyncedTimestamp = null,
|
||||
newCurrencyName = currencyName,
|
||||
newDeletionDisabled = deletionDisabled,
|
||||
newMyAccessLevel = myAccessLevel,
|
||||
newBearerToken = null,
|
||||
newArchivedTs = archivedTs ?: 0L
|
||||
)
|
||||
}
|
||||
|
||||
private fun syncPaymentModes(projResponse: ServerResponse.ProjectResponse) {
|
||||
val remote = projResponse.getPaymentModes(project.id)
|
||||
for (pm in remote) {
|
||||
val local = dbHelper.getPaymentMode(pm.remoteId, project.id)
|
||||
if (local == null) {
|
||||
Log.d(TAG, "Add local pm : $pm")
|
||||
dbHelper.addPaymentMode(pm)
|
||||
} else if (pm.name == local.name && pm.color == local.color && pm.icon == local.icon) {
|
||||
Log.d(TAG, "Nothing to do for pm : $local")
|
||||
} else {
|
||||
Log.d(TAG, "Update local pm : $pm")
|
||||
dbHelper.updatePaymentMode(local.id, pm.name, pm.icon, pm.color)
|
||||
}
|
||||
}
|
||||
|
||||
// Only settled rows may be dropped; one still waiting to be pushed is not "gone".
|
||||
val remoteIds = remote.map { it.remoteId }.toSet()
|
||||
for (local in dbHelper.getPaymentModes(project.id)) {
|
||||
if (local.state == DBBill.STATE_OK && local.remoteId !in remoteIds) {
|
||||
dbHelper.deletePaymentMode(local.id)
|
||||
Log.d(TAG, "Delete local pm : $local")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun syncCategories(projResponse: ServerResponse.ProjectResponse) {
|
||||
val remote = projResponse.getCategories(project.id)
|
||||
for (c in remote) {
|
||||
if (c.remoteId == DBBill.CATEGORY_REIMBURSEMENT) continue
|
||||
val local = dbHelper.getCategory(c.remoteId, project.id)
|
||||
if (local == null) {
|
||||
Log.d(TAG, "Add local category : $c")
|
||||
dbHelper.addCategory(c)
|
||||
} else if (c.name == local.name && c.color == local.color && c.icon == local.icon) {
|
||||
Log.d(TAG, "Nothing to do for category : $local")
|
||||
} else {
|
||||
Log.d(TAG, "Update local category : $c")
|
||||
dbHelper.updateCategory(local.id, c.name, c.icon, c.color)
|
||||
}
|
||||
}
|
||||
|
||||
val remoteIds = remote.map { it.remoteId }.toSet()
|
||||
for (local in dbHelper.getCategories(project.id)) {
|
||||
if (local.state == DBBill.STATE_OK && local.remoteId !in remoteIds) {
|
||||
dbHelper.deleteCategory(local.id)
|
||||
Log.d(TAG, "Delete local category : $local")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun syncCurrencies(projResponse: ServerResponse.ProjectResponse) {
|
||||
val remote = projResponse.getCurrencies(project.id)
|
||||
for (c in remote) {
|
||||
val local = dbHelper.getCurrency(c.remoteId, project.id)
|
||||
if (local == null) {
|
||||
Log.d(TAG, "Add local currency : $c")
|
||||
dbHelper.addCurrency(c)
|
||||
} else if (c.name == local.name && c.exchangeRate == local.exchangeRate) {
|
||||
Log.d(TAG, "Nothing to do for currency : $local")
|
||||
} else {
|
||||
Log.d(TAG, "Update local currency : $c")
|
||||
dbHelper.updateCurrency(local.id, c.name, c.exchangeRate)
|
||||
}
|
||||
}
|
||||
|
||||
val remoteIds = remote.map { it.remoteId }.toSet()
|
||||
for (local in dbHelper.getCurrencies(project.id)) {
|
||||
if (local.state == DBBill.STATE_OK && local.remoteId !in remoteIds) {
|
||||
dbHelper.deleteCurrency(local.id)
|
||||
Log.d(TAG, "Delete local currency : $local")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/** Returns the members the server listed, keyed by remote id, for the later cleanup pass. */
|
||||
private fun syncMembers(projResponse: ServerResponse.ProjectResponse): Map<Long, DBMember> {
|
||||
val remote = projResponse.getMembers(project.id)
|
||||
for (m in remote) {
|
||||
val local = dbHelper.getMember(m.remoteId, project.id)
|
||||
if (local == null) {
|
||||
Log.d(TAG, "Add local member : $m")
|
||||
val mid = dbHelper.addMember(m)
|
||||
if (!m.ncUserId.isNullOrEmpty()) {
|
||||
updateMemberAvatar(mid)
|
||||
}
|
||||
} else {
|
||||
updateLocalMember(m, local)
|
||||
}
|
||||
}
|
||||
return remote.associateBy { it.remoteId }
|
||||
}
|
||||
|
||||
private fun updateLocalMember(remote: DBMember, local: DBMember) {
|
||||
val ncUserIdChanged = remote.ncUserId != local.ncUserId
|
||||
Log.d(TAG, "member NC user id : ${local.ncUserId} => ${remote.ncUserId} ID changed $ncUserIdChanged")
|
||||
if (ncUserIdChanged && remote.ncUserId == null) {
|
||||
remote.ncUserId = ""
|
||||
}
|
||||
|
||||
// The server omits colours it has never been told about, which is not the same as
|
||||
// clearing them, so a null triple means "unchanged" rather than "no colour".
|
||||
val remoteHasNoColour = remote.r == null && remote.g == null && remote.b == null
|
||||
val colourUnchanged = remoteHasNoColour ||
|
||||
(remote.r == local.r && remote.g == local.g && remote.b == local.b)
|
||||
|
||||
if (remote.name == local.name && remote.weight == local.weight &&
|
||||
remote.isActivated == local.isActivated && colourUnchanged && !ncUserIdChanged
|
||||
) {
|
||||
Log.d(TAG, "Nothing to do for member : $local")
|
||||
if (!local.ncUserId.isNullOrEmpty() && local.avatar.isNullOrEmpty()) {
|
||||
Log.d(TAG, "except updating avatar")
|
||||
updateMemberAvatar(local.id)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
Log.d(TAG, "Update local member : $remote")
|
||||
val r = if (remoteHasNoColour) local.r else remote.r
|
||||
val g = if (remoteHasNoColour) local.g else remote.g
|
||||
val b = if (remoteHasNoColour) local.b else remote.b
|
||||
val needAvatarUpdate = ncUserIdChanged && !remote.ncUserId.isNullOrEmpty()
|
||||
dbHelper.updateMember(
|
||||
local.id, remote.name, remote.weight,
|
||||
remote.isActivated, null, null,
|
||||
r, g, b, remote.ncUserId, if (ncUserIdChanged) "" else null
|
||||
)
|
||||
if (needAvatarUpdate) {
|
||||
updateMemberAvatar(local.id)
|
||||
}
|
||||
}
|
||||
|
||||
private fun buildRemoteIdMaps(): RemoteIdMaps {
|
||||
val members = dbHelper.getMembersOfProject(project.id, null)
|
||||
.associate { it.remoteId to it.id }
|
||||
|
||||
val categories = dbHelper.getCategories(project.id)
|
||||
.associate { it.remoteId to it.id }
|
||||
.toMutableMap()
|
||||
// The built-in categories keep their negative ids rather than getting local rows.
|
||||
categories[DBBill.CATEGORY_REIMBURSEMENT] = DBBill.CATEGORY_REIMBURSEMENT
|
||||
dbHelper.getCategories(project.id).filter { it.remoteId < 0 }
|
||||
.forEach { categories[it.remoteId] = it.id }
|
||||
|
||||
val paymentModes = dbHelper.getPaymentModes(project.id)
|
||||
.associate { it.remoteId to it.id }
|
||||
.toMutableMap()
|
||||
dbHelper.getPaymentModes(project.id).filter { it.remoteId < 0 }
|
||||
.forEach { paymentModes[it.remoteId] = it.id }
|
||||
|
||||
return RemoteIdMaps(members, categories, paymentModes)
|
||||
}
|
||||
|
||||
/**
|
||||
* Fetches the bills, by paged walk where the server supports one and by complete fetch
|
||||
* otherwise. Falls back to the complete fetch whenever the walk cannot be trusted, so the
|
||||
* caller always gets a usable result.
|
||||
*/
|
||||
private fun fetchRemoteBills(
|
||||
idMaps: RemoteIdMaps,
|
||||
localBillsByRemoteId: Map<Long, DBBill>
|
||||
): RemoteBills {
|
||||
val usePagedWalk = project.type == ProjectType.COSPEND && !forceFullSync &&
|
||||
localBillsByRemoteId.isNotEmpty() && client!!.supportsPagedBills
|
||||
if (usePagedWalk) {
|
||||
walkBillPages(idMaps, localBillsByRemoteId)?.let { return it }
|
||||
}
|
||||
return fetchAllBills(idMaps)
|
||||
}
|
||||
|
||||
/**
|
||||
* Walks back through pages of bills, newest first, until it has seen a run of
|
||||
* [UNCHANGED_RUN_TO_SETTLE] consecutive bills that already match locally - at which point
|
||||
* everything older is taken on trust.
|
||||
*
|
||||
* That only terminates while the server really does reverse the order and honour the
|
||||
* offset. One that does neither returns the same oldest-first page every time, and since
|
||||
* the walk compares against local rows it never writes, a single unknown bill keeps the
|
||||
* run at zero and the same page is requested forever. Returns null when the responses
|
||||
* show that happening, so the caller can fall back to the complete fetch.
|
||||
*/
|
||||
private fun walkBillPages(
|
||||
idMaps: RemoteIdMaps,
|
||||
localBillsByRemoteId: Map<Long, DBBill>
|
||||
): RemoteBills? {
|
||||
Log.d(TAG, "Starting partial sync for project ${project.remoteId}")
|
||||
val limit = 50
|
||||
val bills = mutableListOf<DBBill>()
|
||||
var syncTimestamp = project.lastSyncedTimestamp
|
||||
var offset = 0
|
||||
var previousPageIds: List<Long>? = null
|
||||
// Counted across pages, not restarted at each one: a run that begins near the end of
|
||||
// a page still finishes on the next.
|
||||
var unchangedRun = 0
|
||||
|
||||
while (true) {
|
||||
val response = client!!.getBills(project, offset, limit, true, 0)
|
||||
val page = response.getBillsCospend(
|
||||
project.id, idMaps.members, idMaps.categories, idMaps.paymentModes
|
||||
)
|
||||
if (page.isEmpty()) break
|
||||
|
||||
if (page.first().timestamp < page.last().timestamp) {
|
||||
Log.w(TAG, "Server returned bills oldest-first; the paged walk cannot be trusted")
|
||||
return null
|
||||
}
|
||||
val pageIds = page.map { it.remoteId }
|
||||
if (pageIds == previousPageIds) {
|
||||
Log.w(TAG, "Server returned the same page for offset $offset; it is ignoring the offset")
|
||||
return null
|
||||
}
|
||||
previousPageIds = pageIds
|
||||
|
||||
bills.addAll(page)
|
||||
if (offset == 0 && response.syncTimestamp > 0) {
|
||||
syncTimestamp = response.syncTimestamp
|
||||
}
|
||||
|
||||
var settled = false
|
||||
for (remote in page) {
|
||||
val local = localBillsByRemoteId[remote.remoteId]
|
||||
if (local != null && !hasChanged(local, remote)) {
|
||||
unchangedRun++
|
||||
if (unchangedRun >= UNCHANGED_RUN_TO_SETTLE) {
|
||||
settled = true
|
||||
break
|
||||
}
|
||||
} else {
|
||||
unchangedRun = 0
|
||||
}
|
||||
}
|
||||
|
||||
// A short page is the end of the collection: there is nothing older to walk back
|
||||
// to, so asking for the next offset would only refetch it.
|
||||
if (settled || page.size < limit) break
|
||||
offset += limit
|
||||
}
|
||||
|
||||
// A walk reports no allIds, so it never causes a local deletion.
|
||||
return RemoteBills(bills, emptyList(), syncTimestamp)
|
||||
}
|
||||
|
||||
private fun fetchAllBills(idMaps: RemoteIdMaps): RemoteBills {
|
||||
Log.d(TAG, "Starting full sync for project ${project.remoteId}")
|
||||
val response = client!!.getBills(project)
|
||||
return if (project.type == ProjectType.IHATEMONEY) {
|
||||
val bills = response.getBillsIHM(
|
||||
project.id, idMaps.members, idMaps.categories, idMaps.paymentModes
|
||||
)
|
||||
RemoteBills(bills, bills.map { it.remoteId }, 0L)
|
||||
} else {
|
||||
RemoteBills(
|
||||
response.getBillsCospend(
|
||||
project.id, idMaps.members, idMaps.categories, idMaps.paymentModes
|
||||
),
|
||||
response.allBillIds,
|
||||
response.syncTimestamp
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
private fun applyRemoteBills(
|
||||
remoteBills: List<DBBill>,
|
||||
localBillsByRemoteId: Map<Long, DBBill>
|
||||
) {
|
||||
for (remoteBill in remoteBills) {
|
||||
val localBill = localBillsByRemoteId[remoteBill.remoteId]
|
||||
if (localBill == null) {
|
||||
dbHelper.addBill(remoteBill)
|
||||
nbPulledNewBills++
|
||||
newBillsDialogText += "+ ${remoteBill.what}\n"
|
||||
continue
|
||||
}
|
||||
|
||||
if (hasChanged(localBill, remoteBill)) {
|
||||
dbHelper.updateBill(
|
||||
localBill.id, null, remoteBill.payerId,
|
||||
remoteBill.amount, remoteBill.timestamp,
|
||||
remoteBill.what, DBBill.STATE_OK, remoteBill.repeat,
|
||||
remoteBill.paymentMode, remoteBill.paymentModeId,
|
||||
remoteBill.categoryId, remoteBill.comment
|
||||
)
|
||||
nbPulledUpdatedBills++
|
||||
updatedBillsDialogText += "✏ ${remoteBill.what}\n"
|
||||
} else {
|
||||
Log.d(TAG, "Nothing to do for bill : $localBill")
|
||||
}
|
||||
|
||||
syncBillOwers(localBill, remoteBill)
|
||||
}
|
||||
}
|
||||
|
||||
private fun syncBillOwers(localBill: DBBill, remoteBill: DBBill) {
|
||||
val localMemberIds = localBill.billOwers.map { it.memberId }.toSet()
|
||||
val remoteMemberIds = remoteBill.billOwers.map { it.memberId }.toSet()
|
||||
|
||||
for (rbo in remoteBill.billOwers) {
|
||||
if (rbo.memberId !in localMemberIds) {
|
||||
dbHelper.addBillower(localBill.id, rbo.memberId)
|
||||
Log.d(TAG, "Add local billOwer : $rbo")
|
||||
}
|
||||
}
|
||||
for (lbo in localBill.billOwers) {
|
||||
if (lbo.memberId !in remoteMemberIds) {
|
||||
dbHelper.deleteBillOwer(lbo.id)
|
||||
Log.d(TAG, "Delete local billOwer : $lbo")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Drops local bills the server no longer has. An empty allIds means the server never told
|
||||
* us the full set - after a paged walk, say - and nothing may be deleted on that basis.
|
||||
*/
|
||||
private fun deleteVanishedBills(pulled: RemoteBills, localBills: List<DBBill>) {
|
||||
if (pulled.allIds.isEmpty()) return
|
||||
|
||||
val stillRemote: Set<Long> =
|
||||
if (project.type == ProjectType.COSPEND || project.type == ProjectType.IHATEMONEY) {
|
||||
pulled.allIds.toSet()
|
||||
} else {
|
||||
pulled.bills.map { it.remoteId }.toSet()
|
||||
}
|
||||
|
||||
for (localBill in localBills) {
|
||||
if (localBill.remoteId !in stillRemote) {
|
||||
dbHelper.deleteBill(localBill.id)
|
||||
nbPulledDeletedBills++
|
||||
deletedBillsDialogText += "🗑 ${localBill.what}\n"
|
||||
Log.d(TAG, "Delete local bill : $localBill")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun deleteVanishedMembers(remoteMembersByRemoteId: Map<Long, DBMember>) {
|
||||
for (localMember in dbHelper.getMembersOfProject(project.id, null)) {
|
||||
if (remoteMembersByRemoteId.containsKey(localMember.remoteId)) continue
|
||||
|
||||
// A member still named by a bill cannot be removed without orphaning it.
|
||||
if (dbHelper.getBillsOfMember(localMember.id).isEmpty() &&
|
||||
dbHelper.getBillowersOfMember(localMember.id).isEmpty()
|
||||
) {
|
||||
dbHelper.deleteMember(localMember.id)
|
||||
Log.d(TAG, "Delete local member : $localMember")
|
||||
} else {
|
||||
Log.d(TAG, "WARNING local member : ${localMember.name} does not exist remotely but is still involved in some bills")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun onPostExecute(status: LoginStatus) {
|
||||
if (status != LoginStatus.OK) {
|
||||
@@ -935,11 +1081,18 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
return isCospend && projUrl == accountUrl
|
||||
}
|
||||
|
||||
fun editRemoteProject(projId: Long, newName: String?, newEmail: String?,
|
||||
newPassword: String?, newMainCurrencyName: String?, callback: ICallback): Boolean {
|
||||
fun editRemoteProject(
|
||||
projId: Long,
|
||||
newName: String? = null,
|
||||
newEmail: String? = null,
|
||||
newPassword: String? = null,
|
||||
newMainCurrencyName: String? = null,
|
||||
newArchivedTs: Long? = null,
|
||||
callback: ICallback
|
||||
): Boolean {
|
||||
updateNetworkStatus()
|
||||
if (isSyncPossible) {
|
||||
EditRemoteProjectTask(projId, newName, newEmail, newPassword, newMainCurrencyName, callback).execute()
|
||||
EditRemoteProjectTask(projId, newName, newEmail, newPassword, newMainCurrencyName, newArchivedTs, callback).execute()
|
||||
return true
|
||||
}
|
||||
return false
|
||||
@@ -951,6 +1104,7 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
private val newEmail: String?,
|
||||
private val newPassword: String?,
|
||||
private val newMainCurrencyName: String?,
|
||||
private val newArchivedTs: Long?,
|
||||
private val callback: ICallback
|
||||
) {
|
||||
private val project: DBProject? = dbHelper.getProject(projId)
|
||||
@@ -984,8 +1138,21 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
}
|
||||
var status = LoginStatus.OK
|
||||
try {
|
||||
// Pass current project values if the new ones are null to ensure a complete project object is sent to the server
|
||||
val currentProj = project!!
|
||||
val finalName = (newName ?: currentProj.name).let { if (it.isBlank() || it == "null") currentProj.remoteId else it }
|
||||
// Stay null when the project has no main currency, so the PUT omits currencyName
|
||||
// instead of silently setting the server-side currency.
|
||||
val finalCurrency = (newMainCurrencyName ?: currentProj.currencyName)
|
||||
?.takeUnless { it.isBlank() || it == "null" }
|
||||
|
||||
val response = client!!.editRemoteProject(
|
||||
project!!, newName, newEmail, newPassword, newMainCurrencyName
|
||||
currentProj,
|
||||
finalName,
|
||||
newEmail ?: currentProj.email,
|
||||
newPassword,
|
||||
finalCurrency,
|
||||
newArchivedTs
|
||||
)
|
||||
if (BillsListViewActivity.DEBUG) {
|
||||
Log.i(TAG, "RESPONSE edit remote project : ${response.stringContent}")
|
||||
@@ -1025,8 +1192,11 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
}
|
||||
} else {
|
||||
dbHelper.updateProject(
|
||||
project!!.id, newName, newEmail, newPassword,
|
||||
null, null, null, null, null, null
|
||||
projId = project!!.id,
|
||||
newName = newName,
|
||||
newEmail = newEmail,
|
||||
newPassword = newPassword,
|
||||
newArchivedTs = newArchivedTs
|
||||
)
|
||||
}
|
||||
callback.onFinish(newName ?: "", errorString)
|
||||
@@ -1205,7 +1375,7 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
}
|
||||
}
|
||||
|
||||
private fun hasChanged(localBill: DBBill, remoteBill: DBBill): Boolean {
|
||||
internal fun hasChanged(localBill: DBBill, remoteBill: DBBill): Boolean {
|
||||
if (localBill.payerId == remoteBill.payerId &&
|
||||
localBill.amount == remoteBill.amount &&
|
||||
localBill.timestamp == remoteBill.timestamp &&
|
||||
@@ -1372,6 +1542,11 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
}
|
||||
|
||||
private fun onPostExecute(status: LoginStatus) {
|
||||
if (status == LoginStatus.OK) {
|
||||
preferences.edit {
|
||||
putLong(appContext.getString(R.string.pref_key_last_account_sync_timestamp), System.currentTimeMillis())
|
||||
}
|
||||
}
|
||||
if (status != LoginStatus.OK) {
|
||||
var errorString = appContext.getString(R.string.error_sync, appContext.getString(status.str)) + "\n\n"
|
||||
for (errorMessage in errorMessages) {
|
||||
@@ -1616,6 +1791,16 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
companion object {
|
||||
private val TAG = CowspentServerSyncHelper::class.java.simpleName
|
||||
|
||||
/**
|
||||
* How many consecutive bills, walking newest to oldest, must already match locally before
|
||||
* the paged walk concludes that every older bill matches too.
|
||||
*
|
||||
* A whole page of 50 had to match before, so one edit anywhere in a page forced another
|
||||
* page to be fetched. A trailing run is the same bet on a smaller sample: it can settle
|
||||
* part way into a page, and it carries across page boundaries rather than restarting.
|
||||
*/
|
||||
private const val UNCHANGED_RUN_TO_SETTLE = 25
|
||||
|
||||
private var instance: CowspentServerSyncHelper? = null
|
||||
private val projectIdsToSync: MutableList<Long> = ArrayList()
|
||||
|
||||
@@ -1627,6 +1812,12 @@ class CowspentServerSyncHelper private constructor(private val dbHelper: Cowspen
|
||||
return instance!!
|
||||
}
|
||||
|
||||
@VisibleForTesting
|
||||
fun resetInstance() {
|
||||
instance = null
|
||||
projectIdsToSync.clear()
|
||||
}
|
||||
|
||||
fun isNextcloudAccountConfigured(context: Context): Boolean {
|
||||
val preferences = PreferenceManager.getDefaultSharedPreferences(context)
|
||||
return !preferences.getString(AccountActivity.SETTINGS_URL, AccountActivity.DEFAULT_SETTINGS).isNullOrEmpty() ||
|
||||
|
||||
@@ -24,7 +24,7 @@ object ColorUtils {
|
||||
val colorMode = if (prefs.contains(modeKey)) {
|
||||
prefs.getString(modeKey, "system")
|
||||
} else {
|
||||
val useServer = prefs.getBoolean(context.getString(R.string.pref_key_use_server_color), true)
|
||||
val useServer = prefs.getBoolean(context.getString(R.string.pref_key_use_server_color), false)
|
||||
val useSystem = prefs.getBoolean(context.getString(R.string.pref_key_use_system_color), true)
|
||||
when {
|
||||
useServer -> "server"
|
||||
|
||||
@@ -51,7 +51,7 @@ class NextcloudClient(
|
||||
|
||||
@Throws(JSONException::class, IOException::class, TokenMismatchException::class, NextcloudHttpRequestFailedException::class)
|
||||
fun getCapabilities(project: DBProject?): ServerResponse.CapabilitiesResponse {
|
||||
val target: String = if (project == null || url != "") {
|
||||
val target: String = if (project == null || url != "" || nextcloudAPI != null) {
|
||||
"/ocs/v2.php/cloud/capabilities"
|
||||
} else {
|
||||
val realServerUrl = project.serverUrl!!
|
||||
@@ -86,7 +86,7 @@ class NextcloudClient(
|
||||
}
|
||||
|
||||
@Throws(TokenMismatchException::class, NextcloudHttpRequestFailedException::class)
|
||||
private fun requestServerWithSSO(
|
||||
internal fun requestServerWithSSO(
|
||||
nextcloudAPI: NextcloudAPI,
|
||||
target: String,
|
||||
method: String,
|
||||
@@ -141,7 +141,7 @@ class NextcloudClient(
|
||||
}
|
||||
|
||||
@Throws(TokenMismatchException::class, NextcloudHttpRequestFailedException::class)
|
||||
private fun imageRequestServerWithSSO(
|
||||
internal fun imageRequestServerWithSSO(
|
||||
nextcloudAPI: NextcloudAPI,
|
||||
target: String,
|
||||
method: String,
|
||||
@@ -182,7 +182,7 @@ class NextcloudClient(
|
||||
}
|
||||
|
||||
@Throws(IOException::class, NextcloudHttpRequestFailedException::class)
|
||||
private fun requestServer(
|
||||
internal fun requestServer(
|
||||
target: String,
|
||||
method: String, params: JSONObject?, lastETag: String?, needLogin: Boolean, isOCSRequest: Boolean
|
||||
): VersatileProjectSyncClient.ResponseData {
|
||||
@@ -248,7 +248,7 @@ class NextcloudClient(
|
||||
}
|
||||
|
||||
@Throws(IOException::class, NextcloudHttpRequestFailedException::class)
|
||||
private fun imageRequestServer(
|
||||
internal fun imageRequestServer(
|
||||
target: String,
|
||||
method: String, params: JSONObject?, lastETag: String?, needLogin: Boolean, isOCSRequest: Boolean
|
||||
): VersatileProjectSyncClient.ResponseData {
|
||||
|
||||
@@ -12,15 +12,10 @@ import net.helcel.cowspent.model.DBProject
|
||||
import org.json.JSONArray
|
||||
import org.json.JSONException
|
||||
import org.json.JSONObject
|
||||
import org.xml.sax.SAXException
|
||||
import java.io.ByteArrayInputStream
|
||||
import java.io.IOException
|
||||
import java.io.InputStream
|
||||
import java.text.SimpleDateFormat
|
||||
import java.util.Date
|
||||
import java.util.Locale
|
||||
import javax.xml.parsers.DocumentBuilderFactory
|
||||
import javax.xml.parsers.ParserConfigurationException
|
||||
|
||||
|
||||
/**
|
||||
@@ -41,6 +36,10 @@ open class ServerResponse(
|
||||
val lastModified: Long
|
||||
get() = response.lastModified
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
|
||||
@Throws(JSONException::class)
|
||||
fun getResponseObjectData(): JSONObject {
|
||||
val rawData = JSONObject(content)
|
||||
@@ -125,10 +124,6 @@ open class ServerResponse(
|
||||
private val isJsonMember: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val remoteMemberId: Long
|
||||
get() = if (isJsonMember)
|
||||
@@ -142,10 +137,6 @@ open class ServerResponse(
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val remoteCategoryId: Long
|
||||
get() {
|
||||
@@ -162,32 +153,18 @@ open class ServerResponse(
|
||||
class EditRemoteCategoryResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class DeleteRemoteCategoryResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class CreateRemotePaymentModeResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val remotePaymentModeId: Long
|
||||
get() {
|
||||
@@ -204,32 +181,18 @@ open class ServerResponse(
|
||||
class EditRemotePaymentModeResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class DeleteRemotePaymentModeResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class CreateRemoteCurrencyResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val remoteCurrencyId: Long
|
||||
get() {
|
||||
@@ -246,32 +209,17 @@ open class ServerResponse(
|
||||
class EditRemoteCurrencyResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class DeleteRemoteCurrencyResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class EditRemoteProjectResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class EditRemoteMemberResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
@@ -289,10 +237,6 @@ open class ServerResponse(
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val remoteBillId: Long
|
||||
get() {
|
||||
@@ -311,10 +255,6 @@ open class ServerResponse(
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val remoteBillId: Long
|
||||
get() {
|
||||
@@ -331,32 +271,17 @@ open class ServerResponse(
|
||||
class DeleteRemoteBillResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class DeleteRemoteProjectResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class CreateRemoteProjectResponse(
|
||||
response: VersatileProjectSyncClient.ResponseData,
|
||||
isOcsResponse: Boolean
|
||||
) : ServerResponse(response, isOcsResponse) {
|
||||
|
||||
@get:Throws(JSONException::class)
|
||||
val stringContent: String
|
||||
get() = getResponseStringData()
|
||||
}
|
||||
) : ServerResponse(response, isOcsResponse)
|
||||
|
||||
class BillsResponse(response: VersatileProjectSyncClient.ResponseData, isOcsResponse: Boolean) :
|
||||
ServerResponse(response, isOcsResponse) {
|
||||
@@ -457,17 +382,6 @@ open class ServerResponse(
|
||||
get() = content
|
||||
}
|
||||
|
||||
@Throws(JSONException::class)
|
||||
protected fun getPublicTokenFromJSON(json: JSONObject): String? {
|
||||
if (json.has("code") && json.has("sharetoken")) {
|
||||
val done = json.getInt("code")
|
||||
val publicToken = json.getString("sharetoken")
|
||||
if (done == 1) {
|
||||
return publicToken
|
||||
}
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
||||
@Throws(JSONException::class)
|
||||
protected fun getNameFromJSON(json: JSONObject): String {
|
||||
@@ -897,7 +811,9 @@ open class ServerResponse(
|
||||
memberRemoteIdToId: Map<Long, Long>
|
||||
): List<DBBillOwer> {
|
||||
val billOwers: MutableList<DBBillOwer> = ArrayList()
|
||||
if (json.has("owers")) {
|
||||
// As everywhere else here, an explicitly null value is not a value: getJSONArray would
|
||||
// throw on it, and that exception fails the whole project sync over one bill.
|
||||
if (json.has("owers") && !json.isNull("owers")) {
|
||||
val jsonOs = json.getJSONArray("owers")
|
||||
for (i in 0 until jsonOs.length()) {
|
||||
val obj = jsonOs.get(i)
|
||||
@@ -935,6 +851,8 @@ open class ServerResponse(
|
||||
remoteId = json.getString("id")
|
||||
}
|
||||
if (!json.isNull("ncurl")) {
|
||||
ncUrl = json.getString("ncurl")
|
||||
} else if (!json.isNull("ncUrl")) {
|
||||
ncUrl = json.getString("ncUrl")
|
||||
}
|
||||
val archivedTs: Long? = getArchivedTsFromJSON(json)
|
||||
@@ -944,26 +862,6 @@ open class ServerResponse(
|
||||
return DBAccountProject(0, remoteId, null, name, ncUrl, archivedTs)
|
||||
}
|
||||
|
||||
@Throws(IOException::class)
|
||||
protected fun getColorFromContent(content: String): String? {
|
||||
var result: String? = null
|
||||
try {
|
||||
val dbf = DocumentBuilderFactory.newInstance()
|
||||
val db = dbf.newDocumentBuilder()
|
||||
val stream: InputStream = ByteArrayInputStream(content.toByteArray())
|
||||
val doc = db.parse(stream)
|
||||
doc.documentElement.normalize()
|
||||
// Locate the Tag Name
|
||||
val nodeList = doc.getElementsByTagName("color")
|
||||
if (nodeList.length > 0) {
|
||||
result = nodeList.item(0).textContent
|
||||
Log.i(TAG, "I GOT THE COLOR from server: $result")
|
||||
}
|
||||
} catch (_: ParserConfigurationException) {
|
||||
} catch (_: SAXException) {
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
protected fun getColorFromJsonContent(json: JSONObject): String? {
|
||||
return try {
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
package net.helcel.cowspent.util
|
||||
|
||||
import android.content.Context
|
||||
import androidx.preference.PreferenceManager
|
||||
import net.helcel.cowspent.R
|
||||
|
||||
/**
|
||||
* The SyncOnOpen preference: how often opening the app refreshes the account and every project.
|
||||
*
|
||||
* The choices and the default live here rather than in the settings screen so that the screen and
|
||||
* the sync trigger cannot disagree about what is in effect.
|
||||
*/
|
||||
object SyncSettings {
|
||||
|
||||
/** Steps offered by the slider, in minutes. */
|
||||
val INTERVAL_CHOICES_MINUTES = listOf(1, 10, 60, 1440)
|
||||
|
||||
const val DEFAULT_INTERVAL_MINUTES = 10
|
||||
|
||||
/**
|
||||
* The configured interval in minutes. A stored value that is not one of the offered steps —
|
||||
* from a restored backup, or a build that changed the steps — falls back to the default
|
||||
* rather than being displayed as the first step while a different value drives the sync.
|
||||
*/
|
||||
fun intervalMinutes(context: Context): Int {
|
||||
val prefs = PreferenceManager.getDefaultSharedPreferences(context)
|
||||
val stored = prefs.getInt(
|
||||
context.getString(R.string.pref_key_auto_sync_on_open),
|
||||
DEFAULT_INTERVAL_MINUTES
|
||||
)
|
||||
return if (stored in INTERVAL_CHOICES_MINUTES) stored else DEFAULT_INTERVAL_MINUTES
|
||||
}
|
||||
}
|
||||
@@ -47,6 +47,8 @@ class VersatileProjectSyncClient(
|
||||
gt
|
||||
}
|
||||
|
||||
val supportsPagedBills: Boolean get() = cospendVersionGT161
|
||||
|
||||
fun canAccessProjectWithNCLogin(project: DBProject): Boolean {
|
||||
return (project.password == ""
|
||||
&& url.replace("/+$".toRegex(), "") != ""
|
||||
@@ -114,7 +116,7 @@ class VersatileProjectSyncClient(
|
||||
@Throws(IOException::class, TokenMismatchException::class, NextcloudHttpRequestFailedException::class)
|
||||
fun editRemoteProject(
|
||||
project: DBProject, newName: String?, newEmail: String?, newPassword: String?,
|
||||
newMainCurrencyName: String?
|
||||
newMainCurrencyName: String?, newArchivedTs: Long? = null
|
||||
): ServerResponse.EditRemoteProjectResponse {
|
||||
val paramKeys: MutableList<String> = ArrayList()
|
||||
val paramValues: MutableList<String> = ArrayList()
|
||||
@@ -130,6 +132,10 @@ class VersatileProjectSyncClient(
|
||||
paramKeys.add("password")
|
||||
paramValues.add(newPassword)
|
||||
}
|
||||
if (newArchivedTs != null) {
|
||||
paramKeys.add("archived_ts")
|
||||
paramValues.add(newArchivedTs.toString())
|
||||
}
|
||||
|
||||
var target: String
|
||||
var username: String? = null
|
||||
@@ -154,10 +160,18 @@ class VersatileProjectSyncClient(
|
||||
paramKeys.add("password")
|
||||
paramValues.add(newPassword)
|
||||
}
|
||||
if (newEmail != null) {
|
||||
paramKeys.add("contact_email")
|
||||
paramValues.add(newEmail)
|
||||
}
|
||||
if (newMainCurrencyName != null) {
|
||||
paramKeys.add("currencyName")
|
||||
paramValues.add(newMainCurrencyName)
|
||||
}
|
||||
if (newArchivedTs != null) {
|
||||
paramKeys.add("archivedTs")
|
||||
paramValues.add(newArchivedTs.toString())
|
||||
}
|
||||
}
|
||||
if (canAccessProjectWithNCLogin(project)) {
|
||||
username = this.username
|
||||
@@ -675,22 +689,66 @@ class VersatileProjectSyncClient(
|
||||
}
|
||||
|
||||
@Throws(JSONException::class, IOException::class, TokenMismatchException::class, NextcloudHttpRequestFailedException::class)
|
||||
fun getBills(project: DBProject): ServerResponse.BillsResponse {
|
||||
fun getBills(
|
||||
project: DBProject,
|
||||
offset: Int? = null,
|
||||
limit: Int? = null,
|
||||
reverse: Boolean? = null,
|
||||
deleted: Int? = null
|
||||
): ServerResponse.BillsResponse {
|
||||
var target: String
|
||||
var username: String?
|
||||
var password: String?
|
||||
var bearerToken: String?
|
||||
var useOcsApiRequest: Boolean
|
||||
|
||||
val paramKeys: MutableList<String> = ArrayList()
|
||||
val paramValues: MutableList<String> = ArrayList()
|
||||
|
||||
if (ProjectType.COSPEND == project.type) {
|
||||
val tsLastSync = project.lastSyncedTimestamp
|
||||
if (offset == null) {
|
||||
if (cospendVersionGT161) {
|
||||
paramKeys.add("lastChanged")
|
||||
} else {
|
||||
paramKeys.add("lastchanged")
|
||||
}
|
||||
paramValues.add(tsLastSync.toString())
|
||||
} else {
|
||||
paramKeys.add("offset")
|
||||
paramValues.add(offset.toString())
|
||||
if (limit != null) {
|
||||
paramKeys.add("limit")
|
||||
paramValues.add(limit.toString())
|
||||
}
|
||||
if (reverse != null) {
|
||||
paramKeys.add("reverse")
|
||||
paramValues.add(reverse.toString())
|
||||
}
|
||||
if (deleted != null) {
|
||||
paramKeys.add("deleted")
|
||||
paramValues.add(deleted.toString())
|
||||
}
|
||||
}
|
||||
|
||||
if (canAccessProjectWithNCLogin(project)) {
|
||||
username = this.username
|
||||
password = this.password
|
||||
target = if (cospendVersionGT161)
|
||||
project.getRequestBaseUrl(true) + "/api/v1/projects/" + project.remoteId + "/bills?lastChanged=" + tsLastSync
|
||||
else
|
||||
project.getRequestBaseUrl(false) + "/api-priv/projects/" + project.remoteId + "/bills?lastchanged=" + tsLastSync
|
||||
useOcsApiRequest = cospendVersionGT161
|
||||
val baseUrl = project.getRequestBaseUrl(useOcsApiRequest)
|
||||
target = if (useOcsApiRequest)
|
||||
"$baseUrl/api/v1/projects/${project.remoteId}/bills"
|
||||
else
|
||||
"$baseUrl/api-priv/projects/${project.remoteId}/bills"
|
||||
|
||||
if (paramKeys.isNotEmpty()) {
|
||||
target += "?"
|
||||
for (i in paramKeys.indices) {
|
||||
if (i > 0) target += "&"
|
||||
target += "${paramKeys[i]}=${paramValues[i]}"
|
||||
}
|
||||
}
|
||||
|
||||
return ServerResponse.BillsResponse(
|
||||
requestServer(
|
||||
target, METHOD_GET, null, null,
|
||||
@@ -699,14 +757,6 @@ class VersatileProjectSyncClient(
|
||||
useOcsApiRequest
|
||||
)
|
||||
} else if (canAccessProjectWithSSO(project)) {
|
||||
val paramKeys: MutableList<String> = ArrayList()
|
||||
val paramValues: MutableList<String> = ArrayList()
|
||||
if (cospendVersionGT161) {
|
||||
paramKeys.add("lastChanged")
|
||||
} else {
|
||||
paramKeys.add("lastchanged")
|
||||
}
|
||||
paramValues.add(tsLastSync.toString())
|
||||
return if (cospendVersionGT161) {
|
||||
target = "/ocs/v2.php/apps/cospend/api/v1/projects/" + project.remoteId + "/bills"
|
||||
ServerResponse.BillsResponse(requestServerWithSSO(nextcloudAPI!!, target, METHOD_GET, paramKeys, paramValues, true), true)
|
||||
@@ -716,10 +766,20 @@ class VersatileProjectSyncClient(
|
||||
}
|
||||
} else {
|
||||
useOcsApiRequest = cospendVersionGT161
|
||||
target = if (cospendVersionGT161)
|
||||
project.getRequestBaseUrl(true) + "/api/v1/public/projects/" + project.remoteId + "/" + getEncodedPassword(project.password) + "/bills?lastChanged=" + tsLastSync
|
||||
val baseUrl = project.getRequestBaseUrl(useOcsApiRequest)
|
||||
target = if (useOcsApiRequest)
|
||||
"$baseUrl/api/v1/public/projects/${project.remoteId}/${getEncodedPassword(project.password)}/bills"
|
||||
else
|
||||
project.getRequestBaseUrl(false) + "/apiv2/projects/" + project.remoteId + "/" + getEncodedPassword(project.password) + "/bills?lastchanged=" + tsLastSync
|
||||
"$baseUrl/apiv2/projects/${project.remoteId}/${getEncodedPassword(project.password)}/bills"
|
||||
|
||||
if (paramKeys.isNotEmpty()) {
|
||||
target += "?"
|
||||
for (i in paramKeys.indices) {
|
||||
if (i > 0) target += "&"
|
||||
target += "${paramKeys[i]}=${paramValues[i]}"
|
||||
}
|
||||
}
|
||||
|
||||
return ServerResponse.BillsResponse(
|
||||
requestServer(
|
||||
target, METHOD_GET, null, null,
|
||||
@@ -1470,5 +1530,8 @@ class VersatileProjectSyncClient(
|
||||
const val METHOD_POST = "POST"
|
||||
const val METHOD_PUT = "PUT"
|
||||
const val METHOD_DELETE = "DELETE"
|
||||
|
||||
const val REMOTE_ARCHIVED_TS_NOW = 0L
|
||||
const val REMOTE_ARCHIVED_TS_UNSET = -1L
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,9 +5,11 @@ fun evalMath(expression: String): Double {
|
||||
var result = 0.0
|
||||
var db: SQLiteDatabase? = null
|
||||
try {
|
||||
// Force floating point division by replacing / with * 1.0 /
|
||||
val forcedRealExpr = expression.replace("/", "* 1.0 /")
|
||||
// Opens a temporary, in-memory system database block
|
||||
db = SQLiteDatabase.create(null)
|
||||
val cursor = db.rawQuery("SELECT ($expression);", null)
|
||||
val cursor = db.rawQuery("SELECT ($forcedRealExpr);", null)
|
||||
if (cursor.moveToFirst()) {
|
||||
result = cursor.getDouble(0)
|
||||
}
|
||||
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,263 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">Neue Rechnung</string>
|
||||
<string name="action_add_project">Projekt hinzufügen</string>
|
||||
<string name="action_save">Speichern</string>
|
||||
<string name="action_edit">Bearbeiten</string>
|
||||
<string name="action_share">Teilen</string>
|
||||
<string name="action_search">Suchen</string>
|
||||
<string name="action_open_menu">Menü öffnen</string>
|
||||
<string name="action_close_search">Suche schließen</string>
|
||||
<string name="action_clear_search">Suche leeren</string>
|
||||
<string name="action_delete">Löschen</string>
|
||||
<string name="simple_back">Zurück</string>
|
||||
<string name="action_archive">Archivieren</string>
|
||||
<string name="action_unarchive">Reaktivieren</string>
|
||||
<string name="action_export">Exportieren</string>
|
||||
<string name="action_stats">Statistik</string>
|
||||
<string name="action_settle">Abrechnen</string>
|
||||
<string name="action_scan_qrcode">QR Code einscannen</string>
|
||||
<string name="action_settings">Einstellungen</string>
|
||||
<string name="action_label_bills">Fehlende Kategorien</string>
|
||||
<string name="action_logout">Abmelden</string>
|
||||
<string name="action_connect">Verbinden</string>
|
||||
<string name="action_discard">Verwerfen</string>
|
||||
<string name="action_members">Mitglieder</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Währungen</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistiken</string>
|
||||
<string name="title_edit_project">Projekt bearbeiten</string>
|
||||
<string name="title_label_bills">Rechnungen kennzeichnen</string>
|
||||
<string name="title_labels">Labels verwalten</string>
|
||||
<string name="title_about">Über</string>
|
||||
<string name="title_settle">Projekt abrechnen</string>
|
||||
<string name="title_share">Projekt teilen</string>
|
||||
<string name="title_add_project">Projekt hinzufügen</string>
|
||||
<string name="title_add_category">Neue Kategorie</string>
|
||||
<string name="title_add_payment_mode">Zahlungsmethode hinzufügen</string>
|
||||
<string name="title_account">Nextcloud-Konto</string>
|
||||
<string name="title_share_web">Weblink</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Bist du sicher?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">Alle Rechnungen</string>
|
||||
<string name="label_categories">Kategorien</string>
|
||||
<string name="label_payment_modes">Zahlungsmethoden</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Farbe</string>
|
||||
<string name="label_weight">Gewicht</string>
|
||||
<string name="label_activated">Aktiviert</string>
|
||||
<string name="label_password">Passwort</string>
|
||||
<string name="label_email">E-Mail</string>
|
||||
<string name="label_url">Serveradresse</string>
|
||||
<string name="label_username">Benutzername</string>
|
||||
<string name="label_comment">Kommentar</string>
|
||||
<string name="label_what">Was?</string>
|
||||
<string name="label_payer">Wer hat bezahlt?</string>
|
||||
<string name="label_owers">Für wen?</string>
|
||||
<string name="label_repeat">Wiederholen alle</string>
|
||||
<string name="label_mode">Modus</string>
|
||||
<string name="label_category">Kategorie</string>
|
||||
<string name="label_project_id">Projekt-ID/Name</string>
|
||||
<string name="label_project_title">Projekttitel</string>
|
||||
<string name="label_use_sso">Nextcloud App-Konto verwenden</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Ungespeicherte Änderungen</string>
|
||||
<string name="dialog_unsaved_changes_msg">Änderungen vor dem Verlassen speichern?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">Das Remote-Projekt wird nicht gelöscht.</string>
|
||||
<string name="dialog_sync_error_title">Sync-Fehler</string>
|
||||
<string name="dialog_sync_error_msg">Synchronisation fehlgeschlagen für %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Die Ausgaben sind bereits ausgeglichen.</string>
|
||||
<string name="msg_project_added">Projekt %1$s hinzugefügt</string>
|
||||
<string name="msg_bill_labeled_done">Alle Rechnungen kategorisiert</string>
|
||||
<string name="msg_no_suggestions">Keine Vorschläge</string>
|
||||
<string name="msg_auth_warning">Benötigt Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link in Zwischenablage kopiert</string>
|
||||
<string name="msg_share_qr">Scanne den QR-Code oder teile den Link, um beizutreten.</string>
|
||||
<string name="msg_share_web">Link für den Zugriff per Web-Browser.</string>
|
||||
<string name="msg_share_qr_warn">Teile diesen Link mit einem Cowspent Benutzer.</string>
|
||||
<string name="msg_settle_intro">Abrechnung für %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s schuldet %3$.2f an %2$s</string>
|
||||
<string name="msg_stats_intro">Statistiken für %1$s:</string>
|
||||
<string name="msg_stats_header">Mitglied (Gezahlt | Ausgegeben | Saldo)</string>
|
||||
<string name="msg_logged_in_as">Angemeldet als %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Fehler</string>
|
||||
<string name="error_loading">Lädt</string>
|
||||
<string name="error_no_projects">Keine Projekte gefunden</string>
|
||||
<string name="error_no_members">Keine Mitglieder gefunden</string>
|
||||
<string name="error_no_bills">Keine Rechnungen gefunden</string>
|
||||
<string name="error_no_member">Mindestens ein Mitglied erforderlich</string>
|
||||
<string name="error_maintenance_mode">Server ist im Wartungsmodus</string>
|
||||
<string name="error_400">400 Falsche Anfrage</string>
|
||||
<string name="error_401">401 Unautorisiert</string>
|
||||
<string name="error_403">403 Verboten</string>
|
||||
<string name="error_404">404 Nicht gefunden</string>
|
||||
<string name="error_sync">Sync fehlgeschlagen: %1$s</string>
|
||||
<string name="error_invalid_login">Ungültiger Login: %1$s</string>
|
||||
<string name="error_auth">Benutzername oder Passwort falsch</string>
|
||||
<string name="error_json">Ungültige Server-Antwort</string>
|
||||
<string name="error_req_failed">Anfrage fehlgeschlagen</string>
|
||||
<string name="error_invalid_email">Ungültige E-Mail</string>
|
||||
<string name="error_invalid_project_id">Ungültige Projekt-ID</string>
|
||||
<string name="error_invalid_project_name">Ungültiger Projekttitel</string>
|
||||
<string name="error_invalid_bill_name">Ungültiger Rechnungsname</string>
|
||||
<string name="error_invalid_bill_date">Ungültiges Rechnungsdatum</string>
|
||||
<string name="error_invalid_bill_payer">Zahler erforderlich</string>
|
||||
<string name="error_invalid_bill_owers">Schuldner erforderlich</string>
|
||||
<string name="error_no_network">Keine Netzwerkverbindung</string>
|
||||
<string name="error_server">Serverfehler</string>
|
||||
<string name="error_io">Serververbindung getrennt</string>
|
||||
<string name="error_share_impossible">Dieses Projekt kann nicht geteilt werden</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Mit Nextcloud Konto verbinden</string>
|
||||
<string name="drawer_last_sync">Letzter Sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Abbrechen</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Ja</string>
|
||||
<string name="simple_no">Nein</string>
|
||||
<string name="simple_close">Schließen</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Erscheinung</string>
|
||||
<string name="settings_network">Netzwerk</string>
|
||||
<string name="settings_other">Andere</string>
|
||||
<string name="settings_night_mode">Thema</string>
|
||||
<string name="settings_offline_mode">Offline-Modus</string>
|
||||
<string name="settings_offline_mode_summary">Nur manuell synchronisieren.</string>
|
||||
<string name="settings_color_custom">Eigene Farbe</string>
|
||||
<string name="settings_color_mode">Farbauswahl</string>
|
||||
<string name="settings_show_archived">Archivierte Projekte anzeigen</string>
|
||||
<string name="settings_beta_features">Beta-Funktionen</string>
|
||||
<string name="settings_beta_features_summary">Experimentelle Funktionen aktivieren. Benutzung auf eigene Gefahr.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Aus letzter Rechnung vorausfüllen</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Zahler, Kategorie, Zahlungsart und Beteiligte aus der zuletzt erstellten Rechnung des Projekts übernehmen.</string>
|
||||
<string name="settings_auto_sync_on_open">Synchronisierungsintervall</string>
|
||||
<string name="settings_auto_sync_on_open_summary">Wie oft Konto und alle Projekte beim Öffnen der App aktualisiert werden.</string>
|
||||
<string name="pref_value_sync_1m">1 Minute</string>
|
||||
<string name="pref_value_sync_10m">10 Minuten</string>
|
||||
<string name="pref_value_sync_1h">1 Stunde</string>
|
||||
<string name="pref_value_sync_1d">1 Tag</string>
|
||||
<string name="settings_url_warn_http">WARNUNG: \"http\" ist unsicher. Verwende \"https\".</string>
|
||||
<string name="settings_colorpicker_title">Farbe wählen</string>
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manuell</string>
|
||||
<string name="pref_value_theme_light">Hell</string>
|
||||
<string name="pref_value_theme_dark">Dunkel</string>
|
||||
<string name="pref_value_theme_system">System folgen</string>
|
||||
|
||||
<!-- Constants (Do not translate) -->
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">Keine Wiederholung</string>
|
||||
<string name="repeat_day">Täglich</string>
|
||||
<string name="repeat_week">Wöchentlich</string>
|
||||
<string name="repeat_fortnight">Vierzehntägig</string>
|
||||
<string name="repeat_month">Monatlich</string>
|
||||
<string name="repeat_year">Jährlich</string>
|
||||
<string name="payment_mode_none">Keine</string>
|
||||
<string name="payment_mode_all">Alle</string>
|
||||
<string name="payment_mode_credit_card">Kreditkarte</string>
|
||||
<string name="payment_mode_cash">Bargeld</string>
|
||||
<string name="payment_mode_check">Scheck</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Überweisung</string>
|
||||
<string name="category_none">Keine</string>
|
||||
<string name="category_all">Alle</string>
|
||||
<string name="category_all_except_reimbursement">Alle außer Erstattung</string>
|
||||
<string name="category_groceries">Lebensmittel</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Miete</string>
|
||||
<string name="category_bills">Abrechnung</string>
|
||||
<string name="category_excursion">Ausflug/Kultur</string>
|
||||
<string name="category_health">Gesundheit</string>
|
||||
<string name="category_shopping">Einkaufen</string>
|
||||
<string name="category_reimbursement">Erstattung</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Unterkunft</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">Was</string>
|
||||
<string name="new_project_where">Wo</string>
|
||||
<string name="where_local">Nur lokal</string>
|
||||
<string name="todo_join">Bestehendem Projekt beitreten</string>
|
||||
<string name="todo_create">Neues Projekt erstellen</string>
|
||||
<string name="import_tooltip">Aus Datei importieren</string>
|
||||
<string name="choose_project_management_action">Projekt</string>
|
||||
<string name="project_added_success">Projekt erfolgreich hinzugefügt.</string>
|
||||
<string name="no_projects_text">Du hast noch keine Projekte.</string>
|
||||
<string name="configure_account_choice">Nextcloud-Konto konfigurieren</string>
|
||||
<string name="add_project_choice">Projekt manuell hinzufügen</string>
|
||||
<string name="no_members_text">Keine Mitglieder in diesem Projekt.</string>
|
||||
<string name="no_bills_text">Keine Rechnungen gefunden.</string>
|
||||
<string name="member_already_exists">Mitglied existiert bereits.</string>
|
||||
<string name="activity_dialog_title">Projekt: %1$s</string>
|
||||
<string name="remove_project_confirmation">Projekt %1$s entfernt.</string>
|
||||
<string name="file_saved_success">Datei gespeichert: %1$s</string>
|
||||
<string name="import_error_header">Import fehlgeschlagen in Zeile %d</string>
|
||||
<string name="import_error_date">Ungültiges Datumsformat in Zeile %d</string>
|
||||
<string name="import_error_owers">Ungültige Schuldner in Zeile %d</string>
|
||||
<string name="add_member_dialog_title">Mitglied hinzufügen</string>
|
||||
<string name="edit_member_dialog_title">Mitglied bearbeiten</string>
|
||||
<string name="member_edit_delete">Löschen</string>
|
||||
<string name="project_edition_no_change">Keine zu speichernden Änderungen.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">Keine (optimal)</string>
|
||||
<string name="settle_who">Wer zahlt</string>
|
||||
<string name="settle_to_whom">An wen</string>
|
||||
<string name="settle_how_much">Betrag</string>
|
||||
<string name="simple_settle_share">Teilen</string>
|
||||
<string name="simple_create_bills">Rechnungen erstellen</string>
|
||||
<string name="settle_bill_what">Abrechnung</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Währung wählen (%s)</string>
|
||||
<string name="setting_none">Keine</string>
|
||||
<string name="setting_all">Alle</string>
|
||||
<string name="currency_saved_success">Währungseinstellungen gespeichert.</string>
|
||||
<string name="main_currency">Hauptwährung</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Empfohlene Kategorien</string>
|
||||
<string name="label_bills_skip">Überspringen</string>
|
||||
<string name="stats_date_min">Von</string>
|
||||
<string name="stats_date_max">An</string>
|
||||
<string name="stats_who">Mitglied</string>
|
||||
<string name="stats_paid">Bezahlt</string>
|
||||
<string name="stats_spent">Ausgegeben</string>
|
||||
<string name="stats_balance">Saldo</string>
|
||||
<string name="total">Gesamt: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Verbindung fehlgeschlagen: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Erstellung fehlgeschlagen: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Fehler beim Aktualisieren des Remote-Projekts: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Netzwerk nicht verfügbar für Remote Operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Fehler beim Analysieren des QR-Codes.</string>
|
||||
<string name="error_token_mismatch">Authentifizierungstoken stimmen nicht überein. Bitte melde dich erneut an.</string>
|
||||
<string name="insufficient_access_level">Du hast keine Berechtigung, um diese Aktion durchzuführen.</string>
|
||||
<string name="delete_label_confirmation_title">Kategorie löschen</string>
|
||||
<string name="delete_label_confirmation_message">Bist du sicher, dass du diese Kategorie löschen möchtest?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Betreuer</string>
|
||||
<string name="about_license_title">Lizenz</string>
|
||||
<string name="about_source_title">Quellcode</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Projekt %1$s</string>
|
||||
<string name="share_chooser_title">Teilen %1$s</string>
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,265 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">Nueva factura</string>
|
||||
<string name="action_add_project">Añadir proyecto</string>
|
||||
<string name="action_save">Guardar</string>
|
||||
<string name="action_edit">Editar</string>
|
||||
<string name="action_share">Compartir</string>
|
||||
<string name="action_search">Buscar</string>
|
||||
<string name="action_open_menu">Abrir el menú</string>
|
||||
<string name="action_close_search">Cerrar la búsqueda</string>
|
||||
<string name="action_clear_search">Borrar la búsqueda</string>
|
||||
<string name="action_delete">Eliminar</string>
|
||||
<string name="simple_back">Atrás</string>
|
||||
<string name="action_archive">Archivar</string>
|
||||
<string name="action_unarchive">Desarchivar</string>
|
||||
<string name="action_export">Exportar</string>
|
||||
<string name="action_stats">Estadísticas</string>
|
||||
<string name="action_settle">Liquidar</string>
|
||||
<string name="action_scan_qrcode">Escanear código QR</string>
|
||||
<string name="action_settings">Ajustes</string>
|
||||
<string name="action_label_bills">Categorizar facturas</string>
|
||||
<string name="action_logout">Cerrar sesión</string>
|
||||
<string name="action_connect">Conectar</string>
|
||||
<string name="action_discard">Descartar</string>
|
||||
<string name="action_members">Miembros</string>
|
||||
<string name="action_labels">Etiquetas</string>
|
||||
<string name="action_currencies">Monedas</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Estadísticas</string>
|
||||
<string name="title_edit_project">Editar proyecto</string>
|
||||
<string name="title_label_bills">Categorizar facturas</string>
|
||||
<string name="title_labels">Gestionar etiquetas</string>
|
||||
<string name="title_about">Acerca de</string>
|
||||
<string name="title_settle">Liquidar proyecto</string>
|
||||
<string name="title_share">Compartir proyecto</string>
|
||||
<string name="title_add_project">Añadir proyecto</string>
|
||||
<string name="title_add_category">Añadir categoría</string>
|
||||
<string name="title_add_payment_mode">Añadir modo de pago</string>
|
||||
<string name="title_account">Cuenta de Nextcloud</string>
|
||||
<string name="title_share_web">Enlace web</string>
|
||||
<string name="title_share_qr">Enlace de Cowspent</string>
|
||||
<string name="title_confirm">¿Estás seguro?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">Todas las facturas</string>
|
||||
<string name="label_categories">Categorías</string>
|
||||
<string name="label_payment_modes">Modos de pago</string>
|
||||
<string name="label_name">Nombre</string>
|
||||
<string name="label_icon">Icono / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Peso</string>
|
||||
<string name="label_activated">Activado</string>
|
||||
<string name="label_password">Contraseña</string>
|
||||
<string name="label_email">Correo electrónico</string>
|
||||
<string name="label_url">Dirección del servidor</string>
|
||||
<string name="label_username">Nombre de usuario</string>
|
||||
<string name="label_comment">Comentario</string>
|
||||
<string name="label_what">¿Qué?</string>
|
||||
<string name="label_payer">¿Quién pagó?</string>
|
||||
<string name="label_owers">¿Para quién?</string>
|
||||
<string name="label_repeat">Repetición</string>
|
||||
<string name="label_mode">Modo</string>
|
||||
<string name="label_category">Categoría</string>
|
||||
<string name="label_project_id">ID/nombre del proyecto</string>
|
||||
<string name="label_project_title">Título del proyecto</string>
|
||||
<string name="label_use_sso">Usar la cuenta de la aplicación Nextcloud</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Cambios sin guardar</string>
|
||||
<string name="dialog_unsaved_changes_msg">¿Guardar los cambios antes de salir?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">El proyecto remoto no se eliminará.</string>
|
||||
<string name="dialog_sync_error_title">Error de sincronización</string>
|
||||
<string name="dialog_sync_error_msg">Error al sincronizar %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Los gastos ya están equilibrados.</string>
|
||||
<string name="msg_project_added">Proyecto %1$s añadido</string>
|
||||
<string name="msg_bill_labeled_done">Todas las facturas están categorizadas</string>
|
||||
<string name="msg_no_suggestions">No hay sugerencias</string>
|
||||
<string name="msg_auth_warning">Requiere Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Enlace copiado al portapapeles</string>
|
||||
<string name="msg_share_qr">Escanea el código QR o comparte el enlace para unirte al proyecto.</string>
|
||||
<string name="msg_share_web">Enlace de acceso desde un navegador web.</string>
|
||||
<string name="msg_share_qr_warn">Comparte este enlace con un usuario de Cowspent.</string>
|
||||
<string name="msg_settle_intro">Liquidación de %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s debe %3$.2f a %2$s</string>
|
||||
<string name="msg_stats_intro">Estadísticas de %1$s:</string>
|
||||
<string name="msg_stats_header">Miembro (Pagado | Gastado | Saldo)</string>
|
||||
<string name="msg_logged_in_as">Sesión iniciada como %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Cargando</string>
|
||||
<string name="error_no_projects">No se encontraron proyectos</string>
|
||||
<string name="error_no_members">No se encontraron miembros</string>
|
||||
<string name="error_no_bills">No se encontraron facturas</string>
|
||||
<string name="error_no_member">Se requiere al menos un miembro</string>
|
||||
<string name="error_maintenance_mode">El servidor está en modo de mantenimiento</string>
|
||||
<string name="error_400">400 Solicitud incorrecta</string>
|
||||
<string name="error_401">401 No autorizado</string>
|
||||
<string name="error_403">403 Prohibido</string>
|
||||
<string name="error_404">404 No encontrado</string>
|
||||
<string name="error_sync">Error de sincronización: %1$s</string>
|
||||
<string name="error_invalid_login">Inicio de sesión no válido: %1$s</string>
|
||||
<string name="error_auth">Nombre de usuario o contraseña incorrectos</string>
|
||||
<string name="error_json">Respuesta del servidor no válida</string>
|
||||
<string name="error_req_failed">La petición ha fallado</string>
|
||||
<string name="error_invalid_email">Correo electrónico no válido</string>
|
||||
<string name="error_invalid_project_id">ID de proyecto no válido</string>
|
||||
<string name="error_invalid_project_name">Título de proyecto no válido</string>
|
||||
<string name="error_invalid_bill_name">Nombre de factura no válido</string>
|
||||
<string name="error_invalid_bill_date">Fecha de factura no válida</string>
|
||||
<string name="error_invalid_bill_payer">Pagador requerido</string>
|
||||
<string name="error_invalid_bill_owers">Participantes requeridos</string>
|
||||
<string name="error_no_network">No hay conexión de red</string>
|
||||
<string name="error_server">Error del servidor</string>
|
||||
<string name="error_io">Se ha perdido la conexión con el servidor</string>
|
||||
<string name="error_share_impossible">No se puede compartir este proyecto</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Conectar a una cuenta de Nextcloud</string>
|
||||
<string name="drawer_last_sync">Última sincronización: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancelar</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Sí</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Cerrar</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Apariencia</string>
|
||||
<string name="settings_network">Red</string>
|
||||
<string name="settings_other">Otros</string>
|
||||
<string name="settings_night_mode">Tema</string>
|
||||
<string name="settings_offline_mode">Modo sin conexión</string>
|
||||
<string name="settings_offline_mode_summary">Sincronizar solo manualmente.</string>
|
||||
<string name="settings_color_custom">Color personalizado</string>
|
||||
<string name="settings_color_mode">Selección de color</string>
|
||||
<string name="settings_show_archived">Mostrar los proyectos archivados</string>
|
||||
<string name="settings_beta_features">Funciones beta</string>
|
||||
<string name="settings_beta_features_summary">Activar las funciones experimentales. Úsalas bajo tu propia responsabilidad.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Rellenar desde la última factura</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Reutilizar el pagador, la categoría, el modo y los participantes de la última factura creada en el proyecto.</string>
|
||||
<string name="settings_auto_sync_on_open">Intervalo de sincronización</string>
|
||||
<string name="settings_auto_sync_on_open_summary">Con qué frecuencia se actualizan la cuenta y todos los proyectos al abrir la aplicación.</string>
|
||||
<string name="pref_value_sync_1m">1 minuto</string>
|
||||
<string name="pref_value_sync_10m">10 minutos</string>
|
||||
<string name="pref_value_sync_1h">1 hora</string>
|
||||
<string name="pref_value_sync_1d">1 día</string>
|
||||
<string name="settings_url_warn_http">ADVERTENCIA: \"http\" no es seguro. Usa \"https\".</string>
|
||||
<string name="settings_colorpicker_title">Elegir un color</string>
|
||||
|
||||
<string name="pref_value_color_system">Sistema</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Claro</string>
|
||||
<string name="pref_value_theme_dark">Oscuro</string>
|
||||
<string name="pref_value_theme_system">Seguir el sistema</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">Sin repetición</string>
|
||||
<string name="repeat_day">Diaria</string>
|
||||
<string name="repeat_week">Semanal</string>
|
||||
<string name="repeat_fortnight">Quincenal</string>
|
||||
<string name="repeat_month">Mensual</string>
|
||||
<string name="repeat_year">Anual</string>
|
||||
|
||||
<string name="payment_mode_none">Ninguno</string>
|
||||
<string name="payment_mode_all">Todos</string>
|
||||
<string name="payment_mode_credit_card">Tarjeta de crédito</string>
|
||||
<string name="payment_mode_cash">Efectivo</string>
|
||||
<string name="payment_mode_check">Cheque</string>
|
||||
<string name="payment_mode_online">En línea</string>
|
||||
<string name="payment_mode_transfer">Transferencia</string>
|
||||
|
||||
<string name="category_none">Ninguna</string>
|
||||
<string name="category_all">Todas</string>
|
||||
<string name="category_all_except_reimbursement">Todas excepto reembolso</string>
|
||||
<string name="category_groceries">Supermercado</string>
|
||||
<string name="category_leisure">Bar/Fiesta</string>
|
||||
<string name="category_rent">Alquiler</string>
|
||||
<string name="category_bills">Factura</string>
|
||||
<string name="category_excursion">Excursión/Cultura</string>
|
||||
<string name="category_health">Salud</string>
|
||||
<string name="category_shopping">Compras</string>
|
||||
<string name="category_reimbursement">Reembolso</string>
|
||||
<string name="category_restaurant">Restaurante</string>
|
||||
<string name="category_accomodation">Alojamiento</string>
|
||||
<string name="category_transport">Transporte</string>
|
||||
<string name="category_sport">Deporte</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">Qué</string>
|
||||
<string name="new_project_where">Dónde</string>
|
||||
<string name="where_local">Solo local</string>
|
||||
<string name="todo_join">Unirse a un proyecto existente</string>
|
||||
<string name="todo_create">Crear un proyecto nuevo</string>
|
||||
<string name="import_tooltip">Importar desde un archivo</string>
|
||||
<string name="choose_project_management_action">Proyecto</string>
|
||||
<string name="project_added_success">Proyecto añadido correctamente.</string>
|
||||
<string name="no_projects_text">Aún no tienes proyectos.</string>
|
||||
<string name="configure_account_choice">Configurar una cuenta de Nextcloud</string>
|
||||
<string name="add_project_choice">Añadir un proyecto manualmente</string>
|
||||
<string name="no_members_text">No hay miembros en este proyecto.</string>
|
||||
<string name="no_bills_text">No se encontraron facturas.</string>
|
||||
<string name="member_already_exists">El miembro ya existe.</string>
|
||||
<string name="activity_dialog_title">Proyecto: %1$s</string>
|
||||
<string name="remove_project_confirmation">Proyecto %1$s eliminado.</string>
|
||||
<string name="file_saved_success">Archivo guardado: %1$s</string>
|
||||
<string name="import_error_header">Error de importación en la fila %d</string>
|
||||
<string name="import_error_date">Formato de fecha no válido en la fila %d</string>
|
||||
<string name="import_error_owers">Participantes no válidos en la fila %d</string>
|
||||
<string name="add_member_dialog_title">Añadir miembro</string>
|
||||
<string name="edit_member_dialog_title">Editar miembro</string>
|
||||
<string name="member_edit_delete">Eliminar</string>
|
||||
<string name="project_edition_no_change">No hay cambios que guardar.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">Ninguno (óptimo)</string>
|
||||
<string name="settle_who">Quién paga</string>
|
||||
<string name="settle_to_whom">A quién</string>
|
||||
<string name="settle_how_much">Importe</string>
|
||||
<string name="simple_settle_share">Compartir</string>
|
||||
<string name="simple_create_bills">Crear las facturas</string>
|
||||
<string name="settle_bill_what">Liquidación</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Elegir moneda (%s)</string>
|
||||
<string name="setting_none">Ninguna</string>
|
||||
<string name="setting_all">Todas</string>
|
||||
<string name="currency_saved_success">Ajustes de moneda guardados.</string>
|
||||
<string name="main_currency">Moneda principal</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Categorías sugeridas</string>
|
||||
<string name="label_bills_skip">Omitir</string>
|
||||
<string name="stats_date_min">Desde</string>
|
||||
<string name="stats_date_max">Hasta</string>
|
||||
<string name="stats_who">Miembro</string>
|
||||
<string name="stats_paid">Pagado</string>
|
||||
<string name="stats_spent">Gastado</string>
|
||||
<string name="stats_balance">Saldo</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Error de conexión: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Error al crear: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error al actualizar el proyecto remoto: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Red no disponible para esta operación remota.</string>
|
||||
<string name="error_scanning_bill_qr_code">No se ha podido leer el código QR.</string>
|
||||
<string name="error_token_mismatch">El token de autenticación no coincide. Vuelve a iniciar sesión.</string>
|
||||
<string name="insufficient_access_level">No tienes permiso para realizar esta acción.</string>
|
||||
<string name="delete_label_confirmation_title">Eliminar etiqueta</string>
|
||||
<string name="delete_label_confirmation_message">¿Seguro que quieres eliminar esta etiqueta?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Versión %1$s</string>
|
||||
<string name="about_maintainer_title">Mantenedor</string>
|
||||
<string name="about_license_title">Licencia</string>
|
||||
<string name="about_source_title">Código fuente</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Proyecto %1$s</string>
|
||||
<string name="share_chooser_title">Compartir %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,268 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">Nouvelle facture</string>
|
||||
<string name="action_add_project">Ajouter un projet</string>
|
||||
<string name="action_save">Enregistrer</string>
|
||||
<string name="action_edit">Modifier</string>
|
||||
<string name="action_share">Partager</string>
|
||||
<string name="action_search">Rechercher</string>
|
||||
<string name="action_open_menu">Ouvrir le menu</string>
|
||||
<string name="action_close_search">Fermer la recherche</string>
|
||||
<string name="action_clear_search">Effacer la recherche</string>
|
||||
<string name="action_delete">Supprimer</string>
|
||||
<string name="simple_back">Retour</string>
|
||||
<string name="action_archive">Archiver</string>
|
||||
<string name="action_unarchive">Désarchiver</string>
|
||||
<string name="action_export">Exporter</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Régler</string>
|
||||
<string name="action_scan_qrcode">Scanner un QR code</string>
|
||||
<string name="action_settings">Réglages</string>
|
||||
<string name="action_label_bills">Catégoriser les factures</string>
|
||||
<string name="action_logout">Déconnecter</string>
|
||||
<string name="action_connect">Connecter</string>
|
||||
<string name="action_discard">Abandonner</string>
|
||||
<string name="action_members">Membres</string>
|
||||
<string name="action_labels">Étiquettes</string>
|
||||
<string name="action_currencies">Devises</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistiques</string>
|
||||
<string name="title_edit_project">Modifier le projet</string>
|
||||
<string name="title_label_bills">Catégoriser les factures</string>
|
||||
<string name="title_labels">Gérer les étiquettes</string>
|
||||
<string name="title_about">À propos</string>
|
||||
<string name="title_settle">Régler le projet</string>
|
||||
<string name="title_share">Partager le projet</string>
|
||||
<string name="title_add_project">Ajouter un projet</string>
|
||||
<string name="title_add_category">Ajouter une catégorie</string>
|
||||
<string name="title_add_payment_mode">Ajouter un mode de paiement</string>
|
||||
<string name="title_account">Compte Nextcloud</string>
|
||||
<string name="title_share_web">Lien web</string>
|
||||
<string name="title_share_qr">Lien Cowspent</string>
|
||||
<string name="title_confirm">Êtes-vous sûr(e) ?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">Toutes les factures</string>
|
||||
<string name="label_categories">Catégories</string>
|
||||
<string name="label_payment_modes">Modes de paiement</string>
|
||||
<string name="label_name">Nom</string>
|
||||
<string name="label_icon">Icône / Emoji</string>
|
||||
<string name="label_color">Couleur</string>
|
||||
<string name="label_weight">Poids</string>
|
||||
<string name="label_activated">Activé</string>
|
||||
<string name="label_password">Mot de passe</string>
|
||||
<string name="label_email">Courriel</string>
|
||||
<string name="label_url">Adresse du serveur</string>
|
||||
<string name="label_username">Nom d\'utilisateur</string>
|
||||
<string name="label_comment">Commentaire</string>
|
||||
<string name="label_what">Quoi ?</string>
|
||||
<string name="label_payer">Qui a payé ?</string>
|
||||
<string name="label_owers">Pour qui ?</string>
|
||||
<string name="label_repeat">Répétition</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Catégorie</string>
|
||||
<string name="label_project_id">ID/nom du projet</string>
|
||||
<string name="label_project_title">Titre du projet</string>
|
||||
<string name="label_use_sso">Utiliser le compte de l\'application Nextcloud</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Modifications non enregistrées</string>
|
||||
<string name="dialog_unsaved_changes_msg">Enregistrer les modifications avant de quitter ?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">Le projet distant ne sera pas supprimé.</string>
|
||||
<string name="dialog_sync_error_title">Erreur de synchronisation</string>
|
||||
<string name="dialog_sync_error_msg">Échec de la synchronisation pour %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Les dépenses sont déjà équilibrées.</string>
|
||||
<string name="msg_project_added">Projet %1$s ajouté</string>
|
||||
<string name="msg_bill_labeled_done">Toutes les factures sont catégorisées</string>
|
||||
<string name="msg_no_suggestions">Aucune suggestion</string>
|
||||
<string name="msg_auth_warning">Nécessite Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Lien copié dans le presse-papiers</string>
|
||||
<string name="msg_share_qr">Scannez le QR code ou partagez le lien pour rejoindre le projet.</string>
|
||||
<string name="msg_share_web">Lien d\'accès depuis un navigateur web.</string>
|
||||
<string name="msg_share_qr_warn">Partagez ce lien avec un utilisateur de Cowspent.</string>
|
||||
<string name="msg_settle_intro">Règlement pour %1$s :</string>
|
||||
<string name="msg_settle_sentence">%1$s doit %3$.2f à %2$s</string>
|
||||
<string name="msg_stats_intro">Statistiques pour %1$s :</string>
|
||||
<string name="msg_stats_header">Membre (Payé | Dépensé | Solde)</string>
|
||||
<string name="msg_logged_in_as">Connecté en tant que %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Erreur</string>
|
||||
<string name="error_loading">Chargement</string>
|
||||
<string name="error_no_projects">Aucun projet trouvé</string>
|
||||
<string name="error_no_members">Aucun membre trouvé</string>
|
||||
<string name="error_no_bills">Aucune facture trouvée</string>
|
||||
<string name="error_no_member">Au moins un membre est requis</string>
|
||||
<string name="error_maintenance_mode">Le serveur est en mode maintenance</string>
|
||||
<string name="error_400">400 Requête incorrecte</string>
|
||||
<string name="error_401">401 Non autorisé</string>
|
||||
<string name="error_403">403 Interdit</string>
|
||||
<string name="error_404">404 Introuvable</string>
|
||||
<string name="error_sync">Échec de la synchronisation : %1$s</string>
|
||||
<string name="error_invalid_login">Identifiant invalide : %1$s</string>
|
||||
<string name="error_auth">Mauvais nom d\'utilisateur ou mot de passe</string>
|
||||
<string name="error_json">Réponse du serveur invalide</string>
|
||||
<string name="error_req_failed">La requête a échoué</string>
|
||||
<string name="error_invalid_email">Adresse e-mail invalide</string>
|
||||
<string name="error_invalid_project_id">ID de projet invalide</string>
|
||||
<string name="error_invalid_project_name">Titre de projet invalide</string>
|
||||
<string name="error_invalid_bill_name">Nom de facture invalide</string>
|
||||
<string name="error_invalid_bill_date">Date de facture invalide</string>
|
||||
<string name="error_invalid_bill_payer">Payeur requis</string>
|
||||
<string name="error_invalid_bill_owers">Participants requis</string>
|
||||
<string name="error_no_network">Aucune connexion réseau</string>
|
||||
<string name="error_server">Erreur serveur</string>
|
||||
<string name="error_io">La connexion au serveur a échoué</string>
|
||||
<string name="error_share_impossible">Impossible de partager ce projet</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Se connecter au compte Nextcloud</string>
|
||||
<string name="drawer_last_sync">Dernière synchronisation : %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Annuler</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Oui</string>
|
||||
<string name="simple_no">Non</string>
|
||||
<string name="simple_close">Fermer</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Apparence</string>
|
||||
<string name="settings_network">Réseau</string>
|
||||
<string name="settings_other">Autres</string>
|
||||
<string name="settings_night_mode">Thème</string>
|
||||
<string name="settings_offline_mode">Mode hors ligne</string>
|
||||
<string name="settings_offline_mode_summary">Synchroniser uniquement manuellement.</string>
|
||||
<string name="settings_color_custom">Couleur personnalisée</string>
|
||||
<string name="settings_color_mode">Sélection de la couleur</string>
|
||||
<string name="settings_show_archived">Afficher les projets archivés</string>
|
||||
<string name="settings_beta_features">Fonctionnalités bêta</string>
|
||||
<string name="settings_beta_features_summary">Activer les fonctionnalités expérimentales. À utiliser à vos risques et périls.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Pré-remplir depuis la dernière facture</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Reprendre le payeur, la catégorie, le mode et les participants de la dernière facture créée dans le projet.</string>
|
||||
<string name="settings_auto_sync_on_open">Intervalle de synchronisation</string>
|
||||
<string name="settings_auto_sync_on_open_summary">Fréquence de rafraîchissement du compte et de tous les projets à l\'ouverture de l\'application.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 heure</string>
|
||||
<string name="pref_value_sync_1d">1 jour</string>
|
||||
<string name="settings_url_warn_http">AVERTISSEMENT : \"http\" n\'est pas sûr. Utilisez \"https\".</string>
|
||||
<string name="settings_colorpicker_title">Choisir une couleur</string>
|
||||
|
||||
<string name="pref_value_color_system">Système</string>
|
||||
<string name="pref_value_color_manual">Manuelle</string>
|
||||
<string name="pref_value_theme_light">Clair</string>
|
||||
<string name="pref_value_theme_dark">Sombre</string>
|
||||
<string name="pref_value_theme_system">Suivre le système</string>
|
||||
|
||||
<!-- Constants (Do not translate) -->
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">Pas de répétition</string>
|
||||
<string name="repeat_day">Quotidienne</string>
|
||||
<string name="repeat_week">Hebdomadaire</string>
|
||||
<string name="repeat_fortnight">Toutes les deux semaines</string>
|
||||
<string name="repeat_month">Mensuelle</string>
|
||||
<string name="repeat_year">Annuelle</string>
|
||||
|
||||
<string name="payment_mode_none">Aucun</string>
|
||||
<string name="payment_mode_all">Tous</string>
|
||||
<string name="payment_mode_credit_card">Carte bancaire</string>
|
||||
<string name="payment_mode_cash">Espèces</string>
|
||||
<string name="payment_mode_check">Chèque</string>
|
||||
<string name="payment_mode_online">En ligne</string>
|
||||
<string name="payment_mode_transfer">Virement</string>
|
||||
|
||||
<string name="category_none">Aucune</string>
|
||||
<string name="category_all">Toutes</string>
|
||||
<string name="category_all_except_reimbursement">Toutes sauf remboursement</string>
|
||||
<string name="category_groceries">Courses</string>
|
||||
<string name="category_leisure">Bar/Fête</string>
|
||||
<string name="category_rent">Loyer</string>
|
||||
<string name="category_bills">Facture</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Santé</string>
|
||||
<string name="category_shopping">Achats</string>
|
||||
<string name="category_reimbursement">Remboursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Hébergement</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">Quoi</string>
|
||||
<string name="new_project_where">Où</string>
|
||||
<string name="where_local">Local uniquement</string>
|
||||
<string name="todo_join">Rejoindre un projet existant</string>
|
||||
<string name="todo_create">Créer un nouveau projet</string>
|
||||
<string name="import_tooltip">Importer depuis un fichier</string>
|
||||
<string name="choose_project_management_action">Projet</string>
|
||||
<string name="project_added_success">Le projet a été ajouté avec succès.</string>
|
||||
<string name="no_projects_text">Vous n\'avez pas encore de projet.</string>
|
||||
<string name="configure_account_choice">Configurer le compte Nextcloud</string>
|
||||
<string name="add_project_choice">Ajouter un projet manuellement</string>
|
||||
<string name="no_members_text">Aucun membre dans ce projet.</string>
|
||||
<string name="no_bills_text">Aucune facture trouvée.</string>
|
||||
<string name="member_already_exists">Ce membre existe déjà.</string>
|
||||
<string name="activity_dialog_title">Projet : %1$s</string>
|
||||
<string name="remove_project_confirmation">Projet %1$s supprimé.</string>
|
||||
<string name="file_saved_success">Fichier enregistré : %1$s</string>
|
||||
<string name="import_error_header">Échec de l\'importation à la ligne %d</string>
|
||||
<string name="import_error_date">Format de date invalide à la ligne %d</string>
|
||||
<string name="import_error_owers">Participants invalides à la ligne %d</string>
|
||||
<string name="add_member_dialog_title">Ajouter un membre</string>
|
||||
<string name="edit_member_dialog_title">Modifier le membre</string>
|
||||
<string name="member_edit_delete">Supprimer</string>
|
||||
<string name="project_edition_no_change">Aucune modification à enregistrer.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">Aucun (optimal)</string>
|
||||
<string name="settle_who">Qui paie</string>
|
||||
<string name="settle_to_whom">À qui</string>
|
||||
<string name="settle_how_much">Montant</string>
|
||||
<string name="simple_settle_share">Partager</string>
|
||||
<string name="simple_create_bills">Créer les factures</string>
|
||||
<string name="settle_bill_what">Règlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choisir la devise (%s)</string>
|
||||
<string name="setting_none">Aucune</string>
|
||||
<string name="setting_all">Toutes</string>
|
||||
<string name="currency_saved_success">Paramètres des devises enregistrés.</string>
|
||||
<string name="main_currency">Devise principale</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Catégories suggérées</string>
|
||||
<string name="label_bills_skip">Ignorer</string>
|
||||
<string name="stats_date_min">Du</string>
|
||||
<string name="stats_date_max">Au</string>
|
||||
<string name="stats_who">Membre</string>
|
||||
<string name="stats_paid">Payé</string>
|
||||
<string name="stats_spent">Dépensé</string>
|
||||
<string name="stats_balance">Solde</string>
|
||||
<string name="total">Total : %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Échec de la connexion : %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Échec de la création : %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Erreur lors de la mise à jour du projet distant : %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Réseau indisponible pour cette opération distante.</string>
|
||||
<string name="error_scanning_bill_qr_code">Impossible de lire le QR code.</string>
|
||||
<string name="error_token_mismatch">Jeton d\'authentification invalide. Veuillez vous reconnecter.</string>
|
||||
<string name="insufficient_access_level">Vous n\'avez pas la permission d\'effectuer cette action.</string>
|
||||
<string name="delete_label_confirmation_title">Supprimer l\'étiquette</string>
|
||||
<string name="delete_label_confirmation_message">Voulez-vous vraiment supprimer cette étiquette ?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Mainteneur</string>
|
||||
<string name="about_license_title">Licence</string>
|
||||
<string name="about_source_title">Code source</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Projet %1$s</string>
|
||||
<string name="share_chooser_title">Partager %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,272 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<!--
|
||||
Untranslated: these are the English strings, kept here so a translation can be
|
||||
contributed by simply replacing the values. Strings marked translatable="false" in
|
||||
values/strings.xml (app and product names, preference keys) are deliberately absent
|
||||
and must not be added.
|
||||
-->
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
<string name="action_add_project">Add project</string>
|
||||
<string name="action_save">Save</string>
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
<string name="action_stats">Stats</string>
|
||||
<string name="action_settle">Settle</string>
|
||||
<string name="action_scan_qrcode">Scan QR Code</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<string name="action_label_bills">Label missing categories</string>
|
||||
<string name="action_logout">Logout</string>
|
||||
<string name="action_connect">Connect</string>
|
||||
<string name="action_discard">Discard</string>
|
||||
<string name="action_members">Members</string>
|
||||
<string name="action_labels">Labels</string>
|
||||
<string name="action_currencies">Currencies</string>
|
||||
|
||||
<!-- Titles -->
|
||||
<string name="title_stats">Statistics</string>
|
||||
<string name="title_edit_project">Edit project</string>
|
||||
<string name="title_label_bills">Label Bills</string>
|
||||
<string name="title_labels">Manage Labels</string>
|
||||
<string name="title_about">About</string>
|
||||
<string name="title_settle">Settle Project</string>
|
||||
<string name="title_share">Share Project</string>
|
||||
<string name="title_add_project">Add Project</string>
|
||||
<string name="title_add_category">Add Category</string>
|
||||
<string name="title_add_payment_mode">Add Payment Mode</string>
|
||||
<string name="title_account">Nextcloud Account</string>
|
||||
<string name="title_share_web">Web link</string>
|
||||
<string name="title_share_qr">Cowspent link</string>
|
||||
<string name="title_confirm">Are you sure?</string>
|
||||
|
||||
<!-- Labels and Fields -->
|
||||
<string name="label_all_bills">All bills</string>
|
||||
<string name="label_categories">Categories</string>
|
||||
<string name="label_payment_modes">Payment Modes</string>
|
||||
<string name="label_name">Name</string>
|
||||
<string name="label_icon">Icon / Emoji</string>
|
||||
<string name="label_color">Color</string>
|
||||
<string name="label_weight">Weight</string>
|
||||
<string name="label_activated">Activated</string>
|
||||
<string name="label_password">Password</string>
|
||||
<string name="label_email">E-mail</string>
|
||||
<string name="label_url">Server address</string>
|
||||
<string name="label_username">Username</string>
|
||||
<string name="label_comment">Comment</string>
|
||||
<string name="label_what">What?</string>
|
||||
<string name="label_payer">Who paid?</string>
|
||||
<string name="label_owers">For whom?</string>
|
||||
<string name="label_repeat">Repeat every</string>
|
||||
<string name="label_mode">Mode</string>
|
||||
<string name="label_category">Category</string>
|
||||
<string name="label_project_id">Project ID/name</string>
|
||||
<string name="label_project_title">Project title</string>
|
||||
<string name="label_use_sso">Use Nextcloud App Account</string>
|
||||
|
||||
<!-- Dialogs and Messages -->
|
||||
<string name="dialog_unsaved_changes_title">Unsaved changes</string>
|
||||
<string name="dialog_unsaved_changes_msg">Save changes before leaving?</string>
|
||||
<string name="dialog_confirm_remove_project_msg">The remote project will not be deleted.</string>
|
||||
<string name="dialog_sync_error_title">Sync error</string>
|
||||
<string name="dialog_sync_error_msg">Sync failed for %1$s.\n\n%2$s</string>
|
||||
<string name="dialog_balanced_msg">Expenses are already balanced.</string>
|
||||
<string name="msg_project_added">Project %1$s added</string>
|
||||
<string name="msg_bill_labeled_done">All bills labeled</string>
|
||||
<string name="msg_no_suggestions">No suggestions</string>
|
||||
<string name="msg_auth_warning">Requires Cospend v0.3.4+.</string>
|
||||
<string name="msg_link_copied">Link copied to clipboard</string>
|
||||
<string name="msg_share_qr">Scan QR code or share the link to join.</string>
|
||||
<string name="msg_share_web">Link for web browser access.</string>
|
||||
<string name="msg_share_qr_warn">Share this link with a Cowspent user.</string>
|
||||
<string name="msg_settle_intro">Settlement for %1$s:</string>
|
||||
<string name="msg_settle_sentence">%1$s owes %3$.2f to %2$s</string>
|
||||
<string name="msg_stats_intro">Stats for %1$s:</string>
|
||||
<string name="msg_stats_header">Member (Paid | Spent | Balance)</string>
|
||||
<string name="msg_logged_in_as">Logged in as %1$s</string>
|
||||
|
||||
<!-- Errors -->
|
||||
<string name="error_generic">Error</string>
|
||||
<string name="error_loading">Loading</string>
|
||||
<string name="error_no_projects">No projects found</string>
|
||||
<string name="error_no_members">No members found</string>
|
||||
<string name="error_no_bills">No bills found</string>
|
||||
<string name="error_no_member">At least one member required</string>
|
||||
<string name="error_maintenance_mode">Server is in maintenance mode</string>
|
||||
<string name="error_400">400 Bad request</string>
|
||||
<string name="error_401">401 Unauthorized</string>
|
||||
<string name="error_403">403 Forbidden</string>
|
||||
<string name="error_404">404 Not Found</string>
|
||||
<string name="error_sync">Sync failed: %1$s</string>
|
||||
<string name="error_invalid_login">Invalid login: %1$s</string>
|
||||
<string name="error_auth">Wrong username or password</string>
|
||||
<string name="error_json">Invalid server response</string>
|
||||
<string name="error_req_failed">Request failed</string>
|
||||
<string name="error_invalid_email">Invalid e-mail</string>
|
||||
<string name="error_invalid_project_id">Invalid project ID</string>
|
||||
<string name="error_invalid_project_name">Invalid project title</string>
|
||||
<string name="error_invalid_bill_name">Invalid bill name</string>
|
||||
<string name="error_invalid_bill_date">Invalid bill date</string>
|
||||
<string name="error_invalid_bill_payer">Payer required</string>
|
||||
<string name="error_invalid_bill_owers">Owers required</string>
|
||||
<string name="error_no_network">No network connection</string>
|
||||
<string name="error_server">Server error</string>
|
||||
<string name="error_io">Server connection broken</string>
|
||||
<string name="error_share_impossible">Cannot share this project</string>
|
||||
|
||||
<!-- Drawer / Common UI -->
|
||||
<string name="drawer_no_account">Connect to Nextcloud account</string>
|
||||
<string name="drawer_last_sync">Last sync: %1$02d:%2$02d</string>
|
||||
<string name="simple_cancel">Cancel</string>
|
||||
<string name="simple_ok" tools:ignore="ButtonCase,Typos">Ok</string>
|
||||
<string name="simple_yes">Yes</string>
|
||||
<string name="simple_no">No</string>
|
||||
<string name="simple_close">Close</string>
|
||||
|
||||
<!-- Settings -->
|
||||
<string name="settings_appearance">Appearance</string>
|
||||
<string name="settings_network">Network</string>
|
||||
<string name="settings_other">Other</string>
|
||||
<string name="settings_night_mode">Theme</string>
|
||||
<string name="settings_offline_mode">Offline mode</string>
|
||||
<string name="settings_offline_mode_summary">Only sync manually.</string>
|
||||
<string name="settings_color_custom">Custom color</string>
|
||||
<string name="settings_color_mode">Color Selection</string>
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
<string name="pref_value_theme_system">Follow system</string>
|
||||
|
||||
<!-- Enums and Lists -->
|
||||
<string name="repeat_no">No repeat</string>
|
||||
<string name="repeat_day">Daily</string>
|
||||
<string name="repeat_week">Weekly</string>
|
||||
<string name="repeat_fortnight">Fortnightly</string>
|
||||
<string name="repeat_month">Monthly</string>
|
||||
<string name="repeat_year">Yearly</string>
|
||||
|
||||
<string name="payment_mode_none">None</string>
|
||||
<string name="payment_mode_all">All</string>
|
||||
<string name="payment_mode_credit_card">Credit card</string>
|
||||
<string name="payment_mode_cash">Cash</string>
|
||||
<string name="payment_mode_check">Check</string>
|
||||
<string name="payment_mode_online">Online</string>
|
||||
<string name="payment_mode_transfer">Transfer</string>
|
||||
|
||||
<string name="category_none">None</string>
|
||||
<string name="category_all">All</string>
|
||||
<string name="category_all_except_reimbursement">All except reimbursement</string>
|
||||
<string name="category_groceries">Grocery</string>
|
||||
<string name="category_leisure">Bar/Party</string>
|
||||
<string name="category_rent">Rent</string>
|
||||
<string name="category_bills">Bill</string>
|
||||
<string name="category_excursion">Excursion/Culture</string>
|
||||
<string name="category_health">Health</string>
|
||||
<string name="category_shopping">Shopping</string>
|
||||
<string name="category_reimbursement">Reimbursement</string>
|
||||
<string name="category_restaurant">Restaurant</string>
|
||||
<string name="category_accomodation">Accommodation</string>
|
||||
<string name="category_transport">Transport</string>
|
||||
<string name="category_sport">Sport</string>
|
||||
|
||||
<!-- Project specific -->
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
<string name="configure_account_choice">Configure Nextcloud account</string>
|
||||
<string name="add_project_choice">Add project manually</string>
|
||||
<string name="no_members_text">No members in this project.</string>
|
||||
<string name="no_bills_text">No bills found.</string>
|
||||
<string name="member_already_exists">Member already exists.</string>
|
||||
<string name="activity_dialog_title">Project: %1$s</string>
|
||||
<string name="remove_project_confirmation">Project %1$s removed.</string>
|
||||
<string name="file_saved_success">File saved: %1$s</string>
|
||||
<string name="import_error_header">Import failed at row %d</string>
|
||||
<string name="import_error_date">Invalid date format at row %d</string>
|
||||
<string name="import_error_owers">Invalid owers at row %d</string>
|
||||
<string name="add_member_dialog_title">Add Member</string>
|
||||
<string name="edit_member_dialog_title">Edit Member</string>
|
||||
<string name="member_edit_delete">Delete</string>
|
||||
<string name="project_edition_no_change">No changes to save.</string>
|
||||
|
||||
<!-- Settlement -->
|
||||
<string name="center_none">None (Optimal)</string>
|
||||
<string name="settle_who">Who pays</string>
|
||||
<string name="settle_to_whom">To whom</string>
|
||||
<string name="settle_how_much">Amount</string>
|
||||
<string name="simple_settle_share">Share</string>
|
||||
<string name="simple_create_bills">Create bills</string>
|
||||
<string name="settle_bill_what">Settlement</string>
|
||||
|
||||
<!-- Currencies -->
|
||||
<string name="currency_dialog_title">Choose Currency (%s)</string>
|
||||
<string name="setting_none">None</string>
|
||||
<string name="setting_all">All</string>
|
||||
<string name="currency_saved_success">Currency settings saved.</string>
|
||||
<string name="main_currency">Main Currency</string>
|
||||
|
||||
<!-- Statistics -->
|
||||
<string name="label_bills_suggested">Suggested Categories</string>
|
||||
<string name="label_bills_skip">Skip</string>
|
||||
<string name="stats_date_min">From</string>
|
||||
<string name="stats_date_max">To</string>
|
||||
<string name="stats_who">Member</string>
|
||||
<string name="stats_paid">Paid</string>
|
||||
<string name="stats_spent">Spent</string>
|
||||
<string name="stats_balance">Balance</string>
|
||||
<string name="total">Total: %1$s</string>
|
||||
|
||||
<!-- Errors Extra -->
|
||||
<string name="error_project_connect_check">Connection failed: %1$s</string>
|
||||
<string name="error_create_remote_project_helper">Creation failed: %1$s</string>
|
||||
<string name="error_edit_remote_project_helper">Error updating remote project: %1$s</string>
|
||||
<string name="remote_project_operation_no_network">Network unavailable for remote operation.</string>
|
||||
<string name="error_scanning_bill_qr_code">Failed to parse QR code.</string>
|
||||
<string name="error_token_mismatch">Authentication token mismatch. Please log in again.</string>
|
||||
<string name="insufficient_access_level">You don\'t have permission to perform this action.</string>
|
||||
<string name="delete_label_confirmation_title">Delete Label</string>
|
||||
<string name="delete_label_confirmation_message">Are you sure you want to delete this label?</string>
|
||||
|
||||
<!-- About -->
|
||||
<string name="about_version">Version %1$s</string>
|
||||
<string name="about_maintainer_title">Maintainer</string>
|
||||
<string name="about_license_title">License</string>
|
||||
<string name="about_source_title">Source code</string>
|
||||
|
||||
<!-- New constants for backward compatibility or shared use -->
|
||||
<string name="share_intent_title">Project %1$s</string>
|
||||
<string name="share_chooser_title">Share %1$s</string>
|
||||
|
||||
</resources>
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<string name="app_name">Cowspent</string>
|
||||
<string name="app_name" translatable="false">Cowspent</string>
|
||||
|
||||
<!-- Actions -->
|
||||
<string name="action_new_bill">New bill</string>
|
||||
@@ -10,7 +10,11 @@
|
||||
<string name="action_edit">Edit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_search">Search</string>
|
||||
<string name="action_open_menu">Open menu</string>
|
||||
<string name="action_close_search">Close search</string>
|
||||
<string name="action_clear_search">Clear search</string>
|
||||
<string name="action_delete">Delete</string>
|
||||
<string name="simple_back">Back</string>
|
||||
<string name="action_archive">Archive</string>
|
||||
<string name="action_unarchive">Unarchive</string>
|
||||
<string name="action_export">Export</string>
|
||||
@@ -137,11 +141,20 @@
|
||||
<string name="settings_show_archived">Show archived projects</string>
|
||||
<string name="settings_beta_features">Beta Features</string>
|
||||
<string name="settings_beta_features_summary">Enable experimental features. Use at your own risk.</string>
|
||||
<string name="settings_fill_new_bill_from_last">Auto-fill from last bill</string>
|
||||
<string name="settings_fill_new_bill_from_last_summary">Pre-fill payer, category, mode and owers from the last bill created in the project.</string>
|
||||
<string name="settings_stats_include_deactivated">Include deactivated members in stats</string>
|
||||
<string name="settings_auto_sync_on_open">Sync interval</string>
|
||||
<string name="settings_auto_sync_on_open_summary">How often to refresh the account and all projects when opening the app.</string>
|
||||
<string name="pref_value_sync_1m">1 minute</string>
|
||||
<string name="pref_value_sync_10m">10 minutes</string>
|
||||
<string name="pref_value_sync_1h">1 hour</string>
|
||||
<string name="pref_value_sync_1d">1 day</string>
|
||||
<string name="settings_url_warn_http">WARNING: "http" is unsafe. Use "https".</string>
|
||||
<string name="settings_colorpicker_title">Choose Color</string>
|
||||
|
||||
<string name="pref_value_color_system">System</string>
|
||||
<string name="pref_value_color_server">Nextcloud</string>
|
||||
<string name="pref_value_color_server" translatable="false">Nextcloud</string>
|
||||
<string name="pref_value_color_manual">Manual</string>
|
||||
<string name="pref_value_theme_light">Light</string>
|
||||
<string name="pref_value_theme_dark">Dark</string>
|
||||
@@ -158,6 +171,10 @@
|
||||
<string name="pref_key_offline_mode" translatable="false">offlineMode</string>
|
||||
<string name="pref_key_show_archived" translatable="false">showArchived</string>
|
||||
<string name="pref_key_beta_features" translatable="false">betaFeatures</string>
|
||||
<string name="pref_key_stats_include_deactivated" translatable="false">statsIncludeDeactivated</string>
|
||||
<string name="pref_key_auto_sync_on_open" translatable="false">autoSyncOnOpen</string>
|
||||
<string name="pref_key_last_account_sync_timestamp" translatable="false">lastAccountSyncTimestamp</string>
|
||||
<string name="pref_key_fill_new_bill_from_last" translatable="false">fillNewBillFromLast</string>
|
||||
<string name="pref_value_night_mode_no" translatable="false">1</string>
|
||||
<string name="pref_value_night_mode_yes" translatable="false">2</string>
|
||||
<string name="pref_value_night_mode_system" translatable="false">-1</string>
|
||||
@@ -198,13 +215,11 @@
|
||||
<string name="new_project_action">What</string>
|
||||
<string name="new_project_where">Where</string>
|
||||
<string name="where_local">Local only</string>
|
||||
<string name="where_cospend">Cospend</string>
|
||||
<string name="where_ihatemoney">IHateMoney</string>
|
||||
<string name="where_cospend" translatable="false">Cospend</string>
|
||||
<string name="where_ihatemoney" translatable="false">IHateMoney</string>
|
||||
<string name="todo_join">Join existing project</string>
|
||||
<string name="todo_create">Create new project</string>
|
||||
<string name="import_tooltip">Import from file</string>
|
||||
<string name="choose_account_project_dialog_title">Choose project</string>
|
||||
<string name="choose_account_project_dialog_impossible">No projects found on this account.</string>
|
||||
<string name="choose_project_management_action">Project</string>
|
||||
<string name="project_added_success">Project added successfully.</string>
|
||||
<string name="no_projects_text">You have no projects yet.</string>
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
package net.helcel.cowspent
|
||||
|
||||
import androidx.compose.ui.ExperimentalComposeUiApi
|
||||
import androidx.compose.ui.InternalComposeUiApi
|
||||
import androidx.compose.ui.platform.InfiniteAnimationPolicy
|
||||
import androidx.compose.ui.platform.WindowRecomposerFactory
|
||||
import androidx.compose.ui.platform.WindowRecomposerPolicy
|
||||
import androidx.compose.ui.platform.createLifecycleAwareWindowRecomposer
|
||||
import kotlinx.coroutines.CancellationException
|
||||
import org.junit.rules.TestWatcher
|
||||
import org.junit.runner.Description
|
||||
|
||||
/**
|
||||
* Robolectric's paused looper only goes idle once nothing is left to run, but a Compose infinite
|
||||
* animation (the pull-to-refresh spinner, for instance) keeps requesting frames forever. Any test
|
||||
* that launches an activity whose UI shows one then burns minutes of CPU inside
|
||||
* ActivityScenario.launch() before it gives up.
|
||||
*
|
||||
* ComposeTestRule solves this by installing an InfiniteAnimationPolicy that cancels those
|
||||
* animations; this rule does the same for tests driving an activity directly.
|
||||
*/
|
||||
@OptIn(ExperimentalComposeUiApi::class, InternalComposeUiApi::class)
|
||||
class NoInfiniteAnimationsRule : TestWatcher() {
|
||||
|
||||
private object CancelInfiniteAnimations : InfiniteAnimationPolicy {
|
||||
override suspend fun <R> onInfiniteOperation(block: suspend () -> R): R =
|
||||
throw CancellationException("Infinite animations are disabled in unit tests")
|
||||
}
|
||||
|
||||
override fun starting(description: Description) {
|
||||
WindowRecomposerPolicy.setFactory { view ->
|
||||
view.createLifecycleAwareWindowRecomposer(CancelInfiniteAnimations)
|
||||
}
|
||||
}
|
||||
|
||||
override fun finished(description: Description) {
|
||||
WindowRecomposerPolicy.setFactory(WindowRecomposerFactory.LifecycleAware)
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,86 @@
|
||||
package net.helcel.cowspent.android
|
||||
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.ui.test.junit4.createComposeRule
|
||||
import androidx.compose.ui.test.*
|
||||
import net.helcel.cowspent.NoInfiniteAnimationsRule
|
||||
import org.junit.Rule
|
||||
import org.junit.Test
|
||||
import org.junit.runner.RunWith
|
||||
import org.robolectric.RobolectricTestRunner
|
||||
import org.robolectric.annotation.Config
|
||||
|
||||
/**
|
||||
* Every `@Preview` in the app, rendered once.
|
||||
*
|
||||
* Previews are compiled into the release APK and are the only caller of some composables with
|
||||
* awkward argument shapes, so a preview that throws is a real compile-time-clean runtime break that
|
||||
* nothing else would catch. This is a smoke test: it asserts the tree composed, not what it looks
|
||||
* like — the behaviour of each screen is covered by that screen's own tests.
|
||||
*/
|
||||
@RunWith(RobolectricTestRunner::class)
|
||||
@Config(sdk = [34], qualifiers = "w1080dp-h2400dp")
|
||||
class PreviewsTest {
|
||||
|
||||
@get:Rule
|
||||
val composeTestRule = createComposeRule()
|
||||
|
||||
@get:Rule
|
||||
val noInfiniteAnimations = NoInfiniteAnimationsRule()
|
||||
|
||||
private fun renders(preview: @Composable () -> Unit) {
|
||||
composeTestRule.setContent { preview() }
|
||||
composeTestRule.waitForIdle()
|
||||
composeTestRule.onRoot().assertExists()
|
||||
}
|
||||
|
||||
@Test fun testBillItemRow() = renders { net.helcel.cowspent.android.main.BillItemRowPreview() }
|
||||
@Test fun testSectionHeader() = renders { net.helcel.cowspent.android.main.SectionHeaderPreview() }
|
||||
@Test fun testEmptyProjectsState() = renders { net.helcel.cowspent.android.main.EmptyProjectsStatePreview() }
|
||||
@Test fun testEmptyMembersState() = renders { net.helcel.cowspent.android.main.EmptyMembersStatePreview() }
|
||||
@Test fun testEmptyBillsState() = renders { net.helcel.cowspent.android.main.EmptyBillsStatePreview() }
|
||||
|
||||
@Test fun testEditBillScreen() = renders { net.helcel.cowspent.android.bill_edit.EditBillScreenPreview() }
|
||||
@Test fun testEditBillScreenWeighted() = renders { net.helcel.cowspent.android.bill_edit.EditBillScreenWeightedPreview() }
|
||||
@Test fun testEditBillScreenCustom() = renders { net.helcel.cowspent.android.bill_edit.EditBillScreenCustomPreview() }
|
||||
@Test fun testEditBillScreenPercent() = renders { net.helcel.cowspent.android.bill_edit.EditBillScreenPercentPreview() }
|
||||
|
||||
@Test fun testUserAvatar() = renders { net.helcel.cowspent.android.helper.UserAvatarPreview() }
|
||||
@Test fun testUserAvatarCustomColor() = renders { net.helcel.cowspent.android.helper.UserAvatarCustomColorPreview() }
|
||||
@Test fun testUserAvatarDisabled() = renders { net.helcel.cowspent.android.helper.UserAvatarDisabledPreview() }
|
||||
|
||||
@Test fun testProjectSettlementUI() = renders { net.helcel.cowspent.android.project.settle.ProjectSettlementUIPreview() }
|
||||
@Test fun testProjectSettlementUIBalanced() = renders { net.helcel.cowspent.android.project.settle.ProjectSettlementUIBalancedPreview() }
|
||||
|
||||
@Test fun testLabelManagementCategories() = renders { net.helcel.cowspent.android.label.LabelManagementCategoriesPreview() }
|
||||
@Test fun testLabelManagementPaymentModes() = renders { net.helcel.cowspent.android.label.LabelManagementPaymentModesPreview() }
|
||||
|
||||
@Test fun testDrawerItem() = renders { net.helcel.cowspent.android.drawer.DrawerItemPreview() }
|
||||
@Test fun testDrawer() = renders { net.helcel.cowspent.android.drawer.DrawerPreview() }
|
||||
|
||||
@Test fun testCurrencyRow() = renders { net.helcel.cowspent.android.currencies.CurrencyRowPreview() }
|
||||
@Test fun testManageCurrenciesScreen() = renders { net.helcel.cowspent.android.currencies.ManageCurrenciesScreenPreview() }
|
||||
|
||||
@Test fun testProjectStatisticsTable() = renders { net.helcel.cowspent.android.statistics.ProjectStatisticsTablePreview() }
|
||||
@Test fun testProjectSpendingGraph() = renders { net.helcel.cowspent.android.statistics.ProjectSpendingGraphPreview() }
|
||||
@Test fun testProjectSankeyDiagram() = renders { net.helcel.cowspent.android.statistics.ProjectSankeyDiagramPreview() }
|
||||
|
||||
@Test fun testProjectShareDialogContent() = renders { net.helcel.cowspent.android.project.ProjectShareDialogContentPreview() }
|
||||
@Test fun testMemberManagementScreen() = renders { net.helcel.cowspent.android.project.member.MemberManagementScreenPreview() }
|
||||
@Test fun testMemberEditDialogContent() = renders { net.helcel.cowspent.android.project.member.MemberEditDialogContentPreview() }
|
||||
@Test fun testMemberAddDialogContent() = renders { net.helcel.cowspent.android.project.member.MemberAddDialogContentPreview() }
|
||||
@Test fun testEditProjectScreen() = renders { net.helcel.cowspent.android.project.edit.EditProjectScreenPreview() }
|
||||
@Test fun testNewProjectScreen() = renders { net.helcel.cowspent.android.project.create.NewProjectScreenPreview() }
|
||||
|
||||
@Test fun testColorPicker() = renders { net.helcel.cowspent.android.helper.ColorPickerPreview() }
|
||||
@Test fun testLabelBillsScreen() = renders { net.helcel.cowspent.android.bill_label.LabelBillsScreenPreview() }
|
||||
@Test fun testAccountScreen() = renders { net.helcel.cowspent.android.account.AccountScreenPreview() }
|
||||
@Test fun testAboutScreen() = renders { net.helcel.cowspent.android.about.AboutScreenPreview() }
|
||||
|
||||
@Test fun testSimpleAlertDialog() = renders { net.helcel.cowspent.android.helper.SimpleAlertDialogPreview() }
|
||||
@Test fun testConfirmationDialog() = renders { net.helcel.cowspent.android.helper.ConfirmationDialogPreview() }
|
||||
@Test fun testListDialogWithIcons() = renders { net.helcel.cowspent.android.helper.ListDialogWithIconsPreview() }
|
||||
|
||||
/** Opens a real database, so it is the one preview that needs a Robolectric context to exist. */
|
||||
@Test fun testBillsListScreen() = renders { net.helcel.cowspent.android.main.BillsListScreenPreview() }
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
files:
|
||||
- source: /app/src/main/res/values/strings.xml
|
||||
translation: /app/src/main/res/values-%android_code%/strings.xml
|
||||
+4
-2
@@ -19,10 +19,12 @@ org.gradle.dependency.verification.console=verbose
|
||||
# When configured, Gradle will run in incubating parallel mode.
|
||||
# This option should only be used with decoupled projects. More details, visit
|
||||
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
|
||||
# org.gradle.parallel=true
|
||||
org.gradle.parallel=true
|
||||
android.useAndroidX=true
|
||||
android.nonTransitiveRClass=false
|
||||
org.gradle.warning.mode=all
|
||||
android.uniquePackageNames=false
|
||||
android.dependency.useConstraints=false
|
||||
android.r8.strictFullModeForKeepRules=false
|
||||
android.r8.strictFullModeForKeepRules=false
|
||||
# Enabled parallel sync for Gradle 9.4+
|
||||
org.gradle.tooling.parallel=true
|
||||
|
||||
Vendored
BIN
Binary file not shown.
+1
-1
@@ -1,6 +1,6 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-9.6.1-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-9.7.1-bin.zip
|
||||
networkTimeout=10000
|
||||
retries=0
|
||||
retryBackOffMs=500
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/bin/sh
|
||||
|
||||
#
|
||||
# Copyright © 2015-2021 the original authors.
|
||||
# Copyright © 2015 the original authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
@@ -20,7 +20,7 @@
|
||||
|
||||
##############################################################################
|
||||
#
|
||||
# Gradle start up script for POSIX generated by Gradle.
|
||||
# gradlew start up script for POSIX generated by Gradle.
|
||||
#
|
||||
# Important for running:
|
||||
#
|
||||
@@ -29,7 +29,7 @@
|
||||
# bash, then to run this script, type that shell name before the whole
|
||||
# command line, like:
|
||||
#
|
||||
# ksh Gradle
|
||||
# ksh gradlew
|
||||
#
|
||||
# Busybox and similar reduced shells will NOT work, because this script
|
||||
# requires all of these POSIX shell features:
|
||||
@@ -57,7 +57,7 @@
|
||||
# Darwin, MinGW, and NonStop.
|
||||
#
|
||||
# (3) This script is generated from the Groovy template
|
||||
# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||
# https://github.com/gradle/gradle/blob/3d91ce3b8caaf77ad09f381f43615b715b53f72c/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||
# within the Gradle project.
|
||||
#
|
||||
# You can find Gradle at https://github.com/gradle/gradle/.
|
||||
@@ -114,7 +114,6 @@ case "$( uname )" in #(
|
||||
NONSTOP* ) nonstop=true ;;
|
||||
esac
|
||||
|
||||
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
||||
|
||||
|
||||
# Determine the Java command to use to start the JVM.
|
||||
@@ -172,7 +171,6 @@ fi
|
||||
# For Cygwin or MSYS, switch paths to Windows format before running java
|
||||
if "$cygwin" || "$msys" ; then
|
||||
APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
|
||||
CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
|
||||
|
||||
JAVACMD=$( cygpath --unix "$JAVACMD" )
|
||||
|
||||
@@ -212,8 +210,7 @@ DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||
|
||||
set -- \
|
||||
"-Dorg.gradle.appname=$APP_BASE_NAME" \
|
||||
-classpath "$CLASSPATH" \
|
||||
org.gradle.wrapper.GradleWrapperMain \
|
||||
-jar "$APP_HOME/gradle/wrapper/gradle-wrapper.jar" \
|
||||
"$@"
|
||||
|
||||
# Stop when "xargs" is not available.
|
||||
|
||||
Vendored
+12
-24
@@ -19,12 +19,12 @@
|
||||
@if "%DEBUG%"=="" @echo off
|
||||
@rem ##########################################################################
|
||||
@rem
|
||||
@rem Gradle startup script for Windows
|
||||
@rem gradlew startup script for Windows
|
||||
@rem
|
||||
@rem ##########################################################################
|
||||
|
||||
@rem Set local scope for the variables with windows NT shell
|
||||
if "%OS%"=="Windows_NT" setlocal
|
||||
@rem Set local scope for the variables, and ensure extensions are enabled
|
||||
setlocal EnableExtensions
|
||||
|
||||
set DIRNAME=%~dp0
|
||||
if "%DIRNAME%"=="" set DIRNAME=.
|
||||
@@ -51,7 +51,7 @@ echo. 1>&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
||||
echo location of your Java installation. 1>&2
|
||||
|
||||
goto fail
|
||||
"%COMSPEC%" /c exit 1
|
||||
|
||||
:findJavaFromJavaHome
|
||||
set JAVA_HOME=%JAVA_HOME:"=%
|
||||
@@ -65,30 +65,18 @@ echo. 1>&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
|
||||
echo location of your Java installation. 1>&2
|
||||
|
||||
goto fail
|
||||
"%COMSPEC%" /c exit 1
|
||||
|
||||
:execute
|
||||
@rem Setup the command line
|
||||
|
||||
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
|
||||
|
||||
|
||||
@rem Execute Gradle
|
||||
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
|
||||
@rem Execute gradlew
|
||||
@rem endlocal doesn't take effect until after the line is parsed and variables are expanded
|
||||
@rem which allows us to clear the local environment before executing the java command
|
||||
endlocal & "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %* & call :exitWithErrorLevel
|
||||
|
||||
:end
|
||||
@rem End local scope for the variables with windows NT shell
|
||||
if %ERRORLEVEL% equ 0 goto mainEnd
|
||||
|
||||
:fail
|
||||
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
|
||||
rem the _cmd.exe /c_ return code!
|
||||
set EXIT_CODE=%ERRORLEVEL%
|
||||
if %EXIT_CODE% equ 0 set EXIT_CODE=1
|
||||
if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
|
||||
exit /b %EXIT_CODE%
|
||||
|
||||
:mainEnd
|
||||
if "%OS%"=="Windows_NT" endlocal
|
||||
|
||||
:omega
|
||||
:exitWithErrorLevel
|
||||
@rem Use "%COMSPEC%" /c exit to allow operators to work properly in scripts
|
||||
"%COMSPEC%" /c exit %ERRORLEVEL%
|
||||
|
||||
@@ -6,6 +6,9 @@ pluginManagement {
|
||||
maven { url = 'https://jitpack.io' }
|
||||
}
|
||||
}
|
||||
plugins {
|
||||
id 'org.gradle.toolchains.foojay-resolver-convention' version '1.0.0'
|
||||
}
|
||||
dependencyResolutionManagement {
|
||||
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
|
||||
repositories {
|
||||
|
||||
Reference in New Issue
Block a user