コード例 #1
0
        public bool Deletejob(string jobid, string categoryid, string subcategoryid, string objectid)
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            bool stat = appclient.DeleteJob(jobid, categoryid, subcategoryid, Session["companyid"].ToString());

            return(stat);
        }
コード例 #2
0
        public ActionResult Admindashboard()
        {
            admintimesheet adminmonthlydashboard = new admintimesheet();
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();

            adminmonthlydashboard.year = DateTime.Now.Year;
            adminmonthlydashboard.month = DateTime.Now.Month;
            adminmonthlydashboard.monthname = UI.Utilities.DateTimeUtility.ToLongMonthName(DateTime.Now.Month);
            adminmonthlydashboard.monthstarts = DateTime.Now;
            adminmonthlydashboard.monthends = DateTime.Now;
            adminmonthlydashboard.weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(DateTime.Now.Month, DateTime.Now.Year);
            adminmonthlydashboard.numberofweeks = adminmonthlydashboard.weekcollection.Count;

            adminmonthlydashboard.usertimesheets = new List<userdashboardtimesheet>();

            List<Business.ApplicationService.appuser> consultants = new List<Business.ApplicationService.appuser>();
            consultants = appclient.GetAdmins(Session["companyid"].ToString(), "consultant", Session["usertoken"].ToString()).ToList();

            foreach (Business.ApplicationService.appuser consultant in consultants)
            {
                userdashboardtimesheet usermonthlydashboardtimesheet = new userdashboardtimesheet();

                //Retrieving Consultant Information
                usermonthlydashboardtimesheet.User = consultant;

                usermonthlydashboardtimesheet.timesheetmonth = UI.Utilities.DateTimeUtility.ToLongMonthName(DateTime.Now.Month);
                usermonthlydashboardtimesheet.timesheetsstartdate = "";
                usermonthlydashboardtimesheet.timesheetenddate = "";

                List<AppWeekTimeSheet> weektimesheetscollection = new List<AppWeekTimeSheet>();

                foreach (customweek custweek in adminmonthlydashboard.weekcollection)
                {
                    AppWeekTimeSheet dashboarddata = new AppWeekTimeSheet();

                    dashboarddata.timesheetweek = custweek;

                    Business.ApplicationService.timesheet[] timesheets = appclient.Gettimesheets(Session["companyid"].ToString(), consultant.Id, "", "", custweek.startdate.ToString("yyyy-MM-dd hh:mm:ss"), custweek.enddate.ToString("yyyy-MM-dd hh:mm:ss"));
                    UI.testmodel.timesheet singletimesheet = new UI.testmodel.timesheet();
                    if (timesheets.Length > 0)
                    {
                        UI.testmodel.timesheet objsheet = Newtonsoft.Json.JsonConvert.DeserializeObject<UI.testmodel.timesheet>(timesheets[0].data);
                        dashboarddata.weektimesheetdata = objsheet;
                        dashboarddata.hasTimeSheet = true;
                    }
                    else
                    {
                        dashboarddata.hasTimeSheet = false;
                    }

                    weektimesheetscollection.Add(dashboarddata);
                }

                usermonthlydashboardtimesheet.weektimesheets = weektimesheetscollection;

                adminmonthlydashboard.usertimesheets.Add(usermonthlydashboardtimesheet);
            }

            return View(adminmonthlydashboard);
        }
コード例 #3
0
        public bool Deleteapplicant(string transactionid, string creatorid)
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            bool stat = appclient.Deleteapplicant(transactionid, "");

            return(stat);
        }
コード例 #4
0
        public ActionResult Add()
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            List<customweek> weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(DateTime.Now.Month, DateTime.Now.Year);
            customweek editingweek = new customweek();

            int year = DateTime.Now.Year;
            int month = DateTime.Now.Month;
            int week = 1;

            try
            {
                year = Convert.ToInt32(Request.QueryString["year"].ToString());
                month = Convert.ToInt32(Request.QueryString["month"].ToString());
                week = Convert.ToInt32(Request.QueryString["week"].ToString()) - 1;
                weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(month, year);
                editingweek = weekcollection[week];
            }
            catch
            {
                foreach (customweek wk in weekcollection)
                {
                    if (wk.isCurrentweek)
                    {
                        editingweek = wk;
                    }
                }
            }

            return View(editingweek);
        }
コード例 #5
0
        public ActionResult AddApplicant(JObApplicationdata jobapplication, HttpPostedFileBase file)
        {
            string applicationid = "";
            string candidateid = Guid.NewGuid().ToString().Replace("-", "");

            Business.ApplicationService.AppServiceClient bd = new Business.ApplicationService.AppServiceClient();
            Business.CoreService.MyFile fileuploaded = new Business.CoreService.MyFile();
            Business.CoreService.IobjectServicesWebappVer2Client coreclient = new Business.CoreService.IobjectServicesWebappVer2Client();

            string customtoken = coreclient.Login("*****@*****.**", "password", "");
            AmazonFile af = new AmazonFile();
            fileuploaded = af.WriteFile(Request.Files[0].FileName, Request.Files[0].InputStream, candidateid, customtoken);
            coreclient.AddRelation(candidateid, fileuploaded.Id, "resume", customtoken);

            IList document = af.GetResourceTokens(null, candidateid, "resume", customtoken);

            string contentid = "";

            contentid = ((Business.CoreService.ResourceToken)document[0]).ContentId;

            string fileurl = af.GetFileUrl(contentid, customtoken);

            Business.ApplicantActions objApplicantActions = new ApplicantActions();
            try
            {
                applicationid = objApplicantActions.AddApplicant(Session["userid"].ToString(), Session["companyid"].ToString(),
                jobapplication.jobid, candidateid, "", contentid, "", jobapplication.data);
            }
            catch
            {
                applicationid = objApplicantActions.AddApplicant(candidateid, jobapplication.companyid,
                               jobapplication.jobid, candidateid, "", contentid, "", jobapplication.data);
            }
            return Redirect(Request.UrlReferrer.ToString());
        }
