Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
abook_check
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abook_android
abook_check
Commits
ee17a18f
Commit
ee17a18f
authored
Nov 24, 2021
by
Lee Munkyeong
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'features/1.4.100_develop_mk' into 'features/1.4.202'
図面ホットスポット色及びトップ画面更新ProgressBar修正 See merge request
!251
parents
16ca9515
71c14dc7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
153 additions
and
23 deletions
+153
-23
ABVJE_BL/src/jp/agentec/abook/abv/bl/common/constant/ABookKeys.java
+5
-0
ABVJE_BL/src/jp/agentec/abook/abv/bl/download/ContentRefresher.java
+12
-15
ABVJE_BL/src/jp/agentec/abook/abv/bl/dto/OperationTaskDto.java
+2
-0
ABVJE_BL/src/jp/agentec/abook/abv/bl/logic/OperationLogic.java
+50
-5
ABVJE_Launcher_Android/assets/check
+1
-1
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/viewer/activity/ContentViewActivity.java
+67
-2
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/viewer/view/OperationTaskLayout.java
+16
-0
No files found.
ABVJE_BL/src/jp/agentec/abook/abv/bl/common/constant/ABookKeys.java
View file @
ee17a18f
...
@@ -193,6 +193,11 @@ public class ABookKeys {
...
@@ -193,6 +193,11 @@ public class ABookKeys {
public
static
final
String
THETA_LIST_ACTIVITY_FLG
=
"thetaListActivityFlg"
;
public
static
final
String
THETA_LIST_ACTIVITY_FLG
=
"thetaListActivityFlg"
;
//連続作業
//連続作業
public
static
final
String
PANO_IMAGE
=
"panoImage"
;
public
static
final
String
TASK_PDF
=
"taskPdf"
;
public
static
final
String
PHASE_INFO_JSON
=
"phaseInfo.json"
;
public
static
final
String
TIME_LINE_LIST
=
"timeLineList"
;
public
static
final
String
PROCESS_KEY
=
"processKey"
;
public
static
final
String
PROCESS_KEY
=
"processKey"
;
public
static
final
String
PROCESS_STATUS
=
"processStatus"
;
public
static
final
String
PROCESS_STATUS
=
"processStatus"
;
public
static
final
String
PHASE_NO
=
"phaseNo"
;
public
static
final
String
PHASE_NO
=
"phaseNo"
;
...
...
ABVJE_BL/src/jp/agentec/abook/abv/bl/download/ContentRefresher.java
View file @
ee17a18f
...
@@ -204,29 +204,32 @@ public class ContentRefresher {
...
@@ -204,29 +204,32 @@ public class ContentRefresher {
}
}
groupLogic
.
initializeGroups
();
// グループ設定(グループ変更の場合、FetchDateをクリアする)
groupLogic
.
initializeGroups
();
// グループ設定(グループ変更の場合、FetchDateをクリアする)
if
(
mProgressCallback
!=
null
)
{
if
(
mProgressCallback
!=
null
)
{
mProgressCallback
.
callback
(
5
);
mProgressCallback
.
callback
(
10
);
}
}
categoryLogic
.
initializeCategories
();
// カテゴリ設定
categoryLogic
.
initializeCategories
();
// カテゴリ設定
// 絞り検索マスタデータの最新更新された時のFetchDateを一時に保存する。
// 絞り検索マスタデータの最新更新された時のFetchDateを一時に保存する。
if
(
mProgressCallback
!=
null
)
{
if
(
mProgressCallback
!=
null
)
{
mProgressCallback
.
callback
(
5
);
mProgressCallback
.
callback
(
10
);
}
}
// CMSでメンテナンスされる絞り検索マスタデータをアプリから取得できるようにJSONファイルを生成する。
// CMSでメンテナンスされる絞り検索マスタデータをアプリから取得できるようにJSONファイルを生成する。
apertureMasterDataLogic
.
initializeApertureMasterData
();
apertureMasterDataLogic
.
initializeApertureMasterData
();
if
(
mProgressCallback
!=
null
)
{
if
(
mProgressCallback
!=
null
)
{
mProgressCallback
.
callback
(
5
);
mProgressCallback
.
callback
(
10
);
}
}
// 作業種別情報を取得
// 作業種別情報を取得
operationGroupMasterLogic
.
setOperationGroupMaster
();
operationGroupMasterLogic
.
setOperationGroupMaster
();
if
(
mProgressCallback
!=
null
)
{
if
(
mProgressCallback
!=
null
)
{
mProgressCallback
.
callback
(
5
);
mProgressCallback
.
callback
(
10
);
}
}
if
(
interrupt
)
{
// この時点で停止要求が来た場合先には進まない。(ServiceOption/Group/Categoryの更新は1セットで行う(トランザクションはそれぞれ別))
if
(
interrupt
)
{
// この時点で停止要求が来た場合先には進まない。(ServiceOption/Group/Categoryの更新は1セットで行う(トランザクションはそれぞれ別))
Logger
.
d
(
TAG
,
"stop refresh worker before content update."
);
Logger
.
d
(
TAG
,
"stop refresh worker before content update."
);
setFail
();
setFail
();
updateRefreshContentListState
(-
1L
,
null
,
mProgressCallback
);
updateRefreshContentListState
(-
1L
,
null
,
mProgressCallback
);
if
(
mProgressCallback
!=
null
)
{
mProgressCallback
.
callback
(
10
);
}
return
;
return
;
}
}
isFinishedContentCheck
=
retrieveServerContent
(
localContents
,
mProgressCallback
);
// ContentVersionAPIを呼出し新規と更新の場合ContentInfoをDLする
isFinishedContentCheck
=
retrieveServerContent
(
localContents
,
mProgressCallback
);
// ContentVersionAPIを呼出し新規と更新の場合ContentInfoをDLする
...
@@ -236,13 +239,12 @@ public class ContentRefresher {
...
@@ -236,13 +239,12 @@ public class ContentRefresher {
initializingRefreshing
=
false
;
initializingRefreshing
=
false
;
if
(!
isRefreshing
())
{
if
(!
isRefreshing
())
{
updateRefreshContentListState
(-
1L
,
null
,
mProgressCallback
);
updateRefreshContentListState
(-
1L
,
null
);
}
}
mProgressCallback
.
callback
(
100
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
Logger
.
e
(
"refreshContent failed."
,
e
);
Logger
.
e
(
"refreshContent failed."
,
e
);
mProgressCallback
.
callback
(
100
);
updateRefreshContentListState
(-
1L
,
e
);
updateRefreshContentListState
(-
1L
,
e
);
mProgressCallback
.
callback
(
100
);
}
}
contentDownloader
.
kickTask
();
contentDownloader
.
kickTask
();
Logger
.
i
(
TAG
,
"refresh main thread end.-----------------------------------------------"
);
Logger
.
i
(
TAG
,
"refresh main thread end.-----------------------------------------------"
);
...
@@ -342,11 +344,6 @@ public class ContentRefresher {
...
@@ -342,11 +344,6 @@ public class ContentRefresher {
List
<
ContentDto
>
serverContents
=
json
.
contentVersions
;
List
<
ContentDto
>
serverContents
=
json
.
contentVersions
;
// DTO Info:contentId, metaVersion, resourceVersion, contentNameKana, readerShareFlg
// DTO Info:contentId, metaVersion, resourceVersion, contentNameKana, readerShareFlg
int
progressPercent
=
0
;
if
(
CollectionUtil
.
isNotEmpty
(
serverContents
)
&&
serverContents
.
size
()
!=
0
)
{
progressPercent
=
50
/
serverContents
.
size
()
<
1
?
1
:
50
/
serverContents
.
size
();
}
int
totalProgress
=
0
;
int
totalProgress
=
0
;
for
(
ContentDto
serverContentDto
:
serverContents
)
{
for
(
ContentDto
serverContentDto
:
serverContents
)
{
while
(
isBusyRefreshingContent
())
{
while
(
isBusyRefreshingContent
())
{
...
@@ -386,9 +383,9 @@ public class ContentRefresher {
...
@@ -386,9 +383,9 @@ public class ContentRefresher {
}
}
}
}
}
}
if
(
mProgressCallback
!=
null
&&
totalProgress
<
5
0
)
{
if
(
mProgressCallback
!=
null
&&
totalProgress
<
2
0
)
{
mProgressCallback
.
callback
(
progressPercent
);
mProgressCallback
.
callback
(
1
);
totalProgress
=
totalProgress
+
progressPercent
;
totalProgress
=
totalProgress
+
1
;
}
}
}
}
...
...
ABVJE_BL/src/jp/agentec/abook/abv/bl/dto/OperationTaskDto.java
View file @
ee17a18f
...
@@ -14,6 +14,8 @@ public class OperationTaskDto extends AbstractDto {
...
@@ -14,6 +14,8 @@ public class OperationTaskDto extends AbstractDto {
public
int
seqId
;
public
int
seqId
;
public
Date
insertDate
;
public
Date
insertDate
;
public
Date
updateDate
;
public
Date
updateDate
;
public
String
processKey
;
public
int
processStatus
;
public
float
pdfX
;
public
float
pdfX
;
public
float
pdfY
;
public
float
pdfY
;
public
boolean
isFinished
;
public
boolean
isFinished
;
...
...
ABVJE_BL/src/jp/agentec/abook/abv/bl/logic/OperationLogic.java
View file @
ee17a18f
...
@@ -2,6 +2,7 @@ package jp.agentec.abook.abv.bl.logic;
...
@@ -2,6 +2,7 @@ package jp.agentec.abook.abv.bl.logic;
import
static
jp
.
agentec
.
abook
.
abv
.
bl
.
acms
.
type
.
OperationType
.
DRAWING
;
import
static
jp
.
agentec
.
abook
.
abv
.
bl
.
acms
.
type
.
OperationType
.
DRAWING
;
import
static
jp
.
agentec
.
abook
.
abv
.
bl
.
acms
.
type
.
OperationType
.
PANO
;
import
static
jp
.
agentec
.
abook
.
abv
.
bl
.
acms
.
type
.
OperationType
.
PANO
;
import
static
jp
.
agentec
.
abook
.
abv
.
bl
.
acms
.
type
.
OperationType
.
PDF
;
import
net.lingala.zip4j.exception.ZipException
;
import
net.lingala.zip4j.exception.ZipException
;
...
@@ -116,7 +117,7 @@ public class OperationLogic extends AbstractLogic {
...
@@ -116,7 +117,7 @@ public class OperationLogic extends AbstractLogic {
public
void
initializeOperations
(
Callback
mCallBack
)
throws
AcmsException
,
NetworkDisconnectedException
{
public
void
initializeOperations
(
Callback
mCallBack
)
throws
AcmsException
,
NetworkDisconnectedException
{
// 作業グループリスト取得
// 作業グループリスト取得
setWorkingGroupList
();
setWorkingGroupList
();
mCallBack
.
callback
(
5
);
mCallBack
.
callback
(
2
);
// 作業一覧取得し、登録・更新・削除する
// 作業一覧取得し、登録・更新・削除する
retrieveServerOperation
(
mCallBack
);
retrieveServerOperation
(
mCallBack
);
}
}
...
@@ -369,7 +370,6 @@ public class OperationLogic extends AbstractLogic {
...
@@ -369,7 +370,6 @@ public class OperationLogic extends AbstractLogic {
insertFlg
=
false
;
insertFlg
=
false
;
break
;
break
;
}
}
mCallBack
.
callback
(
1
);
}
}
// 更新されたら以下の処理は行わない
// 更新されたら以下の処理は行わない
...
@@ -397,7 +397,6 @@ public class OperationLogic extends AbstractLogic {
...
@@ -397,7 +397,6 @@ public class OperationLogic extends AbstractLogic {
for
(
OperationGroupMasterRelationDto
operationGroupMasterRelationDto
:
serverOperationDto
.
operationGroupMasterRelationDtoList
)
{
for
(
OperationGroupMasterRelationDto
operationGroupMasterRelationDto
:
serverOperationDto
.
operationGroupMasterRelationDtoList
)
{
mOperationGroupMasterOperationDao
.
insertOperationGroupMasterOperation
(
operationGroupMasterRelationDto
);
mOperationGroupMasterOperationDao
.
insertOperationGroupMasterOperation
(
operationGroupMasterRelationDto
);
}
}
mCallBack
.
callback
(
2
);
}
}
// 作業担当グループ登録
// 作業担当グループ登録
...
@@ -1222,7 +1221,7 @@ public class OperationLogic extends AbstractLogic {
...
@@ -1222,7 +1221,7 @@ public class OperationLogic extends AbstractLogic {
JSONObject
phaseStatusJson
=
new
JSONObject
();
JSONObject
phaseStatusJson
=
new
JSONObject
();
phaseStatusJson
.
put
(
ABookKeys
.
PROCESS_LIST
,
processInfoList
);
phaseStatusJson
.
put
(
ABookKeys
.
PROCESS_LIST
,
processInfoList
);
OperationDto
operation
=
mOperationDao
.
getOperation
(
operationId
);
OperationDto
operation
=
mOperationDao
.
getOperation
(
operationId
);
if
(
operation
.
operationType
==
PANO
||
operation
.
operationType
==
DRAWING
)
{
if
(
operation
.
operationType
==
PANO
||
operation
.
operationType
==
DRAWING
||
operation
.
operationType
==
PDF
)
{
contentPath
=
contentPath
.
replaceAll
(
"panoImage"
,
"processList"
);
contentPath
=
contentPath
.
replaceAll
(
"panoImage"
,
"processList"
);
contentPath
=
contentPath
.
replaceAll
(
"taskPdf"
,
"processList"
);
contentPath
=
contentPath
.
replaceAll
(
"taskPdf"
,
"processList"
);
}
}
...
@@ -1249,12 +1248,35 @@ public class OperationLogic extends AbstractLogic {
...
@@ -1249,12 +1248,35 @@ public class OperationLogic extends AbstractLogic {
}
}
processInfoJson
.
put
(
"processList"
,
taskJsonList
);
processInfoJson
.
put
(
"processList"
,
taskJsonList
);
OperationDto
operation
=
mOperationDao
.
getOperation
(
operationId
);
OperationDto
operation
=
mOperationDao
.
getOperation
(
operationId
);
if
(
operation
.
operationType
==
PANO
||
operation
.
operationType
==
DRAWING
)
{
if
(
operation
.
operationType
==
PANO
||
operation
.
operationType
==
DRAWING
||
operation
.
operationType
==
PDF
)
{
contentPath
=
contentPath
.
replaceAll
(
"panoImage"
,
"processList"
);
contentPath
=
contentPath
.
replaceAll
(
"taskPdf"
,
"processList"
);
}
Logger
.
d
(
TAG
,
"createProcessInfoJson : "
+
processInfoJson
.
toString
());
FileUtil
.
createFile
(
contentPath
+
"/processInfo.json"
,
processInfoJson
.
toString
());
}
private
String
getProcessInfoJson
(
Long
operationId
,
String
contentPath
)
throws
IOException
{
List
<
JSONObject
>
taskJsonList
=
new
ArrayList
<
JSONObject
>();
JSONObject
processInfoJson
=
new
JSONObject
();
List
<
TaskDto
>
taskDtoList
=
mTaskDao
.
selectTaskGroupByProcessKeyByOperationId
(
operationId
);
for
(
TaskDto
dto
:
taskDtoList
)
{
JSONObject
taskDtoJson
=
new
JSONObject
();
taskDtoJson
.
put
(
ABookKeys
.
TASK_NAME
,
dto
.
taskName
);
taskDtoJson
.
put
(
ABookKeys
.
TASK_CODE
,
dto
.
taskCode
);
taskDtoJson
.
put
(
ABookKeys
.
PROCESS_KEY
,
dto
.
processKey
);
taskDtoJson
.
put
(
ABookKeys
.
PROCESS_STATUS
,
dto
.
processStatus
);
taskJsonList
.
add
(
taskDtoJson
);
}
processInfoJson
.
put
(
"processList"
,
taskJsonList
);
OperationDto
operation
=
mOperationDao
.
getOperation
(
operationId
);
if
(
operation
.
operationType
==
PANO
||
operation
.
operationType
==
DRAWING
||
operation
.
operationType
==
PDF
)
{
contentPath
=
contentPath
.
replaceAll
(
"panoImage"
,
"processList"
);
contentPath
=
contentPath
.
replaceAll
(
"panoImage"
,
"processList"
);
contentPath
=
contentPath
.
replaceAll
(
"taskPdf"
,
"processList"
);
contentPath
=
contentPath
.
replaceAll
(
"taskPdf"
,
"processList"
);
}
}
Logger
.
d
(
TAG
,
"createProcessInfoJson : "
+
processInfoJson
.
toString
());
Logger
.
d
(
TAG
,
"createProcessInfoJson : "
+
processInfoJson
.
toString
());
FileUtil
.
createFile
(
contentPath
+
"/processInfo.json"
,
processInfoJson
.
toString
());
FileUtil
.
createFile
(
contentPath
+
"/processInfo.json"
,
processInfoJson
.
toString
());
return
processInfoJson
.
toString
();
}
}
/**
/**
...
@@ -2147,6 +2169,29 @@ public class OperationLogic extends AbstractLogic {
...
@@ -2147,6 +2169,29 @@ public class OperationLogic extends AbstractLogic {
}
}
}
}
public
String
getProcessDataAndCreateJson
(
Long
operationId
,
String
contentPath
,
boolean
routineTaskReportFlg
)
throws
NetworkDisconnectedException
,
ABVException
,
IOException
{
GetOperationDataParameters
param
=
new
GetOperationDataParameters
(
ABVDataCache
.
getInstance
().
getMemberInfo
().
sid
,
operationId
);
ProcessDataJSON
json
=
AcmsClient
.
getInstance
(
ABVDataCache
.
getInstance
().
getUrlPath
(),
ABVEnvironment
.
getInstance
().
networkAdapter
).
getProcessData
(
param
);
for
(
TaskDto
taskDto
:
json
.
taskDtoList
)
{
for
(
TaskDto
phaseTaskDto
:
taskDto
.
phaseList
)
{
//Taskデータ更新(phaseStatus, processStatus)
mTaskDao
.
updateStatus
(
taskDto
.
processKey
,
phaseTaskDto
.
phaseNo
,
taskDto
.
processStatus
,
phaseTaskDto
.
phaseStatus
);
for
(
TaskReportApprovalDto
taskReportApprovalDto
:
phaseTaskDto
.
taskReportApprovalDtoList
)
{
taskReportApprovalDto
.
processKey
=
taskDto
.
processKey
;
taskReportApprovalDto
.
phaseNo
=
phaseTaskDto
.
phaseNo
;
//TaskReportApprovalデータ追加・更新
if
(
mTaskReportApprovalDao
.
selectTaskReportApprovalByProcessKey
(
taskDto
.
processKey
,
phaseTaskDto
.
phaseNo
,
taskReportApprovalDto
.
approvalNo
)
!=
null
)
{
mTaskReportApprovalDao
.
update
(
taskReportApprovalDto
);
}
else
{
mTaskReportApprovalDao
.
insert
(
taskReportApprovalDto
);
}
}
}
}
return
getProcessInfoJson
(
operationId
,
contentPath
);
}
/**
/**
* 工程情報を全部削除する。(全削除ボタンタップ時)
* 工程情報を全部削除する。(全削除ボタンタップ時)
* @param operationId 作業ID
* @param operationId 作業ID
...
...
check
@
76fa1d17
Subproject commit
4313eb5084533edc7b622189bb928a4724c5bf29
Subproject commit
76fa1d1741dafcf7915a0c5e8eb051b059eeede3
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/viewer/activity/ContentViewActivity.java
View file @
ee17a18f
...
@@ -4,6 +4,10 @@ package jp.agentec.abook.abv.ui.viewer.activity;
...
@@ -4,6 +4,10 @@ package jp.agentec.abook.abv.ui.viewer.activity;
* @author jang
* @author jang
*/
*/
import
static
jp
.
agentec
.
abook
.
abv
.
bl
.
acms
.
type
.
OperationType
.
DRAWING
;
import
static
jp
.
agentec
.
abook
.
abv
.
bl
.
acms
.
type
.
OperationType
.
PANO
;
import
static
jp
.
agentec
.
abook
.
abv
.
bl
.
acms
.
type
.
OperationType
.
PDF
;
import
android.app.AlertDialog
;
import
android.app.AlertDialog
;
import
android.app.Dialog
;
import
android.app.Dialog
;
import
android.content.Context
;
import
android.content.Context
;
...
@@ -79,6 +83,7 @@ import java.util.Map;
...
@@ -79,6 +83,7 @@ import java.util.Map;
import
java.util.Objects
;
import
java.util.Objects
;
import
java.util.concurrent.ConcurrentHashMap
;
import
java.util.concurrent.ConcurrentHashMap
;
import
jp.agentec.abook.abv.bl.acms.client.json.AcmsJSONParser
;
import
jp.agentec.abook.abv.bl.acms.client.json.DownloadedContentInfoJSON
;
import
jp.agentec.abook.abv.bl.acms.client.json.DownloadedContentInfoJSON
;
import
jp.agentec.abook.abv.bl.acms.client.json.MarkingJson
;
import
jp.agentec.abook.abv.bl.acms.client.json.MarkingJson
;
import
jp.agentec.abook.abv.bl.acms.client.json.content.ActionInfoJSON
;
import
jp.agentec.abook.abv.bl.acms.client.json.content.ActionInfoJSON
;
...
@@ -96,7 +101,9 @@ import jp.agentec.abook.abv.bl.common.CommonExecutor;
...
@@ -96,7 +101,9 @@ import jp.agentec.abook.abv.bl.common.CommonExecutor;
import
jp.agentec.abook.abv.bl.common.Constant
;
import
jp.agentec.abook.abv.bl.common.Constant
;
import
jp.agentec.abook.abv.bl.common.constant.ABookCommConstants
;
import
jp.agentec.abook.abv.bl.common.constant.ABookCommConstants
;
import
jp.agentec.abook.abv.bl.common.constant.ABookKeys
;
import
jp.agentec.abook.abv.bl.common.constant.ABookKeys
;
import
jp.agentec.abook.abv.bl.common.exception.ABVException
;
import
jp.agentec.abook.abv.bl.common.exception.ExceptionHandler
;
import
jp.agentec.abook.abv.bl.common.exception.ExceptionHandler
;
import
jp.agentec.abook.abv.bl.common.exception.NetworkDisconnectedException
;
import
jp.agentec.abook.abv.bl.common.log.Logger
;
import
jp.agentec.abook.abv.bl.common.log.Logger
;
import
jp.agentec.abook.abv.bl.common.util.ContentFileUtil
;
import
jp.agentec.abook.abv.bl.common.util.ContentFileUtil
;
import
jp.agentec.abook.abv.bl.common.util.JsonUtil
;
import
jp.agentec.abook.abv.bl.common.util.JsonUtil
;
...
@@ -105,9 +112,13 @@ import jp.agentec.abook.abv.bl.data.dao.AbstractDao;
...
@@ -105,9 +112,13 @@ import jp.agentec.abook.abv.bl.data.dao.AbstractDao;
import
jp.agentec.abook.abv.bl.data.dao.ContentDao
;
import
jp.agentec.abook.abv.bl.data.dao.ContentDao
;
import
jp.agentec.abook.abv.bl.data.dao.ContentPageDao
;
import
jp.agentec.abook.abv.bl.data.dao.ContentPageDao
;
import
jp.agentec.abook.abv.bl.download.ContentFileExtractor
;
import
jp.agentec.abook.abv.bl.download.ContentFileExtractor
;
import
jp.agentec.abook.abv.bl.dto.ChatMessageDto
;
import
jp.agentec.abook.abv.bl.dto.ChatRoomDto
;
import
jp.agentec.abook.abv.bl.dto.ContentBookmarkDto
;
import
jp.agentec.abook.abv.bl.dto.ContentBookmarkDto
;
import
jp.agentec.abook.abv.bl.dto.ContentDto
;
import
jp.agentec.abook.abv.bl.dto.ContentDto
;
import
jp.agentec.abook.abv.bl.dto.OperationDto
;
import
jp.agentec.abook.abv.bl.dto.OperationTaskDto
;
import
jp.agentec.abook.abv.bl.dto.OperationTaskDto
;
import
jp.agentec.abook.abv.bl.dto.TaskDto
;
import
jp.agentec.abook.abv.bl.logic.AbstractLogic
;
import
jp.agentec.abook.abv.bl.logic.AbstractLogic
;
import
jp.agentec.abook.abv.bl.logic.ContentReadingLogLogic
;
import
jp.agentec.abook.abv.bl.logic.ContentReadingLogLogic
;
import
jp.agentec.abook.abv.bl.logic.ContractLogic
;
import
jp.agentec.abook.abv.bl.logic.ContractLogic
;
...
@@ -173,6 +184,7 @@ import jp.agentec.abook.abv.ui.viewer.view.action.TapMediaPlayer;
...
@@ -173,6 +184,7 @@ import jp.agentec.abook.abv.ui.viewer.view.action.TapMediaPlayer;
import
jp.agentec.abook.abv.ui.viewer.view.action.VideoMountAction
;
import
jp.agentec.abook.abv.ui.viewer.view.action.VideoMountAction
;
import
jp.agentec.adf.net.http.HttpDownloadSimpleNotification
;
import
jp.agentec.adf.net.http.HttpDownloadSimpleNotification
;
import
jp.agentec.adf.net.http.HttpDownloadState
;
import
jp.agentec.adf.net.http.HttpDownloadState
;
import
jp.agentec.adf.util.DateTimeUtil
;
import
jp.agentec.adf.util.FileUtil
;
import
jp.agentec.adf.util.FileUtil
;
import
jp.agentec.adf.util.StringUtil
;
import
jp.agentec.adf.util.StringUtil
;
...
@@ -336,7 +348,7 @@ public class ContentViewActivity extends ABVContentViewActivity {
...
@@ -336,7 +348,7 @@ public class ContentViewActivity extends ABVContentViewActivity {
public
boolean
mMoveTaskFlg
=
false
;
public
boolean
mMoveTaskFlg
=
false
;
private
long
currentRemoteObjectId
=
0
;
private
long
currentRemoteObjectId
=
0
;
private
static
final
int
FINISHED_STATUS
=
999
;
/**
/**
* スクロールステータス
* スクロールステータス
...
@@ -5351,6 +5363,7 @@ public class ContentViewActivity extends ABVContentViewActivity {
...
@@ -5351,6 +5363,7 @@ public class ContentViewActivity extends ABVContentViewActivity {
mMainLayout
.
addView
(
operationTaskLayout
);
mMainLayout
.
addView
(
operationTaskLayout
);
List
<
OperationTaskDto
>
tasks
=
mTaskHotspotJSON
.
getPageTasks
(
pageNumber
);
List
<
OperationTaskDto
>
tasks
=
mTaskHotspotJSON
.
getPageTasks
(
pageNumber
);
operationTaskLayout
.
addAllOperationTaskIcon
(
rootLayout
,
tasks
);
operationTaskLayout
.
addAllOperationTaskIcon
(
rootLayout
,
tasks
);
//画面回転の時
//画面回転の時
...
@@ -5404,14 +5417,66 @@ public class ContentViewActivity extends ABVContentViewActivity {
...
@@ -5404,14 +5417,66 @@ public class ContentViewActivity extends ABVContentViewActivity {
hotspot
=
new
JSONObject
(
checkParam
.
get
(
ABookKeys
.
HOT_SPOT
));
hotspot
=
new
JSONObject
(
checkParam
.
get
(
ABookKeys
.
HOT_SPOT
));
taskCode
=
hotspot
.
getString
(
ABookKeys
.
TASK_CODE
);
taskCode
=
hotspot
.
getString
(
ABookKeys
.
TASK_CODE
);
}
}
if
(
checkParam
.
get
(
"phaseNo"
)
!=
null
&&
!
Objects
.
equals
(
checkParam
.
get
(
"phaseNo"
),
"1"
))
{
OperationDto
operation
=
mOperationDao
.
getOperation
(
mOperationId
);
String
jsonPath
=
""
;
if
((
operation
.
operationType
==
PANO
||
operation
.
operationType
==
DRAWING
||
operation
.
operationType
==
PDF
)
&&
operation
.
reportType
==
Constant
.
ReportType
.
ReportContinuous
)
{
String
processKey
=
checkParam
.
get
(
ABookKeys
.
PROCESS_KEY
)
!=
null
?
checkParam
.
get
(
ABookKeys
.
PROCESS_KEY
)
:
""
;
List
<
TaskDto
>
taskList
=
mTaskDao
.
getTaskByProcessKey
(
processKey
);
if
(
taskList
!=
null
&&
taskList
.
size
()
>
0
)
{
for
(
TaskDto
task
:
taskList
)
{
if
(
task
.
phaseNo
==
1
)
{
operationTaskLayout
.
setIconStatus
(
taskKey
,
true
);
operationTaskLayout
.
currentTaskDto
.
taskKey
=
task
.
taskKey
;
operationTaskLayout
.
currentTaskDto
.
taskCode
=
task
.
taskCode
;
jsonPath
=
mContentPath
.
replaceAll
(
ABookKeys
.
PANO_IMAGE
,
ABookKeys
.
PROCESS_LIST
).
replaceAll
(
ABookKeys
.
TASK_PDF
,
ABookKeys
.
PROCESS_LIST
)
+
"/"
+
ABookKeys
.
PHASE_INFO_JSON
;
JSONObject
phaseInfo
=
null
;
int
lastPhase
=
0
;
try
{
phaseInfo
=
new
JSONObject
(
FileUtil
.
readTextFile
(
jsonPath
));
JSONArray
timeLineListJSONArray
=
phaseInfo
.
getJSONArray
(
ABookKeys
.
TIME_LINE_LIST
);
for
(
int
listCount
=
0
;
listCount
<
timeLineListJSONArray
.
length
();
listCount
++)
{
if
(
timeLineListJSONArray
.
getJSONObject
(
listCount
).
length
()
==
0
)
{
break
;
break
;
}
}
JSONObject
timeLineJSONObject
=
timeLineListJSONArray
.
getJSONObject
(
listCount
);
JSONArray
phaseListJSONArray
=
timeLineJSONObject
.
getJSONArray
(
ABookKeys
.
PHASE_LIST
);
lastPhase
=
lastPhase
+
phaseListJSONArray
.
length
();
}
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
}
TaskDto
lastTask
=
null
;
for
(
TaskDto
compareTask
:
taskList
)
{
if
(
compareTask
.
phaseNo
==
lastPhase
)
{
lastTask
=
compareTask
;
}
}
if
(
lastTask
!=
null
)
{
operationTaskLayout
.
currentTaskDto
.
isFinished
=
(
lastTask
.
taskStatus
==
FINISHED_STATUS
);
}
else
{
operationTaskLayout
.
currentTaskDto
.
isFinished
=
false
;
}
operationTaskLayout
.
currentTaskDto
.
processKey
=
task
.
processKey
;
operationTaskLayout
.
currentTaskDto
.
processStatus
=
task
.
processStatus
;
operationTaskLayout
.
addOperationTaskIcon
(
operationTaskLayout
.
currentLayout
,
operationTaskLayout
.
currentTaskDto
);
}
}
}
else
{
operationTaskLayout
.
setIconStatus
(
taskKey
,
true
);
operationTaskLayout
.
setIconStatus
(
taskKey
,
true
);
operationTaskLayout
.
currentTaskDto
.
taskKey
=
taskKey
;
operationTaskLayout
.
currentTaskDto
.
taskKey
=
taskKey
;
operationTaskLayout
.
currentTaskDto
.
taskCode
=
taskCode
;
operationTaskLayout
.
currentTaskDto
.
taskCode
=
taskCode
;
operationTaskLayout
.
currentTaskDto
.
isFinished
=
operationTaskLayout
.
isTaskFinished
(
taskKey
);
operationTaskLayout
.
currentTaskDto
.
isFinished
=
operationTaskLayout
.
isTaskFinished
(
taskKey
);
operationTaskLayout
.
addOperationTaskIcon
(
operationTaskLayout
.
currentLayout
,
operationTaskLayout
.
currentTaskDto
);
operationTaskLayout
.
addOperationTaskIcon
(
operationTaskLayout
.
currentLayout
,
operationTaskLayout
.
currentTaskDto
);
}
}
else
{
operationTaskLayout
.
setIconStatus
(
taskKey
,
true
);
operationTaskLayout
.
currentTaskDto
.
taskKey
=
taskKey
;
operationTaskLayout
.
currentTaskDto
.
taskCode
=
taskCode
;
operationTaskLayout
.
currentTaskDto
.
isFinished
=
operationTaskLayout
.
isTaskFinished
(
taskKey
);
operationTaskLayout
.
addOperationTaskIcon
(
operationTaskLayout
.
currentLayout
,
operationTaskLayout
.
currentTaskDto
);
}
//hideOperationTaskLayout();
//hideOperationTaskLayout();
}
else
{
}
else
{
operationTaskLayout
.
setIconStatus
(
taskKey
,
false
);
operationTaskLayout
.
setIconStatus
(
taskKey
,
false
);
...
...
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/viewer/view/OperationTaskLayout.java
View file @
ee17a18f
...
@@ -285,7 +285,16 @@ public class OperationTaskLayout extends RelativeLayout {
...
@@ -285,7 +285,16 @@ public class OperationTaskLayout extends RelativeLayout {
public
void
addAllOperationTaskIcon
(
final
ZoomRelativeLayout
rootLayout
,
final
List
<
OperationTaskDto
>
dto
)
{
public
void
addAllOperationTaskIcon
(
final
ZoomRelativeLayout
rootLayout
,
final
List
<
OperationTaskDto
>
dto
)
{
for
(
OperationTaskDto
task
:
dto
)
{
for
(
OperationTaskDto
task
:
dto
)
{
TaskDto
taskDto
=
mTaskDao
.
getTaskByTaskKey
(
task
.
taskKey
);
task
.
processKey
=
taskDto
.
processKey
;
task
.
processStatus
=
taskDto
.
processStatus
;
if
(
StringUtil
.
isNullOrEmpty
(
task
.
processKey
))
{
task
.
isFinished
=
isTaskFinished
(
task
.
taskKey
);
task
.
isFinished
=
isTaskFinished
(
task
.
taskKey
);
}
else
if
(
task
.
processStatus
==
FINISHED_STATUS
)
{
task
.
isFinished
=
true
;
}
else
{
task
.
isFinished
=
false
;
}
addOperationTaskIcon
(
rootLayout
,
task
);
addOperationTaskIcon
(
rootLayout
,
task
);
}
}
}
}
...
@@ -302,6 +311,13 @@ public class OperationTaskLayout extends RelativeLayout {
...
@@ -302,6 +311,13 @@ public class OperationTaskLayout extends RelativeLayout {
return
mTaskDao
.
getTaskByTaskKey
(
taskKey
).
taskStatus
==
FINISHED_STATUS
;
return
mTaskDao
.
getTaskByTaskKey
(
taskKey
).
taskStatus
==
FINISHED_STATUS
;
}
}
public
boolean
isProcessFinished
(
String
taskKey
)
{
if
(
mTaskDao
.
getTaskByTaskKey
(
taskKey
)
==
null
)
{
return
false
;
}
return
mTaskDao
.
getTaskByTaskKey
(
taskKey
).
taskStatus
==
FINISHED_STATUS
;
}
public
void
showTaskList
(
int
pageNum
,
boolean
isNormalSize
)
{
public
void
showTaskList
(
int
pageNum
,
boolean
isNormalSize
)
{
final
String
script
=
String
.
format
(
SCRIPT_SHOW_TASK_LIST
,
pageNum
+
1
);
final
String
script
=
String
.
format
(
SCRIPT_SHOW_TASK_LIST
,
pageNum
+
1
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment