Отображать сообщение, когда флажок не установлен в JSP - PullRequest
1 голос
/ 04 февраля 2020

, если box.obj1 или box.obj2 не пусты, тогда флажок checkBox отключен, Как отображать сообщение, когда наведите курсор на отключенный флажок?

я могу использовать JavaScript, чтобы отобразить сообщение, когда зависание на отключенном флажок, но есть ли способ установить сообщение ниже jsp для отображения сообщения, когда флажок отключен.

<div class="container sub-process" id="searchResultDiv-${searchList.makeUnique}">
<div align="center" class="form-group col-md-12 col-sm-12 input-group-xs paddingnarrow searchResultsDiv in" id="searchDiv-${modelClass.makeUnique}">    
    <table data-process-name="processName" class="has-tablesorter-childRow table-xcondensed col-md-12 col-sm-12 nopadding table-bordered tablesorter resultsTable" style="font-size:11px;">
        <thead class="ui-widget-header">
            <tr>
                <th id="select_box" class="tablesorter-ignoreColumn filter-false sorter-false">Select</th>
            </tr>
        </thead>
        <tbody>
        <fmt:setLocale value="en_US"/>
        <c:forEach var="box" begin="0" end="999" items="${searchList.modelClass}">
        <c:choose>
        <c:when test="${not empty box.obj1 or not empty box.obj2}"> 
        <c:set value="disabled" var="checkBoxDisabled"></c:set>   
        </c:when>
        <c:otherwise>
        <c:set value="" var="checkBoxDisabled"></c:set>   
        </c:otherwise>      
        </c:choose>
            <tr class="table accordion-toggle className noHoverEffect" data-toggle="collapse" data-target="#uniqueId" id="className-uniqueId">  
                <td class="subClassName tablesorter-ignoreColumn">
                    <a href="#">
                        <input style="background-color:inherit; height:16px; min-width:8px; margin-top:1px;" class="form-control checkBox" 
                        type="checkbox"  ${checkBoxDisabled} name="selectCheckBox"/>
                    </a>
            </td>
            </tr>
        </c:forEach>
        </tbody>
    </table>
</div>              

...