文书上传服务器

This commit is contained in:
leomon 2023-05-24 17:52:55 +08:00
parent d81bff33f9
commit 02ccc9723d
30 changed files with 1591 additions and 375 deletions

View File

@ -23,8 +23,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BeginScreen", "BeginScreen\
EndProject EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DocumentManagement", "DocumentManagement\DocumentManagement.csproj", "{80E69D05-8436-4342-B0B1-5ADAA8E83D41}" Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DocumentManagement", "DocumentManagement\DocumentManagement.csproj", "{80E69D05-8436-4342-B0B1-5ADAA8E83D41}"
EndProject EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DataCollectorService", "DataCollectorService\DataCollectorService.csproj", "{A445F69B-9EA6-40F8-87EA-D524A40FB90B}"
EndProject
Global Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU 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|x64.Build.0 = Release|Any CPU
{80E69D05-8436-4342-B0B1-5ADAA8E83D41}.Release|x86.ActiveCfg = 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 {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 EndGlobalSection
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8" ?> <?xml version="1.0" encoding="utf-8" ?>
<AtuoUpdate> <AtuoUpdate>
<ConnectionString>Data Source=.;Initial Catalog=AIMSDB_DLSJZQZYYY;User ID=sa;Password=Test2020;</ConnectionString> <ConnectionString>Data Source=.;Initial Catalog=AIMSDB_FJZPTFYY;User ID=sa;Password=Test2020;</ConnectionString>
<DataConnectionString>Data Source=.;Initial Catalog=AIMSDB_DATA;User ID=sa;Password=Test2020;</DataConnectionString> <DataConnectionString>Data Source=.;Initial Catalog=AIMSDB_DATA;User ID=sa;Password=Test2020;</DataConnectionString>
<HisConnectionStringOracel>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;</HisConnectionStringOracel> <HisConnectionStringOracel>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;</HisConnectionStringOracel>
<LastLoginNo></LastLoginNo> <LastLoginNo></LastLoginNo>

View File

@ -430,6 +430,7 @@ namespace AIMS.OperationAfter.UI
doc.Dock = DockStyle.Fill; doc.Dock = DockStyle.Fill;
doc.Show(); 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);
} }
} }

View File

@ -50,11 +50,11 @@ namespace AIMS
txtNo.Select(); txtNo.Select();
txtNo.Focus(); txtNo.Focus();
} }
#if DEBUG //#if DEBUG
txtNo.Text = "admin"; // txtNo.Text = "admin";
txtPassWord.Text = "1"; // txtPassWord.Text = "1";
btnOk_Click(null, null); // btnOk_Click(null, null);
#endif //#endif
} }
private void btnOk_Click(object sender, EventArgs e) private void btnOk_Click(object sender, EventArgs e)
{ {

View File

@ -174,7 +174,8 @@ namespace AIMS.OperationAanesthesia
pDoc.Print(); 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; count = 0;
} }
catch (Exception exp) catch (Exception exp)

View File

@ -175,7 +175,7 @@ namespace AIMS.OperationAanesthesia
{ {
pDoc.Print(); pDoc.Print();
} }
ControlExtension.UPDocument(_record.PatientId.Value, _record.OperationApplyId.Value, _record.Id.Value, _record.RecoverId.Value, "40,50", "麻醉记录单");
PublicMethod.WriteLog("打印麻醉记录单", _record.PatientId.Value, 1, "麻醉"); PublicMethod.WriteLog("打印麻醉记录单", _record.PatientId.Value, 1, "麻醉");
count = 0; count = 0;
} }

View File

@ -238,7 +238,8 @@ namespace AIMS.OperationAanesthesia
pDoc.Print(); 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; count = 0;
} }
catch (Exception exp) catch (Exception exp)
@ -422,7 +423,7 @@ namespace AIMS.OperationAanesthesia
{ {
DrawGraph.FactEvents Inevent = null; DrawGraph.FactEvents Inevent = null;
DateTimeInput tb = obj as DateTimeInput; DateTimeInput tb = obj as DateTimeInput;
if (_record.StateName == "麻醉复苏中") if (_record.StateName == "麻醉复苏中" || tb.Name.Equals("txtBG"))
{ {
DeleteEventTime("txtAnaesthesiaEnd", "麻醉完成", tb, ref Inevent); DeleteEventTime("txtAnaesthesiaEnd", "麻醉完成", tb, ref Inevent);
DeleteEventTime("txtBG", cmbBGType.Text, tb, ref Inevent); DeleteEventTime("txtBG", cmbBGType.Text, tb, ref Inevent);

View File

@ -2294,6 +2294,7 @@ namespace AIMS.OperationAanesthesia
pDoc.Print(); pDoc.Print();
} }
ControlExtension.UPDocument(_record.PatientId.Value, _record.OperationApplyId.Value, _record.Id.Value, _record.RecoverId.Value, "20", "护理记录单");
plRefresh_Click(null, null); plRefresh_Click(null, null);
} }
catch (Exception exp) catch (Exception exp)

View File

@ -1921,6 +1921,7 @@ namespace AIMS.OperationAanesthesia
{ {
myEditControl.ExecuteCommand("FilePrint", false, null); myEditControl.ExecuteCommand("FilePrint", false, null);
plRefresh_Click(null, null); plRefresh_Click(null, null);
ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName);
new frmMessageBox("打印完成!").Show(); new frmMessageBox("打印完成!").Show();
} }
catch (Exception exp) catch (Exception exp)

View File

@ -184,18 +184,21 @@ namespace AIMS.OperationAanesthesia
DModel = DocumentDAL.GetDocumentbyName("第二类精神药品处方笺", Patient.PatientId, item.Id.Value); DModel = DocumentDAL.GetDocumentbyName("第二类精神药品处方笺", Patient.PatientId, item.Id.Value);
LoadDocument(); LoadDocument();
myEditControl.ExecuteCommand("FilePrint", false, null); myEditControl.ExecuteCommand("FilePrint", false, null);
ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName);
} }
else if (item.FeeTypeId == "精神I类") else if (item.FeeTypeId == "精神I类")
{ {
DModel = DocumentDAL.GetDocumentbyName("第一类精神药品处方笺", Patient.PatientId, item.Id.Value); DModel = DocumentDAL.GetDocumentbyName("第一类精神药品处方笺", Patient.PatientId, item.Id.Value);
LoadDocument(); LoadDocument();
myEditControl.ExecuteCommand("FilePrint", false, null); myEditControl.ExecuteCommand("FilePrint", false, null);
ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName);
} }
else if (item.FeeTypeId == "麻醉药") else if (item.FeeTypeId == "麻醉药")
{ {
DModel = DocumentDAL.GetDocumentbyName("麻醉药品处方笺", Patient.PatientId, item.Id.Value); DModel = DocumentDAL.GetDocumentbyName("麻醉药品处方笺", Patient.PatientId, item.Id.Value);
LoadDocument(); LoadDocument();
myEditControl.ExecuteCommand("FilePrint", false, null); 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); tsbSava_Click(null, null);
myEditControl.ExecuteCommand("FilePrint", true, 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) private void tsbExit_Click(object sender, EventArgs e)
{ {

View File

@ -336,7 +336,7 @@ namespace AIMS
} }
} }
public static List<OperationRoom> SiteRooms; public static List<OperationRoom> 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)
{ {
@ -352,7 +352,7 @@ namespace AIMS
{ {
comboBoxEx.Text = PublicMethod.LastOperationSite; comboBoxEx.Text = PublicMethod.LastOperationSite;
} }
if (DefaultSite!="") if (DefaultSite != "")
{ {
comboBoxEx.Text = DefaultSite; comboBoxEx.Text = DefaultSite;
} }
@ -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);
}
}
} }
} }

View File

