protected void btnAdd_ServerClick(object sender, EventArgs e) { ITCNDDefectCheckDef itcnd = new ITCNDDefectCheckDef(); itcnd.family = this.CmbMaintainFamilyForECRVersion.InnerDropDownList.SelectedValue.Trim(); // itcnd.type itcnd.type = this.CmbMaintainType.InnerDropDownList.SelectedValue.Trim(); itcnd.editor = this.HiddenUserName.Value.Trim(); itcnd.code = this.CmbMaintainITCNDDefectCheckWithCode.InnerDropDownList.SelectedValue.Trim(); System.DateTime cdt = DateTime.Now; itcnd.cdt = cdt; try { //调用添加的方法 相同的key时需要抛出异常... itcndDefectCheck.AddITCNDDefectCheck(itcnd); } catch(FisException fex) { showErrorMessage(fex.mErrmsg); return; } catch(System.Exception ex) { showErrorMessage(ex.Message); return; } //按照ac adaptor list加载表格中的数据 //... showList(); this.updatePanel2.Update(); // string assemblyId = replaceSpecialChart(adaptor.assemb); ScriptManager.RegisterStartupScript(this.updatePanel, typeof(System.Object), "saveUpdate", "resetTableHeight();AddUpdateComplete('" + itcnd.family + "');HideWait();", true); }
//protected void btnDisplaySelectedInfo_ServerClick(object sender, EventArgs e) //{ // string descrSeled = this.HiddenTypeDescr.Value.Trim(); // string partno = this.HiddenPartNo.Value.Trim(); // string station = this.HiddenStation.Value.Trim(); // string location = this.HiddenLocation.Value.Trim(); // if (partno != "") // { // this.ddlPartNo.refresh(descrSeled); // showListByGradeList(); // ScriptManager.RegisterStartupScript(this.Page, typeof(System.Object), "display", "displaySelectedItem('" + descrSeled + "','" + partno + "','" + station + "','" + location + "');HideWait();", true); // } //} protected void btnDelete_ServerClick(object sender, EventArgs e) { string selectedFamily = this.dOldId.Value.Trim(); try { ITCNDDefectCheckDef def = new ITCNDDefectCheckDef(); def.family = this.dOldId.Value.Trim(); def.code = this.dOldCode.Value.Trim(); //调用删除方法. itcndDefectCheck.RemoveITCNDDefectCheck(def); } catch(FisException fex) { showErrorMessage(fex.mErrmsg); return; } catch(System.Exception ex) { showErrorMessage(ex.Message); return; } //按照ac adaptor list加载表格中的数据. //... showList(); this.updatePanel2.Update(); ScriptManager.RegisterStartupScript(this.updatePanel, typeof(System.Object), "saveUpdate", "resetTableHeight();DeleteComplete();HideWait();", true); }