首页
壁纸
关于
推荐
战略合作
Google
主题Joe
Search
1
涂鸦设备本地化接入(涂鸦电表)
13 阅读
2
CentOS 定时同步指定文件到ftp
6 阅读
3
laydate输入日期年月日时分,以十分钟为间隔,不需要秒
5 阅读
4
记一次Django_cas_ng数据库migrate错误
5 阅读
5
Centos7 安装python3并配置pip
4 阅读
运维
Windows
Linux
MacOS
Android
vmware
开发
Python
Go
Html
Electron
智家
HomeAssistant
ESPhome
Unraid
群晖
网络相关
登录
Search
标签搜索
运维
Linux
Python
django
智能家居
Nginx
MACos
brew
layui
cas
群晖
nas
zabbix
vim
JDK
sonar
jenkins
Nexus
转发
mysql
Ruike
累计撰写
29
篇文章
累计收到
109
条评论
首页
栏目
运维
Windows
Linux
MacOS
Android
vmware
开发
Python
Go
Html
Electron
智家
HomeAssistant
ESPhome
Unraid
群晖
网络相关
页面
壁纸
关于
推荐
战略合作
Google
主题Joe
搜索到
1
篇与
的结果
2022-12-09
laydate输入日期年月日时分,以十分钟为间隔,不需要秒
项目要求插入日期时选择年月日时分且以十分钟为间隔,不需要秒,项目中使用了layui的laydate日期插件,下面是实现此功能的具体操作:一:去除选择日期插件上的秒样式,更改分样式使其只显示00、10、20、30、40、50.layui-laydate-content>.layui-laydate-list { padding-bottom: 0px; overflow: hidden; } .layui-laydate-content>.layui-laydate-list>li{ width:50% } .merge-box .scrollbox .merge-list { padding-bottom: 5px; } .layui-laydate-content>.layui-laydate-list>li:nth-child(2)>ol>li:nth-child(-n+10):nth-child(n+2){ display: none; } .layui-laydate-content>.layui-laydate-list>li:nth-child(2)>ol>li:nth-child(-n+20):nth-child(n+12){ display: none; } .layui-laydate-content>.layui-laydate-list>li:nth-child(2)>ol>li:nth-child(-n+30):nth-child(n+22){ display: none; } .layui-laydate-content>.layui-laydate-list>li:nth-child(2)>ol>li:nth-child(-n+40):nth-child(n+32){ display: none; } .layui-laydate-content>.layui-laydate-list>li:nth-child(2)>ol>li:nth-child(-n+50):nth-child(n+42){ display: none; } .layui-laydate-content>.layui-laydate-list>li:nth-child(2)>ol>li:nth-child(-n+60):nth-child(n+52){ display: none; } 二:在js中的laydate.render中加format,使得选择日期时间之后,输入框中显示yyyy-MM-dd HH:mm格式的日期<#input id="actualBerthingTime" name="实际靠泊时间"/> laydate.render({ elem: '#actualBerthingTime' , type: 'datetime', trigger: 'click', format: 'yyyy-MM-dd HH:mm' });摘自:https://blog.csdn.net/qq_34896730/article/details/103696014感谢
2022年12月09日
5 阅读
0 评论
0 点赞