Browse Source

整改数据添加其他数据可以修改

ychk 3 months ago
parent
commit
a6e91bd0f1

+ 2 - 2
app/build.gradle

@@ -10,8 +10,8 @@ android {
         minSdkVersion 21
         //noinspection OldTargetApi
         targetSdkVersion 29
-        versionCode 92
-        versionName "9.2"
+        versionCode 93
+        versionName "9.3"
         testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
         ndk {
             abiFilters 'arm64-v8a'

+ 1 - 1
app/src/main/java/com/tofly/yxpc/base/Api.java

@@ -180,6 +180,6 @@ public interface Api {
     /**
      * 提交整改数据
      */
-    @POST("yt/yxswWaterMeterInspectDeal/correction")
+    @POST("yt/yxswWaterMeterInspectDeal/update")
     Observable<BaseResponse> submitDataCorrection(@Body RequestBody body);
 }

+ 4 - 10
app/src/main/java/com/tofly/yxpc/ui/fragment/UnCalibrateWorkFragment.java

@@ -40,7 +40,6 @@ public class UnCalibrateWorkFragment extends PhotoFragment {
     private final List<FileBean> photoList = new ArrayList<>();
     private WaterMeterEntity waterMeterEntity;
     private final List<DictEntity> dictEntities = new ArrayList<>();
-    private boolean isFirst = true;
     private LocationUtil_xu.CoordinateClass locationUtilXuNew = null;
 
     @Override
@@ -179,10 +178,7 @@ public class UnCalibrateWorkFragment extends PhotoFragment {
     @Override
     public void initMapView() {
         super.initMapView();
-        aMap.setOnMapTouchListener(motionEvent -> {
-            binding.llMap.mapView.requestDisallowInterceptTouchEvent(motionEvent.getAction() != MotionEvent.ACTION_UP);
-            isFirst = false;
-        });
+        aMap.setOnMapTouchListener(motionEvent -> binding.llMap.mapView.requestDisallowInterceptTouchEvent(motionEvent.getAction() != MotionEvent.ACTION_UP));
         binding.llMap.imDrag.setVisibility(View.VISIBLE);
         binding.llMap.imgNavit.setVisibility(View.GONE);
         binding.llMap.imgFw.setVisibility(View.GONE);
@@ -211,11 +207,9 @@ public class UnCalibrateWorkFragment extends PhotoFragment {
     @Override
     public void initMapListener(LocationUtil_xu.CoordinateClass info, String headName, String shortName, String areaCode) {
         super.initMapListener(info, headName, shortName, areaCode);
-        if (!isFirst) {
-            locationUtilXuNew = info;
-            binding.tvLat.setText("经度:" + locationUtilXuNew.Longtitude + " 纬度:" + locationUtilXuNew.Latitude);
-            binding.tvAddr.setText(locationUtilXuNew.addr == null ? "" : locationUtilXuNew.addr);
-        }
+        locationUtilXuNew = info;
+        binding.tvLat.setText("经度:" + locationUtilXuNew.Longtitude + " 纬度:" + locationUtilXuNew.Latitude);
+        binding.tvAddr.setText(locationUtilXuNew.addr == null ? "" : locationUtilXuNew.addr);
     }
 
     @Override

+ 3 - 7
app/src/main/java/com/tofly/yxpc/ui/fragment/WaterCheckWorkFragment.java

@@ -48,7 +48,6 @@ public class WaterCheckWorkFragment extends PhotoFragment {
     private LocationUtil_xu.CoordinateClass locationUtilXuNew = null;
     private WaterMeterEntity waterMeterEntity;
     private final List<DictEntity> dictEntities = new ArrayList<>();
-    private boolean isFirst = true;
     private final List<String> brandIdList = new ArrayList<>();
     private final List<String> calibarIdList = new ArrayList<>();
     private final List<String> typeIdList = new ArrayList<>();
@@ -420,7 +419,6 @@ public class WaterCheckWorkFragment extends PhotoFragment {
         super.initMapView();
         aMap.setOnMapTouchListener(motionEvent -> {
             binding.llMap.mapView.requestDisallowInterceptTouchEvent(motionEvent.getAction() != MotionEvent.ACTION_UP);
-            isFirst = false;
         });
         binding.llMap.imDrag.setVisibility(View.VISIBLE);
         binding.llMap.imgNavit.setVisibility(View.GONE);
@@ -465,11 +463,9 @@ public class WaterCheckWorkFragment extends PhotoFragment {
     @Override
     public void initMapListener(LocationUtil_xu.CoordinateClass info, String headName, String shortName, String areaCode) {
         super.initMapListener(info, headName, shortName, areaCode);
-        if (!isFirst) {
-            locationUtilXuNew = info;
-            binding.tvLat.setText("经度:" + locationUtilXuNew.Longtitude + " 纬度:" + locationUtilXuNew.Latitude);
-            binding.tvAddr.setText(locationUtilXuNew.addr == null ? "" : locationUtilXuNew.addr);
-        }
+        locationUtilXuNew = info;
+        binding.tvLat.setText("经度:" + locationUtilXuNew.Longtitude + " 纬度:" + locationUtilXuNew.Latitude);
+        binding.tvAddr.setText(locationUtilXuNew.addr == null ? "" : locationUtilXuNew.addr);
     }
 
     @Override

+ 2 - 0
app/src/main/res/layout/fragment_water_check_correction.xml

@@ -1131,6 +1131,7 @@
                     android:layout_width="match_parent"
                     android:layout_height="wrap_content"
                     android:layout_marginStart="@dimen/dp_10"
+                    android:layout_marginTop="@dimen/dp_14"
                     android:layout_marginEnd="@dimen/dp_10"
                     android:gravity="center_vertical"
                     android:orientation="horizontal">
@@ -1174,6 +1175,7 @@
                     android:layout_width="match_parent"
                     android:layout_height="wrap_content"
                     android:layout_marginStart="@dimen/dp_10"
+                    android:layout_marginTop="@dimen/dp_14"
                     android:layout_marginEnd="@dimen/dp_10"
                     android:gravity="center_vertical"
                     android:orientation="horizontal">