Replies: 1 comment 6 replies
-
Hello @haIIux,
I'm not sure I understand the issue. Is it a compiler error, or an app that misbehave at runtime? I can't really tell. But maybe I can help anyway. Something is strange in your sample code: it is the use of a
There is one important word in the above paragraph: mutable. One can't build a binding out database values fetched by To make changes, you have to copy the immutable entry fetched from the database into a mutable storage (such as a When the Save button is pressed, and the modified entry is persisted on disk, |
Beta Was this translation helpful? Give feedback.
-
I want to preface my questions with an apology as one of my biggest hurdles with SwiftUI is the passing of data. I don't know why... it just is so this may be something in which is related to that however I am also extremely new to GRDB (less than 24hrs).
I have a list view as outlined below, I query in all of the journal entires then allow the user to select one, and from the
SelectedEntryView
they can toggle an edit state which simply changes the view fromText
view objects to aTextField
andTextEditor
object. The issue I'm running into is passing theentry
from theForEach
down to the children to appropriately save. Once again, I'm unsure if this is a SwiftUI understanding issue or something I'm doing wrong with GRDBQuery.Beta Was this translation helpful? Give feedback.
All reactions