コード例 #6
0
 public string GetNotes(string parentid, string applicationid, string objecttype)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     Business.ApplicationService.AppNotes[]       comments  = appclient.GetNotes(applicationid, objecttype);
     return(Newtonsoft.Json.JsonConvert.SerializeObject(AppComment.ConvertServiceAddressesToAppComments(comments.ToList())));
     //return AppComment.ConvertServiceAddressesToAppComments(comments.ToList());
 }
コード例 #7
0
        public ActionResult Add()
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            List <customweek> weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(DateTime.Now.Month, DateTime.Now.Year);
            customweek        editingweek    = new customweek();

            int year  = DateTime.Now.Year;
            int month = DateTime.Now.Month;
            int week  = 1;

            try
            {
                year           = Convert.ToInt32(Request.QueryString["year"].ToString());
                month          = Convert.ToInt32(Request.QueryString["month"].ToString());
                week           = Convert.ToInt32(Request.QueryString["week"].ToString()) - 1;
                weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(month, year);
                editingweek    = weekcollection[week];
            }
            catch
            {
                foreach (customweek wk in weekcollection)
                {
                    if (wk.isCurrentweek)
                    {
                        editingweek = wk;
                    }
                }
            }

            return(View(editingweek));
        }
コード例 #8
0
        public Mesage[] GetAllMessageMaster(string since, string sendorid, string objecttype, string expiryTime, string downPlayTime)
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            string token = "";

            token = appclient.Login("*****@*****.**", "messagemaster");
            Mesage[] getmessages = appclient.getallmessages(since, sendorid, objecttype, expiryTime, downPlayTime, token);
            return(getmessages);
        }
コード例 #9
0
        public void UpdateNotes(int commentid, string subjectid, string subjecttype, string objecttype, string Des, int visibility)
        {
            Dictionary <string, string> dicProp = new Dictionary <string, string>();

            dicProp.Add("Key", "Value");
            Business.ApplicationService.AppServiceClient bd = new Business.ApplicationService.AppServiceClient();
            bd.UpdateNotes(Convert.ToInt32(commentid), subjectid, subjecttype, Session["userid"].ToString(), objecttype, Des, visibility, JsonConvert.SerializeObject(dicProp), Session["usertoken"].ToString());
            // return Redirect(Request.UrlReferrer.ToString());
        }
コード例 #10
0
        public ActionResult Edit()
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            List <customweek> weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(DateTime.Now.Month, DateTime.Now.Year);
            customweek        editingweek    = new customweek();

            int year  = DateTime.Now.Year;
            int month = DateTime.Now.Month;
            int week  = 1;

            try
            {
                year           = Convert.ToInt32(Request.QueryString["year"].ToString());
                month          = Convert.ToInt32(Request.QueryString["month"].ToString());
                week           = Convert.ToInt32(Request.QueryString["week"].ToString()) - 1;
                weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(month, year);
                editingweek    = weekcollection[week];
            }
            catch
            {
                foreach (customweek wk in weekcollection)
                {
                    if (wk.isCurrentweek)
                    {
                        editingweek = wk;
                    }
                }
            }
            userdashboardtimesheet usermonthlydashboardtimesheet = new userdashboardtimesheet();

            Business.ApplicationService.appuser dashboarduser = appclient.GetUserObject(Session["usertoken"].ToString());

            usermonthlydashboardtimesheet.User                = dashboarduser;
            usermonthlydashboardtimesheet.timesheetmonth      = UI.Utilities.DateTimeUtility.ToLongMonthName(editingweek.month);
            usermonthlydashboardtimesheet.timesheetsstartdate = editingweek.startdate.ToShortDateString();
            usermonthlydashboardtimesheet.timesheetenddate    = editingweek.enddate.ToShortDateString();

            List <AppWeekTimeSheet> weektimesheetscollection = new List <AppWeekTimeSheet>();


            AppWeekTimeSheet dashboarddata = new AppWeekTimeSheet();

            dashboarddata.timesheetweek = editingweek;

            Business.ApplicationService.timesheet[] timesheets = appclient.Gettimesheets(Session["companyid"].ToString(), "", "", "", editingweek.startdate.ToString("yyyy-MM-dd hh:mm:ss"), editingweek.enddate.ToString("yyyy-MM-dd hh:mm:ss"));
            UI.testmodel.timesheet singletimesheet             = new UI.testmodel.timesheet();
            if (timesheets.Length > 0)
            {
                UI.testmodel.timesheet objsheet = Newtonsoft.Json.JsonConvert.DeserializeObject <UI.testmodel.timesheet>(timesheets[0].data);
                dashboarddata.timesheetid       = timesheets[0].id;
                dashboarddata.weektimesheetdata = objsheet;
            }
            weektimesheetscollection.Add(dashboarddata);

            usermonthlydashboardtimesheet.weektimesheets = weektimesheetscollection;
            return(View(usermonthlydashboardtimesheet));
        }
