Specify the language of the codelab if it is not English:
In which task and step of the codelab can this issue be found?
12 through 13
Describe the problem
Step twelve sets "outOfStock" to quantity <= 0. Step thirteen asserts that the "Sell" Button is disabled when item quantity reaches 0, but button is not disabled because the Button function call has not been updated. Following change to ItemDetailsScreen.kt is needed to fully implement this change:
URL of codelab:
https://github.com/google-developer-training/basic-android-kotlin-compose-training-inventory-app/issues/new?assignees=&labels=&template=read-and-update-data-using-room-issue-template-.md&title=Read+and+update+data+using+Room
Specify the language of the codelab if it is not English:
In which task and step of the codelab can this issue be found?
12 through 13
Describe the problem
Step twelve sets "outOfStock" to quantity <= 0. Step thirteen asserts that the "Sell" Button is disabled when item quantity reaches 0, but button is not disabled because the Button function call has not been updated. Following change to ItemDetailsScreen.kt is needed to fully implement this change:
Button( onClick = onSellItem, modifier = Modifier.fillMaxWidth(), shape = MaterialTheme.shapes.small, enabled =
!itemDetailsUiState.outOfStock
Steps to reproduce?
Versions Android Studio version: API version of the emulator:
Additional information Include screenshots if they would be useful in clarifying the problem.