@ -21,7 +21,7 @@ namespace AIMS.OremrUserControl
//模板Model //模板Model
private PrintTemplate TModel = new PrintTemplate(); private PrintTemplate TModel = new PrintTemplate();
//文档Model //文档Model
private PrintDocument DModel = new PrintDocument(); public PrintDocument DModel = new PrintDocument();
//患者Id //患者Id
public PatientRecord Patient = new PatientRecord(); public PatientRecord Patient = new PatientRecord();
//刷新文档目录 //刷新文档目录
@ -375,11 +375,15 @@ namespace AIMS.OremrUserControl
if (tsbSaveAndPrint.Text == "打印") if (tsbSaveAndPrint.Text == "打印")
{ {
myEditControl.ExecuteCommand("FilePrint", true, null); myEditControl.ExecuteCommand("FilePrint", true, null);
ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName);
} }
else else
{ {
tsbSave_Click(null, null); tsbSave_Click(null, null);
myEditControl.ExecuteCommand("FilePrint", true, null); myEditControl.ExecuteCommand("FilePrint", true, null);
ControlExtension.UPDocument(Patient.PatientId, Patient.ApplyId, DModel.Id, 3, DModel.TemplateId.ToString(), DModel.XmlFileName);
} }
} }

View File

@ -55,6 +55,7 @@
<Compile Include="BLL\AutoGenerate\BFeesRecordReport.cs" /> <Compile Include="BLL\AutoGenerate\BFeesRecordReport.cs" />
<Compile Include="BLL\AutoGenerate\BNotesRecord.cs" /> <Compile Include="BLL\AutoGenerate\BNotesRecord.cs" />
<Compile Include="BLL\AutoGenerate\BOperationRecordAnalgesia.cs" /> <Compile Include="BLL\AutoGenerate\BOperationRecordAnalgesia.cs" />
<Compile Include="BLL\AutoGenerate\BPrintDocumentUP.cs" />
<Compile Include="BLL\Extension\BFeesRecord.cs" /> <Compile Include="BLL\Extension\BFeesRecord.cs" />
<Compile Include="BLL\Extension\BFeesRecordReport.cs" /> <Compile Include="BLL\Extension\BFeesRecordReport.cs" />
<Compile Include="BLL\Extension\BNotesRecord.cs" /> <Compile Include="BLL\Extension\BNotesRecord.cs" />
@ -62,6 +63,7 @@
<Compile Include="DAL\AutoGenerate\DFeesRecordReport.cs" /> <Compile Include="DAL\AutoGenerate\DFeesRecordReport.cs" />
<Compile Include="DAL\AutoGenerate\DNotesRecord.cs" /> <Compile Include="DAL\AutoGenerate\DNotesRecord.cs" />
<Compile Include="DAL\AutoGenerate\DOperationRecordAnalgesia.cs" /> <Compile Include="DAL\AutoGenerate\DOperationRecordAnalgesia.cs" />
<Compile Include="DAL\AutoGenerate\DPrintDocumentUP.cs" />
<Compile Include="DAL\Extension\DFeesRecord.cs" /> <Compile Include="DAL\Extension\DFeesRecord.cs" />
<Compile Include="DAL\Extension\DFeesRecordReport.cs" /> <Compile Include="DAL\Extension\DFeesRecordReport.cs" />
<Compile Include="DAL\Extension\DNotesRecord.cs" /> <Compile Include="DAL\Extension\DNotesRecord.cs" />
@ -346,6 +348,7 @@
<Compile Include="DAL\Extension\DUserPurview.cs" /> <Compile Include="DAL\Extension\DUserPurview.cs" />
<Compile Include="Model\AutoGenerate\FeesRecordReport.cs" /> <Compile Include="Model\AutoGenerate\FeesRecordReport.cs" />
<Compile Include="Model\AutoGenerate\NotesRecord.cs" /> <Compile Include="Model\AutoGenerate\NotesRecord.cs" />
<Compile Include="Model\AutoGenerate\PrintDocumentUP.cs" />
<Compile Include="Model\Extension\FeesRecord.cs" /> <Compile Include="Model\Extension\FeesRecord.cs" />
<Compile Include="Model\AutoGenerate\AnaesthesiaEvents.cs" /> <Compile Include="Model\AutoGenerate\AnaesthesiaEvents.cs" />
<Compile Include="Model\AutoGenerate\AnaesthesiaMethod.cs" /> <Compile Include="Model\AutoGenerate\AnaesthesiaMethod.cs" />
@ -540,6 +543,7 @@
<Compile Include="ObjectQuery\PersonMap.cs" /> <Compile Include="ObjectQuery\PersonMap.cs" />
<Compile Include="ObjectQuery\PharmaCologyMap.cs" /> <Compile Include="ObjectQuery\PharmaCologyMap.cs" />
<Compile Include="ObjectQuery\PrintDocMap.cs" /> <Compile Include="ObjectQuery\PrintDocMap.cs" />
<Compile Include="ObjectQuery\PrintDocumentUPMap.cs" />
<Compile Include="ObjectQuery\ProgramExceptionMap.cs" /> <Compile Include="ObjectQuery\ProgramExceptionMap.cs" />
<Compile Include="ObjectQuery\ProviderMap.cs" /> <Compile Include="ObjectQuery\ProviderMap.cs" />
<Compile Include="ObjectQuery\QualityControlConfigMap.cs" /> <Compile Include="ObjectQuery\QualityControlConfigMap.cs" />

View File

@ -0,0 +1,160 @@
using System;
using AIMSDAL;
using AIMSModel;
using System.Collections;
using System.Collections.Generic;
namespace AIMSBLL
{
public partial class BPrintDocumentUP
{
#region
/// <summary>
/// 插入实体
/// </summary>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>标识列值或影响的记录行数</returns>
public static int Insert(PrintDocumentUP printDocumentUP)
{
return DPrintDocumentUP.Insert(printDocumentUP);
}
#endregion
#region
/// <summary>
/// 删除实体
/// </summary>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>影响的记录行数</returns>
public static int Delete(PrintDocumentUP printDocumentUP)
{
return DPrintDocumentUP.Delete(printDocumentUP);
}
/// <summary>
/// 根据对象查询语句删除
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>影响的记录行数</returns>
public static int Delete(string oql, ParameterList parameters)
{
return DPrintDocumentUP.Delete(oql,parameters);
}
#endregion
#region
/// <summary>
/// 更新实体
/// </summary>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>影响的记录行数</returns>
public static int Update(PrintDocumentUP printDocumentUP)
{
return DPrintDocumentUP.Update(printDocumentUP);
}
/// <summary>
/// 根据对象查询语句更新实体
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>影响的记录行数</returns>
public static int Update(string oql, ParameterList parameters)
{
return DPrintDocumentUP.Update(oql,parameters);
}
#endregion
#region
/// <summary>
/// \查询实体集合
/// </summary>
/// <returns>实体类对象集合</returns>
public static List<PrintDocumentUP> Select()
{
return DPrintDocumentUP.Select();
}
/// <summary>
/// 递归查询实体集合
/// </summary>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体类对象集合</returns>
public static List<PrintDocumentUP> Select(RecursiveType recursiveType, int recursiveDepth)
{
return DPrintDocumentUP.Select(recursiveType, recursiveDepth);
}
/// <summary>
/// 根据对象查询语句查询实体集合
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>实体类对象集合</returns>
public static List<PrintDocumentUP> Select(string oql, ParameterList parameters)
{
return DPrintDocumentUP.Select(oql, parameters);
}
/// <summary>
/// 根据对象查询语句递归查询实体集合
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体类对象集合</returns>
public static List<PrintDocumentUP> Select(string oql, ParameterList parameters,RecursiveType recursiveType, int recursiveDepth)
{
return DPrintDocumentUP.Select(oql, parameters, recursiveType, recursiveDepth);
}
#endregion
#region
/// <summary>
/// 更据对象查询语句查询单个实体
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>实体对象</returns>
public static PrintDocumentUP SelectSingle(string oql, ParameterList parameters)
{
return DPrintDocumentUP.SelectSingle(oql, parameters);
}
/// <summary>
/// 更据对象查询语句递归查询单个实体
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体对象</returns>
public static PrintDocumentUP SelectSingle(string oql, ParameterList parameters, RecursiveType recursiveType, int recursiveDepth)
{
return DPrintDocumentUP.SelectSingle(oql, parameters, recursiveType, recursiveDepth);
}
/// <summary>
/// 按主键字段查询特定实体
/// </summary>
/// <param name="id">主键值</param>
/// <returns>实体类对象</returns>
public static PrintDocumentUP SelectSingle(int? id)
{
return DPrintDocumentUP.SelectSingle(id);
}
/// <summary>
/// 更据主键递归查询单个实体
/// </summary>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体对象</returns>
public static PrintDocumentUP SelectSingle(int? id, RecursiveType recursiveType, int recursiveDepth)
{
return DPrintDocumentUP.SelectSingle(id, recursiveType, recursiveDepth);
}
#endregion
}
}

