⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 procnephrectomiesform.ascx.cs

📁 医疗决策支持系统
💻 CS
📖 第 1 页 / 共 2 页
字号:
			dr[Nephrectomy.PathPattern] = Request.Form[PathPattern.UniqueID].ToString();
			dr[Nephrectomy.PathCancerMaxDim] = PathCancerMaxDim.Value;
			dr[Nephrectomy.PathOtherKidney] = Request.Form[PathOtherKidney.UniqueID].ToString();
			dr[Nephrectomy.Pathologist] = Request.Form[Pathologist.UniqueID].ToString();
			dr[Nephrectomy.PathNotes] = PathNotes.Value;
			dr[Nephrectomy.PathDataSource] = Request.Form[PathDataSource.UniqueID].ToString();
			dr[Nephrectomy.PathQuality] = Request.Form[PathQuality.UniqueID].ToString();

			AddBaseParams(dr);
			biz.Tables[Nephrectomy.Table_ProcNephrectomies].Rows.Add(dr);
			biz.AcceptChanges();
			return biz;

		}

		protected override void SetFields(BizObject bz)
		{
			Nephrectomy biz = (Nephrectomy)bz;
			DataRow dr = biz.Tables[Nephrectomy.Table_ProcNephrectomies].Rows[0];

			//selects use: PageUtil.SelectDropDownItem(fieldIdName, dr[Object.FieldName]);
			
			SurgeryId.Value = dr[Nephrectomy.SurgeryId].ToString();
			ProcNephrectomyId.Value = dr[Nephrectomy.ProcNephrectomyId].ToString();
			//PageUtil.SelectDropDownItem(OpCPT_Code, dr[Nephrectomy.OpCPT_Code]);
			OpCPT_Code.Value = dr[Nephrectomy.OpCPT_Code].ToString();
			OpCPT_Description.Value = dr[Nephrectomy.OpCPT_Description].ToString();
			OpSurgeon.Value = dr[Nephrectomy.OpSurgeon].ToString();
			PageUtil.SelectDropDownItem(OpSurgeonType, dr[Nephrectomy.OpSurgeonType]);
			OpAssistant.Value = dr[Nephrectomy.OpAssistant].ToString();
			PageUtil.SelectDropDownItem(OpAssistantType, dr[Nephrectomy.OpAssistantType]);
			PageUtil.SelectDropDownItem(OpType, dr[Nephrectomy.OpType]);
			PageUtil.SelectDropDownItem(OpTypePlanned, dr[Nephrectomy.OpTypePlanned]);
			OpApproach.Value = dr[Nephrectomy.OpApproach].ToString();
			PageUtil.SelectDropDownItem(OpCaseQuality, dr[Nephrectomy.OpCaseQuality]);
			PageUtil.SelectDropDownItem(OpSide, dr[Nephrectomy.OpSide]);
			PageUtil.SelectDropDownItem(OpCompleteResectionByUS, dr[Nephrectomy.OpCompleteResectionByUS]);
			OpPartialReason.Value = dr[Nephrectomy.OpPartialReason].ToString();
			PageUtil.SelectDropDownItem(OpPartialIschemia, dr[Nephrectomy.OpPartialIschemia]);
			PageUtil.SelectDropDownItem(OpPartialIceSlush, dr[Nephrectomy.OpPartialIceSlush]);
			OpPartialClampStartTime.Value = dr[Nephrectomy.OpPartialClampStartTime].ToString();
			OpPartialClampStopTime.Value = dr[Nephrectomy.OpPartialClampStopTime].ToString();
			OpPartialClampTime.Value = dr[Nephrectomy.OpPartialClampTime].ToString();
			OpNotes.Value = dr[Nephrectomy.OpNotes].ToString();
			PathNum.Value = dr[Nephrectomy.PathNum].ToString();
			PageUtil.SelectDropDownItem(PathExtension, dr[Nephrectomy.PathExtension]);
			PathMarginStatus.Value = dr[Nephrectomy.PathMarginStatus].ToString();
			PageUtil.SelectDropDownItem(PathAdrenalInv, dr[Nephrectomy.PathAdrenalInv]);
			PageUtil.SelectDropDownItem(PathAdrenalSide, dr[Nephrectomy.PathAdrenalSide]);
			PageUtil.SelectDropDownItem(PathMultifocal, dr[Nephrectomy.PathMultifocal]);
			PageUtil.SelectDropDownItem(PathStageSystem, dr[Nephrectomy.PathStageSystem]);

			PageUtil.SelectDropDownItem(PathGrade, dr[Nephrectomy.PathGrade]);
			PageUtil.SelectDropDownItem(PathNuclearGrade, dr[Nephrectomy.PathNuclearGrade]);
			PathHistology.Value = dr[Nephrectomy.PathHistology].ToString();
			PathPattern.Value = dr[Nephrectomy.PathPattern].ToString();
			PathCancerMaxDim.Value = dr[Nephrectomy.PathCancerMaxDim].ToString();
			PageUtil.SelectDropDownItem(PathOtherKidney, dr[Nephrectomy.PathOtherKidney]);
			Pathologist.Value = dr[Nephrectomy.Pathologist].ToString();
			PathNotes.Value = dr[Nephrectomy.PathNotes].ToString();
			PathDataSource.Value = dr[Nephrectomy.PathDataSource].ToString();
			PageUtil.SelectDropDownItem(PathQuality, dr[Nephrectomy.PathQuality]);

			SetBaseFields(dr);

			SetStageSelects();
			PageUtil.SelectDropDownItem(PathStageSystem, dr[Nephrectomy.PathStageSystem]);	
			PageUtil.SelectDropDownItem(PathStageT, dr[Nephrectomy.PathStageT]);
			PageUtil.SelectDropDownItem(PathStageM, dr[Nephrectomy.PathStageM]);
		}
	
