Closed Nikitaxub closed 2 years ago
You need to reload that section, or at least that first row so that the new settings has effect. For example:
override func rowsHaveBeenRemoved(_ rows: [BaseRow], at indexes: [IndexPath]) {
super.rowsHaveBeenRemoved(rows, at: indexes)
let bedtimesSection = form.sectionBy(tag: "testTag") as! MultivaluedSection
if bedtimesSection.count == 2 {
bedtimesSection.multivaluedOptions = [.Insert]
bedtimesSection.reload() // <---
}
}
It works. Thank's.
Hi Eureka Team! I want to limit the number of lines by one at minimum.
This is my code entirely. And it works. In the sense that the last row cannot be deleted 😉 But the image of the minus does not disappear, although touching/clicking does not cause the "delete" button.