View File

@ -252,12 +252,33 @@ namespace AIMSBLL
TimeSpan BeginTimets = DateTime.Parse(dr["BeginTime"].ToString()).Subtract(drugMinTime); TimeSpan BeginTimets = DateTime.Parse(dr["BeginTime"].ToString()).Subtract(drugMinTime);
PhysioData PhysioDataObj = new PhysioData(); PhysioData PhysioDataObj = new PhysioData();
PhysioDataObj.PatientId = _record.Id.Value; PhysioDataObj.PatientId = _record.Id.Value;
PhysioDataObj.RecordTime = InRoomTime.AddSeconds(BeginTimets.TotalSeconds); PhysioDataObj.RecordTime = GetRecordTime(_record, InRoomTime.AddSeconds(BeginTimets.TotalSeconds));
PhysioDataObj.PhysioDataConfigId = PhysioParamId; PhysioDataObj.PhysioDataConfigId = PhysioParamId;
PhysioDataObj.ValueString = dr["Value"].ToString(); PhysioDataObj.ValueString = dr["Value"].ToString();
if (PhysioDataObj.RecordTime >= InRoomTime)
PhysioDataObjs.Add(PhysioDataObj); PhysioDataObjs.Add(PhysioDataObj);
} }
PhysioDataService.AddPhysioDatas2(PhysioDataObjs); 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;
}
} }
} }

View File

@ -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
/// <summary>
/// 插入
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>标识列值或影响的记录行数</returns>
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());
}
/// <summary>
/// 不使用事务的插入方法
/// </summary>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>标识列值或影响的记录行数</returns>
internal static int Insert(PrintDocumentUP printDocumentUP)
{
using(SqlConnection conn=new SqlConnection(Connection.ConnectionString))
{
conn.Open();
using (SqlCommand cmd = conn.CreateCommand())
{
return Insert(cmd, printDocumentUP);
}
}
}
/// <summary>
/// 使用事务的插入方法
/// </summary>
/// <param name="connection">实现共享Connection的对象</param>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>标识列值或影响的记录行数</returns>
internal static int Insert(Connection connection,PrintDocumentUP printDocumentUP)
{
return Insert(connection.Command, printDocumentUP);
}
#endregion
#region
/// <summary>
/// 删除
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>影响的记录行数</returns>
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();
}
/// <summary>
/// 不使用事务的删除方法
/// </summary>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>影响的记录行数</returns>
internal static int Delete(PrintDocumentUP printDocumentUP)
{
using (SqlConnection conn = new SqlConnection(Connection.ConnectionString))
{
conn.Open();
using (SqlCommand cmd = conn.CreateCommand())
{
return ExcuteDeleteCommand(cmd, printDocumentUP);
}
}
}
/// <summary>
/// 使用事务的删除方法
/// </summary>
/// <param name="connection">实现共享Connection的对象</param>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>影响的记录行数</returns>
internal static int Delete(Connection connection,PrintDocumentUP printDocumentUP)
{
return ExcuteDeleteCommand(connection.Command, printDocumentUP);
}
/// <summary>
/// 执行删除命令
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>影响的记录行数</returns>
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();
}
/// <summary>
/// 不使用事务的删除方法
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>影响的记录行数</returns>
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);
}
}
}
/// <summary>
/// 使用事务的删除方法
/// </summary>
/// <param name="connection">实现共享Connection的对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>影响的记录行数</returns>
internal static int Delete(Connection connection, string oql, ParameterList parameters)
{
return ExcuteDeleteCommand(connection.Command, oql, parameters);
}
#endregion
#region
/// <summary>
/// 更新
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>影响的记录行数</returns>
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();
}
/// <summary>
/// 不使用事务的更新方法
/// </summary>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>影响的记录行数</returns>
internal static int Update(PrintDocumentUP printDocumentUP)
{
using(SqlConnection conn=new SqlConnection(Connection.ConnectionString))
{
conn.Open();
using (SqlCommand cmd = conn.CreateCommand())
{
return ExcuteUpdateCommand(cmd, printDocumentUP);
}
}
}
/// <summary>
/// 使用事务的更新方法
/// </summary>
/// <param name="connection">实现共享Connection的对象</param>
/// <param name="printDocumentUP">实体类对象</param>
/// <returns>影响的记录行数</returns>
internal static int Update(Connection connection,PrintDocumentUP printDocumentUP)
{
return ExcuteUpdateCommand(connection.Command, printDocumentUP);
}
/// <summary>
/// 执行更新命令
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>影响的记录行数</returns>
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();
}
/// <summary>
/// 不使用事务的更新方法
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>影响的记录行数</returns>
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);
}
}
}
/// <summary>
/// 使用事务的更新方法
/// </summary>
/// <param name="connection">实现共享Connection的对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>影响的记录行数</returns>
internal static int Update(Connection connection, string oql, ParameterList parameters)
{
return ExcuteUpdateCommand(connection.Command, oql, parameters);
}
#endregion
#region
/// <summary>
/// 执行Command获取对象列表
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体类对象列表</returns>
internal static List<PrintDocumentUP> ExcuteSelectCommand(SqlCommand cmd,RecursiveType recursiveType,int recursiveDepth)
{
List<PrintDocumentUP> printDocumentUPList = new List<PrintDocumentUP>();
using (SqlDataReader dr = cmd.ExecuteReader())
{
while (dr.Read())
{
PrintDocumentUP printDocumentUP = DataReaderToEntity(dr);
printDocumentUPList.Add(printDocumentUP);
}
}
return printDocumentUPList;
}
/// <summary>
/// 执行查询命令
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体类对象集合</returns>
internal static List<PrintDocumentUP> 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);
}
/// <summary>
/// 根据对象查询语句查询实体集合
/// </summary>
/// <returns>实体类对象集合</returns>
internal static List<PrintDocumentUP> 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);
}
}
}
/// <summary>
/// 根据对象查询语句查询实体集合
/// </summary>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体类对象集合</returns>
internal static List<PrintDocumentUP> 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);
}
}
}
/// <summary>
/// 根据对象查询语句查询实体集合
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>实体类对象集合</returns>
internal static List<PrintDocumentUP> 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);
}
}
}
/// <summary>
/// 根据对象查询语句查询实体集合
/// </summary>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体类对象集合</returns>
internal static List<PrintDocumentUP> 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);
}
}
}
/// <summary>
/// 根据对象查询语句查询实体集合(启用事务)
/// </summary>
/// <param name="connection">连接对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体类对象集合</returns>
internal static List<PrintDocumentUP> Select(Connection connection, string oql, ParameterList parameters, RecursiveType recursiveType, int recursiveDepth)
{
return ExcuteSelectCommand(connection.Command, oql, parameters,recursiveType, recursiveDepth);
}
#endregion
#region
/// <summary>
/// 递归查询单个实体
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体对象</returns>
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;
}
/// <summary>
/// 更据对象查询语句递归查询单个实体
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体对象</returns>
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);
}
/// <summary>
/// 更据对象查询语句递归查询单个实体
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体对象</returns>
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);
}
}
}
/// <summary>
/// 更据对象查询语句查询单个实体
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>实体对象</returns>
internal static PrintDocumentUP SelectSingle(string oql, ParameterList parameters)
{
return SelectSingle(oql,parameters,RecursiveType.Parent,1);
}
/// <summary>
/// 更据对象查询语句并启用事务查询单个实体
/// </summary>
/// <param name="connection">连接对象</param>
/// <param name="oql">对象查询语句</param>
/// <param name="parameters">参数列表</param>
/// <returns>实体对象</returns>
internal static PrintDocumentUP SelectSingle(Connection connection, string oql, ParameterList parameters, RecursiveType recursiveType, int recursiveDepth)
{
return ExcuteSelectSingleCommand(connection.Command, oql, parameters, recursiveType, recursiveDepth);
}
/// <summary>
/// 更据主键值递归查询单个实体
/// </summary>
/// <param name="cmd">Command对象</param>
/// <param name="id">主键值</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体对象</returns>
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);
}
/// <summary>
/// 按主键字段查询特定实体
/// </summary>
/// <param name="id">主键值</param>
/// <returns>实体类对象</returns>
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);
}
}
}
/// <summary>
/// 按主键字段查询特定实体
/// </summary>
/// <param name="id">主键值</param>
/// <param name="recursiveType">递归类型</param>
/// <param name="recursiveDepth">递归深度</param>
/// <returns>实体类对象</returns>
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);
}
}
}
/// <summary>
/// 使用事务并按主键字段查询特定实体
/// </summary>
/// <param name="connection">连接对象</param>
/// <param name="id">主键值</param>
/// <returns>实体类对象</returns>
internal static PrintDocumentUP SelectSingle(Connection connection,int? id, RecursiveType recursiveType, int recursiveDepth)
{
return SelectSingle(connection.Command, id, recursiveType, recursiveDepth);
}
#endregion
/// <summary>
/// 从DataReader中取出值生成实体对象
/// </summary>
/// <param name="searcher">查询对象</param>
/// <returns>过滤条件字符串</returns>
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;
}
}
}

