Commit 92abfbd7 by Masaru Abe

マイグレーション対応 JSONにObjectIdがなかった場合でもエラーにならないようにする

parent 8b7fdd8a
......@@ -2512,20 +2512,23 @@ function RegisterLog() {
for (var nIndex2 = 0; nIndex2 < objectLogArray.length; nIndex2++) {
actionDate = new Date(objectLogArray[nIndex2].actionDate);
var line = [];
line.push(actionDate.jpDateTimeString1());
line.push(objectLogArray[nIndex2].pageNo);
line.push(objectLogArray[nIndex2].objectId);
line.push(objectLogArray[nIndex2].resourceId);
line.push(objectLogArray[nIndex2].mediaType);
line.push(objectLogArray[nIndex2].actionType);
line.push(objectLogArray[nIndex2].actionValue);
line.push(objectLogArray[nIndex2].actionTime);
line.push(objectLogArray[nIndex2].locationX);
line.push(objectLogArray[nIndex2].locationY);
line.push(objectLogArray[nIndex2].locationHeight);
line.push(objectLogArray[nIndex2].locationWidth);
lines.push(line);
//alert("ObjectLog Line:" + JSON.stringify( line ) );
if( objectLogArray[nIndex2].objectId ){
line.push(actionDate.jpDateTimeString1());
line.push(objectLogArray[nIndex2].pageNo);
line.push(objectLogArray[nIndex2].objectId);
line.push(objectLogArray[nIndex2].resourceId);
line.push(objectLogArray[nIndex2].mediaType);
line.push(objectLogArray[nIndex2].actionType);
line.push(objectLogArray[nIndex2].actionValue);
line.push(objectLogArray[nIndex2].actionTime);
line.push(objectLogArray[nIndex2].locationX);
line.push(objectLogArray[nIndex2].locationY);
line.push(objectLogArray[nIndex2].locationHeight);
line.push(objectLogArray[nIndex2].locationWidth);
lines.push(line);
//alert("ObjectLog Line:" + JSON.stringify( line ) );
}
}
//alert("ObjectLog Lines:" + JSON.stringify( lines ) );
......
......@@ -50,13 +50,17 @@ function webGetContentPageSize(){
"webGetContent",
"GET",
{ contentId: contentID, sid: ClientData.userInfo_sid(), getType: 6 },
function (data) {
$.each(data.contentData.pageInfoData.pagesInfo, function(i, n){
contentPageSizeArr.push(n);
});
//Get Page size of firstPage
getPageSizeByPageNo(1);
function (data) {
if( data.contentData.pageInfoData.pagesInfo ){
$.each(data.contentData.pageInfoData.pagesInfo, function(i, n){
contentPageSizeArr.push(n);
});
//Get Page size of firstPage
getPageSizeByPageNo(1);
} else {
showErrorScreen();
}
},
null);
};
......
......@@ -144,8 +144,12 @@ function getMediaType1(iValueObj) {
pageObject['height'] = iValueObj.location.height;
pageObject['id'] = "MediaType1_" + iValueObj.action.actionType;
//詳細ログ用
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
if (iValueObj.action.actionType == 0) {
/*get mediaInfo */
......@@ -402,8 +406,12 @@ function getMediaType2(iValueObj) {
pageObject['height'] = iValueObj.location.height;
pageObject['visible'] = true;
//詳細ログ用
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
return pageObject;
};
......@@ -447,8 +455,12 @@ function getMediaType3(iValueObj) {
pageObject['height'] = iValueObj.location.height;
pageObject['visible'] = true;
//詳細ログ用
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
return pageObject;
};
......@@ -491,8 +503,12 @@ function getMediaType4(iValueObj) {
pageObject['height'] = iValueObj.location.height;
pageObject['visible'] = true;
//詳細ログ用(使わない)
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用(使わない)
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
return pageObject;
};
......@@ -523,8 +539,12 @@ function getMediaType5(iValueObj) {
pageObject['height'] = iValueObj.location.height;
pageObject['visible'] = true;
//詳細ログ用(使わない)
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用(使わない)
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
return pageObject;
};
......@@ -588,8 +608,12 @@ function getMediaType6(iValueObj) {
pageObject['height'] = iValueObj.location.height;
pageObject['visible'] = true;
//詳細ログ用
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
return pageObject;
};
......@@ -626,8 +650,12 @@ function getMediaType7(iValueObj) {
pageObject['height'] = iValueObj.location.height;
pageObject['visible'] = true;
//詳細ログ用(使わない)
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用(使わない)
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
return pageObject;
};
......@@ -679,8 +707,12 @@ function getMediaType8(iValueObj) {
pageObject['3dview'] = _3dViewObject;
}
//詳細ログ用
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
return pageObject;
};
......@@ -700,8 +732,12 @@ function getMediaType9(iValueObj) {
pageObject['height'] = iValueObj.location.height;
pageObject['visible'] = true;
//詳細ログ用
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
if(iValueObj.action.actionType == 11){
var resourceId = iValueObj.mediaInfo.resourceId;
......@@ -742,8 +778,12 @@ function getMediaType11(iValueObj) {
pageObject['height'] = iValueObj.location.height;
pageObject['visible'] = true;
//詳細ログ用
pageObject["objectId"] = iValueObj.action.objectId;
//詳細ログ用
try{
pageObject["objectId"] = iValueObj.action.objectId;
}catch(e){
pageObject["objectId"] = "";
}
if(iValueObj.action.actionType == 12){
var resourceId = iValueObj.mediaInfo.resourceId;
......
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