zoukankan      html  css  js  c++  java
  • 个人日常笔记

    1. datebox设置默认时间
    $(document).ready(function() {    
             $("#start").datebox("setValue",myformatter( new Date()));
             $("#end").datebox("setValue",myformatter( new Date()));
             /* $(".datebox :text").attr("readonly","readonly"); */
        });
    
        function myformatter(date){  
            var y = date.getFullYear();  
            var m = date.getMonth()+1;  
            var d = date.getDate();  
            return y+'-'+(m<10?('0'+m):m)+'-'+(d<10?('0'+d):d);  
        }

    2.easyui input设置为日期 class="easyui-datebox"

    class="easyui-datetimebox"  带时分秒

    3.easyui input标签动态变成下拉框

    供货商:<input type="text" id="from_customer_id" style="70px;height:20px;" />
        $('#from_customer_id').combobox({   
                      url:'${ctx}/admin/repo_tool/listSelect',   
                      valueField:'id',   
                      textField:'customername',
                      panelHeight:'100',
                      editable:false,
                });    
        Controller方法加头:@RequestMapping("/listSelect")
                            @ResponseBody        
    
        如果想获取下拉框的值  用这个:  .combobox("getValue");

    4. 背景图为灰色

    background-color:rgb(235, 235, 228)"

    5. 输入框去空格

    onkeyup="value=value.replace(/s/g,'')"

    6. 输入框只能输入数字以及去空格

    onkeyup="this.value=this.value.replace(/D/g,'')"  onafterpaste="this.value=this.value.replace(/D/g,'')"

    7. 边框为灰色,背景也为灰色

    style='background-color:#ccc;border-bottom:2px solid #ccc'

    8. jquery 获取easyui combobox选中的值

    $('#comboboxlist').combobox('getValue');

     9.EasyUI combotree 赋值

    $('#{$namespace}menu_id').combotree('setValues', '{$menu_id}'); 
  • 相关阅读:
    (12)springboot打war包-copy
    基于Python在MacOS上安装robotframework-ride
    mac终端输入python默认打开python3
    win10 切换网卡的bat
    PyCharm2018激活码
    我告诉你 ,一个 window免费系统下载的网站!
    oracle 子查询的几个种类
    trunc()
    case when then else end 与 decode 的区别
    触发器 of oracle
  • 原文地址:https://www.cnblogs.com/weiloong/p/4871188.html
Copyright © 2011-2022 走看看