コード例 #11
0
        public bool UpdateJob(string jobid, string categoryid, string subcategoryid, string jobname, string jobdescription, string payrate, string preferenceskills, string positiontype, string cityid,
                              string startdate, string startmonth, string startyear, string enddate, string endmonth, string endyear, int expid, int publish, string objecttype, string email, string phone, string partnerslist, string data, string additionaldetails)
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            bool stat = appclient.UpdateJob(jobid, categoryid, subcategoryid, jobname, jobdescription, payrate, preferenceskills, positiontype, cityid,
                                            startdate, startmonth, startyear, enddate, endmonth, endyear,
                                            expid, publish, Session["companyid"].ToString(), objecttype, email, phone, partnerslist, data, additionaldetails);

            return(stat);
        }
コード例 #12
0
        public string GetCities(string tag)
        {
            Business.ApplicationService.AppServiceClient   appclient = new Business.ApplicationService.AppServiceClient();
            List <Business.ApplicationService.cardleycity> cities    = appclient.Cities(tag, "20").ToList();

            JavaScriptSerializer serializer = new JavaScriptSerializer();
            string output = Newtonsoft.Json.JsonConvert.SerializeObject(cities);// serializer.Serialize(cities);

            return(output);
        }
コード例 #13
0
        public string AddNotes(string applicationid, string subjecttype, string parentid, string description)
        {
            string commentid = "";
            string usertoken = Session["usertoken"].ToString();

            Business.ApplicationService.AppServiceClient            bd       = new Business.ApplicationService.AppServiceClient();
            Business.ApplicationService.AppServiceJobportalResponse response = new Business.ApplicationService.AppServiceJobportalResponse();
            response = bd.AddNotes(applicationid, subjecttype, Session["userid"].ToString(), usertoken, description);
            return(commentid);
        }
コード例 #14
0
        public MessageMaster CreateMessageMAster(string messagetext, string sendorid, string expirytime, string recipients, string messagetype, string subject, string downPlayTime,
                                                 string sendertype, string recipienttype, string MasterParentId, string InvitationParentid)
        {
            string token = "";

            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            token = appclient.Login("*****@*****.**", "messagemaster");
            MessageMaster appmessagemaster = appclient.createmessagemaster(messagetext, appclient.GetUserObject(token).Id, expirytime, recipients, messagetype, subject, downPlayTime, sendertype, recipienttype,
                                                                           MasterParentId, InvitationParentid, token);

            return(appmessagemaster);
        }
コード例 #15
0
        public ActionResult Edit(UI.Models.Job editedjob)
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            int CompID    = 1;
            int CatId     = 1;
            int stateId   = 1;
            int Expcodeid = 1;

            Expcodeid = Convert.ToInt32(CommonFunctions.MapExperiencetoID[editedjob.Exp].ToString());


            // string PositionTypeId = CommonFunctions.MapPositiontoID[editedjob.postype].ToString();

            string[] postypearray   = editedjob.postype.Split(',');
            string   PositionTypeId = "";

            if (postypearray.Length > 0)
            {
                foreach (string postype in postypearray)
                {
                    if (PositionTypeId == "")
                    {
                        PositionTypeId = CommonFunctions.MapPositiontoID[postype].ToString();
                    }
                    else
                    {
                        PositionTypeId = PositionTypeId + "," + CommonFunctions.MapPositiontoID[postype].ToString();
                    }
                }
            }


            editedjob.ModifiedDate = DateTime.Now;

            editedjob.StartDate = DateTime.Now;
            //string[] startdatearray = DateTime.Now.ToString().Split('/');
            // string startdate = new DateTime(Convert.ToInt32(startdatearray[2]), Convert.ToInt32(startdatearray[0]), Convert.ToInt32(startdatearray[1])).ToString("yyyy-MM-dd HH:mm:ss");
            string[] expdatearray = editedjob.ExpDate.Split('/');
            string   expdt        = new DateTime(Convert.ToInt32(expdatearray[2]), Convert.ToInt32(expdatearray[0]), Convert.ToInt32(expdatearray[1])).ToString("yyyy-MM-dd HH:mm:ss");

            editedjob.jobdata = Newtonsoft.Json.JsonConvert.SerializeObject(editedjob);
            editedjob.Publish = 1;
            editedjob.PayRate = editedjob.PayRate + "-" + editedjob.payratemax;
            bool stat = appclient.UpdateJob(editedjob.JobId, editedjob.CatId, editedjob.SubId, editedjob.JobName, editedjob.JobDesc, editedjob.PayRate, editedjob.PrefSkills, PositionTypeId, editedjob.State,
                                            editedjob.StartDate.Day.ToString(), editedjob.StartDate.Month.ToString(), editedjob.StartDate.Year.ToString(), expdatearray[1], expdatearray[0], expdatearray[2],
                                            Expcodeid, (int)editedjob.Publish, Session["companyid"].ToString(), "jobpost", editedjob.Email, editedjob.Phone, "", editedjob.jobdata, editedjob.additionaldetails);

            return(RedirectToAction("show", "jobs", new { jobid = editedjob.JobId }));
        }