View File

@ -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;
/// <summary>
///
/// </summary>
public int? Id
{
get{ return id; }
set{ id=value; }
}
/// <summary>
///
/// </summary>
public int? PatientId
{
get{ return patientId; }
set{ patientId=value; }
}
/// <summary>
///
/// </summary>
public int? ApplyId
{
get{ return applyId; }
set{ applyId=value; }
}
/// <summary>
///
/// </summary>
public int? RecorId
{
get{ return recorId; }
set{ recorId=value; }
}
/// <summary>
///
/// </summary>
public int? RecoverId
{
get{ return recoverId; }
set{ recoverId=value; }
}
/// <summary>
///
/// </summary>
public string DocumentId
{
get{ return documentId; }
set{ documentId=value; }
}
/// <summary>
///
/// </summary>
public string DocumentName
{
get{ return documentName; }
set{ documentName=value; }
}
/// <summary>
///
/// </summary>
public string IsUpload
{
get{ return isUpload; }
set{ isUpload=value; }
}
/// <summary>
///
/// </summary>
public int? OperatorId
{
get{ return operatorId; }
set{ operatorId=value; }
}
/// <summary>
///
/// </summary>
public DateTime? OperatorTime
{
get{ return operatorTime; }
set{ operatorTime=value; }
}
/// <summary>
///
/// </summary>
public string Remark
{
get{ return remark; }
set{ remark=value; }
}
/// <summary>
///
/// </summary>
public string Remark2
{
get{ return remark2; }
set{ remark2=value; }
}
/// <summary>
///
/// </summary>
public string Remark3
{
get{ return remark3; }
set{ remark3=value; }
}
}
}

View File

@ -0,0 +1,46 @@
using System;
using System.Collections;
using System.Collections.Generic;
namespace AIMSObjectQuery
{
internal partial class PrintDocumentUPMap:IMap
{
private Dictionary<string, string> dictionary = new Dictionary<string, string>();
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
}
}

View File

@ -1,55 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{A445F69B-9EA6-40F8-87EA-D524A40FB90B}</ProjectGuid>
<OutputType>WinExe</OutputType>
<RootNamespace>DataCollectorService</RootNamespace>
<AssemblyName>DataCollectorService</AssemblyName>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<Deterministic>true</Deterministic>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.ServiceProcess" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Service1.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="Service1.Designer.cs">
<DependentUpon>Service1.cs</DependentUpon>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>

View File

@ -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
{
/// <summary>
/// 应用程序的主入口点。
/// </summary>
static void Main()
{
ServiceBase[] ServicesToRun;
ServicesToRun = new ServiceBase[]
{
new Service1()
};
ServiceBase.Run(ServicesToRun);
}
}
}

View File

@ -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")]

View File

@ -1,37 +0,0 @@
namespace DataCollectorService
{
partial class Service1
{
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
/// <param name="disposing">如果应释放托管资源,为 true否则为 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region
/// <summary>
/// 设计器支持所需的方法 - 不要修改
/// 使用代码编辑器修改此方法的内容。
/// </summary>
private void InitializeComponent()
{
components = new System.ComponentModel.Container();
this.ServiceName = "Service1";
}
#endregion
}
}

View File

@ -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()
{
}
}
}

View File

@ -105,6 +105,12 @@
<DependentUpon>AreaManageForm.cs</DependentUpon> <DependentUpon>AreaManageForm.cs</DependentUpon>
</Compile> </Compile>
<Compile Include="DocumentParent.cs" /> <Compile Include="DocumentParent.cs" />
<Compile Include="frmPrintDocument.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="frmPrintDocument.designer.cs">
<DependentUpon>frmPrintDocument.cs</DependentUpon>
</Compile>
<Compile Include="frmTemplateD.cs"> <Compile Include="frmTemplateD.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
@ -139,6 +145,9 @@
<EmbeddedResource Include="AreaManageForm.resx"> <EmbeddedResource Include="AreaManageForm.resx">
<DependentUpon>AreaManageForm.cs</DependentUpon> <DependentUpon>AreaManageForm.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="frmPrintDocument.resx">
<DependentUpon>frmPrintDocument.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmTemplateD.resx"> <EmbeddedResource Include="frmTemplateD.resx">
<DependentUpon>frmTemplateD.cs</DependentUpon> <DependentUpon>frmTemplateD.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
@ -177,9 +186,6 @@
<Content Include="AIMS.xml"> <Content Include="AIMS.xml">
<CopyToOutputDirectory>Always</CopyToOutputDirectory> <CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content> </Content>
<Content Include="PdfiumViewer.dll">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1"> <BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
@ -206,7 +212,6 @@
<Name>DrawGraph</Name> <Name>DrawGraph</Name>
</ProjectReference> </ProjectReference>
</ItemGroup> </ItemGroup>
<ItemGroup />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it. <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets. Other similar extension points exist, see Microsoft.Common.targets.

View File

