fix: 【应用编排】判断器分支判断结果错误 (#680)

This commit is contained in:
shaohuzhang1 2024-07-02 10:27:48 +08:00 committed by GitHub
parent 5199195717
commit 25ebef6b41
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 9 additions and 5 deletions

View File

@ -18,6 +18,10 @@ from .len_gt_compare import *
from .len_le_compare import *
from .len_lt_compare import *
from .len_equal_compare import *
from .is_not_null_compare import *
from .is_null_compare import *
compare_handle_list = [GECompare(), GTCompare(), ContainCompare(), EqualCompare(), LTCompare(), LECompare(),
LenLECompare(), LenGECompare(), LenEqualCompare(), LenGTCompare(), LenLTCompare()]
LenLECompare(), LenGECompare(), LenEqualCompare(), LenGTCompare(), LenLTCompare(),
IsNullCompare(),
IsNotNullCompare()]

View File

@ -17,5 +17,5 @@ class IsNotNullCompare(Compare):
if compare == 'is_not_null':
return True
def compare(self, source_value, compare, target_value=None):
return source_value is not None
def compare(self, source_value, compare, target_value):
return source_value is not None and len(source_value) > 0

View File

@ -17,5 +17,5 @@ class IsNullCompare(Compare):
if compare == 'is_null':
return True
def compare(self, source_value, compare, target_value=None):
return source_value is None
def compare(self, source_value, compare, target_value):
return source_value is None or len(source_value) == 0