Scan to open on your phone
Point a camera at the QR code - it opens this exact paste, no app needed.
https://codepastes.com/zzgs85yyp14kx7cduntitledPlain Text
DropdownMenu(
expanded = mostrarSelectorPresentacion,
onDismissRequest = {
mostrarSelectorPresentacion = false
},
modifier = Modifier.heightIn(max = 300.dp)
) {
Column(
modifier = Modifier
.heightIn(max = 300.dp)
.verticalScroll(rememberScrollState())
) {
presentaciones
.filter { presentacion ->
presentacion.activo &&
aromas.any { aroma ->
aroma.id == presentacion.aromaId &&
aroma.productoId == lote.productoId &&
aroma.activo
} &&
filasEdicionLote.none { fila ->
fila.presentacionId == presentacion.id
}
}
.forEach { presentacion ->
DropdownMenuItem(
text = {
val aromaNombre = aromas.firstOrNull {
it.id == presentacion.aromaId
}?.nombre ?: "Aroma desconocido"
Column {
Text(
text = aromaNombre,
color = LoteSoftBlue
)
Text(
text = presentacion.nombre
)
}
},
onClick = {
filasEdicionLote.add(
FilaEdicionLote(
presentacionId = presentacion.id,
cantidadFabricada = "0",
barrancas = "0",
valledupar = "0"
)
)
presentacionParaAgregar = presentacion.id
mostrarSelectorPresentacion = false
}
)
}
}
}3,410 chars · codepastes.com