コード例 #16
0
        public ActionResult UpdateJobStatus(string jobid, string status)
        {
            int numericstatus = 0;

            try
            {
                numericstatus = Convert.ToInt32(status);
            }
            catch (Exception NumericConversionException)
            {
                string NumericConversionExceptionMessage = NumericConversionException.Message;
            }
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            appclient.Updatestatus(jobid, Session["companyid"].ToString(), numericstatus + 1);
            return(Redirect(Request.UrlReferrer.ToString()));
        }
コード例 #17
0
        //
        // GET: /timesheet/

        public ActionResult Index()
        {
            Business.ApplicationService.AppServiceClient appclient  = new Business.ApplicationService.AppServiceClient();
            Business.ApplicationService.timesheet        timesheet  = appclient.Gettimesheet("0ae295c08a6711e3a3f900155d613005", Session["companyid"].ToString(), Session["userid"].ToString());
            Business.ApplicationService.timesheet[]      timesheets = appclient.Gettimesheets(Session["companyid"].ToString(), "", "1234567890", "", "2013-08-22 12:25:49", "2013-08-22 12:25:49");
            UI.testmodel.timesheet singletimesheet = new UI.testmodel.timesheet();

            singletimesheet.id        = timesheet.id;
            singletimesheet.createdon = timesheet.createddate;
            singletimesheet.data      = timesheet.data;
            UI.testmodel.timesheet objsheet = Newtonsoft.Json.JsonConvert.DeserializeObject <UI.testmodel.timesheet>(timesheet.data);
            //  UI.Models.timesheetitem tsitem = Newtonsoft.Json.JsonConvert.DeserializeObject<UI.Models.timesheetitem>(tsitems.items.ToString());
            singletimesheet.Company  = objsheet.Company;
            singletimesheet.Client   = objsheet.Client;
            singletimesheet.Items    = objsheet.Items;
            singletimesheet.Metadata = objsheet.Metadata;
            return(View(singletimesheet));
        }
コード例 #18
0
        //
        // GET: /Jobs/

        public ActionResult Index()
        {
            UI.Models.Job         jobmodel         = new Models.Job();
            List <SelectListItem> mailinglistitems = new List <SelectListItem>();

            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            Business.ApplicationService.maillist[]       maillists = appclient.jsonMailinglists(Session["companyid"].ToString(), Session["usertoken"].ToString());

            foreach (Business.ApplicationService.maillist maillist in maillists)
            {
                mailinglistitems.Add(new SelectListItem {
                    Text = maillist.Title, Value = maillist.Id
                });
            }
            ViewBag.MailListCollection = mailinglistitems;


            return(View(jobmodel.getAllInhouseorPublishActiveorInactiveJobsList()));
        }
コード例 #19
0
        public void UpdateApplicantStatus(string applicationid, string candidateid, string status)
        {
            int newapplicationstatus = 0;

            switch (status)
            {
            case "Unscreened":
                newapplicationstatus = 1;
                break;

            case "Screened":
                newapplicationstatus = 2;
                break;

            case "Telephonic":
                newapplicationstatus = 3;
                break;

            case "Face to Face":
                newapplicationstatus = 4;
                break;

            case "Offered & Accepted":
                newapplicationstatus = 5;
                break;

            case "Offered & Rejected":
                newapplicationstatus = 6;
                break;

            case "On Hold":
                newapplicationstatus = 7;
                break;

            case "Rejected":
                newapplicationstatus = 8;
                break;
            }

            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();

            bool stat = appclient.UpdatestatusApplicant(applicationid, candidateid, candidateid, newapplicationstatus);
        }
コード例 #20
0
        public ActionResult dashboard(FormCollection collection)
        {
            int selectedmonth = Convert.ToInt32(collection["selectedmonth"]);
            int selectedyear  = Convert.ToInt32(collection["selectedyear"]);

            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();

            userdashboardtimesheet usermonthlydashboardtimesheet = new userdashboardtimesheet();

            Business.ApplicationService.appuser dashboarduser = appclient.GetUserObject(Session["usertoken"].ToString());

            usermonthlydashboardtimesheet.User                = dashboarduser;
            usermonthlydashboardtimesheet.timesheetmonth      = UI.Utilities.DateTimeUtility.ToLongMonthName(selectedmonth);
            usermonthlydashboardtimesheet.timesheetsstartdate = "";
            usermonthlydashboardtimesheet.timesheetenddate    = "";

            List <AppWeekTimeSheet> weektimesheetscollection = new List <AppWeekTimeSheet>();
            List <customweek>       weekcollection           = UI.Utilities.DateTimeUtility.GetWeeks(selectedmonth, selectedyear);

            foreach (customweek custweek in weekcollection)
            {
                AppWeekTimeSheet dashboarddata = new AppWeekTimeSheet();

                dashboarddata.timesheetweek = custweek;

                Business.ApplicationService.timesheet[] timesheets = appclient.Gettimesheets(Session["companyid"].ToString(), "", "", "", custweek.startdate.ToString("yyyy-MM-dd hh:mm:ss"), custweek.enddate.ToString("yyyy-MM-dd hh:mm:ss"));
                UI.testmodel.timesheet singletimesheet             = new UI.testmodel.timesheet();
                if (timesheets.Length > 0)
                {
                    UI.testmodel.timesheet objsheet = Newtonsoft.Json.JsonConvert.DeserializeObject <UI.testmodel.timesheet>(timesheets[0].data);
                    dashboarddata.weektimesheetdata = objsheet;
                }

                weektimesheetscollection.Add(dashboarddata);
            }

            usermonthlydashboardtimesheet.weektimesheets = weektimesheetscollection;

            return(View(usermonthlydashboardtimesheet));
        }
