コード例 #1
0
ファイル: clsApplyUnitSvc.cs プロジェクト: timsanc/HIS
        public long m_lngDelApplyUnitDetailByApplyIDAndCheckItemID(System.Security.Principal.IPrincipal p_objPrincipal,
                                                                   clsApplUnitDetail_VO p_objRecord)
        {
            long lngRes = 0;

            clsPrivilegeHandleService objPrivilege = new clsPrivilegeHandleService();

            lngRes = objPrivilege.m_lngCheckCallPrivilege(p_objPrincipal, "com.digitalwave.iCare.middletier.LIS.clsApplyUnitSvc", "m_lngDelApplyUnitDetailByApplyIDAndCheckItemID");
            if (lngRes < 0)
            {
                return(-1);
            }

            string strSQL = @"DELETE FROM t_aid_lis_apply_unit_detail
							   WHERE check_item_id_chr = '"                             + p_objRecord.strCheckItemID + @"'
								 AND apply_unit_id_chr = '"                                 + p_objRecord.strApplUnitID + "'";

            try
            {
                com.digitalwave.iCare.middletier.HRPService.clsHRPTableService objHRPSvc = new clsHRPTableService();
                long lngRecEff = -1;
                lngRes = objHRPSvc.DoExcuteForDelete(strSQL, ref lngRecEff);
                if (lngRecEff > -1)
                {
                    lngRes = 1;
                }
                objHRPSvc.Dispose();
            }
            catch (Exception objEx)
            {
                com.digitalwave.Utility.clsLogText objLogger = new clsLogText();
                bool blnRes = objLogger.LogError(objEx);
            }
            return(lngRes);
        }
コード例 #2
0
ファイル: clsApplyUnitSvc.cs プロジェクト: timsanc/HIS
        public long m_lngDelApplUnit(System.Security.Principal.IPrincipal p_objPrincipal, string strApplUnitID)
        {
            long lngRes = 0;

            clsPrivilegeHandleService objPrivilege = new clsPrivilegeHandleService();

            lngRes = objPrivilege.m_lngCheckCallPrivilege(p_objPrincipal, "com.digitalwave.iCare.middletier.LIS.clsAppGroupSvc", "m_lngDelApplUnit");
            if (lngRes < 0)
            {
                return(-1);
            }

            string strSQL = @"DELETE FROM t_aid_lis_apply_unit WHERE apply_unit_id_chr = '" + strApplUnitID + "'";

            try
            {
                com.digitalwave.iCare.middletier.HRPService.clsHRPTableService objHRPSvc = new clsHRPTableService();
                long lngRecEff = -1;
                lngRes = objHRPSvc.DoExcuteForDelete(strSQL, ref lngRecEff);
                objHRPSvc.Dispose();
            }
            catch (Exception objEx)
            {
                com.digitalwave.Utility.clsLogText objLogger = new clsLogText();
                bool blnRes = objLogger.LogError(objEx);
            }
            return(lngRes);
        }
コード例 #3
0
ファイル: clsAppGroupSvc.cs プロジェクト: timsanc/HIS
        public long m_lngDelApplUserGroupRelation(System.Security.Principal.IPrincipal p_objPrincipal, string strApplUserGroupID, string strParentUserGroupId)
        {
            long lngRes = 0;

            clsPrivilegeHandleService objPrivilege = new clsPrivilegeHandleService();

            lngRes = objPrivilege.m_lngCheckCallPrivilege(p_objPrincipal, "com.digitalwave.iCare.middletier.LIS.clsAppGroupSvc", "m_lngDelApplUserGroupRelation");
            if (lngRes < 0)
            {
                return(-1);
            }

            string strSQL = @"DELETE FROM t_aid_lis_appuser_group_relate WHERE USER_GROUP_ID_CHR = '" + strApplUserGroupID + "' or CHILD_USER_GROUP_ID_CHR = '" + strApplUserGroupID + "' AND USER_GROUP_ID_CHR = '" + strParentUserGroupId + "'";

            try
            {
                com.digitalwave.iCare.middletier.HRPService.clsHRPTableService objHRPSvc = new clsHRPTableService();
                long lngRecEff = -1;
                lngRes = objHRPSvc.DoExcuteForDelete(strSQL, ref lngRecEff);
                if (lngRecEff > -1)
                {
                    lngRes = 1;
                }
                objHRPSvc.Dispose();
            }
            catch (Exception objEx)
            {
                com.digitalwave.Utility.clsLogText objLogger = new clsLogText();
                bool blnRes = objLogger.LogError(objEx);
            }
            return(lngRes);
        }