aboutsummaryrefslogtreecommitdiff
path: root/androidApp/src/main/java/mx/trackermap
diff options
context:
space:
mode:
authorIván Ávalos <avalos@disroot.org>2022-01-16 19:19:08 -0600
committerIván Ávalos <avalos@disroot.org>2022-01-16 19:19:08 -0600
commit33e051ae011471e3472a69d405f805319d25bd70 (patch)
tree16facd10f595d6a5c77a82322bc3fbbc8089c16e /androidApp/src/main/java/mx/trackermap
parenta822ae0996b13576be9dc7a9fc3b9c5acb0d90d3 (diff)
downloadetbsa-trackermap-mobile-33e051ae011471e3472a69d405f805319d25bd70.tar.gz
etbsa-trackermap-mobile-33e051ae011471e3472a69d405f805319d25bd70.tar.bz2
etbsa-trackermap-mobile-33e051ae011471e3472a69d405f805319d25bd70.zip
Hide device limit when <= 0, and show device unique ID on details view
Diffstat (limited to 'androidApp/src/main/java/mx/trackermap')
-rw-r--r--androidApp/src/main/java/mx/trackermap/TrackerMap/android/session/UserInformationActivity.kt6
1 files changed, 6 insertions, 0 deletions
diff --git a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/session/UserInformationActivity.kt b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/session/UserInformationActivity.kt
index 13deed0..a3c6fd6 100644
--- a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/session/UserInformationActivity.kt
+++ b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/session/UserInformationActivity.kt
@@ -64,6 +64,12 @@ class UserInformationActivity : AppCompatActivity() {
idInfo.text = "${user.id ?: "--"}"
deviceLimitInfo.text = "${user.deviceLimit ?: "--"}"
adminInfo.text = "${user.administrator}"
+ user.deviceLimit?.let {
+ if (it <= 0) {
+ adminInfoLabel.visibility = View.GONE
+ adminInfo.visibility = View.GONE
+ }
+ }
}
}
}