2022年9月8日

layui表格自动换行相关css和js

摘要: <style> .layui-table-cell { height: auto; overflow: visible; text-overflow: inherit; white-space: normal; word-break: break-all; } .layui-table-cell a 阅读全文

posted @ 2022-09-08 11:39 小馬過河﹎ 阅读(442) 评论(0) 推荐(0)

mysql 自定义函数 身份证号转年龄(支持15/18位身份证)

摘要: 函数 FUNCTION `idcard2age`(`idcard` varchar(255)) RETURNS int(10) BEGIN if idcard regexp '[0-9]{18}|[0-9]{17}X|[0-9]{15}' then if(length(idcard)=18)then 阅读全文

posted @ 2022-09-08 11:38 小馬過河﹎ 阅读(74) 评论(0) 推荐(0)

javascript随机整数

摘要: zoom范围[x,y] 对应关系:Math.floor(Math.random() * [y-x]) + x; 例如:zoom范围[11,18] Math.floor(Math.random() * 7) + 11 阅读全文

posted @ 2022-09-08 11:35 小馬過河﹎ 阅读(21) 评论(0) 推荐(0)

jQuery ajax 使用同步模式(禁用异步模式)

摘要: $.ajaxSettings.async = false $.getJSON('__MODULE__/Echart/l_hjcate_cun', { cun_id: '{:I("cun_id")}' }, function (res) { res.forEach(i => { option.xAxi 阅读全文

posted @ 2022-09-08 11:16 小馬過河﹎ 阅读(114) 评论(0) 推荐(0)

layui主动触发表单控件事件select|checkbox|radio

摘要: ### 以radio为例,监听事件的代码为: ```javascript form.on('radio(filter)', function (data) { // dosomething }) ``` ### 主动触发事件: ```javascript $('#radioID').next().t 阅读全文

posted @ 2022-09-08 11:15 小馬過河﹎ 阅读(787) 评论(0) 推荐(0)

jquery.table.rowspan 自动合并单元格rowspan插件使用方法

摘要: jquery.table.rowspan.js源码 (function ($) { $.fn.extend({ //表格合并单元格,colIdx要合并的列序号,从0开始 "rowspan": function (colIdx) { return this.each(function () { var 阅读全文

posted @ 2022-09-08 11:12 小馬過河﹎ 阅读(525) 评论(0) 推荐(0)

ThinkPHP3上传文件使用保存为原文件名并且支持覆盖

摘要: $upload->saveName = []; $upload->replace = true; 阅读全文

posted @ 2022-09-08 11:02 小馬過河﹎ 阅读(46) 评论(0) 推荐(0)

ThinkPHP统计字段+1或者-1

摘要: $User = M("User"); // 实例化User对象 $User->where('id=5')->setInc('score', 3); // 用户的积分加3 $User->where('id=5')->setInc('score'); // 用户的积分加1 $User->where('i 阅读全文

posted @ 2022-09-08 10:40 小馬過河﹎ 阅读(163) 评论(0) 推荐(0)

uni-app picker-view 简单使用一例

摘要: 文档链接 https://uniapp.dcloud.io/component/picker-view.html 源码 <template> <view class="u-p-30"> <u-divider>{{edus[current].label}}</u-divider> <picker-vi 阅读全文

posted @ 2022-09-08 10:37 小馬過河﹎ 阅读(1158) 评论(0) 推荐(0)

uniapp picker-view picker-view-column 选择日期一例

摘要: 文档链接 https://uniapp.dcloud.io/component/picker-view.html 源码 <template> <view class="u-p-30"> <u-divider>{{year}}年{{month}}月{{day}}日</u-divider> <picke 阅读全文

posted @ 2022-09-08 10:35 小馬過河﹎ 阅读(543) 评论(0) 推荐(0)

导航