Commit 5c66731e by Masaru Abe

#12786 1.11.0対応

parent 95342c7f
...@@ -57,7 +57,7 @@ var UserEnvironment = function() { ...@@ -57,7 +57,7 @@ var UserEnvironment = function() {
}; };
/** check user browser */ /** check user browser */
function checkBrowser(userAgent) { function checkBrowser(userAgent) {
if(userAgent.toLowerCase().indexOf("msie") >= 0) { if(userAgent.toLowerCase().indexOf("msie") >= 0 || userAgent.toLowerCase().indexOf("trident") >= 0) {
return "msie"; return "msie";
} }
if(userAgent.toLowerCase().indexOf("firefox") >= 0) { if(userAgent.toLowerCase().indexOf("firefox") >= 0) {
......
...@@ -161,6 +161,11 @@ var Keys = { ...@@ -161,6 +161,11 @@ var Keys = {
serviceOpt_marking: 'marking', serviceOpt_marking: 'marking',
// Session :事業者オプション(serviceOpt)_一定期間経過後アプリロック:Char(Y:可能, N:不可) // Session :事業者オプション(serviceOpt)_一定期間経過後アプリロック:Char(Y:可能, N:不可)
serviceOpt_force_login_periodically: 'force_login_periodically', serviceOpt_force_login_periodically: 'force_login_periodically',
// Session :事業者オプション(serviceOpt)_パスワード変更:Char(Y:可能, N:不可)
serviceOpt_change_pw: 'change_pw',
// Session :事業者オプション(serviceOpt)_パスワードポリシー:Integer(0:標準, 1:S社)
serviceOpt_password_policy: 'password_policy',
// Session :共通(common)_コンテンツID:Integer // Session :共通(common)_コンテンツID:Integer
common_contentId: 'common_contentId', common_contentId: 'common_contentId',
// Local :共通(common)_コンテンツID:Integer // Local :共通(common)_コンテンツID:Integer
...@@ -1054,6 +1059,24 @@ var ClientData = { ...@@ -1054,6 +1059,24 @@ var ClientData = {
} }
}, },
// Session :事業者オプション(serviceOpt)_パスワード変更:Char(Y:可能, N:不可)
serviceOpt_change_pw: function (data) {
if (arguments.length > 0) {
SessionStorageUtils.set(Keys.serviceOpt_change_pw, data);
} else {
return SessionStorageUtils.get(Keys.serviceOpt_change_pw);
}
},
// Session :事業者オプション(serviceOpt)_パスワードポリシー:Integer(0:標準, 1:S社)
serviceOpt_password_policy: function (data) {
if (arguments.length > 0) {
SessionStorageUtils.set(Keys.serviceOpt_password_policy, data);
} else {
return SessionStorageUtils.get(Keys.serviceOpt_password_policy);
}
},
// Session :共通(common)_コンテンツID:Integer // Session :共通(common)_コンテンツID:Integer
common_contentId: function (data) { common_contentId: function (data) {
if (arguments.length > 0) { if (arguments.length > 0) {
......
...@@ -35,7 +35,7 @@ $(document).ready(function () { ...@@ -35,7 +35,7 @@ $(document).ready(function () {
ClientData.BookmarkScreen(ScreenIds.BookmarkList); ClientData.BookmarkScreen(ScreenIds.BookmarkList);
//Check if Force Change password //Check if Force Change password
if(ClientData.requirePasswordChange() != 1){ if(ClientData.requirePasswordChange() != 1 || ClientData.serviceOpt_change_pw() == 'N'){
// Synchronize bookmarks with server // Synchronize bookmarks with server
SyncContent(); SyncContent();
......
...@@ -53,7 +53,7 @@ $(document).ready(function(){ ...@@ -53,7 +53,7 @@ $(document).ready(function(){
ClientData.BookmarkScreen(ScreenIds.ContentSearch); ClientData.BookmarkScreen(ScreenIds.ContentSearch);
//Check if Force Change password //Check if Force Change password
if(ClientData.requirePasswordChange() != 1){ if(ClientData.requirePasswordChange() != 1 || ClientData.serviceOpt_change_pw() == 'N'){
//Format text display more record //Format text display more record
formatDisplayMoreRecord(); formatDisplayMoreRecord();
......
...@@ -9,8 +9,6 @@ $(document).ready(function () { ...@@ -9,8 +9,6 @@ $(document).ready(function () {
if (!avwCheckLogin(ScreenIds.Login)) return; if (!avwCheckLogin(ScreenIds.Login)) return;
// Set event to prevent leave // Set event to prevent leave
//avwSetLogoutNortice(); //avwSetLogoutNortice();
if(ClientData.requirePasswordChange() != 1 ) { if(ClientData.requirePasswordChange() != 1 ) {
......
...@@ -52,7 +52,7 @@ $(document).ready(function(){ ...@@ -52,7 +52,7 @@ $(document).ready(function(){
ClientData.BookmarkScreen(ScreenIds.History); ClientData.BookmarkScreen(ScreenIds.History);
if(ClientData.requirePasswordChange() != 1){ if(ClientData.requirePasswordChange() != 1 || ClientData.serviceOpt_change_pw() == 'N'){
if(ClientData.ReadingContentIds() == null || ClientData.ReadingContentIds() == 'undefined' || ClientData.ReadingContentIds().length == 0){ if(ClientData.ReadingContentIds() == null || ClientData.ReadingContentIds() == 'undefined' || ClientData.ReadingContentIds().length == 0){
}else{ }else{
syncReadingContent(); syncReadingContent();
......
...@@ -59,7 +59,7 @@ $(document).ready(function () { ...@@ -59,7 +59,7 @@ $(document).ready(function () {
ClientData.BookmarkScreen(ScreenIds.Home); ClientData.BookmarkScreen(ScreenIds.Home);
//Check if Force Change password //Check if Force Change password
if (ClientData.requirePasswordChange() != 1) { if (ClientData.requirePasswordChange() != 1 || ClientData.serviceOpt_change_pw() == 'N' ) {
// Register log // Register log
RegisterLog(); RegisterLog();
......
...@@ -24,6 +24,8 @@ var force_pw_change_periodically; ...@@ -24,6 +24,8 @@ var force_pw_change_periodically;
var user_data_backup; var user_data_backup;
var marking; var marking;
var force_login_periodically; var force_login_periodically;
var change_pw;
var password_policy;
var login_errorMessage = ""; var login_errorMessage = "";
//Load login Info //Load login Info
...@@ -230,7 +232,7 @@ function processLogin() { ...@@ -230,7 +232,7 @@ function processLogin() {
$('#main-error-message').css('display', 'none'); $('#main-error-message').css('display', 'none');
if (data.requirePasswordChange == 0) { if (data.requirePasswordChange == 0 || change_pw == 'N' ) {
ClientData.userInfo_sid(ClientData.userInfo_sid_local()); ClientData.userInfo_sid(ClientData.userInfo_sid_local());
avwScreenMove("abvw/" + ScreenIds.Home); avwScreenMove("abvw/" + ScreenIds.Home);
} }
...@@ -487,7 +489,13 @@ function saveServiceUserOption(){ ...@@ -487,7 +489,13 @@ function saveServiceUserOption(){
} }
else if(option.serviceName == 'user_data_backup'){ else if(option.serviceName == 'user_data_backup'){
ClientData.serviceOpt_user_data_backup(option.value); ClientData.serviceOpt_user_data_backup(option.value);
} }
else if(option.serviceName == 'change_pw'){
ClientData.serviceOpt_change_pw(option.value);
}
else if(option.serviceName == 'password_policy'){
ClientData.serviceOpt_password_policy(option.value);
}
}); });
}; };
...@@ -510,7 +518,14 @@ function getServiceOptionList(){ ...@@ -510,7 +518,14 @@ function getServiceOptionList(){
} }
else if(option.serviceName == 'user_data_backup'){ else if(option.serviceName == 'user_data_backup'){
user_data_backup = option.value; user_data_backup = option.value;
} }
else if(option.serviceName == 'change_pw'){
change_pw = option.value;
}
else if(option.serviceName == 'password_policy'){
password_policy = option.value;
}
}); });
}; };
......
...@@ -59,12 +59,15 @@ $(document).ready(function () { ...@@ -59,12 +59,15 @@ $(document).ready(function () {
$("#dspOptBk").hide(); $("#dspOptBk").hide();
} }
if ( ClientData.serviceOpt_change_pw() == 'N' ) {
// Get flag to determine must change password $("#dspPwdUpd").hide();
avwCmsApi(ClientData.userInfo_accountPath(), "requirePasswordChange", 'GET', { sid: ClientData.userInfo_sid() }, } else {
avwCmsApi_requirePasswordChange_success, // Get flag to determine must change password
null avwCmsApi(ClientData.userInfo_accountPath(), "requirePasswordChange", 'GET', { sid: ClientData.userInfo_sid() },
); avwCmsApi_requirePasswordChange_success,
null
);
}
// In case: user_data_backup = "Y" -> backup // In case: user_data_backup = "Y" -> backup
if (ClientData.serviceOpt_user_data_backup() != "Y") { if (ClientData.serviceOpt_user_data_backup() != "Y") {
...@@ -526,22 +529,19 @@ function dspPwdUpd1_Click(e) { ...@@ -526,22 +529,19 @@ function dspPwdUpd1_Click(e) {
if (isOK) { if (isOK) {
/*
// Check max length // Check max length
if (!ValidationUtil.CheckMaxLengthForByte(getCurrentPassword(), 16)) { if (!ValidationUtil.CheckMaxLengthForByte(getCurrentPassword(), 16)) {
isOK = false; isOK = false;
} }
if (!ValidationUtil.CheckMaxLengthForByte(getNewPassword(), 16)) { if (!ValidationUtil.CheckMaxLengthForByte(getNewPassword(), 16)) {
isOK = false; isOK = false;
} }
if (!ValidationUtil.CheckMaxLengthForByte(getNewPasswordRe(), 16)) { if (!ValidationUtil.CheckMaxLengthForByte(getNewPasswordRe(), 16)) {
isOK = false; isOK = false;
} }
// Data type // Data type
if (!ValidationUtil.IsAlphabetOrNumberOrSymbol(getCurrentPassword())) { if (!ValidationUtil.IsAlphabetOrNumberOrSymbol(getCurrentPassword())) {
isOK = false; isOK = false;
} }
if (!ValidationUtil.IsAlphabetOrNumberOrSymbol(getNewPassword())) { if (!ValidationUtil.IsAlphabetOrNumberOrSymbol(getNewPassword())) {
...@@ -550,11 +550,8 @@ function dspPwdUpd1_Click(e) { ...@@ -550,11 +550,8 @@ function dspPwdUpd1_Click(e) {
if (!ValidationUtil.IsAlphabetOrNumberOrSymbol(getNewPasswordRe())) { if (!ValidationUtil.IsAlphabetOrNumberOrSymbol(getNewPasswordRe())) {
isOK = false; isOK = false;
} }
*/
var str = getCurrentPassword() + ""; var str = getCurrentPassword() + "";
// if (str.contains("_") || str.contains("‐")) {
// isOK = false;
// }
} }
......
...@@ -133,15 +133,15 @@ ...@@ -133,15 +133,15 @@
<span id="dialog-error-message" class="alertTxtDialog lang"> </span> <span id="dialog-error-message" class="alertTxtDialog lang"> </span>
<dl> <dl>
<dt><label id="lblPwdCur" class="lang" lang="txtPwdCurr">現在パスワード</label></dt> <dt><label id="lblPwdCur" class="lang" lang="txtPwdCurr">現在パスワード</label></dt>
<dd><input type="password" id="txtPwdCur" maxlength="16" /></dd> <dd><input type="password" id="txtPwdCur" maxlength="128" /></dd>
</dl> </dl>
<dl> <dl>
<dt><label id="lblPwdNew" class="lang" lang="txtPwdNew">変更パスワード</label></dt> <dt><label id="lblPwdNew" class="lang" lang="txtPwdNew">変更パスワード</label></dt>
<dd><input type="password" id="txtPwdNew" maxlength="16" /></dd> <dd><input type="password" id="txtPwdNew" maxlength="128" /></dd>
</dl> </dl>
<dl> <dl>
<dt><label id="lblPwdNewRe" class="lang" lang="txtPwdNewRe">(再)変更パスワード</label></dt> <dt><label id="lblPwdNewRe" class="lang" lang="txtPwdNewRe">(再)変更パスワード</label></dt>
<dd><input type="password" id="txtPwdNewRe" maxlength="16" /></dd> <dd><input type="password" id="txtPwdNewRe" maxlength="128" /></dd>
</dl> </dl>
<p><label class="lang" lang="txtPwdRemind" id="txtChangePassComment">※スキップを選択すると、30日間このメッセージは表示されません</label></p> <p><label class="lang" lang="txtPwdRemind" id="txtChangePassComment">※スキップを選択すると、30日間このメッセージは表示されません</label></p>
<p class="loginbtn"><a class="change lang" href="#" id="dspPwdUpd1" lang="dspChange">変更</a><a class="skip lang" href="#" lang="dspSkip" id="dspSkip">スキップ</a><a class="cancel lang" href="#" lang="dspCancel" id="dspCancel">キャンセル</a></p> <p class="loginbtn"><a class="change lang" href="#" id="dspPwdUpd1" lang="dspChange">変更</a><a class="skip lang" href="#" lang="dspSkip" id="dspSkip">スキップ</a><a class="cancel lang" href="#" lang="dspCancel" id="dspCancel">キャンセル</a></p>
......
...@@ -76,15 +76,15 @@ ...@@ -76,15 +76,15 @@
<dl> <dl>
<dt class="lang" lang="txtPwdCurr">現在パスワード:</dt> <dt class="lang" lang="txtPwdCurr">現在パスワード:</dt>
<dd><input type="password" id="txtCurrentPass" maxlength="16" /></dd> <dd><input type="password" id="txtCurrentPass" maxlength="128" /></dd>
</dl> </dl>
<dl> <dl>
<dt class="lang" lang="txtPwdNew">変更パスワード:</dt> <dt class="lang" lang="txtPwdNew">変更パスワード:</dt>
<dd><input type="password" id="txtNewPass" maxlength="16"/></dd> <dd><input type="password" id="txtNewPass" maxlength="128"/></dd>
</dl> </dl>
<dl> <dl>
<dt class="lang" lang="txtPwdNewRe">新パスワード(確認):</dt> <dt class="lang" lang="txtPwdNewRe">新パスワード(確認):</dt>
<dd><input type="password" id="txtConfirmNew" maxlength="16"/></dd> <dd><input type="password" id="txtConfirmNew" maxlength="128"/></dd>
</dl> </dl>
<p class="lang memory" lang="txtPwdRemind" id="txtPwdRemind" >※スキップを選択すると、30日間このメッセージは表示されません</p> <p class="lang memory" lang="txtPwdRemind" id="txtPwdRemind" >※スキップを選択すると、30日間このメッセージは表示されません</p>
<p class="loginbtn"><a class="skip lang" id="btnSkip" lang="dspSkip">スキップ</a><a class="change lang" id="btnChange" lang="dspChange">変更</a></p> <p class="loginbtn"><a class="skip lang" id="btnSkip" lang="dspSkip">スキップ</a><a class="change lang" id="btnChange" lang="dspChange">変更</a></p>
......
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