修改急诊报表,去掉无用字段,修改报表中药品id为drug_info表的drug_id2
This commit is contained in:
parent
c38bfd09dc
commit
150da75771
|
|
@ -338,7 +338,7 @@ namespace DM_Weight.Report
|
||||||
Report.LoadFromFile(new FileInfo(AppDomain.CurrentDomain.BaseDirectory) + "ReportTemp//" + "orderUse_template.grf");
|
Report.LoadFromFile(new FileInfo(AppDomain.CurrentDomain.BaseDirectory) + "ReportTemp//" + "orderUse_template.grf");
|
||||||
|
|
||||||
SQL = $@"
|
SQL = $@"
|
||||||
SELECT oi.p_name,oi.age,oi.sex,oi.id_number,oi.patientno,oi.disease,od.drug_id,oi.doctor_name,oi.order_no,oi.order_date,
|
SELECT oi.p_name,oi.age,oi.sex,oi.id_number,oi.patientno,oi.disease,di.drug_id2,oi.doctor_name,oi.order_no,oi.order_date,
|
||||||
dmr.id,dmr.`drawer_no` AS drawerNo,dmr.`col_no` AS colNo,dmr.`type` AS `type`,dmr.`quantity` AS quantity,
|
dmr.id,dmr.`drawer_no` AS drawerNo,dmr.`col_no` AS colNo,dmr.`type` AS `type`,dmr.`quantity` AS quantity,
|
||||||
dmr.`manu_no` AS manuNo,dmr.`eff_date` AS effDate,dmr.`operation_time` AS operationTime,
|
dmr.`manu_no` AS manuNo,dmr.`eff_date` AS effDate,dmr.`operation_time` AS operationTime,
|
||||||
di.`drug_name` AS drugName,di.`drug_spec` AS drugSpec,di.`pack_unit` AS packUnit,
|
di.`drug_name` AS drugName,di.`drug_spec` AS drugSpec,di.`pack_unit` AS packUnit,
|
||||||
|
|
@ -384,7 +384,7 @@ namespace DM_Weight.Report
|
||||||
string p_machine_id = (ConfigurationManager.AppSettings["machineId"] ?? "DM1");
|
string p_machine_id = (ConfigurationManager.AppSettings["machineId"] ?? "DM1");
|
||||||
string SQL = $@" SELECT ac.create_time as operationTime, IF(ac.INVOICE_NO='日结','',ac.INVOICE_NO) invoiceNo,
|
string SQL = $@" SELECT ac.create_time as operationTime, IF(ac.INVOICE_NO='日结','',ac.INVOICE_NO) invoiceNo,
|
||||||
ac.manu_no as manuNo,ac.eff_date as effDate,ac.add_quantity inQuantity,ac.manu_stock as manuQuantity,ac.department as dept,ac.out_quantity as outQuantity,ac.total_stock as totalQuantity,IF(ac.INVOICE_NO='日结',ac.INVOICE_NO,'') as rj,
|
ac.manu_no as manuNo,ac.eff_date as effDate,ac.add_quantity inQuantity,ac.manu_stock as manuQuantity,ac.department as dept,ac.out_quantity as outQuantity,ac.total_stock as totalQuantity,IF(ac.INVOICE_NO='日结',ac.INVOICE_NO,'') as rj,
|
||||||
di.drug_id as drugId,di.drug_name as drugName,di.drug_spec as drugSpec,di.manufactory as manufactory,di.big_unit as bigUnit,u1.user_name as operatorName,u2.user_name as reviewerName,db.baseQuantity
|
di.drug_id2 as drugId,di.drug_name as drugName,di.drug_spec as drugSpec,di.manufactory as manufactory,di.big_unit as bigUnit,u1.user_name as operatorName,u2.user_name as reviewerName,db.baseQuantity
|
||||||
FROM account_book_g2 ac left join drug_info di on ac.drug_id=di.drug_id left join user_list u1 on ac.user_id1=u1.id left join user_list u2 on ac.user_id2=u2.id LEFT JOIN DRUG_BASE db on di.drug_id=db.drugid and db.machine_id='{p_machine_id}'
|
FROM account_book_g2 ac left join drug_info di on ac.drug_id=di.drug_id left join user_list u1 on ac.user_id1=u1.id left join user_list u2 on ac.user_id2=u2.id LEFT JOIN DRUG_BASE db on di.drug_id=db.drugid and db.machine_id='{p_machine_id}'
|
||||||
WHERE ac.machine_id='{p_machine_id}' and create_time>'{p_startDate}' AND create_time<'{p_endDate}' AND TYPE IN(1,2,3) ";
|
WHERE ac.machine_id='{p_machine_id}' and create_time>'{p_startDate}' AND create_time<'{p_endDate}' AND TYPE IN(1,2,3) ";
|
||||||
if (!string.IsNullOrEmpty(drug_id))
|
if (!string.IsNullOrEmpty(drug_id))
|
||||||
|
|
|
||||||
|
|
@ -123,11 +123,13 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"Name":"批号",
|
"Name":"批号",
|
||||||
"Width":2.01083
|
"Width":2.01083,
|
||||||
|
"Visible":false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"Name":"效期",
|
"Name":"效期",
|
||||||
"Width":1.61396
|
"Width":1.61396,
|
||||||
|
"Visible":false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"Name":"科室"
|
"Name":"科室"
|
||||||
|
|
@ -151,7 +153,8 @@
|
||||||
"Name":"门诊/住院号"
|
"Name":"门诊/住院号"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"Name":"专用病历号(麻卡号)"
|
"Name":"专用病历号(麻卡号)",
|
||||||
|
"Visible":false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"Name":"疾病名称"
|
"Name":"疾病名称"
|
||||||
|
|
|
||||||
|
|
@ -273,7 +273,7 @@ namespace DM_Weight.ViewModels
|
||||||
DrugInfos.Clear();
|
DrugInfos.Clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
//DrugInfos = SqlSugarHelper.Db.SqlQueryable<DrugInfo>(str).Where(di => di.DrugName.Contains(text) || di.PyCode.Contains(text) || di.DrugId.Contains(text)).OrderBy(di => di.DrugName).OrderBy(di => di.DrugId).ToList();
|
DrugInfos = SqlSugarHelper.Db.SqlQueryable<DrugInfo>(str).Where(di => di.DrugName.Contains(text) || di.PyCode.Contains(text) || di.DrugId.Contains(text)).OrderBy(di => di.DrugName).OrderBy(di => di.DrugId).ToList();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue