-
Notifications
You must be signed in to change notification settings - Fork 24
/
CLAIMS-RETURNED.drl
25 lines (21 loc) · 1.33 KB
/
CLAIMS-RETURNED.drl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package org.kuali.ole.rules.demo.claimsReturned
import org.kuali.ole.OLEConstants
import org.kuali.ole.deliver.util.OleItemRecordForCirc
import org.kuali.ole.deliver.util.DroolsResponse
rule "Claims Returned Policy Set for Item type Book"
agenda-group "claims returned validation"
activation-group "claims returned validation"
when
$i: OleItemRecordForCirc(getItemType() in ("BOOK"),
getItemLibraryLocation() in ("LSC","B-EDUC","B-HPER","DLL","SCL","DOCS"),
getItemLocation() in ("PSK", "BED-STACKS","BED-TEACHMAT","BHP-JOURNALS","LawPer"))
$d : DroolsResponse()
then
$d.setRuleMatched(true);
$d.getDroolsExchange().addToContext(OLEConstants.CLAIMS_RETURNED_NOTICE,"Claims Returned Notice");
$d.getDroolsExchange().addToContext(OLEConstants.CLAIMS_RETURNED_FOUND_NO_FEES_NOTICE,"Claims Returned Found No Fees Notice");
$d.getDroolsExchange().addToContext(OLEConstants.CLAIMS_RETURNED_FOUND_FINES_OWED_NOTICE,"Claims Returned Found Fines Owed Notice");
$d.getDroolsExchange().addToContext(OLEConstants.CLAIMS_RETURNED_NOT_FOUND_NOTICE,"Claims Returned Not Found Notice");
$d.getDroolsExchange().addToContext(OLEConstants.CLAIMS_RETURNED_NOT_FOUND_NO_FEES_NOTICE,"Claims Returned Not Found No Fees Notice");
$d.getDroolsExchange().addToContext(OLEConstants.CLAIMS_RETURNED_NOT_FOUND_FINES_OWED_NOTICE_TITLE,"Claims Returned Not Found Fines Owed Notice");
end