加注释与细节调整

dhzzyy
luoxingjian 6 months ago
parent 6e87226f0a
commit 7486ceee55
  1. 39
      PEIS/View/Exam/CareerHisInqForm.cs
  2. 3
      PEIS/View/Exam/EmploymentHisForm.cs

@ -10,16 +10,20 @@ using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading;
using System.Windows.Forms;
namespace PEIS.View.Exam
{
/// <summary>
/// 职业史问诊
/// </summary>
public partial class CareerHisInqForm : ViewBase, ICareerHisInqView
{
private Int64 EID;
private Int64? ID;
/// <summary>
///
/// 职业史问诊
/// </summary>
/// <param name="pID">体检患者表id</param>
public CareerHisInqForm(Int64 eID)
@ -35,10 +39,13 @@ namespace PEIS.View.Exam
}
private void CareerHisInqForm_Shown(object sender, EventArgs e)
{
ThreadPool.QueueUserWorkItem(state =>
{
LoadPatients(EID);
LoadEmploymentHis(EID);
LoadExamCareerHisInq(EID);
});
}
private void ToolMenuItem_Add_Click(object sender, EventArgs e)
@ -85,18 +92,18 @@ namespace PEIS.View.Exam
{
if (patient!=null)
{
textBox1.Text = patient.ID.ToString();
textBox2.Text= patient.ID.ToString();
textBox3.Text = patient.Name;
textBox4.Text = patient.Sex == "1" ? "男" : "女";
textBox5.Text = patient.Age.ToString();
//textBox9.Text = patient.
//textBox7.Text = patient.HazardFactors;
//textBox8.Text= patient
//textBox9.Text= patient.JobTypes
//textBox10.Text =
//textBox11.Text = patient.WorkYears
//textBox12.Text =
Invoke(new Action(() => textBox1.Text = patient.ID.ToString()));
Invoke(new Action(() => textBox2.Text= patient.ID.ToString()));
Invoke(new Action(() => textBox3.Text = patient.Name));
Invoke(new Action(() => textBox4.Text = patient.Sex == "1" ? "男" : "女"));
Invoke(new Action(() => textBox5.Text = patient.Age.ToString()));
//Invoke(new Action(() =>textBox9.Text = patient)).
//Invoke(new Action(() =>textBox7.Text = patient.HazardFactors));
//Invoke(new Action(() =>textBox8.Text= patient))
//Invoke(new Action(() =>textBox9.Text= patient.JobTypes))
//Invoke(new Action(() =>textBox10.Text = ))
//Invoke(new Action(() =>textBox11.Text = patient.WorkYears))
//Invoke(new Action(() =>textBox12.Text = ))
}
}
@ -180,7 +187,7 @@ namespace PEIS.View.Exam
if (textbox != null)
{
var propert = properties.Where(p => p.Name == textbox.Name).FirstOrDefault();
if (propert!=null) textbox.Text = propert.GetValue(examCareerHis, null)?.ToString();
if (propert!=null) Invoke(new Action(()=>textbox.Text = propert.GetValue(examCareerHis, null)?.ToString()));
}
if (panel != null)
@ -196,8 +203,8 @@ namespace PEIS.View.Exam
{
var value = propert.GetValue(examCareerHis, null)?.ToString();
var radioName = pName + "_" + value;
if (radioButName == radioName) radioButton.Checked = true;
else radioButton.Checked = false;
if (radioButName == radioName) Invoke(new Action(() => radioButton.Checked = true));
else Invoke(new Action(() => radioButton.Checked = false));
}
}
}

@ -11,6 +11,9 @@ using System.Windows.Forms;
namespace PEIS.View.Exam
{
/// <summary>
/// 职业史
/// </summary>
public partial class EmploymentHisForm : Form
{
private Int64 PID;

Loading…
Cancel
Save