Commit 05668f53 by Lee Jaebin

#32824 作業一覧画面改善

CMS、フォーム連携作業
バグ修正
指示・報告の登録・更新・削除処理の結合
作業一覧のデザイン変更
一時保存処理
parent 93492905
...@@ -539,10 +539,10 @@ public class AcmsClient implements AcmsClientResponseListener { ...@@ -539,10 +539,10 @@ public class AcmsClient implements AcmsClientResponseListener {
HttpMultipartList.add(new HttpMultipart(ABookKeys.TASK_HOT_SPOT_INFO, taskReportDto.taskHotSpotInfo)); HttpMultipartList.add(new HttpMultipart(ABookKeys.TASK_HOT_SPOT_INFO, taskReportDto.taskHotSpotInfo));
HttpMultipartList.add(new HttpMultipart(ABookKeys.TASK_REPORT_INFO, taskReportDto.jsonData)); HttpMultipartList.add(new HttpMultipart(ABookKeys.TASK_REPORT_INFO, taskReportDto.jsonData));
HttpMultipartList.add(new HttpMultipart(ABookKeys.ATTACHED_CHANGE_FLAG, taskReportDto.attachedFileSendFlg ? "1" : "0")); HttpMultipartList.add(new HttpMultipart(ABookKeys.ATTACHED_CHANGE_FLAG, taskReportDto.attachedFileSendFlg ? "1" : "0"));
HttpMultipartList.add(new HttpMultipart(ABookKeys.ROUTINE_TASK_FLAG, reportType == Constant.ReportType.Routine ? "1" : "0")); HttpMultipartList.add(new HttpMultipart(ABookKeys.ROUTINE_TASK_FLAG, reportType == Constant.ReportType.RoutineTask ? "1" : "0"));
// 定期点検用 // 定期点検用
if (reportType == Constant.ReportType.Routine) { if (reportType == Constant.ReportType.RoutineTask) {
HttpMultipartList.add(new HttpMultipart(ABookKeys.TASK_REPORT_ID, StringUtil.toString(taskReportDto.taskReportId))); HttpMultipartList.add(new HttpMultipart(ABookKeys.TASK_REPORT_ID, StringUtil.toString(taskReportDto.taskReportId)));
HttpMultipartList.add(new HttpMultipart(ABookKeys.TASK_REPORT_INFO_ID, StringUtil.toString(taskReportDto.taskReportInfoId))); HttpMultipartList.add(new HttpMultipart(ABookKeys.TASK_REPORT_INFO_ID, StringUtil.toString(taskReportDto.taskReportInfoId)));
HttpMultipartList.add(new HttpMultipart(ABookKeys.REPORT_START_DATE, DateTimeUtil.toStringForCmsGMT(taskReportDto.reportStartDate))); HttpMultipartList.add(new HttpMultipart(ABookKeys.REPORT_START_DATE, DateTimeUtil.toStringForCmsGMT(taskReportDto.reportStartDate)));
......
...@@ -88,12 +88,6 @@ public class Constant { ...@@ -88,12 +88,6 @@ public class Constant {
String REPORT_GPS = "reportGps"; String REPORT_GPS = "reportGps";
} }
public interface OperationReportType {
int REPORT_TYPE = 0;
int ROUTINE_TASK = 1;
int REPORT_RESPONSE_TYPE = 2;
}
public interface PushMessageSendType { public interface PushMessageSendType {
int InGroup = 0; int InGroup = 0;
int AllOperation = 1; int AllOperation = 1;
...@@ -141,7 +135,7 @@ public class Constant { ...@@ -141,7 +135,7 @@ public class Constant {
public interface ReportType { public interface ReportType {
int Report = 0; // 報告 int Report = 0; // 報告
int Routine = 1; // 定期点検 int RoutineTask = 1; // 定期点検
int ReportReply = 2; // 報告(回答) int ReportReply = 2; // 報告(回答)
} }
......
...@@ -243,6 +243,7 @@ public class OperationDao extends AbstractDao { ...@@ -243,6 +243,7 @@ public class OperationDao extends AbstractDao {
sql.append(" top.report_type, "); sql.append(" top.report_type, ");
sql.append(" top.report_cycle, "); sql.append(" top.report_cycle, ");
sql.append(" top.enable_report_update, "); sql.append(" top.enable_report_update, ");
sql.append(" top.enable_report_edit, ");
sql.append(" CASE "); sql.append(" CASE ");
sql.append(" WHEN report_type = 1 THEN ( "); sql.append(" WHEN report_type = 1 THEN ( ");
sql.append(" SELECT strftime('%Y/%m/%d %H:%M', datetime(ttr.report_start_date, 'localtime')) || ' ~ ' || strftime('%Y/%m/%d %H:%M', datetime(ttr.report_end_date, 'localtime')) "); sql.append(" SELECT strftime('%Y/%m/%d %H:%M', datetime(ttr.report_start_date, 'localtime')) || ' ~ ' || strftime('%Y/%m/%d %H:%M', datetime(ttr.report_end_date, 'localtime')) ");
......
...@@ -71,6 +71,16 @@ public class TaskReportDao extends AbstractDao { ...@@ -71,6 +71,16 @@ public class TaskReportDao extends AbstractDao {
dto.taskReportLevel = cursor.getInt(column); dto.taskReportLevel = cursor.getInt(column);
} }
column = cursor.getColumnIndex("task_report_id");
if (column != -1) {
dto.taskReportId = cursor.getInt(column);
}
column = cursor.getColumnIndex("task_report_info_id");
if (column != -1) {
dto.taskReportInfoId = cursor.getInt(column);
}
column = cursor.getColumnIndex("report_start_date"); column = cursor.getColumnIndex("report_start_date");
if (column != -1) { if (column != -1) {
dto.reportStartDate = DateTimeUtil.toDate(cursor.getString(column), "UTC", DateTimeFormat.yyyyMMddHHmmss_hyphen); dto.reportStartDate = DateTimeUtil.toDate(cursor.getString(column), "UTC", DateTimeFormat.yyyyMMddHHmmss_hyphen);
...@@ -81,10 +91,18 @@ public class TaskReportDao extends AbstractDao { ...@@ -81,10 +91,18 @@ public class TaskReportDao extends AbstractDao {
dto.reportEndDate = DateTimeUtil.toDate(cursor.getString(column), "UTC", DateTimeFormat.yyyyMMddHHmmss_hyphen); dto.reportEndDate = DateTimeUtil.toDate(cursor.getString(column), "UTC", DateTimeFormat.yyyyMMddHHmmss_hyphen);
} }
column = cursor.getColumnIndex("local_saved_flg");
if (column != -1) {
dto.localSavedFlg = toBool(cursor.getInt(column));
}
return dto; return dto;
} }
/**
* 報告登録処理
* @param dto
*/
public void insert(TaskReportDto dto) { public void insert(TaskReportDto dto) {
insert("insert into t_task_report " insert("insert into t_task_report "
+ "(task_key, " + "(task_key, "
...@@ -99,13 +117,46 @@ public class TaskReportDao extends AbstractDao { ...@@ -99,13 +117,46 @@ public class TaskReportDao extends AbstractDao {
+ "report_end_date, " + "report_end_date, "
+ "enable_report, " + "enable_report, "
+ "reported_flg, " + "reported_flg, "
+ "task_report_level) " + "task_report_level, "
+ "local_saved_flg ) "
+ "values " + "values "
+ "(?,?,?,?,?,?,?,?,?,?,?,?,?)", + "(?,?,?,?,?,?,?,?,?,?,?,?,?,?)",
dto.getInsertValues()); dto.getInsertValues());
} }
/** /**
* 報告更新処理
* @param dto
* @return
*/
public boolean update(TaskReportDto dto) {
Object[] objects;
StringBuffer sql = new StringBuffer();
sql.append("UPDATE t_task_report SET ");
sql.append("json_data=?, ");
sql.append("attached_file_name=?, ");
sql.append("local_attached_file_name=?, ");
sql.append("attached_file_send_flg=?, ");
sql.append("data_send_flg=?, ");
sql.append("report_end_date=?, ");
sql.append("enable_report=?, ");
sql.append("reported_flg=?, ");
sql.append("task_report_level=?, ");
sql.append("local_saved_flg=? ");
sql.append("WHERE task_key=? AND task_report_level=?");
if (dto.reportStartDate != null) {
sql.append(" AND datetime(report_start_date)=datetime(?)");
objects = new Object[]{dto.jsonData, dto.attachedFileName, dto.localAttachedFileName, dto.attachedFileSendFlg, dto.dataSendFlg,
dto.reportEndDate, dto.enableReport, dto.reportedFlg, dto.taskReportLevel, dto.localSavedFlg, dto.taskKey, dto.taskReportLevel, dto.reportStartDate};
} else {
objects = new Object[]{dto.jsonData, dto.attachedFileName, dto.localAttachedFileName, dto.attachedFileSendFlg, dto.dataSendFlg,
dto.reportEndDate, dto.enableReport, dto.reportedFlg, dto.taskReportLevel, dto.localSavedFlg, dto.taskKey, dto.taskReportLevel};
}
return update(sql.toString(), objects) > 0;
}
/**
* 作業IDで報告取得 * 作業IDで報告取得
* (作業報告タイプ 昇順、作業報告ID 昇順、報告開始日 昇順) * (作業報告タイプ 昇順、作業報告ID 昇順、報告開始日 昇順)
* @param operationId * @param operationId
...@@ -124,7 +175,6 @@ public class TaskReportDao extends AbstractDao { ...@@ -124,7 +175,6 @@ public class TaskReportDao extends AbstractDao {
return rawQueryGetDtoList(sb.toString(), new String[]{"" + operationId}, TaskReportDto.class); return rawQueryGetDtoList(sb.toString(), new String[]{"" + operationId}, TaskReportDto.class);
} }
/** /**
* 作業キーと作業報告タイプで作業報告データ取得 * 作業キーと作業報告タイプで作業報告データ取得
* @param taskKey * @param taskKey
...@@ -144,26 +194,6 @@ public class TaskReportDao extends AbstractDao { ...@@ -144,26 +194,6 @@ public class TaskReportDao extends AbstractDao {
return rawQueryGetDtoList("select * from t_task_report where task_key=? ORDER BY task_report_id, report_start_date", new String[]{ "" + taskKey }, TaskReportDto.class); return rawQueryGetDtoList("select * from t_task_report where task_key=? ORDER BY task_report_id, report_start_date", new String[]{ "" + taskKey }, TaskReportDto.class);
} }
public boolean update(TaskReportDto dto) {
long count = update("update t_task_report "
+ "set "
+ "json_data=?, "
+ "attached_file_name=?, "
+ "local_attached_file_name=?, "
+ "attached_file_send_flg=?, "
+ "data_send_flg=?, "
+ "task_report_id=?, "
+ "task_report_info_id=?, "
+ "report_start_date=?, "
+ "report_end_date=?, "
+ "enable_report=?, "
+ "reported_flg=?, "
+ "task_report_level=? "
+ "where task_key=? AND task_report_level=?",
dto.getUpdateValues());
return count > 0;
}
/** /**
* 送信フラグのあるデータが存在するか * 送信フラグのあるデータが存在するか
* *
...@@ -244,26 +274,6 @@ public class TaskReportDao extends AbstractDao { ...@@ -244,26 +274,6 @@ public class TaskReportDao extends AbstractDao {
} }
/** /**
* 定期点検用の報告更新
* @param dto
* @return
*/
public boolean updateRoutineTask(TaskReportDto dto) {
long count = update("update t_task_report "
+ "set "
+ "report_end_date=?, "
+ "attached_file_name=?, "
+ "local_attached_file_name=?, "
+ "json_data=?, "
+ "data_send_flg=?, "
+ "attached_file_send_flg=? "
+ "reported_flg=? "
+ "where task_key=? and task_report_id=? and datetime(report_start_date)=datetime(?)",
new Object[]{dto.reportEndDate, dto.attachedFileName, dto.localAttachedFileName, dto.jsonData, dto.dataSendFlg, dto.attachedFileSendFlg, dto.reportedFlg, dto.taskKey, dto.taskReportId, dto.reportStartDate});
return count > 0;
}
/**
* テーブル物理削除 * テーブル物理削除
* @param dto * @param dto
*/ */
...@@ -276,7 +286,7 @@ public class TaskReportDao extends AbstractDao { ...@@ -276,7 +286,7 @@ public class TaskReportDao extends AbstractDao {
* @param dto * @param dto
*/ */
public void deleteRoutineTaskReport(TaskReportDto dto) { public void deleteRoutineTaskReport(TaskReportDto dto) {
delete("t_task_report", "task_key=? and task_report_level=? task_report_id=? and datetime(report_start_date)=datetime(?, 'utc')", new String[] { dto.taskKey, "" + dto.taskReportLevel, "" + dto.taskReportId, DateTimeUtil.toString(dto.reportStartDate, DateTimeFormat.yyyyMMddHHmmss_hyphen) }); delete("t_task_report", "task_key=? AND task_report_level=? AND task_report_id=? AND datetime(report_start_date)=datetime(?, 'utc')", new String[] { dto.taskKey, "" + dto.taskReportLevel, "" + dto.taskReportId, DateTimeUtil.toString(dto.reportStartDate, DateTimeFormat.yyyyMMddHHmmss_hyphen) });
} }
/** /**
...@@ -346,11 +356,13 @@ public class TaskReportDao extends AbstractDao { ...@@ -346,11 +356,13 @@ public class TaskReportDao extends AbstractDao {
} }
/** /**
* 作業キーで作業時間が存在する作業報告データ取得(定期点検) * 定期点検報告のデータ取得
* @param taskKey * @param taskKey
* @param taskReportId
* @param reportStartDate
* @return * @return
*/ */
public List<TaskReportDto> getNotNullStartDateTaskReportByTaskKey(String taskKey) { public TaskReportDto getRoutineTaskReport(String taskKey, int taskReportId, String reportStartDate) {
return rawQueryGetDtoList("select * from t_task_report where task_key=? AND report_start_date IS NOT NULL", new String[]{ taskKey }, TaskReportDto.class); return rawQueryGetDto("select * from t_task_report where task_key=? and task_report_id=? and datetime(report_start_date)=datetime(?)", new String[]{ taskKey, "" + taskReportId, reportStartDate }, TaskReportDto.class);
} }
} }
...@@ -35,6 +35,7 @@ public class TTaskReport extends SQLiteTableScript { ...@@ -35,6 +35,7 @@ public class TTaskReport extends SQLiteTableScript {
sql.append(" , enable_report SMALLINT NOT NULL DEFAULT 0 "); sql.append(" , enable_report SMALLINT NOT NULL DEFAULT 0 ");
sql.append(" , task_report_level SMALLINT NOT NULL DEFAULT 0 "); sql.append(" , task_report_level SMALLINT NOT NULL DEFAULT 0 ");
sql.append(" , reported_flg BOOLEAN DEFAULT 0 "); sql.append(" , reported_flg BOOLEAN DEFAULT 0 ");
sql.append(" , local_saved_flg BOOLEAN DEFAULT 0 ");
sql.append(" ) "); sql.append(" ) ");
ddl.add(sql.toString()); ddl.add(sql.toString());
......
...@@ -24,17 +24,17 @@ public class TaskReportDto extends AbstractDto { ...@@ -24,17 +24,17 @@ public class TaskReportDto extends AbstractDto {
public Date reportEndDate; // 作業終了日 public Date reportEndDate; // 作業終了日
public int enableReport; // 報告可能区分 public int enableReport; // 報告可能区分
public String attachedFileName; public String attachedFileName;
public String taskReportInfo;
public boolean reportedFlg; // 定期点検用 public boolean reportedFlg; // 定期点検用
public boolean localSavedFlg; // 一時保存用
@Override @Override
public Object[] getInsertValues() { public Object[] getInsertValues() {
return new Object[] { taskKey, jsonData, attachedFileName, localAttachedFileName, attachedFileSendFlg, dataSendFlg, taskReportId, taskReportInfoId, reportStartDate, reportEndDate, enableReport, reportedFlg, taskReportLevel}; return new Object[] { taskKey, jsonData, attachedFileName, localAttachedFileName, attachedFileSendFlg, dataSendFlg, taskReportId, taskReportInfoId, reportStartDate, reportEndDate, enableReport, reportedFlg, taskReportLevel, localSavedFlg};
} }
@Override @Override
public Object[] getUpdateValues() { public Object[] getUpdateValues() {
return new Object[] { jsonData, attachedFileName, localAttachedFileName, attachedFileSendFlg, dataSendFlg, taskReportId, taskReportInfoId, reportStartDate, reportEndDate, enableReport, reportedFlg, taskReportLevel, taskKey, taskReportLevel }; return new Object[] { jsonData, attachedFileName, localAttachedFileName, attachedFileSendFlg, dataSendFlg, reportEndDate, enableReport, reportedFlg, taskReportLevel, localSavedFlg, taskKey, taskReportLevel , reportStartDate };
} }
@Override @Override
......
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/icon_infomation_update_on" android:state_enabled="true" />
<item android:drawable="@drawable/icon_infomation_update_off" android:state_enabled="false" />
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/icon_pano_edit_on" android:state_enabled="true"/>
<item android:drawable="@drawable/icon_pano_edit_off" android:state_enabled="false" />
</selector>
\ No newline at end of file
...@@ -4,7 +4,8 @@ ...@@ -4,7 +4,8 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="@drawable/list_selector_holo_light" android:background="@drawable/list_selector_holo_light"
android:descendantFocusability="blocksDescendants" android:descendantFocusability="blocksDescendants"
android:orientation="vertical"> android:padding="10dp"
android:orientation="horizontal">
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
...@@ -14,38 +15,34 @@ ...@@ -14,38 +15,34 @@
<LinearLayout <LinearLayout
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_marginLeft="30dp"
android:layout_marginTop="10dp"
android:gravity="left" android:gravity="left"
android:orientation="horizontal"> android:orientation="horizontal">
<ImageButton <ImageView
android:id="@+id/operation_type" android:id="@+id/report_type"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginRight="10dp" android:layout_marginRight="10dp"/>
android:background="@drawable/btn_pano_edit" />
<ImageButton <ImageView
android:id="@+id/operation_report_type" android:id="@+id/operation_type"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content" />
android:background="@drawable/btn_information_update" />
</LinearLayout> </LinearLayout>
<LinearLayout <LinearLayout
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="30dp" android:layout_marginLeft="15dp"
android:layout_marginTop="10dp" android:layout_weight="1"
android:orientation="vertical"> android:orientation="vertical">
<TextView <TextView
android:id="@+id/operation_name" android:id="@+id/operation_name"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:ellipsize="end" android:ellipsize="end"
android:maxLines="1" android:maxLines="1"
android:text="@string/dummy_str" android:text="@string/dummy_str"
...@@ -58,6 +55,7 @@ ...@@ -58,6 +55,7 @@
android:id="@+id/operation_date" android:id="@+id/operation_date"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:ellipsize="end" android:ellipsize="end"
android:maxLines="1" android:maxLines="1"
android:text="@string/dummy_date" android:text="@string/dummy_date"
...@@ -67,27 +65,33 @@ ...@@ -67,27 +65,33 @@
</LinearLayout> </LinearLayout>
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:gravity="right" android:layout_marginRight="10dp"
android:layout_marginLeft="30dp"
android:layout_marginTop="10dp"
android:orientation="horizontal"> android:orientation="horizontal">
<ImageButton <ImageButton
android:id="@+id/btn_pano_edit" android:id="@+id/btn_pano_edit"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginRight="10dp" android:background="@drawable/ic_edit_list"
android:background="@drawable/btn_pano_edit"
android:visibility="invisible" /> android:visibility="invisible" />
<ImageButton <ImageButton
android:id="@+id/btn_information_update" android:id="@+id/btn_sync"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="@drawable/btn_information_update" /> android:layout_marginLeft="10dp"
android:background="@drawable/ic_reload_list" />
</LinearLayout> </LinearLayout>
<ImageView
android:id="@+id/item_nextLevel"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_alignParentRight="true"
android:src="@drawable/ic_navigation_next_item"
android:visibility="visible" />
</LinearLayout> </LinearLayout>
</LinearLayout> </LinearLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="match_parent"
android:background="@drawable/list_selector_holo_light" android:background="@drawable/list_selector_holo_light"
android:descendantFocusability="blocksDescendants" android:descendantFocusability="blocksDescendants"
android:orientation="vertical"> android:orientation="vertical">
...@@ -10,24 +10,34 @@ ...@@ -10,24 +10,34 @@
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="30dp"
android:layout_marginTop="10dp" android:layout_marginTop="10dp"
android:orientation="vertical"> android:orientation="horizontal">
<LinearLayout <LinearLayout
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="match_parent"
android:orientation="vertical"> android:layout_marginTop="10dp"
android:gravity="left"
android:orientation="horizontal">
<TextView <ImageButton
android:id="@+id/operation_date" android:id="@+id/operation_type"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:ellipsize="end" android:layout_marginRight="10dp" />
android:maxLines="2"
android:text="@string/dummy_date" <ImageButton
android:textColor="@color/operation_date" android:id="@+id/report_type"
android:textSize="@dimen/operation_normal_text_size" /> android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</LinearLayout>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_weight="1"
android:orientation="vertical">
<TextView <TextView
android:id="@+id/operation_name" android:id="@+id/operation_name"
...@@ -42,12 +52,21 @@ ...@@ -42,12 +52,21 @@
android:textStyle="bold" android:textStyle="bold"
android:visibility="visible" /> android:visibility="visible" />
<TextView
android:id="@+id/operation_date"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:ellipsize="end"
android:maxLines="2"
android:text="@string/dummy_date"
android:textColor="@color/operation_date"
android:textSize="@dimen/operation_normal_text_size" />
</LinearLayout> </LinearLayout>
<LinearLayout <LinearLayout
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="right"
android:layout_margin="3dp" android:layout_margin="3dp"
android:orientation="horizontal"> android:orientation="horizontal">
...@@ -56,15 +75,23 @@ ...@@ -56,15 +75,23 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
android:background="@drawable/btn_pano_edit" /> android:background="@drawable/ic_edit_list" />
<ImageButton <ImageButton
android:id="@+id/btn_information_update" android:id="@+id/btn_sync"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
android:background="@drawable/btn_information_update" /> android:background="@drawable/ic_reload_list" />
</LinearLayout> </LinearLayout>
<ImageView
android:id="@+id/item_nextLevel"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_gravity="center"
android:src="@drawable/ic_navigation_next_item"
android:visibility="visible" />
</LinearLayout> </LinearLayout>
</LinearLayout> </LinearLayout>
\ No newline at end of file
...@@ -5,44 +5,42 @@ ...@@ -5,44 +5,42 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="@drawable/list_selector_holo_light" android:background="@drawable/list_selector_holo_light"
android:descendantFocusability="blocksDescendants" android:descendantFocusability="blocksDescendants"
android:padding="10dp"
android:orientation="vertical"> android:orientation="vertical">
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="200dp"
android:layout_margin="10dp"
android:background="@drawable/panel_frame" android:background="@drawable/panel_frame"
android:orientation="vertical" android:orientation="vertical">
android:paddingTop="10dp">
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="wrap_content"
android:padding="5dp">
<LinearLayout <LinearLayout
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="match_parent">
android:padding="5dp">
<ImageButton <ImageView
android:id="@+id/operation_type" android:id="@+id/report_type"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="@drawable/btn_information_update" /> android:layout_marginLeft="5dp"
android:layout_marginRight="10dp" />
<ImageButton <ImageView
android:id="@+id/operation_report_type" android:id="@+id/operation_type"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content" />
android:layout_marginLeft="5dp"
android:background="@drawable/btn_information_update" />
</LinearLayout> </LinearLayout>
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:padding="5dp"
android:gravity="right" android:gravity="right"
android:orientation="horizontal"> android:orientation="horizontal">
...@@ -50,15 +48,15 @@ ...@@ -50,15 +48,15 @@
android:id="@+id/btn_pano_edit" android:id="@+id/btn_pano_edit"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:visibility="invisible" android:background="@drawable/ic_edit_panel"
android:background="@drawable/btn_pano_edit" /> android:visibility="invisible" />
<ImageButton <ImageButton
android:id="@+id/btn_information_update" android:id="@+id/btn_sync"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="5dp" android:layout_marginLeft="10dp"
android:background="@drawable/btn_information_update" /> android:background="@drawable/ic_reload_panel" />
</LinearLayout> </LinearLayout>
</LinearLayout> </LinearLayout>
...@@ -66,14 +64,13 @@ ...@@ -66,14 +64,13 @@
android:id="@+id/view3" android:id="@+id/view3"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="1dp" android:layout_height="1dp"
android:layout_weight="1"
android:background="@color/line_side" /> android:background="@color/line_side" />
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="wrap_content"
android:gravity="center_vertical" android:gravity="center_vertical"
android:orientation="horizontal"> android:orientation="vertical">
<TextView <TextView
android:id="@+id/operation_name" android:id="@+id/operation_name"
...@@ -86,30 +83,19 @@ ...@@ -86,30 +83,19 @@
android:textColor="@color/operation_name" android:textColor="@color/operation_name"
android:textSize="@dimen/app_large_text_size" android:textSize="@dimen/app_large_text_size"
android:textStyle="bold" /> android:textStyle="bold" />
</LinearLayout>
<LinearLayout
android:id="@+id/operation_date_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_centerInParent="true"
android:layout_marginBottom="10dp"
android:layout_marginTop="10dp"
android:layout_weight="1"
android:orientation="vertical"
android:padding="3dp"
android:paddingBottom="10dp">
<TextView <TextView
android:id="@+id/operation_date" android:id="@+id/operation_date"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:layout_weight="1"
android:ellipsize="end" android:ellipsize="end"
android:maxLines="1" android:maxLines="1"
android:text="@string/dummy_date" android:text="@string/dummy_date"
android:textColor="@color/operation_date" android:textColor="@color/operation_date"
android:textSize="@dimen/operation_normal_text_size" /> android:textSize="@dimen/operation_normal_text_size" />
</LinearLayout> </LinearLayout>
</LinearLayout> </LinearLayout>
</LinearLayout> </LinearLayout>
\ No newline at end of file
...@@ -2,7 +2,7 @@ package jp.agentec.abook.abv.launcher.android; ...@@ -2,7 +2,7 @@ package jp.agentec.abook.abv.launcher.android;
import java.util.ArrayList; import java.util.ArrayList;
import jp.agentec.abook.abv.bl.common.Constant.OperationReportType; import jp.agentec.abook.abv.bl.common.Constant.ReportType;
import jp.agentec.abook.abv.bl.common.log.Logger; import jp.agentec.abook.abv.bl.common.log.Logger;
import jp.agentec.abook.abv.cl.util.PreferenceUtil; import jp.agentec.abook.abv.cl.util.PreferenceUtil;
import jp.agentec.abook.abv.ui.common.appinfo.AppDefType; import jp.agentec.abook.abv.ui.common.appinfo.AppDefType;
...@@ -22,7 +22,7 @@ public class ABVUIDataCache { ...@@ -22,7 +22,7 @@ public class ABVUIDataCache {
// ホーム画面項目 // ホーム画面項目
private int viewMode; // パンネル、リスト形式 private int viewMode; // パンネル、リスト形式
private ArrayList<Integer> mOperationReportTypes; private ArrayList<Integer> mReportTypes;
public long lastUpdateTime = -1; public long lastUpdateTime = -1;
public String searchText; public String searchText;
...@@ -112,7 +112,7 @@ public class ABVUIDataCache { ...@@ -112,7 +112,7 @@ public class ABVUIDataCache {
} }
public void setOperationReportTypes(ArrayList<Integer> operationReportTypes) { public void setOperationReportTypes(ArrayList<Integer> operationReportTypes) {
this.mOperationReportTypes = operationReportTypes; this.mReportTypes = operationReportTypes;
String val = null; String val = null;
if (operationReportTypes.size() > 0) { if (operationReportTypes.size() > 0) {
// カンマ区切りで保存 // カンマ区切りで保存
...@@ -137,14 +137,14 @@ public class ABVUIDataCache { ...@@ -137,14 +137,14 @@ public class ABVUIDataCache {
operationReportTypes.add(Integer.parseInt(contentType)); operationReportTypes.add(Integer.parseInt(contentType));
} }
} }
mOperationReportTypes = operationReportTypes; mReportTypes = operationReportTypes;
} else { } else {
mOperationReportTypes = new ArrayList<Integer>(); mReportTypes = new ArrayList<Integer>();
mOperationReportTypes.add(OperationReportType.REPORT_TYPE); mReportTypes.add(ReportType.Report);
mOperationReportTypes.add(OperationReportType.ROUTINE_TASK); mReportTypes.add(ReportType.RoutineTask);
mOperationReportTypes.add(OperationReportType.REPORT_RESPONSE_TYPE); mReportTypes.add(ReportType.ReportReply);
} }
return mOperationReportTypes; return mReportTypes;
} }
} }
...@@ -788,7 +788,7 @@ public abstract class ABVContentViewActivity extends ABVAuthenticatedActivity { ...@@ -788,7 +788,7 @@ public abstract class ABVContentViewActivity extends ABVAuthenticatedActivity {
helpViewType = Constant.HelpViewType.ListOperationDirector; helpViewType = Constant.HelpViewType.ListOperationDirector;
break; break;
case Constant.XWalkOpenType.TASK_REPORT: case Constant.XWalkOpenType.TASK_REPORT:
if (operationDto.reportType == Constant.OperationReportType.ROUTINE_TASK) { if (operationDto.reportType == Constant.ReportType.RoutineTask) {
helpViewType = Constant.HelpViewType.RoutineTaskOperation; helpViewType = Constant.HelpViewType.RoutineTaskOperation;
} else { } else {
helpViewType = Constant.HelpViewType.ListOperationReporter; helpViewType = Constant.HelpViewType.ListOperationReporter;
...@@ -825,7 +825,7 @@ public abstract class ABVContentViewActivity extends ABVAuthenticatedActivity { ...@@ -825,7 +825,7 @@ public abstract class ABVContentViewActivity extends ABVAuthenticatedActivity {
if (mXWalkOpenType == Constant.XWalkOpenType.TASK_DERECTION) { if (mXWalkOpenType == Constant.XWalkOpenType.TASK_DERECTION) {
helpViewType = Constant.HelpViewType.DirectorTask; helpViewType = Constant.HelpViewType.DirectorTask;
} else if (mXWalkOpenType == Constant.XWalkOpenType.TASK_REPORT) { } else if (mXWalkOpenType == Constant.XWalkOpenType.TASK_REPORT) {
if (operationDto.reportType == Constant.OperationReportType.ROUTINE_TASK) { if (operationDto.reportType == Constant.ReportType.RoutineTask) {
helpViewType = Constant.HelpViewType.RoutineTaskOperationReport; helpViewType = Constant.HelpViewType.RoutineTaskOperationReport;
} else { } else {
helpViewType = Constant.HelpViewType.ReportTask; helpViewType = Constant.HelpViewType.ReportTask;
...@@ -862,14 +862,16 @@ public abstract class ABVContentViewActivity extends ABVAuthenticatedActivity { ...@@ -862,14 +862,16 @@ public abstract class ABVContentViewActivity extends ABVAuthenticatedActivity {
} }
// 作業追加区分の値を取得する // 作業追加区分の値を取得する
mAddReport = true; mAddReport = true;
if (abookCheckParam.containsKey(ABookKeys.ADD_REPORT)) {
// 定期点検の場合、以下のフラグを変更しない(mAddReport trueのみ)
if (abookCheckParam.containsKey(ABookKeys.ADD_REPORT) && operationDto.reportType != Constant.ReportType.RoutineTask) {
mAddReport = Integer.parseInt(abookCheckParam.get(ABookKeys.ADD_REPORT)) > 0 ? true : false; mAddReport = Integer.parseInt(abookCheckParam.get(ABookKeys.ADD_REPORT)) > 0 ? true : false;
} }
int taskReportId = 0; int taskReportId = 0;
String reportStartDate = ""; String reportStartDate = "";
if (operationDto.reportType == Constant.OperationReportType.ROUTINE_TASK && abookCheckParam.get(ABookKeys.TASK_REPORT_ID) != null && abookCheckParam.get(ABookKeys.REPORT_START_DATE) != null) { if (operationDto.reportType == Constant.ReportType.RoutineTask && abookCheckParam.get(ABookKeys.TASK_REPORT_ID) != null && abookCheckParam.get(ABookKeys.REPORT_START_DATE) != null) {
taskReportId = Integer.parseInt(abookCheckParam.get(ABookKeys.TASK_REPORT_ID)); taskReportId = Integer.parseInt(abookCheckParam.get(ABookKeys.TASK_REPORT_ID));
reportStartDate = abookCheckParam.get(ABookKeys.REPORT_START_DATE); reportStartDate = abookCheckParam.get(ABookKeys.REPORT_START_DATE);
} }
......
...@@ -84,12 +84,12 @@ public class ABookCheckWebViewHelper extends ABookHelper { ...@@ -84,12 +84,12 @@ public class ABookCheckWebViewHelper extends ABookHelper {
switch (cmd) { switch (cmd) {
case ABookKeys.CMD_INSERT_TASK_REPORT: case ABookKeys.CMD_INSERT_TASK_REPORT:
case ABookKeys.CMD_UPDATE_TASK_REPORT: case ABookKeys.CMD_UPDATE_TASK_REPORT:
insertOrUpdateTaskReport(taskKey, enableReportHistory, operationId, contentId, param, contentPath, reportType, taskReportLevel, true); insertOrUpdateTaskReport(taskKey, enableReportHistory, operationId, contentId, param, contentPath, reportType, taskReportLevel, false);
copyTaskAttachedMovie(operationId, contentId, taskKey, taskReportLevel); copyTaskAttachedMovie(operationId, contentId, taskKey, taskReportLevel);
sendTaskData(context, operationId, taskKey, taskReportLevel); sendTaskData(context, operationId, taskKey, taskReportLevel);
break; break;
case ABookKeys.CMD_LOCAL_SAVE_TASK_REPORT: case ABookKeys.CMD_LOCAL_SAVE_TASK_REPORT:
insertOrUpdateTaskReport(taskKey, enableReportHistory, operationId, contentId, param, contentPath, reportType, taskReportLevel, false); insertOrUpdateTaskReport(taskKey, enableReportHistory, operationId, contentId, param, contentPath, reportType, taskReportLevel, true);
copyTaskAttachedMovie(operationId, contentId, taskKey, taskReportLevel); copyTaskAttachedMovie(operationId, contentId, taskKey, taskReportLevel);
ABVToastUtil.showMakeText(context, R.string.msg_temp_save_result, Toast.LENGTH_SHORT); ABVToastUtil.showMakeText(context, R.string.msg_temp_save_result, Toast.LENGTH_SHORT);
mFinishCallback.callback(true); mFinishCallback.callback(true);
...@@ -99,7 +99,7 @@ public class ABookCheckWebViewHelper extends ABookHelper { ...@@ -99,7 +99,7 @@ public class ABookCheckWebViewHelper extends ABookHelper {
String reportStartDate = ""; String reportStartDate = "";
boolean sendTaskReportDataFlg = false; boolean sendTaskReportDataFlg = false;
if (reportType == Constant.ReportType.Routine) { if (reportType == Constant.ReportType.RoutineTask) {
taskReportId = Integer.valueOf(param.get(ABookKeys.TASK_REPORT_ID)); taskReportId = Integer.valueOf(param.get(ABookKeys.TASK_REPORT_ID));
reportStartDate = param.get(ABookKeys.REPORT_START_DATE).replace("T", " "); reportStartDate = param.get(ABookKeys.REPORT_START_DATE).replace("T", " ");
mOperationLogic.deleteRoutineTaskReport(operationId, contentId, taskKey, taskReportId, reportStartDate); mOperationLogic.deleteRoutineTaskReport(operationId, contentId, taskKey, taskReportId, reportStartDate);
...@@ -131,7 +131,6 @@ public class ABookCheckWebViewHelper extends ABookHelper { ...@@ -131,7 +131,6 @@ public class ABookCheckWebViewHelper extends ABookHelper {
mFinishCallback.callback(false); mFinishCallback.callback(false);
break; break;
} }
} }
/** /**
...@@ -281,7 +280,7 @@ public class ABookCheckWebViewHelper extends ABookHelper { ...@@ -281,7 +280,7 @@ public class ABookCheckWebViewHelper extends ABookHelper {
* @param taskReportLevel * @param taskReportLevel
* @throws IOException * @throws IOException
*/ */
private void insertOrUpdateTaskReport(String taskKey, int enableReportHistory, long operationId, long contentId, Map<String, String> param, String contentPath, int reportType, int taskReportLevel, boolean dataSendFlg) throws IOException { private void insertOrUpdateTaskReport(String taskKey, int enableReportHistory, long operationId, long contentId, Map<String, String> param, String contentPath, int reportType, int taskReportLevel, boolean localSavedFlg) throws IOException {
int taskReportSendId = 0; int taskReportSendId = 0;
boolean attachedChangeFlag = param.get(ABookKeys.ATTACHED_CHANGE_FLAG).equals("1") ? true : false; boolean attachedChangeFlag = param.get(ABookKeys.ATTACHED_CHANGE_FLAG).equals("1") ? true : false;
String taskReport = param.get(ABookKeys.TASK_REPORT); String taskReport = param.get(ABookKeys.TASK_REPORT);
...@@ -289,14 +288,14 @@ public class ABookCheckWebViewHelper extends ABookHelper { ...@@ -289,14 +288,14 @@ public class ABookCheckWebViewHelper extends ABookHelper {
int taskReportId = 0; int taskReportId = 0;
String reportStartDate = ""; String reportStartDate = "";
if (reportType == Constant.ReportType.Routine) { if (reportType == Constant.ReportType.RoutineTask) {
taskReportId = Integer.valueOf(param.get(ABookKeys.TASK_REPORT_ID)); taskReportId = Integer.valueOf(param.get(ABookKeys.TASK_REPORT_ID));
reportStartDate = param.get(ABookKeys.REPORT_START_DATE); reportStartDate = param.get(ABookKeys.REPORT_START_DATE);
reportStartDate = reportStartDate.replace("T", " "); reportStartDate = reportStartDate.replace("T", " ");
TaskReportDto taskReportDto = mOperationLogic.getRoutineTaskReportUtc(taskKey, taskReportId, reportStartDate); TaskReportDto taskReportDto = mOperationLogic.getRoutineTaskReportUtc(taskKey, taskReportId, reportStartDate);
taskReportDto.jsonData = taskReport; taskReportDto.jsonData = taskReport;
mOperationLogic.updateRoutineTaskReport(operationId, contentId, taskReportDto, attachedChangeFlag, true, true); mOperationLogic.updateRoutineTaskReport(operationId, contentId, taskReportDto, attachedChangeFlag, true, true, localSavedFlg);
mOperationLogic.createJsonForOperationContent(operationId, contentPath, true); mOperationLogic.createJsonForOperationContent(operationId, contentPath, true);
copyRoutineTaskReportAttachedMovie(operationId, contentId, taskKey, taskReportId, reportStartDate); copyRoutineTaskReportAttachedMovie(operationId, contentId, taskKey, taskReportId, reportStartDate);
...@@ -310,27 +309,26 @@ public class ABookCheckWebViewHelper extends ABookHelper { ...@@ -310,27 +309,26 @@ public class ABookCheckWebViewHelper extends ABookHelper {
TaskReportDto taskReportDto = mOperationLogic.getTaskReport(taskKey, taskReportLevel); TaskReportDto taskReportDto = mOperationLogic.getTaskReport(taskKey, taskReportLevel);
if (taskReportDto != null) { if (taskReportDto != null) {
// 更新 // 更新
mOperationLogic.updateTaskReport(taskReportDto.taskKey, operationId, contentId, taskReportLevel, Constant.EnableReport.YES, taskReportJson, null, attachedChangeFlag, dataSendFlg); mOperationLogic.updateTaskReport(taskReportDto.taskKey, operationId, contentId, taskReportLevel, Constant.EnableReport.YES, taskReportJson, null, attachedChangeFlag, localSavedFlg ? false : true, localSavedFlg);
} else { } else {
// 登録 // 登録
mOperationLogic.insertTaskReport(taskKey, operationId, contentId, taskReportLevel, Constant.EnableReport.YES, taskReportJson, null, attachedChangeFlag, dataSendFlg); mOperationLogic.insertTaskReport(taskKey, operationId, contentId, taskReportLevel, Constant.EnableReport.YES, taskReportJson, null, attachedChangeFlag, localSavedFlg ? false : true, localSavedFlg);
} }
mOperationLogic.createJsonForOperationContent(operationId, contentPath, false); mOperationLogic.createJsonForOperationContent(operationId, contentPath, false);
copyTaskAttachedMovie(operationId, contentId, taskKey, taskReportLevel); copyTaskAttachedMovie(operationId, contentId, taskKey, taskReportLevel);
} }
if (dataSendFlg) { if (!localSavedFlg) {
if (enableReportHistory == Constant.EnableReportHistory.Invalid) { if (enableReportHistory == Constant.EnableReportHistory.Invalid) {
//データ無い場合は中でinsertされる //データ無い場合は中でinsertされる
taskReportSendId = mOperationLogic.updateTaskReportSend(taskKey, taskReportId, reportStartDate, taskReportJson, false); taskReportSendId = mOperationLogic.updateTaskReportSend(taskKey, taskReportId, reportStartDate, taskReportJson, false);
} else { } else {
taskReportSendId = mOperationLogic.insertTaskReportSend(taskKey, taskReportId, reportStartDate, taskReportJson, false); taskReportSendId = mOperationLogic.insertTaskReportSend(taskKey, taskReportId, reportStartDate, taskReportJson, false);
} }
// #32926 作業報告画面改善 start
copyReportTaskSendFiles(operationId, taskKey, taskReportSendId, reportType == Constant.ReportType.RoutineTask, taskReportId, reportStartDate, taskReportLevel);
// #32926 作業報告画面改善 end
} }
// #32926 作業報告画面改善 start
copyReportTaskSendFiles(operationId, taskKey, taskReportSendId, reportType == Constant.ReportType.Routine, taskReportId, reportStartDate, taskReportLevel);
// #32926 作業報告画面改善 end
} }
// xwalkで動画ファイルにアクセスするため、../files/..の以下のパスのディレクトりを../cache/..以下のパスに変更 // xwalkで動画ファイルにアクセスするため、../files/..の以下のパスのディレクトりを../cache/..以下のパスに変更
...@@ -340,7 +338,7 @@ public class ABookCheckWebViewHelper extends ABookHelper { ...@@ -340,7 +338,7 @@ public class ABookCheckWebViewHelper extends ABookHelper {
for (TaskDto taskDto : taskDtoList) { for (TaskDto taskDto : taskDtoList) {
List<TaskReportDto> taskReportDtoList = mOperationLogic.getTaskReportByTaskKey(taskDto.taskKey); List<TaskReportDto> taskReportDtoList = mOperationLogic.getTaskReportByTaskKey(taskDto.taskKey);
for (TaskReportDto taskReportDto : taskReportDtoList) { for (TaskReportDto taskReportDto : taskReportDtoList) {
if (operationDto.reportType == Constant.OperationReportType.ROUTINE_TASK) { if (operationDto.reportType == Constant.ReportType.RoutineTask) {
copyRoutineTaskReportAttachedMovie(operationId, contentId, taskReportDto.taskKey, taskReportDto.taskReportId, taskReportDto.reportStartDate); copyRoutineTaskReportAttachedMovie(operationId, contentId, taskReportDto.taskKey, taskReportDto.taskReportId, taskReportDto.reportStartDate);
} else { } else {
copyTaskAttachedMovie(operationId, contentId, taskDto.taskKey, taskReportDto.taskReportLevel); copyTaskAttachedMovie(operationId, contentId, taskDto.taskKey, taskReportDto.taskReportLevel);
......
...@@ -244,7 +244,7 @@ public class ParentWebViewActivity extends ABVContentViewActivity { ...@@ -244,7 +244,7 @@ public class ParentWebViewActivity extends ABVContentViewActivity {
runOnUiThread(new Runnable() { runOnUiThread(new Runnable() {
@Override @Override
public void run() { public void run() {
progressDialog.setProgress(20); progressDialogHorizontal.setProgress(20);
webViewLoadUrl(String.format("javascript:CHK_E.checkResourceEntry('%s')", resourceId)); webViewLoadUrl(String.format("javascript:CHK_E.checkResourceEntry('%s')", resourceId));
} }
}); });
...@@ -252,21 +252,21 @@ public class ParentWebViewActivity extends ABVContentViewActivity { ...@@ -252,21 +252,21 @@ public class ParentWebViewActivity extends ABVContentViewActivity {
handler.post(new Runnable() { handler.post(new Runnable() {
@Override @Override
public void run() { public void run() {
int progress = progressDialog.getProgress(); int progress = progressDialogHorizontal.getProgress();
if (progress == 0) { if (progress == 0) {
return; return;
} else if (progress == 100) { } else if (progress == 100) {
progressDialog.setProgress(0); progressDialogHorizontal.setProgress(0);
closeProgressPopup(); closeProgressPopup();
} else if (progress < 100 && progress > 80) { } else if (progress < 100 && progress > 80) {
progressDialog.setProgress(progress + 1); progressDialogHorizontal.setProgress(progress + 1);
handler.postDelayed(this, 2000); handler.postDelayed(this, 2000);
} else if (progress <= 80 && progress >= 60) { } else if (progress <= 80 && progress >= 60) {
progressDialog.setProgress(progress + 2); progressDialogHorizontal.setProgress(progress + 2);
handler.postDelayed(this, 1000); handler.postDelayed(this, 1000);
} else if (progress < 60) { } else if (progress < 60) {
progressDialog.setProgress(progress + 4); progressDialogHorizontal.setProgress(progress + 4);
handler.postDelayed(this, 1000); handler.postDelayed(this, 1000);
} }
} }
......
...@@ -278,15 +278,15 @@ public class OperationTaskLayout extends RelativeLayout { ...@@ -278,15 +278,15 @@ public class OperationTaskLayout extends RelativeLayout {
final String script = String.format(SCRIPT_SHOW_TASK_LIST, pageNum + 1); final String script = String.format(SCRIPT_SHOW_TASK_LIST, pageNum + 1);
RelativeLayout.LayoutParams params; RelativeLayout.LayoutParams params;
if (isNormalSize) { // if (isNormalSize) {
params = createParam(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT); params = createParam(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
} else { // } else {
DisplayMetrics displayMetrics = getResources().getDisplayMetrics(); // DisplayMetrics displayMetrics = getResources().getDisplayMetrics();
int halfWidth = (int) (displayMetrics.density * OperationTaskLayout.HALF_WIDTH); // int halfWidth = (int) (displayMetrics.density * OperationTaskLayout.HALF_WIDTH);
int screenWidth = displayMetrics.widthPixels; // int screenWidth = displayMetrics.widthPixels;
params = createParam(halfWidth, ViewGroup.LayoutParams.WRAP_CONTENT); // params = createParam(halfWidth, ViewGroup.LayoutParams.WRAP_CONTENT);
params.addRule(RelativeLayout.ALIGN_PARENT_RIGHT); // params.addRule(RelativeLayout.ALIGN_PARENT_RIGHT);
} // }
setLayoutParams(params); setLayoutParams(params);
...@@ -335,20 +335,20 @@ public class OperationTaskLayout extends RelativeLayout { ...@@ -335,20 +335,20 @@ public class OperationTaskLayout extends RelativeLayout {
public void setTaskFormPosition(float screenX, boolean isNormalSize) { public void setTaskFormPosition(float screenX, boolean isNormalSize) {
RelativeLayout.LayoutParams params; RelativeLayout.LayoutParams params;
if (isNormalSize) { // if (isNormalSize) {
params = createParam(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT); params = createParam(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
} else { // } else {
DisplayMetrics displayMetrics = getResources().getDisplayMetrics(); // DisplayMetrics displayMetrics = getResources().getDisplayMetrics();
int halfWidth = (int) (displayMetrics.density * OperationTaskLayout.HALF_WIDTH); // int halfWidth = (int) (displayMetrics.density * OperationTaskLayout.HALF_WIDTH);
int screenWidth = displayMetrics.widthPixels; // int screenWidth = displayMetrics.widthPixels;
params = createParam(halfWidth, ViewGroup.LayoutParams.WRAP_CONTENT); // params = createParam(halfWidth, ViewGroup.LayoutParams.WRAP_CONTENT);
//
if (screenX < screenWidth / 2) { // if (screenX < screenWidth / 2) {
params.addRule(RelativeLayout.ALIGN_PARENT_RIGHT); // params.addRule(RelativeLayout.ALIGN_PARENT_RIGHT);
} else { // } else {
params.addRule(RelativeLayout.ALIGN_PARENT_LEFT); // params.addRule(RelativeLayout.ALIGN_PARENT_LEFT);
} // }
} // }
setLayoutParams(params); setLayoutParams(params);
} }
......
...@@ -38,8 +38,8 @@ app_versioncode=1 ...@@ -38,8 +38,8 @@ app_versioncode=1
# abvEnvironments.xml # abvEnvironments.xml
#cms server #cms server
acms_address=https://abook188-1.abook.bz/acms acms_address=https://abook189.abook.bz/acms
download_server_address=https://abook188-1.abook.bz/acms download_server_address=https://abook189.abook.bz/acms
#syncview server #syncview server
websocket_server_http_url=https://abookplus.agentec.jp/v1 websocket_server_http_url=https://abookplus.agentec.jp/v1
......
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