You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
65 lines
2.3 KiB
65 lines
2.3 KiB
layui.use(['form','table'], function(){
|
|
var form = layui.form;
|
|
var table = layui.table;
|
|
table.render({
|
|
elem: '#recordTable'
|
|
// ,url: '#' //数据接口
|
|
,data: []
|
|
,cols: [[ //表头
|
|
{field: 'cu', title: 'coin', width: '14%'}
|
|
,{field: 'money', title: 'amount', width: '14%'}
|
|
,{field: 'time', title: 'time', width: '14%'}
|
|
,{field: 'money1', title: 'free amount', width: '14%'}
|
|
,{field: 'experience', title: 'trading coin', width: '14%'}
|
|
,{field: 'money2', title: 'trading amount', width: '14%'}
|
|
,{field: 'price', title: 'trading price', width: '16%'}
|
|
]]
|
|
,skin: 'line'
|
|
,page: { //支持传入 laypage 组件的所有参数(某些参数除外,如:jump/elem) - 详见文档
|
|
layout: ['count', 'prev', 'page', 'next'], //自定义分页布局
|
|
groups: 7, // 只显示 1 个连续页码
|
|
first: false, //不显示首页
|
|
last: false //不显示尾页
|
|
}
|
|
});
|
|
table.render({
|
|
elem: '#recordTable2'
|
|
// ,url: '#' //数据接口
|
|
,data: []
|
|
,cols: [[ //表头
|
|
{field: 'cu', title: 'Time', width: '14%'}
|
|
,{field: 'money', title: 'Direction', width: '14%'}
|
|
,{field: 'time', title: 'Price', width: '14%'}
|
|
,{field: 'money1', title: 'Amount', width: '14%'}
|
|
,{field: 'experience', title: 'Symbol', width: '14%'}
|
|
,{field: 'money2', title: 'Action', width: '14%'}
|
|
]]
|
|
,skin: 'line'
|
|
,page: { //支持传入 laypage 组件的所有参数(某些参数除外,如:jump/elem) - 详见文档
|
|
layout: ['count', 'prev', 'page', 'next'], //自定义分页布局
|
|
groups: 7, // 只显示 1 个连续页码
|
|
first: false, //不显示首页
|
|
last: false //不显示尾页
|
|
}
|
|
});
|
|
//切换标签tab页
|
|
$('#tabHead li').on('click',function(){
|
|
$('#tabHead li').removeClass('activeLi');
|
|
$(this).addClass('activeLi')
|
|
let name = $(this).data('name');
|
|
$("#tab-panel section").hide()
|
|
$("#tab-panel section[data-name='"+name+"']").show()
|
|
})
|
|
|
|
|
|
});
|
|
|
|
$(function(){
|
|
$('.layui-form-item .layui-input').keyup( function(){
|
|
if($(this).val()){
|
|
$('.layui-btn').removeClass('disabledSubmit').addClass('activeSubmit')
|
|
}else{
|
|
$('.layui-btn').removeClass('activeSubmit').addClass('disabledSubmit')
|
|
}
|
|
})
|
|
})
|