@ -30,12 +30,10 @@
{ {
this.components = new System.ComponentModel.Container(); this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainUp)); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainUp));
this.cmbManageList = new System.Windows.Forms.ComboBox();
this.label1 = new System.Windows.Forms.Label(); this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label(); this.label2 = new System.Windows.Forms.Label();
this.txtManageName = new System.Windows.Forms.TextBox(); this.txtManageName = new System.Windows.Forms.TextBox();
this.btnCreate = new System.Windows.Forms.Button(); this.btnCreate = new System.Windows.Forms.Button();
this.btnSave = new System.Windows.Forms.Button();
this.panel1 = new System.Windows.Forms.Panel(); this.panel1 = new System.Windows.Forms.Panel();
this.panel4 = new System.Windows.Forms.Panel(); this.panel4 = new System.Windows.Forms.Panel();
this.button5 = new System.Windows.Forms.Button(); this.button5 = new System.Windows.Forms.Button();
@ -64,17 +62,6 @@
this.myPanel1.SuspendLayout(); this.myPanel1.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
// //
// cmbManageList
//
this.cmbManageList.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.cmbManageList.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.cmbManageList.FormattingEnabled = true;
this.cmbManageList.Location = new System.Drawing.Point(771, 10);
this.cmbManageList.Name = "cmbManageList";
this.cmbManageList.Size = new System.Drawing.Size(155, 20);
this.cmbManageList.TabIndex = 0;
this.cmbManageList.Visible = false;
//
// label1 // label1
// //
this.label1.AutoSize = true; this.label1.AutoSize = true;
@ -113,22 +100,11 @@
this.btnCreate.UseVisualStyleBackColor = true; this.btnCreate.UseVisualStyleBackColor = true;
this.btnCreate.Visible = false; this.btnCreate.Visible = false;
// //
// btnSave
//
this.btnSave.Location = new System.Drawing.Point(895, 7);
this.btnSave.Name = "btnSave";
this.btnSave.Size = new System.Drawing.Size(75, 23);
this.btnSave.TabIndex = 5;
this.btnSave.Text = "保存";
this.btnSave.UseVisualStyleBackColor = true;
this.btnSave.Click += new System.EventHandler(this.btnSave_Click);
//
// panel1 // panel1
// //
this.panel1.Controls.Add(this.panel4); this.panel1.Controls.Add(this.panel4);
this.panel1.Controls.Add(this.label3); this.panel1.Controls.Add(this.label3);
this.panel1.Controls.Add(this.txtProjectName); this.panel1.Controls.Add(this.txtProjectName);
this.panel1.Controls.Add(this.cmbManageList);
this.panel1.Controls.Add(this.label1); this.panel1.Controls.Add(this.label1);
this.panel1.Controls.Add(this.label2); this.panel1.Controls.Add(this.label2);
this.panel1.Controls.Add(this.txtManageName); this.panel1.Controls.Add(this.txtManageName);
@ -157,7 +133,6 @@
this.panel4.Controls.Add(this.button2); this.panel4.Controls.Add(this.button2);
this.panel4.Controls.Add(this.btnCreate); this.panel4.Controls.Add(this.btnCreate);
this.panel4.Controls.Add(this.btnPrint); this.panel4.Controls.Add(this.btnPrint);
this.panel4.Controls.Add(this.btnSave);
this.panel4.Dock = System.Windows.Forms.DockStyle.Bottom; this.panel4.Dock = System.Windows.Forms.DockStyle.Bottom;
this.panel4.Location = new System.Drawing.Point(0, 4); this.panel4.Location = new System.Drawing.Point(0, 4);
this.panel4.Name = "panel4"; this.panel4.Name = "panel4";
@ -188,7 +163,7 @@
// //
// button11 // button11
// //
this.button11.Location = new System.Drawing.Point(981, 6); this.button11.Location = new System.Drawing.Point(887, 7);
this.button11.Name = "button11"; this.button11.Name = "button11";
this.button11.Size = new System.Drawing.Size(75, 23); this.button11.Size = new System.Drawing.Size(75, 23);
this.button11.TabIndex = 12; this.button11.TabIndex = 12;
@ -198,7 +173,7 @@
// //
// BtnBind // BtnBind
// //
this.BtnBind.Location = new System.Drawing.Point(809, 7); this.BtnBind.Location = new System.Drawing.Point(802, 7);
this.BtnBind.Name = "BtnBind"; this.BtnBind.Name = "BtnBind";
this.BtnBind.Size = new System.Drawing.Size(75, 23); this.BtnBind.Size = new System.Drawing.Size(75, 23);
this.BtnBind.TabIndex = 11; this.BtnBind.TabIndex = 11;
@ -221,11 +196,10 @@
this.textBox1.Name = "textBox1"; this.textBox1.Name = "textBox1";
this.textBox1.Size = new System.Drawing.Size(59, 21); this.textBox1.Size = new System.Drawing.Size(59, 21);
this.textBox1.TabIndex = 10; this.textBox1.TabIndex = 10;
this.textBox1.Text = "786";
// //
// button9 // button9
// //
this.button9.Location = new System.Drawing.Point(321, 7); this.button9.Location = new System.Drawing.Point(319, 7);
this.button9.Name = "button9"; this.button9.Name = "button9";
this.button9.Size = new System.Drawing.Size(107, 23); this.button9.Size = new System.Drawing.Size(107, 23);
this.button9.TabIndex = 6; this.button9.TabIndex = 6;
@ -235,7 +209,7 @@
// //
// button8 // button8
// //
this.button8.Location = new System.Drawing.Point(609, 7); this.button8.Location = new System.Drawing.Point(604, 7);
this.button8.Name = "button8"; this.button8.Name = "button8";
this.button8.Size = new System.Drawing.Size(102, 23); this.button8.Size = new System.Drawing.Size(102, 23);
this.button8.TabIndex = 6; this.button8.TabIndex = 6;
@ -245,7 +219,7 @@
// //
// button12 // button12
// //
this.button12.Location = new System.Drawing.Point(722, 7); this.button12.Location = new System.Drawing.Point(716, 7);
this.button12.Name = "button12"; this.button12.Name = "button12";
this.button12.Size = new System.Drawing.Size(76, 23); this.button12.Size = new System.Drawing.Size(76, 23);
this.button12.TabIndex = 6; this.button12.TabIndex = 6;
@ -255,7 +229,7 @@
// //
// button7 // button7
// //
this.button7.Location = new System.Drawing.Point(523, 7); this.button7.Location = new System.Drawing.Point(519, 7);
this.button7.Name = "button7"; this.button7.Name = "button7";
this.button7.Size = new System.Drawing.Size(75, 23); this.button7.Size = new System.Drawing.Size(75, 23);
this.button7.TabIndex = 6; this.button7.TabIndex = 6;
@ -265,7 +239,7 @@
// //
// button6 // button6
// //
this.button6.Location = new System.Drawing.Point(439, 7); this.button6.Location = new System.Drawing.Point(436, 7);
this.button6.Name = "button6"; this.button6.Name = "button6";
this.button6.Size = new System.Drawing.Size(73, 23); this.button6.Size = new System.Drawing.Size(73, 23);
this.button6.TabIndex = 6; this.button6.TabIndex = 6;
@ -275,7 +249,7 @@
// //
// button10 // button10
// //
this.button10.Location = new System.Drawing.Point(230, 7); this.button10.Location = new System.Drawing.Point(229, 7);
this.button10.Name = "button10"; this.button10.Name = "button10";
this.button10.Size = new System.Drawing.Size(80, 23); this.button10.Size = new System.Drawing.Size(80, 23);
this.button10.TabIndex = 6; this.button10.TabIndex = 6;
@ -295,7 +269,7 @@
// //
// btnPrint // btnPrint
// //
this.btnPrint.Location = new System.Drawing.Point(1067, 7); this.btnPrint.Location = new System.Drawing.Point(972, 7);
this.btnPrint.Name = "btnPrint"; this.btnPrint.Name = "btnPrint";
this.btnPrint.Size = new System.Drawing.Size(59, 23); this.btnPrint.Size = new System.Drawing.Size(59, 23);
this.btnPrint.TabIndex = 5; this.btnPrint.TabIndex = 5;
@ -412,7 +386,6 @@
private System.Windows.Forms.Label label2; private System.Windows.Forms.Label label2;
private System.Windows.Forms.TextBox txtManageName; private System.Windows.Forms.TextBox txtManageName;
private System.Windows.Forms.Button btnCreate; private System.Windows.Forms.Button btnCreate;
private System.Windows.Forms.Button btnSave;
private System.Windows.Forms.Panel panel1; private System.Windows.Forms.Panel panel1;
private DrawGraph.ZedGraphControl zgcAnaesRecord; private DrawGraph.ZedGraphControl zgcAnaesRecord;
private System.Windows.Forms.Label label3; private System.Windows.Forms.Label label3;

