|
@@ -27,9 +27,10 @@ namespace PTMedicalInsurance.Forms
|
|
|
public string patInfo = "", ReadCardOutParam = "", CertNo = "";
|
|
public string patInfo = "", ReadCardOutParam = "", CertNo = "";
|
|
|
public string presAdmLoc = "", presAdmDoc = "", presAdmID = "", presNo = "", hiRxno = "";
|
|
public string presAdmLoc = "", presAdmDoc = "", presAdmID = "", presNo = "", hiRxno = "";
|
|
|
public string DrCode = "", DrName = "", DrInsuCode = "", DrCertNo = "";
|
|
public string DrCode = "", DrName = "", DrInsuCode = "", DrCertNo = "";
|
|
|
|
|
+ public string IID;
|
|
|
|
|
|
|
|
- //1.声明自适应类实例
|
|
|
|
|
- AutoResizeForm asc = new AutoResizeForm();
|
|
|
|
|
|
|
+ //1.声明自适应类实例
|
|
|
|
|
+ AutoResizeForm asc = new AutoResizeForm();
|
|
|
private InvokeHelper invoker = new InvokeHelper();
|
|
private InvokeHelper invoker = new InvokeHelper();
|
|
|
private HisIrisServices hIS = new HisIrisServices();
|
|
private HisIrisServices hIS = new HisIrisServices();
|
|
|
private MIIrisServices mIS = new MIIrisServices();
|
|
private MIIrisServices mIS = new MIIrisServices();
|
|
@@ -42,8 +43,38 @@ namespace PTMedicalInsurance.Forms
|
|
|
asc.controllInitializeSize(this);
|
|
asc.controllInitializeSize(this);
|
|
|
asc.controlAutoSize(this);
|
|
asc.controlAutoSize(this);
|
|
|
}
|
|
}
|
|
|
|
|
+ public MedInsuQuery(JObject jo)
|
|
|
|
|
+ {
|
|
|
|
|
+ InitializeComponent();
|
|
|
|
|
+ Global.pat.certNO = JsonHelper.getDestValue(jo, "idNo");
|
|
|
|
|
+ IID = JsonHelper.getDestValue(jo, "idNo");
|
|
|
|
|
+ if (!string.IsNullOrEmpty(Global.pat.admID))
|
|
|
|
|
+ {
|
|
|
|
|
+ string hisPatBaseInfo = "";
|
|
|
|
|
+
|
|
|
|
|
+ if (hIS.GetHisPatBaseInfo(out hisPatBaseInfo) != 0)
|
|
|
|
|
+ {
|
|
|
|
|
|
|
|
- public MedInsuQuery( int iPage)
|
|
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ //jaVolaItems = JArray.Parse(JsonHelper.getDestValue(jo, "output.result"));
|
|
|
|
|
+ //dtVolaItems = (DataTable)jo["output"]["result"].ToObject(typeof(DataTable));
|
|
|
|
|
+ //dgvVolaItems.DataSource = dtVolaItems;
|
|
|
|
|
+ //grdSetter.SetHeaderTextOfPAIPAVolaItem(dgvVolaItems);
|
|
|
|
|
+ //tbJrID.Text = JsonHelper.getDestValue(jo, "output.result[0].jr_id");
|
|
|
|
|
+ //tbRuleID.Text = JsonHelper.getDestValue(jo, "output.result[0].rule_id");
|
|
|
|
|
+ //tbPatID.Text = JsonHelper.getDestValue(jo, "output.result[0].patn_id");
|
|
|
|
|
+ //tbMdtrdID.Text = JsonHelper.getDestValue(jo, "output.result[0].mdtrt_id");
|
|
|
|
|
+ //tbVolaAmt.Text = JsonHelper.getDestValue(jo, "output.result[0].vola_amt");
|
|
|
|
|
+ //tbVolaAmtStas.Text = JsonHelper.getDestValue(jo, "output.result[0].vola_amt_stas");
|
|
|
|
|
+ //tbSevDeg.Text = JsonHelper.getDestValue(jo, "output.result[0].sev_deg");
|
|
|
|
|
+ //tbVolaBhvrType.Text = JsonHelper.getDestValue(jo, "output.result[0].vola_bhvr_type");
|
|
|
|
|
+ //tbVolaEvid.Text = JsonHelper.getDestValue(jo, "output.result[0].vola_evid");
|
|
|
|
|
+ //tbRuleName.Text = JsonHelper.getDestValue(jo, "output.result[0].rule_name");
|
|
|
|
|
+ //rbtVolaContent.Text = JsonHelper.getDestValue(jo, "output.result[0].vola_cont");
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ public MedInsuQuery(int iPage)
|
|
|
{
|
|
{
|
|
|
InitializeComponent();
|
|
InitializeComponent();
|
|
|
|
|
|
|
@@ -54,7 +85,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
private void btnClose_Click(object sender, EventArgs e)
|
|
private void btnClose_Click(object sender, EventArgs e)
|
|
|
- {
|
|
|
|
|
|
|
+ {
|
|
|
this.Close();
|
|
this.Close();
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -62,7 +93,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
{
|
|
{
|
|
|
//this.WindowState = FormWindowState.Maximized;
|
|
//this.WindowState = FormWindowState.Maximized;
|
|
|
|
|
|
|
|
- tbcMain.SelectedIndex = 1;
|
|
|
|
|
|
|
+ tbcMain.SelectedIndex = 6;
|
|
|
|
|
|
|
|
dpST.Text = DateTime.Now.ToString("yyyy-MM-dd 00:00:00");
|
|
dpST.Text = DateTime.Now.ToString("yyyy-MM-dd 00:00:00");
|
|
|
dpED.Text = DateTime.Now.ToString("yyyy-MM-dd 23:59:59");
|
|
dpED.Text = DateTime.Now.ToString("yyyy-MM-dd 23:59:59");
|
|
@@ -82,8 +113,8 @@ namespace PTMedicalInsurance.Forms
|
|
|
DT_ST1.Text = DateTime.Now.ToString("yyyy-MM-dd 00:00:00");
|
|
DT_ST1.Text = DateTime.Now.ToString("yyyy-MM-dd 00:00:00");
|
|
|
DT_ET1.Text = DateTime.Now.ToString("yyyy-MM-dd 23:59:59");
|
|
DT_ET1.Text = DateTime.Now.ToString("yyyy-MM-dd 23:59:59");
|
|
|
|
|
|
|
|
- dptST.Text = DateTime.Now.ToString("yyyy-MM-01 00:00:00");
|
|
|
|
|
- dptET.Text = DateTime.Now.ToString("yyyy-MM-31 23:59:59");
|
|
|
|
|
|
|
+ dptST.Text = DateTime.Now.AddDays(-30).ToString("yyyy-MM-dd 00:00:00");
|
|
|
|
|
+ dptET.Text = DateTime.Now.ToString("yyyy-MM-dd 23:59:59");
|
|
|
|
|
|
|
|
dtTHSJ.Text = DateTime.Now.ToString();
|
|
dtTHSJ.Text = DateTime.Now.ToString();
|
|
|
|
|
|
|
@@ -99,7 +130,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
|
|
|
|
|
grdSetter.SetHeaderTextOfSettlList(dgvSettleData);
|
|
grdSetter.SetHeaderTextOfSettlList(dgvSettleData);
|
|
|
grdSetter.SetHeaderTextOfSettltMentFeelDetailInfo(dgvFeeInfo);
|
|
grdSetter.SetHeaderTextOfSettltMentFeelDetailInfo(dgvFeeInfo);
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
grdSetter.SetHeaderTextOfHISRegister(dgv_HISRegInfo);
|
|
grdSetter.SetHeaderTextOfHISRegister(dgv_HISRegInfo);
|
|
|
grdSetter.SetHeaderTextOfHISPrescFee(dgv_PrescriptionInfo);
|
|
grdSetter.SetHeaderTextOfHISPrescFee(dgv_PrescriptionInfo);
|
|
|
grdSetter.SetHeaderTextOfBillInfo(dgv_BillInfo);
|
|
grdSetter.SetHeaderTextOfBillInfo(dgv_BillInfo);
|
|
@@ -116,7 +147,14 @@ namespace PTMedicalInsurance.Forms
|
|
|
|
|
|
|
|
rbg_Type.SelectedIndex = 0;
|
|
rbg_Type.SelectedIndex = 0;
|
|
|
tbJGBM.Text = Global.inf.hospitalNO;
|
|
tbJGBM.Text = Global.inf.hospitalNO;
|
|
|
- dtTHSJ.Text= DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
|
|
|
|
|
|
+ dtTHSJ.Text = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
|
|
|
|
+
|
|
|
|
|
+ if (!string.IsNullOrEmpty(IID))
|
|
|
|
|
+ {
|
|
|
|
|
+ tbcMain.TabPages.Clear();
|
|
|
|
|
+ tbcMain.TabPages.Add(tab5205);
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
private void btnQuery_Click(object sender, EventArgs e)
|
|
private void btnQuery_Click(object sender, EventArgs e)
|
|
@@ -125,7 +163,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
string sCZYXM = Global.user.name;
|
|
string sCZYXM = Global.user.name;
|
|
|
|
|
|
|
|
string SqlHeard = " Adm_Dr,MdtrtID,Name as PatientName,Age,PsnCertNO,Gend,PsnType,EmpName,AdmInDepName,insuplcAdmdvs,sZYZT AS sZTSM, "
|
|
string SqlHeard = " Adm_Dr,MdtrtID,Name as PatientName,Age,PsnCertNO,Gend,PsnType,EmpName,AdmInDepName,insuplcAdmdvs,sZYZT AS sZTSM, "
|
|
|
- + " AdmBed,RegDate,MainDiagName,AttendDoctorNO,ChiefPhyDocName,'"+ sCZYXM+ "' as OpertName,'' as InHospNo,''Address ";
|
|
|
|
|
|
|
+ + " AdmBed,RegDate,MainDiagName,AttendDoctorNO,ChiefPhyDocName,'" + sCZYXM + "' as OpertName,'' as InHospNo,''Address ";
|
|
|
|
|
|
|
|
string SqlStrMain = " SELECT a.*,b.*,a.PatientName AS Name,a.PsnType AS PsnTypeCode,'在院' sZYZT FROM BS_MIPatCurrentInsuInfo a LEFT JOIN BS_MedInsuRegisterInfo b "
|
|
string SqlStrMain = " SELECT a.*,b.*,a.PatientName AS Name,a.PsnType AS PsnTypeCode,'在院' sZYZT FROM BS_MIPatCurrentInsuInfo a LEFT JOIN BS_MedInsuRegisterInfo b "
|
|
|
+ " ON a.MdtrtID=b.InsuRegID AND a.Interface_Dr=b.Interface_Dr AND a.Hospital_Dr=b.Hospital_Dr "
|
|
+ " ON a.MdtrtID=b.InsuRegID AND a.Interface_Dr=b.Interface_Dr AND a.Hospital_Dr=b.Hospital_Dr "
|
|
@@ -137,10 +175,10 @@ namespace PTMedicalInsurance.Forms
|
|
|
+ " FROM BS_MIPatCurrentInsuInfo a LEFT JOIN BS_MedInsuRegisterInfo b "
|
|
+ " FROM BS_MIPatCurrentInsuInfo a LEFT JOIN BS_MedInsuRegisterInfo b "
|
|
|
+ " ON a.MdtrtID=b.InsuRegID AND a.Interface_Dr=b.Interface_Dr AND a.Hospital_Dr=b.Hospital_Dr "
|
|
+ " ON a.MdtrtID=b.InsuRegID AND a.Interface_Dr=b.Interface_Dr AND a.Hospital_Dr=b.Hospital_Dr "
|
|
|
+ " LEFT JOIN BS_MedInsuSettlement c ON a.MdtrtID=b.InsuRegID AND b.InsuRegID=c.MdtrtID AND a.Interface_Dr=b.Interface_Dr AND b.Interface_Dr=c.Interface_Dr "
|
|
+ " LEFT JOIN BS_MedInsuSettlement c ON a.MdtrtID=b.InsuRegID AND b.InsuRegID=c.MdtrtID AND a.Interface_Dr=b.Interface_Dr AND b.Interface_Dr=c.Interface_Dr "
|
|
|
- + " WHERE b.Type=1 AND b.ValidFlag=1 AND c.BillType=1 AND b.Hospital_Dr= " + Global.inf.hospitalDr + " AND b.Interface_Dr= " + Global.inf.interfaceDr
|
|
|
|
|
|
|
+ + " WHERE b.Type=1 AND b.ValidFlag=1 AND c.BillType=1 AND b.Hospital_Dr= " + Global.inf.hospitalDr + " AND b.Interface_Dr= " + Global.inf.interfaceDr
|
|
|
+ " AND c.AdmType=2 AND c.SettlementDateTime<='" + dpED.Text + "' AND c.SettlementDateTime>'" + dpST.Text + "' "; //
|
|
+ " AND c.AdmType=2 AND c.SettlementDateTime<='" + dpED.Text + "' AND c.SettlementDateTime>'" + dpST.Text + "' "; //
|
|
|
|
|
|
|
|
- string sqlStr = " SELECT "+ SqlHeard + " FROM ("+ SqlStrMain +") M ";
|
|
|
|
|
|
|
+ string sqlStr = " SELECT " + SqlHeard + " FROM (" + SqlStrMain + ") M ";
|
|
|
|
|
|
|
|
//MessageBox.Show(sqlStr);
|
|
//MessageBox.Show(sqlStr);
|
|
|
|
|
|
|
@@ -178,7 +216,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
{
|
|
{
|
|
|
string BedNo, BedDocName, InHospNo, Address;
|
|
string BedNo, BedDocName, InHospNo, Address;
|
|
|
JObject joTmp = new JObject();
|
|
JObject joTmp = new JObject();
|
|
|
- joTmp.Add("admID", dt.Rows[i]["Adm_Dr"].ToString());
|
|
|
|
|
|
|
+ joTmp.Add("admID", dt.Rows[i]["Adm_Dr"].ToString());
|
|
|
JObject joRtn2 = invoker.invokeHISService(JsonHelper.setIrisInpar("05110014", joTmp).ToString(), "获取患者就诊信息");
|
|
JObject joRtn2 = invoker.invokeHISService(JsonHelper.setIrisInpar("05110014", joTmp).ToString(), "获取患者就诊信息");
|
|
|
if (JsonHelper.parseIrisRtnValue(joRtn2, out string errMsg) == 0)
|
|
if (JsonHelper.parseIrisRtnValue(joRtn2, out string errMsg) == 0)
|
|
|
{
|
|
{
|
|
@@ -190,10 +228,10 @@ namespace PTMedicalInsurance.Forms
|
|
|
dt.Rows[i]["AttendDoctorNO"] = BedDocName;
|
|
dt.Rows[i]["AttendDoctorNO"] = BedDocName;
|
|
|
dt.Rows[i]["InHospNo"] = InHospNo;
|
|
dt.Rows[i]["InHospNo"] = InHospNo;
|
|
|
dt.Rows[i]["Address"] = Address;
|
|
dt.Rows[i]["Address"] = Address;
|
|
|
- }
|
|
|
|
|
|
|
+ }
|
|
|
else
|
|
else
|
|
|
{
|
|
{
|
|
|
- if (errMsg.IndexOf("请重新登录") > 0)
|
|
|
|
|
|
|
+ if (errMsg.IndexOf("请重新登录") > 0)
|
|
|
{
|
|
{
|
|
|
MessageBox.Show("获取患者信息失败,请重新登录系统!");
|
|
MessageBox.Show("获取患者信息失败,请重新登录系统!");
|
|
|
break;
|
|
break;
|
|
@@ -206,7 +244,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
private void btnPrint_Click(object sender, EventArgs e)
|
|
private void btnPrint_Click(object sender, EventArgs e)
|
|
|
{
|
|
{
|
|
|
string LSH = DateTime.Now.ToString("yyyy-MM-dd"); //DateTime.Now.ToString("MMddHHmmssffff");
|
|
string LSH = DateTime.Now.ToString("yyyy-MM-dd"); //DateTime.Now.ToString("MMddHHmmssffff");
|
|
|
- string sFliePathName = @"C:\Users\Administrator\Desktop\" + LSH + "医保在院患者登记或结算信息.xls";
|
|
|
|
|
|
|
+ string sFliePathName = @"C:\Users\Administrator\Desktop\" + LSH + "医保在院患者登记或结算信息.xls";
|
|
|
string ReturnFileName = ExportToExcel.DataTabletoExcel(dtExport, sFliePathName);
|
|
string ReturnFileName = ExportToExcel.DataTabletoExcel(dtExport, sFliePathName);
|
|
|
if (ReturnFileName != "")
|
|
if (ReturnFileName != "")
|
|
|
{
|
|
{
|
|
@@ -298,7 +336,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
sqlstr = sqlstr + " and a.OccurTime<'" + DT_ET1.Text + "'";
|
|
sqlstr = sqlstr + " and a.OccurTime<'" + DT_ET1.Text + "'";
|
|
|
sqlstr = sqlstr + " and a.Interface_Dr='" + Global.inf.interfaceDr + "'";
|
|
sqlstr = sqlstr + " and a.Interface_Dr='" + Global.inf.interfaceDr + "'";
|
|
|
|
|
|
|
|
- if (tb_CertNo.Text!="")
|
|
|
|
|
|
|
+ if (tb_CertNo.Text != "")
|
|
|
sqlstr = sqlstr + " and a.CertificateNO='" + tb_CertNo.Text + "'";
|
|
sqlstr = sqlstr + " and a.CertificateNO='" + tb_CertNo.Text + "'";
|
|
|
|
|
|
|
|
JObject joSqlstr = new JObject();
|
|
JObject joSqlstr = new JObject();
|
|
@@ -350,7 +388,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
joData.Add("certno", certno);
|
|
joData.Add("certno", certno);
|
|
|
joData.Add("psn_name", psn_name);
|
|
joData.Add("psn_name", psn_name);
|
|
|
joData.Add("gend", gend);
|
|
joData.Add("gend", gend);
|
|
|
- joData.Add("naty", naty);
|
|
|
|
|
|
|
+ joData.Add("naty", naty);
|
|
|
joData.Add("brdy", brdy);
|
|
joData.Add("brdy", brdy);
|
|
|
joData.Add("age", age);
|
|
joData.Add("age", age);
|
|
|
joData.Add("balc", balc);
|
|
joData.Add("balc", balc);
|
|
@@ -394,7 +432,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
|
|
|
|
|
JObject joSqlstr = new JObject();
|
|
JObject joSqlstr = new JObject();
|
|
|
joSqlstr.Add("sqlStr", sqlStr);
|
|
joSqlstr.Add("sqlStr", sqlStr);
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
JArray jaParam = new JArray();
|
|
JArray jaParam = new JArray();
|
|
|
jaParam.Add(joSqlstr);
|
|
jaParam.Add(joSqlstr);
|
|
|
JObject joSettlQuery = new JObject();
|
|
JObject joSettlQuery = new JObject();
|
|
@@ -435,7 +473,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- int iCenter = dgvSettleData.CurrentRow.Index;
|
|
|
|
|
|
|
+ int iCenter = dgvSettleData.CurrentRow.Index;
|
|
|
Global.pat.mdtrtID = dgvSettleData.Rows[iCenter].Cells["MdtrtID"].Value.ToString();
|
|
Global.pat.mdtrtID = dgvSettleData.Rows[iCenter].Cells["MdtrtID"].Value.ToString();
|
|
|
Global.pat.medType = dgvSettleData.Rows[iCenter].Cells["MedicalType"].Value.ToString();
|
|
Global.pat.medType = dgvSettleData.Rows[iCenter].Cells["MedicalType"].Value.ToString();
|
|
|
Global.pat.psn_no = dgvSettleData.Rows[iCenter].Cells["PersonnelNO"].Value.ToString();
|
|
Global.pat.psn_no = dgvSettleData.Rows[iCenter].Cells["PersonnelNO"].Value.ToString();
|
|
@@ -443,7 +481,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
Global.pat.billID = dgvSettleData.Rows[iCenter].Cells["BillID"].Value.ToString();
|
|
Global.pat.billID = dgvSettleData.Rows[iCenter].Cells["BillID"].Value.ToString();
|
|
|
Global.pat.recordID = dgvSettleData.Rows[iCenter].Cells["RecordID"].Value.ToString();
|
|
Global.pat.recordID = dgvSettleData.Rows[iCenter].Cells["RecordID"].Value.ToString();
|
|
|
Global.pat.certNO = dgvSettleData.Rows[iCenter].Cells["CertificateNO"].Value.ToString();
|
|
Global.pat.certNO = dgvSettleData.Rows[iCenter].Cells["CertificateNO"].Value.ToString();
|
|
|
- Global.pat.name= dgvSettleData.Rows[iCenter].Cells["PatientName"].Value.ToString();
|
|
|
|
|
|
|
+ Global.pat.name = dgvSettleData.Rows[iCenter].Cells["PatientName"].Value.ToString();
|
|
|
|
|
|
|
|
Global.pat.brdy = dgvSettleData.Rows[iCenter].Cells["BirthDay"].Value.ToString();
|
|
Global.pat.brdy = dgvSettleData.Rows[iCenter].Cells["BirthDay"].Value.ToString();
|
|
|
Global.pat.gend = dgvSettleData.Rows[iCenter].Cells["Gender"].Value.ToString();
|
|
Global.pat.gend = dgvSettleData.Rows[iCenter].Cells["Gender"].Value.ToString();
|
|
@@ -564,7 +602,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
{
|
|
{
|
|
|
if ((joRtn["result"].ToString() == "[]") || (joRtn["result"].ToString() == ""))
|
|
if ((joRtn["result"].ToString() == "[]") || (joRtn["result"].ToString() == ""))
|
|
|
{
|
|
{
|
|
|
- MessageBox.Show("调用HIS接口服务05110038获取处方号【"+ presNo + "】门诊处方风险提示参数结果为空!");
|
|
|
|
|
|
|
+ MessageBox.Show("调用HIS接口服务05110038获取处方号【" + presNo + "】门诊处方风险提示参数结果为空!");
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -597,7 +635,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
/// </summary>
|
|
/// </summary>
|
|
|
/// <param name="param"></param>
|
|
/// <param name="param"></param>
|
|
|
/// <returns></returns>
|
|
/// <returns></returns>
|
|
|
- public string GetPsnType(string param)
|
|
|
|
|
|
|
+ public string GetPsnType(string param)
|
|
|
{
|
|
{
|
|
|
if ((param == "11") || (param == "11021") || (param == "11031") ||
|
|
if ((param == "11") || (param == "11021") || (param == "11031") ||
|
|
|
(param == "1101") || (param == "1102") || (param == "1103") ||
|
|
(param == "1101") || (param == "1102") || (param == "1103") ||
|
|
@@ -712,7 +750,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
else
|
|
else
|
|
|
if ((param == "16") || (param == "160104") || (param == "140805") ||
|
|
if ((param == "16") || (param == "160104") || (param == "140805") ||
|
|
|
(param == "160100") || (param == "160101") || (param == "160102") ||
|
|
(param == "160100") || (param == "160101") || (param == "160102") ||
|
|
|
- (param == "160103"))
|
|
|
|
|
|
|
+ (param == "160103"))
|
|
|
return "1025113"; //居民(老年)
|
|
return "1025113"; //居民(老年)
|
|
|
else
|
|
else
|
|
|
return "1025111"; //居民(成年)
|
|
return "1025111"; //居民(成年)
|
|
@@ -747,7 +785,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
return 0;
|
|
return 0;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- public string GetInsuFeeInfo(string admID, string InsuCode)
|
|
|
|
|
|
|
+ public string GetInsuFeeInfo(string admID, string InsuCode)
|
|
|
{
|
|
{
|
|
|
string sqlStr;
|
|
string sqlStr;
|
|
|
sqlStr = " SELECT admID as Adm_Dr,'' as Name,''as HISCode,MedInsuNO,Price,Sumamt, ";
|
|
sqlStr = " SELECT admID as Adm_Dr,'' as Name,''as HISCode,MedInsuNO,Price,Sumamt, ";
|
|
@@ -769,9 +807,9 @@ namespace PTMedicalInsurance.Forms
|
|
|
decimal SelfPayProp = decimal.Parse(JsonHelper.getDestValue(joRtn, "result.data[0].SelfPayProp"));
|
|
decimal SelfPayProp = decimal.Parse(JsonHelper.getDestValue(joRtn, "result.data[0].SelfPayProp"));
|
|
|
|
|
|
|
|
//1007100-医保个人,1007200-医保统筹,1007300-现金
|
|
//1007100-医保个人,1007200-医保统筹,1007300-现金
|
|
|
- if (SelfPayProp == 0)
|
|
|
|
|
- return "1007200";
|
|
|
|
|
- else
|
|
|
|
|
|
|
+ if (SelfPayProp == 0)
|
|
|
|
|
+ return "1007200";
|
|
|
|
|
+ else
|
|
|
return "1007300";
|
|
return "1007300";
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -798,7 +836,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
string billCode = dgv_BillInfo.Rows[dgv_BillInfo.CurrentRow.Index].Cells["billCode"].Value.ToString();
|
|
string billCode = dgv_BillInfo.Rows[dgv_BillInfo.CurrentRow.Index].Cells["billCode"].Value.ToString();
|
|
|
string billTime = dgv_BillInfo.Rows[dgv_BillInfo.CurrentRow.Index].Cells["billTime"].Value.ToString();
|
|
string billTime = dgv_BillInfo.Rows[dgv_BillInfo.CurrentRow.Index].Cells["billTime"].Value.ToString();
|
|
|
string InsuredType = dgv_BillInfo.Rows[dgv_BillInfo.CurrentRow.Index].Cells["participateType"].Value.ToString(); //险种类型
|
|
string InsuredType = dgv_BillInfo.Rows[dgv_BillInfo.CurrentRow.Index].Cells["participateType"].Value.ToString(); //险种类型
|
|
|
- string admID = dgv_BillInfo.Rows[dgv_BillInfo.CurrentRow.Index].Cells["admID"].Value.ToString();
|
|
|
|
|
|
|
+ string admID = dgv_BillInfo.Rows[dgv_BillInfo.CurrentRow.Index].Cells["admID"].Value.ToString();
|
|
|
|
|
|
|
|
if (InsuredType.Substring(0, 2) == "31")
|
|
if (InsuredType.Substring(0, 2) == "31")
|
|
|
{
|
|
{
|
|
@@ -822,8 +860,8 @@ namespace PTMedicalInsurance.Forms
|
|
|
joData["participateType"] = participateType;
|
|
joData["participateType"] = participateType;
|
|
|
joData["personnelType"] = personnelType;
|
|
joData["personnelType"] = personnelType;
|
|
|
|
|
|
|
|
- JArray jaFeeDetail = JArray.Parse(JsonHelper.getDestValue(joInput20002, "result[0].detail"));
|
|
|
|
|
-
|
|
|
|
|
|
|
+ JArray jaFeeDetail = JArray.Parse(JsonHelper.getDestValue(joInput20002, "result[0].detail"));
|
|
|
|
|
+
|
|
|
//for (int i = 0; i < jaFeeDetail.Count; i++)
|
|
//for (int i = 0; i < jaFeeDetail.Count; i++)
|
|
|
//{
|
|
//{
|
|
|
// string InsuCode = jaFeeDetail[i]["medicalDrugId"].ToString();
|
|
// string InsuCode = jaFeeDetail[i]["medicalDrugId"].ToString();
|
|
@@ -854,7 +892,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
|
|
|
|
|
private void dgv_BillInfo_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
|
|
private void dgv_BillInfo_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
|
|
|
{
|
|
{
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
private void uiButton19_Click(object sender, EventArgs e)
|
|
private void uiButton19_Click(object sender, EventArgs e)
|
|
@@ -865,7 +903,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
MessageBox.Show("请查询患者参保信息");
|
|
MessageBox.Show("请查询患者参保信息");
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
for (int i = 0; i < dgv_4001.Rows.Count; i++)
|
|
for (int i = 0; i < dgv_4001.Rows.Count; i++)
|
|
|
{
|
|
{
|
|
|
//int iCenter = dgv_4001.CurrentRow.Index;
|
|
//int iCenter = dgv_4001.CurrentRow.Index;
|
|
@@ -1082,7 +1120,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
{
|
|
{
|
|
|
MessageBox.Show("门诊处方风险提示上传失败:" + errorMsg);
|
|
MessageBox.Show("门诊处方风险提示上传失败:" + errorMsg);
|
|
|
return;
|
|
return;
|
|
|
- }
|
|
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -1165,6 +1203,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
private void btnReadCard_Click(object sender, EventArgs e)
|
|
private void btnReadCard_Click(object sender, EventArgs e)
|
|
|
{
|
|
{
|
|
|
string outParam = "", errMsg = "";
|
|
string outParam = "", errMsg = "";
|
|
|
|
|
+
|
|
|
if (hBus.readCard(out outParam) != 0)
|
|
if (hBus.readCard(out outParam) != 0)
|
|
|
{
|
|
{
|
|
|
MessageBox.Show("读卡失败!" + outParam);
|
|
MessageBox.Show("读卡失败!" + outParam);
|
|
@@ -1186,7 +1225,7 @@ namespace PTMedicalInsurance.Forms
|
|
|
{
|
|
{
|
|
|
MessageBox.Show("setGlobalPatAfaterShowPatInfo全局变量赋值异常!" + errMsg);
|
|
MessageBox.Show("setGlobalPatAfaterShowPatInfo全局变量赋值异常!" + errMsg);
|
|
|
return;
|
|
return;
|
|
|
- }
|
|
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -1194,21 +1233,56 @@ namespace PTMedicalInsurance.Forms
|
|
|
private void btn5205_Click(object sender, EventArgs e)
|
|
private void btn5205_Click(object sender, EventArgs e)
|
|
|
{
|
|
{
|
|
|
string outParam = "", errMsg = "";
|
|
string outParam = "", errMsg = "";
|
|
|
|
|
+ JObject joData = new JObject();
|
|
|
|
|
+ JObject joInput = new JObject();
|
|
|
|
|
+ JObject joRtn = new JObject();
|
|
|
|
|
+ string errorMsg = "";
|
|
|
|
|
+ if (string.IsNullOrEmpty(Global.pat.psn_no))
|
|
|
|
|
+ {
|
|
|
|
|
+ joData.Add("mdtrt_cert_type", "02");
|
|
|
|
|
+ joData.Add("mdtrt_cert_no", Global.pat.certNO);
|
|
|
|
|
+ joData.Add("card_sn","");
|
|
|
|
|
+ joData.Add("begntime", DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"));
|
|
|
|
|
+ joData.Add("psn_cert_type", "01");
|
|
|
|
|
+ joData.Add("certno", Global.pat.certNO); //证件号码
|
|
|
|
|
+ joData.Add("psn_name", Global.pat.name);
|
|
|
|
|
+
|
|
|
|
|
+ joInput.Add("data", joData);
|
|
|
|
|
+
|
|
|
|
|
+ joRtn = invoker.invokeCenterService("1101", JsonHelper.setCenterInpar("1101", joInput));
|
|
|
|
|
+ if (JsonHelper.parseCenterRtnValue(joRtn, out errorMsg) != 0)
|
|
|
|
|
+ {
|
|
|
|
|
+ outParam = "获取病人参保信息失败:" + errorMsg;
|
|
|
|
|
+
|
|
|
|
|
+ }
|
|
|
|
|
+ else
|
|
|
|
|
+ {
|
|
|
|
|
+ //joRtn.Add("cardinfo",joCardInfo);
|
|
|
|
|
+
|
|
|
|
|
+ outParam = joRtn.ToString();
|
|
|
|
|
+ Global.pat.insuplc_admdvs = JsonHelper.getDestValue(JObject.Parse(outParam), "output.insuinfo.insuplc_admdvs"); //参保地
|
|
|
|
|
+ Global.pat.psn_no = JsonHelper.getDestValue(JObject.Parse(outParam), "output.baseinfo.psn_no"); //人员编号
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
if (string.IsNullOrEmpty(Global.pat.psn_no))
|
|
if (string.IsNullOrEmpty(Global.pat.psn_no))
|
|
|
{
|
|
{
|
|
|
- MessageBox.Show("未获取到该患者的医保个人编号,请重新读卡!");
|
|
|
|
|
|
|
+ MessageBox.Show("未获取到该患者的医保个人编号,请确认患者建卡信息是否维护身份证号!");
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- JObject joInput = new JObject();
|
|
|
|
|
- JObject joData = new JObject();
|
|
|
|
|
- joData.Add("psn_no", Global.pat.psn_no);
|
|
|
|
|
- joData.Add("begntime", dptST.Text);
|
|
|
|
|
- joData.Add("endtime", dptET.Text);
|
|
|
|
|
- joInput.Add("data", joData);
|
|
|
|
|
|
|
+ JObject joInput1 = new JObject();
|
|
|
|
|
+ JObject joData1 = new JObject();
|
|
|
|
|
+ joData1.Add("psn_no", Global.pat.psn_no);
|
|
|
|
|
+ //joData1.Add("psn_no", "34010000000005004087");//合肥
|
|
|
|
|
+ //joData1.Add("psn_no", "34990010039324");//省医保
|
|
|
|
|
+ joData1.Add("begntime", dptST.Text);
|
|
|
|
|
+ joData1.Add("endtime", dptET.Text);
|
|
|
|
|
+ joInput1.Add("data", joData1);
|
|
|
|
|
|
|
|
- JObject joRtn = invoker.invokeCenterService("5205", JsonHelper.setCenterInparF("5205", joInput));
|
|
|
|
|
|
|
+ JObject joRtn1 = invoker.invokeCenterService("5205", JsonHelper.setCenterInpar("5205", joInput1));
|
|
|
if (JsonHelper.parseCenterRtnValue(joRtn, out errMsg) != 0)
|
|
if (JsonHelper.parseCenterRtnValue(joRtn, out errMsg) != 0)
|
|
|
{
|
|
{
|
|
|
MessageBox.Show("人员慢特病用药记录查询失败:" + errMsg);
|
|
MessageBox.Show("人员慢特病用药记录查询失败:" + errMsg);
|
|
@@ -1216,9 +1290,22 @@ namespace PTMedicalInsurance.Forms
|
|
|
}
|
|
}
|
|
|
else
|
|
else
|
|
|
{
|
|
{
|
|
|
- dgv5205.DataSource = (DataTable)joRtn["output"]["feedetail"].ToObject(typeof(DataTable));
|
|
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
|
|
+ JObject joOutput = JObject.Parse(JsonHelper.getDestValue(joRtn1, "output"));
|
|
|
|
|
+ JArray joIDInfo = JArray.Parse(JsonHelper.getDestValue(joOutput, "feedetail"));
|
|
|
|
|
+
|
|
|
|
|
+ if (joIDInfo.Count > 0)
|
|
|
|
|
+ {
|
|
|
|
|
+ for (int i = 0; i < joIDInfo.Count; i++)
|
|
|
|
|
+ {
|
|
|
|
|
+ Utils.convertTimestamp((JObject)joIDInfo[i], "fee_ocur_time");
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ //dgv5205.DataSource = (DataTable)joRtn["output"]["feedetail"].ToObject(typeof(DataTable));
|
|
|
|
|
+ dgv5205.DataSource = (DataTable)joIDInfo.ToObject(typeof(DataTable));
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
|
|
|
|
|
public int queryHISDirectory(out string errMsg)
|
|
public int queryHISDirectory(out string errMsg)
|
|
|
{
|
|
{
|