public A_Sen_Mean nextSentence(A_Sen_Mean tblSenMean, int intCountry) { //lay thong tin SentenceId va MeanId tu man hinh var tblSenMeanSearch = db.A_Sen_Mean.Find(tblSenMean.SenMeanId); if (intCountry == 0) { //cap nhat lai ngay Mean MeanDao meanDao = new MeanDao(); meanDao.UpdateTime(meanDao.FindById(tblSenMeanSearch.MeanId.Value)); return(senMeanDao.getListSortByMeanUpdateTime().FirstOrDefault()); } else { //cap nhat lai ngay Sentence SentenceDao senDao = new SentenceDao(); senDao.UpdateTime(senDao.FindById(tblSenMeanSearch.SentenceId.Value)); return(senMeanDao.getListSortBySenUpdateTime().FirstOrDefault()); } }