public int PradelstosDienos() { int virsytuDienuSk = 0; DateTime grazinimoData = PaemimoData.AddDays(DienosGrazinti); if (!ArLaikuGrazino()) { virsytuDienuSk = (DateTime.Now - grazinimoData).Days; } return(virsytuDienuSk); }
public bool Validate() { var isValid = true; DateTime pridetaData = PaemimoData.AddDays(DienosGrazinti); if (pridetaData <= DateTime.Now.Date) { isValid = false; } return(isValid); }
public bool ArLaikuGrazino() { bool arLaiku = true; DateTime grazinimoData = PaemimoData.AddDays(DienosGrazinti); if (grazinimoData <= DateTime.Now) { arLaiku = false; } return(arLaiku); }