|
|
|
@ -1,4 +1,4 @@
|
|
|
|
package com.ejada.hmg.live_activity
|
|
|
|
package com.cloudsolutions.HMGPatientApp
|
|
|
|
|
|
|
|
|
|
|
|
import android.app.Activity
|
|
|
|
import android.app.Activity
|
|
|
|
import android.app.Notification
|
|
|
|
import android.app.Notification
|
|
|
|
@ -77,6 +77,16 @@ class CustomLiveActivityManager(context: Context) :
|
|
|
|
remoteViews.setTextViewText(R.id.status_text, data["nextTicketStatus"] as? String ?: "")
|
|
|
|
remoteViews.setTextViewText(R.id.status_text, data["nextTicketStatus"] as? String ?: "")
|
|
|
|
remoteViews.setTextViewText(R.id.queue_label, data["yourTicketHeader"] as? String ?: "")
|
|
|
|
remoteViews.setTextViewText(R.id.queue_label, data["yourTicketHeader"] as? String ?: "")
|
|
|
|
remoteViews.setTextViewText(R.id.serving_label, data["currentlyServingTitle"] as? String ?: "")
|
|
|
|
remoteViews.setTextViewText(R.id.serving_label, data["currentlyServingTitle"] as? String ?: "")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Hide serving_layout if currentlyServingToken is empty
|
|
|
|
|
|
|
|
val currentlyServingToken = data["currentlyServingToken"] as? String ?: ""
|
|
|
|
|
|
|
|
if (currentlyServingToken.isEmpty()) {
|
|
|
|
|
|
|
|
remoteViews.setViewVisibility(R.id.serving_layout, android.view.View.GONE)
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
remoteViews.setViewVisibility(R.id.serving_layout, android.view.View.VISIBLE)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private suspend fun updateCollapsedView(data: Map<String, Any>) {
|
|
|
|
private suspend fun updateCollapsedView(data: Map<String, Any>) {
|