StableVersion4.3/HL_FristAidPlatform_Apoplexy/InputDialog_trans.cs

246 lines
9.5 KiB
C#

using HL_FristAidPlatform_DTO;
using System.Windows.Forms;
namespace HL_FristAidPlatform_Apoplexy
{
public static class InputDialog_trans
{
public static DialogResult Show(out string strText, out PatientNIHSSDTO dto1, int i)
{
string strTemp = string.Empty;
strText = "";
PatientNIHSSDTO dto;
dto1 = new PatientNIHSSDTO();
DialogResult result = new DialogResult();
if (i == 1)
{
}
else if (i == 2)
{
//Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(2);
//InputDialog_trans.TextHandler = (str) => { strTemp = str; };
//result = InputDialog_trans.ShowDialog();
//strText = strTemp;
//return result;
dto = new PatientNIHSSDTO();
Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(3);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
dto1 = dto;
}
else if (i == 3)
{
dto = new PatientNIHSSDTO();
Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(3);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
dto1 = dto;
}
else if (i == 4)
{
dto = new PatientNIHSSDTO();
Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(3);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
dto1 = dto;
}
else if (i == 5)
{
dto = new PatientNIHSSDTO();
Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(3);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
dto1 = dto;
}
else if (i == 6)
{
dto = new PatientNIHSSDTO();
Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(6);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
if (!string.IsNullOrEmpty(strTemp))
{
dto.TotalScore = int.Parse(strTemp);
}
dto1 = dto;
}
else if (i == 7)
{
dto = new PatientNIHSSDTO();
Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(7);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
if (!string.IsNullOrEmpty(strTemp))
{
dto.TotalScore = int.Parse(strTemp);
}
dto1 = dto;
}
else if (i == 8)
{
dto = new PatientNIHSSDTO();
Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(8);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
if (!string.IsNullOrEmpty(strTemp))
{
dto.TotalScore = int.Parse(strTemp);
}
dto1 = dto;
}
else if (i == 9)
{
dto = new PatientNIHSSDTO();
Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(9);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
if (!string.IsNullOrEmpty(strTemp))
{
dto.TotalScore = int.Parse(strTemp);
}
dto1 = dto;
}
else if (i == 10)
{
dto = new PatientNIHSSDTO();
Form_PatientNIHSS InputDialog_trans = new Form_PatientNIHSS(10);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
if (!string.IsNullOrEmpty(strTemp))
{
dto.TotalScore = int.Parse(strTemp);
}
dto1 = dto;
}
return result;
}
public static DialogResult ShowForCT(out string strText, int i,string patientGUID,int flag,int type,string name, string gendername, string age)
{
string strTemp = string.Empty;
strText = "";
DialogResult result = new DialogResult();
if (i == 6)
{
//Form_PatientCT
Form_PatientCT InputDialog_trans = new Form_PatientCT(patientGUID, flag, 1, name, gendername, age);
InputDialog_trans.TextHandler = (str) => { strTemp = str; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
}
return result;
}
public static DialogResult ShowForMRS(out string strText, out PatientMRSDTO dto1, int i)
{
string strTemp = string.Empty;
strText = "";
PatientMRSDTO dtomrs;
dto1 = new PatientMRSDTO();
DialogResult result = new DialogResult();
if (i == 1)
{
dtomrs = new PatientMRSDTO();
Form_PatientMRS InputDialog_trans = new Form_PatientMRS(1);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dtomrs = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
dto1 = dtomrs;
}
if (i == 2)
{
dtomrs = new PatientMRSDTO();
Form_PatientMRS InputDialog_trans = new Form_PatientMRS(2);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dtomrs = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
dto1 = dtomrs;
}
return result;
}
public static DialogResult ShowForGCS(out string strText, out PatientGCSDTO dto1, int i)
{
string strTemp = string.Empty;
strText = "";
PatientGCSDTO dtogcs;
dto1 = new PatientGCSDTO();
DialogResult result = new DialogResult();
if (i == 1)
{
dtogcs = new PatientGCSDTO();
Form_PatientGCS InputDialog_trans = new Form_PatientGCS(1);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dtogcs = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
dto1 = dtogcs;
}
if (i == 2)
{
dtogcs = new PatientGCSDTO();
Form_PatientGCS InputDialog_trans = new Form_PatientGCS(2);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dtogcs = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
dto1 = dtogcs;
}
return result;
}
public static DialogResult ShowForWaterSwallow(out string strText, out PatientWaterSwallowDTO dto1, string patientGUID, int type)
{
string strTemp = string.Empty;
strText = "";
PatientWaterSwallowDTO dtomrs;
dto1 = new PatientWaterSwallowDTO();
DialogResult result = new DialogResult();
dtomrs = new PatientWaterSwallowDTO();
Form_PatientWaterSwallow InputDialog_trans = new Form_PatientWaterSwallow(patientGUID, type);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dtomrs = ss; };
result = InputDialog_trans.ShowDialog();
dto1 = dtomrs;
strText = strTemp;
return result;
}
public static DialogResult ShowFast(out string strText, out T_Service_PatientFASTScoreDTO dto1, int i, string patientGUID)
{
string strTemp = string.Empty;
strText = "";
T_Service_PatientFASTScoreDTO dto;
dto1 = new T_Service_PatientFASTScoreDTO();
DialogResult result = new DialogResult();
if (i == 0)
{
dto = new T_Service_PatientFASTScoreDTO();
Form_FASTED InputDialog_trans = new Form_FASTED(patientGUID, 0);
InputDialog_trans.TextHandler = (str, ss) => { strTemp = str; dto = ss; };
result = InputDialog_trans.ShowDialog();
strText = strTemp;
if (!string.IsNullOrEmpty(strTemp))
{
dto.TotalScore = int.Parse(strTemp);
}
dto1 = dto;
}
return result;
}
}
}