Beispiel #1
0
        public async Task <int> Delete(int id)
        {
            var deleteCollection = new PreSalescollection {
                Id = id
            };

            _context.PreSalescollection.Attach(deleteCollection);
            _context.PreSalescollection.Remove(deleteCollection);
            _context.SaveChanges();
            return(id);
        }
Beispiel #2
0
        public async Task <int> Delete(int id)
        {
            var deletePayment = new Payment {
                Id = id
            };

            _context.Payments.Attach(deletePayment);
            _context.Payments.Remove(deletePayment);
            _context.SaveChanges();
            return(id);
        }