Commit 234a1a65 by Takumi Imai

Merge branch 'feature/1.0_check_web_dev_kdh_2' into 'feature/1.0_check_web_dev'

change url path for develop server

See merge request !33
parents 15e918ab b4c0e28e
......@@ -292,8 +292,7 @@
COMMON.checkAuth = function (async = true) {
let params = {};
params.sid = COMMON.getSid;
var urlPath = ClientData.userInfo_accountPath();
const url = CONSTANT.URL.CMS.BASE + urlPath + CONSTANT.URL.CMS.API.BASE + CONSTANT.URL.CMS.API.AUTH_SESSION;
const url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.AUTH_SESSION;
COMMON.cmsAjax(url, params, async, null, function () {
COMMON.goUrlWithCurrentParams(CONSTANT.PAGE_NAME.LOGIN);
});
......@@ -418,11 +417,11 @@
return SessionStorageUtils.get(CONSTANT.KEYS.conf_apiLoginUrl);
}
},
conf_checkApiLoginUrl: function (data) {
conf_checkApiUrl: function (data) {
if (arguments.length > 0) {
SessionStorageUtils.set(CONSTANT.KEYS.conf_checkApiLoginUrl, data);
SessionStorageUtils.set(CONSTANT.KEYS.conf_checkApiUrl, data);
} else {
return SessionStorageUtils.get(CONSTANT.KEYS.conf_checkApiLoginUrl);
return SessionStorageUtils.get(CONSTANT.KEYS.conf_checkApiUrl);
}
},
conf_apiResourceDlUrl: function (data) {
......
......@@ -48,21 +48,28 @@ CONSTANT.REPLY_NO = {
CONSTANT.URL = {
CMS: {
// BASE_CMS: 'https://' + location.host + '/checkapi/web/',
BASE: 'http://localhost:8080/acms/',
//BASE: 'https://chatdev2.agentec.jp/acms/',
API: {
BASE: '/checkapi/web/',
ALL_OPERATION_LIST: 'operationListWeb/getOperationList',
AUTH_SESSION: 'getSession/checkAuthUser',
OPERATION_VIEW_LOG: 'operationViewLog/saveLog',
PASSWORD_CHANGE: 'passwordChangeWeb/',
LOGIN: 'webClientLogin/',
LOGOUT: 'logoutWeb/',
DASHBOARD: 'dashboard/',
DASHBOARD_SETTING: 'dashboardSetting/',
SAVE_DASHBOARD_SETTING: 'saveDashboardSetting/',
PUSH_MESSAGE_TEMPLATE: 'pushMessageTemplate/',
OPERATION_SELECT: 'operationSelect/',
NEW_REPORT: 'newReport/',
WORKING_FLOW: 'workingFlow/',
WARNING_WITH_REPORT: 'warningWithReport/',
PUSH_MESSAGE_DETAIL: 'pushMessageDetail/',
PUSH_MESSAGE_LIST: 'pushMessageList/',
SEND_PUSH_MESSAGE: 'sendPushMessage/',
},
HTML: {
BASE: '/checkapi/web/html/',
BASE: 'html/',
TASK_REPORT_LIST: 'getTaskReport/',
LIST_REPORT_FORM: 'listReportForm/showReport',
REPORT_LIST: 'reportList',
......@@ -115,7 +122,7 @@ CONSTANT.KEYS = {
pushInfo_newMsgNumber: 'pushInfo_newMsgNumber',
conf_apiUrl: 'conf_apiUrl',
conf_apiLoginUrl: 'conf_apiLoginUrl',
conf_checkApiLoginUrl: 'conf_checkApiLoginUrl',
conf_checkApiUrl: 'conf_checkApiUrl',
conf_apiResourceDlUrl: 'conf_apiResourceDlUrl',
// Session :ABookCheck:Char (Y: Yes, N: No)
serviceOpt_abook_check: 'abook_check',
......
{
"apiUrl" : "http://localhost:8080/acms/{0}/abvapi",
"checkApiLoginUrl" : "http://localhost:8080/acms/{0}/checkapi/web",
"checkApiUrl" : "http://localhost:8080/acms/{0}/checkapi/web/",
"apiLoginUrl" : "http://localhost:8080/acms/nuabvapi",
"apiResourceDlUrl" : "http://localhost:8080/acms/{0}/dl",
"1apiUrl" : "https://chatdev2.agentec.jp/acms/{0}/abvapi",
"1checkApiLoginUrl" : "https://chatdev2.agentec.jp/acms/{0}/checkapi/web",
"1checkApiUrl" : "https://chatdev2.agentec.jp/acms/{0}/checkapi/web/",
"1apiLoginUrl" : "https://chatdev2.agentec.jp/acms/nuabvapi",
"1apiResourceDlUrl" : "https://chatdev2.agentec.jp/acms/{0}/dl",
"bookShelfCount" : 15,
......
......@@ -26,7 +26,8 @@
<script type="text/javascript" src="../js/dashboardSetting/dashboard-setting.js"></script>
<script type="text/javascript" src="../js/template/template.js"></script>
<script type="text/javascript" src="../js/dashboard/dashboard.js"></script>
<script src="https://cdn.jsdelivr.net/npm/gasparesganga-jquery-loading-overlay@2.1.7/dist/loadingoverlay.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
DASHBOARD.init();
......
......@@ -22,6 +22,9 @@
<script type="text/javascript" src="../common/js/common.js?__UPDATEID__"></script>
<script type="text/javascript" src="../js/header/header.js?__UPDATEID__"></script>
<script type="text/javascript" src="../js/reportList/reportList.js?__UPDATEID__"></script>
<script src="https://cdn.jsdelivr.net/npm/gasparesganga-jquery-loading-overlay@2.1.7/dist/loadingoverlay.min.js"></script>
</head>
<body onload="RL.init();">
......@@ -56,8 +59,8 @@
<!-- confirm -->
<div id="includedConfirmModal"></div>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
<script type="text/javascript" src="../common/js/web/app.js?__UPDATEID__"></script>
<script type="text/javascript" src="../common/js/web/common.js?__UPDATEID__"></script>
<script type="text/javascript" src="../common/js/newdash/app.js?__UPDATEID__"></script>
<script type="text/javascript" src="../common/js/newdash/common.js?__UPDATEID__"></script>
</body>
</html>
......@@ -27,7 +27,7 @@ DASHBOARD.defaultDashboard = {
pushMesage: 0,
};
DASHBOARD.getDataApiUrl = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + 'dashboard/';
DASHBOARD.getDataApiUrl = COMMON.format(ClientData.conf_checkApiUrl(), urlPath) + CONSTANT.URL.CMS.API.DASHBOARD;
/**
* Call api get data
......
......@@ -17,7 +17,7 @@ DashboardSetting.elementItems = {
dashboardHome: { id: 'settingDashboardHome', name: 'chk-home', enabled: false },
};
DashboardSetting.baseApiUrl = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + 'dashboardSetting/';
DashboardSetting.baseApiUrl = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.DASHBOARD_SETTING;
/**
* default setting
......@@ -122,7 +122,7 @@ DashboardSetting.saveSetting = function () {
const element = DashboardSetting.elementItems[key];
param[key] = element.enabled ? 1 : 0;
}
const url = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + 'saveDashboardSetting/';
const url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.SAVE_DASHBOARD_SETTING;
COMMON.cmsAjax(url, param, false, function (json) {
DashboardSetting.closeModal();
if (DashboardSetting.changeSettingCallback && typeof DashboardSetting.changeSettingCallback === 'function') {
......
......@@ -20,7 +20,7 @@ HEADER.processLogout = function() {
var params = {
sid: ClientData.userInfo_sid()
};
const url = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + CONSTANT.URL.CMS.API.LOGOUT;
const url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.LOGOUT;
COMMON.cmsAjax(url, params, false,
function (data) {
if (data.httpStatus == CONSTANT.HTTP_STATUS.OK) {
......
......@@ -185,9 +185,8 @@ LOGIN.processLogin = function() {
if (ClientData.userInfo_sid_local()) {
params.previousSid = ClientData.userInfo_sid_local();
}
// Get url to login
url = CONSTANT.URL.CMS.BASE + accountPath + CONSTANT.URL.CMS.API.BASE + CONSTANT.URL.CMS.API.LOGIN;
url = COMMON.format(ClientData.conf_checkApiUrl(), accountPath) + CONSTANT.URL.CMS.API.LOGIN;
COMMON.cmsAjax(url, params, true, function(data) {
LOGIN.userinfo_sid = data.sid;
......@@ -335,7 +334,7 @@ LOGIN.changePasswordProcess = function() {
params.language = I18N.getCurrentLanguage();
}
const url = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + CONSTANT.URL.CMS.API.PASSWORD_CHANGE;
const url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.PASSWORD_CHANGE;
COMMON.cmsAjax(url, params, false, function(result) {
if (result.httpStatus == '200') {
......@@ -548,7 +547,7 @@ LOGIN.ready = function() {
// set api connection
ClientData.conf_apiUrl(siteUrl + "{0}/abvapi");
ClientData.conf_apiLoginUrl(siteUrl + "nuabvapi");
ClientData.conf_checkApiLoginUrl(siteUrl + "checkapi/web");
ClientData.conf_checkApiUrl(siteUrl + "checkapi/web");
ClientData.conf_apiResourceDlUrl(siteUrl + "{0}/dl");
// set account setting value
ClientData.userInfo_accountPath(urlPath);
......@@ -561,7 +560,7 @@ LOGIN.ready = function() {
} else {
// conf parameter set
ClientData.conf_apiUrl(sysSettings.apiUrl);
ClientData.conf_checkApiLoginUrl(sysSettings.checkApiLoginUrl);
ClientData.conf_checkApiUrl(sysSettings.checkApiUrl);
ClientData.conf_apiLoginUrl(sysSettings.apiLoginUrl);
ClientData.conf_apiResourceDlUrl(sysSettings.apiResourceDlUrl);
}
......
......@@ -20,7 +20,7 @@ NotificationSelect.getNotificationSelectData = function (callback) {
let param = {
sid: COMMON.getSid(),
};
const url = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + 'pushMessageTemplate/';
const url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.PUSH_MESSAGE_TEMPLATE;
COMMON.cmsAjax(url, param, false, function (json) {
if (callback) {
callback(json);
......
......@@ -64,7 +64,7 @@ OL.getAllDataWeb = function (searchKeyWord, sortIndex, searchStartDate, searchEn
param.operationGroupMasterId = operationGroupMasterId;
}
const url = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + CONSTANT.URL.CMS.API.ALL_OPERATION_LIST;
const url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.ALL_OPERATION_LIST;
COMMON.cmsAjax(url, param, false, function (json) {
OL.saveSearchKeyWord(searchKeyWord, sortIndex, searchStartDate, searchEndDate, operationGroupMasterId);
......@@ -527,7 +527,7 @@ OL.saveOperationReadingLog = function (operationId, operationType, reportType) {
params.operationType = operationType;
params.reportType = reportType;
params.viewingStartDate = COMMON.currentTime();
const url = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + CONSTANT.URL.CMS.API.OPERATION_VIEW_LOG;
const url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.OPERATION_VIEW_LOG;
COMMON.cmsAjax(url, params, false);
};
......@@ -539,7 +539,7 @@ OL.saveOperationReadingLog = function (operationId, operationType, reportType) {
* @returns url
*/
OL.createUrlOfOperation = function (enableAddReport, reportType) {
let baseUrl = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.HTML.BASE;
let baseUrl = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.HTML.BASE;
if (reportType == CONSTANT.REPORT_TYPE.ROUTINE || enableAddReport == '1') {
return baseUrl + CONSTANT.URL.CMS.HTML.TASK_REPORT_LIST;
} else {
......
......@@ -22,7 +22,7 @@ OperationSelect.getOperationSelectData = function (callback) {
let param = {
sid: COMMON.getSid(),
};
const url = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + 'operationSelect/';
const url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.OPERATION_SELECT;
COMMON.cmsAjax(url, param, false, function (json) {
if (callback) {
callback(json);
......
......@@ -47,10 +47,10 @@ PICKUP.defaultPickupList = {
operationList:[]
}
PICKUP.baseApiUrl = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE ;
PICKUP.getNewReportListApiUrl = PICKUP.baseApiUrl + 'newReport/';
PICKUP.getContinuousWorkListApiUrl = PICKUP.baseApiUrl + 'workingFlow/';
PICKUP.getReportWithWarningsListApiUrl = PICKUP.baseApiUrl + 'warningWithReport/';
PICKUP.baseApiUrl = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath);
PICKUP.getNewReportListApiUrl = PICKUP.baseApiUrl + CONSTANT.URL.CMS.API.NEW_REPORT;
PICKUP.getContinuousWorkListApiUrl = PICKUP.baseApiUrl + CONSTANT.URL.CMS.API.WORKING_FLOW;
PICKUP.getReportWithWarningsListApiUrl = PICKUP.baseApiUrl + CONSTANT.URL.CMS.API.WARNING_WITH_REPORT;
/**
* Call get new report list api get data
......
var PushMessageDetail = {};
PushMessageDetail.baseApiUrl = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + 'pushMessageDetail/';
PushMessageDetail.baseApiUrl = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.PUSH_MESSAGE_DETAIL;
/**
* dummy json for test
......
......@@ -3,7 +3,7 @@
* @since cms:1.4.3.2&1.4.3.3 web:1.0
*/
var PushMessageList = {};
PushMessageList.baseApiUrl = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + 'pushMessageList/';
PushMessageList.baseApiUrl = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + '';
/**
* Init when html onload
......
......@@ -3,7 +3,8 @@
var RL = {};
RL.init = function() {
COMMON.checkAuth(false);
console.log("kdh check ok");
// COMMON.checkAuth(true);
RL.loadCommon();
RL.initTaskReportList();
......@@ -25,7 +26,7 @@ RL.initTaskReportList = function() {
params.sid = COMMON.getSid();
params.operationId = sessionStorage.OL_operationId;
params.returnUrl = CONSTANT.URL.WEB.BASE + CONSTANT.URL.WEB.OPERATION_LIST;
let url = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.HTML.BASE + CONSTANT.URL.CMS.HTML.TASK_REPORT_LIST;
let url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.HTML.BASE + CONSTANT.URL.CMS.HTML.TASK_REPORT_LIST;
// COMMON.postCommunication(url, params);
$("#task-list").load(url, params);
// COMMON.cmsAjax(url, params, false, function(result) {
......
......@@ -5,7 +5,7 @@
*/
var SendMessage = {};
SendMessage.baseApiUrl = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + 'sendPushMessage/';
SendMessage.baseApiUrl = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.SEND_PUSH_MESSAGE;
/**
* Get input content
......
......@@ -77,7 +77,7 @@ SETTINGS.dspPwdUpd1_Click = function(e) {
language: I18N.getCurrentLanguage(),
appId: 4
};
const url = CONSTANT.URL.CMS.BASE + ClientData.userInfo_accountPath() + CONSTANT.URL.CMS.API.BASE + CONSTANT.URL.CMS.API.PASSWORD_CHANGE;
const url = COMMON.format(ClientData.conf_checkApiUrl(), ClientData.userInfo_accountPath) + CONSTANT.URL.CMS.API.PASSWORD_CHANGE;
COMMON.cmsAjax(url, params, false,
SETTINGS.avwCmsApi_passwordChange_success,
SETTINGS.avwCmsApi_passwordChange_fail);
......
......@@ -25,6 +25,7 @@ modify_api()
"apiUrl" : "$URI_PREFIX/{0}/abvapi",
"apiLoginUrl" : "$URI_PREFIX/nuabvapi",
"apiResourceDlUrl" : "$URI_PREFIX/{0}/dl",
"checkApiUrl" : "$URI_PREFIX/{0}/checkapi/web/",
"bookShelfCount" : 15,
"bookListCount" : 15,
"screenlockTimeDefault" : 30,
......
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