public bool SendCreateEmployeeRequest(InsertEmployeeProperties porperties)
        {
            var request = new InsertEmployeeRequest
            {
                InsertEmployeePorperties = porperties
            };

            var response = this.employeeService.InsertEmployee(request);
            if (response != null && response.Exception == null)
            {
                MessageBox.Show(string.Format("Response: {0}" + Environment.NewLine + "Employee Id: {1}" + Environment.NewLine + "Error Messages: {2}",
                    response.ResponceCode, response.EmployeeId, response.InvalidDataMessage));
                if (!string.IsNullOrWhiteSpace(response.EmployeeId))
                {
                    return true;
                }
            }
            return false;
        }
        public InsertEmployeeResponse InsertEmployee(InsertEmployeeRequest request)
        {
            Employee newEmployee = this.AssignAvailablePropertiesToDomain(request.InsertEmployeePorperties);
            var brokenRules = newEmployee.GetBrokenRules().ToList();

            InsertEmployeeResponse response = new InsertEmployeeResponse();

            if (brokenRules.Count == 0)
            {
                response.ResponceCode = "Success";
                response.InvalidDataMessage = string.Empty;

                try
                {
                    this.employeeRepository.Add(newEmployee);
                    this.employeeRepository.Save();
                    response.EmployeeId = newEmployee.PersistenceId.ToString();

                }
                // TODO Find more specific exception.
                catch (Exception ex)
                {
                    response.Exception = ex;
                    response.ResponceCode = "Database Error";
                }
            }
            else
            {
                response.ResponceCode = "Failure";

                var sb = new StringBuilder();
                foreach (var rule in brokenRules)
                {
                    sb.AppendLine(rule.RuleDescription);
                }

                response.InvalidDataMessage = sb.ToString();
            }
            return response;
        }