Archived
Canteen items are now individually clickable to signal that they are separate items; BUG: filtering does not work anymore
This commit is contained in:
@@ -38,7 +38,8 @@ class CanteenOfferItemAdapter(private val offers: List<CanteenOfferGroup>) : Rec
|
||||
LayoutInflater.from(holder.binding.root.context),
|
||||
)
|
||||
|
||||
line.content.text = offer.title
|
||||
line.textContent.text = offer.title
|
||||
line.textPrice.text = offer.price
|
||||
val indices = arrayListOf<Int>()
|
||||
offer.dietaryPreferences.filterIndexed { index, char ->
|
||||
if (char == 't') {
|
||||
|
||||
@@ -127,8 +127,6 @@ class CanteenFragment : Fragment() {
|
||||
|
||||
val prefsRegex = getPrefRegex()
|
||||
|
||||
|
||||
|
||||
val filteredForPreferences = if (prefsRegex.toString() == "ffffffffff") {
|
||||
// show all elements and skip filtering
|
||||
this
|
||||
@@ -139,13 +137,13 @@ class CanteenFragment : Fragment() {
|
||||
}
|
||||
}
|
||||
|
||||
val a = filteredForPreferences.map {
|
||||
CanteenOfferGroupElement(
|
||||
it.title,
|
||||
it.price,
|
||||
it.dietaryPreferences,
|
||||
)
|
||||
}
|
||||
// val a = filteredForPreferences.map {
|
||||
// CanteenOfferGroupElement(
|
||||
// it.title,
|
||||
// it.price,
|
||||
// it.dietaryPreferences,
|
||||
// )
|
||||
// }
|
||||
val b = filteredForPreferences.map { offer ->
|
||||
CanteenOfferGroup(
|
||||
offer.date,
|
||||
|
||||
Reference in New Issue
Block a user