Example #1
0
        public async Task <string> UpdateGroupMaster(UpdateGroupMasterDomainModel model)
        {
            using (var _context = new YSCMEntities())
            {
                try
                {
                    var existingGroup = _context.AccessGroupMasters.Where(e => e.AccessGroupId == model.AccessGroupId).FirstOrDefault <AccessGroupMaster>();


                    if (existingGroup != null)
                    {
                        existingGroup.UpdatedBy   = "190455";
                        existingGroup.UpdatedDate = DateTime.Now;
                        existingGroup.GroupName   = model.GroupName;
                        await _context.SaveChangesAsync();
                    }
                    else
                    {
                        return("No Record Found");
                    }
                    return("Data Updated Successfully");
                }
                catch (Exception ex)
                { throw ex; }
            }
        }
Example #2
0
        public async Task <string> UpdateGroupMaster([FromBody] UpdateGroupMasterDomainModel groupMaster)
        {
            var result = await _iConfigAccessInterface.UpdateGroupMaster(groupMaster);

            return(result);
        }
Example #3
0
 public Task <string> UpdateGroupMaster(UpdateGroupMasterDomainModel model)
 {
     return(_iConfigAccessInterfaceDA.UpdateGroupMaster(model));
 }