Exemple #1
0
 public int SavePolicyHolder(PolicyHolder policyHolder)
 {
     using (var actions = new PolicyActions())
     {
         var policyHolderModel = PolicyHolderMapping.MapDtoToEntity(policyHolder);
         actions.SavePolicyHolder(policyHolderModel);
         policyHolder.Id = policyHolderModel.Id;
     }
     return(policyHolder.Id);
 }
Exemple #2
0
 public int SavePolicyHolder([FromBody]Data.DTOs.PolicyHolder policyHolder)
 {
     using (var actions = new PolicyActions(_connectionString))
     {
         var policyHolderModel = PolicyHolderMapping.MapDtoToEntity(policyHolder);
         actions.SavePolicyHolder(policyHolderModel);
         policyHolder.Id = policyHolderModel.Id;
     }
     return policyHolder.Id;
 }