Merge branch 'lxq' of git.excellentkk.cn:mkm/nk-lihaink-cn into lxq

This commit is contained in:
liuxiaoquan 2023-03-07 18:38:15 +08:00
commit 6d78ed0e4d

View File

@ -100,6 +100,7 @@
<div class="layui-input-inline" style="width:35%;">
<div class="layui-form-item">
<label class="layui-form-label">保证金状态</label>
<div class="layui-input-block">
<select name="interest" lay-filter="aihao">
@ -111,6 +112,18 @@
<option value="4">旅行</option>
</select>
</div>
<div class="layui-tab" lay-filter="demo" lay-allowclose="true">
<ul class="layui-tab-title">
<li class="layui-this" lay-id="11"></li>
<li lay-id="22"></li>
</ul>
<div class="layui-tab-content">
<div class="layui-this" lay-id="11" class="layui-tab-item layui-show">内容1</div>
<div lay-id="22" class="layui-tab-item">内容2</div>
</div>
</div>
</div>
</div>
@ -124,8 +137,8 @@
<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
<ul class="layui-tab-title">
<li class="layui-this">缴存保证金</li>
<li>退回保证金</li>
<li lay-id="11" class="layui-this site-demo-active" data-type="tabChange">缴存保证金</li>
<li lay-id="22" class="site-demo-active" data-type="tabChange">退回保证金</li>
</ul>
<div class="layui-tab-content" style="height: 100px;">
@ -346,29 +359,83 @@
//监听搜索提交
// form.on('submit(searchform)', function(data) {
// layui.pageTable.reload({
// where: {
// keywords: data.field.keywords
// },
// page: {
// curr: 1
// }
// });
// return false;
// });
form.on('submit(searchform)', function(data) {
layui.pageTable.reload({
where: {
keywords: data.field.keywords
},
page: {
curr: 1
}
});
return false;
});
// 日期范围
layui.use('laydate', function () {
layui.use(['laydate','element'], function () {
var laydate = layui.laydate;
var $ = layui.jquery,element = layui.element;
//日期范围
laydate.render({
elem: '#test6'
//设置开始日期、日期日期的 input 选择器
//数组格式为 2.6.6 开始新增,之前版本直接配置 true 或任意分割字符即可
, range: ['#test-startDate-1', '#test-endDate-1']
,done: function(value, date, endDate){
if (value) {
// 时间选择
console.log(value); //得到日期生成的值2017-08-18
console.log(date); //得到日期时间对象:{year: 2017, month: 8, date: 18, hours: 0, minutes: 0, seconds: 0}
console.log(endDate); //得结束的日期时间对象开启范围选择range: true才会返回。对象成员同上。
alert(1);
layui.pageTable.reload({
where: {
keywords: data.field.keywords
},
page: {
curr: 1
}
});
} else {
// 重置
}
}
});
//触发事件
var active = {
tabChange: function(){
//切换到指定Tab项
element.tabChange('demo', this.getAttribute('lay-id')); //切换到:用户管理
// 展示
this.getAttribute()
// 删除
}
};
$('.site-demo-active').on('click', function(){
var othis = $(this), type = othis.data('type');
active[type] ? active[type].call(this, othis) : '';
});
//Hash地址的定位
// var layid = location.hash.replace(/^#test=/, '');
// element.tabChange('test', layid);
});
// table.on('laydate', function (obj) {
// if (obj.event === 'add') {
// tool.side("/admin/merchant/type/form");
// return false;
// }
// });
}
</script>
{/block}