/// <summary> /// 初始化数据 /// </summary> /// <param name="ut"></param> private void OnStartData(DeviceDetectEntity ut) { //StandardDeviceID_Input.Text = StandardDeviceID_Disp.Text = ut.StandardDeviceID.ToString(); //WillTestDeviceID_Input.Text = WillTestDeviceID_Disp.Text = ut.WillTestDeviceID.ToString(); CertificateNum_Input.Text = CertificateNum_Disp.Text = ut.CertificateNum.ToString(); //CertificateType_Input.Text = CertificateType_Disp.Text = ut.CertificateType.ToString(); DetectLocation_Input.Text = DetectLocation_Disp.Text = ut.DetectLocation.ToString(); DetectResult_Input.Text = DetectResult_Disp.Text = ut.DetectResult.ToString(); EnvironmentNote_Input.Text = EnvironmentNote_Disp.Text = ut.EnvironmentNote.ToString(); string defStr = "/"; if (ut.Humidity != 0) defStr = ut.Humidity.ToString() + ut.HumidityUnit; Humidity_Input.Text = Humidity_Disp.Text = defStr; //HumidityUnit_Input.Text = HumidityUnit_Disp.Text = ut.HumidityUnit.ToString(); if (ut.Temperature != 0) defStr = ut.Temperature.ToString() + ut.TemperatureUnit; Temperature_Input.Text = Temperature_Disp.Text = defStr; //TemperatureUnit_Input.Text = TemperatureUnit_Disp.Text = ut.TemperatureUnit.ToString(); ValidDate_Input.Text = ValidDate_Disp.Text = ut.ValidDate.ToString(); DetectNote_Input.Text = DetectNote_Disp.Text = ut.DetectNote.ToString(); //ReportType_Input.Text = ReportType_Disp.Text = ut.ReportType.ToString(); //ReportPath_Input.Text = ReportPath_Disp.Text = ut.ReportPath.ToString(); DetectUserName_Input.Text = DetectUserName_Disp.Text = ut.DetectUserName.ToString(); //DetectUserID_Input.Text = DetectUserID_Disp.Text = ut.DetectUserID.ToString(); DetectDate_Input.Text = DetectDate_Disp.Text = ut.DetectDate.ToString(); Verifier_Input.Text = Verifier_Disp.Text = ut.Verifier.ToString(); //VerifierID_Input.Text = VerifierID_Disp.Text = ut.VerifierID.ToString(); VerifyFlag_Input.Text = VerifyFlag_Disp.Text = ToolMethods.GetVerifyStringByFlag(ut.VerifyFlag); VerifyTime_Input.Text = VerifyTime_Disp.Text = ut.VerifyTime.ToString(); Approver_Input.Text = Approver_Disp.Text = ut.Approver.ToString(); //ApproverID_Input.Text = ApproverID_Disp.Text = ut.ApproverID.ToString(); ApproveFlag_Input.Text = ApproveFlag_Disp.Text = ToolMethods.GetApproveStringByFlag(ut.ApproveFlag); ApproveTime_Input.Text = ApproveTime_Disp.Text = ut.ApproveTime.ToString(); SurfaceCheck_Input.Text = SurfaceCheck_Disp.Text = (ut.OutwardCheckFlag > 0 ? "合格" : "不合格"); DeviceEntity device = BusinessFacadeShanliTech_HLD_Business.DeviceDisp(ut.WillTestDeviceID); if ("DEVICE_CATE_P".Equals(device.DeviceCategoryCode)) { ZeroPointCheck_Input.Text = ZeroPointCheck_Disp.Text = ut.ZeroPointCheck.ToString(); WithstandCheck_Input.Text = WithstandCheck_Disp.Text = ut.WithstandCheck.ToString(); PointerSmoothCheck_Input.Text = PointerSmoothCheck_Disp.Text = ut.PointerSmoothCheck.ToString(); } else if ("DEVICE_CATE_AP".Equals(device.DeviceCategoryCode)) { ZeroCheck_TR.Visible = false; WithstandCheck_Input.Text = WithstandCheck_Disp.Text = ut.WithstandCheck.ToString(); PointerSmoothCheck_Input.Text = PointerSmoothCheck_Disp.Text = ut.PointerSmoothCheck.ToString(); } else if ("DEVICE_CATE_E".Equals(device.DeviceCategoryCode)) P_Properties.Visible = false; StandardDeviceName_Input.Text = StandardDeviceName_Disp.Text = ut.StandardDeviceName.ToString(); WillTestDeviceName_Input.Text = WillTestDeviceName_Disp.Text = ut.WillTestDeviceName.ToString(); ReportType_Disp.Text = ToolMethods.GetDictionaryNameByID(ut.ReportType.ToString()); //ReportType }
protected void Button2_Click(object sender, EventArgs e) { string Checkbox_Value = (string)Common.sink("Checkbox", MethodType.Post, 2000, 1, DataType.Str); string[] Checkbox_Value_Array = Checkbox_Value.Split(','); Int32 IDX = 0; for (int i = 0; i < Checkbox_Value_Array.Length; i++) { if (Int32.TryParse(Checkbox_Value_Array[i], out IDX)) { DeviceDetectEntity et = new DeviceDetectEntity(); et.DataTable_Action_ = DataTable_Action.Delete; et.ID = IDX; BusinessFacadeShanliTech_HLD_Business.DeviceDetectInsertUpdateDelete(et); } } EventMessage.MessageBox(1, "批量删除成功", string.Format("批量删除({0})成功!", Checkbox_Value), Icon_Type.OK, Common.GetHomeBaseUrl("default.aspx")); }