Пример #1
0
 /// <summary>
 /// 将符合条件的未归档病人病历归档
 /// </summary>
 /// <auth>Yanqiao.Cai</auth>
 /// <date>2012-12-23</date>
 /// <param name="noofinpat"></param>
 public static void SetRecordsRebacked(int noofinpat)
 {
     try
     {
         DataTable dt = DS_SqlService.GetAllRecordsByNoofinpat(noofinpat);
         if (null == dt || dt.Rows.Count == 0)
         {
             DrectSoft.Common.Ctrs.DLG.MyMessageBox.Show("该病人没有病历,无法归档。");
             return;
         }
         if (DrectSoft.Common.Ctrs.DLG.MyMessageBox.Show("您是否要归档该病历?", "归档病历", DrectSoft.Common.Ctrs.DLG.MyMessageBoxButtons.YesNo) == DialogResult.No)
         {
             return;
         }
         if (CheckRecordRebacked(noofinpat.ToString()))
         {
             int num = DS_SqlService.SetRecordsRebacked(noofinpat.ToString());
             if (num > 0)
             {
                 DrectSoft.Common.Ctrs.DLG.MyMessageBox.Show("归档成功");
                 return;
             }
         }
         DrectSoft.Common.Ctrs.DLG.MyMessageBox.Show("该病人已归档。");
     }
     catch (Exception ex)
     {
         throw new Exception(ex.Message);
     }
 }