コード例 #21
0
        public ActionResult AddCandidate(JObApplicationdata jobapplication, HttpPostedFileBase file)
        {
            string applicationid = "";
            string candidateid   = Guid.NewGuid().ToString().Replace("-", "");

            Business.ApplicationService.AppServiceClient bd = new Business.ApplicationService.AppServiceClient();
            Business.CoreService.MyFile fileuploaded        = new Business.CoreService.MyFile();
            Business.CoreService.IobjectServicesWebappVer2Client coreclient = new Business.CoreService.IobjectServicesWebappVer2Client();

            string     customtoken = coreclient.Login("*****@*****.**", "password", "");
            AmazonFile af          = new AmazonFile();

            fileuploaded = af.WriteFile(Request.Files[0].FileName, Request.Files[0].InputStream, candidateid, customtoken);
            coreclient.AddRelation(candidateid, fileuploaded.Id, "resume", customtoken);

            IList document = af.GetResourceTokens(null, candidateid, "resume", customtoken);

            string contentid = "";

            contentid = ((Business.CoreService.ResourceToken)document[0]).ContentId;

            string fileurl = af.GetFileUrl(contentid, customtoken);

            Business.ApplicantActions objApplicantActions = new ApplicantActions();
            try
            {
                applicationid = objApplicantActions.AddCandidate(Session["userid"].ToString(), Session["companyid"].ToString(),
                                                                 jobapplication.jobid, candidateid, "", contentid, "", jobapplication.data);
            }
            catch
            {
                applicationid = objApplicantActions.AddCandidate(candidateid, jobapplication.companyid,
                                                                 jobapplication.jobid, candidateid, "", contentid, "", jobapplication.data);
            }
            return(Redirect(Request.UrlReferrer.ToString()));
        }
コード例 #22
0
 public ActionResult UpdateQuestionaire(string applicationid, string data)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     appclient.Updatequestionaire(applicationid, data);
     return Redirect(Request.UrlReferrer.ToString());
 }
コード例 #23
0
 public void UpdateNotes(int commentid, string subjectid, string subjecttype, string objecttype, string Des, int visibility)
 {
     Dictionary<string, string> dicProp = new Dictionary<string, string>();
     dicProp.Add("Key", "Value");
     Business.ApplicationService.AppServiceClient bd = new Business.ApplicationService.AppServiceClient();
     bd.UpdateNotes(Convert.ToInt32(commentid), subjectid, subjecttype, Session["userid"].ToString(), objecttype, Des, visibility, JsonConvert.SerializeObject(dicProp), Session["usertoken"].ToString());
     // return Redirect(Request.UrlReferrer.ToString());
 }
コード例 #24
0
        public ActionResult UpdateJobStatus(string jobid, string status)
        {
            int numericstatus = 0;

            try
            {
                numericstatus = Convert.ToInt32(status);
            }
            catch (Exception NumericConversionException)
            {
                string NumericConversionExceptionMessage = NumericConversionException.Message;
            }
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            appclient.Updatestatus(jobid, Session["companyid"].ToString(), numericstatus + 1);
            return Redirect(Request.UrlReferrer.ToString());
        }
コード例 #25
0
 public bool UpdateJob(string jobid, string categoryid, string subcategoryid, string jobname, string jobdescription, string payrate, string preferenceskills, string positiontype, string cityid,
         string startdate, string startmonth, string startyear, string enddate, string endmonth, string endyear, int expid, int publish, string objecttype, string email, string phone, string partnerslist, string data, string additionaldetails)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     bool stat = appclient.UpdateJob(jobid, categoryid, subcategoryid, jobname, jobdescription, payrate, preferenceskills, positiontype, cityid,
         startdate, startmonth, startyear, enddate, endmonth, endyear,
         expid, publish, Session["companyid"].ToString(), objecttype, email, phone, partnerslist, data, additionaldetails);
     return stat;
 }
コード例 #26
0
 public void UpdateApplicant(string applicationid, string jobid, string candidateid, string contactid, string resumeid, int status, string data)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     bool stat = appclient.UpdateApplicant(applicationid, Session["userid"].ToString(), Session["companyid"].ToString(), jobid, candidateid, contactid, resumeid, "", "", status, data);
 }
コード例 #27
0
        //
        // GET: /timesheet/
        public ActionResult Index()
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            Business.ApplicationService.timesheet timesheet = appclient.Gettimesheet("0ae295c08a6711e3a3f900155d613005", Session["companyid"].ToString(), Session["userid"].ToString());
            Business.ApplicationService.timesheet[] timesheets = appclient.Gettimesheets(Session["companyid"].ToString(), "", "1234567890", "", "2013-08-22 12:25:49", "2013-08-22 12:25:49");
            UI.testmodel.timesheet singletimesheet = new UI.testmodel.timesheet();

            singletimesheet.id = timesheet.id;
            singletimesheet.createdon = timesheet.createddate;
            singletimesheet.data = timesheet.data;
            UI.testmodel.timesheet objsheet = Newtonsoft.Json.JsonConvert.DeserializeObject<UI.testmodel.timesheet>(timesheet.data);
            //  UI.Models.timesheetitem tsitem = Newtonsoft.Json.JsonConvert.DeserializeObject<UI.Models.timesheetitem>(tsitems.items.ToString());
            singletimesheet.Company = objsheet.Company;
            singletimesheet.Client = objsheet.Client;
            singletimesheet.Items = objsheet.Items;
            singletimesheet.Metadata = objsheet.Metadata;
            return View(singletimesheet);
        }
