All Downloads are FREE. Search and download functionalities are using the official Maven repository.

edits.seer.internal.rules.IFN6084.xml Maven / Gradle / Ivy

There is a newer version: 024-13
Show newest version
        <rule id="IFN6084" name="Tumor Deposits, Colorectal, Surgery 03-2022 (SEER)" tag="N6084" java-path="lines.line" category="inter-field" depends="Year_of_Diagnosis">
            <expression><![CDATA[if (line.dateOfDiagnosisYear == null || line.dateOfDiagnosisYear < '2019' || line.dateOfDiagnosisYear > '2022' || line.rxSummSurgPrimSite == null
            || line.schemaId != '00200' || ['6','7'].contains(line.typeOfReportingSource))
    return true

Integer dolcYear = Functions.asInt(line.dateOfLastContactYear)
Integer dolcMonth = Functions.asInt(line.dateOfLastContactMonth)
Integer dolcDay = Functions.asInt(line.dateOfLastContactDay)
Integer dxYear = Functions.asInt(line.dateOfDiagnosisYear)
Integer dxMonth = Functions.asInt(line.dateOfDiagnosisMonth)
Integer dxDay = Functions.asInt(line.dateOfDiagnosisDay)

if (line.vitalStatus == '0' && (Boolean)((Closure)Context.compareDatesWithinMonths).call(dolcYear, dolcMonth, dolcDay, dxYear, dxMonth, dxDay, 5))
    return true

String tumorDeposits = line.tumorDeposits
if (tumorDeposits == null || tumorDeposits == 'X8')
    return true

if (Functions.matches(line.rxSummSurgPrimSite, /^00|1[0-4]|2\d$/) || line.rxSummSurgPrimSite == '99')
    return tumorDeposits == 'X9'

return true]]></expression>
            <message>Tumor Deposits conflicts with RX Summ--Surg Prim Site 03-2022.</message>
            <description><![CDATA[This edit verifies that Tumor Deposits SSDI is coded consistently with
RX Summ--Surg Prim Site 03-2022.

1. This edit is skipped if any of the following conditions is true:

   a. Year of Date of Diagnosis is less than 2019 or greater than 2022, blank (unknown), or invalid
   b. Schema ID is not 00200
   c. Tumor Deposits is blank or X8 (not applicable)
   d. RX Summ--Surg Prim Site 03-2022 is blank
   e. Type of Reporting Source = 6 (Autopsy Only) or 7 (Death Certificate Only)
   f. Vital Status = 0 and Date of Last Contact within 5 months of Date of Diagnosis

2. If RX Summ-Surg Prim Site 03-2022 = 00 (no surgery), 10-14 (tumor destruction
     without pathology specimen), or 20-29 (local excision)
   Tumor Deposits must = X9 (no surgical resection of primary site)

3. If RX Summ-Surg Prim Site 03-2022 = 99 (unknown if surgery performed)
    Tumor Deposits must = X9 (Tumor Deposits not asssessed or unknown if assessed)
]]></description>
            <history>
                <event version="SE18-019-02" user="kirbyk" date="2019-05-15" ref="68154">Edit created.</event>
                <event version="SE22-022-01" user="beverung" date="2022-01-20" ref="68897">Update edit name to match new NAACCR translated edit.</event>
                <event version="SE22-022-01" user="beverung" date="2022-02-18" ref="68798">Add skip conditions for Type of Reporting Source and Date of Last Contact/Vital Status.</event>
                <event version="SE23-023-01" user="shearerw" date="2023-01-25" ref="69103">Update edit name and add skip condition for DX year after 2022.</event>
                <event version="SE23-023-03" user="shearerw" date="2023-05-24" ref="69216">Fix logic for DOLC within 5 months of DX date to allow difference in year.</event>
                <event version="SE24-024-01" user="cooki" date="2024-02-06" ref="69373">Added condition #3 for code 99.</event>
            </history>
        </rule>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy