Пример #1
0
        public List <CompanyJobPoco> GetAllCompanyJob()
        {
            EFGenericRepository <CompanyJobPoco> companyjobrepo = new EFGenericRepository <CompanyJobPoco>(false);
            CompanyJobLogic _companyjoblogic = new CompanyJobLogic(companyjobrepo);

            return(_companyjoblogic.GetAll());
        }
Пример #2
0
        public void RemoveCompanyJob(CompanyJobPoco[] items)
        {
            var logic = new CompanyJobLogic
                            (new EFGenericRepository <CompanyJobPoco>(false));

            logic.Delete(items);
        }
Пример #3
0
        public CompanyJobPoco GetSingleCompanyJob(string id)
        {
            EFGenericRepository <CompanyJobPoco> companyjobrepo = new EFGenericRepository <CompanyJobPoco>(false);
            CompanyJobLogic _companyjoblogic = new CompanyJobLogic(companyjobrepo);

            return(_companyjoblogic.Get(Guid.Parse(id)));
        }
Пример #4
0
        public void UpdateCompanyJob(CompanyJobPoco[] pocos)
        {
            EFGenericRepository <CompanyJobPoco> repo = new EFGenericRepository <CompanyJobPoco>(false);
            CompanyJobLogic logic = new CompanyJobLogic(repo);

            logic.Update(pocos);
        }
Пример #5
0
        public void AddCompanyJob(CompanyJobPoco[] item)
        {
            EFGenericRepository <CompanyJobPoco> companyjobrepo = new EFGenericRepository <CompanyJobPoco>(false);
            CompanyJobLogic _companyjoblogic = new CompanyJobLogic(companyjobrepo);

            _companyjoblogic.Add(item);
        }
Пример #6
0
        public void UpdateCompanyJob(CompanyJobPoco[] items)
        {
            EFGenericRepository <CompanyJobPoco> CompanyJobRepo = new EFGenericRepository <CompanyJobPoco>(false);
            var Logic = new CompanyJobLogic(CompanyJobRepo);

            Logic.Update(items);
        }
Пример #7
0
        public void UpdateCompanyJob(CompanyJobPoco[] items)
        {
            EFGenericRepository <CompanyJobPoco> companyjobrepo = new EFGenericRepository <CompanyJobPoco>(false);
            CompanyJobLogic _companyjoblogic = new CompanyJobLogic(companyjobrepo);

            _companyjoblogic.Update(items);
        }
Пример #8
0
        public ActionResult Create([Bind(Include = "Id,Company,JobName,JobDescription")] CompanyJobs companyJobs)
        {
            if (ModelState.IsValid)
            {
                var  companyJobsLogic = new CompanyJobLogic(new EFGenericRepository <CompanyJobPoco>());
                Guid jobId            = Guid.NewGuid();
                companyJobsLogic.Add(new CompanyJobPoco[] { new CompanyJobPoco
                                                            {
                                                                Id              = jobId,
                                                                Company         = (Guid)System.Web.HttpContext.Current.Session["companyJobsId"],
                                                                ProfileCreated  = DateTime.Now,
                                                                IsInactive      = false,
                                                                IsCompanyHidden = false
                                                            } });
                var  companyJobsDescriptionLogic = new CompanyJobDescriptionLogic(new EFGenericRepository <CompanyJobDescriptionPoco>());
                Guid jobsDescriptionId           = Guid.NewGuid();
                companyJobsDescriptionLogic.Add(new CompanyJobDescriptionPoco[] { new CompanyJobDescriptionPoco
                                                                                  {
                                                                                      Id              = jobsDescriptionId,
                                                                                      Job             = jobId,
                                                                                      JobName         = companyJobs.JobName,
                                                                                      JobDescriptions = companyJobs.JobDescription
                                                                                  } });
                return(RedirectToAction("Index"));
            }

            return(View(companyJobs));
        }
Пример #9
0
        public CompanyJobPoco GetSingleCompanyJob(string Id)
        {
            Guid id    = new Guid(Id);
            var  logic = new CompanyJobLogic(new EFGenericRepository <CompanyJobPoco>(false));

            return(logic.Get(id));
        }
Пример #10
0
        public void UpdateCompanyJob(CompanyJobPoco[] items)
        {
            var logic = new CompanyJobLogic
                            (new EFGenericRepository <CompanyJobPoco>());

            logic.Update(items);
        }
