Filter all profiles that are not operational
This commit is contained in:
parent
ac2d2415ab
commit
cc7f9a2957
|
@ -54,7 +54,7 @@ class OpenEuiccService : EuiccService() {
|
||||||
override fun onGetEuiccProfileInfoList(slotId: Int): GetEuiccProfileInfoListResult? {
|
override fun onGetEuiccProfileInfoList(slotId: Int): GetEuiccProfileInfoListResult? {
|
||||||
val channel = findChannel(slotId) ?: return null
|
val channel = findChannel(slotId) ?: return null
|
||||||
val profiles = channel.lpa.profiles.filter {
|
val profiles = channel.lpa.profiles.filter {
|
||||||
it.profileClass != LocalProfileInfo.Clazz.Testing
|
it.profileClass == LocalProfileInfo.Clazz.Operational
|
||||||
}.map {
|
}.map {
|
||||||
EuiccProfileInfo.Builder(it.iccidLittleEndian).apply {
|
EuiccProfileInfo.Builder(it.iccidLittleEndian).apply {
|
||||||
setProfileName(it.name)
|
setProfileName(it.name)
|
||||||
|
|
|
@ -81,7 +81,7 @@ class EuiccManagementFragment : Fragment(), EuiccFragmentMarker, EuiccProfilesCh
|
||||||
}
|
}
|
||||||
|
|
||||||
withContext(Dispatchers.Main) {
|
withContext(Dispatchers.Main) {
|
||||||
adapter.profiles = profiles.filter { it.profileClass != LocalProfileInfo.Clazz.Testing }
|
adapter.profiles = profiles.filter { it.profileClass == LocalProfileInfo.Clazz.Operational }
|
||||||
adapter.notifyDataSetChanged()
|
adapter.notifyDataSetChanged()
|
||||||
binding.swipeRefresh.isRefreshing = false
|
binding.swipeRefresh.isRefreshing = false
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue