Skip to content
Snippets Groups Projects

Edit screen

Merged Koller Felix requested to merge Edit-Screen into main
6 files
+ 148
8
Compare changes
  • Side-by-side
  • Inline
Files
6
@@ -5,7 +5,6 @@ import androidx.room.Delete
import androidx.room.Insert
import androidx.room.OnConflictStrategy
import androidx.room.Query
import androidx.room.Update
import kotlinx.coroutines.flow.Flow
@Dao
@@ -22,8 +21,8 @@ interface EntriesDao {
@Query("SELECT * FROM entries")
fun getAllEntries(): Flow<List<EntryEntity>>
@Update
suspend fun update(entry: EntryEntity)
@Query("UPDATE entries SET title = :title, text = :text WHERE id = :id")
suspend fun update(id: Int, title: String, text: String)
@Query("UPDATE entries SET imagePath = :imagePath WHERE id = :id")
suspend fun updatePicturePhoto(id: Int, imagePath: String)
Loading