Пример #11
0
        public ActionResult Create([Bind(Include = "ProfileCreated,IsInactive,IsCompanyHidden")] CompanyJobPoco poco)
        {
            var companyId = Session["Company"];

            poco.Company = (Guid)companyId;
            CompanyJobPoco[] pocos = new CompanyJobPoco[] { poco };
            var request            = new RestRequest("api/careercloud/company/v1/job", Method.POST);

            request.AddJsonBody(pocos);
            request.RequestFormat = DataFormat.Json;
            var response = client.Execute(request);


            //Get Job
            //Get Back The Job just saved and add to session

            CompanyJobRepository repository = new CompanyJobRepository();
            CompanyJobLogic      logic      = new CompanyJobLogic(repository);
            var companyJob = logic.GetAll().Where(s => s.Company == poco.Company).FirstOrDefault();

            if (Session["Job"] == null)
            {
                Session["Job"] = companyJob.Id;
            }

            return(RedirectToAction("JobDescription"));
        }
Пример #12
0
        public void UpdateCompanyJob(CompanyJobPoco[] pocos)
        {
            ApplicantProfileRepository <CompanyJobPoco> repo = new ApplicantProfileRepository <CompanyJobPoco>(false);
            CompanyJobLogic log = new CompanyJobLogic(repo);

            log.Update(pocos);
        }
Пример #13
0
        public List <CompanyJobPoco> GetAllCompanyJob()
        {
            ApplicantProfileRepository <CompanyJobPoco> repo = new ApplicantProfileRepository <CompanyJobPoco>(false);
            CompanyJobLogic log = new CompanyJobLogic(repo);

            return(log.GetAll());
        }
Пример #14
0
        public CompanyJobPoco GetSingleCompanyJob(string Id)
        {
            EFGenericRepository <CompanyJobPoco> repo = new EFGenericRepository <CompanyJobPoco>(false);
            CompanyJobLogic logic = new CompanyJobLogic(repo);

            return(logic.Get(Guid.Parse(Id)));
        }
Пример #15
0
        public CompanyJobPoco GetSingleCompanyJob(string Id)
        {
            ApplicantProfileRepository <CompanyJobPoco> repo = new ApplicantProfileRepository <CompanyJobPoco>(false);
            CompanyJobLogic log = new CompanyJobLogic(repo);

            return(log.Get(Guid.Parse(Id)));
        }
Пример #16
0
        public List <CompanyJobPoco> GetAllCompanyJob()
        {
            var repo  = new EFGenericRepository <CompanyJobPoco>(false);
            var logic = new CompanyJobLogic(repo);

            return(logic.GetAll());
        }
Пример #17
0
        public void RemoveCompanyJob(CompanyJobPoco[] pocos)
        {
            var repo  = new EFGenericRepository <CompanyJobPoco>(false);
            var logic = new CompanyJobLogic(repo);

            logic.Delete(pocos);
        }
Пример #18
0
        public void AddCompanyJob(CompanyJobPoco[] pocos)
        {
            var repo  = new EFGenericRepository <CompanyJobPoco>(false);
            var logic = new CompanyJobLogic(repo);

            logic.Add(pocos);
        }
Пример #19
0
        public CompanyJobController()
        {
            EFGenericRepository <CompanyJobPoco> repo =
                new EFGenericRepository <CompanyJobPoco>(false);

            _logic = new CompanyJobLogic(repo);
        }
Пример #20
0
        public Company()
        {
            EFGenericRepository <CompanyDescriptionPoco> repo = new EFGenericRepository <CompanyDescriptionPoco>(false);

            _logic = new CompanyDescriptionLogic(repo);

            EFGenericRepository <CompanyJobDescriptionPoco> repo1 = new EFGenericRepository <CompanyJobDescriptionPoco>(false);

            _logicAJL = new CompanyJobDescriptionLogic(repo1);

            EFGenericRepository <CompanyJobEducationPoco> repo2 = new EFGenericRepository <CompanyJobEducationPoco>(false);

            _logicEducation = new CompanyJobEducationLogic(repo2);

            EFGenericRepository <CompanyJobPoco> repo3 = new EFGenericRepository <CompanyJobPoco>(false);

            _logicJob = new CompanyJobLogic(repo3);

            EFGenericRepository <CompanyJobSkillPoco> repo4 = new EFGenericRepository <CompanyJobSkillPoco>(false);

            _logicJobSkill = new CompanyJobSkillLogic(repo4);

            EFGenericRepository <CompanyLocationPoco> repo5 = new EFGenericRepository <CompanyLocationPoco>(false);

            _logicCompanyLocation = new CompanyLocationLogic(repo5);

            EFGenericRepository <CompanyProfilePoco> repo6 = new EFGenericRepository <CompanyProfilePoco>(false);

            _logicCompanyProfile = new CompanyProfileLogic(repo6);
        }
Пример #21
0
        public void AddCompanyJob(CompanyJobPoco[] items)
        {
            var logic = new CompanyJobLogic
                            (new EFGenericRepository <CompanyJobPoco>(false));

            logic.Add(items);
        }
