美文网首页
Java.SOP.JSP

Java.SOP.JSP

作者: InitialX | 来源:发表于2018-08-03 14:15 被阅读19次

更新:
-- 2018/10/24 添加selected demo

  • 取序号:
<td>${status.index+1 }</td>
  • 格式化时间:
<td>
  <fmt:formatDate value="${api.createdDt }" pattern="yyyy-MM-dd HH:mm:ss" />
</td>
  • 重置
//重置
    $('#btn_reset').click(function() {
        window.location.href = "${ctx}/manage/log/sysLog";
    })
  • Radio checked
<form method="post" action="">
    <input type="radio" name="sex" <c:if test="${param.sex== '男'}">checked="checked"</c:if>>男
    <input type="radio" name="sex" <c:if test="${param.sex== '女'}">checked="checked"</c:if>>女
    </form>
  • Selected
<select id="bank" name="bank" class="col-sm-4 form-control">
    <c:if test="${not empty validBankList }">
          <c:forEach items="${validBankList}" var="bank" varStatus="status" step="1">    
            <option value="${bank}" <c:if test="${bank == accountListSearchParamDto.bank}">selected</c:if>>${bank}</option>
          </c:forEach>
    </c:if>
</select>
  • 固定表格高度(bootstrap)
 <div class="table-responsive" style="max-height:400px;overflow: scroll;">
                <table class="table table-striped table-bordered table-hover dataTables-example">
                    <thead>
                        <tr>
                            <th>编号</th>
                            <th>节日</th>
                            <th>开始日期</th>
                            <th>结束日期</th>
                            <th>操作</th> 
                        </tr>
                    </thead>
                    <!-- <tbody>
                        <c:if test="${not empty festivalList }">
                            <c:forEach items="${festivalList}" var="festival" varStatus="status"
                                step="1">
                                <tr>
                                    <td>${status.index+1 }</td>
                                    <td>${festival.festivalName}</td>
                                    <td>
                                        <fmt:formatDate value="${festival.festivalStartDate}"
                                            pattern="yyyy-MM-dd" />
                                    </td>
                                    <td>
                                        <fmt:formatDate value="${festival.festivalEndDate}"
                                            pattern="yyyy-MM-dd" />
                                    </td>
                                    <td>
                                        <a href="${ctx}/manage/festival/festivalConfigPage?festivalId=${festival.id}">
                                            <i class="fa fa-check">&nbsp;&nbsp;编辑</i>
                                        </a>
                                    </td>
                                </tr>
                            </c:forEach>
                        </c:if> 
                    </tbody> --!>
                </table> 
                <%-- <tags:pagination page="${festivalPage}" paginationSize="10" />  --%>
            </div>  
image.png

相关文章

  • Java.SOP.JSP

    更新:-- 2018/10/24 添加selected demo 取序号: 格式化时间: 重置 Radio che...

网友评论

      本文标题:Java.SOP.JSP

      本文链接:https://www.haomeiwen.com/subject/zqpheftx.html