public void AddCodeMap(CodeMap4AddDTO dto4Add) { var code = new CodeMap { Key = _codeMapRepository.GetKey(), CodeName = dto4Add.CodeName, Category = dto4Add.Category, ChineseName = dto4Add.ChineseName, Upper = dto4Add.CodeName.ToUpper(), Lower = dto4Add.CodeName.ToLower(), CreatedOn = DateTime.Now, Description = dto4Add.Description, Status = CodeStatus.Active }; _codeMapRepository.Add(code); }
public ObjectResult Post(CodeMap4AddDTO item) { _codeMapService.AddCodeMap(item); _context.Commit(); return(new ObjectResult("OK")); }