Пример #22
0
        public CompanyJobPoco GetSingleCompanyJob(string Id)
        {
            var            logic          = new CompanyJobLogic(new EFGenericRepository <CompanyJobPoco>(false));
            CompanyJobPoco companyJobPoco = new CompanyJobPoco();

            companyJobPoco = logic.Get(Guid.Parse(Id));
            return(companyJobPoco);
        }
Пример #23
0
        public List <CompanyJobPoco> GetAllCompanyJob()
        {
            List <CompanyJobPoco> companyJobPoco = new List <CompanyJobPoco>();
            var logic = new CompanyJobLogic(new EFGenericRepository <CompanyJobPoco>(false));

            companyJobPoco = logic.GetAll();
            return(companyJobPoco);
        }
Пример #24
0
        public void PopulateJobSelectList(Guid?selected = null)
        {
            var logic = new CompanyJobLogic(new EFGenericRepository <CompanyJobPoco>());
            var Poco  = logic.GetAll(i => i.CompanyJobDescription, i => i.CompanyProfile.CompanyDescriptions);

            var compJobs = from d in Poco.Select(j => new { Job = j.Id, Name = j.CompanyJobDescription.JobName, comp = j.CompanyProfile.CompanyDescriptions }) select d;

            ViewData["Job"] = new SelectList(compJobs.Select(s => new { Id = s.Job, JobName = string.Concat(s.Name, " <--|--> ", s.comp.First().CompanyName) }), "Id", "JobName", selected);
        }
Пример #25
0
 public Company()
 {
     _CompanyDescriptionLogic    = new CompanyDescriptionLogic(new EFGenericRepository <CompanyDescriptionPoco>(false));
     _CompanyJobEducationLogic   = new CompanyJobEducationLogic(new EFGenericRepository <CompanyJobEducationPoco>(false));
     _CompanyJobLogic            = new CompanyJobLogic(new EFGenericRepository <CompanyJobPoco>(false));
     _CompanyJobSkillLogic       = new CompanyJobSkillLogic(new EFGenericRepository <CompanyJobSkillPoco>(false));
     _CompanyLocationLogic       = new CompanyLocationLogic(new EFGenericRepository <CompanyLocationPoco>(false));
     _CompanyProfileLogic        = new CompanyProfileLogic(new EFGenericRepository <CompanyProfilePoco>(false));
     _CompanyJobDescriptionLogic = new CompanyJobDescriptionLogic(new EFGenericRepository <CompanyJobDescriptionPoco>(false));
 }
        public CompanyJobController(CareerCloudContext context)
        {
            _context = context;
            var repo = new EFGenericRepository <CompanyJobPoco>();

            _logic = new CompanyJobLogic(repo);

            var repos = new EFGenericRepository <CompanyProfilePoco>();

            _plogic = new CompanyProfileLogic(repos);
        }
Пример #27
0
 public CompanyJobsController(IDataRepository <CompanyJobPoco> repo,
                              IDataRepository <CompanyJobDescriptionPoco> descRepo,
                              IDataRepository <CompanyJobSkillPoco> skillRepo,
                              IDataRepository <CompanyJobEducationPoco> eduRepo
                              )
 {
     _jobLogic   = new CompanyJobLogic(repo);
     _descLogic  = new CompanyJobDescriptionLogic(descRepo);
     _skillLogic = new CompanyJobSkillLogic(skillRepo);
     _eduLogic   = new CompanyJobEducationLogic(eduRepo);
 }
        public override Task <CompanyJobObj> GetCompanyJob(IdRequestCompanyJob request, ServerCallContext context)
        {
            var            _logic = new CompanyJobLogic(new EFGenericRepository <CompanyJobPoco>());
            CompanyJobPoco poco   = _logic.Get(Guid.Parse(request.Id));

            if (poco == null)
            {
                throw new ArgumentOutOfRangeException();
            }
            return(TranslateFromPoco(poco));
        }
        public override Task <Empty> CreateCompanyJob(CompanyJobObjs request, ServerCallContext context)
        {
            var _logic = new CompanyJobLogic(new EFGenericRepository <CompanyJobPoco>());
            List <CompanyJobPoco> pocos = new List <CompanyJobPoco>();

            foreach (var item in request.Obj)
            {
                pocos.Add(TranslateFromProto(item, new CompanyJobPoco()));
            }

            _logic.Add(pocos.ToArray());
            return(Task.FromResult(new Empty()));
        }
Пример #30
0
        public override Task <Empty> DeleteApplcantEducation(CompanyJobs request, ServerCallContext context)
        {
            var logic = new CompanyJobLogic(new EFGenericRepository <CompanyJobPoco>());

            List <CompanyJobPoco> pocos = new List <CompanyJobPoco>();

            foreach (CompanyJob proto in request.CompJob)
            {
                pocos.Add(TranslateFromProto(proto));
            }

            logic.Delete(pocos.ToArray());

            return(Task.FromResult(new Empty()));
        }