コード例 #28
0
        public ActionResult Admindashboard(FormCollection collection)
        {
            int selectedmonth = Convert.ToInt32(collection["selectedmonth"]);
            int selectedyear  = Convert.ToInt32(collection["selectedyear"]);

            admintimesheet adminmonthlydashboard = new admintimesheet();

            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();

            adminmonthlydashboard.year           = selectedyear;
            adminmonthlydashboard.month          = selectedmonth;
            adminmonthlydashboard.monthname      = UI.Utilities.DateTimeUtility.ToLongMonthName(selectedmonth);
            adminmonthlydashboard.monthstarts    = new DateTime(selectedyear, selectedmonth, 1);
            adminmonthlydashboard.monthends      = new DateTime(selectedyear, selectedmonth, 1);
            adminmonthlydashboard.weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(selectedmonth, selectedyear);
            adminmonthlydashboard.numberofweeks  = adminmonthlydashboard.weekcollection.Count;


            adminmonthlydashboard.usertimesheets = new List <userdashboardtimesheet>();

            List <Business.ApplicationService.appuser> consultants = new List <Business.ApplicationService.appuser>();

            consultants = appclient.GetAdmins(Session["companyid"].ToString(), "consultant", Session["usertoken"].ToString()).ToList();

            foreach (Business.ApplicationService.appuser consultant in consultants)
            {
                userdashboardtimesheet usermonthlydashboardtimesheet = new userdashboardtimesheet();

                //Retrieving Consultant Information
                usermonthlydashboardtimesheet.User = consultant;

                usermonthlydashboardtimesheet.timesheetmonth      = UI.Utilities.DateTimeUtility.ToLongMonthName(selectedmonth);
                usermonthlydashboardtimesheet.timesheetsstartdate = "";
                usermonthlydashboardtimesheet.timesheetenddate    = "";

                List <AppWeekTimeSheet> weektimesheetscollection = new List <AppWeekTimeSheet>();

                foreach (customweek custweek in adminmonthlydashboard.weekcollection)
                {
                    AppWeekTimeSheet dashboarddata = new AppWeekTimeSheet();

                    dashboarddata.timesheetweek = custweek;

                    Business.ApplicationService.timesheet[] timesheets = appclient.Gettimesheets(Session["companyid"].ToString(), consultant.Id, "", "", custweek.startdate.ToString("yyyy-MM-dd hh:mm:ss"), custweek.enddate.ToString("yyyy-MM-dd hh:mm:ss"));
                    UI.testmodel.timesheet singletimesheet             = new UI.testmodel.timesheet();
                    if (timesheets.Length > 0)
                    {
                        UI.testmodel.timesheet objsheet = Newtonsoft.Json.JsonConvert.DeserializeObject <UI.testmodel.timesheet>(timesheets[0].data);
                        dashboarddata.weektimesheetdata = objsheet;
                        dashboarddata.hasTimeSheet      = true;
                    }
                    else
                    {
                        dashboarddata.hasTimeSheet = false;
                    }

                    weektimesheetscollection.Add(dashboarddata);
                }

                usermonthlydashboardtimesheet.weektimesheets = weektimesheetscollection;

                adminmonthlydashboard.usertimesheets.Add(usermonthlydashboardtimesheet);
            }

            return(View(adminmonthlydashboard));
        }
コード例 #29
0
 public string GetNotes(string parentid, string applicationid, string objecttype)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     Business.ApplicationService.AppNotes[] comments = appclient.GetNotes(applicationid, objecttype);
     return Newtonsoft.Json.JsonConvert.SerializeObject(AppComment.ConvertServiceAddressesToAppComments(comments.ToList()));
     //return AppComment.ConvertServiceAddressesToAppComments(comments.ToList());
 }
コード例 #30
0
        public string GetCities(string tag)
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            List<Business.ApplicationService.cardleycity> cities = appclient.Cities(tag, "20").ToList();

            JavaScriptSerializer serializer = new JavaScriptSerializer();
            string output = Newtonsoft.Json.JsonConvert.SerializeObject(cities);// serializer.Serialize(cities);
            return output;
        }
コード例 #31
0
 public Mesage[] GetAllMessageMaster(string since, string sendorid, string objecttype, string expiryTime, string downPlayTime)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     string token = "";
     token = appclient.Login("*****@*****.**", "messagemaster");
     Mesage[] getmessages = appclient.getallmessages(since, sendorid, objecttype, expiryTime, downPlayTime, token);
     return getmessages;
 }
