Mirth Community

Mirth Community (http://www.mirthcorp.com/community/forums/index.php)
-   General Discussion (http://www.mirthcorp.com/community/forums/forumdisplay.php?f=7)
-   -   HL7 Source filter - need help (http://www.mirthcorp.com/community/forums/showthread.php?t=219011)

pmcnally 03-14-2019 05:20 AM

HL7 Source filter - need help
 
Hello,
I have a source filter that I cannot get working properly and I am looking for some help.

We are currently on 3.5.1 (I will update once I finish this suite of feeds).
This is an ORU feed coming & we need to suppress certain reports from sending in D (draft) status. The report code is in OBR.21 and the status in OBR.25.

This is my code. It is currently suppressing everything in Draft, not just these report types.

var reportType = ['2NDLENTMAL', 'ABV', 'ARTERIAL', 'ASV', 'AVBMT', 'BEDSPIRO', 'BHSJ.ECT', 'CAIR RPT', 'CARD', 'CARDREPORT', 'CIREXC', 'CLC FTSG', 'CLCFTSG-2',
'CLCIWAMOTO', 'CPAP09', 'CPAPNON09', 'DIPMYOREP', 'DOBMYOPER', 'DOPECHOREP', 'DUPLEX', 'ECHO REP', 'ED', 'ED.NOTE', 'EKG', 'EKG STRIP', 'EXERTESTRE',
'FEEG', 'FGI', 'FGSCR', 'FICS', 'FIRCR', 'FOSE', 'FTSG', 'FTWCLC', 'GRAFTETN', 'HOLTER', 'HST', 'IRMES', 'ISF', 'LENTMAL', 'LIV CTR', 'MELANOMWLE',
'MICROSURG', 'MOHS.OP', 'MOHSATT', 'MOHSCGRAFT', 'MOHSED+C', 'MSLT09', 'MWT09', 'MYOPEREXER', 'NM', 'NMMT', 'NPSG09', 'OUT REHAB', 'OUTPT REHA',
'PETSCAN', 'POSTPURSE', 'PS', 'PSMT', 'PULREPORT', 'RBMPHOTO', 'RCR', 'RCS', 'REA', 'REEG', 'RER', 'RGI', 'RPCM.ANEST', 'RPCM.BNOTE', 'RPCM.CCPHO',
'RPCM.COC', 'RPCM.COCPD', 'RPCM.COCPO', 'RPCM.CPR', 'RPCM.EEG', 'RPCM.EGDCP', 'RPCM.ENDUS', 'RPCM.EPR', 'RPCM.ERCP', 'RPCM.GIP', 'RPCM.OADM',
'RPCM.PAL', 'RPCM.RADPN', 'RPCM.SLFUP', 'RPCM.SURGB', 'RPCM.TNOTE', 'RPCM.UPEND', 'RPCM.URO', 'RSOPN', 'SIMPEXCCLC', 'SJEXMPS', 'SJNM', 'SJNMMT',
'SJPHARMMPS', 'SJSP', 'SJSPMT', 'SNERC.COG1', 'SNERC.SWAL', 'SP', 'SPCM.COCCM', 'SPCM.ECT', 'SPCM.GI', 'SPCM.OBHTP', 'SPCM.PFT', 'SPCM.REHWC',
'SPCM.RWEEK', 'SPCM.STVID', 'SPCM.TMTG', 'SPFAT', 'SPLIT09', 'SPMT', 'SPMT1', 'STAGING', 'TEE', 'TRANS'];

for each(obr in msg.OBR)
{
if(reportType.indexOf(obr['OBR.21']['OBR.21.1']) == -1 && obr['OBR.25']['OBR.25.1'] == 'D') return false;
else return true;

}

Thanks.

agermano 03-18-2019 11:24 PM

Double posted to http://www.mirthcorp.com/community/f...d.php?t=219012

See other thread.

davidakh 05-31-2019 06:23 AM

i have same problem_


All times are GMT -8. The time now is 07:26 PM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Mirth Corporation