public ResponseDto <FamilyDto> RegisterFamily(FamilyDto family) { ResponseDto <FamilyDto> response = new ResponseDto <FamilyDto>(); FamilyModel familyModel = new FamilyModel(); if (familyModel.ExistFamily(family.FamilyName) == null) { response.Data = familyModel.RegisterFamily(family); response.header.Message = ResponseMessages.SuccessMessage.Message; response.header.Code = ResponseMessages.SuccessMessage.Code; } else { response.header.Message = ResponseMessages.RepeatedRegister.Message; response.header.Code = ResponseMessages.RepeatedRegister.Code; } return(response); }