提交代码
This commit is contained in:
@@ -68,6 +68,7 @@ namespace FineUIPro.Web.Personal
|
||||
{
|
||||
this.txtLeaveDate.Text = string.Format("{0:yyyy-MM-dd}", trip.LeaveDate);
|
||||
}
|
||||
txtArriveDate_TextChanged(null, null);
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -125,5 +126,17 @@ namespace FineUIPro.Web.Personal
|
||||
this.drpProject.Hidden = true;
|
||||
}
|
||||
}
|
||||
|
||||
protected void txtArriveDate_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(this.txtArriveDate.Text.Trim()) && !string.IsNullOrEmpty(this.txtLeaveDate.Text.Trim()))
|
||||
{
|
||||
this.lbDays.Text = ((Convert.ToDateTime(this.txtLeaveDate.Text.Trim()) - Convert.ToDateTime(this.txtArriveDate.Text.Trim())).Days + 1).ToString();
|
||||
}
|
||||
else
|
||||
{
|
||||
this.lbDays.Text = string.Empty;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user