mail/rspamd: fix model (missing properties), constraint bugs (#1120)

* mail/rspamd: fix model (missing properties), constaint bugs
This commit is contained in:
Fabian Franz BSc
2019-01-06 20:30:17 +01:00
committed by GitHub
parent a72edff55a
commit 8257b1fbbc
@@ -17,10 +17,35 @@
<MaximumValue>999</MaximumValue>
<Constraints>
<check001>
<ValidationMessage>This field must be bigger than the header score.</ValidationMessage>
<ValidationMessage>This field must be bigger than the subject score.</ValidationMessage>
<type>ComparedToFieldConstraint</type>
<field>subjectscore</field>
<operator>gt</operator>
</check001>
<check002>
<ValidationMessage>This field must be bigger than the reject score.</ValidationMessage>
<type>ComparedToFieldConstraint</type>
<field>headerscore</field>
<operator>gt</operator>
</check002>
<check003>
<ValidationMessage>This field must be bigger than the greylist score.</ValidationMessage>
<type>ComparedToFieldConstraint</type>
<field>greylistscore</field>
<operator>gt</operator>
</check003>
</Constraints>
</rejectscore>
<headerscore type="IntegerField">
<Required>N</Required>
<MinimumValue>1</MinimumValue>
<MaximumValue>999</MaximumValue>
<Constraints>
<check001>
<ValidationMessage>This field must be lower than the subject score.</ValidationMessage>
<type>ComparedToFieldConstraint</type>
<field>subjectscore</field>
<operator>lt</operator>
</check001>
<check002>
<ValidationMessage>This field must be lower than the reject score.</ValidationMessage>
@@ -35,7 +60,7 @@
<operator>gt</operator>
</check003>
</Constraints>
</rejectscore>
</headerscore>
<greylistscore type="IntegerField">
<Required>N</Required>
<MinimumValue>1</MinimumValue>
@@ -61,6 +86,31 @@
</check003>
</Constraints>
</greylistscore>
<subjectscore type="IntegerField">
<Required>N</Required>
<MinimumValue>1</MinimumValue>
<MaximumValue>999</MaximumValue>
<Constraints>
<check001>
<ValidationMessage>This field must be bigger than the header score.</ValidationMessage>
<type>ComparedToFieldConstraint</type>
<field>headerscore</field>
<operator>gt</operator>
</check001>
<check002>
<ValidationMessage>This field must be lower than the reject score.</ValidationMessage>
<type>ComparedToFieldConstraint</type>
<field>rejectscore</field>
<operator>lt</operator>
</check002>
<check003>
<ValidationMessage>This field must be bigger than the subject score.</ValidationMessage>
<type>ComparedToFieldConstraint</type>
<field>greylistscore</field>
<operator>gt</operator>
</check003>
</Constraints>
</subjectscore>
<rewritesubject type="TextField">
<Required>N</Required>
</rewritesubject>