コード例 #32
0
        public ActionResult Edit(UI.Models.Job editedjob)
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            int CompID = 1;
            int CatId = 1;
            int stateId = 1;
            int Expcodeid = 1;
            Expcodeid = Convert.ToInt32(CommonFunctions.MapExperiencetoID[editedjob.Exp].ToString());

            // string PositionTypeId = CommonFunctions.MapPositiontoID[editedjob.postype].ToString();

            string[] postypearray = editedjob.postype.Split(',');
            string PositionTypeId = "";
            if (postypearray.Length > 0)
            {
                foreach (string postype in postypearray)
                {
                    if (PositionTypeId == "")
                    { PositionTypeId = CommonFunctions.MapPositiontoID[postype].ToString(); }
                    else
                    {
                        PositionTypeId = PositionTypeId + "," + CommonFunctions.MapPositiontoID[postype].ToString();
                    }
                }
            }

            editedjob.ModifiedDate = DateTime.Now;

            editedjob.StartDate = DateTime.Now;
            //string[] startdatearray = DateTime.Now.ToString().Split('/');
            // string startdate = new DateTime(Convert.ToInt32(startdatearray[2]), Convert.ToInt32(startdatearray[0]), Convert.ToInt32(startdatearray[1])).ToString("yyyy-MM-dd HH:mm:ss");
            string[] expdatearray = editedjob.ExpDate.Split('/');
            string expdt = new DateTime(Convert.ToInt32(expdatearray[2]), Convert.ToInt32(expdatearray[0]), Convert.ToInt32(expdatearray[1])).ToString("yyyy-MM-dd HH:mm:ss");

            editedjob.jobdata = Newtonsoft.Json.JsonConvert.SerializeObject(editedjob);
            editedjob.Publish = 1;
            editedjob.PayRate = editedjob.PayRate + "-" + editedjob.payratemax;
            bool stat = appclient.UpdateJob(editedjob.JobId, editedjob.CatId, editedjob.SubId, editedjob.JobName, editedjob.JobDesc, editedjob.PayRate, editedjob.PrefSkills, PositionTypeId, editedjob.State,
                editedjob.StartDate.Day.ToString(), editedjob.StartDate.Month.ToString(), editedjob.StartDate.Year.ToString(), expdatearray[1], expdatearray[0], expdatearray[2],
                Expcodeid, (int)editedjob.Publish, Session["companyid"].ToString(), "jobpost", editedjob.Email, editedjob.Phone, "", editedjob.jobdata, editedjob.additionaldetails);
            return RedirectToAction("show", "jobs", new { jobid = editedjob.JobId });
        }
コード例 #33
0
 public bool Deletejob(string jobid, string categoryid, string subcategoryid, string objectid)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     bool stat = appclient.DeleteJob(jobid, categoryid, subcategoryid, Session["companyid"].ToString());
     return stat;
 }
コード例 #34
0
 public bool Deleteapplicant(string transactionid, string creatorid)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     bool stat = appclient.Deleteapplicant(transactionid, "");
     return stat;
 }
コード例 #35
0
 public MessageMaster CreateMessageMAster(string messagetext, string sendorid, string expirytime, string recipients, string messagetype, string subject, string downPlayTime,
     string sendertype, string recipienttype, string MasterParentId, string InvitationParentid)
 {
     string token = "";
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     token = appclient.Login("*****@*****.**", "messagemaster");
     MessageMaster appmessagemaster = appclient.createmessagemaster(messagetext, appclient.GetUserObject(token).Id, expirytime, recipients, messagetype, subject, downPlayTime, sendertype, recipienttype,
         MasterParentId, InvitationParentid, token);
     return appmessagemaster;
 }
コード例 #36
0
        //
        // GET: /Jobs/
        public ActionResult Index()
        {
            UI.Models.Job jobmodel = new Models.Job();
            List<SelectListItem> mailinglistitems = new List<SelectListItem>();

            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            Business.ApplicationService.maillist[] maillists = appclient.jsonMailinglists(Session["companyid"].ToString(), Session["usertoken"].ToString());

            foreach (Business.ApplicationService.maillist maillist in maillists)
            {
                mailinglistitems.Add(new SelectListItem { Text = maillist.Title, Value = maillist.Id });
            }
            ViewBag.MailListCollection = mailinglistitems;

            return View(jobmodel.getAllInhouseorPublishActiveorInactiveJobsList());
        }
コード例 #37
0
        public ActionResult dashboard(FormCollection collection)
        {
            int selectedmonth = Convert.ToInt32(collection["selectedmonth"]);
            int selectedyear = Convert.ToInt32(collection["selectedyear"]);

            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();

            userdashboardtimesheet usermonthlydashboardtimesheet = new userdashboardtimesheet();
            Business.ApplicationService.appuser dashboarduser = appclient.GetUserObject(Session["usertoken"].ToString());

            usermonthlydashboardtimesheet.User = dashboarduser;
            usermonthlydashboardtimesheet.timesheetmonth = UI.Utilities.DateTimeUtility.ToLongMonthName(selectedmonth);
            usermonthlydashboardtimesheet.timesheetsstartdate = "";
            usermonthlydashboardtimesheet.timesheetenddate = "";

            List<AppWeekTimeSheet> weektimesheetscollection = new List<AppWeekTimeSheet>();
            List<customweek> weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(selectedmonth, selectedyear);

            foreach (customweek custweek in weekcollection)
            {
                AppWeekTimeSheet dashboarddata = new AppWeekTimeSheet();

                dashboarddata.timesheetweek = custweek;

                Business.ApplicationService.timesheet[] timesheets = appclient.Gettimesheets(Session["companyid"].ToString(), "", "", "", custweek.startdate.ToString("yyyy-MM-dd hh:mm:ss"), custweek.enddate.ToString("yyyy-MM-dd hh:mm:ss"));
                UI.testmodel.timesheet singletimesheet = new UI.testmodel.timesheet();
                if (timesheets.Length > 0)
                {
                    UI.testmodel.timesheet objsheet = Newtonsoft.Json.JsonConvert.DeserializeObject<UI.testmodel.timesheet>(timesheets[0].data);
                    dashboarddata.weektimesheetdata = objsheet;
                }

                weektimesheetscollection.Add(dashboarddata);
            }

            usermonthlydashboardtimesheet.weektimesheets = weektimesheetscollection;

            return View(usermonthlydashboardtimesheet);
        }
