Commit 5168bcdd by Takumi Imai

#49772 ローディング

parent 4d6db034
......@@ -38,7 +38,10 @@ COMMON.showLoading = function () {
* close loading
*/
COMMON.closeLoading = function () {
setTimeout(function () {
$('#contentFieldOrverlay').show();
$.LoadingOverlay('hide');
}, 500);
};
/**
......
......@@ -138,18 +138,3 @@ $('.view-menu .view-block-btn').on('click', function () {
$('.view-content').removeClass('view-list');
$('.view-content').addClass('view-block');
});
/** loading */
$(function () {
function e() {
setTimeout(function () {
$.LoadingOverlay('hide');
}, 2000);
}
$('.search-form-btn').on('click', function () {
$.LoadingOverlay('show', {
image: 'img/loading.gif',
});
e();
});
});
......@@ -5,55 +5,53 @@
* @since cms:1.4.3.2&1.4.3.3 web:1.0
*/
var HEADER = {};
var HEADER = {};
$(function () {
COMMON.showLoading();
});
/** Direct home page setting */
HEADER.goToHomePage = function (pageId) {
/** Direct home page setting */
HEADER.goToHomePage = function (pageId) {
DashboardSetting.getSettingData(function (settings) {
if(settings.dashboardHome == 1)
{
if (settings.dashboardHome == 1) {
sessionStorage.activeHomePage = CONSTANT.PAGE_NAME.DASHBOARD;
HEADER.goDashboard();
}
else
{
} else {
sessionStorage.activeHomePage = CONSTANT.PAGE_TAB.OPERATION_LIST;
HEADER.goOperationList();
}
});
}
};
/**
/**
* Go page of operationList
*/
HEADER.goOperationList = function () {
HEADER.goOperationList = function () {
OL.init();
};
};
/**
/**
* Go page of dashboard
*/
HEADER.goDashboard = function () {
HEADER.goDashboard = function () {
sessionStorage.activeHomePage = CONSTANT.PAGE_NAME.DASHBOARD;
COMMON.avwScreenMove("dashboard.html");
};
COMMON.avwScreenMove('dashboard.html');
};
/**
/**
* Initialize with any navigation
*
* @param {String} bottomNav
*/
HEADER.activeInitBottomNav = function (bottomNav) {
HEADER.activeInitBottomNav = function (bottomNav) {
HEADER.inactiveAllBottomNav();
HEADER.activeBottomNav(bottomNav);
};
};
/**
/**
* change inactive all footer bottom
*/
HEADER.inactiveAllBottomNav = function () {
HEADER.inactiveAllBottomNav = function () {
let navs = document.getElementsByClassName('bottom-nav');
for (i = 0; i < navs.length; i++) {
navs[i].className = navs[i].className.replace('text-primary', 'text-secondary');
......@@ -62,15 +60,14 @@
img.src = img.getAttribute('data-inactive-src');
}
}
};
};
/**
/**
* Change specific footer bottom to active.
*
* @param {String} bottomNavId
*/
HEADER.activeBottomNav = function (bottomNavId) {
HEADER.activeBottomNav = function (bottomNavId) {
let elm = $('#' + bottomNavId);
if (typeof elm !== 'object') {
console.log('HEADER.activeBottomNav:elm !== object:' + bottomNavId);
......@@ -82,4 +79,4 @@
if (img && img.getAttribute('data-src')) {
img.src = img.getAttribute('data-src');
}
};
};
......@@ -27,7 +27,7 @@
</head>
<body>
<div id="contentFieldOrverlay" style="display: none;">
<!-- header -->
<div id="includedHeader"></div>
......@@ -99,6 +99,7 @@
<div id="includedConfirmModal"></div>
<script type="text/javascript" src="../common/js/app.js?__UPDATEID__"></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</div>
</body>
</html>
......@@ -37,6 +37,7 @@
</head>
<body>
<div id="contentFieldOrverlay" style="display: none;">
<!-- header -->
<div id="includedHeader"></div>
<!-- dashboard -->
......@@ -67,5 +68,6 @@
<div id="includedConfirmModal"></div>
<script type="text/javascript" src="../common/js/app.js?__UPDATEID__"></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</div>
</body>
</html>
\ No newline at end of file
......@@ -21,8 +21,6 @@
<script src="../common/js/constant.js?__UPDATEID__"></script>
<script src="../common/js/common.js?__UPDATEID__"></script>
<script src="../common/js/header.js?__UPDATEID__"></script>
<script src="../common/js/app.js?__UPDATEID__" defer></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/gasparesganga-jquery-loading-overlay@2.1.7/dist/loadingoverlay.min.js"></script>
......@@ -31,11 +29,11 @@
<script src="../js/dashboard/dashboard.js?__UPDATEID__"></script>
<script src="../js/template/template.js?__UPDATEID__"></script>
<script src="../js/topPage/topPage.js?__UPDATEID__"></script>
<script src="../js/reportForm/reportForm.js?__UPDATEID__" defer></script>
<script src="../js/reportForm/reportForm.js?__UPDATEID__"></script>
</head>
<body>
<div id="contentFieldOrverlay" style="display: none;">
<!-- header -->
<div id="includedHeader"></div>
<!-- task list -->
......@@ -147,5 +145,8 @@
<p id="checkLoadingMessage"></p>
<div id="checkLoadingImage"><img src='######' /></div>
</div>
</div>
<script src="../common/js/app.js?__UPDATEID__" defer></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</body>
</html>
......@@ -33,7 +33,7 @@
</head>
<body>
<div id="contentFieldOrverlay" style="display: none;">
<!-- header -->
<div id="includedHeader"></div>
......@@ -60,6 +60,7 @@
<div id="includedConfirmModal"></div>
<script type="text/javascript" src="../common/js/app.js?__UPDATEID__"></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</div>
</body>
</html>
\ No newline at end of file
......@@ -42,7 +42,8 @@
</script>
</head>
<body >
<body>
<div id="contentFieldOrverlay" style="display: none;">
<div id="includedHeader"></div>
<!-- pickup -->
<main>
......@@ -141,6 +142,7 @@
<div id="includedConfirmModal"></div>
<script type="text/javascript" src="../common/js/app.js?__UPDATEID__"></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</div>
</body>
</html>
\ No newline at end of file
......@@ -33,7 +33,7 @@
</head>
<body>
<div id="contentFieldOrverlay" style="display: none;">
<!-- header -->
<div id="includedHeader"></div>
<!-- message detail -->
......@@ -73,6 +73,7 @@
</main>
<script type="text/javascript" src="../common/js/app.js"></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</div>
</body>
</html>
\ No newline at end of file
......@@ -33,8 +33,7 @@
</head>
<body>
<div id="contentFieldOrverlay" style="display: none;">
<div id="includedHeader"></div>
<!-- message list -->
<main>
......@@ -54,5 +53,6 @@
</main>
<script type="text/javascript" src="../common/js/app.js"></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</div>
</body>
</html>
\ No newline at end of file
......@@ -21,13 +21,13 @@
<script type="text/javascript" src="../common/js/constant.js?__UPDATEID__"></script>
<script type="text/javascript" src="../common/js/common.js?__UPDATEID__"></script>
<script type="text/javascript" src="../js/header/header.js?__UPDATEID__"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/gasparesganga-jquery-loading-overlay@2.1.7/dist/loadingoverlay.min.js"></script>
<script src="../js/reportForm/reportForm.js?__UPDATEID__"></script>
</head>
<body onload="RF.init();">
<div id="contentFieldOrverlay" style="display: none;">
<!-- header -->
<div id="includedHeader"></div>
......@@ -62,5 +62,6 @@
<div id="includedConfirmModal"></div>
<script type="text/javascript" src="../common/js/app.js?__UPDATEID__"></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</div>
</body>
</html>
\ No newline at end of file
......@@ -33,8 +33,8 @@
</script>
</head>
<body >
<body>
<div id="contentFieldOrverlay" style="display: none;">
<!-- header -->
<div id="includedHeader"></div>
<div id="includedMainTitle"></div>
......@@ -46,6 +46,7 @@
<div id="includedConfirmModal"></div>
<script type="text/javascript" src="../common/js/app.js?__UPDATEID__"></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</div>
</body>
</html>
......@@ -36,7 +36,7 @@
</head>
<body>
<div id="contentFieldOrverlay" style="display: none;">
<div id="includedHeader"></div>
<!-- send message -->
<main>
......@@ -91,6 +91,7 @@
<div id="includeTemplateModal"></div>
<script type="text/javascript" src="../common/js/app.js"></script>
<script src="../common/js/event.js?__UPDATEID__"></script>
</div>
</body>
</html>
\ No newline at end of file
......@@ -134,6 +134,7 @@ DASHBOARD.init = function () {
DASHBOARD.initCommunications();
});
});
COMMON.closeLoading();
};
/** load common data */
DASHBOARD.loadCommon = function () {
......
......@@ -14,6 +14,8 @@ PP.init = function () {
PP.loadCommon();
PP.initPdfList();
COMMON.closeLoading();
};
PP.loadCommon = function () {
......
......@@ -150,6 +150,7 @@ PICKUP.init = function () {
TEMPLATE.loadMainNavsTitle('#includedMainTitle', 'pickup', navs, null);
PICKUP.initSettingActivePickup();
PICKUP.settingPickup();
COMMON.closeLoading();
};
/**
* Setting pickup data
......
......@@ -48,6 +48,7 @@ PushMessageDetail.init = function () {
PushMessageDetail.getMessageDetail(urlParam.pushMessageId, function (message) {
PushMessageDetail.showMessage(message);
});
COMMON.closeLoading();
};
/**
......
......@@ -25,6 +25,7 @@ PushMessageList.init = function () {
PushMessageList.getMessageList(function (messageList) {
PushMessageList.generateMessageListHtml(messageList.pushMessageList);
});
COMMON.closeLoading();
};
/**
......
......@@ -12,6 +12,7 @@ RF.init = function () {
RF.loadCommon();
RF.initFormView();
COMMON.closeLoading();
};
RF.loadCommon = function () {
......@@ -36,6 +37,7 @@ RF.initFormView = function () {
params.sid = COMMON.getSid();
params.operationId = operationId;
params.lang = I18N.getCurrentLanguage;
if (taskKey) params.taskKey = taskKey;
if (replyNo) params.replyNo = replyNo;
if (processKey) params.processKey = processKey;
......
......@@ -13,11 +13,12 @@ RL.init = function () {
RL.checkQuickReport();
RL.loadCommon();
RL.initTaskReportList();
COMMON.closeLoading();
};
RL.loadCommon = function() {
TEMPLATE.loadHearder("#includedHeader");
TEMPLATE.loadConfirmModal("#includedConfirmModal");
RL.loadCommon = function () {
TEMPLATE.loadHearder('#includedHeader');
TEMPLATE.loadConfirmModal('#includedConfirmModal');
const navs = [
{
titleLang: 'dashboard',
......@@ -27,29 +28,35 @@ RL.loadCommon = function() {
titleLang: 'pickup',
},
];
TEMPLATE.loadMainNavsTitle("#includedMainTitle", "reportList", navs, RL.loadMainTitleCallback);
}
TEMPLATE.loadMainNavsTitle('#includedMainTitle', 'reportList', navs, RL.loadMainTitleCallback);
};
RL.isQuickReport;
RL.checkQuickReport = function() {
RL.checkQuickReport = function () {
if (sessionStorage.OL_operationId) {
let params = {};
params.sid = COMMON.getSid();
params.operationId = sessionStorage.OL_operationId;
params.returnUrl = CONSTANT.URL.WEB.BASE + CONSTANT.URL.WEB.OPERATION_LIST;
let url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath()) + CONSTANT.URL.CMS.API.IS_QUICK_REPORT;
COMMON.cmsAjax(url, params, false, function(result) {
COMMON.cmsAjax(
url,
params,
false,
function (result) {
RL.isQuickReport = result.isQuickReport;
}, function() {
COMMON.displayAlert("msgOperationEmpty");
COMMON.avwScreenMove("index.html");
});
},
function () {
COMMON.displayAlert('msgOperationEmpty');
COMMON.avwScreenMove('index.html');
},
);
} else {
COMMON.displayAlert("error");
COMMON.avwScreenMove("index.html");
COMMON.displayAlert('error');
COMMON.avwScreenMove('index.html');
}
}
};
RL.initTaskReportList = function () {
if (sessionStorage.OL_operationId) {
......@@ -68,7 +75,6 @@ RL.initTaskReportList = function () {
RL.loadMainTitleCallback = function () {
//add dashboard setting item
if (RL.isQuickReport) {
var elmA = $('<div id="btnPdfPrint" onclick="RL.goPdfPrint();">');
let elmImg = $('<img src="../common/img/icon_pdf.svg" alt="pdf出力" class="p-1 w-40px" data-toggle="tooltip" data-placement="bottom" title="pdf出力">');
elmImg.attr('title', I18N.i18nText('reportList'));
......
......@@ -129,4 +129,6 @@ SendMessage.init = function () {
I18N.initi18n();
$("label[for='sendTypeGroup']").append(I18N.i18nText('labelSendTypeGroup'));
$("label[for='sendTypeAll']").append(I18N.i18nText('labelSendTypeAll'));
COMMON.closeLoading();
};
......@@ -11,6 +11,7 @@ $(document).ready(function () {
COMMON.checkAuth(false);
SETTINGS.initScreen();
$('#dspPwdUpd1').click(SETTINGS.dspPwdUpd1_Click);
COMMON.closeLoading();
});
// Process changing password
......
......@@ -19,7 +19,6 @@ $(document).ready(function () {
* show page
*/
TOP.init = function () {
COMMON.showLoading();
HEADER.goToHomePage();
COMMON.closeLoading();
};
......
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