Exemple #1
0
        public void UpdateSalaryHead(Int64 headId, float amount)
        {
            EmployeeMonthlySalaryHeads emp = db.EmployeeMonthlySalaryHeads.Find(headId);

            if (emp != null)
            {
                emp.Amount          = amount;
                db.Entry(emp).State = EntityState.Modified;
                db.SaveChanges();
            }
        }
Exemple #2
0
        public bool IsdeleteLecture(string LectureId)
        {
            using (var db = new UserDBContext())
            {
                var lecture = db.LectureMaster.Find(LectureId);
                if (lecture != null)
                {
                    lecture.IsDelete        = true;
                    db.Entry(lecture).State = EntityState.Modified;
                    db.SaveChanges();
                    return(true);
                }
            }

            return(false);
        }