protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { if (accountsFacade.userIsBindPasswordCard(Fetch.GetUserCookie( ).UserID)) { Panel1.Visible = false; return; } else { Panel2.Visible = false; } PasswordCard pc = new PasswordCard( ); pc.CreateSerialNumber( ); lbSerialNumber.Text = pc.AddSpace( ); lbA1.Text = pc.GetNumberByCoordinate("A1"); lbA2.Text = pc.GetNumberByCoordinate("A2"); lbA3.Text = pc.GetNumberByCoordinate("A3"); lbA4.Text = pc.GetNumberByCoordinate("A4"); lbB1.Text = pc.GetNumberByCoordinate("B1"); lbB2.Text = pc.GetNumberByCoordinate("B2"); lbB3.Text = pc.GetNumberByCoordinate("B3"); lbB4.Text = pc.GetNumberByCoordinate("B4"); lbC1.Text = pc.GetNumberByCoordinate("C1"); lbC2.Text = pc.GetNumberByCoordinate("C2"); lbC3.Text = pc.GetNumberByCoordinate("C3"); lbC4.Text = pc.GetNumberByCoordinate("C4"); lbD1.Text = pc.GetNumberByCoordinate("D1"); lbD2.Text = pc.GetNumberByCoordinate("D2"); lbD3.Text = pc.GetNumberByCoordinate("D3"); lbD4.Text = pc.GetNumberByCoordinate("D4"); lbE1.Text = pc.GetNumberByCoordinate("E1"); lbE2.Text = pc.GetNumberByCoordinate("E2"); lbE3.Text = pc.GetNumberByCoordinate("E3"); lbE4.Text = pc.GetNumberByCoordinate("E4"); lbF1.Text = pc.GetNumberByCoordinate("F1"); lbF2.Text = pc.GetNumberByCoordinate("F2"); lbF3.Text = pc.GetNumberByCoordinate("F3"); lbF4.Text = pc.GetNumberByCoordinate("F4"); string[] number = pc.RandomString( ); lbNumber1.Text = number[0]; lbNumber2.Text = number[1]; lbNumber3.Text = number[2]; } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { SwitchStep(1); if (FacadeManage.aideAccountsFacade.userIsBindPasswordCard(Fetch.GetUserCookie().UserID)) { RenderAlertInfo2(false, "您已经成功申请了密保卡!"); return; } PasswordCard pc = new PasswordCard(); pc.CreateSerialNumber(); lbSerialNumber.Text = pc.AddSpace(); lbA1.Text = pc.GetNumberByCoordinate("A1"); lbA2.Text = pc.GetNumberByCoordinate("A2"); lbA3.Text = pc.GetNumberByCoordinate("A3"); lbA4.Text = pc.GetNumberByCoordinate("A4"); lbB1.Text = pc.GetNumberByCoordinate("B1"); lbB2.Text = pc.GetNumberByCoordinate("B2"); lbB3.Text = pc.GetNumberByCoordinate("B3"); lbB4.Text = pc.GetNumberByCoordinate("B4"); lbC1.Text = pc.GetNumberByCoordinate("C1"); lbC2.Text = pc.GetNumberByCoordinate("C2"); lbC3.Text = pc.GetNumberByCoordinate("C3"); lbC4.Text = pc.GetNumberByCoordinate("C4"); lbD1.Text = pc.GetNumberByCoordinate("D1"); lbD2.Text = pc.GetNumberByCoordinate("D2"); lbD3.Text = pc.GetNumberByCoordinate("D3"); lbD4.Text = pc.GetNumberByCoordinate("D4"); lbE1.Text = pc.GetNumberByCoordinate("E1"); lbE2.Text = pc.GetNumberByCoordinate("E2"); lbE3.Text = pc.GetNumberByCoordinate("E3"); lbE4.Text = pc.GetNumberByCoordinate("E4"); lbF1.Text = pc.GetNumberByCoordinate("F1"); lbF2.Text = pc.GetNumberByCoordinate("F2"); lbF3.Text = pc.GetNumberByCoordinate("F3"); lbF4.Text = pc.GetNumberByCoordinate("F4"); string[] number = pc.RandomString(); lbNumber1.Text = number[0]; lbNumber2.Text = number[1]; lbNumber3.Text = number[2]; } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { SwitchStep(1); string serialNumber = FacadeManage.aideAccountsFacade.GetPasswordCardByUserID(Fetch.GetUserCookie().UserID); if (serialNumber == "0") { RenderAlertInfo2(true, "您还未申请密保卡!"); return; } PasswordCard pc = new PasswordCard(); pc.SerialNumber = Convert.ToInt32(serialNumber); lbSerialNumber.Text = pc.AddSpace(); string[] coordinate = pc.RandomString(); lbNumber1.Text = coordinate[0]; lbNumber2.Text = coordinate[1]; lbNumber3.Text = coordinate[2]; } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { string serialNumber = accountsFacade.GetPasswordCardByUserID(Fetch.GetUserCookie( ).UserID); if (serialNumber == "0") { Panel1.Visible = false; return; } else { Panel2.Visible = false; } PasswordCard pc = new PasswordCard( ); pc.SerialNumber = Convert.ToInt32(serialNumber); lbSerialNumber.Text = pc.AddSpace( ); string[] coordinate = pc.RandomString( ); lbNumber1.Text = coordinate[0]; lbNumber2.Text = coordinate[1]; lbNumber3.Text = coordinate[2]; } }