Beispiel #1
0
        public IStatusGeneric AddProjectToperson(Guid projectId)
        {
            var status = new StatusGenericHandler();

            this.ProjectLink.Add(PersonProject.CreatepersonContractor(0, projectId).Result);
            return(status);
        }
Beispiel #2
0
        public static IStatusGeneric <Person> CreatePerson(string firstName, string lastName
                                                           , string nationalId, string mobileNumber, Guid[] projectIds)
        {
            var status = new StatusGenericHandler <Person>();
            var person = new Person
            {
                FirstName    = firstName,
                LastName     = lastName,
                NationalId   = nationalId,
                MobileNumber = mobileNumber
            };

            foreach (var ids in projectIds)
            {
                person.ProjectLink.Add(PersonProject.CreatepersonContractor(0, ids).Result);
            }

            status.Result = person;
            return(status);
        }