add common.isModile() api pe support function
parent
7cec73d5b8
commit
c293847c51
|
|
@ -29,6 +29,17 @@ layui.define(['jquery', 'element','table'], function(exports) {
|
|||
return ids;
|
||||
}
|
||||
|
||||
/**
|
||||
* 当前是否为与移动端
|
||||
* */
|
||||
this.isModile = function(){
|
||||
if ($(window).width() <= 768) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 提交 json 数据
|
||||
* @param data 提交数据
|
||||
|
|
|
|||
|
|
@ -201,7 +201,7 @@
|
|||
type: 2,
|
||||
title: '新增',
|
||||
shade: 0.1,
|
||||
area: ['500px', '400px'],
|
||||
area: [common.isModile()?'100%':'500px', common.isModile()?'100%':'400px'],
|
||||
content: MODULE_PATH + 'add.html'
|
||||
});
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue