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
1b821011
Commit
1b821011
authored
Mar 19, 2021
by
onuma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
カテゴリ絞込時にも、フィルターが使用可にした。
parent
1cf43e09
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
34 additions
and
59 deletions
+34
-59
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/dao/OperationDao.java
+24
-28
ABVJE_BL/src/jp/agentec/abook/abv/bl/logic/OperationGroupMasterLogic.java
+2
-2
ABVJE_BL/src/jp/agentec/abook/abv/bl/logic/OperationLogic.java
+0
-21
ABVJE_UI_Android/src/jp/agentec/abook/abv/launcher/android/ABVUIDataCache.java
+0
-6
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/helper/OperationGroupMasterListHelper.java
+8
-2
No files found.
ABVJE_BL/src/jp/agentec/abook/abv/bl/data/dao/OperationDao.java
View file @
1b821011
...
@@ -343,12 +343,12 @@ public class OperationDao extends AbstractDao {
...
@@ -343,12 +343,12 @@ public class OperationDao extends AbstractDao {
* @return 作業リスト
* @return 作業リスト
*/
*/
public
List
<
OperationDto
>
getOperationByReportType
(
Integer
reportType
)
{
public
List
<
OperationDto
>
getOperationByReportType
(
Integer
reportType
)
{
StringBuffer
sql
=
new
StringBuffer
();
StringBuffer
sql
=
new
StringBuffer
();
sql
.
append
(
" SELECT * "
);
sql
.
append
(
" SELECT * "
);
sql
.
append
(
" FROM t_operation "
);
sql
.
append
(
" FROM t_operation "
);
sql
.
append
(
" WHERE report_type = ?"
);
sql
.
append
(
" WHERE report_type = ?"
);
return
rawQueryGetDtoList
(
sql
.
toString
(),
new
String
[]
{
""
+
reportType
},
OperationDto
.
class
);
return
rawQueryGetDtoList
(
sql
.
toString
(),
new
String
[]
{
""
+
reportType
},
OperationDto
.
class
);
}
}
/**
/**
* ユーザ情報でグループが変更した時のみ使用
* ユーザ情報でグループが変更した時のみ使用
...
@@ -398,21 +398,28 @@ public class OperationDao extends AbstractDao {
...
@@ -398,21 +398,28 @@ public class OperationDao extends AbstractDao {
* @param operationSortingType ソートタイプ
* @param operationSortingType ソートタイプ
* @return カテゴリに紐づく作業リスト
* @return カテゴリに紐づく作業リスト
*/
*/
public
List
<
OperationDto
>
getOperationsByGroupMasterId
(
Integer
operationGroupMasterId
,
OperationSortingType
operationSortingType
)
{
public
List
<
OperationDto
>
getOperationsByGroupMasterId
(
Integer
operationGroupMasterId
,
String
reportTypeStr
,
OperationSortingType
operationSortingType
)
{
String
sql
=
generateGetOperationQuery
(
null
,
null
,
null
,
operation
SortingType
,
operationGroupMasterId
);
String
sql
=
generateGetOperationQuery
(
null
,
null
,
null
,
operation
GroupMasterId
,
reportTypeStr
,
operationSortingType
);
return
rawQueryGetDtoList
(
sql
,
null
,
OperationDto
.
class
);
return
rawQueryGetDtoList
(
sql
,
null
,
OperationDto
.
class
);
}
}
/**
/**
* 引数の検索条件で作業情報リストを
* 引数の検索条件で作業情報リストを
* 取得用のsql文作成
* 取得用のsql文作成
* @param searchOperationName
* @param searchOperationName ホーム画面入力した検索キーワード
* @param searchStartDateStr
* @param searchStartDateStr 開始期間
* @param searchEndDateStr
* @param searchEndDateStr 終了期間
* @param operationSortingType
* @param operationGroupMasterId 作業ID
* @return
* @param reportTypeStr 点検 or 報告
* @param operationSortingType ソート方向
* @return SQL文
*/
*/
private
String
generateGetOperationQuery
(
String
searchOperationName
,
String
searchStartDateStr
,
String
searchEndDateStr
,
OperationSortingType
operationSortingType
,
Integer
operationGroupMasterId
)
{
private
String
generateGetOperationQuery
(
String
searchOperationName
,
String
searchStartDateStr
,
String
searchEndDateStr
,
Integer
operationGroupMasterId
,
String
reportTypeStr
,
OperationSortingType
operationSortingType
)
{
String
curDate
=
DateTimeUtil
.
toStringInTimeZone
(
new
Date
(),
DateTimeFormat
.
yyyyMMddHHmmss_hyphen
,
"UTC"
);
String
curDate
=
DateTimeUtil
.
toStringInTimeZone
(
new
Date
(),
DateTimeFormat
.
yyyyMMddHHmmss_hyphen
,
"UTC"
);
StringBuffer
sql
=
new
StringBuffer
();
StringBuffer
sql
=
new
StringBuffer
();
...
@@ -479,6 +486,9 @@ public class OperationDao extends AbstractDao {
...
@@ -479,6 +486,9 @@ public class OperationDao extends AbstractDao {
Date
endDate
=
DateTimeUtil
.
toDate
(
searchEndDateStr
,
"UTC"
,
DateTimeFormat
.
yyyyMMdd_hyphen
);
Date
endDate
=
DateTimeUtil
.
toDate
(
searchEndDateStr
,
"UTC"
,
DateTimeFormat
.
yyyyMMdd_hyphen
);
sql
.
append
(
" AND top.operation_start_date <= '"
+
DateTimeUtil
.
toString
(
endDate
,
DateTimeFormat
.
yyyyMMdd_hyphen
)
+
"'"
);
sql
.
append
(
" AND top.operation_start_date <= '"
+
DateTimeUtil
.
toString
(
endDate
,
DateTimeFormat
.
yyyyMMdd_hyphen
)
+
"'"
);
}
}
if
(
reportTypeStr
!=
null
)
{
sql
.
append
(
" AND top.report_type in ("
+
reportTypeStr
+
")"
);
}
// 並び順
// 並び順
if
(
operationSortingType
!=
null
)
{
if
(
operationSortingType
!=
null
)
{
...
@@ -512,17 +522,4 @@ public class OperationDao extends AbstractDao {
...
@@ -512,17 +522,4 @@ public class OperationDao extends AbstractDao {
return
sql
.
toString
();
return
sql
.
toString
();
}
}
/**
* 引数の検索条件で作業情報リストを取得(作業一覧表示用)
* @param searchOperationName
* @param searchStartDateStr
* @param searchEndDateStr
* @param operationSortType
* @return
*/
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
);
}
}
}
\ No newline at end of file
ABVJE_BL/src/jp/agentec/abook/abv/bl/logic/OperationGroupMasterLogic.java
View file @
1b821011
...
@@ -165,8 +165,8 @@ public class OperationGroupMasterLogic extends AbstractLogic {
...
@@ -165,8 +165,8 @@ public class OperationGroupMasterLogic extends AbstractLogic {
* @param operationSortingType ソートタイプ
* @param operationSortingType ソートタイプ
* @return
* @return
*/
*/
public
List
<
OperationDto
>
getOperationByOperationGroupMasterId
(
Integer
operationGroupMasterId
,
OperationSortingType
operationSortingType
)
{
public
List
<
OperationDto
>
getOperationByOperationGroupMasterId
(
Integer
operationGroupMasterId
,
String
reportTypeStr
,
OperationSortingType
operationSortingType
)
{
return
mOperationDao
.
getOperationsByGroupMasterId
(
operationGroupMasterId
,
operationSortingType
);
return
mOperationDao
.
getOperationsByGroupMasterId
(
operationGroupMasterId
,
reportTypeStr
,
operationSortingType
);
}
}
}
}
ABVJE_BL/src/jp/agentec/abook/abv/bl/logic/OperationLogic.java
View file @
1b821011
...
@@ -1794,25 +1794,4 @@ public class OperationLogic extends AbstractLogic {
...
@@ -1794,25 +1794,4 @@ public class OperationLogic extends AbstractLogic {
}
}
return
result
;
return
result
;
}
}
/**
* 作業一覧取得
*
* @param searchWord 検索条件:作業名
* @param searchStartDateStr 検索条件:作業日範囲(開始)
* @param searchEndDateStr 検索条件:作業日範囲(終了)
* @param operationSortingType ソート順
* @return 作業リスト
*/
public
List
<
OperationDto
>
getRefreshOperation
(
String
searchWord
,
String
searchStartDateStr
,
String
searchEndDateStr
,
OperationSortingType
operationSortingType
)
{
List
<
OperationDto
>
operationDtoList
;
operationDtoList
=
mOperationDao
.
getOperations
(
searchWord
,
searchStartDateStr
,
searchEndDateStr
,
operationSortingType
);
for
(
OperationDto
operationDto
:
operationDtoList
)
{
// 作業送信フラグが存在する場合またはホットスポット更新フラグが存在する場合、needSyncFlgをtrueにセット
if
(
mTaskReportDao
.
isExistSendTaskData
(
operationDto
.
operationId
)
||
mTaskReportDao
.
isExistUpdateTargetHotSpotTaskData
(
operationDto
.
operationId
))
{
mOperationDao
.
updateNeedSyncFlg
(
operationDto
.
operationId
,
true
);
}
}
return
operationDtoList
;
}
}
}
ABVJE_UI_Android/src/jp/agentec/abook/abv/launcher/android/ABVUIDataCache.java
View file @
1b821011
...
@@ -56,9 +56,6 @@ public class ABVUIDataCache {
...
@@ -56,9 +56,6 @@ public class ABVUIDataCache {
private
void
init
()
{
private
void
init
()
{
viewMode
=
loadViewMode
();
viewMode
=
loadViewMode
();
///////////////////////////////////////////////////////////////////////////////////////////////////////
// カテゴリ選択機能
///////////////////////////////////////////////////////////////////////////////////////////////////////
operationGroupMasterStack
=
new
Stack
<>();
operationGroupMasterStack
=
new
Stack
<>();
}
}
...
@@ -271,9 +268,6 @@ public class ABVUIDataCache {
...
@@ -271,9 +268,6 @@ public class ABVUIDataCache {
}
}
}
}
///////////////////////////////////////////////////////////////////////////////////////////////////////
// カテゴリ選択機能
///////////////////////////////////////////////////////////////////////////////////////////////////////
// 作業種別絞り込み用のスタック
// 作業種別絞り込み用のスタック
public
Stack
<
OperationGroupMasterDto
>
operationGroupMasterStack
;
public
Stack
<
OperationGroupMasterDto
>
operationGroupMasterStack
;
/**
/**
...
...
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/helper/OperationGroupMasterListHelper.java
View file @
1b821011
...
@@ -12,9 +12,12 @@ import jp.agentec.abook.abv.bl.dto.OperationGroupMasterDto;
...
@@ -12,9 +12,12 @@ import jp.agentec.abook.abv.bl.dto.OperationGroupMasterDto;
import
jp.agentec.abook.abv.bl.logic.AbstractLogic
;
import
jp.agentec.abook.abv.bl.logic.AbstractLogic
;
import
jp.agentec.abook.abv.bl.logic.OperationGroupMasterLogic
;
import
jp.agentec.abook.abv.bl.logic.OperationGroupMasterLogic
;
import
jp.agentec.abook.abv.launcher.android.ABVApplication
;
import
jp.agentec.abook.abv.launcher.android.ABVApplication
;
import
jp.agentec.abook.abv.ui.common.appinfo.AppDefType
;
import
jp.agentec.abook.abv.ui.home.activity.OperationListActivity
;
import
jp.agentec.abook.abv.ui.home.activity.OperationListActivity
;
import
jp.agentec.adf.util.CollectionUtil
;
import
jp.agentec.adf.util.CollectionUtil
;
import
static
jp
.
agentec
.
abook
.
abv
.
cl
.
util
.
PreferenceUtil
.
getUserPref
;
public
class
OperationGroupMasterListHelper
extends
CategoryOperationListHelper
<
OperationGroupMasterDto
>
{
public
class
OperationGroupMasterListHelper
extends
CategoryOperationListHelper
<
OperationGroupMasterDto
>
{
private
static
final
String
TAG
=
"OperationGroupMasterListHelper"
;
private
static
final
String
TAG
=
"OperationGroupMasterListHelper"
;
...
@@ -72,10 +75,13 @@ public class OperationGroupMasterListHelper extends CategoryOperationListHelper<
...
@@ -72,10 +75,13 @@ public class OperationGroupMasterListHelper extends CategoryOperationListHelper<
}
}
OperationGroupMasterDto
peekOperationGroupMasterDto
=
stack
.
peek
();
OperationGroupMasterDto
peekOperationGroupMasterDto
=
stack
.
peek
();
// ソート方向
int
operationSortType
=
mAppActivity
.
getSortCondition
();
int
operationSortType
=
mAppActivity
.
getSortCondition
();
OperationSortingType
operationSortingType
=
OperationSortingType
.
parse
(
operationSortType
);
OperationSortingType
operationSortingType
=
OperationSortingType
.
parse
(
operationSortType
);
// 作業種別IDで紐づく作業リストを取得
// 報告 or 定期点検
return
mOperationGroupMasterLogic
.
getOperationByOperationGroupMasterId
(
peekOperationGroupMasterDto
.
operationGroupMasterId
,
operationSortingType
);
String
reportTypeStr
=
getUserPref
(
mAppActivity
,
AppDefType
.
UserPrefKey
.
OPERATION_REPORT_TYPES
,
null
);
return
mOperationGroupMasterLogic
.
getOperationByOperationGroupMasterId
(
peekOperationGroupMasterDto
.
operationGroupMasterId
,
reportTypeStr
,
operationSortingType
);
}
}
/**
/**
...
...
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