Exemple #1
0
        public async ValueTask <ReadingNote> DeleteReadingNoteAsync(ReadingNote readingNote)
        {
            EntityEntry <ReadingNote> readingNoteEntityEntry = this.ReadingNotes.Remove(readingNote);

            await this.SaveChangesAsync();

            return(readingNoteEntityEntry.Entity);
        }
Exemple #2
0
        public async ValueTask <ReadingNote> InsertReadingNoteAsync(ReadingNote readingNote)
        {
            EntityEntry <ReadingNote> readingNoteEntityEntry = await this.ReadingNotes.AddAsync(readingNote);

            await this.SaveChangesAsync();

            return(readingNoteEntityEntry.Entity);
        }