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