From 02ccc9723dfaf624fc24a7cefa0b862b9cbcc9b2 Mon Sep 17 00:00:00 2001 From: leomon Date: Wed, 24 May 2023 17:52:55 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=87=E4=B9=A6=E4=B8=8A=E4=BC=A0=E6=9C=8D?= =?UTF-8?q?=E5=8A=A1=E5=99=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- AIMS.sln | 18 - AIMS/AIMS.xml | 2 +- AIMS/DocManager/frmDocument3.cs | 3 +- AIMS/FormLogin.cs | 10 +- .../frmAanesthesiaPainlessRecord.cs | 3 +- .../frmAanesthesiaRecord.cs | 2 +- .../frmAanesthesiaRecover.cs | 5 +- .../frmInstrumentRecord.cs | 1 + .../frmInstrumentRecord2.cs | 1 + .../oldSystemCode/frmPrescriptionDocument.cs | 4 + AIMS/OremrUserControl/ControlExtension.cs | 41 +- AIMS/OremrUserControl/ucDocument.cs | 6 +- AIMSEntity/AIMSEntity.csproj | 4 + .../BLL/AutoGenerate/BPrintDocumentUP.cs | 160 +++++ .../BLL/Extension/BOperationTemplate.cs | 25 +- .../DAL/AutoGenerate/DPrintDocumentUP.cs | 651 ++++++++++++++++++ .../Model/AutoGenerate/PrintDocumentUP.cs | 131 ++++ AIMSEntity/ObjectQuery/PrintDocumentUPMap.cs | 46 ++ .../DataCollectorService.csproj | 55 -- DataCollectorService/Program.cs | 24 - .../Properties/AssemblyInfo.cs | 36 - DataCollectorService/Service1.Designer.cs | 37 - DataCollectorService/Service1.cs | 27 - .../DrawGraphManagement.csproj | 13 +- DrawGraphManagement/MainUp.Designer.cs | 51 +- DrawGraphManagement/MainUp.cs | 185 ++--- DrawGraphManagement/PdfiumViewer.dll | Bin 115712 -> 0 bytes DrawGraphManagement/frmPrintDocument.cs | 168 +++++ .../frmPrintDocument.designer.cs | 131 ++++ DrawGraphManagement/frmPrintDocument.resx | 126 ++++ 30 files changed, 1591 insertions(+), 375 deletions(-) create mode 100644 AIMSEntity/BLL/AutoGenerate/BPrintDocumentUP.cs create mode 100644 AIMSEntity/DAL/AutoGenerate/DPrintDocumentUP.cs create mode 100644 AIMSEntity/Model/AutoGenerate/PrintDocumentUP.cs create mode 100644 AIMSEntity/ObjectQuery/PrintDocumentUPMap.cs delete mode 100644 DataCollectorService/DataCollectorService.csproj delete mode 100644 DataCollectorService/Program.cs delete mode 100644 DataCollectorService/Properties/AssemblyInfo.cs delete mode 100644 DataCollectorService/Service1.Designer.cs delete mode 100644 DataCollectorService/Service1.cs delete mode 100644 DrawGraphManagement/PdfiumViewer.dll create mode 100644 DrawGraphManagement/frmPrintDocument.cs create mode 100644 DrawGraphManagement/frmPrintDocument.designer.cs create mode 100644 DrawGraphManagement/frmPrintDocument.resx diff --git a/AIMS.sln b/AIMS.sln index 82499a5..ffddf67 100644 --- a/AIMS.sln +++ b/AIMS.sln @@ -23,8 +23,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BeginScreen", "BeginScreen\ EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DocumentManagement", "DocumentManagement\DocumentManagement.csproj", "{80E69D05-8436-4342-B0B1-5ADAA8E83D41}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DataCollectorService", "DataCollectorService\DataCollectorService.csproj", "{A445F69B-9EA6-40F8-87EA-D524A40FB90B}" -EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -173,22 +171,6 @@ Global {80E69D05-8436-4342-B0B1-5ADAA8E83D41}.Release|x64.Build.0 = Release|Any CPU {80E69D05-8436-4342-B0B1-5ADAA8E83D41}.Release|x86.ActiveCfg = Release|Any CPU {80E69D05-8436-4342-B0B1-5ADAA8E83D41}.Release|x86.Build.0 = Release|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Debug|Any CPU.Build.0 = Debug|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Debug|x64.ActiveCfg = Debug|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Debug|x64.Build.0 = Debug|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Debug|x86.ActiveCfg = Debug|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Debug|x86.Build.0 = Debug|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Release|Any CPU.ActiveCfg = Release|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Release|Any CPU.Build.0 = Release|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Release|Mixed Platforms.Build.0 = Release|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Release|x64.ActiveCfg = Release|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Release|x64.Build.0 = Release|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Release|x86.ActiveCfg = Release|Any CPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B}.Release|x86.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/AIMS/AIMS.xml b/AIMS/AIMS.xml index 8facc04..8fe8536 100644 --- a/AIMS/AIMS.xml +++ b/AIMS/AIMS.xml @@ -1,6 +1,6 @@  - Data Source=.;Initial Catalog=AIMSDB_DLSJZQZYYY;User ID=sa;Password=Test2020; + Data Source=.;Initial Catalog=AIMSDB_FJZPTFYY;User ID=sa;Password=Test2020; Data Source=.;Initial Catalog=AIMSDB_DATA;User ID=sa;Password=Test2020; Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.10.7)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=orcl2))));Persist Security Info=True;User ID=smview;Password=i39; diff --git a/AIMS/DocManager/frmDocument3.cs b/AIMS/DocManager/frmDocument3.cs index 857a650..83ae383 100644 --- a/AIMS/DocManager/frmDocument3.cs +++ b/AIMS/DocManager/frmDocument3.cs @@ -429,7 +429,8 @@ namespace AIMS.OperationAfter.UI doc.Parent = c; doc.Dock = DockStyle.Fill; doc.Show(); - doc.myEditControl.ExecuteCommand("FilePrint", false, null); + doc.myEditControl.ExecuteCommand("FilePrint", false, null); + ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, doc.DModel.Id, 3, doc.DModel.TemplateId.ToString(), doc.DModel.XmlFileName); } } diff --git a/AIMS/FormLogin.cs b/AIMS/FormLogin.cs index 9dc6701..d58576e 100644 --- a/AIMS/FormLogin.cs +++ b/AIMS/FormLogin.cs @@ -50,11 +50,11 @@ namespace AIMS txtNo.Select(); txtNo.Focus(); } -#if DEBUG - txtNo.Text = "admin"; - txtPassWord.Text = "1"; - btnOk_Click(null, null); -#endif +//#if DEBUG +// txtNo.Text = "admin"; +// txtPassWord.Text = "1"; +// btnOk_Click(null, null); +//#endif } private void btnOk_Click(object sender, EventArgs e) { diff --git a/AIMS/OperationAanesthesia/frmAanesthesiaPainlessRecord.cs b/AIMS/OperationAanesthesia/frmAanesthesiaPainlessRecord.cs index 7eb4843..2e895dd 100644 --- a/AIMS/OperationAanesthesia/frmAanesthesiaPainlessRecord.cs +++ b/AIMS/OperationAanesthesia/frmAanesthesiaPainlessRecord.cs @@ -174,7 +174,8 @@ namespace AIMS.OperationAanesthesia pDoc.Print(); } - PublicMethod.WriteLog("打印麻醉记录单", _record.PatientId.Value, 1, "麻醉"); + ControlExtension.UPDocument(_record.PatientId.Value, _record.OperationApplyId.Value, _record.Id.Value, _record.RecoverId.Value, "60", "镇静镇痛评估记录"); + PublicMethod.WriteLog("打印镇静镇痛评估记录", _record.PatientId.Value, 1, "麻醉"); count = 0; } catch (Exception exp) diff --git a/AIMS/OperationAanesthesia/frmAanesthesiaRecord.cs b/AIMS/OperationAanesthesia/frmAanesthesiaRecord.cs index be8ba35..e03d939 100644 --- a/AIMS/OperationAanesthesia/frmAanesthesiaRecord.cs +++ b/AIMS/OperationAanesthesia/frmAanesthesiaRecord.cs @@ -175,7 +175,7 @@ namespace AIMS.OperationAanesthesia { pDoc.Print(); } - + ControlExtension.UPDocument(_record.PatientId.Value, _record.OperationApplyId.Value, _record.Id.Value, _record.RecoverId.Value, "40,50", "麻醉记录单"); PublicMethod.WriteLog("打印麻醉记录单", _record.PatientId.Value, 1, "麻醉"); count = 0; } diff --git a/AIMS/OperationAanesthesia/frmAanesthesiaRecover.cs b/AIMS/OperationAanesthesia/frmAanesthesiaRecover.cs index dde6f47..187f4be 100644 --- a/AIMS/OperationAanesthesia/frmAanesthesiaRecover.cs +++ b/AIMS/OperationAanesthesia/frmAanesthesiaRecover.cs @@ -238,7 +238,8 @@ namespace AIMS.OperationAanesthesia pDoc.Print(); } - PublicMethod.WriteLog("打印麻醉记录单", _record.PatientId.Value, 1, "恢复"); + ControlExtension.UPDocument(_record.PatientId.Value, _record.OperationApplyId.Value, _record.Id.Value, _record.RecoverId.Value, "10", "恢复记录单"); + PublicMethod.WriteLog("打印恢复记录单", _record.PatientId.Value, 1, "恢复"); count = 0; } catch (Exception exp) @@ -422,7 +423,7 @@ namespace AIMS.OperationAanesthesia { DrawGraph.FactEvents Inevent = null; DateTimeInput tb = obj as DateTimeInput; - if (_record.StateName == "麻醉复苏中") + if (_record.StateName == "麻醉复苏中" || tb.Name.Equals("txtBG")) { DeleteEventTime("txtAnaesthesiaEnd", "麻醉完成", tb, ref Inevent); DeleteEventTime("txtBG", cmbBGType.Text, tb, ref Inevent); diff --git a/AIMS/OperationAanesthesia/frmInstrumentRecord.cs b/AIMS/OperationAanesthesia/frmInstrumentRecord.cs index 47340f0..14699d3 100644 --- a/AIMS/OperationAanesthesia/frmInstrumentRecord.cs +++ b/AIMS/OperationAanesthesia/frmInstrumentRecord.cs @@ -2294,6 +2294,7 @@ namespace AIMS.OperationAanesthesia pDoc.Print(); } + ControlExtension.UPDocument(_record.PatientId.Value, _record.OperationApplyId.Value, _record.Id.Value, _record.RecoverId.Value, "20", "护理记录单"); plRefresh_Click(null, null); } catch (Exception exp) diff --git a/AIMS/OperationAanesthesia/frmInstrumentRecord2.cs b/AIMS/OperationAanesthesia/frmInstrumentRecord2.cs index 487bdc3..89f4916 100644 --- a/AIMS/OperationAanesthesia/frmInstrumentRecord2.cs +++ b/AIMS/OperationAanesthesia/frmInstrumentRecord2.cs @@ -1921,6 +1921,7 @@ namespace AIMS.OperationAanesthesia { myEditControl.ExecuteCommand("FilePrint", false, null); plRefresh_Click(null, null); + ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName); new frmMessageBox("打印完成!").Show(); } catch (Exception exp) diff --git a/AIMS/OperationAanesthesia/oldSystemCode/frmPrescriptionDocument.cs b/AIMS/OperationAanesthesia/oldSystemCode/frmPrescriptionDocument.cs index 482cdaa..1dbf4a5 100644 --- a/AIMS/OperationAanesthesia/oldSystemCode/frmPrescriptionDocument.cs +++ b/AIMS/OperationAanesthesia/oldSystemCode/frmPrescriptionDocument.cs @@ -184,18 +184,21 @@ namespace AIMS.OperationAanesthesia DModel = DocumentDAL.GetDocumentbyName("第二类精神药品处方笺", Patient.PatientId, item.Id.Value); LoadDocument(); myEditControl.ExecuteCommand("FilePrint", false, null); + ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName); } else if (item.FeeTypeId == "精神I类") { DModel = DocumentDAL.GetDocumentbyName("第一类精神药品处方笺", Patient.PatientId, item.Id.Value); LoadDocument(); myEditControl.ExecuteCommand("FilePrint", false, null); + ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName); } else if (item.FeeTypeId == "麻醉药") { DModel = DocumentDAL.GetDocumentbyName("麻醉药品处方笺", Patient.PatientId, item.Id.Value); LoadDocument(); myEditControl.ExecuteCommand("FilePrint", false, null); + ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName); } } } @@ -444,6 +447,7 @@ namespace AIMS.OperationAanesthesia { tsbSava_Click(null, null); myEditControl.ExecuteCommand("FilePrint", true, null); + ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName); } private void tsbExit_Click(object sender, EventArgs e) { diff --git a/AIMS/OremrUserControl/ControlExtension.cs b/AIMS/OremrUserControl/ControlExtension.cs index 3af0cf1..30db1c5 100644 --- a/AIMS/OremrUserControl/ControlExtension.cs +++ b/AIMS/OremrUserControl/ControlExtension.cs @@ -336,9 +336,9 @@ namespace AIMS } } public static List SiteRooms; - public static void GetOperationSiteRoom(Label labelSite, ComboBoxEx comboBoxEx, ComboBox cboRoom,string DefaultSite="") + public static void GetOperationSiteRoom(Label labelSite, ComboBoxEx comboBoxEx, ComboBox cboRoom, string DefaultSite = "") { - if (PublicMethod.OperationSite.Count <= 2) + if (PublicMethod.OperationSite.Count <= 2) { labelSite.Visible = false; comboBoxEx.Visible = false; @@ -352,7 +352,7 @@ namespace AIMS { comboBoxEx.Text = PublicMethod.LastOperationSite; } - if (DefaultSite!="") + if (DefaultSite != "") { comboBoxEx.Text = DefaultSite; } @@ -365,7 +365,7 @@ namespace AIMS else { SiteRooms = BOperationRoom.GetOperationRooms("IsValid=1 and Site='" + comboBoxEx.Text + "'"); - SiteRooms.Insert(0, new OperationRoom() { Id = -1, Name = "" }); + SiteRooms.Insert(0, new OperationRoom() { Id = -1, Name = "" }); } if (cboRoom != null) @@ -472,5 +472,38 @@ namespace AIMS } } } + + public static void UPDocument(int PatientId, int ApplyId, int RecoredId, int RecoverId, string DocumentId, string DocumentName) + { + try + { + PrintDocumentUP printDocumentUP = BPrintDocumentUP.SelectSingle("PatientId=@PatientId and DocumentId=@DocumentId", new ParameterList("@PatientId", PatientId, "@DocumentId", DocumentId)); + if (printDocumentUP == null) + { + printDocumentUP = new PrintDocumentUP(); + } + printDocumentUP.PatientId = PatientId; + printDocumentUP.ApplyId = ApplyId; + printDocumentUP.RecorId = RecoredId; + printDocumentUP.RecoverId = RecoverId; + printDocumentUP.DocumentId = DocumentId.ToString(); + printDocumentUP.DocumentName = DocumentName; + printDocumentUP.IsUpload = "0"; + printDocumentUP.OperatorId = PublicMethod.OperatorId; + printDocumentUP.OperatorTime = DateTime.Now; + if (printDocumentUP.Id != null && printDocumentUP.Id.Value > 0) + { + BPrintDocumentUP.Update(printDocumentUP); + } + else + { + BPrintDocumentUP.Insert(printDocumentUP); + } + } + catch (Exception ex) + { + PublicMethod.WriteLog(ex); + } + } } } diff --git a/AIMS/OremrUserControl/ucDocument.cs b/AIMS/OremrUserControl/ucDocument.cs index 5c72a6e..c13d361 100644 --- a/AIMS/OremrUserControl/ucDocument.cs +++ b/AIMS/OremrUserControl/ucDocument.cs @@ -21,7 +21,7 @@ namespace AIMS.OremrUserControl //模板Model private PrintTemplate TModel = new PrintTemplate(); //文档Model - private PrintDocument DModel = new PrintDocument(); + public PrintDocument DModel = new PrintDocument(); //患者Id public PatientRecord Patient = new PatientRecord(); //刷新文档目录 @@ -375,11 +375,15 @@ namespace AIMS.OremrUserControl if (tsbSaveAndPrint.Text == "打印") { myEditControl.ExecuteCommand("FilePrint", true, null); + + ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName); } else { tsbSave_Click(null, null); myEditControl.ExecuteCommand("FilePrint", true, null); + + ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName); } } diff --git a/AIMSEntity/AIMSEntity.csproj b/AIMSEntity/AIMSEntity.csproj index ac44133..0a60e65 100644 --- a/AIMSEntity/AIMSEntity.csproj +++ b/AIMSEntity/AIMSEntity.csproj @@ -55,6 +55,7 @@ + @@ -62,6 +63,7 @@ + @@ -346,6 +348,7 @@ + @@ -540,6 +543,7 @@ + diff --git a/AIMSEntity/BLL/AutoGenerate/BPrintDocumentUP.cs b/AIMSEntity/BLL/AutoGenerate/BPrintDocumentUP.cs new file mode 100644 index 0000000..f47950a --- /dev/null +++ b/AIMSEntity/BLL/AutoGenerate/BPrintDocumentUP.cs @@ -0,0 +1,160 @@ +using System; +using AIMSDAL; +using AIMSModel; +using System.Collections; +using System.Collections.Generic; + +namespace AIMSBLL +{ + public partial class BPrintDocumentUP + { + #region 插入实体操作部份 + /// + /// 插入实体 + /// + /// 实体类对象 + /// 标识列值或影响的记录行数 + public static int Insert(PrintDocumentUP printDocumentUP) + { + return DPrintDocumentUP.Insert(printDocumentUP); + } + #endregion + + #region 删除实体操作 + /// + /// 删除实体 + /// + /// 实体类对象 + /// 影响的记录行数 + public static int Delete(PrintDocumentUP printDocumentUP) + { + return DPrintDocumentUP.Delete(printDocumentUP); + } + /// + /// 根据对象查询语句删除 + /// + /// 对象查询语句 + /// 参数列表 + /// 影响的记录行数 + public static int Delete(string oql, ParameterList parameters) + { + return DPrintDocumentUP.Delete(oql,parameters); + } + #endregion + + #region 更新实体操作 + + /// + /// 更新实体 + /// + /// 实体类对象 + /// 影响的记录行数 + public static int Update(PrintDocumentUP printDocumentUP) + { + return DPrintDocumentUP.Update(printDocumentUP); + } + + /// + /// 根据对象查询语句更新实体 + /// + /// 对象查询语句 + /// 参数列表 + /// 影响的记录行数 + public static int Update(string oql, ParameterList parameters) + { + return DPrintDocumentUP.Update(oql,parameters); + } + #endregion + + #region 查询实体集合 + /// + /// \查询实体集合 + /// + /// 实体类对象集合 + public static List Select() + { + return DPrintDocumentUP.Select(); + } + /// + /// 递归查询实体集合 + /// + /// 递归类型 + /// 递归深度 + /// 实体类对象集合 + public static List Select(RecursiveType recursiveType, int recursiveDepth) + { + return DPrintDocumentUP.Select(recursiveType, recursiveDepth); + } + + /// + /// 根据对象查询语句查询实体集合 + /// + /// 对象查询语句 + /// 参数列表 + /// 实体类对象集合 + public static List Select(string oql, ParameterList parameters) + { + return DPrintDocumentUP.Select(oql, parameters); + } + + /// + /// 根据对象查询语句递归查询实体集合 + /// + /// 对象查询语句 + /// 参数列表 + /// 递归类型 + /// 递归深度 + /// 实体类对象集合 + public static List Select(string oql, ParameterList parameters,RecursiveType recursiveType, int recursiveDepth) + { + return DPrintDocumentUP.Select(oql, parameters, recursiveType, recursiveDepth); + } + #endregion + + #region 查询单个实体 + /// + /// 更据对象查询语句查询单个实体 + /// + /// 对象查询语句 + /// 参数列表 + /// 实体对象 + public static PrintDocumentUP SelectSingle(string oql, ParameterList parameters) + { + return DPrintDocumentUP.SelectSingle(oql, parameters); + } + /// + /// 更据对象查询语句递归查询单个实体 + /// + /// 对象查询语句 + /// 参数列表 + /// 递归类型 + /// 递归深度 + /// 实体对象 + public static PrintDocumentUP SelectSingle(string oql, ParameterList parameters, RecursiveType recursiveType, int recursiveDepth) + { + return DPrintDocumentUP.SelectSingle(oql, parameters, recursiveType, recursiveDepth); + } + + /// + /// 按主键字段查询特定实体 + /// + /// 主键值 + /// 实体类对象 + public static PrintDocumentUP SelectSingle(int? id) + { + return DPrintDocumentUP.SelectSingle(id); + } + + /// + /// 更据主键递归查询单个实体 + /// + /// 递归类型 + /// 递归深度 + /// 实体对象 + public static PrintDocumentUP SelectSingle(int? id, RecursiveType recursiveType, int recursiveDepth) + { + return DPrintDocumentUP.SelectSingle(id, recursiveType, recursiveDepth); + } + #endregion + } +} diff --git a/AIMSEntity/BLL/Extension/BOperationTemplate.cs b/AIMSEntity/BLL/Extension/BOperationTemplate.cs index fcc439a..278ee44 100644 --- a/AIMSEntity/BLL/Extension/BOperationTemplate.cs +++ b/AIMSEntity/BLL/Extension/BOperationTemplate.cs @@ -252,12 +252,33 @@ namespace AIMSBLL TimeSpan BeginTimets = DateTime.Parse(dr["BeginTime"].ToString()).Subtract(drugMinTime); PhysioData PhysioDataObj = new PhysioData(); PhysioDataObj.PatientId = _record.Id.Value; - PhysioDataObj.RecordTime = InRoomTime.AddSeconds(BeginTimets.TotalSeconds); + PhysioDataObj.RecordTime = GetRecordTime(_record, InRoomTime.AddSeconds(BeginTimets.TotalSeconds)); PhysioDataObj.PhysioDataConfigId = PhysioParamId; PhysioDataObj.ValueString = dr["Value"].ToString(); - PhysioDataObjs.Add(PhysioDataObj); + if (PhysioDataObj.RecordTime >= InRoomTime) + PhysioDataObjs.Add(PhysioDataObj); } PhysioDataService.AddPhysioDatas2(PhysioDataObjs); } + + public static DateTime GetRecordTime(OperationRecord myOpeRecord, DateTime pdTemp, int collectInterval = 5) + { + DateTime result = Convert.ToDateTime(pdTemp.ToString("yyyy-MM-dd HH:mm:00.000")); + //小于入室时间默认不画 + for (int i = 0; i < (480 / 5); i++) + {//InRoomTime.Value + DateTime tempTime = myOpeRecord.PageBegin.AddMinutes(i * 5); + if (tempTime >= result && result < tempTime.AddMinutes(5)) + { + result = tempTime; + break; + } + } + //if (result < myOpeRecord.InRoomTime.Value) + //{ + // result = myOpeRecord.InRoomTime.Value; + //} + return result; + } } } diff --git a/AIMSEntity/DAL/AutoGenerate/DPrintDocumentUP.cs b/AIMSEntity/DAL/AutoGenerate/DPrintDocumentUP.cs new file mode 100644 index 0000000..caf6b91 --- /dev/null +++ b/AIMSEntity/DAL/AutoGenerate/DPrintDocumentUP.cs @@ -0,0 +1,651 @@ +using System; +using System.Data; +using System.Data.SqlClient; +using System.Collections; +using AIMSModel; +using AIMSObjectQuery; +using System.Collections.Generic; + +namespace AIMSDAL +{ + internal partial class DPrintDocumentUP + { + #region 插入实体操作部份 + /// + /// 插入 + /// + /// Command对象 + /// 实体类对象 + /// 标识列值或影响的记录行数 + internal static int Insert(SqlCommand cmd, PrintDocumentUP printDocumentUP) + { + cmd.Parameters.Clear(); + cmd.CommandText = "insert into PrintDocumentUP (PatientId,ApplyId,RecorId,RecoverId,DocumentId,DocumentName,IsUpload,OperatorId,OperatorTime,Remark,Remark2,Remark3) values (@PatientId,@ApplyId,@RecorId,@RecoverId,@DocumentId,@DocumentName,@IsUpload,@OperatorId,@OperatorTime,@Remark,@Remark2,@Remark3);select @@identity"; + //从实体中取出值放入Command的参数列表 + cmd.Parameters.Add(new SqlParameter("@PatientId",printDocumentUP.PatientId.HasValue?(object)printDocumentUP.PatientId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@ApplyId",printDocumentUP.ApplyId.HasValue?(object)printDocumentUP.ApplyId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@RecorId",printDocumentUP.RecorId.HasValue?(object)printDocumentUP.RecorId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@RecoverId",printDocumentUP.RecoverId.HasValue?(object)printDocumentUP.RecoverId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@DocumentId",printDocumentUP.DocumentId==null?(object)DBNull.Value:(object)printDocumentUP.DocumentId)); + cmd.Parameters.Add(new SqlParameter("@DocumentName",printDocumentUP.DocumentName==null?(object)DBNull.Value:(object)printDocumentUP.DocumentName)); + cmd.Parameters.Add(new SqlParameter("@IsUpload",printDocumentUP.IsUpload==null?(object)DBNull.Value:(object)printDocumentUP.IsUpload)); + cmd.Parameters.Add(new SqlParameter("@OperatorId",printDocumentUP.OperatorId.HasValue?(object)printDocumentUP.OperatorId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@OperatorTime",printDocumentUP.OperatorTime.HasValue?(object)printDocumentUP.OperatorTime.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@Remark",printDocumentUP.Remark==null?(object)DBNull.Value:(object)printDocumentUP.Remark)); + cmd.Parameters.Add(new SqlParameter("@Remark2",printDocumentUP.Remark2==null?(object)DBNull.Value:(object)printDocumentUP.Remark2)); + cmd.Parameters.Add(new SqlParameter("@Remark3",printDocumentUP.Remark3==null?(object)DBNull.Value:(object)printDocumentUP.Remark3)); + return Convert.ToInt32(cmd.ExecuteScalar()); + } + /// + /// 不使用事务的插入方法 + /// + /// 实体类对象 + /// 标识列值或影响的记录行数 + internal static int Insert(PrintDocumentUP printDocumentUP) + { + using(SqlConnection conn=new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return Insert(cmd, printDocumentUP); + } + } + } + + /// + /// 使用事务的插入方法 + /// + /// 实现共享Connection的对象 + /// 实体类对象 + /// 标识列值或影响的记录行数 + internal static int Insert(Connection connection,PrintDocumentUP printDocumentUP) + { + return Insert(connection.Command, printDocumentUP); + } + #endregion + + #region 删除实体操作 + + /// + /// 删除 + /// + /// Command对象 + /// 实体类对象 + /// 影响的记录行数 + internal static int ExcuteDeleteCommand(SqlCommand cmd, PrintDocumentUP printDocumentUP) + { + cmd.Parameters.Clear(); + cmd.CommandText = "delete from PrintDocumentUP where Id=@Id"; + //从实体中取出值放入Command的参数列表 + cmd.Parameters.Add(new SqlParameter("@Id", printDocumentUP.Id)); + return cmd.ExecuteNonQuery(); + } + /// + /// 不使用事务的删除方法 + /// + /// 实体类对象 + /// 影响的记录行数 + internal static int Delete(PrintDocumentUP printDocumentUP) + { + using (SqlConnection conn = new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return ExcuteDeleteCommand(cmd, printDocumentUP); + } + } + } + /// + /// 使用事务的删除方法 + /// + /// 实现共享Connection的对象 + /// 实体类对象 + /// 影响的记录行数 + internal static int Delete(Connection connection,PrintDocumentUP printDocumentUP) + { + return ExcuteDeleteCommand(connection.Command, printDocumentUP); + } + + /// + /// 执行删除命令 + /// + /// Command对象 + /// 对象查询语句 + /// 参数列表 + /// 影响的记录行数 + internal static int ExcuteDeleteCommand(SqlCommand cmd, string oql, ParameterList parameters) + { + //解析过滤部份Sql语句 + string filterString = SyntaxAnalyzer.ParseSql(oql, new PrintDocumentUPMap()); + if (filterString != string.Empty) + { + filterString = " where " + filterString; + } + cmd.Parameters.Clear(); + cmd.CommandText = "delete from PrintDocumentUP " + filterString; + //添加参数 + if (parameters != null) + { + foreach (string key in parameters.Keys) + { + cmd.Parameters.Add(new SqlParameter(key, parameters[key])); + } + } + return cmd.ExecuteNonQuery(); + } + + /// + /// 不使用事务的删除方法 + /// + /// 对象查询语句 + /// 参数列表 + /// 影响的记录行数 + internal static int Delete(string oql, ParameterList parameters) + { + using (SqlConnection conn = new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return ExcuteDeleteCommand(cmd, oql, parameters); + } + } + } + + /// + /// 使用事务的删除方法 + /// + /// 实现共享Connection的对象 + /// 对象查询语句 + /// 参数列表 + /// 影响的记录行数 + internal static int Delete(Connection connection, string oql, ParameterList parameters) + { + return ExcuteDeleteCommand(connection.Command, oql, parameters); + } + + #endregion + + #region 更新实体操作 + + /// + /// 更新 + /// + /// Command对象 + /// 实体类对象 + /// 影响的记录行数 + internal static int ExcuteUpdateCommand(SqlCommand cmd, PrintDocumentUP printDocumentUP) + { + cmd.CommandText = "update PrintDocumentUP set PatientId=@PatientId,ApplyId=@ApplyId,RecorId=@RecorId,RecoverId=@RecoverId,DocumentId=@DocumentId,DocumentName=@DocumentName,IsUpload=@IsUpload,OperatorId=@OperatorId,OperatorTime=@OperatorTime,Remark=@Remark,Remark2=@Remark2,Remark3=@Remark3 where Id=@Id"; + //从实体中取出值放入Command的参数列表 + cmd.Parameters.Add(new SqlParameter("@PatientId",printDocumentUP.PatientId.HasValue?(object)printDocumentUP.PatientId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@ApplyId",printDocumentUP.ApplyId.HasValue?(object)printDocumentUP.ApplyId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@RecorId",printDocumentUP.RecorId.HasValue?(object)printDocumentUP.RecorId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@RecoverId",printDocumentUP.RecoverId.HasValue?(object)printDocumentUP.RecoverId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@DocumentId",printDocumentUP.DocumentId==null?(object)DBNull.Value:(object)printDocumentUP.DocumentId)); + cmd.Parameters.Add(new SqlParameter("@DocumentName",printDocumentUP.DocumentName==null?(object)DBNull.Value:(object)printDocumentUP.DocumentName)); + cmd.Parameters.Add(new SqlParameter("@IsUpload",printDocumentUP.IsUpload==null?(object)DBNull.Value:(object)printDocumentUP.IsUpload)); + cmd.Parameters.Add(new SqlParameter("@OperatorId",printDocumentUP.OperatorId.HasValue?(object)printDocumentUP.OperatorId.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@OperatorTime",printDocumentUP.OperatorTime.HasValue?(object)printDocumentUP.OperatorTime.Value:(object)DBNull.Value)); + cmd.Parameters.Add(new SqlParameter("@Remark",printDocumentUP.Remark==null?(object)DBNull.Value:(object)printDocumentUP.Remark)); + cmd.Parameters.Add(new SqlParameter("@Remark2",printDocumentUP.Remark2==null?(object)DBNull.Value:(object)printDocumentUP.Remark2)); + cmd.Parameters.Add(new SqlParameter("@Remark3",printDocumentUP.Remark3==null?(object)DBNull.Value:(object)printDocumentUP.Remark3)); + cmd.Parameters.Add(new SqlParameter("@Id", printDocumentUP.Id)); + return cmd.ExecuteNonQuery(); + } + + /// + /// 不使用事务的更新方法 + /// + /// 实体类对象 + /// 影响的记录行数 + internal static int Update(PrintDocumentUP printDocumentUP) + { + using(SqlConnection conn=new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return ExcuteUpdateCommand(cmd, printDocumentUP); + } + } + } + /// + /// 使用事务的更新方法 + /// + /// 实现共享Connection的对象 + /// 实体类对象 + /// 影响的记录行数 + internal static int Update(Connection connection,PrintDocumentUP printDocumentUP) + { + return ExcuteUpdateCommand(connection.Command, printDocumentUP); + } + /// + /// 执行更新命令 + /// + /// Command对象 + /// 对象查询语句 + /// 参数列表 + /// 影响的记录行数 + internal static int ExcuteUpdateCommand(SqlCommand cmd, string oql, ParameterList parameters) + { + //解析过滤部份Sql语句 + string updateString = SyntaxAnalyzer.ParseSql(oql, new PrintDocumentUPMap()); + cmd.CommandText = "update PrintDocumentUP set " + updateString; + cmd.Parameters.Clear(); + //添加参数 + if (parameters != null) + { + foreach (string key in parameters.Keys) + { + cmd.Parameters.Add(new SqlParameter(key, parameters[key])); + } + } + return cmd.ExecuteNonQuery(); + } + + /// + /// 不使用事务的更新方法 + /// + /// 对象查询语句 + /// 参数列表 + /// 影响的记录行数 + internal static int Update(string oql, ParameterList parameters) + { + using (SqlConnection conn = new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return ExcuteUpdateCommand(cmd, oql, parameters); + } + } + } + + /// + /// 使用事务的更新方法 + /// + /// 实现共享Connection的对象 + /// 对象查询语句 + /// 参数列表 + /// 影响的记录行数 + internal static int Update(Connection connection, string oql, ParameterList parameters) + { + return ExcuteUpdateCommand(connection.Command, oql, parameters); + } + #endregion + + #region 查询实体集合 + /// + /// 执行Command获取对象列表 + /// + /// Command对象 + /// 递归类型 + /// 递归深度 + /// 实体类对象列表 + internal static List ExcuteSelectCommand(SqlCommand cmd,RecursiveType recursiveType,int recursiveDepth) + { + List printDocumentUPList = new List(); + using (SqlDataReader dr = cmd.ExecuteReader()) + { + while (dr.Read()) + { + PrintDocumentUP printDocumentUP = DataReaderToEntity(dr); + printDocumentUPList.Add(printDocumentUP); + } + } + return printDocumentUPList; + } + /// + /// 执行查询命令 + /// + /// Command对象 + /// 对象查询语句 + /// 参数列表 + /// 递归类型 + /// 递归深度 + /// 实体类对象集合 + internal static List ExcuteSelectCommand(SqlCommand cmd, string oql, ParameterList parameters,RecursiveType recursiveType,int recursiveDepth) + { + //解析过滤部份Sql语句 + string filterString = SyntaxAnalyzer.ParseSql(oql, new PrintDocumentUPMap()); + if (filterString != string.Empty) + { + if(filterString.Trim().ToLower().IndexOf("order ")!=0) + filterString = " where " + filterString; + } + cmd.Parameters.Clear(); + cmd.CommandText = "select * from PrintDocumentUP " + filterString; + //添加参数 + if (parameters != null) + { + foreach (string key in parameters.Keys) + { + cmd.Parameters.Add(new SqlParameter(key, parameters[key])); + } + } + return ExcuteSelectCommand(cmd, recursiveType, recursiveDepth); + } + + /// + /// 根据对象查询语句查询实体集合 + /// + /// 实体类对象集合 + internal static List Select() + { + using(SqlConnection conn=new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + cmd.CommandText = "select * from PrintDocumentUP"; + return ExcuteSelectCommand(cmd, RecursiveType.Parent, 1); + } + } + } + /// + /// 根据对象查询语句查询实体集合 + /// + /// 递归类型 + /// 递归深度 + /// 实体类对象集合 + internal static List Select(RecursiveType recursiveType, int recursiveDepth) + { + using(SqlConnection conn=new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + cmd.CommandText = "select * from PrintDocumentUP"; + return ExcuteSelectCommand(cmd, recursiveType, recursiveDepth); + } + } + } + + /// + /// 根据对象查询语句查询实体集合 + /// + /// 对象查询语句 + /// 参数列表 + /// 实体类对象集合 + internal static List Select(string oql, ParameterList parameters) + { + using(SqlConnection conn=new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return ExcuteSelectCommand(cmd, oql, parameters, RecursiveType.Parent, 1); + } + } + } + + /// + /// 根据对象查询语句查询实体集合 + /// + /// 对象查询语句 + /// 参数列表 + /// 递归类型 + /// 递归深度 + /// 实体类对象集合 + internal static List Select(string oql, ParameterList parameters,RecursiveType recursiveType, int recursiveDepth) + { + using(SqlConnection conn=new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return ExcuteSelectCommand(cmd, oql, parameters, recursiveType, recursiveDepth); + } + } + } + + /// + /// 根据对象查询语句查询实体集合(启用事务) + /// + /// 连接对象 + /// 对象查询语句 + /// 参数列表 + /// 递归类型 + /// 递归深度 + /// 实体类对象集合 + internal static List Select(Connection connection, string oql, ParameterList parameters, RecursiveType recursiveType, int recursiveDepth) + { + return ExcuteSelectCommand(connection.Command, oql, parameters,recursiveType, recursiveDepth); + } + #endregion + + #region 查询单个实体 + + /// + /// 递归查询单个实体 + /// + /// Command对象 + /// 递归类型 + /// 递归深度 + /// 实体对象 + internal static PrintDocumentUP ExcuteSelectSingleCommand(SqlCommand cmd,RecursiveType recursiveType,int recursiveDepth) + { + PrintDocumentUP printDocumentUP=null; + using (SqlDataReader dr = cmd.ExecuteReader()) + { + if(dr.Read()) + printDocumentUP = DataReaderToEntity(dr); + } + if(printDocumentUP==null) + return printDocumentUP; + return printDocumentUP; + } + /// + /// 更据对象查询语句递归查询单个实体 + /// + /// Command对象 + /// 对象查询语句 + /// 参数列表 + /// 递归类型 + /// 递归深度 + /// 实体对象 + internal static PrintDocumentUP ExcuteSelectSingleCommand(SqlCommand cmd, string oql, ParameterList parameters,RecursiveType recursiveType,int recursiveDepth) + { + //解析过滤部份Sql语句 + string filterString = SyntaxAnalyzer.ParseSql(oql, new PrintDocumentUPMap()); + if(filterString!=string.Empty) + { + filterString=" where "+filterString; + } + cmd.CommandText = "select * from PrintDocumentUP " + filterString; + cmd.Parameters.Clear(); + //添加参数 + if (parameters != null) + { + foreach (string key in parameters.Keys) + { + cmd.Parameters.Add(new SqlParameter(key, parameters[key])); + } + } + return ExcuteSelectSingleCommand(cmd, recursiveType, recursiveDepth); + } + + /// + /// 更据对象查询语句递归查询单个实体 + /// + /// Command对象 + /// 对象查询语句 + /// 参数列表 + /// 递归类型 + /// 递归深度 + /// 实体对象 + internal static PrintDocumentUP SelectSingle(string oql, ParameterList parameters, RecursiveType recursiveType, int recursiveDepth) + { + using(SqlConnection conn=new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return ExcuteSelectSingleCommand(cmd, oql, parameters, recursiveType, recursiveDepth); + } + } + } + + /// + /// 更据对象查询语句查询单个实体 + /// + /// Command对象 + /// 对象查询语句 + /// 参数列表 + /// 实体对象 + internal static PrintDocumentUP SelectSingle(string oql, ParameterList parameters) + { + return SelectSingle(oql,parameters,RecursiveType.Parent,1); + } + + /// + /// 更据对象查询语句并启用事务查询单个实体 + /// + /// 连接对象 + /// 对象查询语句 + /// 参数列表 + /// 实体对象 + internal static PrintDocumentUP SelectSingle(Connection connection, string oql, ParameterList parameters, RecursiveType recursiveType, int recursiveDepth) + { + return ExcuteSelectSingleCommand(connection.Command, oql, parameters, recursiveType, recursiveDepth); + } + + /// + /// 更据主键值递归查询单个实体 + /// + /// Command对象 + /// 主键值 + /// 递归类型 + /// 递归深度 + /// 实体对象 + internal static PrintDocumentUP SelectSingle(SqlCommand cmd, int? id,RecursiveType recursiveType,int recursiveDepth) + { + cmd.Parameters.Clear(); + if(id.HasValue) + { + cmd.CommandText = "select * from PrintDocumentUP where Id=@pk"; + cmd.Parameters.Add(new SqlParameter("@pk",id.Value)); + } + else + { + cmd.CommandText = "select * from PrintDocumentUP where Id is null"; + } + return ExcuteSelectSingleCommand(cmd, recursiveType, recursiveDepth); + } + + /// + /// 按主键字段查询特定实体 + /// + /// 主键值 + /// 实体类对象 + internal static PrintDocumentUP SelectSingle(int? id) + { + using(SqlConnection conn=new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return SelectSingle(cmd,id,RecursiveType.Parent,1); + } + } + } + /// + /// 按主键字段查询特定实体 + /// + /// 主键值 + /// 递归类型 + /// 递归深度 + /// 实体类对象 + internal static PrintDocumentUP SelectSingle(int? id, RecursiveType recursiveType, int recursiveDepth) + { + using(SqlConnection conn=new SqlConnection(Connection.ConnectionString)) + { + conn.Open(); + using (SqlCommand cmd = conn.CreateCommand()) + { + return SelectSingle(cmd,id, recursiveType, recursiveDepth); + } + } + } + + /// + /// 使用事务并按主键字段查询特定实体 + /// + /// 连接对象 + /// 主键值 + /// 实体类对象 + internal static PrintDocumentUP SelectSingle(Connection connection,int? id, RecursiveType recursiveType, int recursiveDepth) + { + return SelectSingle(connection.Command, id, recursiveType, recursiveDepth); + } + #endregion + + + /// + /// 从DataReader中取出值生成实体对象 + /// + /// 查询对象 + /// 过滤条件字符串 + private static PrintDocumentUP DataReaderToEntity(SqlDataReader dr) + { + PrintDocumentUP entity = new PrintDocumentUP (); + if(dr["Id"]!=System.DBNull.Value) + { + entity.Id=Convert.ToInt32(dr["Id"]); + } + if(dr["PatientId"]!=System.DBNull.Value) + { + entity.PatientId=Convert.ToInt32(dr["PatientId"]); + } + if(dr["ApplyId"]!=System.DBNull.Value) + { + entity.ApplyId=Convert.ToInt32(dr["ApplyId"]); + } + if(dr["RecorId"]!=System.DBNull.Value) + { + entity.RecorId=Convert.ToInt32(dr["RecorId"]); + } + if(dr["RecoverId"]!=System.DBNull.Value) + { + entity.RecoverId=Convert.ToInt32(dr["RecoverId"]); + } + if(dr["DocumentId"]!=System.DBNull.Value) + { + entity.DocumentId=dr["DocumentId"].ToString(); + } + if(dr["DocumentName"]!=System.DBNull.Value) + { + entity.DocumentName=dr["DocumentName"].ToString(); + } + if(dr["IsUpload"]!=System.DBNull.Value) + { + entity.IsUpload=dr["IsUpload"].ToString(); + } + if(dr["OperatorId"]!=System.DBNull.Value) + { + entity.OperatorId=Convert.ToInt32(dr["OperatorId"]); + } + if(dr["OperatorTime"]!=System.DBNull.Value) + { + entity.OperatorTime=Convert.ToDateTime(dr["OperatorTime"]); + } + if(dr["Remark"]!=System.DBNull.Value) + { + entity.Remark=dr["Remark"].ToString(); + } + if(dr["Remark2"]!=System.DBNull.Value) + { + entity.Remark2=dr["Remark2"].ToString(); + } + if(dr["Remark3"]!=System.DBNull.Value) + { + entity.Remark3=dr["Remark3"].ToString(); + } + return entity; + } + } +} + diff --git a/AIMSEntity/Model/AutoGenerate/PrintDocumentUP.cs b/AIMSEntity/Model/AutoGenerate/PrintDocumentUP.cs new file mode 100644 index 0000000..d4b2223 --- /dev/null +++ b/AIMSEntity/Model/AutoGenerate/PrintDocumentUP.cs @@ -0,0 +1,131 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using AIMSDAL; + +namespace AIMSModel +{ + [Serializable] + public partial class PrintDocumentUP + { + private int? id; + private int? patientId; + private int? applyId; + private int? recorId; + private int? recoverId; + private string documentId; + private string documentName; + private string isUpload; + private int? operatorId; + private DateTime? operatorTime; + private string remark; + private string remark2; + private string remark3; + + + /// + /// + /// + public int? Id + { + get{ return id; } + set{ id=value; } + } + /// + /// + /// + public int? PatientId + { + get{ return patientId; } + set{ patientId=value; } + } + /// + /// + /// + public int? ApplyId + { + get{ return applyId; } + set{ applyId=value; } + } + /// + /// + /// + public int? RecorId + { + get{ return recorId; } + set{ recorId=value; } + } + /// + /// + /// + public int? RecoverId + { + get{ return recoverId; } + set{ recoverId=value; } + } + /// + /// + /// + public string DocumentId + { + get{ return documentId; } + set{ documentId=value; } + } + /// + /// + /// + public string DocumentName + { + get{ return documentName; } + set{ documentName=value; } + } + /// + /// + /// + public string IsUpload + { + get{ return isUpload; } + set{ isUpload=value; } + } + /// + /// + /// + public int? OperatorId + { + get{ return operatorId; } + set{ operatorId=value; } + } + /// + /// + /// + public DateTime? OperatorTime + { + get{ return operatorTime; } + set{ operatorTime=value; } + } + /// + /// + /// + public string Remark + { + get{ return remark; } + set{ remark=value; } + } + /// + /// + /// + public string Remark2 + { + get{ return remark2; } + set{ remark2=value; } + } + /// + /// + /// + public string Remark3 + { + get{ return remark3; } + set{ remark3=value; } + } + } +} diff --git a/AIMSEntity/ObjectQuery/PrintDocumentUPMap.cs b/AIMSEntity/ObjectQuery/PrintDocumentUPMap.cs new file mode 100644 index 0000000..f885bb5 --- /dev/null +++ b/AIMSEntity/ObjectQuery/PrintDocumentUPMap.cs @@ -0,0 +1,46 @@ +using System; +using System.Collections; +using System.Collections.Generic; + +namespace AIMSObjectQuery +{ + internal partial class PrintDocumentUPMap:IMap + { + private Dictionary dictionary = new Dictionary(); + public PrintDocumentUPMap() + { + dictionary.Add("id", "Id"); + dictionary.Add("patientid", "PatientId"); + dictionary.Add("applyid", "ApplyId"); + dictionary.Add("recorid", "RecorId"); + dictionary.Add("recoverid", "RecoverId"); + dictionary.Add("documentid", "DocumentId"); + dictionary.Add("documentname", "DocumentName"); + dictionary.Add("isupload", "IsUpload"); + dictionary.Add("operatorid", "OperatorId"); + dictionary.Add("operatortime", "OperatorTime"); + dictionary.Add("remark", "Remark"); + dictionary.Add("remark2", "Remark2"); + dictionary.Add("remark3", "Remark3"); + } + + #region IMap 成员 + + public string this[string propertyName] + { + get + { + try + { + return dictionary[propertyName.ToLower()]; + } + catch (KeyNotFoundException) + { + throw new Exception(propertyName + "属性不存在"); + } + } + } + + #endregion + } +} diff --git a/DataCollectorService/DataCollectorService.csproj b/DataCollectorService/DataCollectorService.csproj deleted file mode 100644 index 076fa4f..0000000 --- a/DataCollectorService/DataCollectorService.csproj +++ /dev/null @@ -1,55 +0,0 @@ - - - - - Debug - AnyCPU - {A445F69B-9EA6-40F8-87EA-D524A40FB90B} - WinExe - DataCollectorService - DataCollectorService - v4.0 - 512 - true - - - AnyCPU - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - AnyCPU - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - - - - - - - - - - - Component - - - Service1.cs - - - - - - \ No newline at end of file diff --git a/DataCollectorService/Program.cs b/DataCollectorService/Program.cs deleted file mode 100644 index 6c6a064..0000000 --- a/DataCollectorService/Program.cs +++ /dev/null @@ -1,24 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.ServiceProcess; -using System.Text; - -namespace DataCollectorService -{ - internal static class Program - { - /// - /// 应用程序的主入口点。 - /// - static void Main() - { - ServiceBase[] ServicesToRun; - ServicesToRun = new ServiceBase[] - { - new Service1() - }; - ServiceBase.Run(ServicesToRun); - } - } -} diff --git a/DataCollectorService/Properties/AssemblyInfo.cs b/DataCollectorService/Properties/AssemblyInfo.cs deleted file mode 100644 index d1c7223..0000000 --- a/DataCollectorService/Properties/AssemblyInfo.cs +++ /dev/null @@ -1,36 +0,0 @@ -using System.Reflection; -using System.Runtime.CompilerServices; -using System.Runtime.InteropServices; - -// 有关程序集的一般信息由以下 -// 控制。更改这些特性值可修改 -// 与程序集关联的信息。 -[assembly: AssemblyTitle("DataCollectorService")] -[assembly: AssemblyDescription("")] -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("DataCollectorService")] -[assembly: AssemblyCopyright("Copyright © 2023")] -[assembly: AssemblyTrademark("")] -[assembly: AssemblyCulture("")] - -// 将 ComVisible 设置为 false 会使此程序集中的类型 -//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型 -//请将此类型的 ComVisible 特性设置为 true。 -[assembly: ComVisible(false)] - -// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID -[assembly: Guid("a445f69b-9ea6-40f8-87ea-d524a40fb90b")] - -// 程序集的版本信息由下列四个值组成: -// -// 主版本 -// 次版本 -// 生成号 -// 修订号 -// -//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值 -//通过使用 "*",如下所示: -// [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/DataCollectorService/Service1.Designer.cs b/DataCollectorService/Service1.Designer.cs deleted file mode 100644 index a371bcb..0000000 --- a/DataCollectorService/Service1.Designer.cs +++ /dev/null @@ -1,37 +0,0 @@ -namespace DataCollectorService -{ - partial class Service1 - { - /// - /// 必需的设计器变量。 - /// - private System.ComponentModel.IContainer components = null; - - /// - /// 清理所有正在使用的资源。 - /// - /// 如果应释放托管资源,为 true;否则为 false。 - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region 组件设计器生成的代码 - - /// - /// 设计器支持所需的方法 - 不要修改 - /// 使用代码编辑器修改此方法的内容。 - /// - private void InitializeComponent() - { - components = new System.ComponentModel.Container(); - this.ServiceName = "Service1"; - } - - #endregion - } -} diff --git a/DataCollectorService/Service1.cs b/DataCollectorService/Service1.cs deleted file mode 100644 index 4e19adc..0000000 --- a/DataCollectorService/Service1.cs +++ /dev/null @@ -1,27 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Diagnostics; -using System.Linq; -using System.ServiceProcess; -using System.Text; - -namespace DataCollectorService -{ - public partial class Service1 : ServiceBase - { - public Service1() - { - InitializeComponent(); - } - - protected override void OnStart(string[] args) - { - } - - protected override void OnStop() - { - } - } -} diff --git a/DrawGraphManagement/DrawGraphManagement.csproj b/DrawGraphManagement/DrawGraphManagement.csproj index 4ea416c..869fb5a 100644 --- a/DrawGraphManagement/DrawGraphManagement.csproj +++ b/DrawGraphManagement/DrawGraphManagement.csproj @@ -105,6 +105,12 @@ AreaManageForm.cs + + Form + + + frmPrintDocument.cs + Form @@ -139,6 +145,9 @@ AreaManageForm.cs + + frmPrintDocument.cs + frmTemplateD.cs @@ -177,9 +186,6 @@ Always - - Always - @@ -206,7 +212,6 @@ DrawGraph - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 17, 17 + + + 563, 17 + + \ No newline at end of file