增加日期下拉方法
This commit is contained in:
parent
7e37c24f44
commit
00da005a77
@ -525,7 +525,6 @@ function LayuiUtil(layui, viewer) {
|
||||
* 初始化选项
|
||||
*/
|
||||
function initOption() {
|
||||
// 得到数据?
|
||||
$('#' + name).empty();
|
||||
// if (selectedValue === '') {
|
||||
// // 监听初始化
|
||||
@ -567,6 +566,23 @@ function LayuiUtil(layui, viewer) {
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 下拉数据字典
|
||||
* @param opt
|
||||
*/
|
||||
this.selectData = function(opt) {
|
||||
this.select({
|
||||
url: top.restAjax.path('api/data/listbyparentid/{parentId}', [opt.parentId]),
|
||||
domId: opt.domId,
|
||||
name: opt.name,
|
||||
dataForm: opt.dataForm,
|
||||
valueKey: 'dataId',
|
||||
nameKey: 'dataName',
|
||||
onInit: opt.onInit,
|
||||
onSelect: opt.onSelect
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取选择的option
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user