コード例 #1
0
        public async Task UpdateCoefficient(double coefficient, string userId)
        {
            var user = await GetUser(userId);

            user.Coefficient = coefficient;
            _db.Update(user);
            await _db.SaveChangesAsync();
        }
コード例 #2
0
        public async Task Add(Product product)
        {
            await _db.Products.AddAsync(product);

            await _db.SaveChangesAsync();
        }
コード例 #3
0
        public async Task Add(List <AdditionalImage> addtImages)
        {
            await _db.AdditionalImages.AddRangeAsync(addtImages);

            await _db.SaveChangesAsync();
        }