The following two rule definitions can be used for your use case.
rule 1
when
$item: Item (price > 1000)
then
modify ($item) {
doNotBuy = true
}
rule 2
when
$item: Item(price>1000, price<700)
then
modify($item) {
negotiate = true
}
The basic thing with the Drools is, it evaluates the when
parts of your rules and decides whether then
part of a rule is to be executed. You do not need to do anything except that writing meaningful conditions in the when
part.
salience
is a totally different beast and I recommend you to stay away from it, at least until you get familiar with drools.