/*
		// enabling of staging fields is different
		override public void EnableFormFields()  
		{
			foreach(Control con in this.Controls)  
			{
				if (con is HtmlControl)  
				{
					if (con is HtmlInputControl || con is HtmlSelect || con is HtmlTextArea || con is HtmlInputText)  
					{
						if (!con.ID.Equals("PathStageT") || !con.ID.Equals("PathStageM"))
						{
							((HtmlControl)con).Disabled = false;
						}
					}
					else if (con is HtmlImage) // added by jf for the calendar buttons
					{
						((HtmlControl)con).Attributes.Add("class", "pdFormFieldButtonOn");
						((HtmlControl)con).Disabled = false;
					}
				}
				else if (con is DataGrid)  
				{
					((DataGrid)con).Enabled = true;
				}
				else if (con is LinkButton)  
				{
					((LinkButton)con).Enabled = true;
				}
				else if (con is Caisis.UI.ComboBox)
				{
					((Caisis.UI.ComboBox)con).Disabled = false;
				}


				SetStageSelects();
			}
		}
*/

		override protected void SetStageSelects()
		{
			string selectedPathStageSystem;
			string trimSelectedPathStageSystem;

			if (Request.Form[PathStageSystem.UniqueID] != null && Request.Form[PathStageSystem.UniqueID] != "")
			{
				selectedPathStageSystem = Request.Form[PathStageSystem.UniqueID];
			}
			else
			{
				selectedPathStageSystem = PathStageSystem.Value;
			}
			


			if (selectedPathStageSystem.StartsWith("UICC_").Equals(true))
			{
				trimSelectedPathStageSystem = selectedPathStageSystem.Remove(0, 4);
			}
			else
			{
				trimSelectedPathStageSystem = "_" + selectedPathStageSystem;
			}



			PageUtil.FillLkpDropDown(PathStageT, "KidneyPathStageT" + trimSelectedPathStageSystem, ViewState);
			PageUtil.FillLkpDropDown(PathStageM, "KidneyPathStageM" + trimSelectedPathStageSystem, ViewState);



			// logic to turn off TM stages if Stage System not selected not working currently. leave on for now.
/*			if (PathStageSystem.Disabled.Equals(false) && selectedPathStageSystem != null && selectedPathStageSystem.Length > 0)
			{				
				PathStageT.Disabled = false;
				PathStageM.Disabled = false;
			}
			else
			{
				PathStageT.Disabled = true;
				PathStageM.Disabled = true;
			}
*/

			if (PathStageSystem.Disabled.Equals(false))
			{				
				PathStageT.Disabled = false;
				PathStageM.Disabled = false;
			}
			else
			{
				PathStageT.Disabled = true;
				PathStageM.Disabled = true;
			}

			ActivateStagingInfo(trimSelectedPathStageSystem);

		}




		protected void FillStagingInfo(string fieldName, Repeater rptStages)
		{
			DataTable dt = PageUtil.RetrieveList(fieldName);


			if (dt.Rows.Count < 1)
			{
				DataRow blankRow = dt.NewRow();
				dt.Rows.Add(blankRow);
				dt.Rows[0]["LkpDescription"] = "You must select a staging system to view available options.";
			}
			else
			{
				rptStages.DataSource = dt.DefaultView;
				rptStages.DataBind();
			}
		}


		protected void ActivateStagingInfo(string StageSystemName)
		{
			if (PathStageSystem.Disabled.Equals(false))
			{

				if (PathStageT.Disabled.Equals(false))
				{

					FillStagingInfo("KidneyPathStageT" + StageSystemName, rptTStages);
					FillStagingInfo("KidneyPathStageM" + StageSystemName, rptMStages);
					TStagingInfoLink.Attributes.Add("style", "cursor: hand;");
					MStagingInfoLink.Attributes.Add("style", "cursor: hand;");
					TStagingInfoLink.Attributes.Add("onclick", "ShowSpecificStagingInfo('T');");
					MStagingInfoLink.Attributes.Add("onclick", "ShowSpecificStagingInfo('M');");

				}
				else
				{
					TStagingInfoLink.Attributes.Add("onclick", "RequestStagingSystem();");
					MStagingInfoLink.Attributes.Add("onclick", "RequestStagingSystem();");
				}

			}
		}






		protected void TStagingInfoDataBound(Object Sender, RepeaterItemEventArgs e) 
		{

			System.Web.UI.HtmlControls.HtmlAnchor tStageLink;
			tStageLink = (HtmlAnchor) e.Item.FindControl("tStageLink");


			if (e.Item.ItemType == ListItemType.Item || e.Item.ItemType == ListItemType.AlternatingItem) 
			{

				int linkIndex = e.Item.ItemIndex + 1;
				tStageLink.Attributes.Add("onclick", "MM_showHideLayers('TStagesDiv','','hide'); MM_showHideLayers('stagingInfoDiv','','hide'); setStageSelectValue('" + PathStageT.ClientID + "', " + linkIndex.ToString() + ");");
			}
		}


		protected void MStagingInfoDataBound(Object Sender, RepeaterItemEventArgs e) 
		{

			System.Web.UI.HtmlControls.HtmlAnchor mStageLink;
			mStageLink = (HtmlAnchor) e.Item.FindControl("mStageLink");


			if (e.Item.ItemType == ListItemType.Item || e.Item.ItemType == ListItemType.AlternatingItem) 
			{
				int linkIndex = e.Item.ItemIndex + 1;
				mStageLink.Attributes.Add("onclick", "MM_showHideLayers('MStagesDiv','','hide'); MM_showHideLayers('stagingInfoDiv','','hide'); setStageSelectValue('" + PathStageM.ClientID + "', " + linkIndex.ToString() + ");");
			}
		}







		// need to turn staging wizard off if cancel is uclicked
		override public void DisableFormFields()  
		{
			base.DisableFormFields();
			TStagingInfoLink.Attributes.Clear();
			MStagingInfoLink.Attributes.Clear();

		}


		override public void PopulateForm(BizObject bz)  
		{
			if (bz != null && bz.Tables[0].Rows.Count != 0)
			{
				base.PopulateForm(bz);
			}
			else
			{
				ResetFormFields();
			}

		}

		protected override void OnPreRender(EventArgs e)
		{
			base.OnPreRender (e);
			SurgeryId.Value = _saveSurgeryId;
		}










	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -