コード例 #1
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (this.Request.QueryString["command"] == "delete")
     {
         var accountPeriodRepository = new AccountPeriodRepository();
         var accountPeriodIdString = this.Request.QueryString["accountPeriodId"];
         int accountPeriodId;
         if (int.TryParse(accountPeriodIdString, out accountPeriodId))
         {
             accountPeriodRepository.RemoveAccountPeriod(accountPeriodId);
             Response.Redirect(Globals.NavigateURL(this.TabId));
         }
     }
 }