dialogue box is done
This commit is contained in:
@@ -61,9 +61,7 @@ class HemoCubeFragment : Fragment() {
|
|||||||
Toast.makeText(
|
Toast.makeText(
|
||||||
requireContext(), "Test Results Uploaded Successfully", Toast.LENGTH_SHORT
|
requireContext(), "Test Results Uploaded Successfully", Toast.LENGTH_SHORT
|
||||||
).show()
|
).show()
|
||||||
|
|
||||||
findNavController().navigate(R.id.action_hemocubeFragment_to_homeFragment)
|
findNavController().navigate(R.id.action_hemocubeFragment_to_homeFragment)
|
||||||
|
|
||||||
}
|
}
|
||||||
binding.progressBar.visibility = View.GONE
|
binding.progressBar.visibility = View.GONE
|
||||||
}
|
}
|
||||||
@@ -163,17 +161,35 @@ class HemoCubeFragment : Fragment() {
|
|||||||
binding.tvSubtitle4.text = stringData
|
binding.tvSubtitle4.text = stringData
|
||||||
}
|
}
|
||||||
|
|
||||||
if (stringData.contains("ERROR")) {
|
if (stringData.contains("ERROR 500")) {
|
||||||
UIUtils.createAlertDialog(requireContext(),
|
UIUtils.createAlertDialog(requireContext(),
|
||||||
"ERROR",
|
"BUFFER ERROR",
|
||||||
"Do you want to continue with existing buffer",
|
"Do you want to continue with existing buffer",
|
||||||
getString(R.string.no),
|
getString(R.string.noo),
|
||||||
"Yes",
|
"Yes",
|
||||||
object : MyDialogListener {
|
object : MyDialogListener {
|
||||||
override fun onClickNegativeButton() {
|
override fun onClickNegativeButton() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onClickPositiveButton() {
|
||||||
listenToHemoCube()
|
listenToHemoCube()
|
||||||
startBuffer()
|
startBuffer()
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
if (stringData.contains("ERROR 501")) {
|
||||||
|
UIUtils.createAlertDialog(requireContext(),
|
||||||
|
"SAMPLE ERROR",
|
||||||
|
"Do you want to continue with Sample",
|
||||||
|
getString(R.string.noo),
|
||||||
|
"Yes",
|
||||||
|
object : MyDialogListener {
|
||||||
|
override fun onClickNegativeButton() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
override fun onClickPositiveButton() {
|
override fun onClickPositiveButton() {
|
||||||
listenToHemoCube()
|
listenToHemoCube()
|
||||||
@@ -183,6 +199,7 @@ class HemoCubeFragment : Fragment() {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
resultData += fullReadOutput.toString()
|
resultData += fullReadOutput.toString()
|
||||||
DataHolder.hemoCubeTestData?.resultData
|
DataHolder.hemoCubeTestData?.resultData
|
||||||
if (stringData.contains("#Sample Completed")) {
|
if (stringData.contains("#Sample Completed")) {
|
||||||
|
|||||||
@@ -44,6 +44,8 @@
|
|||||||
<string name="please_place">Please place the cuvette containing sample for reference before running</string>
|
<string name="please_place">Please place the cuvette containing sample for reference before running</string>
|
||||||
<string name="yes">Yes</string>
|
<string name="yes">Yes</string>
|
||||||
<string name="no">No</string>
|
<string name="no">No</string>
|
||||||
|
<string name="noo"></string>
|
||||||
|
|
||||||
|
|
||||||
<string name="connect">Connect</string>
|
<string name="connect">Connect</string>
|
||||||
<string name="connected">Connected</string>
|
<string name="connected">Connected</string>
|
||||||
|
|||||||
Reference in New Issue
Block a user