Ejemplo n.º 1
0
        public int DeleteJobPortal(int key)
        {
            TblJobPortal tblJobPortal = dbContext.TblJobPortal.Where(x => x.PortalId == key).FirstOrDefault();

            tblJobPortal.IsActive = false;
            dbContext.TblJobPortal.Update(tblJobPortal);
            return(dbContext.SaveChanges());
        }
Ejemplo n.º 2
0
        public int UpdateJobPortal(TblJobPortal tblJobPortal)
        {
            if (dbContext.TblJobPortal.Where(r => r.PortalName.ToUpper() == tblJobPortal.PortalName.ToUpper() && r.PortalId != tblJobPortal.PortalId && r.IsActive == true).Count() > 0)
            {
                return(-1);
            }
            tblJobPortal.IsActive = true;
            dbContext.Entry(tblJobPortal).State = EntityState.Modified;
            dbContext.TblJobPortal.Update(tblJobPortal);
            int result = dbContext.SaveChanges();

            dbContext.Entry(tblJobPortal).State = EntityState.Detached;
            return(result);
        }
Ejemplo n.º 3
0
 public int UpdateJobPortal(TblJobPortal tblJobPortal)
 {
     return(MastersDAL.UpdateJobPortal(tblJobPortal));
 }
Ejemplo n.º 4
0
 public int CreateJobPortal(TblJobPortal tblJobPortal)
 {
     return(MastersDAL.CreateJobPortal(tblJobPortal));
 }
Ejemplo n.º 5
0
        public IActionResult JobPortal(int id, [FromBody] TblJobPortal tblJobPortal)
        {
            int result = _imasters.UpdateJobPortal(tblJobPortal);

            return(Ok(result));
        }
Ejemplo n.º 6
0
        public IActionResult JobPortal(int id)
        {
            TblJobPortal result = _imasters.GetJobPortalByCriteria(id);

            return(Ok(result));
        }