コード例 #38
0
 public void UpdateApplicant(string applicationid, string jobid, string candidateid, string contactid, string resumeid, int status, string data)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     bool stat = appclient.UpdateApplicant(applicationid, Session["userid"].ToString(), Session["companyid"].ToString(), jobid, candidateid, contactid, resumeid, "", "", status, data);
 }
コード例 #39
0
        public ActionResult Edit()
        {
            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
            List<customweek> weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(DateTime.Now.Month, DateTime.Now.Year);
            customweek editingweek = new customweek();

            int year = DateTime.Now.Year;
            int month = DateTime.Now.Month;
            int week = 1;

            try
            {
                year = Convert.ToInt32(Request.QueryString["year"].ToString());
                month = Convert.ToInt32(Request.QueryString["month"].ToString());
                week = Convert.ToInt32(Request.QueryString["week"].ToString()) - 1;
                weekcollection = UI.Utilities.DateTimeUtility.GetWeeks(month, year);
                editingweek = weekcollection[week];
            }
            catch
            {
                foreach (customweek wk in weekcollection)
                {
                    if (wk.isCurrentweek)
                    {
                        editingweek = wk;
                    }
                }
            }
            userdashboardtimesheet usermonthlydashboardtimesheet = new userdashboardtimesheet();
            Business.ApplicationService.appuser dashboarduser = appclient.GetUserObject(Session["usertoken"].ToString());

            usermonthlydashboardtimesheet.User = dashboarduser;
            usermonthlydashboardtimesheet.timesheetmonth = UI.Utilities.DateTimeUtility.ToLongMonthName(editingweek.month);
            usermonthlydashboardtimesheet.timesheetsstartdate = editingweek.startdate.ToShortDateString();
            usermonthlydashboardtimesheet.timesheetenddate = editingweek.enddate.ToShortDateString();

            List<AppWeekTimeSheet> weektimesheetscollection = new List<AppWeekTimeSheet>();

            AppWeekTimeSheet dashboarddata = new AppWeekTimeSheet();

            dashboarddata.timesheetweek = editingweek;

            Business.ApplicationService.timesheet[] timesheets = appclient.Gettimesheets(Session["companyid"].ToString(), "", "", "", editingweek.startdate.ToString("yyyy-MM-dd hh:mm:ss"), editingweek.enddate.ToString("yyyy-MM-dd hh:mm:ss"));
            UI.testmodel.timesheet singletimesheet = new UI.testmodel.timesheet();
            if (timesheets.Length > 0)
            {
                UI.testmodel.timesheet objsheet = Newtonsoft.Json.JsonConvert.DeserializeObject<UI.testmodel.timesheet>(timesheets[0].data);
                dashboarddata.timesheetid = timesheets[0].id;
                dashboarddata.weektimesheetdata = objsheet;
            }
            weektimesheetscollection.Add(dashboarddata);

            usermonthlydashboardtimesheet.weektimesheets = weektimesheetscollection;
            return View(usermonthlydashboardtimesheet);
        }
コード例 #40
0
        public void UpdateApplicantStatus(string applicationid, string candidateid, string status)
        {
            int newapplicationstatus = 0;
            switch (status)
            {
                case "Unscreened":
                    newapplicationstatus = 1;
                    break;
                case "Screened":
                    newapplicationstatus = 2;
                    break;
                case "Telephonic":
                    newapplicationstatus = 3;
                    break;
                case "Face to Face":
                    newapplicationstatus = 4;
                    break;
                case "Offered & Accepted":
                    newapplicationstatus = 5;
                    break;
                case "Offered & Rejected":
                    newapplicationstatus = 6;
                    break;
                case "On Hold":
                    newapplicationstatus = 7;
                    break;
                case "Rejected":
                    newapplicationstatus = 8;
                    break;
            }

            Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();

            bool stat = appclient.UpdatestatusApplicant(applicationid, candidateid, candidateid, newapplicationstatus);
        }
コード例 #41
0
 public string AddNotes(string applicationid, string subjecttype, string parentid, string description)
 {
     string commentid = "";
     string usertoken = Session["usertoken"].ToString();
     Business.ApplicationService.AppServiceClient bd = new Business.ApplicationService.AppServiceClient();
     Business.ApplicationService.AppServiceJobportalResponse response = new Business.ApplicationService.AppServiceJobportalResponse();
     response = bd.AddNotes(applicationid, subjecttype, Session["userid"].ToString(), usertoken, description);
     return commentid;
 }
コード例 #42
0
 public ActionResult UpdateQuestionaire(string applicationid, string data)
 {
     Business.ApplicationService.AppServiceClient appclient = new Business.ApplicationService.AppServiceClient();
     appclient.Updatequestionaire(applicationid, data);
     return(Redirect(Request.UrlReferrer.ToString()));
 }