private long m_lngAddNewAppUnitItem(clsLisAppUnitItemVO unitItemRelation) { long lngRes = 0; long lngReff = 0; #region == SQL == string sql = @"insert into t_opr_lis_app_unit_item ( application_id_chr, check_item_id_chr, apply_unit_id_chr ) values ( ?, ?, ?) "; #endregion clsHRPTableService objHRPSvc = new clsHRPTableService(); IDataParameter[] arrParams = null; objHRPSvc.CreateDatabaseParameter(3, out arrParams); try { arrParams[0].Value = unitItemRelation.m_strAPPLICATION_ID_CHR; arrParams[1].Value = unitItemRelation.m_strCHECK_ITEM_ID_CHR; arrParams[2].Value = unitItemRelation.m_strAPPLY_UNIT_ID_CHR; //往表增加记录 lngRes = objHRPSvc.lngExecuteParameterSQL(sql, ref lngReff, arrParams); objHRPSvc.Dispose(); } catch (Exception objEx) { new clsLogText().LogError(objEx); } return(lngRes); }
private void AddUnitItems(ref List <clsLisAppUnitItemVO> lstUnitItem, string unitId) { ApplyUnitDetail detail = m_dicApplyUnitDetail[unitId]; clsCheckItem_VO[] arrCheckItem = detail.Items; for (int i = 0; i < arrCheckItem.Length; i++) { clsLisAppUnitItemVO item = new clsLisAppUnitItemVO(); item.m_strAPPLY_UNIT_ID_CHR = unitId; item.m_strCHECK_ITEM_ID_CHR = arrCheckItem[i].m_strCheck_Item_ID; lstUnitItem.Add(item); } }
/// <summary> /// 形成申请单的报告组的标本组的检验项目 /// </summary> private void m_objGenerateAppUnitItems() { ArrayList arlUnitItems = new ArrayList(); foreach (clsLIS_AppApplyUnit objAppApplyUnit in this.m_objAppApplyUnits) { arlUnitItems.Clear(); clsCheckItem_VO[] objCheckItemVOArr = null; long lngRet = clsCheckItemSmp.s_obj.m_lngGetCheckItem(objAppApplyUnit.m_ObjDataVO.m_strAPPLY_UNIT_ID_CHR, out objCheckItemVOArr); if (lngRet > 0 && objCheckItemVOArr != null && objCheckItemVOArr.Length > 0) { for (int i = 0; i < objCheckItemVOArr.Length; i++) { clsLisAppUnitItemVO objUnitItem = new clsLisAppUnitItemVO(); objUnitItem.m_strAPPLY_UNIT_ID_CHR = objAppApplyUnit.m_StrApplyUnitID; objUnitItem.m_strCHECK_ITEM_ID_CHR = objCheckItemVOArr[i].m_strCheck_Item_ID; arlUnitItems.Add(objUnitItem); } objAppApplyUnit.m_ObjItemArr = (clsLisAppUnitItemVO[])arlUnitItems.ToArray(typeof(clsLisAppUnitItemVO)); } } }
private long m_lngAddNewAppUnitItem(clsLisAppUnitItemVO p_objRecord) { long lngRes = 0; long lngReff = 0; clsHRPTableService dbSvc = new clsHRPTableService(); #region == SQL == string sql = @"insert into t_opr_lis_app_unit_item ( application_id_chr, check_item_id_chr, apply_unit_id_chr ) values(?, ?, ?) "; #endregion try { IDataParameter[] objLisAddItemRefArr = null; dbSvc.CreateDatabaseParameter(3, out objLisAddItemRefArr); objLisAddItemRefArr[0].Value = p_objRecord.m_strAPPLICATION_ID_CHR; objLisAddItemRefArr[1].Value = p_objRecord.m_strCHECK_ITEM_ID_CHR; objLisAddItemRefArr[2].Value = p_objRecord.m_strAPPLY_UNIT_ID_CHR; //往表增加记录 lngRes = dbSvc.lngExecuteParameterSQL(sql, ref lngReff, objLisAddItemRefArr); dbSvc.Dispose(); } catch (Exception ex) { ThrowException(ex); } return(lngRes); }
private void m_objGenerateAppUnitItems() { clsDomainController_ApplyUnitManage objApplyUnitManage = new clsDomainController_ApplyUnitManage(); System.Collections.ArrayList arlUnitItems = new System.Collections.ArrayList(); foreach (clsLIS_AppApplyUnit objAppApplyUnit in this.m_objAppApplyUnits) { arlUnitItems.Clear(); clsCheckItem_VO[] objCheckItemVOArr = null; long lngRet = objApplyUnitManage.m_lngGetCheckItemByApplUnitID(objAppApplyUnit.m_ObjDataVO.m_strAPPLY_UNIT_ID_CHR, out objCheckItemVOArr); if (lngRet > 0 && objCheckItemVOArr != null && objCheckItemVOArr.Length > 0) { for (int i = 0; i < objCheckItemVOArr.Length; i++) { // clsLisDeviceCheckItem_VO objDevItem = null; // new clsDomainController_LisDeviceManage().m_lngGetDeviceCheckItemInfoByCheckItemID( // objCheckItemVOArr[i].m_strCheck_Item_ID.Trim(),out objDevItem); // if(objDevItem != null) // { // objCheckItem.m_StrDeviceItemName = objDevItem.strDeviceCheckItemName.Trim(); // } clsLisAppUnitItemVO objUnitItem = new clsLisAppUnitItemVO(); objUnitItem.m_strAPPLY_UNIT_ID_CHR = objAppApplyUnit.m_StrApplyUnitID; objUnitItem.m_strCHECK_ITEM_ID_CHR = objCheckItemVOArr[i].m_strCheck_Item_ID; objUnitItem.m_strItemprice_mny = objCheckItemVOArr[i].m_strItemprice_mny; arlUnitItems.Add(objUnitItem); } objAppApplyUnit.m_ObjItemArr = (clsLisAppUnitItemVO[])arlUnitItems.ToArray(typeof(clsLisAppUnitItemVO)); } } }