zoukankan      html  css  js  c++  java
  • bjui的validate表单验证的使用

    date-rule ="date" 表示格式为yyyy-MM-dd

    date-rule = "datetime" 表示格式为yyyy-MM-dd HH:mm:ss

    依赖框架在:http://niceue.com/validator/demo/

    用法例子:

    <tr>
                    <td align="right">扣款金额</td>
                    <td align="left">
                        <select name="withholdMoney" data-toggle="selectpicker">
                            <c:forEach items="${withholdStrategyManagerForm.withholdStrategyModuleEnums}" var="withholdStrategy">
                                <option <c:if test="${withholdStrategy.code eq withholdStrategyManagerForm.withholdMoney}">selected</c:if> value="${withholdStrategy.code}">${withholdStrategy.desc}</option>
                            </c:forEach>
                        </select>
                          
                        <input type="text" data-rule="required; integer; range[1~100]" value="${withholdStrategyManagerForm.withholdMoneyRate}" name="withholdMoneyRate">%
                    </td>
                </tr>
    
                <tr>
                    <td align="right">优先级</td>
                    <td align="left"><input data-rule="required; integer; range[1~100]; remote[get:${pageContext.request.contextPath}/withholdStrategy/checkPriority, priority]" type="text" name="priority" value="${withholdStrategyManagerForm.priority}"></td>
                </tr>
    <tr>
                    <td align="right">生效时间</td>
                    <td align="left">
                        <input type="text" data-rule="required; datetime;" name="startEffectDate" value="${withholdStrategyManagerForm.startEffectDate}" data-toggle="datepicker" data-pattern="yyyy-MM-dd HH:mm:ss">   
                        <input type="text" data-rule="required; datetime; match[gte, startEffectDate];" name="endEffectDate" value="${withholdStrategyManagerForm.endEffectDate}" data-toggle="datepicker" data-pattern="yyyy-MM-dd HH:mm:ss">
                    </td>
                </tr>.
    

      

    使用到了范围,比较,远端

  • 相关阅读:
    【模板】扩展中国剩余定理(EXCRT)
    战略游戏(树形DP)
    二叉苹果树(树形DP)
    货车运输(最大生成树,LCA)
    [CQOI2016]密钥破解
    Pollard-Rho算法andMiller_Rabin算法
    [TJOI2009]猜数字(中国剩余定理)
    中国剩余定理(学习笔记)
    线段树 Segment Tree
    辗转相除法
  • 原文地址:https://www.cnblogs.com/aigeileshei/p/7690780.html
Copyright © 2011-2022 走看看