Changeset 65091 in vbox for trunk/src/VBox/ValidationKit/testmanager/webui/wuimain.py
- Timestamp:
- Jan 4, 2017 2:04:12 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/testmanager/webui/wuimain.py
r65090 r65091 933 933 for oCrit in oFilter.aCriteria: 934 934 if len(oCrit.aoPossible) > 0: 935 if oCrit.sState == oCrit.ksState_Selected \ 936 or len(oCrit.aoPossible) <= 2 \ 935 if ( oCrit.oSub is None \ 936 and ( oCrit.sState == oCrit.ksState_Selected \ 937 or len(oCrit.aoPossible) <= 2)) \ 938 or ( oCrit.oSub is not None \ 939 and ( oCrit.sState == oCrit.ksState_Selected \ 940 or oCrit.oSub.sState == oCrit.ksState_Selected \ 941 or (len(oCrit.aoPossible) <= 2 and len(oCrit.oSub.aoPossible) <= 2))) \ 937 942 or oCrit.fExpanded is True: 938 sClass = 'sf-collaps able';943 sClass = 'sf-collapsible'; 939 944 sChar = '▼'; 940 945 else: … … 942 947 sChar = '▶'; 943 948 944 sHtml += u' <dt class="%s"><a href="javascript:void(0)" onclick="toggleCollaps ableDtDd(this);">%s'\949 sHtml += u' <dt class="%s"><a href="javascript:void(0)" onclick="toggleCollapsibleDtDd(this);">%s'\ 945 950 u' %s</a></dt>\n' \ 946 951 u' <dd class="%s">\n' \ … … 950 955 for oDesc in oCrit.aoPossible: 951 956 fChecked = oDesc.oValue in oCrit.aoSelected; 952 sHtml += u' <li%s%s>< input type="checkbox" name="%s" value="%s"%s/>%s%s</li>\n' \957 sHtml += u' <li%s%s><label><input type="checkbox" name="%s" value="%s"%s%s/>%s%s</label>\n' \ 953 958 % ( ' class="side-filter-irrelevant"' if oDesc.fIrrelevant else '', 954 ' title="%s"' % (webutils.escapeAttr(oDesc.sHover,) if oDesc.sHover is not None else ''), 955 oCrit.sVarNm, oDesc.oValue, ' checked' if fChecked else '', 959 (' title="%s"' % (webutils.escapeAttr(oDesc.sHover,)) if oDesc.sHover is not None else ''), 960 oCrit.sVarNm, 961 oDesc.oValue, 962 ' checked' if fChecked else '', 963 ' onclick="toggleCollapsibleCheckbox(this);"' if oDesc.aoSubs is not None else '', 956 964 webutils.escapeElem(oDesc.sDesc), 957 965 '<span class="side-filter-count"> [%u]</span>' % (oDesc.cTimes) if oDesc.cTimes is not None 958 966 else '', ); 959 967 if oDesc.aoSubs is not None: 968 sHtml += u' <ul class="sf-checkbox-%s">\n' % ('collapsible' if fChecked else 'expandable', ); 969 for oSubDesc in oDesc.aoSubs: 970 fSubChecked = oSubDesc.oValue in oCrit.oSub.aoSelected; 971 sHtml += u' <li%s%s><label><input type="checkbox" name="%s" value="%s"%s/>%s%s</label>\n' \ 972 % ( ' class="side-filter-irrelevant"' if oSubDesc.fIrrelevant else '', 973 ' title="%s"' % ( webutils.escapeAttr(oSubDesc.sHover,) if oSubDesc.sHover is not None 974 else ''), 975 oCrit.oSub.sVarNm, oSubDesc.oValue, ' checked' if fSubChecked else '', 976 webutils.escapeElem(oSubDesc.sDesc), 977 '<span class="side-filter-count"> [%u]</span>' % (oSubDesc.cTimes) 978 if oSubDesc.cTimes is not None else '', ); 979 980 sHtml += u' </ul>\n'; 981 sHtml += u' </li>'; 960 982 sHtml += u' </ul>\n' \ 961 983 u' </dd>\n';
Note:
See TracChangeset
for help on using the changeset viewer.