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
fbc108a4
Commit
fbc108a4
authored
Aug 30, 2019
by
Lee Jaebin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#34867 作業並び替え機能
parent
9ce2a1f8
Show whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
308 additions
and
461 deletions
+308
-461
ABVJE_BL/src/jp/agentec/abook/abv/bl/acms/type/OperationSortingType.java
+62
-0
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/DBConnector.java
+1
-1
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/DatabaseVersions.java
+1
-0
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/dao/OperationDao.java
+43
-10
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/tables/TOperation.java
+7
-16
ABVJE_BL/src/jp/agentec/abook/abv/bl/logic/OperationLogic.java
+3
-2
ABVJE_UI_Android/res/layout-large/ac_operation_list.xml
+13
-4
ABVJE_UI_Android/res/layout-normal/ac_operation_list.xml
+11
-2
ABVJE_UI_Android/res/layout/item_simple_list_single_choice.xml
+11
-0
ABVJE_UI_Android/res/values-ja/arrays.xml
+4
-69
ABVJE_UI_Android/res/values-ko/arrays.xml
+0
-64
ABVJE_UI_Android/res/values/arrays.xml
+0
-103
ABVJE_UI_Android/src/jp/agentec/abook/abv/launcher/android/ABVUIDataCache.java
+17
-37
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/common/activity/ABVUIActivity.java
+1
-1
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/common/appinfo/AppDefType.java
+8
-19
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/OperationListActivity.java
+90
-131
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/helper/HomeOperationListHelper.java
+5
-2
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/helper/OperationListHelper.java
+31
-0
No files found.
ABVJE_BL/src/jp/agentec/abook/abv/bl/acms/type/OperationSortingType.java
0 → 100644
View file @
fbc108a4
package
jp
.
agentec
.
abook
.
abv
.
bl
.
acms
.
type
;
/**
* Created by leej on 2019/08/21.
*/
public
enum
OperationSortingType
{
OperationName
(
0
),
OperationStartDateDESC
(
1
),
OperationStartDateASC
(
2
),
OperationType
(
3
),
ReadingDate
(
4
);
private
final
int
operationSorting
;
OperationSortingType
(
int
operationSorting
)
{
this
.
operationSorting
=
operationSorting
;
}
/**
* 検索をかける項目の番号を返します。
* @return 検索をかける項目の番号です。
* @since 1.0.0
*/
public
int
type
()
{
return
operationSorting
;
}
/**
* 指定した数字に対応するSecurityPolicyCodeの値を返します。
* @param operationSorting 数字のコードです。
* @return 指定した数字に対応するSearchDivisionTypeの値です。
* @since 1.0.0
*/
public
static
OperationSortingType
parse
(
int
operationSorting
)
{
OperationSortingType
sortingType
;
switch
(
operationSorting
)
{
case
0
:
sortingType
=
OperationSortingType
.
OperationName
;
break
;
case
1
:
sortingType
=
OperationSortingType
.
OperationStartDateDESC
;
break
;
case
2
:
sortingType
=
OperationSortingType
.
OperationStartDateASC
;
break
;
case
3
:
sortingType
=
OperationSortingType
.
OperationType
;
break
;
case
4
:
sortingType
=
OperationSortingType
.
ReadingDate
;
break
;
default
:
sortingType
=
OperationSortingType
.
OperationName
;
break
;
}
return
sortingType
;
}
}
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/DBConnector.java
View file @
fbc108a4
...
...
@@ -19,7 +19,7 @@ import jp.agentec.abook.abv.bl.common.db.SQLiteDatabase;
public
class
DBConnector
{
private
static
volatile
DBConnector
dbConnector
=
null
;
public
static
final
String
DatabaseName
=
"ABVJE"
;
public
static
final
int
DatabaseVersion
=
DatabaseVersions
.
Ver1_
1
_0
;
public
static
final
int
DatabaseVersion
=
DatabaseVersions
.
Ver1_
2
_0
;
protected
SQLiteDatabase
db
=
null
;
...
...
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/DatabaseVersions.java
View file @
fbc108a4
...
...
@@ -4,5 +4,6 @@ package jp.agentec.abook.abv.bl.data;
public
class
DatabaseVersions
{
public
static
final
int
Ver1_0_0
=
1
;
public
static
final
int
Ver1_1_0
=
11
;
public
static
final
int
Ver1_2_0
=
21
;
}
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/dao/OperationDao.java
View file @
fbc108a4
...
...
@@ -4,9 +4,11 @@ import java.util.ArrayList;
import
java.util.Date
;
import
java.util.List
;
import
jp.agentec.abook.abv.bl.acms.type.OperationSortingType
;
import
jp.agentec.abook.abv.bl.common.Constant
;
import
jp.agentec.abook.abv.bl.common.db.Cursor
;
import
jp.agentec.abook.abv.bl.common.log.Logger
;
import
jp.agentec.abook.abv.bl.data.SortDirection
;
import
jp.agentec.abook.abv.bl.dto.OperationDto
;
import
jp.agentec.adf.util.DateTimeFormat
;
import
jp.agentec.adf.util.DateTimeUtil
;
...
...
@@ -211,6 +213,15 @@ public class OperationDao extends AbstractDao {
}
/**
* 作業閲覧日付
* @param operationId
* @return
*/
public
boolean
updateReadingDate
(
Long
operationId
)
{
return
update
(
"update t_operation set operation_open_date=? WHERE operation_id=?"
,
new
Object
[]{
DateTimeUtil
.
getCurrentTimestamp
(),
operationId
})
>
0
;
}
/**
* 該当作業を削除(関連テーブルを含む)
* @param dto
*/
...
...
@@ -242,11 +253,11 @@ public class OperationDao extends AbstractDao {
* @param searchOperationName
* @param searchStartDateStr
* @param searchEndDateStr
* @param
reportTypeStr
* @param
operationSortType
* @return
*/
public
List
<
OperationDto
>
getOperations
(
String
searchOperationName
,
String
searchStartDateStr
,
String
searchEndDateStr
,
String
reportTypeStr
)
{
String
sql
=
generateGetOperationQuery
(
searchOperationName
,
searchStartDateStr
,
searchEndDateStr
,
reportTypeStr
,
null
);
public
List
<
OperationDto
>
getOperations
(
String
searchOperationName
,
String
searchStartDateStr
,
String
searchEndDateStr
,
OperationSortingType
operationSortType
)
{
String
sql
=
generateGetOperationQuery
(
searchOperationName
,
searchStartDateStr
,
searchEndDateStr
,
operationSortType
,
null
);
return
rawQueryGetDtoList
(
sql
,
null
,
OperationDto
.
class
);
}
...
...
@@ -266,10 +277,10 @@ public class OperationDao extends AbstractDao {
* @param searchOperationName
* @param searchStartDateStr
* @param searchEndDateStr
* @param
reportTypeStr
* @param
operationSortingType
* @return
*/
private
String
generateGetOperationQuery
(
String
searchOperationName
,
String
searchStartDateStr
,
String
searchEndDateStr
,
String
reportTypeStr
,
Integer
operationGroupMasterId
)
{
private
String
generateGetOperationQuery
(
String
searchOperationName
,
String
searchStartDateStr
,
String
searchEndDateStr
,
OperationSortingType
operationSortingType
,
Integer
operationGroupMasterId
)
{
String
curDate
=
DateTimeUtil
.
toStringInTimeZone
(
new
Date
(),
DateTimeFormat
.
yyyyMMddHHmmss_hyphen
,
"UTC"
);
StringBuffer
sql
=
new
StringBuffer
();
...
...
@@ -337,11 +348,33 @@ public class OperationDao extends AbstractDao {
sql
.
append
(
" AND top.operation_start_date <= '"
+
DateTimeUtil
.
toString
(
endDate
,
DateTimeFormat
.
yyyyMMdd_hyphen
)
+
"'"
);
}
if
(
reportTypeStr
!=
null
)
{
sql
.
append
(
" AND top.report_type in ("
+
reportTypeStr
+
")"
);
}
sql
.
append
(
" ORDER BY top.operation_start_date DESC, top.operation_id DESC"
);
// 並び順
if
(
operationSortingType
!=
null
)
{
switch
(
operationSortingType
)
{
case
OperationName:
sql
.
append
(
" ORDER BY top.operation_name ASC "
);
break
;
case
OperationStartDateASC:
sql
.
append
(
" ORDER BY top.operation_start_date ASC "
);
break
;
case
OperationStartDateDESC:
sql
.
append
(
" ORDER BY top.operation_start_date DESC "
);
break
;
case
OperationType:
sql
.
append
(
" ORDER BY top.report_type ASC "
);
break
;
case
ReadingDate:
sql
.
append
(
" ORDER BY top.operation_open_date DESC "
);
break
;
default
:
sql
.
append
(
" ORDER BY top.operation_name DESC "
);
break
;
}
}
else
{
sql
.
append
(
" ORDER BY top.operation_name ASC "
);
}
// 必ずORDER BYが存在する 2次ソート
sql
.
append
(
", top.operation_id DESC"
);
Logger
.
v
(
TAG
,
"sql=%s"
,
sql
);
...
...
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/tables/TOperation.java
View file @
fbc108a4
...
...
@@ -38,6 +38,7 @@ public class TOperation extends SQLiteTableScript {
sql
.
append
(
" , enable_report_history SMALLINT NOT NULL DEFAULT 0 "
);
sql
.
append
(
" , enable_report_edit SMALLINT NOT NULL DEFAULT 0 "
);
sql
.
append
(
" , enable_add_report SMALLINT NOT NULL DEFAULT 0 "
);
sql
.
append
(
" , operation_open_date DATETIME "
);
sql
.
append
(
" , PRIMARY KEY (operation_id) "
);
sql
.
append
(
" ) "
);
ddl
.
add
(
sql
.
toString
());
...
...
@@ -48,22 +49,12 @@ public class TOperation extends SQLiteTableScript {
@Override
public
List
<
String
>
getUpgradeScript
(
int
oldVersion
,
int
newVersion
)
{
// List<String> ddl = new ArrayList<String>();
// if (oldVersion < DatabaseVersions.Plus_1_9_3) {
// ddl.addAll(getCreateScript(newVersion));
// }
//
// if (oldVersion < DatabaseVersions.Plus_1_9_3_5) { // カラムの追加
// ddl.add(" ALTER TABLE t_operation ADD COLUMN report_update_type INTEGER NOT NULL DEFAULT 0 ");
// }
//
// if (oldVersion < DatabaseVersions.Plus_1_9_4) { // カラムの追加
// ddl.add(" ALTER TABLE t_operation ADD COLUMN project_report_type INTEGER NOT NULL DEFAULT 0 ");
// ddl.add(" ALTER TABLE t_operation ADD COLUMN report_cycle INTEGER NOT NULL DEFAULT 0 ");
// ddl.add(" ALTER TABLE t_operation ADD COLUMN enable_report_update INTEGER NOT NULL DEFAULT 0 ");
// }
// return ddl;
return
null
;
List
<
String
>
ddl
=
new
ArrayList
<
String
>();
if
(
oldVersion
<
DatabaseVersions
.
Ver1_2_0
)
{
// カラムの追加
ddl
.
add
(
"ALTER TABLE t_operation ADD COLUMN operation_open_date DATETIME"
);
}
return
ddl
;
}
@Override
...
...
ABVJE_BL/src/jp/agentec/abook/abv/bl/logic/OperationLogic.java
View file @
fbc108a4
...
...
@@ -23,6 +23,7 @@ import jp.agentec.abook.abv.bl.acms.client.json.SceneEntryJSON;
import
jp.agentec.abook.abv.bl.acms.client.json.WorkerGroupJSON
;
import
jp.agentec.abook.abv.bl.acms.client.parameters.AcmsParameters
;
import
jp.agentec.abook.abv.bl.acms.client.parameters.GetTaskFileParameters
;
import
jp.agentec.abook.abv.bl.acms.type.OperationSortingType
;
import
jp.agentec.abook.abv.bl.common.ABVEnvironment
;
import
jp.agentec.abook.abv.bl.common.Constant
;
import
jp.agentec.abook.abv.bl.common.Callback
;
...
...
@@ -1075,9 +1076,9 @@ public class OperationLogic extends AbstractLogic {
* @param searchEndDateStr
* @return
*/
public
List
<
OperationDto
>
getRefreshOperation
(
String
searchWord
,
String
searchStartDateStr
,
String
searchEndDateStr
,
String
reportTypeStr
)
{
public
List
<
OperationDto
>
getRefreshOperation
(
String
searchWord
,
String
searchStartDateStr
,
String
searchEndDateStr
,
OperationSortingType
operationSortingType
)
{
List
<
OperationDto
>
operationDtoList
;
operationDtoList
=
mOperationDao
.
getOperations
(
searchWord
,
searchStartDateStr
,
searchEndDateStr
,
reportTypeStr
);
operationDtoList
=
mOperationDao
.
getOperations
(
searchWord
,
searchStartDateStr
,
searchEndDateStr
,
operationSortingType
);
for
(
OperationDto
operationDto
:
operationDtoList
)
{
// 作業送信フラグが存在する場合またはホットスポット更新フラグが存在する場合、needSyncFlgをtrueにセット
if
(
mTaskReportDao
.
isExistSendTaskData
(
operationDto
.
operationId
)
||
mTaskReportDao
.
isExistUpdateTargetHotSpotTaskData
(
operationDto
.
operationId
))
{
...
...
ABVJE_UI_Android/res/layout-large/ac_operation_list.xml
View file @
fbc108a4
...
...
@@ -109,27 +109,36 @@
android:textColor=
"@color/app_color"
android:textSize=
"@dimen/app_normal_text_size"
android:textStyle=
"bold"
/>
</LinearLayout>
<ImageButton
android:id=
"@+id/btn_sort"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_marginRight=
"15dp"
android:layout_toLeftOf=
"@+id/btn_communication_menu"
android:background=
"@drawable/ic_communication_menu"
android:onClick=
"onClickSortMenuByTablet"
/>
<ImageButton
android:id=
"@+id/btn_communication_menu"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_marginRight=
"15dp"
android:layout_toLeftOf=
"@+id/btn_s
ub_menu
"
android:layout_toLeftOf=
"@+id/btn_s
etting
"
android:background=
"@drawable/ic_communication_menu"
/>
<ImageButton
android:id=
"@+id/btn_s
ub_menu
"
android:id=
"@+id/btn_s
etting
"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_marginRight=
"15dp"
android:layout_toLeftOf=
"@+id/btn_common_content"
android:background=
"@drawable/ic_operation_setting"
android:onClick=
"onClick
OperationSubMenu
"
/>
android:onClick=
"onClick
Setting
"
/>
<ImageButton
android:id=
"@+id/btn_common_content"
...
...
ABVJE_UI_Android/res/layout-normal/ac_operation_list.xml
View file @
fbc108a4
...
...
@@ -78,6 +78,15 @@
android:src=
"@drawable/ic_batch_sync"
/>
<ImageButton
android:id=
"@+id/btn_sort"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:background=
"@drawable/ic_communication_menu"
android:layout_marginRight=
"15dp"
android:layout_toLeftOf=
"@+id/btn_common_content"
android:onClick=
"onClickSortMenuByNormalSize"
/>
<ImageButton
android:id=
"@+id/btn_common_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
...
...
@@ -150,14 +159,14 @@
android:contentDescription=
"@string/list"
/>
<ImageButton
android:id=
"@+id/btn_s
ub_menu
"
android:id=
"@+id/btn_s
etting
"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_marginRight=
"10dp"
android:layout_alignParentRight=
"true"
android:background=
"@drawable/ic_operation_setting"
android:onClick=
"onClick
OperationSubMenu
"
/>
android:onClick=
"onClick
Setting
"
/>
</RelativeLayout>
...
...
ABVJE_UI_Android/res/layout/item_simple_list_single_choice.xml
0 → 100644
View file @
fbc108a4
<?xml version="1.0" encoding="utf-8"?>
<CheckedTextView
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:id=
"@android:id/text1"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:textAppearance=
"?android:attr/textAppearanceMedium"
android:gravity=
"center_vertical"
android:checkMark=
"?android:attr/listChoiceIndicatorSingle"
android:padding=
"6dp"
/>
ABVJE_UI_Android/res/values-ja/arrays.xml
View file @
fbc108a4
...
...
@@ -2,74 +2,10 @@
<resources>
<string-array
name=
"sort_names"
>
<item>
コンテンツ名(あいうえお)順
</item>
<item>
コンテンツ番号が小さい順
</item>
<item>
公開日が新しい順
</item>
<item>
コンテンツサイズが大きい順
</item>
<item>
ダウンロード日が新しい順
</item>
<item>
閲覧回数が多い順
</item>
<item>
作業名(あいうえお)順
</item>
<item>
作業期間が新しい順
</item>
<item>
作業期間が古い順
</item>
<item>
報告タイプ順
</item>
<item>
閲覧日が新しい順
</item>
</string-array>
<string-array
name=
"sort_names_cloud"
>
<item>
コンテンツ名(あいうえお)順
</item>
<item>
コンテンツ番号が小さい順
</item>
<item>
公開日が最新順
</item>
<item>
コンテンツサイズが大きい順
</item>
</string-array>
<string-array
name=
"content_submenu_names"
>
<item>
コンテンツ詳細
</item>
<item>
コンテンツを開く
</item>
<item>
コンテンツをWebで開く
</item>
<item>
コンテンツダウンロード
</item>
<item>
コンテンツダウンロードキャンセル
</item>
<item>
コンテンツアップデート
</item>
<item>
コンテンツ削除
</item>
<item>
マイデータコピー
</item>
<item>
マイデータ貼付
</item>
<item>
フォルダへ移動
</item>
<item>
お気に入りに追加
</item>
<item>
お気に入り削除
</item>
<item>
コンテンツ共有
</item>
</string-array>
<string-array
name=
"image_change_effect"
>
<item>
スライド
</item>
<item>
フェード
</item>
<item>
リヴィール
&
ムーブイン
</item>
</string-array>
<string-array
name=
"toolbar_submenu"
>
<item>
プリント
</item>
<item>
お気に入り追加
</item>
<item>
テキストコピー
</item>
</string-array>
<string-array
name=
"avaliable_share_app"
>
<item>
facebook
</item>
<item>
line
</item>
<item>
mail
</item>
<item>
mms
</item>
<!-- SMS -->
<item>
message
</item>
<!-- SMS:Sharp端末 -->
<item>
conversation
</item>
<!-- SMS:sony端末 -->
<item>
android.gm
</item>
<!-- Gmail -->
<item>
kakao.talk
</item>
<item>
twitter
</item>
</string-array>
<string-array
name=
"tap_action_on_update"
>
<item>
都度選択
</item>
<item>
そのまま開く
</item>
<item>
自動アップデート
</item>
</string-array>
<string-array
name=
"tap_action_on_delivery_select"
>
<item>
ダウンロード
</item>
<item>
Webを開く
</item>
<item>
都度選択
</item>
</string-array>
<string-array
name=
"fix_orientation"
>
<item>
なし
</item>
<item>
横
</item>
<item>
縦
</item>
<item>
縦(反転)
</item>
</string-array>
</resources>
\ No newline at end of file
ABVJE_UI_Android/res/values-ko/arrays.xml
View file @
fbc108a4
...
...
@@ -10,68 +10,4 @@
<item>
많이 본 순서
</item>
<item>
최근에 본 순서
</item>
</string-array>
<string-array
name=
"sort_names_cloud"
>
<item>
콘텐츠명(가나다)순
</item>
<item>
콘텐츠 번호가 작은 순서
</item>
<item>
공개일이 최근인 순서
</item>
<item>
콘텐츠 용량이 큰 순서
</item>
</string-array>
<string-array
name=
"content_submenu_names"
>
<item>
콘텐츠 상세
</item>
<item>
콘텐츠 열람
</item>
<item>
콘텐츠 열람 by Web
</item>
<item>
콘텐츠 다운로드
</item>
<item>
콘텐츠 다운로드 취소
</item>
<item>
콘텐츠 업데이트
</item>
<item>
콘텐츠 삭제
</item>
<item>
메모/마킹/북마크 복사
</item>
<item>
메모/마킹/북마크 붙여 넣기
</item>
<item>
폴더에 이동
</item>
<item>
즐겨 찾기에 추가
</item>
<item>
즐겨 찾기 제거
</item>
<item>
콘텐츠 공유
</item>
</string-array>
<string-array
name=
"image_change_effect"
>
<item>
Slide
</item>
<item>
Fade
</item>
<item>
Reveal
&
Move In
</item>
</string-array>
<string-array
name=
"toolbar_submenu"
>
<item>
인쇄
</item>
<item>
즐겨찾기
</item>
<item>
본문 추출
</item>
</string-array>
<string-array
name=
"avaliable_share_app"
>
<item>
facebook
</item>
<item>
line
</item>
<item>
mail
</item>
<item>
mms
</item>
<!-- SMS -->
<item>
message
</item>
<!-- SMS:Sharp端末 -->
<item>
conversation
</item>
<!-- SMS:sony端末 -->
<item>
daum.android.air
</item>
<!-- mypeople -->
<item>
android.gm
</item>
<item>
kakao.talk
</item>
<item>
twitter
</item>
</string-array>
<string-array
name=
"tap_action_on_update"
>
<item>
매번 선택
</item>
<item>
열람
</item>
<item>
자동 업데이트
</item>
</string-array>
<string-array
name=
"tap_action_on_delivery_select"
>
<item>
다운로드
</item>
<item>
Web으로 보기
</item>
<item>
매번 선택
</item>
</string-array>
<string-array
name=
"fix_orientation"
>
<item>
미설정
</item>
<item>
가로
</item>
<item>
세로
</item>
<item>
세로(역방향)
</item>
</string-array>
</resources>
ABVJE_UI_Android/res/values/arrays.xml
View file @
fbc108a4
...
...
@@ -11,106 +11,4 @@
<item>
Viewed count
</item>
<item>
Viewed date
</item>
</string-array>
<string-array
name=
"sort_names_cloud"
>
<item>
Content Name
</item>
<item>
Content ID
</item>
<item>
Release Date (Desc)
</item>
<item>
Content Size (Desc)
</item>
</string-array>
<string-array
name=
"content_submenu_names"
>
<item>
Content Detail
</item>
<item>
Content Open
</item>
<item>
Content Open by Web
</item>
<item>
Content Download
</item>
<item>
Cancel Content Download
</item>
<item>
Update Content
</item>
<item>
Delete Content
</item>
<item>
Copy MyData
</item>
<item>
Paste MyData
</item>
<item>
Move To Folder
</item>
<item>
Add Favorite
</item>
<item>
Delete Favorite
</item>
<item>
Share Content
</item>
</string-array>
<string-array
name=
"image_change_effect"
>
<item>
Slide
</item>
<item>
Fade
</item>
<item>
Reviel
&
Move in
</item>
</string-array>
<string-array
name=
"toolbar_submenu"
>
<item>
Print
</item>
<item>
Add Favorite
</item>
<item>
Copy Text
</item>
</string-array>
<string-array
name=
"reader_dashboard_preset"
>
<item>
recent
</item>
<item>
most_viewed
</item>
<item>
favorite
</item>
<item>
myfolder
</item>
</string-array>
<string-array
name=
"avaliable_share_app"
>
<item>
facebook
</item>
<item>
line
</item>
<item>
mail
</item>
<item>
mms
</item>
<!-- SMS -->
<item>
message
</item>
<!-- SMS:Sharp端末 -->
<item>
conversation
</item>
<!-- SMS:sony端末 -->
<item>
android.gm
</item>
<item>
kakao.talk
</item>
<item>
twitter
</item>
</string-array>
<string-array
name=
"tap_action_on_update"
>
<item>
Select each time
</item>
<item>
Open
</item>
<item>
Auto update
</item>
</string-array>
<string-array
name=
"tap_action_on_update_values"
>
<item>
0
</item>
<item>
1
</item>
<item>
2
</item>
</string-array>
<string-array
name=
"tap_action_on_delivery_select"
>
<item>
Download
</item>
<item>
Streaming
</item>
<item>
Select each time
</item>
</string-array>
<string-array
name=
"tap_action_on_delivery_select_values"
>
<item>
0
</item>
<item>
1
</item>
<item>
2
</item>
</string-array>
<string-array
name=
"pdf_image_size_values"
>
<item>
1280x720
</item>
<item>
1280x1024
</item>
<item>
1366x768
</item>
<item>
1920x1080
</item>
</string-array>
<string-array
name=
"fix_orientation"
>
<item>
None
</item>
<item>
Landscape
</item>
<item>
Portrait
</item>
<item>
Portrait(Reverse)
</item>
</string-array>
<string-array
name=
"fix_orientation_values"
>
<item>
0
</item>
<item>
1
</item>
<item>
2
</item>
<item>
3
</item>
</string-array>
<string-array
name=
"monitorTouchMode_values"
>
<item>
0
</item>
<item>
1
</item>
</string-array>
<string-array
name=
"operation_report_types"
>
<item>
Report
</item>
<item>
Routine
</item>
<item>
ReportReply
</item>
</string-array>
</resources>
\ No newline at end of file
ABVJE_UI_Android/src/jp/agentec/abook/abv/launcher/android/ABVUIDataCache.java
View file @
fbc108a4
...
...
@@ -114,6 +114,23 @@ public class ABVUIDataCache {
}
/**
* ソート条件をセット
* @param sortCondition
*/
public
void
setSortCondition
(
int
sortCondition
)
{
/* ロケーションタイプ毎にソート条件を保存する */
PreferenceUtil
.
putUserPref
(
context
,
UserPrefKey
.
OPERATION_SORT_CONDITION
,
sortCondition
);
}
/**
* ソート条件を取得
* @return
*/
public
int
getSortCondition
()
{
return
PreferenceUtil
.
getUserPref
(
context
,
UserPrefKey
.
OPERATION_SORT_CONDITION
,
0
);
}
/**
* xmlに書き込みされた作業種別IDを取得
* @return
*/
...
...
@@ -160,41 +177,4 @@ public class ABVUIDataCache {
returnContentIdList
.
clear
();
}
}
public
void
setOperationReportTypes
(
ArrayList
<
Integer
>
operationReportTypes
)
{
this
.
mReportTypes
=
operationReportTypes
;
String
val
=
null
;
if
(
operationReportTypes
.
size
()
>
0
)
{
// カンマ区切りで保存
StringBuffer
sb
=
new
StringBuffer
();
for
(
int
contentType
:
operationReportTypes
)
{
sb
.
append
(
contentType
);
sb
.
append
(
","
);
}
val
=
sb
.
substring
(
0
,
sb
.
length
()
-
1
);
}
PreferenceUtil
.
putUserPref
(
context
,
UserPrefKey
.
OPERATION_REPORT_TYPES
,
val
);
}
public
ArrayList
<
Integer
>
getOperationReportTypes
()
{
String
operationReportTypesStr
=
PreferenceUtil
.
getUserPref
(
context
,
UserPrefKey
.
OPERATION_REPORT_TYPES
,
null
);
if
(
operationReportTypesStr
!=
null
)
{
ArrayList
<
Integer
>
operationReportTypes
=
new
ArrayList
<>();
String
[]
operationReportTypesStrList
=
operationReportTypesStr
.
split
(
","
);
for
(
String
contentType
:
operationReportTypesStrList
)
{
if
(!
StringUtil
.
isNullOrEmpty
(
contentType
))
{
operationReportTypes
.
add
(
Integer
.
parseInt
(
contentType
));
}
}
mReportTypes
=
operationReportTypes
;
}
else
{
mReportTypes
=
new
ArrayList
<
Integer
>();
mReportTypes
.
add
(
ReportType
.
Report
);
mReportTypes
.
add
(
ReportType
.
RoutineTask
);
mReportTypes
.
add
(
ReportType
.
ReportReply
);
}
return
mReportTypes
;
}
}
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/common/activity/ABVUIActivity.java
View file @
fbc108a4
...
...
@@ -476,7 +476,7 @@ public abstract class ABVUIActivity extends ABVAuthenticatedActivity {
}
// 設定画面表示
public
void
showSetting
Popup
()
{
public
void
showSetting
()
{
Intent
intent
=
new
Intent
();
intent
.
setClassName
(
getApplicationContext
().
getPackageName
(),
ABookSettingActivity
.
class
.
getName
());
intent
.
setFlags
(
Intent
.
FLAG_ACTIVITY_CLEAR_TOP
);
...
...
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/common/appinfo/AppDefType.java
View file @
fbc108a4
...
...
@@ -59,34 +59,23 @@ public interface AppDefType {
String
SYNCED_OPERATION_ID
=
"syncedOperationId_%d"
;
//一日一回情報更新が出来るように
String
VIEW_MODE
=
"viewMode"
;
String
OPERATION_REPORT_TYPES
=
"operationReportTypes"
;
String
RESOURCE_PATTERN_TYPE
=
"resourcePatternType"
;
// 文言リソースパターン
String
OPERATION_GROUP_MASERT_MODE
=
"operation_group_master"
;
// 通常・作業種別モード(画面)
String
OPERATION_GROUP_MASERT_ID
=
"operation_group_master_id"
;
// 作業種別のID
String
APERTURE_MASTER_DATA_FETCH_DATE
=
"apertureMasterDataFetchDate"
;
// 絞り検索マスタデータのFetchDate
}
String
OPERATION_SORT_CONDITION
=
"operation_sort_condition"
;
// 作業のソート
/**
* 表示するデータタイプ
* 全て、クラウド、デバイス
*/
interface
ContentLocationType
{
int
CLOUD
=
1
;
int
DEVICE
=
2
;
int
ALL
=
9
;
String
APERTURE_MASTER_DATA_FETCH_DATE
=
"apertureMasterDataFetchDate"
;
// 絞り検索マスタデータのFetchDate
}
interface
SortType
{
int
CONTENT_NAME
=
0
;
//コンテンツ名
int
CONTENT_ID
=
1
;
//コンテンツ番号
int
DELIVERY_STARTDATE
=
2
;
//公開日
int
CONTENT_SIZE
=
3
;
//コンテンツサイズ
int
DOWNLOAD_DATE
=
4
;
//ダウンロード日
int
READING_COUNT
=
5
;
//閲覧回数
int
READING_DATE
=
6
;
//閲覧日
interface
SortType
{
int
OPERATION_NAME
=
0
;
// 作業名
int
OPERATION_START_DATE_DESC
=
1
;
// 作業時間が新しい順
int
OPERATION_START_DATE_ASC
=
2
;
// 作業時間が古い順
int
OPERATION_TYPE
=
3
;
// 報告タイプ
int
READING_DATE
=
4
;
// 閲覧日が新しい順
}
interface
SubMenuType
{
...
...
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/OperationListActivity.java
View file @
fbc108a4
...
...
@@ -11,7 +11,7 @@ import android.graphics.BitmapFactory;
import
android.net.Uri
;
import
android.os.Bundle
;
import
android.provider.MediaStore
;
import
android.
util.SparseBooleanArra
y
;
import
android.
view.Gravit
y
;
import
android.view.KeyEvent
;
import
android.view.View
;
import
android.view.ViewGroup
;
...
...
@@ -19,8 +19,6 @@ import android.view.Window;
import
android.widget.AbsListView
;
import
android.widget.AdapterView
;
import
android.widget.ArrayAdapter
;
import
android.widget.Button
;
import
android.widget.CheckedTextView
;
import
android.widget.DatePicker
;
import
android.widget.EditText
;
import
android.widget.FrameLayout
;
...
...
@@ -90,7 +88,6 @@ import jp.agentec.abook.abv.bl.dto.TaskDto;
import
jp.agentec.abook.abv.bl.dto.TaskReportDto
;
import
jp.agentec.abook.abv.bl.logic.AbstractLogic
;
import
jp.agentec.abook.abv.bl.logic.OperationGroupMasterLogic
;
import
jp.agentec.abook.abv.bl.logic.ApertureMasterDataLogic
;
import
jp.agentec.abook.abv.bl.logic.OperationLogic
;
import
jp.agentec.abook.abv.bl.logic.PushMessageLogic
;
import
jp.agentec.abook.abv.cl.util.PreferenceUtil
;
...
...
@@ -150,12 +147,6 @@ public class OperationListActivity extends ABVUIActivity {
private
TextView
mEndDate
;
private
LinearLayout
mSearchResultLayout
;
private
LinearLayout
mReportTypeLayoutLabel
;
private
LinearLayout
mReportTypeLayoutButton
;
private
Button
mReportTypeAllButton
;
private
Button
mReportTypeDefaultButton
;
private
Button
mReportTypeRoutineTaskButton
;
private
Dialog
mSearchDialog
;
private
Date
mOperationLastEditDate
;
...
...
@@ -193,8 +184,6 @@ public class OperationListActivity extends ABVUIActivity {
private
OperationListHelper
mListHelper
=
null
;
private
ArrayList
<
Integer
>
mAllOperationReportTypes
;
private
ABVListDialog
mShowDialog
;
private
Map
<
Integer
,
Integer
>
operationCountMap
;
...
...
@@ -204,12 +193,6 @@ public class OperationListActivity extends ABVUIActivity {
// 作業種別のサービスオプション値を保持用フラグ
private
boolean
mOperationGroupMasterServiceOperationFlg
;
// 絞り検索マスタデータ
// private Date mApertureLastEditDate;
// 絞り検索マスタLogic
private
ApertureMasterDataLogic
mApertureMasterDataLogic
=
AbstractLogic
.
getLogic
(
ApertureMasterDataLogic
.
class
);
// ビューの作成
private
class
ReloadHandler
implements
Runnable
{
@Override
...
...
@@ -241,8 +224,6 @@ public class OperationListActivity extends ABVUIActivity {
mViewModeButton
=
(
ImageButton
)
findViewById
(
R
.
id
.
btn_view_mode
);
// 検索ボタン
mSearchButton
=
(
ImageButton
)
findViewById
(
R
.
id
.
btn_search
);
// フィルターボタン
mFilterButton
=
(
ImageButton
)
findViewById
(
R
.
id
.
icon_filter
);
mSearchResultLayout
=
(
LinearLayout
)
findViewById
(
R
.
id
.
search_result
);
mCommunicationButton
=
(
ImageButton
)
findViewById
(
R
.
id
.
btn_communication_menu
);
...
...
@@ -387,8 +368,6 @@ public class OperationListActivity extends ABVUIActivity {
alertDialog
.
show
();
}
}
mAllOperationReportTypes
=
getOperationReportTypeList
(
true
);
// リスト更新
setOperationListView
();
}
...
...
@@ -425,8 +404,6 @@ public class OperationListActivity extends ABVUIActivity {
mCommonContentButton
.
setImageDrawable
(
getRDrawable
(
R
.
drawable
.
ic_common_content_off
));
mCommonContentButton
.
setEnabled
(
false
);
}
// フィルター選択判定
checkSelectedFilterType
();
// 作業種別表示・非表示
if
(
mOperationGroupMasterServiceOperationFlg
)
{
...
...
@@ -436,12 +413,6 @@ public class OperationListActivity extends ABVUIActivity {
if
(
getABVUIDataCache
().
getOperationGroupMasterMode
()
==
OperationLocationType
.
GROUP
)
{
// 検索ワード削除
clearSearch
();
// フィルタのリセット
getABVUIDataCache
().
setOperationReportTypes
(
mAllOperationReportTypes
);
// フィルターボタンを無効にする
mFilterButton
.
setImageDrawable
(
getRDrawable
(
R
.
drawable
.
ic_filter
));
setEnabledImageButton
(
mFilterButton
,
false
);
// 検索ボタンを無効にする
mSearchButton
.
setImageDrawable
(
getRDrawable
(
R
.
drawable
.
ic_operation_search
));
setEnabledImageButton
(
mSearchButton
,
false
);
...
...
@@ -450,7 +421,6 @@ public class OperationListActivity extends ABVUIActivity {
}
else
{
// 全て
// ボタンを活性化
setEnabledImageButton
(
mFilterButton
,
true
);
setEnabledImageButton
(
mSearchButton
,
true
);
// 一括同期ボタン非表示
mOperationBatchSyncButton
.
setVisibility
(
View
.
GONE
);
...
...
@@ -463,7 +433,6 @@ public class OperationListActivity extends ABVUIActivity {
// 一括同期ボタンを非表示
mOperationBatchSyncButton
.
setVisibility
(
View
.
GONE
);
// ボタンを活性化
setEnabledImageButton
(
mFilterButton
,
true
);
setEnabledImageButton
(
mSearchButton
,
true
);
}
...
...
@@ -781,6 +750,8 @@ public class OperationListActivity extends ABVUIActivity {
mOperationLogic
.
createJsonForOpenABookCheckPano
(
operationDto
.
operationId
,
operationDto
.
contentId
,
contentPath
);
mOperationLogic
.
createJsonForOperationContent
(
operationDto
.
operationId
,
contentPath
,
operationDto
.
reportType
==
ReportType
.
RoutineTask
);
// 作業閲覧日付の更新
mOperationDao
.
updateReadingDate
(
operationDto
.
operationId
);
// サーバ作業後、対応必要
StringBuffer
path
=
new
StringBuffer
();
...
...
@@ -961,17 +932,12 @@ public class OperationListActivity extends ABVUIActivity {
}
// 設定画面へ遷移
public
void
onClick
OperationSubMenu
(
View
v
)
{
showSetting
Popup
();
public
void
onClick
Setting
(
View
v
)
{
showSetting
();
}
public
void
onClickShowHelpView
(
View
v
)
{
// if (mOperationAuthLevel == OperationAuthLevel.OPERATION_INSTRUCTOR) {
// showHelpViewDialog(Constant.HelpViewType.OperationListDirector);
// } else {
showHelpViewDialog
(
Constant
.
HelpViewType
.
OperationListReporter
);
// }
}
/**
* 360編集画面表示
...
...
@@ -1977,84 +1943,6 @@ public class OperationListActivity extends ABVUIActivity {
});
}
/**
* 並べ替え画面表示
*
* @param anchor
*/
public
void
onClickOperationFilterList
(
final
View
anchor
)
{
Logger
.
d
(
TAG
,
"onClickShowContentContainerList start"
);
final
ABVPopupListWindow
popup
=
new
ABVPopupListWindow
(
this
,
R
.
layout
.
popup_simple_list
);
popup
.
setTitle
(
getRString
(
R
.
string
.
filter
));
popup
.
setWidth
(
getRDimensionSize
(
R
.
dimen
.
popup_size_xlarge
));
// 表示するコンテンツタイプのリストを作成
List
<
String
>
members
=
Arrays
.
asList
(
getRStringArray
(
R
.
array
.
operation_report_types
));
for
(
int
i
=
0
;
i
<
members
.
size
();
i
++)
{
int
rId
=
getResources
().
getIdentifier
(
members
.
get
(
i
),
"string"
,
getPackageName
());
// リソースパターンの適用
members
.
set
(
i
,
PatternStringUtil
.
patternToString
(
getApplicationContext
(),
rId
,
getUserPref
(
AppDefType
.
UserPrefKey
.
RESOURCE_PATTERN_TYPE
,
0
)));
}
ArrayList
<
Integer
>
selectedOperationReportTypes
=
getOperationReportTypeList
(
false
);
ArrayAdapter
<
String
>
adapter
=
new
ArrayAdapter
<>(
this
,
R
.
layout
.
item_checked_list
,
members
);
popup
.
setListViewAdapter
(
adapter
);
final
ListView
listView
=
popup
.
getListView
();
listView
.
setChoiceMode
(
AbsListView
.
CHOICE_MODE_MULTIPLE
);
for
(
int
i
=
0
;
i
<
mAllOperationReportTypes
.
size
();
i
++)
{
for
(
Integer
id
:
selectedOperationReportTypes
)
{
if
(
id
.
equals
(
mAllOperationReportTypes
.
get
(
i
)))
{
listView
.
setItemChecked
(
i
,
true
);
}
}
}
listView
.
setOnItemClickListener
(
new
AdapterView
.
OnItemClickListener
()
{
@Override
public
void
onItemClick
(
AdapterView
<?>
parent
,
View
view
,
int
position
,
long
cid
)
{
// 並び替えの要素タップイベント
SparseBooleanArray
checkedItemPositions
=
popup
.
getListView
().
getCheckedItemPositions
();
ArrayList
<
Integer
>
selectedOperationReportTypeIds
=
new
ArrayList
<>();
for
(
int
i
=
0
;
i
<
checkedItemPositions
.
size
();
i
++)
{
if
(
checkedItemPositions
.
valueAt
(
i
))
{
selectedOperationReportTypeIds
.
add
(
mAllOperationReportTypes
.
get
(
checkedItemPositions
.
keyAt
(
i
)));
}
}
if
(
selectedOperationReportTypeIds
.
size
()
>
0
)
{
getABVUIDataCache
().
setOperationReportTypes
(
selectedOperationReportTypeIds
);
refreshOperationList
();
}
else
{
((
CheckedTextView
)
view
).
setChecked
(
true
);
listView
.
getCheckedItemPositions
().
put
(
position
,
true
);
}
}
});
listView
.
invalidate
();
popup
.
showAsDropDown
(
anchor
);
}
/**
* フィルター(報告タイプ)の項目取得
* @param isAll フィルターの全ての項目を取得するか、チェックのみ取得するか判定フラグ
* @return
*/
private
ArrayList
<
Integer
>
getOperationReportTypeList
(
boolean
isAll
)
{
ArrayList
<
Integer
>
operationReportTypes
=
new
ArrayList
<>();
if
(
isAll
)
{
operationReportTypes
.
add
(
ReportType
.
Report
);
operationReportTypes
.
add
(
ReportType
.
RoutineTask
);
operationReportTypes
.
add
(
ReportType
.
ReportReply
);
}
else
{
operationReportTypes
=
getABVUIDataCache
().
getOperationReportTypes
();
}
return
operationReportTypes
;
}
// ログイン成功した後、新着更新時の「ContentVersion」APIからリソースパターンを取得し、ローカルに保存する。
private
void
setResourcePattern
()
{
Logger
.
d
(
TAG
,
"ABVEnvironment.getInstance().resourcePatternType : "
+
ABVEnvironment
.
getInstance
().
resourcePatternType
);
...
...
@@ -2062,19 +1950,6 @@ public class OperationListActivity extends ABVUIActivity {
}
/**
* フィルターの選択があるか判定して、画像を変更
*/
private
void
checkSelectedFilterType
()
{
List
<
Integer
>
defaultTypeList
=
getOperationReportTypeList
(
true
);
ArrayList
<
Integer
>
selectedOperationReportTypes
=
getOperationReportTypeList
(
false
);
if
(
defaultTypeList
.
size
()
==
selectedOperationReportTypes
.
size
())
{
mFilterButton
.
setImageDrawable
(
getRDrawable
(
R
.
drawable
.
ic_filter
));
}
else
{
mFilterButton
.
setImageDrawable
(
getRDrawable
(
R
.
drawable
.
ic_filter_selected
));
}
}
/**
* 作業種別の選択のダイアログ画面表示
* @param isInit
* @param autoClose 直下階層が存在しない場合、ダイアログを自動で閉じる
...
...
@@ -2259,7 +2134,6 @@ public class OperationListActivity extends ABVUIActivity {
putUserPref
(
AppDefType
.
UserPrefKey
.
APERTURE_MASTER_DATA_FETCH_DATE
,
ABVDataCache
.
getInstance
().
getTempApertureMasterDataFetchDate
());
}
/**
* カテゴリの一括同期ダイアログ表示
*/
...
...
@@ -2377,4 +2251,89 @@ public class OperationListActivity extends ABVUIActivity {
batchSyncView
.
setActivityDestroy
();
super
.
onDestroy
();
}
/**
* 並び替え設定メニュー(タブレット)
* @param anchor
*/
public
void
onClickSortMenuByTablet
(
View
anchor
)
{
Logger
.
d
(
TAG
,
"onClickShowSortConditionList"
);
final
ABVPopupListWindow
popup
=
new
ABVPopupListWindow
(
this
,
R
.
layout
.
popup_simple_list
);
popup
.
setTitle
(
getRString
(
R
.
string
.
sort_title
));
ListView
listView
=
popup
.
getListView
();
// ソート用のリストビューセット
ArrayAdapter
<
String
>
adapter
=
setSortListView
(
listView
);
listView
.
setAdapter
(
adapter
);
listView
.
setItemChecked
(
getABVUIDataCache
().
getSortCondition
(),
true
);
// 横幅をフィットさせる
popup
.
setWidth
((
int
)(
ABVPopupListWindow
.
getWidestView
(
this
,
adapter
)
*
1.15
));
popup
.
setOnItemClickListener
(
new
AdapterView
.
OnItemClickListener
()
{
@Override
public
void
onItemClick
(
AdapterView
<?>
parent
,
View
view
,
int
position
,
long
id
)
{
Logger
.
d
(
TAG
,
"onClickShowSortConditionList.onItemClick:"
+
id
);
getABVUIDataCache
().
setSortCondition
((
int
)
id
);
// ビューア更新
refreshOperationList
();
}
});
if
(
anchor
==
null
)
{
// 呼び出したViewが存在しない場合、真ん中に表示する
popup
.
showAtLocation
(
getWindow
().
getDecorView
().
findViewById
(
android
.
R
.
id
.
content
),
Gravity
.
CENTER
,
0
,
0
);
}
else
{
popup
.
showAsDropDown
(
anchor
);
}
}
/**
* 並び替え設定メニュー(スマートフォン)
* @param view
*/
public
void
onClickSortMenuByNormalSize
(
View
view
)
{
final
ABVListDialog
dialog
=
new
ABVListDialog
(
this
,
getString
(
R
.
string
.
sort_title
));
// ダイアログ表示時、ダイアログ以外の画面をタップしても閉じられないように設定
dialog
.
setCanceledOnTouchOutside
(
false
);
// ソート用のリストビューセット
ListView
listView
=
dialog
.
getListView
();
dialog
.
setListViewAdapter
(
setSortListView
(
listView
));
listView
.
setItemChecked
(
getABVUIDataCache
().
getSortCondition
(),
true
);
mShowDialog
=
dialog
;
// 閉じるボタン
dialog
.
setRightItemOnClickListener
(
R
.
drawable
.
ic_operation_close
,
new
View
.
OnClickListener
()
{
@Override
public
void
onClick
(
View
v
)
{
dialog
.
dismiss
();
}
});
dialog
.
setOnItemClickListener
(
new
AdapterView
.
OnItemClickListener
()
{
@Override
public
void
onItemClick
(
AdapterView
<?>
parent
,
View
view
,
int
position
,
long
id
)
{
// ポップアップ非表示
dialog
.
dismiss
();
getABVUIDataCache
().
setSortCondition
((
int
)
id
);
refreshOperationList
();
}
});
if
(
isNormalSize
())
{
dialog
.
showHalfSize
();
}
else
{
dialog
.
show
();
}
}
// 並び替えの表示するソートリスト
private
ArrayAdapter
<
String
>
setSortListView
(
ListView
listView
)
{
final
List
<
String
>
sortMembers
=
Arrays
.
asList
(
getRStringArray
(
R
.
array
.
sort_names
));
listView
.
setChoiceMode
(
AbsListView
.
CHOICE_MODE_SINGLE
);
return
new
ArrayAdapter
<>(
this
,
R
.
layout
.
item_checked_list
,
sortMembers
);
}
}
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/helper/HomeOperationListHelper.java
View file @
fbc108a4
...
...
@@ -2,6 +2,7 @@ package jp.agentec.abook.abv.ui.home.helper;
import
java.util.List
;
import
jp.agentec.abook.abv.bl.acms.type.OperationSortingType
;
import
jp.agentec.abook.abv.bl.common.log.Logger
;
import
jp.agentec.abook.abv.bl.dto.ContentDto
;
import
jp.agentec.abook.abv.bl.dto.OperationDto
;
...
...
@@ -26,7 +27,9 @@ public class HomeOperationListHelper extends OperationListHelper {
@Override
protected
List
<
OperationDto
>
findOperationList
()
throws
Exception
{
String
reportTypeStr
=
getUserPref
(
mAppActivity
,
AppDefType
.
UserPrefKey
.
OPERATION_REPORT_TYPES
,
null
);
return
operationLogic
.
getRefreshOperation
(
mAppActivity
.
mSearchWord
,
mAppActivity
.
mStartDateStr
,
mAppActivity
.
mEndDateStr
,
reportTypeStr
);
int
operationSortType
=
getUserPref
(
mAppActivity
,
AppDefType
.
UserPrefKey
.
OPERATION_SORT_CONDITION
,
0
);
OperationSortingType
operationSortingType
=
convertSortType
(
operationSortType
);
return
operationLogic
.
getRefreshOperation
(
mAppActivity
.
mSearchWord
,
mAppActivity
.
mStartDateStr
,
mAppActivity
.
mEndDateStr
,
operationSortingType
);
}
}
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/helper/OperationListHelper.java
View file @
fbc108a4
...
...
@@ -11,6 +11,7 @@ import com.handmark.pulltorefresh.library.PullToRefreshListView;
import
java.util.ArrayList
;
import
java.util.List
;
import
jp.agentec.abook.abv.bl.acms.type.OperationSortingType
;
import
jp.agentec.abook.abv.bl.common.exception.NetworkDisconnectedException
;
import
jp.agentec.abook.abv.bl.common.log.Logger
;
import
jp.agentec.abook.abv.bl.dto.OperationDto
;
...
...
@@ -59,6 +60,36 @@ public abstract class OperationListHelper {
}
/**
* ソートタイプをOperationSortingTypeに変換する
* @param sortType
* @return operationSortingType {@link OperationSortingType}
*/
public
static
OperationSortingType
convertSortType
(
int
sortType
)
{
OperationSortingType
operationSortingType
;
switch
(
sortType
)
{
case
AppDefType
.
SortType
.
OPERATION_NAME
:
operationSortingType
=
OperationSortingType
.
OperationName
;
break
;
case
AppDefType
.
SortType
.
OPERATION_START_DATE_ASC
:
operationSortingType
=
OperationSortingType
.
OperationStartDateASC
;
break
;
case
AppDefType
.
SortType
.
OPERATION_START_DATE_DESC
:
operationSortingType
=
OperationSortingType
.
OperationStartDateDESC
;
break
;
case
AppDefType
.
SortType
.
OPERATION_TYPE
:
operationSortingType
=
OperationSortingType
.
OperationType
;
break
;
case
AppDefType
.
SortType
.
READING_DATE
:
operationSortingType
=
OperationSortingType
.
ReadingDate
;
break
;
default
:
operationSortingType
=
OperationSortingType
.
OperationName
;
break
;
}
return
operationSortingType
;
}
/**
* 作業を検索してListを返す
*
* @return
...
...
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