Compare commits
No commits in common. "master" and "multiple-children" have entirely different histories.
master
...
multiple-c
@ -12,8 +12,8 @@ android {
|
|||||||
applicationId = "it.danieleverducci.lunatracker"
|
applicationId = "it.danieleverducci.lunatracker"
|
||||||
minSdk = 21
|
minSdk = 21
|
||||||
targetSdk = 34
|
targetSdk = 34
|
||||||
versionCode = 4
|
versionCode = 2
|
||||||
versionName = "0.6"
|
versionName = "0.3"
|
||||||
|
|
||||||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,5 @@
|
|||||||
package it.danieleverducci.lunatracker
|
package it.danieleverducci.lunatracker
|
||||||
|
|
||||||
import android.app.DatePickerDialog
|
|
||||||
import android.app.TimePickerDialog
|
|
||||||
import android.content.DialogInterface
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.os.Handler
|
import android.os.Handler
|
||||||
@ -21,6 +18,7 @@ import android.widget.Toast
|
|||||||
import androidx.appcompat.app.AlertDialog
|
import androidx.appcompat.app.AlertDialog
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.core.content.ContextCompat
|
import androidx.core.content.ContextCompat
|
||||||
|
import androidx.core.view.children
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
import androidx.recyclerview.widget.RecyclerView
|
import androidx.recyclerview.widget.RecyclerView
|
||||||
import com.google.android.material.progressindicator.LinearProgressIndicator
|
import com.google.android.material.progressindicator.LinearProgressIndicator
|
||||||
@ -41,7 +39,6 @@ import okio.IOException
|
|||||||
import org.json.JSONException
|
import org.json.JSONException
|
||||||
import utils.NumericUtils
|
import utils.NumericUtils
|
||||||
import java.text.DateFormat
|
import java.text.DateFormat
|
||||||
import java.util.Calendar
|
|
||||||
import java.util.Date
|
import java.util.Date
|
||||||
|
|
||||||
class MainActivity : AppCompatActivity() {
|
class MainActivity : AppCompatActivity() {
|
||||||
@ -51,16 +48,15 @@ class MainActivity : AppCompatActivity() {
|
|||||||
val DEBUG_CHECK_LOGBOOK_CONSISTENCY = false
|
val DEBUG_CHECK_LOGBOOK_CONSISTENCY = false
|
||||||
}
|
}
|
||||||
|
|
||||||
var logbook: Logbook? = null
|
lateinit var logbook: Logbook
|
||||||
var pauseLogbookUpdate = false
|
lateinit var adapter: LunaEventRecyclerAdapter
|
||||||
lateinit var progressIndicator: LinearProgressIndicator
|
lateinit var progressIndicator: LinearProgressIndicator
|
||||||
lateinit var buttonsContainer: ViewGroup
|
lateinit var buttonsContainer: ViewGroup
|
||||||
lateinit var recyclerView: RecyclerView
|
lateinit var recyclerView: RecyclerView
|
||||||
lateinit var handler: Handler
|
lateinit var handler: Handler
|
||||||
var savingEvent = false
|
var savingEvent = false
|
||||||
val updateListRunnable: Runnable = Runnable {
|
val updateListRunnable: Runnable = Runnable {
|
||||||
if (logbook != null && !pauseLogbookUpdate)
|
loadLogbook(logbook.name)
|
||||||
loadLogbook(logbook!!.name)
|
|
||||||
handler.postDelayed(updateListRunnable, 1000*60)
|
handler.postDelayed(updateListRunnable, 1000*60)
|
||||||
}
|
}
|
||||||
var logbookRepo: LogbookRepository? = null
|
var logbookRepo: LogbookRepository? = null
|
||||||
@ -70,6 +66,12 @@ class MainActivity : AppCompatActivity() {
|
|||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
|
|
||||||
handler = Handler(mainLooper)
|
handler = Handler(mainLooper)
|
||||||
|
adapter = LunaEventRecyclerAdapter(this)
|
||||||
|
adapter.onItemClickListener = object: LunaEventRecyclerAdapter.OnItemClickListener{
|
||||||
|
override fun onItemClick(event: LunaEvent) {
|
||||||
|
showEventDetailDialog(event)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Show view
|
// Show view
|
||||||
setContentView(R.layout.activity_main)
|
setContentView(R.layout.activity_main)
|
||||||
@ -78,11 +80,12 @@ class MainActivity : AppCompatActivity() {
|
|||||||
buttonsContainer = findViewById<ViewGroup>(R.id.buttons_container)
|
buttonsContainer = findViewById<ViewGroup>(R.id.buttons_container)
|
||||||
recyclerView = findViewById<RecyclerView>(R.id.list_events)
|
recyclerView = findViewById<RecyclerView>(R.id.list_events)
|
||||||
recyclerView.setLayoutManager(LinearLayoutManager(applicationContext))
|
recyclerView.setLayoutManager(LinearLayoutManager(applicationContext))
|
||||||
|
recyclerView.adapter = adapter
|
||||||
|
|
||||||
// Set listeners
|
// Set listeners
|
||||||
findViewById<View>(R.id.logbooks_add_button).setOnClickListener { showAddLogbookDialog(true) }
|
findViewById<View>(R.id.logbooks_add_button).setOnClickListener { showAddLogbookDialog(true) }
|
||||||
findViewById<View>(R.id.button_bottle).setOnClickListener { askBabyBottleContent() }
|
findViewById<View>(R.id.button_bottle).setOnClickListener { askBabyBottleContent() }
|
||||||
findViewById<View>(R.id.button_food).setOnClickListener { askNotes(LunaEvent(LunaEvent.TYPE_FOOD)) }
|
findViewById<View>(R.id.button_scale).setOnClickListener { askWeightValue() }
|
||||||
findViewById<View>(R.id.button_nipple_left).setOnClickListener { logEvent(
|
findViewById<View>(R.id.button_nipple_left).setOnClickListener { logEvent(
|
||||||
LunaEvent(
|
LunaEvent(
|
||||||
LunaEvent.TYPE_BREASTFEEDING_LEFT_NIPPLE
|
LunaEvent.TYPE_BREASTFEEDING_LEFT_NIPPLE
|
||||||
@ -119,24 +122,13 @@ class MainActivity : AppCompatActivity() {
|
|||||||
showSettings()
|
showSettings()
|
||||||
})
|
})
|
||||||
findViewById<View>(R.id.button_no_connection_retry).setOnClickListener({
|
findViewById<View>(R.id.button_no_connection_retry).setOnClickListener({
|
||||||
// This may happen at start, when logbook is still null: better ask the logbook list
|
loadLogbook(logbook.name)
|
||||||
loadLogbookList()
|
|
||||||
})
|
})
|
||||||
findViewById<View>(R.id.button_sync).setOnClickListener({
|
findViewById<View>(R.id.button_sync).setOnClickListener({
|
||||||
loadLogbookList()
|
loadLogbook(logbook.name)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setListAdapter(items: ArrayList<LunaEvent>) {
|
|
||||||
val adapter = LunaEventRecyclerAdapter(this, items)
|
|
||||||
adapter.onItemClickListener = object: LunaEventRecyclerAdapter.OnItemClickListener{
|
|
||||||
override fun onItemClick(event: LunaEvent) {
|
|
||||||
showEventDetailDialog(event)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
recyclerView.adapter = adapter
|
|
||||||
}
|
|
||||||
|
|
||||||
fun showSettings() {
|
fun showSettings() {
|
||||||
val i = Intent(this, SettingsActivity::class.java)
|
val i = Intent(this, SettingsActivity::class.java)
|
||||||
startActivity(i)
|
startActivity(i)
|
||||||
@ -144,10 +136,9 @@ class MainActivity : AppCompatActivity() {
|
|||||||
|
|
||||||
fun showLogbook() {
|
fun showLogbook() {
|
||||||
// Show logbook
|
// Show logbook
|
||||||
if (logbook == null)
|
adapter.items.clear()
|
||||||
Log.w(TAG, "showLogbook(): logbook is null!")
|
adapter.items.addAll(logbook.logs)
|
||||||
|
adapter.notifyDataSetChanged()
|
||||||
setListAdapter(logbook?.logs ?: arrayListOf())
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onStart() {
|
override fun onStart() {
|
||||||
@ -169,15 +160,10 @@ class MainActivity : AppCompatActivity() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Update list dates
|
// Update list dates
|
||||||
recyclerView.adapter?.notifyDataSetChanged()
|
adapter.notifyDataSetChanged()
|
||||||
|
|
||||||
if (logbook != null) {
|
// Reload data
|
||||||
// Already running: reload data for currently selected logbook
|
loadLogbookList()
|
||||||
loadLogbook(logbook!!.name)
|
|
||||||
} else {
|
|
||||||
// First start: load logbook list
|
|
||||||
loadLogbookList()
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onStop() {
|
override fun onStop() {
|
||||||
@ -257,7 +243,12 @@ class MainActivity : AppCompatActivity() {
|
|||||||
val d = AlertDialog.Builder(this)
|
val d = AlertDialog.Builder(this)
|
||||||
val dialogView = layoutInflater.inflate(R.layout.dialog_notes, null)
|
val dialogView = layoutInflater.inflate(R.layout.dialog_notes, null)
|
||||||
d.setTitle(lunaEvent.getTypeDescription(this))
|
d.setTitle(lunaEvent.getTypeDescription(this))
|
||||||
d.setMessage(lunaEvent.getDialogMessage(this))
|
d.setMessage(
|
||||||
|
when (lunaEvent.type){
|
||||||
|
LunaEvent.TYPE_MEDICINE -> R.string.log_medicine_dialog_description
|
||||||
|
else -> R.string.log_notes_dialog_description
|
||||||
|
}
|
||||||
|
)
|
||||||
d.setView(dialogView)
|
d.setView(dialogView)
|
||||||
val notesET = dialogView.findViewById<EditText>(R.id.notes_edittext)
|
val notesET = dialogView.findViewById<EditText>(R.id.notes_edittext)
|
||||||
val qtyET = dialogView.findViewById<EditText>(R.id.notes_qty_edittext)
|
val qtyET = dialogView.findViewById<EditText>(R.id.notes_qty_edittext)
|
||||||
@ -292,7 +283,7 @@ class MainActivity : AppCompatActivity() {
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
d.setPositiveButton(R.string.trim_logbook_dialog_button_ok) { dialogInterface, i ->
|
d.setPositiveButton(R.string.trim_logbook_dialog_button_ok) { dialogInterface, i ->
|
||||||
logbook?.trim()
|
logbook.trim()
|
||||||
saveLogbook()
|
saveLogbook()
|
||||||
}
|
}
|
||||||
d.setNegativeButton(R.string.trim_logbook_dialog_button_cancel) { dialogInterface, i ->
|
d.setNegativeButton(R.string.trim_logbook_dialog_button_cancel) { dialogInterface, i ->
|
||||||
@ -303,57 +294,21 @@ class MainActivity : AppCompatActivity() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun showEventDetailDialog(event: LunaEvent) {
|
fun showEventDetailDialog(event: LunaEvent) {
|
||||||
// Do not update list while the detail is shown, to avoid changing the object below while it is changed by the user
|
|
||||||
pauseLogbookUpdate = true
|
|
||||||
val dateFormat = DateFormat.getDateTimeInstance();
|
val dateFormat = DateFormat.getDateTimeInstance();
|
||||||
val d = AlertDialog.Builder(this)
|
val d = AlertDialog.Builder(this)
|
||||||
d.setTitle(R.string.dialog_event_detail_title)
|
d.setTitle(R.string.dialog_event_detail_title)
|
||||||
val dialogView = layoutInflater.inflate(R.layout.dialog_event_detail, null)
|
val dialogView = layoutInflater.inflate(R.layout.dialog_event_detail, null)
|
||||||
dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_emoji).setText(event.getTypeEmoji(this))
|
dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_emoji).setText(event.getTypeEmoji(this))
|
||||||
dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_description).setText(event.getTypeDescription(this))
|
dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_description).setText(event.getTypeDescription(this))
|
||||||
|
dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_date).setText(dateFormat.format(Date(event.time * 1000)))
|
||||||
dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_quantity).setText(
|
dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_quantity).setText(
|
||||||
NumericUtils(this).formatEventQuantity(event)
|
NumericUtils(this).formatEventQuantity(event)
|
||||||
)
|
)
|
||||||
dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_notes).setText(event.notes)
|
dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_notes).setText(event.notes)
|
||||||
|
|
||||||
val currentDateTime = Calendar.getInstance()
|
|
||||||
currentDateTime.time = Date(event.time * 1000)
|
|
||||||
val dateTextView = dialogView.findViewById<TextView>(R.id.dialog_event_detail_type_date)
|
|
||||||
dateTextView.text = String.format(getString(R.string.dialog_event_detail_datetime_icon), dateFormat.format(currentDateTime.time))
|
|
||||||
dateTextView.setOnClickListener({
|
|
||||||
// Show datetime picker
|
|
||||||
val startYear = currentDateTime.get(Calendar.YEAR)
|
|
||||||
val startMonth = currentDateTime.get(Calendar.MONTH)
|
|
||||||
val startDay = currentDateTime.get(Calendar.DAY_OF_MONTH)
|
|
||||||
val startHour = currentDateTime.get(Calendar.HOUR_OF_DAY)
|
|
||||||
val startMinute = currentDateTime.get(Calendar.MINUTE)
|
|
||||||
|
|
||||||
DatePickerDialog(this, DatePickerDialog.OnDateSetListener { _, year, month, day ->
|
|
||||||
TimePickerDialog(this, TimePickerDialog.OnTimeSetListener { _, hour, minute ->
|
|
||||||
val pickedDateTime = Calendar.getInstance()
|
|
||||||
pickedDateTime.set(year, month, day, hour, minute)
|
|
||||||
currentDateTime.time = pickedDateTime.time
|
|
||||||
dateTextView.text = String.format(getString(R.string.dialog_event_detail_datetime_icon), dateFormat.format(currentDateTime.time))
|
|
||||||
|
|
||||||
// Save event and move it to the right position in the logbook
|
|
||||||
event.time = currentDateTime.time.time / 1000 // Seconds since epoch
|
|
||||||
logbook?.sort()
|
|
||||||
recyclerView.adapter?.notifyDataSetChanged()
|
|
||||||
saveLogbook()
|
|
||||||
}, startHour, startMinute, false).show()
|
|
||||||
}, startYear, startMonth, startDay).show()
|
|
||||||
})
|
|
||||||
|
|
||||||
d.setView(dialogView)
|
d.setView(dialogView)
|
||||||
d.setPositiveButton(R.string.dialog_event_detail_close_button) { dialogInterface, i -> dialogInterface.dismiss() }
|
d.setPositiveButton(android.R.string.ok) { dialogInterface, i -> dialogInterface.dismiss() }
|
||||||
d.setNeutralButton(R.string.dialog_event_detail_delete_button) { dialogInterface, i -> deleteEvent(event) }
|
|
||||||
val alertDialog = d.create()
|
val alertDialog = d.create()
|
||||||
alertDialog.show()
|
alertDialog.show()
|
||||||
alertDialog.getButton(DialogInterface.BUTTON_NEUTRAL).setTextColor(ContextCompat.getColor(this, R.color.danger))
|
|
||||||
alertDialog.setOnDismissListener({
|
|
||||||
// Resume logbook update
|
|
||||||
pauseLogbookUpdate = false
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun showAddLogbookDialog(requestedByUser: Boolean) {
|
fun showAddLogbookDialog(requestedByUser: Boolean) {
|
||||||
@ -404,7 +359,8 @@ class MainActivity : AppCompatActivity() {
|
|||||||
id: Long
|
id: Long
|
||||||
) {
|
) {
|
||||||
// Changed logbook: empty list
|
// Changed logbook: empty list
|
||||||
setListAdapter(arrayListOf())
|
adapter.items.clear()
|
||||||
|
adapter.notifyDataSetChanged()
|
||||||
// Load logbook
|
// Load logbook
|
||||||
loadLogbook(logbooksNames.get(position))
|
loadLogbook(logbooksNames.get(position))
|
||||||
}
|
}
|
||||||
@ -416,35 +372,15 @@ class MainActivity : AppCompatActivity() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
override fun onIOError(error: IOException) {
|
override fun onIOError(error: IOException) {
|
||||||
Log.e(TAG, "Unable to load logbooks list (IOError): $error")
|
TODO("Not yet implemented")
|
||||||
runOnUiThread({
|
|
||||||
setLoading(false)
|
|
||||||
onRepoError(getString(R.string.settings_network_error) + error.toString())
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onWebDAVError(error: SardineException) {
|
override fun onWebDAVError(error: SardineException) {
|
||||||
Log.e(TAG, "Unable to load logbooks list (SardineException): $error")
|
TODO("Not yet implemented")
|
||||||
runOnUiThread({
|
|
||||||
setLoading(false)
|
|
||||||
onRepoError(
|
|
||||||
if(error.toString().contains("401")) {
|
|
||||||
getString(R.string.settings_webdav_error_denied)
|
|
||||||
} else if(error.toString().contains("503")) {
|
|
||||||
getString(R.string.settings_webdav_error_server_offline)
|
|
||||||
} else {
|
|
||||||
getString(R.string.settings_webdav_error_generic) + error.toString()
|
|
||||||
}
|
|
||||||
)
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onError(error: Exception) {
|
override fun onError(error: Exception) {
|
||||||
Log.e(TAG, "Unable to load logbooks list: $error")
|
TODO("Not yet implemented")
|
||||||
runOnUiThread({
|
|
||||||
setLoading(false)
|
|
||||||
onRepoError(getString(R.string.settings_generic_error) + error.toString())
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -473,8 +409,6 @@ class MainActivity : AppCompatActivity() {
|
|||||||
onRepoError(
|
onRepoError(
|
||||||
if(error.toString().contains("401")) {
|
if(error.toString().contains("401")) {
|
||||||
getString(R.string.settings_webdav_error_denied)
|
getString(R.string.settings_webdav_error_denied)
|
||||||
} else if(error.toString().contains("503")) {
|
|
||||||
getString(R.string.settings_webdav_error_server_offline)
|
|
||||||
} else {
|
} else {
|
||||||
getString(R.string.settings_webdav_error_generic) + error.toString()
|
getString(R.string.settings_webdav_error_generic) + error.toString()
|
||||||
}
|
}
|
||||||
@ -515,7 +449,7 @@ class MainActivity : AppCompatActivity() {
|
|||||||
showLogbook()
|
showLogbook()
|
||||||
|
|
||||||
if (DEBUG_CHECK_LOGBOOK_CONSISTENCY) {
|
if (DEBUG_CHECK_LOGBOOK_CONSISTENCY) {
|
||||||
for (e in logbook?.logs ?: listOf()) {
|
for (e in logbook.logs) {
|
||||||
val em = e.getTypeEmoji(this@MainActivity)
|
val em = e.getTypeEmoji(this@MainActivity)
|
||||||
if (em == getString(R.string.event_unknown_type)) {
|
if (em == getString(R.string.event_unknown_type)) {
|
||||||
Log.e(TAG, "UNKNOWN: ${e.type}")
|
Log.e(TAG, "UNKNOWN: ${e.type}")
|
||||||
@ -538,8 +472,6 @@ class MainActivity : AppCompatActivity() {
|
|||||||
onRepoError(
|
onRepoError(
|
||||||
if(error.toString().contains("401")) {
|
if(error.toString().contains("401")) {
|
||||||
getString(R.string.settings_webdav_error_denied)
|
getString(R.string.settings_webdav_error_denied)
|
||||||
} else if(error.toString().contains("503")) {
|
|
||||||
getString(R.string.settings_webdav_error_server_offline)
|
|
||||||
} else {
|
} else {
|
||||||
getString(R.string.settings_webdav_error_generic) + error.toString()
|
getString(R.string.settings_webdav_error_generic) + error.toString()
|
||||||
}
|
}
|
||||||
@ -574,40 +506,26 @@ class MainActivity : AppCompatActivity() {
|
|||||||
|
|
||||||
fun logEvent(event: LunaEvent) {
|
fun logEvent(event: LunaEvent) {
|
||||||
savingEvent(true)
|
savingEvent(true)
|
||||||
|
adapter.items.add(0, event)
|
||||||
|
adapter.notifyItemInserted(0)
|
||||||
|
recyclerView.smoothScrollToPosition(0)
|
||||||
|
|
||||||
setLoading(true)
|
setLoading(true)
|
||||||
logbook?.logs?.add(0, event)
|
logbook.logs.add(0, event)
|
||||||
recyclerView.adapter?.notifyItemInserted(0)
|
|
||||||
recyclerView.smoothScrollToPosition(0)
|
|
||||||
saveLogbook(event)
|
saveLogbook(event)
|
||||||
|
|
||||||
// Check logbook size to avoid OOM errors
|
// Check logbook size to avoid OOM errors
|
||||||
if (logbook?.isTooBig() == true) {
|
if (logbook.isTooBig()) {
|
||||||
askToTrimLogbook()
|
askToTrimLogbook()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fun deleteEvent(event: LunaEvent) {
|
|
||||||
// Update view
|
|
||||||
savingEvent(true)
|
|
||||||
|
|
||||||
// Update data
|
|
||||||
setLoading(true)
|
|
||||||
logbook?.logs?.remove(event)
|
|
||||||
recyclerView.adapter?.notifyDataSetChanged()
|
|
||||||
saveLogbook()
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Saves the logbook. If saving while adding an event, please specify the event so in case
|
* Saves the logbook. If saving while adding an event, please specify the event so in case
|
||||||
* of error can be removed from the list.
|
* of error can be removed from the list.
|
||||||
*/
|
*/
|
||||||
fun saveLogbook(lastEventAdded: LunaEvent? = null) {
|
fun saveLogbook(lastEventAdded: LunaEvent? = null) {
|
||||||
if (logbook == null) {
|
logbookRepo?.saveLogbook(this, logbook, object: LogbookSavedListener{
|
||||||
Log.e(TAG, "Trying to save logbook, but logbook is null!")
|
|
||||||
return
|
|
||||||
}
|
|
||||||
logbookRepo?.saveLogbook(this, logbook!!, object: LogbookSavedListener{
|
|
||||||
override fun onLogbookSaved() {
|
override fun onLogbookSaved() {
|
||||||
Log.d(TAG, "Logbook saved")
|
Log.d(TAG, "Logbook saved")
|
||||||
runOnUiThread({
|
runOnUiThread({
|
||||||
@ -640,8 +558,6 @@ class MainActivity : AppCompatActivity() {
|
|||||||
onRepoError(
|
onRepoError(
|
||||||
if(error.toString().contains("401")) {
|
if(error.toString().contains("401")) {
|
||||||
getString(R.string.settings_webdav_error_denied)
|
getString(R.string.settings_webdav_error_denied)
|
||||||
} else if(error.toString().contains("503")) {
|
|
||||||
getString(R.string.settings_webdav_error_server_offline)
|
|
||||||
} else {
|
} else {
|
||||||
getString(R.string.settings_webdav_error_generic) + error.toString()
|
getString(R.string.settings_webdav_error_generic) + error.toString()
|
||||||
}
|
}
|
||||||
@ -677,7 +593,8 @@ class MainActivity : AppCompatActivity() {
|
|||||||
setLoading(false)
|
setLoading(false)
|
||||||
|
|
||||||
Toast.makeText(this@MainActivity, R.string.toast_event_add_error, Toast.LENGTH_SHORT).show()
|
Toast.makeText(this@MainActivity, R.string.toast_event_add_error, Toast.LENGTH_SHORT).show()
|
||||||
recyclerView.adapter?.notifyDataSetChanged()
|
adapter.items.remove(event)
|
||||||
|
adapter.notifyDataSetChanged()
|
||||||
savingEvent(false)
|
savingEvent(false)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -730,10 +647,6 @@ class MainActivity : AppCompatActivity() {
|
|||||||
)
|
)
|
||||||
dismiss()
|
dismiss()
|
||||||
})
|
})
|
||||||
contentView.findViewById<View>(R.id.button_scale).setOnClickListener({
|
|
||||||
askWeightValue()
|
|
||||||
dismiss()
|
|
||||||
})
|
|
||||||
}.also { popupWindow ->
|
}.also { popupWindow ->
|
||||||
popupWindow.setOnDismissListener({
|
popupWindow.setOnDismissListener({
|
||||||
Handler(mainLooper).postDelayed({
|
Handler(mainLooper).postDelayed({
|
||||||
|
@ -14,14 +14,13 @@ import utils.NumericUtils
|
|||||||
|
|
||||||
class LunaEventRecyclerAdapter: RecyclerView.Adapter<LunaEventRecyclerAdapter.LunaEventVH> {
|
class LunaEventRecyclerAdapter: RecyclerView.Adapter<LunaEventRecyclerAdapter.LunaEventVH> {
|
||||||
private val context: Context
|
private val context: Context
|
||||||
private val items: ArrayList<LunaEvent>
|
val items = ArrayList<LunaEvent>()
|
||||||
val numericUtils: NumericUtils
|
val numericUtils: NumericUtils
|
||||||
var onItemClickListener: OnItemClickListener? = null
|
var onItemClickListener: OnItemClickListener? = null
|
||||||
val layoutRes: Int
|
val layoutRes: Int
|
||||||
|
|
||||||
constructor(context: Context, items: ArrayList<LunaEvent>) {
|
constructor(context: Context) {
|
||||||
this.context = context
|
this.context = context
|
||||||
this.items = items
|
|
||||||
this.numericUtils = NumericUtils(context)
|
this.numericUtils = NumericUtils(context)
|
||||||
|
|
||||||
val fontScale = context.resources.configuration.fontScale
|
val fontScale = context.resources.configuration.fontScale
|
||||||
|
@ -16,8 +16,4 @@ class Logbook(val name: String) {
|
|||||||
fun trim() {
|
fun trim() {
|
||||||
logs.subList(MAX_SAFE_LOGBOOK_SIZE/2, logs.size).clear()
|
logs.subList(MAX_SAFE_LOGBOOK_SIZE/2, logs.size).clear()
|
||||||
}
|
}
|
||||||
|
|
||||||
fun sort() {
|
|
||||||
logs.sortDescending()
|
|
||||||
}
|
|
||||||
}
|
}
|
@ -11,7 +11,7 @@ import java.util.Date
|
|||||||
* allow expandability and backwards compatibility (if a field is added in a
|
* allow expandability and backwards compatibility (if a field is added in a
|
||||||
* release, it is simply ignored by previous ones).
|
* release, it is simply ignored by previous ones).
|
||||||
*/
|
*/
|
||||||
class LunaEvent: Comparable<LunaEvent> {
|
class LunaEvent {
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
val TYPE_BABY_BOTTLE = "BABY_BOTTLE"
|
val TYPE_BABY_BOTTLE = "BABY_BOTTLE"
|
||||||
@ -27,7 +27,6 @@ class LunaEvent: Comparable<LunaEvent> {
|
|||||||
val TYPE_CUSTOM = "CUSTOM"
|
val TYPE_CUSTOM = "CUSTOM"
|
||||||
val TYPE_COLIC = "COLIC"
|
val TYPE_COLIC = "COLIC"
|
||||||
val TYPE_TEMPERATURE = "TEMPERATURE"
|
val TYPE_TEMPERATURE = "TEMPERATURE"
|
||||||
val TYPE_FOOD = "FOOD"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private val jo: JSONObject
|
private val jo: JSONObject
|
||||||
@ -89,7 +88,6 @@ class LunaEvent: Comparable<LunaEvent> {
|
|||||||
TYPE_NOTE -> R.string.event_note_type
|
TYPE_NOTE -> R.string.event_note_type
|
||||||
TYPE_TEMPERATURE -> R.string.event_temperature_type
|
TYPE_TEMPERATURE -> R.string.event_temperature_type
|
||||||
TYPE_COLIC -> R.string.event_colic_type
|
TYPE_COLIC -> R.string.event_colic_type
|
||||||
TYPE_FOOD -> R.string.event_food_type
|
|
||||||
else -> R.string.event_unknown_type
|
else -> R.string.event_unknown_type
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
@ -110,19 +108,11 @@ class LunaEvent: Comparable<LunaEvent> {
|
|||||||
TYPE_NOTE -> R.string.event_note_desc
|
TYPE_NOTE -> R.string.event_note_desc
|
||||||
TYPE_TEMPERATURE -> R.string.event_temperature_desc
|
TYPE_TEMPERATURE -> R.string.event_temperature_desc
|
||||||
TYPE_COLIC -> R.string.event_colic_desc
|
TYPE_COLIC -> R.string.event_colic_desc
|
||||||
TYPE_FOOD -> R.string.event_food_desc
|
|
||||||
else -> R.string.event_unknown_desc
|
else -> R.string.event_unknown_desc
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
fun getDialogMessage(context: Context): String? {
|
|
||||||
return when(type) {
|
|
||||||
TYPE_MEDICINE -> context.getString(R.string.log_medicine_dialog_description)
|
|
||||||
else -> null
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
fun toJson(): JSONObject {
|
fun toJson(): JSONObject {
|
||||||
return jo
|
return jo
|
||||||
}
|
}
|
||||||
@ -130,8 +120,4 @@ class LunaEvent: Comparable<LunaEvent> {
|
|||||||
override fun toString(): String {
|
override fun toString(): String {
|
||||||
return "${type} qty: $quantity time: ${Date(time * 1000)}"
|
return "${type} qty: $quantity time: ${Date(time * 1000)}"
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun compareTo(other: LunaEvent): Int {
|
|
||||||
return (this.time - other.time).toInt()
|
|
||||||
}
|
|
||||||
}
|
}
|
@ -103,32 +103,19 @@ class WebDAVLogbookRepository(val webDavURL: String, val username: String, val p
|
|||||||
listener: LogbookListObtainedListener
|
listener: LogbookListObtainedListener
|
||||||
) {
|
) {
|
||||||
Thread(Runnable {
|
Thread(Runnable {
|
||||||
try {
|
val logbooksNames = arrayListOf<String>()
|
||||||
val logbooksNames = arrayListOf<String>()
|
for (dr: DavResource in sardine.list(webDavURL)){
|
||||||
for (dr: DavResource in sardine.list(webDavURL)){
|
if(!dr.name.startsWith(FILE_NAME_START))
|
||||||
if(!dr.name.startsWith(FILE_NAME_START))
|
continue
|
||||||
continue
|
if(!dr.name.endsWith(FILE_NAME_END))
|
||||||
if(!dr.name.endsWith(FILE_NAME_END))
|
continue
|
||||||
continue
|
logbooksNames.add(
|
||||||
logbooksNames.add(
|
dr.name.replace("${FILE_NAME_START}_", "")
|
||||||
dr.name.replace("${FILE_NAME_START}_", "")
|
.replace(FILE_NAME_START, "")
|
||||||
.replace(FILE_NAME_START, "")
|
.replace(FILE_NAME_END, "")
|
||||||
.replace(FILE_NAME_END, "")
|
)
|
||||||
)
|
|
||||||
}
|
|
||||||
listener.onLogbookListObtained(logbooksNames)
|
|
||||||
} catch (e: SardineException) {
|
|
||||||
Log.e(TAG, e.toString())
|
|
||||||
listener.onWebDAVError(e)
|
|
||||||
} catch (e: IOException) {
|
|
||||||
Log.e(TAG, e.toString())
|
|
||||||
listener.onIOError(e)
|
|
||||||
} catch (e: SocketTimeoutException) {
|
|
||||||
Log.e(TAG, e.toString())
|
|
||||||
listener.onIOError(e)
|
|
||||||
} catch (e: Exception) {
|
|
||||||
listener.onError(e)
|
|
||||||
}
|
}
|
||||||
|
listener.onLogbookListObtained(logbooksNames)
|
||||||
}).start()
|
}).start()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,5 +0,0 @@
|
|||||||
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:height="24dp" android:tint="#000000" android:viewportHeight="24" android:viewportWidth="24" android:width="24dp">
|
|
||||||
|
|
||||||
<path android:fillColor="@android:color/white" android:pathData="M3,17.25V21h3.75L17.81,9.94l-3.75,-3.75L3,17.25zM20.71,7.04c0.39,-0.39 0.39,-1.02 0,-1.41l-2.34,-2.34c-0.39,-0.39 -1.02,-0.39 -1.41,0l-1.83,1.83 3.75,3.75 1.83,-1.83z"/>
|
|
||||||
|
|
||||||
</vector>
|
|
@ -108,7 +108,7 @@
|
|||||||
android:text="@string/event_bottle_type"/>
|
android:text="@string/event_bottle_type"/>
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/button_food"
|
android:id="@+id/button_scale"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
@ -116,7 +116,7 @@
|
|||||||
android:background="@drawable/button_background"
|
android:background="@drawable/button_background"
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
android:textSize="50dp"
|
android:textSize="50dp"
|
||||||
android:text="@string/event_food_type"/>
|
android:text="@string/event_scale_type"/>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
@ -25,23 +25,19 @@
|
|||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/dialog_event_detail_type_date"
|
android:id="@+id/dialog_event_detail_type_date"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="40dp"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="20dp"
|
android:layout_marginTop="20dp"
|
||||||
android:layout_gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
android:gravity="center_vertical"
|
|
||||||
android:drawableEnd="@drawable/ic_edit"
|
|
||||||
android:drawablePadding="10dp"
|
|
||||||
android:drawableTint="@color/accent"
|
|
||||||
android:textStyle="bold"
|
android:textStyle="bold"
|
||||||
android:text="@string/dialog_event_detail_datetime_icon"/>
|
android:text="2020"/>
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/dialog_event_detail_type_quantity"
|
android:id="@+id/dialog_event_detail_type_quantity"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
android:text="Quantity"/>
|
android:text="2020"/>
|
||||||
|
|
||||||
<ScrollView
|
<ScrollView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
@ -53,7 +49,7 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textStyle="italic"
|
android:textStyle="italic"
|
||||||
android:text="Notes"/>
|
android:text="Lorem ipsum"/>
|
||||||
|
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
@ -59,16 +59,6 @@
|
|||||||
style="@style/OverflowMenuText"
|
style="@style/OverflowMenuText"
|
||||||
android:text="@string/overflow_event_colic"/>
|
android:text="@string/overflow_event_colic"/>
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/button_scale"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:layout_marginTop="10dp"
|
|
||||||
android:padding="20dp"
|
|
||||||
android:background="@drawable/dropdown_list_item_background"
|
|
||||||
style="@style/OverflowMenuText"
|
|
||||||
android:text="@string/overflow_event_scale"/>
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</ScrollView>
|
</ScrollView>
|
@ -13,7 +13,6 @@
|
|||||||
<string name="log_temperature_dialog_title">Temperatura</string>
|
<string name="log_temperature_dialog_title">Temperatura</string>
|
||||||
<string name="log_temperature_dialog_description">Inserisci la temperatura</string>
|
<string name="log_temperature_dialog_description">Inserisci la temperatura</string>
|
||||||
|
|
||||||
<string name="overflow_event_scale">⚖️ Peso</string>
|
|
||||||
<string name="overflow_event_medicine">💊 Medicina</string>
|
<string name="overflow_event_medicine">💊 Medicina</string>
|
||||||
<string name="overflow_event_enema">🪠 Clistere</string>
|
<string name="overflow_event_enema">🪠 Clistere</string>
|
||||||
<string name="overflow_event_note">📝 Nota</string>
|
<string name="overflow_event_note">📝 Nota</string>
|
||||||
@ -21,7 +20,6 @@
|
|||||||
<string name="overflow_event_colic">💨 Colichette</string>
|
<string name="overflow_event_colic">💨 Colichette</string>
|
||||||
|
|
||||||
<string name="event_bottle_desc">Biberon</string>
|
<string name="event_bottle_desc">Biberon</string>
|
||||||
<string name="event_food_desc">Cibo</string>
|
|
||||||
<string name="event_scale_desc">Pesata</string>
|
<string name="event_scale_desc">Pesata</string>
|
||||||
<string name="event_breastfeeding_left_desc">Allatt. al seno (sx)</string>
|
<string name="event_breastfeeding_left_desc">Allatt. al seno (sx)</string>
|
||||||
<string name="event_breastfeeding_both_desc">Allatt. al seno</string>
|
<string name="event_breastfeeding_both_desc">Allatt. al seno</string>
|
||||||
@ -63,7 +61,6 @@
|
|||||||
<string name="settings_storage_dav_pass">Password</string>
|
<string name="settings_storage_dav_pass">Password</string>
|
||||||
<string name="settings_network_error">Impossibile raggiungere il server: </string>
|
<string name="settings_network_error">Impossibile raggiungere il server: </string>
|
||||||
<string name="settings_webdav_error_denied">Nome utente o password WebDAV sbagliati</string>
|
<string name="settings_webdav_error_denied">Nome utente o password WebDAV sbagliati</string>
|
||||||
<string name="settings_webdav_error_server_offline">Il server WebDAV non è al momento disponibile</string>
|
|
||||||
<string name="settings_webdav_error_generic">Si è verificato un errore tentando di accedere al server WebDAV:</string>
|
<string name="settings_webdav_error_generic">Si è verificato un errore tentando di accedere al server WebDAV:</string>
|
||||||
<string name="settings_webdav_creation_error_generic">Impossibile creare un file di salvataggio sul server WebDAV:</string>
|
<string name="settings_webdav_creation_error_generic">Impossibile creare un file di salvataggio sul server WebDAV:</string>
|
||||||
<string name="settings_webdav_creation_ok">Connessione al server WebDAV avvenuta con successo</string>
|
<string name="settings_webdav_creation_ok">Connessione al server WebDAV avvenuta con successo</string>
|
||||||
@ -83,14 +80,11 @@
|
|||||||
<string name="log_notes_dialog_note_hint">Inserisci le note</string>
|
<string name="log_notes_dialog_note_hint">Inserisci le note</string>
|
||||||
|
|
||||||
<string name="dialog_event_detail_title">Dettaglio evento</string>
|
<string name="dialog_event_detail_title">Dettaglio evento</string>
|
||||||
<string name="dialog_event_detail_close_button">OK</string>
|
|
||||||
<string name="dialog_event_detail_delete_button">Elimina</string>
|
|
||||||
|
|
||||||
<string name="dialog_add_logbook_title">Aggiungi diario</string>
|
<string name="dialog_add_logbook_title">Aggiungi diario</string>
|
||||||
<string name="dialog_add_logbook_logbookname">👶 Nome del diario</string>
|
<string name="dialog_add_logbook_logbookname">👶 Nome del diario</string>
|
||||||
<string name="dialog_add_logbook_message">Scrivi un nome per identificare questo diario. Comparirà in cima allo schermo, e se usi WebDAV sarà incluso anche nel nome del file di salvataggio.\nSe vuoi un\'icona, inserisci una emoji!</string>
|
<string name="dialog_add_logbook_message">Scrivi un nome per identificare questo diario. Comparirà in cima allo schermo, e se usi WebDAV sarà incluso anche nel nome del file di salvataggio.\nSe vuoi un\'icona, inserisci una emoji!</string>
|
||||||
|
|
||||||
<string name="dialog_add_logbook_message_intro">Benvenuto! Per usare quest\'app devi creare almeno un diario. Probabilmente vuoi chiamarlo col nome di tuo figlio.</string>
|
|
||||||
<string name="default_logbook_name">👶 Il mio primo diario</string>
|
<string name="default_logbook_name">👶 Il mio primo diario</string>
|
||||||
<string name="logbook_created">Creato nuovo diario: </string>
|
<string name="logbook_created">Creato nuovo diario: </string>
|
||||||
|
|
||||||
|
@ -14,7 +14,6 @@
|
|||||||
<string name="log_temperature_dialog_description">Insert the temperature</string>
|
<string name="log_temperature_dialog_description">Insert the temperature</string>
|
||||||
|
|
||||||
<string name="event_bottle_type" translatable="false">🍼</string>
|
<string name="event_bottle_type" translatable="false">🍼</string>
|
||||||
<string name="event_food_type" translatable="false">🥣</string>
|
|
||||||
<string name="event_scale_type" translatable="false">⚖️</string>
|
<string name="event_scale_type" translatable="false">⚖️</string>
|
||||||
<string name="event_breastfeeding_left_type" translatable="false">🤱 ←</string>
|
<string name="event_breastfeeding_left_type" translatable="false">🤱 ←</string>
|
||||||
<string name="event_breastfeeding_both_type" translatable="false">🤱 ↔</string>
|
<string name="event_breastfeeding_both_type" translatable="false">🤱 ↔</string>
|
||||||
@ -29,7 +28,6 @@
|
|||||||
<string name="event_unknown_type" translatable="false">\?</string>
|
<string name="event_unknown_type" translatable="false">\?</string>
|
||||||
|
|
||||||
<string name="event_bottle_desc">Baby bottle</string>
|
<string name="event_bottle_desc">Baby bottle</string>
|
||||||
<string name="event_food_desc">Food</string>
|
|
||||||
<string name="event_scale_desc">Weight</string>
|
<string name="event_scale_desc">Weight</string>
|
||||||
<string name="event_breastfeeding_left_desc">Breastfeeding (left)</string>
|
<string name="event_breastfeeding_left_desc">Breastfeeding (left)</string>
|
||||||
<string name="event_breastfeeding_both_desc">Breastfeeding</string>
|
<string name="event_breastfeeding_both_desc">Breastfeeding</string>
|
||||||
@ -43,7 +41,6 @@
|
|||||||
<string name="event_colic_desc">Gaseous colic</string>
|
<string name="event_colic_desc">Gaseous colic</string>
|
||||||
<string name="event_unknown_desc"></string>
|
<string name="event_unknown_desc"></string>
|
||||||
|
|
||||||
<string name="overflow_event_scale">⚖️ Weight</string>
|
|
||||||
<string name="overflow_event_medicine">💊 Medicine</string>
|
<string name="overflow_event_medicine">💊 Medicine</string>
|
||||||
<string name="overflow_event_enema">🪠 Enema</string>
|
<string name="overflow_event_enema">🪠 Enema</string>
|
||||||
<string name="overflow_event_note">📝 Note</string>
|
<string name="overflow_event_note">📝 Note</string>
|
||||||
@ -78,7 +75,6 @@
|
|||||||
<string name="settings_storage_dav_pass">Password</string>
|
<string name="settings_storage_dav_pass">Password</string>
|
||||||
<string name="settings_network_error">Unable to reach server: </string>
|
<string name="settings_network_error">Unable to reach server: </string>
|
||||||
<string name="settings_webdav_error_denied">Wrong WebDAV user or password</string>
|
<string name="settings_webdav_error_denied">Wrong WebDAV user or password</string>
|
||||||
<string name="settings_webdav_error_server_offline">WebDAV server is currently unavailable</string>
|
|
||||||
<string name="settings_webdav_error_generic">Error while trying to access WebDAV:</string>
|
<string name="settings_webdav_error_generic">Error while trying to access WebDAV:</string>
|
||||||
<string name="settings_webdav_creation_error_generic">Unable to save a file on the WebDAV server:</string>
|
<string name="settings_webdav_creation_error_generic">Unable to save a file on the WebDAV server:</string>
|
||||||
<string name="settings_webdav_creation_ok">Successfully connected with WebDAV server</string>
|
<string name="settings_webdav_creation_ok">Successfully connected with WebDAV server</string>
|
||||||
@ -107,9 +103,6 @@
|
|||||||
<string name="measurement_unit_temperature_base_metric" translatable="false">°C</string>
|
<string name="measurement_unit_temperature_base_metric" translatable="false">°C</string>
|
||||||
|
|
||||||
<string name="dialog_event_detail_title">Event detail</string>
|
<string name="dialog_event_detail_title">Event detail</string>
|
||||||
<string name="dialog_event_detail_datetime_icon" translatable="false">🕒 %s1</string>
|
|
||||||
<string name="dialog_event_detail_close_button">OK</string>
|
|
||||||
<string name="dialog_event_detail_delete_button">Delete</string>
|
|
||||||
|
|
||||||
<string name="dialog_add_logbook_title">Add logbook</string>
|
<string name="dialog_add_logbook_title">Add logbook</string>
|
||||||
<string name="dialog_add_logbook_logbookname">👶 Logbook name</string>
|
<string name="dialog_add_logbook_logbookname">👶 Logbook name</string>
|
||||||
|
@ -1,3 +0,0 @@
|
|||||||
Multiple children support
|
|
||||||
Fixed interface in devices with big font size
|
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user