Commit b374e7c7 by Vo Duc Thang

9/27 Release

parent 3f8dd190
......@@ -64,7 +64,7 @@
"dspBkCancel":"Logout",
"txtSearchResult":"Result",
"dspHome":"Home",
"txtLoginUser":"(Ver.20130926)User:",
"txtLoginUser":"(Ver.20130927)User:",
"txtAll":"All",
"txtMkgSize":"Size",
"txtMkgS":"S",
......
......@@ -64,7 +64,7 @@
"dspBkCancel":"バックアップせずにログアウト",
"txtSearchResult":"検索結果",
"dspHome":"ホーム",
"txtLoginUser":"(Ver.20130926)ログイン中:",
"txtLoginUser":"(Ver.20130927)ログイン中:",
"txtAll":"すべて",
"txtMkgSize":"太さ",
"txtMkgS":"小",
......
......@@ -64,7 +64,7 @@
"dspBkCancel":"로그아웃",
"txtSearchResult":"검색 결과",
"dspHome":"홈",
"txtLoginUser":"(Ver.20130926)로그인 중:",
"txtLoginUser":"(Ver.20130927)로그인 중:",
"txtAll":"전체",
"txtMkgSize":"두께",
"txtMkgS":"소",
......
......@@ -69,7 +69,7 @@
<div class="menu_language">
<div class="clearfix">
<ul class="floatL">
<li class="floatR">
<li class="floatR" id="li-login-username" style="display:none;">
<label class="lang" lang="txtLoginUser">こんにちは</label>
<label id="login-username"> </label>
</li>
......@@ -208,7 +208,7 @@
<li class="date"><label id="txtPubDt2" lang="dspPubDt2" class="lang">発行日:</label><label id="txtPubDt2_Dsp">____/__/__ __:__</label></li>
<li class="explain" id="txtContentDetail">スマートデバイス向け<br />統合ソリューション</li>
</ul>
<p class="read_btn"><a class="read lang" href="#" id="contentdetail_dspRead" lang="txtRead">読む</a></p>
<p class="read_btn"><a class="read lang" id="contentdetail_dspRead" lang="txtRead">読む</a></p>
</div>
<div id="book_list"></div>
......
......@@ -818,7 +818,7 @@ aside.MemoIndexBox .indexBoxBody_off{
.transition {
background: url(../../img/viewer/transitionbtn_bg.png) 0 0 no-repeat;
/*background: url(../../img/viewer/transitionbtn_bg.png) 0 0 no-repeat;*/
}
/*ボタン設定*/
......@@ -883,8 +883,7 @@ aside.MemoIndexBox .indexBoxBody_off{
/*----------------------------*/
.sizing {
background: url(../../img/viewer/sizingbtn_bg.png) 0 0 no-repeat;
/*background: url(../../img/viewer/sizingbtn_bg.png) 0 0 no-repeat;*/
}
/*ボタン設定*/
......
......@@ -68,6 +68,15 @@
<script src="./common/js/screenLock.js" type="text/javascript"></script>
<script src="js/detail.js" type="text/javascript"></script>
<!--[if IE 9 ]>
<style>
.tab_bg_color
{
overflow-x:scroll;
}
</style>
<![endif]-->
</head>
<body id="bookshelf">
......
......@@ -902,40 +902,40 @@ function isPdfContent(contentType){
return true;
}
};
//Get resource Id of content
function downloadResourceById(contentId){
var params = {
sid: ClientData.userInfo_sid(),
contentId: contentId,
getType: '2',
};
var resourceUrl;
abapi('webGetContent', params, 'GET', function (data) {
var resourceId;
$.each(data.contentData , function(i, n){
if(typeof n == "object"){
resourceId = n.resourceId;
}
});
//Get resource
resourceUrl = getResourceByIdFromAPI(resourceId);
window.open(resourceUrl, "_blank");
// redraw content remove new icon
drawEditImage(contentId);
////Get resource Id of content
//function downloadResourceById(contentId){
// var params = {
// sid: ClientData.userInfo_sid(),
// contentId: contentId,
// getType: '2',
// };
//
// var resourceUrl;
//
// abapi('webGetContent', params, 'GET', function (data) {
// var resourceId;
//
// $.each(data.contentData , function(i, n){
// if(typeof n == "object"){
// resourceId = n.resourceId;
// }
// });
//
// //Get resource
// resourceUrl = getResourceByIdFromAPI(resourceId);
//
// window.open(resourceUrl, "_blank");
});
};
// // redraw content remove new icon
// drawEditImage(contentId);
//
// });
//};
//Download resource
function getResourceByIdFromAPI(resourceId){
return getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + resourceId + "&isDownload=true";
};
////Download resource
//function getResourceByIdFromAPI(resourceId){
// return getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + resourceId + "&isDownload=true";
//};
/* get url */
function getURL(apiName) {
......@@ -1034,6 +1034,9 @@ function readSubmenuFunction_callback(contentId)
if(contentType == ContentTypeKeys.Type_Others){
//Download content
downloadResourceById(contentId);
// redraw content remove new icon
drawEditImage(contentId);
}
else{
//Go to Conten view page
......
......@@ -2091,6 +2091,26 @@ function closeDialogResize() {
//Start Function : No.12
var isZoomingContent = false;
//START TRB00075 - Editor: Long - Date - 24/09/2013 - Summary : Fix for prevent moving page when display dialog
function displayOverlayForHtmlAndMediaType(){
var $overlay = $('#overlay');
var $header = $('header');
var $footer = $('footer');
$header.css('position', 'absolute');
$header.css('width', '100%');
$header.css('z-index', '102');
$footer.css('z-index', '102');
$overlay.show();
//START TRB00075 - Editor: Long - Date - 24/09/2013 - Summary : Fix for prevent moving page when display dialog
document.getElementById('overlay').addEventListener('touchstart', function(event){event.preventDefault(); return false;}, false);
document.getElementById('overlay').addEventListener('touchmove', function(event){event.preventDefault(); return false;}, false);
document.getElementById('overlay').addEventListener('touchend', function(event){event.preventDefault(); return false;}, false);
//END TRB00075 - Editor: Long - Date - 24/09/2013 - Summary : Fix for prevent moving page when display dialog
};
//END TRB00075 - Editor: Long - Date - 24/09/2013 - Summary : Fix for prevent moving page when display dialog
//Display overlay dialog for specify content type
function displayOverlayForSpecifyContentType(){
......@@ -2128,6 +2148,16 @@ function displayOverlayForSpecifyContentType(){
}
//Start : TRB00082 - Editor : Long - Date : 09/25/2013 - Summary : For win 8 rotate handling.
setViewportForWin8();
//End : TRB00082 - Editor : Long - Date : 09/25/2013 - Summary : For win 8 rotate handling.
//Start : TRB00075 - Editor : Long - Date : 09/25/2013 - Summary : prevent moving page
if (avwUserEnvObj.os == "ipad") {
displayOverlayForHtmlAndMediaType();
}
//End : TRB00075 - Editor : Long - Date : 09/25/2013 - Summary : prevent moving page
/* window resize event */
$(window).resize(function () {
//START : TRB00034 - DATE : 09/11/2013 - Editor : Long - Summary : Fix for center loading image
......@@ -2166,6 +2196,11 @@ function displayOverlayForSpecifyContentType(){
/* close dialog popuptext */
closeDialogResize();
//START TRB00091 - Editor : LOng - Date : 09/26/2013 - Summary : Dialog at center when rotate
$("#contentVideoConfirm").center();
$("#contentAudioConfirm").center();
//END TRB00091 - Editor : LOng - Date : 09/26/2013 - Summary : Dialog at center when rotate
});
};
......@@ -2178,13 +2213,13 @@ function handleForContentTypeVideo(resourceUrl){
$container.html('');
if (ClientData.userOpt_musicMode() == "1") {
$container.html('<video id="content_video" autoplay="true" loop="true" preload="auto" controls style="position: absolute; width: 100%; height: 90%; bottom: 1% ">'
$container.html('<video id="content_video" autoplay="true" loop="true" controls="controls" style="position: absolute; width: 100%; height: 100%;">'
+ ' <source src="' + resourceUrl + '" type="video/mp4"> '
+ '</video>'
);
}
else {
$container.html('<video id="content_video" autoplay="true" controls style="position: absolute; width: 100%; height: 90%; bottom: 1% ">'
$container.html('<video id="content_video" autoplay="true" controls="controls" style="position: absolute; width: 100%; height: 100%;">'
+ ' <source src="' + resourceUrl + '" type="video/mp4"> '
+ '</video>'
);
......@@ -2411,8 +2446,10 @@ function fullScreenForNotPdfType(){
var h = $("#wrapper").height();
if(contentType == ContentTypeKeys.Type_Video){
if(avwUserEnvObj.os == 'ipad'){
$('#content_video').removeAttr('controls');
}
}
var $container = $('#dialog');
......@@ -2440,9 +2477,6 @@ function originalScreenForNotPdfType(){
$('#control_screen_2').hide();
$('#header_toolbar').show();
var $container = $('#dialog');
$container.removeAttr('style');
......
......@@ -50,13 +50,16 @@ function showAnket(url, fullscreen) {
function () {
var opacity = 1;
//START TRB00092 - EDITOR: Long - Date: 09/26/2013 - Summary : Fix opacity
if ($(this).index() == 0) {
opacity = 0.2;
opacity = 0.6;
}
else if($(this).index()==1)
{
opacity = 0.7;
opacity = 0.8;
}
//END TRB00092 - EDITOR: Long - Date: 09/26/2013 - Summary : Fix opacity
$('#dialog,#dialog iframe,#dialog .anket-commands,#dialog .anket-commands input').css('opacity', opacity);
}
);
......
......@@ -481,6 +481,9 @@ function createLockLayout(opt){
}
};
//START TRB00049 - Editor: Long - Date: 09/26/2013 - Summary : Add short key alt
var altMode = false;
/* handle keydown */
$(document).keydown(function (e) {
/* set fag true when click ctrl */
......@@ -488,8 +491,12 @@ $(document).keydown(function (e) {
ctrlMode = true;
}
if(e.altKey){
altMode = true;
}
/* set hot key */
if (ctrlMode == true) {
if (ctrlMode == true && altMode == false) {
if (ClientData.IsAddingMarking() == true || isLoadingObject == true) {
/* do nothing*/
} else {
......@@ -559,12 +566,37 @@ $(document).keydown(function (e) {
}
}
}
if(altMode == true && ctrlMode == false){
if (ClientData.IsAddingMarking() == true || isLoadingObject == true) {
/* do nothing*/
}
else {
switch (e.keyCode) {
/* zoom */
case ShortKeys.ZoomInAlt: /* zoomIn */
if(contentType == ContentTypeKeys.Type_PDF || contentType == ContentTypeKeys.Type_Image
|| contentType == ContentTypeKeys.Type_NoFile){
zoomIn();
}
break;
case ShortKeys.ZoomOutAlt: /* zoomOut */
if(contentType == ContentTypeKeys.Type_PDF || contentType == ContentTypeKeys.Type_Image
|| contentType == ContentTypeKeys.Type_NoFile){
zoomOut();
}
break;
}
}
}
});
/* handle keydown */
$(document).keyup(function (e) {
ctrlMode = false;
altMode = false;
});
//END TRB00049 - Editor: Long - Date: 09/26/2013 - Summary : Add short key alt
function onUnlock() {
removeObject();
......@@ -932,7 +964,6 @@ function mouseMove_canvasMain(event) {
_3dAction = _3dActionType.TouchMove_MouseMove;
hitObj.action(imagePt);
}
}
else{
_3dAnimate = false;
......@@ -1034,9 +1065,8 @@ function mouseDown_CanvasMain(event) {
_3dAnimate = false;
if(is3DObject(hitPageObj)){
clearTimeout(this.downTimer);
this.downTimer = setTimeout(function() {
//START TRB00090 - Editor: Long - Date : 09/26/2013 - Summary : remove time to detect 3d animate
if(!isPageTransition){
_3dAnimate = true;
_3dAction = _3dActionType.TouchStart_MouseDown;
......@@ -1048,10 +1078,8 @@ function mouseDown_CanvasMain(event) {
_3dAnimate = false;
moveFlag = true;
}
}, _3dTimeToDetect);
//END TRB00090 - Editor: Long - Date : 09/26/2013 - Summary : remove time to detect 3d animate
}
else{
_3dAnimate = false;
}
......@@ -1278,12 +1306,9 @@ function onTouchstart(evt){
_3dAnimate = false;
if (hitPageObj) {
//START TRB00090 - Editor: Long - Date : 09/26/2013 - Summary : remove time to detect 3d animate
if(is3DObject(hitPageObj)){
clearTimeout(this.downTimer);
this.downTimer = setTimeout(function() {
if(isPageTransition){
_3dAnimate = false;
}
else{
......@@ -1292,12 +1317,11 @@ function onTouchstart(evt){
hitPageObj.action(imagePt);
_3dAnimate = true;
}
}, _3dTimeToDetect);
}
else{
_3dAnimate = false;
}
//END TRB00090 - Editor: Long - Date : 09/26/2013 - Summary : remove time to detect 3d animate
}
//End Function : No.9 - Editor : Long - Date : 08/16/2013 - Summary:
}
......@@ -1322,7 +1346,6 @@ function onTouchstart(evt){
y: touch2.clientY
});
px = touch1.clientX+touch2.clientX/2;
py = touch1.clientY+touch2.clientY/2;
......@@ -1373,8 +1396,7 @@ function onTouchstart(evt){
if (hitPageObj) {
if(is3DObject(hitPageObj)){
clearTimeout(this.downTimer);
this.downTimer = setTimeout(function() {
//START TRB00090 - Editor: Long - Date : 09/26/2013 - Summary : remove time to detect 3d animate
if(isPageTransition){
_3dAnimate = false;
_isClick = true;
......@@ -1386,10 +1408,7 @@ function onTouchstart(evt){
_3dAnimate = true;
_isClick = false;
}
}, _3dTimeToDetect);
//END TRB00090 - Editor: Long - Date : 09/26/2013 - Summary : remove time to detect 3d animate
}
else{
_3dAnimate = false;
......
......@@ -315,6 +315,9 @@ function getMediaType1(iValueObj) {
var resourceId = iValueObj.action.resourceId;
var resourceUrl = "";
//START TRB00093 - Editor : Long - Date: 09/26/2013 - Summary : Check undefine before get
if(iValueObj.contentDataSub){
for(var i = 0; i < iValueObj.contentDataSub.length; i++){
var tempData = iValueObj.contentDataSub[i];
......@@ -323,6 +326,8 @@ function getMediaType1(iValueObj) {
break;
}
}
}
//END TRB00093 - Editor : Long - Date: 09/26/2013 - Summary : Check undefine before get
pageObject["imageUrl"] = getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + iValueObj.mediaInfo.resourceId;
pageObject["resourceUrl"] = resourceUrl;
......@@ -662,6 +667,8 @@ function getMediaType9(iValueObj) {
var resourceId = iValueObj.mediaInfo.resourceId;
var resourceUrl = "";
//START TRB00093 - Editor : Long - Date: 09/26/2013 - Summary : Check undefine before get
if(iValueObj.contentDataSub){
for(var i = 0; i < iValueObj.contentDataSub.length; i++){
var tempData = iValueObj.contentDataSub[i];
......@@ -670,6 +677,8 @@ function getMediaType9(iValueObj) {
break;
}
}
}
//START TRB00093 - Editor : Long - Date: 09/26/2013 - Summary : Check undefine before get
pageObject["imageUrl"] = 'img/htmltype.png';
pageObject["resourceUrl"] = resourceUrl;
......
......@@ -143,7 +143,6 @@ function initPage() {
// Lock screen
LockScreen();
StartTimerUpdateLog();
/* set start log */
......@@ -414,6 +413,10 @@ function initPage() {
sizingScreen();
}
}
//Start : TRB00015 - Editor : Long - Date : 08/28/2013 - Summary : For win 8 rotate handling.
setViewportForWin8();
//End : TRB00015 - Editor : Long - Date : 08/28/2013 - Summary : For win 8 rotate handling.
}
//START TRB00048 - EDITOR : Long - Date : 09/18/2013 - Summary :
else if(nAjaxLoad == 4){
......@@ -550,6 +553,10 @@ function initPage() {
sizingScreen();
}
}
//Start : TRB00015 - Editor : Long - Date : 08/28/2013 - Summary : For win 8 rotate handling.
setViewportForWin8();
//End : TRB00015 - Editor : Long - Date : 08/28/2013 - Summary : For win 8 rotate handling.
}
}
......@@ -587,6 +594,13 @@ function initPageMediaAndHtmlType(){
// Lock screen
LockScreen();
//START TRB00094 - Editor : Long - Date : 09/26/2013 - Summary : Setting log
StartTimerUpdateLog();
/* set start log */
SetStartLog(contentID);
//END TRB00094 - Editor : Long - Date : 09/26/2013 - Summary : Setting log
//enable SpecifyControl
enableSpecifyControl();
......
......@@ -219,18 +219,21 @@ function contentdetail_dspRead_Click_callback(outputId) {
if (ClientData.contentInfo_contentType() == ContentTypeKeys.Type_Others) {
// Get content detail
avwCmsApi(ClientData.userInfo_accountPath(), "webGetContent", "GET", { contentId: ClientData.contentInfo_contentId(), sid: ClientData.userInfo_sid(), getType: 2 },
function (data) {
$.each(data.contentData, function (i, n) {
if (typeof n == "object") {
resourceIdDetail = n.resourceId;
window.open(getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + resourceIdDetail + "&isDownload=true", "_blank");
}
});
},
null
);
// avwCmsApi(ClientData.userInfo_accountPath(), "webGetContent", "GET", { contentId: ClientData.contentInfo_contentId(), sid: ClientData.userInfo_sid(), getType: 2 },
// function (data) {
// $.each(data.contentData, function (i, n) {
// if (typeof n == "object") {
// resourceIdDetail = n.resourceId;
// var resourceUrl = getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + resourceIdDetail + "&isDownload=true";
// window.open(resourceUrl, "_blank");
// }
// });
// },
// null
// );
downloadResourceById(ClientData.contentInfo_contentId());
}
else {
......
......@@ -1042,3 +1042,39 @@ function getIconTypeContent(contentType) {
}
return src;
};
// download resouce content id
function downloadResourceById(contentId){
var params = {
sid: ClientData.userInfo_sid(),
contentId: contentId,
getType: '2'
};
/* abapi('webGetContent', params, 'GET', function (data) {
var resourceId=data.contentData.content.resourceId;
//Get resource
resourceUrl = getResourceByIdFromAPI(resourceId);
// open url to download file
window.open(resourceUrl);
}); */
avwCmsApiSync(ClientData.userInfo_accountPath(), "webGetContent", "get", params,
function (data) {
//Get resourceurl
var resourceUrl = getResourceByIdFromAPI(data.contentData.content.resourceId);
// open url to download file
window.open(resourceUrl);
},
function (xhr, b, c) { });
};
//Download resource
function getResourceByIdFromAPI(resourceId){
return getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + resourceId + "&isDownload=true";
};
\ No newline at end of file
......@@ -725,39 +725,39 @@ function isPdfContent(contentType){
}
};
//Get resource Id of content
function downloadResourceById(contentId){
var params = {
sid: ClientData.userInfo_sid(),
contentId: contentId,
getType: '2',
};
var resourceUrl;
abapi('webGetContent', params, 'GET', function (data) {
var resourceId;
$.each(data.contentData , function(i, n){
if(typeof n == "object"){
resourceId = n.resourceId;
}
});
//Get resource
resourceUrl = getResourceByIdFromAPI(resourceId);
window.open(resourceUrl, "_blank");
////Get resource Id of content
//function downloadResourceById(contentId){
// var params = {
// sid: ClientData.userInfo_sid(),
// contentId: contentId,
// getType: '2',
// };
//
// var resourceUrl;
//
// abapi('webGetContent', params, 'GET', function (data) {
// var resourceId;
//
// $.each(data.contentData , function(i, n){
// if(typeof n == "object"){
// resourceId = n.resourceId;
// }
// });
//
// //Get resource
// resourceUrl = getResourceByIdFromAPI(resourceId);
// window.open(resourceUrl, "_blank");
// redraw content remove new icon
drawEditImage(contentId);
// // redraw content remove new icon
// drawEditImage(contentId);
});
};
// });
//};
//Download resource
function getResourceByIdFromAPI(resourceId){
return getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + resourceId + "&isDownload=true";
};
////Download resource
//function getResourceByIdFromAPI(resourceId){
// return getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + resourceId + "&isDownload=true";
//};
/* get url */
function getURL(apiName) {
......@@ -857,6 +857,9 @@ function readSubmenuFunction_callback(contentId)
if(contentType == ContentTypeKeys.Type_Others){
//Download content
downloadResourceById(contentId);
// redraw content remove new icon
drawEditImage(contentId);
}
else{
//Go to Conten view page
......
......@@ -478,6 +478,8 @@ function canvasClickFunction_callback(outputId)
if(contentType == ContentTypeKeys.Type_Others){
//Download content
downloadResourceById(outputId);
// redraw content remove new icon
drawEditImage(outputId);
}
else{
//Go to Conten view page
......@@ -584,6 +586,10 @@ function canvasClickFunction_callback(outputId)
if(contentType == ContentTypeKeys.Type_Others){
//Download content
downloadResourceById(outputId);
// redraw content remove new icon
drawEditImage(outputId);
}
else{
//Go to Conten view page
......@@ -1372,6 +1378,10 @@ function readSubmenuFunction_callback(contentId)
if(contentType == ContentTypeKeys.Type_Others){
//Download content
downloadResourceById(contentId);
// redraw content remove new icon
drawEditImage(contentId);
}
else{
//Go to Conten view page
......@@ -2022,40 +2032,37 @@ function isPdfContent(contentType){
};
//Get resource Id of content
function downloadResourceById(contentId){
var params = {
sid: ClientData.userInfo_sid(),
contentId: contentId,
getType: '2',
};
var resourceUrl;
abapi('webGetContent', params, 'GET', function (data) {
var resourceId;
$.each(data.contentData , function(i, n){
if(typeof n == "object"){
resourceId = n.resourceId;
}
});
//Get resource
resourceUrl = getResourceByIdFromAPI(resourceId);
window.open(resourceUrl, "_blank");
////Get resource Id of content
//function downloadResourceById(contentId){
// var params = {
// sid: ClientData.userInfo_sid(),
// contentId: contentId,
// getType: '2',
// };
//
// var resourceUrl;
//
// abapi('webGetContent', params, 'GET', function (data) {
// var resourceId;
//
// $.each(data.contentData , function(i, n){
// if(typeof n == "object"){
// resourceId = n.resourceId;
// }
// });
//
// //Get resource
// resourceUrl = getResourceByIdFromAPI(resourceId);
// redraw content remove new icon
drawEditImage(contentId);
// window.open(resourceUrl, "_blank");
});
};
// });
//};
//Download resource
function getResourceByIdFromAPI(resourceId){
return getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + resourceId + "&isDownload=true";
};
////Download resource
//function getResourceByIdFromAPI(resourceId){
// return getURL("webResourceDownload") + "/?sid=" + ClientData.userInfo_sid() + "&resourceId=" + resourceId + "&isDownload=true";
//};
/* get url */
function getURL(apiName) {
......
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