mirror of
https://gitee.com/ulthon/ulthon_admin.git
synced 2026-07-01 15:32:48 +08:00
feat: 页面以子页面打卡时使用弹框方式增加和编辑
This commit is contained in:
@@ -388,15 +388,13 @@
|
||||
admin.api.copyText('[lay-id=' + options.id + ']');
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* 为空时认为自己是普通状态,否则是单选、多选、子页面,此时添加等默认行为走弹框而不是新标签页
|
||||
*/
|
||||
selectMode = admin.getQueryVariable("select_mode");
|
||||
|
||||
selectConfirmCallback = admin.getQueryVariable('select_confirm_callback', 'onTableDataConfirm');
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (selectMode == 'checkbox') {
|
||||
if (options.cols[0][0].type == 'radio') {
|
||||
options.cols[0][0].type = 'checkbox';
|
||||
@@ -415,8 +413,13 @@
|
||||
});
|
||||
|
||||
}
|
||||
} else {
|
||||
if(!admin.isParentIndex()){
|
||||
selectMode = 'childPage'
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// 判断元素对象是否有嵌套的
|
||||
options.cols = admin.table.formatCols(options.cols, options.init);
|
||||
|
||||
@@ -3147,6 +3150,16 @@
|
||||
}
|
||||
return false;
|
||||
},
|
||||
isParentIndex(){
|
||||
try {
|
||||
if (window.parent && window.parent.pageType && window.parent.pageType == 'index') {
|
||||
return true;
|
||||
}
|
||||
} catch (e) {
|
||||
return false;
|
||||
}
|
||||
return false;
|
||||
},
|
||||
findIndexPage(findCallback, missCallback) {
|
||||
if (!findCallback) {
|
||||
findCallback = function (w) { return w; };
|
||||
|
||||
Reference in New Issue
Block a user