View File

@ -46,32 +46,42 @@ namespace DrawGraphManagement
AIMSExtension.PublicMethod.PermissionLevel = role.PermissionLevel == null ? 0 : role.PermissionLevel.Value; AIMSExtension.PublicMethod.PermissionLevel = role.PermissionLevel == null ? 0 : role.PermissionLevel.Value;
AIMSExtension.PublicMethod.RoleName = BMenu.GetMenuRootListManageStr(AIMSExtension.PublicMethod.RoleId, "功能权限"); AIMSExtension.PublicMethod.RoleName = BMenu.GetMenuRootListManageStr(AIMSExtension.PublicMethod.RoleId, "功能权限");
myPanel1.MouseWheel += new System.Windows.Forms.MouseEventHandler(panel1_MouseWheel); myPanel1.MouseWheel += new System.Windows.Forms.MouseEventHandler(panel1_MouseWheel);
LoadManageList();
}
public string DocumentName = "";
public string PrintAanesthesiaRecord(string PatientId)
{
textBox1.Text = PatientId;
button10_Click(null, null); button10_Click(null, null);
BtnBind_Click(null, null); BtnBind_Click(null, null);
OperationRecord _record = operationRecor as OperationRecord;
DocumentName = "麻醉记录单_" + _record.InHospitalNo + "_" + _record.PatientId;
btnPrint_Click(null, null);
return DocumentName;
} }
/// <summary>
/// 加载管理器列表
/// </summary>
private void LoadManageList()
{
Assembly assembly = Assembly.LoadFile(AppDomain.CurrentDomain.BaseDirectory + "DrawGraph.dll");//你的loadfile
Type baseType = typeof(AreaManageBase);
List<Type> types = assembly.GetTypes().Where<Type>(t => t.IsSubclassOf(baseType)).ToList<Type>();
List<Type> viewTypes = types.Where<Type>(s => s.FullName.IndexOf(".document.") < 0).ToList<Type>();
List<Type> wsTypes = types.Where<Type>(s => s.FullName.IndexOf(".document.") >= 0).ToList<Type>();
cmbManageList.Items.Clear(); public string PrintAanesthesiaRecover(string PatientId)
foreach (Type t in viewTypes)
{ {
cmbManageList.Items.Add(t.Name); textBox1.Text = PatientId;
button6_Click(null, null);
BtnBind1(int.Parse(PatientId), 2);
templateManage2 = null;
OperationRecord _record = operationRecor as OperationRecord;
DocumentName = "恢复记录单_" + _record.InHospitalNo + "_" + _record.PatientId;
btnPrint_Click(null, null);
return DocumentName;
} }
cmbManageList.Items.Add("-------------------");
foreach (Type t in wsTypes) public string PrintAanesthesiaPainlessRecord(string PatientId)
{ {
cmbManageList.Items.Add(t.Name); textBox1.Text = PatientId;
} button12_Click(null, null);
BtnBind1(int.Parse(PatientId), 1);
templateManage2 = null;
OperationRecord _record = operationRecor as OperationRecord;
DocumentName = "镇静镇痛评估记录_" + _record.InHospitalNo + "_" + _record.PatientId;
btnPrint_Click(null, null);
return DocumentName;
} }
/// <summary> /// <summary>
@ -240,6 +250,28 @@ namespace DrawGraphManagement
zgcAnaesRecord2.Refresh(); zgcAnaesRecord2.Refresh();
} }
private void BtnBind1(int id, int RecoverId)
{
if (textBox1.Text == "") return;
#region
operationRecor = BOperationRecord.getRecord(new OperationRecord(), id, RecoverId);
templateManage.OpeRecord = operationRecor;
//指定对象的所有值属性的绑定
templateManage.BindOperationRecordValueAll(templateManage.OpeRecord);
//非值对象的数据绑定
templateManage.Bind();
#endregion
foreach (AreaManageBase area in templateManage.ManageList)
{
area.setPrint(true);
}
zgcAnaesRecord.Refresh();
}
private void button1_Click(object sender, EventArgs e) private void button1_Click(object sender, EventArgs e)
{ {
try try
@ -600,40 +632,24 @@ namespace DrawGraphManagement
pDoc.PrintPage -= new PrintPageEventHandler(pDoc_PrintPage); pDoc.PrintPage -= new PrintPageEventHandler(pDoc_PrintPage);
pDoc.PrintPage += new PrintPageEventHandler(pDoc_PrintPage); pDoc.PrintPage += new PrintPageEventHandler(pDoc_PrintPage);
pDoc.PrinterSettings.PrintFileName = pDoc.PrinterSettings.PrintFileName =
Application.StartupPath + "\\backup.xps"; Application.StartupPath + "\\" + DocumentName + ".xps";
pDoc.PrinterSettings.PrintToFile = true; pDoc.PrinterSettings.PrintToFile = true;
pDoc.PrinterSettings.PrinterName = "XPS"; pDoc.PrinterSettings.PrinterName = "XPS";
pDoc.DefaultPageSettings.PrinterSettings.PrinterName = "Microsoft XPS Document Writer"; pDoc.DefaultPageSettings.PrinterSettings.PrinterName = "Microsoft XPS Document Writer";
pDoc.Print(); pDoc.Print();
FixedDocument2Pdf(); byte[] bytes = File.ReadAllBytes(Application.StartupPath + "\\" + DocumentName + ".xps");
// Print to PDF
var outputFilePath = @"E:\PatientDocuments\" + DocumentName + ".pdf";
PdfFilePrinter.PrintXpsToPdf(bytes, outputFilePath, "Document Title");
File.Delete(Application.StartupPath + "\\" + DocumentName + ".xps");
} }
catch (Exception exp) catch (Exception exp)
{ {
PublicMethod.WriteLog(exp, ""); PublicMethod.WriteLog(exp, "");
} }
} }
public static void FixedDocument2Pdf( )
{
//// Convert FixedDocument to XPS file in memory
//var ms = new MemoryStream();
//var package = Package.Open(ms, FileMode.Create);
//var doc = new XpsDocument(package);
//var writer = XpsDocument.CreateXpsDocumentWriter(doc);
//writer.Write(fd.DocumentPaginator);
//doc.Close();
//package.Close();
//// Get XPS file bytes
//var bytes = ms.ToArray();
//ms.Dispose();
byte[] bytes = File.ReadAllBytes( Application.StartupPath + "\\backup.xps");
// Print to PDF
var outputFilePath = @"D:\test.pdf";
PdfFilePrinter.PrintXpsToPdf(bytes, outputFilePath, "Document Title");
}
int m_startPrintPage;// 打印的起始页码 int m_startPrintPage;// 打印的起始页码
int m_endPrintPage;//打印的终止页码 int m_endPrintPage;//打印的终止页码
@ -660,74 +676,6 @@ namespace DrawGraphManagement
e.HasMorePages = false; e.HasMorePages = false;
} }
} }
//public static void ImageConvertToPdfAnes(List<System.Drawing.Image> Images, string SvaePath = @"D:\Temp.pdf")
//{
// try
// {
// System.Drawing.Image pic = Images[0];//strFilePath是该图片的绝对路径
// int intWidth = pic.Width;//长度像素值
// int intHeight = pic.Height;//高度像素值
// //pic.Dispose();
// iTextSharp.text.Rectangle pagesize = new iTextSharp.text.Rectangle(intWidth, intHeight);
// Document pdfdoc = new Document(pagesize);//建立Document对象的实例,并设置Document的大小与边距。
// PdfWriter writer = PdfWriter.GetInstance(pdfdoc, new FileStream(SvaePath, FileMode.Create)); //建立一个PdWf riter对象Writer与document对象关联,通过Writer可以将文档写入到磁盘中。
// pdfdoc.Open(); //打开文档。
// PdfContentByte cb = writer.DirectContent;
// foreach (System.Drawing.Image image in Images)
// {
// image.Save(@"D:\temp.Jpeg", ImageFormat.Jpeg);
// iTextSharp.text.Image img = iTextSharp.text.Image.GetInstance(@"D:\temp.Jpeg");
// img.SetAbsolutePosition(0, 0);
// cb.AddImage(img); //向文档中添加图像数据。
// pdfdoc.NewPage();
// }
// pdfdoc.Close(); //关闭文档,将缓冲区的内容写入磁盘以保存文件。
// }
// catch (Exception ex)
// {
// }
//}
//public void ImageConvertToPdfAnes2(string SvaePath = @"D:\Temp.pdf")
//{
// try
// {
// int intWidth = zgcAnaesRecord.Width;//长度像素值
// int intHeight = zgcAnaesRecord.Height;//高度像素值
// //pic.Dispose();
// iTextSharp.text.Rectangle pagesize = new iTextSharp.text.Rectangle(intWidth, intHeight);
// Document pdfdoc = new Document(pagesize);//建立Document对象的实例,并设置Document的大小与边距。
// PdfWriter writer = PdfWriter.GetInstance(pdfdoc, new FileStream(SvaePath, FileMode.Create)); //建立一个PdWf riter对象Writer与document对象关联,通过Writer可以将文档写入到磁盘中。
// pdfdoc.Open(); //打开文档。
// PdfContentByte cb = writer.DirectContent;
// foreach (MasterPane image in mPanes)
// {
// // 创建一个位图对象
// Bitmap bitmap = new Bitmap(intWidth, intHeight);
// // 创建一个画布对象
// Graphics g = Graphics.FromImage(bitmap);
// g.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.HighQuality;
// g.InterpolationMode = System.Drawing.Drawing2D.InterpolationMode.High;
// g.CompositingQuality = System.Drawing.Drawing2D.CompositingQuality.HighQuality;
// // 清除画布表面,填充指定的颜色
// //g.Clear(Color.White);
// image.Draw(g);
// // 释放资源
// g.Dispose();
// bitmap.Save(@"D:\temp.Jpeg", ImageFormat.Png);
// iTextSharp.text.Image img = iTextSharp.text.Image.GetInstance(@"D:\temp.Jpeg");
// img.SetAbsolutePosition(0, 0);
// cb.AddImage(img); //向文档中添加图像数据。
// pdfdoc.NewPage();
// }
// pdfdoc.Close(); //关闭文档,将缓冲区的内容写入磁盘以保存文件。
// }
// catch (Exception ex)
// {
// }
//}
public List<MasterPane> mPanes = new List<MasterPane>(); public List<MasterPane> mPanes = new List<MasterPane>();
public List<MasterPane> UpPanes = new List<MasterPane>(); public List<MasterPane> UpPanes = new List<MasterPane>();
private void PrintDocPage(object sender, PrintPageEventArgs e) private void PrintDocPage(object sender, PrintPageEventArgs e)
@ -736,19 +684,22 @@ namespace DrawGraphManagement
if (_record.currentPage == 1) if (_record.currentPage == 1)
{ {
PrintDocPane(e, zgcAnaesRecord, templateManage, true); PrintDocPane(e, zgcAnaesRecord, templateManage, true);
if (templateManage2!=null)
{
PrintDocPane(e, zgcAnaesRecord2, templateManage2, false); PrintDocPane(e, zgcAnaesRecord2, templateManage2, false);
} }
}
else else
{ {
for (int i = 1; i <= _record.pageCount; i++) for (int i = 1; i <= _record.pageCount; i++)
{ {
PrintDocPane(e, zgcAnaesRecord, templateManage, true); PrintDocPane(e, zgcAnaesRecord, templateManage, true);
if (i == 1) if (i == 1 && templateManage2!=null)
{ {
PrintDocPane(e, zgcAnaesRecord2, templateManage2, false); PrintDocPane(e, zgcAnaesRecord2, templateManage2, false);
} }
btnNextPage_Click(_record.PatientId.Value); btnNextPage_Click(_record.PatientId.Value);
if (i != 1) if (i != 1 && templateManage2!=null)
{ {
MasterPane mPane = new MasterPane(); MasterPane mPane = new MasterPane();
mPane.Border.IsVisible = false; mPane.Border.IsVisible = false;

Binary file not shown.

View File

@ -0,0 +1,168 @@
using AIMSBLL;
using AIMSModel;
using DCSoft.Writer;
using DCSoft.Writer.Data;
using DCSoft.Writer.Dom;
using DocumentManagement;
using DrawGraph;
using System;
using System.Collections.Generic;
using System.Data;
using System.Drawing;
using System.Globalization;
using System.Linq;
using System.Reflection;
using System.Runtime.InteropServices;
using System.Text.RegularExpressions;
using System.Windows.Forms;
using System.Xml;
using System.Xml.Linq;
namespace DrawGraphManagement
{
public partial class frmPrintDocument : Form
{
public int PatientId;
public string TemplateName;
//模板Model
private PrintTemplate TModel = new PrintTemplate();
//文档Model
private PrintDocument DModel = new PrintDocument();
//患者Id
public PatientRecord Patient = new PatientRecord();
public frmPrintDocument()
{
InitializeComponent();
}
private void frmPrescriptionDocument_Load(object sender, EventArgs e)
{
//myEditControl初始化
myEditControl.MoveFocusHotKey = MoveFocusHotKeys.Tab;
myEditControl.HeaderFooterReadonly = true;
myEditControl.CommandControler = this.writerCommandControler1;
writerCommandControler1.Start();
//表单视图模式
myEditControl.FormView = DCSoft.Writer.Controls.FormViewMode.Strict;
//加载知识库
//DocumentDAL.LoadKBLibaray();
myEditControl.ExecuteCommand("LoadKBLibrary", false, DocumentDAL.Lib);
// 注册自定义的输入域下拉列表提供者
myEditControl.AppHost.Services.AddService(
typeof(IListItemsProvider),
new MyListItemsProvider());
//// 设置文档处于调试模式
//myEditControl.DocumentOptions.BehaviorOptions.DebugMode = true;
//myEditControl.DocumentOptions.BehaviorOptions.InsertCommentBindingUserTrack = true;
//启用逻辑删除、权限控制
myEditControl.Document.Options.SecurityOptions.EnablePermission = true;
myEditControl.Document.Options.SecurityOptions.EnableLogicDelete = true;
myEditControl.Document.Options.SecurityOptions.ShowLogicDeletedContent = true;
myEditControl.Document.Options.SecurityOptions.ShowPermissionMark = true;
myEditControl.Document.Options.SecurityOptions.ShowPermissionTip = true;
toolStrip1.Visible = true;
Patient = PatientRecord.GetPatientRecord(PatientId);
DModel = DocumentDAL.GetDocumentbyName(TemplateName, Patient.PatientId);
LoadDocument();
}
#region
private void LoadDocument()
{
if (DModel.Id > 0)
{
//加载文档
DModel = DocumentDAL.GetDocumentbyId(DModel.Id);
myEditControl.LoadDocumentFromString(DModel.XmlFile, "xml");
//患者基本信息二次赋值
var query = from XTextElement in myEditControl.Document.Fields.ToArray()
where XTextElement is XTextInputFieldElement
&& (XTextElement as XTextInputFieldElement).FieldSettings != null
&& (XTextElement as XTextInputFieldElement).FieldSettings.EditStyle != InputFieldEditStyle.Date
&& (XTextElement as XTextInputFieldElement).FieldSettings.ListSource != null
select XTextElement as XTextInputFieldElement;
DataRow[] dr = DocumentDAL.GetReflectionList("V_OperationRecordALL").Select("KB_SEQ <> '' and Reload=1");
var p = typeof(PatientRecord).GetProperties();
for (int i = 0; i < dr.Count(); i++)
{
var name = dr[i].ItemArray[0].ToString();
var value = dr[i].ItemArray[1].ToString();
XTextInputFieldElement element = query.Where(x => x.FieldSettings.ListSource.SourceName == value).FirstOrDefault();
PropertyInfo info = p.Where(px => px.Name == name).FirstOrDefault();
if (element != null && info != null)
{
element.Text = info.GetValue(Patient, null).ToString();
}
}
}
else
{
//无文档则加载模板
TModel = DocumentDAL.GetTemplatebyId(DModel.TemplateId);
if (TModel.XmlFile == null || TModel.XmlFile.Trim().Equals(string.Empty))
{
myEditControl.ExecuteCommand("FileNew", true, null);
}
else
{
myEditControl.LoadDocumentFromString(TModel.XmlFile, "xml");
}
DModel.XmlFileName = TModel.XmlFileName;
DModel.TemplateId = TModel.Id;
//患者基本信息赋值
var query = from XTextElement in myEditControl.Document.Fields.ToArray()
where XTextElement is XTextInputFieldElement
&& (XTextElement as XTextInputFieldElement).FieldSettings != null
&& (XTextElement as XTextInputFieldElement).FieldSettings.EditStyle != InputFieldEditStyle.Date
&& (XTextElement as XTextInputFieldElement).FieldSettings.ListSource != null
select XTextElement as XTextInputFieldElement;
DataRow[] dr = DocumentDAL.GetReflectionList("V_OperationRecordALL").Select("KB_SEQ <> ''");
var p = typeof(PatientRecord).GetProperties();
for (int i = 0; i < dr.Count(); i++)
{
var name = dr[i].ItemArray[0].ToString();
var value = dr[i].ItemArray[1].ToString();
XTextInputFieldElement element = query.Where(x => x.FieldSettings.ListSource.SourceName == value).FirstOrDefault();
PropertyInfo info = p.Where(px => px.Name == name).FirstOrDefault();
if (element != null && info != null)
{
element.Text = info.GetValue(Patient, null).ToString();
}
}
DocumentExtension.SetDocumentDefaultValue(TModel.XmlFileName, myEditControl.Document, Patient);
}
//文档用户信息
myEditControl.UserLoginByParameter(
AIMSExtension.PublicMethod.OperatorNo,
AIMSExtension.PublicMethod.OperatorName,
AIMSExtension.PublicMethod.PermissionLevel);
//隐藏痕迹先
myEditControl.ExecuteCommand(StandardCommandNames.CleanViewMode, false, true);
}
#endregion
private void tsbAdd_Click(object sender, EventArgs e)
{
myEditControl.ExecuteCommand("FilePrint", true, null);
}
private void tsbExit_Click(object sender, EventArgs e)
{
this.Close();
}
public string PrintDocument()
{
string docName = TemplateName + "_" + Patient.MdrecNo + "_" + Patient.PatientId;
//myEditControl.ExecuteCommand("FilePrint", true, null);
var outputFilePath = @"E:\PatientDocuments\" +docName + ".pdf";
myEditControl.SaveDocument(outputFilePath, "pdf");
return docName;
}
}
}

View File

@ -0,0 +1,131 @@
namespace DrawGraphManagement
{
partial class frmPrintDocument
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
this.toolStrip1 = new System.Windows.Forms.ToolStrip();
this.tsbAdd = new System.Windows.Forms.ToolStripButton();
this.toolStripSeparator4 = new System.Windows.Forms.ToolStripSeparator();
this.tsbExit = new System.Windows.Forms.ToolStripButton();
this.writerCommandControler1 = new DCSoft.Writer.Commands.WriterCommandControler(this.components);
this.panel2 = new System.Windows.Forms.Panel();
this.myEditControl = new DCSoft.Writer.Controls.WriterControl();
this.toolStrip1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.writerCommandControler1)).BeginInit();
this.panel2.SuspendLayout();
this.SuspendLayout();
//
// toolStrip1
//
this.toolStrip1.Font = new System.Drawing.Font("微软雅黑", 10.5F);
this.toolStrip1.ImageScalingSize = new System.Drawing.Size(25, 25);
this.toolStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.tsbAdd,
this.toolStripSeparator4,
this.tsbExit});
this.toolStrip1.Location = new System.Drawing.Point(0, 0);
this.toolStrip1.Name = "toolStrip1";
this.toolStrip1.Size = new System.Drawing.Size(624, 25);
this.toolStrip1.TabIndex = 9;
this.toolStrip1.Text = "toolStrip1";
//
// tsbAdd
//
this.tsbAdd.Font = new System.Drawing.Font("微软雅黑", 9F);
this.tsbAdd.ImageTransparentColor = System.Drawing.Color.Transparent;
this.tsbAdd.Name = "tsbAdd";
this.tsbAdd.Size = new System.Drawing.Size(44, 22);
this.tsbAdd.Text = " 打印";
this.tsbAdd.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
this.tsbAdd.Click += new System.EventHandler(this.tsbAdd_Click);
//
// toolStripSeparator4
//
this.toolStripSeparator4.Name = "toolStripSeparator4";
this.toolStripSeparator4.Size = new System.Drawing.Size(6, 25);
//
// tsbExit
//
this.tsbExit.Font = new System.Drawing.Font("微软雅黑", 9F);
this.tsbExit.ImageTransparentColor = System.Drawing.Color.Transparent;
this.tsbExit.Name = "tsbExit";
this.tsbExit.Size = new System.Drawing.Size(52, 22);
this.tsbExit.Text = " 关闭 ";
this.tsbExit.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
this.tsbExit.Click += new System.EventHandler(this.tsbExit_Click);
//
// panel2
//
this.panel2.Controls.Add(this.myEditControl);
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(0, 25);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(624, 856);
this.panel2.TabIndex = 11;
//
// myEditControl
//
this.myEditControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.myEditControl.Location = new System.Drawing.Point(0, 0);
this.myEditControl.Name = "myEditControl";
this.myEditControl.Size = new System.Drawing.Size(624, 856);
this.myEditControl.TabIndex = 7;
//
// frmPrintDocument
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(624, 881);
this.Controls.Add(this.panel2);
this.Controls.Add(this.toolStrip1);
this.Name = "frmPrintDocument";
this.ShowIcon = false;
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "文书打印";
this.Load += new System.EventHandler(this.frmPrescriptionDocument_Load);
this.toolStrip1.ResumeLayout(false);
this.toolStrip1.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.writerCommandControler1)).EndInit();
this.panel2.ResumeLayout(false);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
public System.Windows.Forms.ToolStrip toolStrip1;
private System.Windows.Forms.ToolStripButton tsbAdd;
private System.Windows.Forms.ToolStripSeparator toolStripSeparator4;
public System.Windows.Forms.ToolStripButton tsbExit;
private DCSoft.Writer.Commands.WriterCommandControler writerCommandControler1;
private System.Windows.Forms.Panel panel2;
private DCSoft.Writer.Controls.WriterControl myEditControl;
}
}

View File

@ -0,0 +1,126 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="toolStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="writerCommandControler1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>563, 17</value>
</metadata>
</root>