Итак, я только что понял, что текущий фильтр, который я использовал, работает правильно, только если первая строка, которую он находит, неверна.
Module m = current
Object o = current
Filter f
load view "Standard view"
//column attribute Object Type
insert(column 3)
attribute(column 3, "Object Type")
width(column 3, 100)
f1 = attribute "Object Type" == "Requirement"
f2 = attribute "Object Type" == "Derived Requirement"
f3 = contains(attribute "Object Text", "(Testing) ", true)
for o in m do
{
f = (f1 || f2) && !(f3)
}
set f
filtering on
refresh current
Пример: это будет моя текущая таблица (не очень хорош в создании таблицы)
ID| Module Information |Object Type
__|______________________________________|____________________
1 | (Teting) this is the incorrect format| Requirements
__|______________________________________|____________________
2 | (Testing) this is also correct format| Derived Requirements
| (Test) this is incorrect format |
__|______________________________________|____________________
3 | (Testing) this is the correct format | Requirements
| (Testing) this is the correct format |
__|______________________________________|____________________
4 | (Testing) this is the correct format | Requirements
| (Teting) this is incorrect format |
__|______________________________________|____________________
Поэтому, если бы я запустил свой скрипт здесь, он показал бы мне только
ID| Module Information |Object Type
__|______________________________________|____________________
1 | (Teting) this is the incorrect format| Requirements
и не то, что я надеялся, это покажет мне:
ID| Module Information |Object Type
__|______________________________________|____________________
1 | (Teting) this is the incorrect format| Requirements
__|______________________________________|____________________
2 | (Testing) this is also correct format| Derived Requirements
| (Test) this is incorrect format |
__|______________________________________|____________________
4 | (Testing) this is the correct format | Requirements
| (Teting) this is incorrect format |
__|______________________________________|____________________
Итак, как мне показать правильный вид? Я предполагаю, что это как-то связано с зацикливанием
фильтра "Текст объекта содержит", но я не уверен, как я могу это сделать.