Commit 4a6c5f41 by Lee Munkyeong

カテゴリーパンクズ対応

parent c2efed99
......@@ -2739,17 +2739,21 @@ CHK.showWhiteFrame = function() {
CHK.createCategory = function(operationGroupMasterList) {
if (CHK.isAndroid) {
$('.group-category-list').remove();
$(".group-category-list").remove();
$("#groupMasterPath").empty();
if (typeof CHK.operationGroupMasterId == 'undefined' || CHK.operationGroupMasterId == 0) {
$("#groupMasterPath").append('<li class="breadcrumb-item"><a href="#" class="text-decoration-none text-dark">' + getMsg("all") + '</a></li>');
} else {
$("#groupMasterPath").append('<li class="breadcrumb-item"><a href="#" class="text-decoration-none text-dark">' + CHK.operationGroupMasterId + '</a></li>');
var groupMaster = operationGroupMasterList.filter(it => it.operationGroupMasterId == CHK.operationGroupMasterId)[0];
var groupMasterPathIdlist = groupMaster.treePath.split('/');
groupMasterPathIdlist.forEach( function (parentId){
var pathOperationGroupMaster = operationGroupMasterList.filter(it => it.operationGroupMasterId == parentId)[0];
$("#groupMasterPath").append('<li class="breadcrumb-item"><a onclick="CHK.changeOperationGroupMaster('
+ pathOperationGroupMaster.operationGroupMasterId + ');" class="text-decoration-none text-dark">'
+ pathOperationGroupMaster.operationGroupMasterName + '</a></li>');
});
}
}
//パンくずリスト初期表示(全体)
$('.breadcrumb li').eq(1).hide();
$('.breadcrumb li').eq(2).hide();
//サイドメニューカテゴリー構造作成
operationGroupMasterList.sort((a, b) => (a.operationGroupMasterId > b.operationGroupMasterId) ? 1 : -1);
......@@ -2895,7 +2899,9 @@ function acdMenu() {
}
CHK.changeOperationGroupMaster = function(operationGroupMasterId) {
$('#category-toggle-button').click();
if ($("#category-menu").hasClass("open")) {
$('#category-toggle-button').click();
}
CHK.operationGroupMasterId = operationGroupMasterId;
CHK.createCategory(CHK.operationGroupMaster.operationGroupMasterList);
CHK.search();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment