瀏覽代碼

改版本

zhanghongrui 3 周之前
父節點
當前提交
c4622d4770
共有 54 個文件被更改,包括 1947 次插入377 次删除
  1. 1 1
      app/debug/output-metadata.json
  2. 二進制
      app/debug/taishiganzhi_debug_v1.0.0_20250714.zip
  3. 二進制
      app/debug/taishiganzhi_debug_v1.0.0_20250714.apk
  4. 1 1
      app/release/output-metadata.json
  5. 二進制
      app/release/taishiganzhi_release_v1.0.0_20250714.apk
  6. 二進制
      app/release/taishiganzhi_release_v1.0.0_20250714.zip
  7. 3 0
      app/src/main/AndroidManifest.xml
  8. 413 0
      app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/DisposalResultsActivity.java
  9. 34 3
      app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/ExoPlayerActivity.java
  10. 29 28
      app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/MonitoringCenterActivity.java
  11. 13 1
      app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/MyVideoPlayerActivity.java
  12. 119 32
      app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/ResourceDetailsActivity.java
  13. 22 0
      app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/viewModel/DisposalResultsViewModel.java
  14. 1 0
      app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/viewModel/ResureDetailsViewModel.java
  15. 9 1
      app/src/main/java/com/sjkj/appthreefloor_tsgz/adapter/EventDetailsAdapter.java
  16. 10 14
      app/src/main/java/com/sjkj/appthreefloor_tsgz/adapter/ImageAdapter.java
  17. 91 0
      app/src/main/java/com/sjkj/appthreefloor_tsgz/adapter/ImageVideoAdapter.java
  18. 10 1
      app/src/main/java/com/sjkj/appthreefloor_tsgz/bean/EventMessageDetailsBean.java
  19. 25 0
      app/src/main/java/com/sjkj/appthreefloor_tsgz/bean/FileBean.java
  20. 14 0
      app/src/main/java/com/sjkj/appthreefloor_tsgz/bean/ImageBean.java
  21. 8 3
      app/src/main/java/com/sjkj/appthreefloor_tsgz/fragment/EventDetailsFragment.java
  22. 321 2
      app/src/main/java/com/sjkj/appthreefloor_tsgz/fragment/EventMessageFragment.java
  23. 2 3
      app/src/main/java/com/sjkj/appthreefloor_tsgz/net/ResureDetailsRequest.java
  24. 2 3
      app/src/main/java/com/sjkj/appthreefloor_tsgz/net/RetrofitService.java
  25. 2 1
      app/src/main/java/com/sjkj/appthreefloor_tsgz/utils/MyVideoView.java
  26. 62 0
      app/src/main/java/com/sjkj/appthreefloor_tsgz/weight/RequiredTextView.java
  27. 8 0
      app/src/main/java/com/sjkj/appthreefloor_tsgz/weight/photoview/PhotoViewActivity.java
  28. 二進制
      app/src/main/res/drawable-xxhdpi/icon_add.png
  29. 二進制
      app/src/main/res/drawable-xxhdpi/icon_camera_bg.png
  30. 二進制
      app/src/main/res/drawable-xxhdpi/icon_camera_phot.png
  31. 二進制
      app/src/main/res/drawable-xxhdpi/icon_camera_video.png
  32. 二進制
      app/src/main/res/drawable-xxhdpi/icon_photo.png
  33. 二進制
      app/src/main/res/drawable-xxhdpi/icon_result_photo.png
  34. 二進制
      app/src/main/res/drawable-xxhdpi/icon_result_video.png
  35. 7 0
      app/src/main/res/drawable/bg_event_noneed.xml
  36. 7 0
      app/src/main/res/drawable/bg_event_report.xml
  37. 10 0
      app/src/main/res/drawable/shape_dept_bg_blue.xml
  38. 159 0
      app/src/main/res/layout/activity_disposal_results.xml
  39. 30 20
      app/src/main/res/layout/activity_exo.xml
  40. 2 0
      app/src/main/res/layout/activity_my_video_player.xml
  41. 3 0
      app/src/main/res/layout/activity_photo_view.xml
  42. 196 191
      app/src/main/res/layout/activity_resure_details.xml
  43. 23 3
      app/src/main/res/layout/fragment_event_details.xml
  44. 74 3
      app/src/main/res/layout/fragment_event_message.xml
  45. 4 4
      app/src/main/res/layout/item_image_list.xml
  46. 51 0
      app/src/main/res/layout/item_image_video_list.xml
  47. 70 47
      app/src/main/res/layout/item_message_details.xml
  48. 6 7
      app/src/main/res/layout/item_video_del_list.xml
  49. 14 2
      app/src/main/res/layout/player_activity.xml
  50. 24 0
      app/src/main/res/layout/view_exopayer_point.xml
  51. 51 0
      app/src/main/res/layout/view_resource_point.xml
  52. 2 2
      app/src/main/res/values/colors.xml
  53. 14 4
      base-lib/src/main/java/com/sjkj/base_lib/utils/AppTools.java
  54. 二進制
      base-lib/src/main/res/drawable-xxhdpi/icon_image_delete.png

+ 1 - 1
app/debug/output-metadata.json

@@ -13,7 +13,7 @@
       "attributes": [],
       "versionCode": 10000,
       "versionName": "1.0.0",
-      "outputFile": "taishiganzhi_debug_v1.0.0_20250714.apk"
+      "outputFile": "taishiganzhi_debug_v1.0.0_20250721.apk"
     }
   ],
   "elementType": "File"

二進制
app/debug/taishiganzhi_debug_v1.0.0_20250714.zip


二進制
app/debug/taishiganzhi_debug_v1.0.0_20250714.apk


+ 1 - 1
app/release/output-metadata.json

@@ -13,7 +13,7 @@
       "attributes": [],
       "versionCode": 10000,
       "versionName": "1.0.0",
-      "outputFile": "taishiganzhi_release_v1.0.0_20250714.apk"
+      "outputFile": "taishiganzhi_release_v1.0.0_20250721.apk"
     }
   ],
   "elementType": "File"

二進制
app/release/taishiganzhi_release_v1.0.0_20250714.apk


二進制
app/release/taishiganzhi_release_v1.0.0_20250714.zip


+ 3 - 0
app/src/main/AndroidManifest.xml

@@ -158,6 +158,9 @@
             android:name="com.sjkj.appthreefloor_tsgz.activity.ResourceDetailsActivity"
             android:screenOrientation="portrait" />
         <activity
+            android:name="com.sjkj.appthreefloor_tsgz.activity.DisposalResultsActivity"
+            android:screenOrientation="portrait" />
+        <activity
             android:screenOrientation="landscape"
             android:name="com.sjkj.appthreefloor_tsgz.activity.ExoPlayerActivity"
             android:configChanges="orientation|screenSize|keyboardHidden"

+ 413 - 0
app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/DisposalResultsActivity.java

@@ -0,0 +1,413 @@
+package com.sjkj.appthreefloor_tsgz.activity;
+
+import android.content.Context;
+import android.content.Intent;
+import android.graphics.drawable.Drawable;
+import android.net.Uri;
+import android.os.AsyncTask;
+import android.os.Environment;
+import android.provider.MediaStore;
+import android.text.TextUtils;
+import android.util.Log;
+import android.view.View;
+
+import androidx.annotation.Nullable;
+import androidx.core.content.ContextCompat;
+import androidx.core.content.FileProvider;
+import androidx.lifecycle.ViewModelProvider;
+import androidx.recyclerview.widget.ItemTouchHelper;
+import androidx.recyclerview.widget.LinearLayoutManager;
+import androidx.recyclerview.widget.RecyclerView;
+
+import com.gyf.immersionbar.ImmersionBar;
+import com.hjq.permissions.OnPermissionCallback;
+import com.hjq.permissions.Permission;
+import com.hjq.permissions.XXPermissions;
+import com.sjkj.appthreefloor_tsgz.R;
+import com.sjkj.appthreefloor_tsgz.activity.viewModel.DisposalResultsViewModel;
+import com.sjkj.appthreefloor_tsgz.adapter.ImageAdapter;
+import com.sjkj.appthreefloor_tsgz.adapter.VideoDelAdapter;
+import com.sjkj.appthreefloor_tsgz.app.App;
+import com.sjkj.appthreefloor_tsgz.bean.FileBean;
+import com.sjkj.appthreefloor_tsgz.bean.ImageBean;
+import com.sjkj.appthreefloor_tsgz.databinding.ActivityDisposalResultsBinding;
+import com.sjkj.appthreefloor_tsgz.net.UploadFileRequest;
+import com.sjkj.appthreefloor_tsgz.utils.SlideItemTouchHelper;
+import com.sjkj.appthreefloor_tsgz.weight.photoview.PhotoViewActivity;
+import com.sjkj.base_lib.adapter.BaseRecAdapter;
+import com.sjkj.base_lib.app.AppManager;
+import com.sjkj.base_lib.net.domain.interactor.ProcessErrorSubscriber;
+import com.sjkj.base_lib.net.utils.RealPathFromUriUtils;
+import com.sjkj.base_lib.utils.AppTools;
+import com.sjkj.base_lib.utils.Constants;
+import com.sjkj.base_lib.utils.ToastUtils;
+import com.sjkj.base_lib.view.BaseActivity;
+import com.sjkj.base_lib.weight.LoadingDialog;
+import com.sjkj.base_lib.weight.silicompressor.SiliCompressor;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URISyntaxException;
+import java.text.SimpleDateFormat;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+import top.zibin.luban.CompressionPredicate;
+import top.zibin.luban.Luban;
+import top.zibin.luban.OnCompressListener;
+import top.zibin.luban.OnRenameListener;
+
+public class DisposalResultsActivity extends BaseActivity {
+    private DisposalResultsViewModel viewModel;
+    private ActivityDisposalResultsBinding binding;
+
+    private static final int TYPE_IMAGE = 1;
+    private static final int TYPE_VIDEO = 2;
+    static String mCurrentPhotoPath;
+    static Uri capturedUri = null;
+    private ImageAdapter adapter;
+    private VideoDelAdapter video_adapter;
+    private List<ImageBean> imageBeans = new ArrayList<>();
+    private List<ImageBean> imageBeans_image = new ArrayList<>();
+    private List<ImageBean> imageBeans_video = new ArrayList<>();
+    private UploadFileRequest uploadFileRequest = new UploadFileRequest(App.getInstance());
+
+    @Override
+    public void initBinding() {
+        binding = (ActivityDisposalResultsBinding) getViewDataBinding();
+        viewModel = new ViewModelProvider(this, new ViewModelProvider.NewInstanceFactory()).get(DisposalResultsViewModel.class);
+        binding.setViewModel(viewModel);
+        binding.setLifecycleOwner(this);
+    }
+
+    @Override
+    public void initListener() {
+        super.initListener();
+        binding.submit.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View view) {
+                if (adapter.getList() == null || adapter.getList().size() <= 0) {
+                    ToastUtils.show("请上传图片");
+                    return;
+                }
+            }
+        });
+
+    }
+
+    public void chooseVideo() {
+        XXPermissions.with(AppManager.getAppManager().currentActivity())
+                // .permission(Permission.WRITE_EXTERNAL_STORAGE)
+                .permission(Permission.MANAGE_EXTERNAL_STORAGE)
+                .permission(Permission.CAMERA)
+                .request(new OnPermissionCallback() {
+                    @Override
+                    public void onGranted(List<String> permissions, boolean all) {
+                        if (all) {
+                            dispatchTakeVideoIntent();
+                        } else {
+                            ToastUtils.show("获取部分权限成功,但部分权限未正常授予");
+                        }
+                    }
+
+                    @Override
+                    public void onDenied(List<String> permissions, boolean never) {
+                        if (never) {
+                            ToastUtils.show("被永久拒绝授权,请手动授予权限");
+                            // 如果是被永久拒绝就跳转到应用权限系统设置页面
+                            XXPermissions.startPermissionActivity(AppManager.getAppManager().currentActivity(), permissions);
+                        } else {
+                            ToastUtils.show("获取权限失败");
+                        }
+                    }
+                });
+    }
+
+    private void dispatchTakeVideoIntent() {
+        Intent takeVideoIntent = new Intent(MediaStore.ACTION_VIDEO_CAPTURE);
+        takeVideoIntent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
+        if (takeVideoIntent.resolveActivity(getPackageManager()) != null) {
+            try {
+
+                takeVideoIntent.putExtra(MediaStore.EXTRA_DURATION_LIMIT, 10);
+                takeVideoIntent.putExtra(MediaStore.EXTRA_VIDEO_QUALITY, 1);
+                capturedUri = FileProvider.getUriForFile(this, AppTools.getPackageNameProvider(),
+                        createMediaFile(TYPE_VIDEO));
+
+                takeVideoIntent.putExtra(MediaStore.EXTRA_OUTPUT, capturedUri);
+                startActivityForResult(takeVideoIntent, 200);
+            } catch (IOException e) {
+                e.printStackTrace();
+            }
+
+        }
+
+
+    }
+
+    private File createMediaFile(int type) throws IOException {
+
+        // Create an image file name
+        String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss").format(new Date());
+        String fileName = (type == TYPE_IMAGE) ? "JPEG_" + timeStamp + "_" : "VID_" + timeStamp + "_";
+        File storageDir = Environment.getExternalStoragePublicDirectory(
+                type == TYPE_IMAGE ? Environment.DIRECTORY_PICTURES : Environment.DIRECTORY_MOVIES);
+        if (!storageDir.exists()) {
+            storageDir.mkdir();
+        }
+
+        File file = File.createTempFile(
+                fileName,  /* prefix */
+                type == TYPE_IMAGE ? ".jpg" : ".mp4",         /* suffix */
+                storageDir      /* directory */
+        );
+
+        // Get the path of the file created
+        mCurrentPhotoPath = file.getAbsolutePath();
+        return file;
+    }
+
+    @Override
+    public void initView() {
+        super.initView();
+        getTitleView().setText("处置结果");
+        ImmersionBar.with(DisposalResultsActivity.this)
+                .statusBarDarkFont(true, 0.2f)
+                .statusBarColor(R.color.white)
+                .init();
+        getTitleView().setTextColor(getResources().getColor(R.color.black));
+        int drawableLeft = R.drawable.icon_back; // 替换为你的drawable资源ID
+        Drawable drawable = ContextCompat.getDrawable(DisposalResultsActivity.this, drawableLeft);
+        if (drawable != null) {
+            getBackView().setCompoundDrawablesRelativeWithIntrinsicBounds(drawable, null, null, null); // 使用Relative版本以支持RTL布局方向
+        }
+        getSupportActionBar().setBackgroundDrawable(getResources().getDrawable(R.color.white));
+
+
+        binding.imageAddIv.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                AppTools.chooseImage();
+
+            }
+        });
+        binding.videoAdd.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View view) {
+                chooseVideo();
+            }
+        });
+        LinearLayoutManager manager = new LinearLayoutManager(DisposalResultsActivity.this);
+        manager.setOrientation(RecyclerView.HORIZONTAL);
+        LinearLayoutManager manager1 = new LinearLayoutManager(DisposalResultsActivity.this);
+        manager1.setOrientation(RecyclerView.HORIZONTAL);
+        binding.imageRecyclerView.setLayoutManager(manager);
+        binding.videoRecyclerView.setLayoutManager(manager1);
+        adapter = new ImageAdapter(DisposalResultsActivity.this);
+        video_adapter = new VideoDelAdapter(DisposalResultsActivity.this);
+        adapter.setItemClick(new BaseRecAdapter.OnItemClick<ImageBean>() {
+            @Override
+            public void onItemClick(ImageBean bean, int position) {
+                if (adapter.getList() != null && adapter.getList().size() > 0) {
+                    ArrayList<String> imageList = new ArrayList<>();
+                    for (int i = 0; i < adapter.getList().size(); i++) {
+                        imageList.add(adapter.getList().get(i).getRealUrl());
+                    }
+
+                    Intent intent = new Intent(DisposalResultsActivity.this, PhotoViewActivity.class);
+                    intent.putStringArrayListExtra("positionDataList", imageList);
+                    intent.putExtra("position", position);
+                    startActivity(intent);
+                }
+            }
+        });
+        video_adapter.setItemClick(new BaseRecAdapter.OnItemClick<ImageBean>() {
+            @Override
+            public void onItemClick(ImageBean bean, int position) {
+
+                // startActivity(OpenFileUtil.openFile(NewEventActivity.this, mCurrentPhotoPath));
+                Intent intent = new Intent(DisposalResultsActivity.this, MyVideoPlayerActivity.class);
+                Log.d("zhr123123", bean.getPath());
+                intent.putExtra("videoUrl", bean.getPath());
+                startActivity(intent);
+            }
+        });
+
+        //添加拖拽事件                                                                 longClickPosition:初始索引值            ActionUpPosition:结束索引值
+        ItemTouchHelper.Callback callback = new SlideItemTouchHelper(DisposalResultsActivity.this, adapter);
+        ItemTouchHelper itemTouchHelper = new ItemTouchHelper(callback);
+        itemTouchHelper.attachToRecyclerView(binding.imageRecyclerView);
+        binding.imageRecyclerView.setAdapter(adapter);
+        binding.videoRecyclerView.setAdapter(video_adapter);
+
+    }
+
+
+    @Override
+    public void loadData() {
+        super.loadData();
+    }
+
+
+    @Override
+    protected int initLayout() {
+
+        return R.layout.activity_disposal_results;
+    }
+
+    @Override
+    protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
+        super.onActivityResult(requestCode, resultCode, data);
+        if (requestCode == Constants.SYSTEM_100 && resultCode == RESULT_OK) {
+            try {
+                List<Uri> list = AppTools.chooseImageResult(data);
+                Uri uri = list.get(0);
+                String path = RealPathFromUriUtils.getRealPathFromUri(this, uri);
+                File file = new File(path);
+                if (file.exists()) {
+                    showLoadingDialog();
+                    Luban.with(this).load(file).ignoreBy(100).setFocusAlpha(false).filter(new CompressionPredicate() {
+                        @Override
+                        public boolean apply(String path) {
+                            return !(TextUtils.isEmpty(path));
+                        }
+                    }).setRenameListener(new OnRenameListener() {
+                        @Override
+                        public String rename(String filePath) {
+                            String result = System.currentTimeMillis() + ".jpg";
+                            return result;
+                        }
+                    }).setCompressListener(new OnCompressListener() {
+                        @Override
+                        public void onStart() {
+                        }
+
+                        @Override
+                        public void onSuccess(File file) {
+                            //TODO 压缩成功后调用,返回压缩后的图片文件
+                            uploadFileRequest.setFile(file);
+                            uploadFileRequest.execute(new ProcessErrorSubscriber<FileBean>() {
+                                @Override
+                                public void onError(Throwable e) {
+                                    super.onError(e);
+                                    ToastUtils.show(e.getMessage());
+                                    hideLoadingDialog(LoadingDialog.LOADING_FAILED);
+                                }
+
+                                @Override
+                                public void onNext(FileBean bean) {
+                                    super.onNext(bean);
+                                    hideLoadingDialog(LoadingDialog.LOADING_SUCCESS);
+                                    ImageBean imageBean = new ImageBean();
+                                    imageBean.setRealUrl(AppTools.getImageBaseUrl() + bean.getFileUrl());
+                                    imageBean.setFileNname(bean.getFileName());
+                                    imageBeans.add(imageBean);
+                                    imageBeans_image.add(imageBean);
+                                    adapter.refreshList(imageBeans_image);
+                                }
+                            });
+                        }
+
+                        @Override
+                        public void onError(Throwable e) {
+                            //TODO 当压缩过去出现问题时调用
+                            ToastUtils.show(e.getMessage() + "");
+                            hideLoadingDialog(LoadingDialog.LOADING_FAILED);
+                        }
+                    }).launch();
+                } else {
+                    ToastUtils.show("图片不存在");
+                }
+
+            } catch (Exception e) {
+                e.printStackTrace();
+            }
+
+
+        } else if (requestCode == Constants.CODE_SUCCESS && resultCode == RESULT_OK) {
+            if (data.getData() != null) {
+                showLoadingDialog();
+                try {
+
+                    File f = new File(Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_MOVIES) + "/IntegratedPlatform/videos");
+
+                    if (f.mkdirs() || f.isDirectory()) {
+                        new VideoCompressAsyncTask(this).execute(mCurrentPhotoPath, f.getPath());
+
+                    }
+                } catch (Exception e) {
+                    e.printStackTrace();
+                }
+            }
+        }
+
+    }
+
+    class VideoCompressAsyncTask extends AsyncTask<String, String, String> {
+
+        Context mContext;
+
+        public VideoCompressAsyncTask(Context context) {
+            mContext = context;
+        }
+
+        @Override
+        protected void onPreExecute() {
+            super.onPreExecute();
+        }
+
+        @Override
+        protected String doInBackground(String... paths) {
+            String filePath = null;
+            try {
+
+                filePath = SiliCompressor.with(mContext).compressVideo(paths[0], paths[1], 1080, 720, 4000000);
+
+            } catch (URISyntaxException e) {
+                e.printStackTrace();
+            }
+            return filePath;
+
+        }
+
+
+        @Override
+        protected void onPostExecute(String compressedFilePath) {
+            super.onPostExecute(compressedFilePath);
+
+            File imageFile = new File(compressedFilePath);
+
+            Log.d("zhr123123", compressedFilePath);
+            Log.d("zhr123123fff", imageFile.getAbsolutePath());
+            uploadFileRequest.setFile(imageFile);
+            uploadFileRequest.execute(new ProcessErrorSubscriber<FileBean>() {
+                @Override
+                public void onError(Throwable e) {
+                    super.onError(e);
+                    ToastUtils.show("上传失败" + e.getMessage());
+                    hideLoadingDialog(LoadingDialog.LOADING_FAILED);
+                }
+
+                @Override
+                public void onNext(FileBean bean) {
+                    super.onNext(bean);
+                    //ToastUtils.show("上传成功" + bean.getWebUrl() + "-=-=");
+                    hideLoadingDialog(LoadingDialog.LOADING_SUCCESS);
+                    ImageBean imageBean = new ImageBean();
+                    imageBean.setRealUrl(AppTools.getImageBaseUrl() + bean.getFileUrl());
+                    imageBean.setFileNname(bean.getFileName());
+                    imageBean.setPath(imageFile.getAbsolutePath());
+                    imageBeans.add(imageBean);
+                    imageBeans_video.add(imageBean);
+                    video_adapter.refreshList(imageBeans_video);
+
+
+                }
+            });
+
+        }
+    }
+
+
+}

+ 34 - 3
app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/ExoPlayerActivity.java

@@ -2,15 +2,16 @@ package com.sjkj.appthreefloor_tsgz.activity;
 
 import android.content.pm.ActivityInfo;
 import android.net.Uri;
-import android.text.TextUtils;
+import android.util.Log;
+import android.view.LayoutInflater;
 import android.view.View;
 import android.view.WindowManager;
+import android.widget.TextView;
 
 import androidx.lifecycle.ViewModelProvider;
 
 import com.google.android.exoplayer2.ExoPlayer;
 import com.google.android.exoplayer2.MediaItem;
-import com.google.android.exoplayer2.Player;
 import com.google.android.exoplayer2.SimpleExoPlayer;
 import com.google.android.exoplayer2.ui.AspectRatioFrameLayout;
 import com.gyf.immersionbar.ImmersionBar;
@@ -25,6 +26,9 @@ import com.sjkj.base_lib.net.domain.interactor.ProcessErrorSubscriber;
 import com.sjkj.base_lib.utils.ToastUtils;
 import com.sjkj.base_lib.view.BaseActivity;
 
+import java.util.Arrays;
+import java.util.List;
+
 public class ExoPlayerActivity extends BaseActivity {
     private PlayViewModel viewModel;
     private PlayerActivityBinding binding;
@@ -91,8 +95,35 @@ public class ExoPlayerActivity extends BaseActivity {
     @Override
     public void loadData() {
         super.loadData();
+
+        List<String> list = Arrays.asList(getIntent().getStringExtra("id").split(","));
+        getUrl(list.get(0));
+        for (int i = 0; i < list.size(); i++) {
+            final int index = i;
+            View view = LayoutInflater.from(ExoPlayerActivity.this).inflate(R.layout.view_exopayer_point, null);
+            TextView tv_title = view.findViewById(R.id.tv_title);
+            tv_title.setText(i + 1 + "");
+            tv_title.setOnClickListener(new View.OnClickListener() {
+                @Override
+                public void onClick(View view) {
+                    Log.d("zhr1231", list.get(index));
+                    if (player != null) {
+                        player.release();
+                        Log.d("zhr111release","release");
+                        player = null;
+                    }
+                    getUrl(list.get(index));
+                }
+            });
+            binding.ll.addView(view);
+
+        }
+
+    }
+
+    private void getUrl(String cameraIndexCode) {
         Params params = new Params();
-        params.put("cameraIndexCode", getIntent().getStringExtra("id"));
+        params.put("cameraIndexCode", cameraIndexCode);
         getPlayerUrlRequest.setParams(params);
         getPlayerUrlRequest.execute(new ProcessErrorSubscriber<ExoPlayerBean>() {
             @Override

+ 29 - 28
app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/MonitoringCenterActivity.java

@@ -4,6 +4,7 @@ import android.content.Intent;
 import android.graphics.drawable.Drawable;
 import android.os.Build;
 import android.text.TextUtils;
+import android.util.Log;
 import android.view.View;
 
 import androidx.annotation.RequiresApi;
@@ -185,6 +186,7 @@ public class MonitoringCenterActivity extends BaseActivity {
             @Override
             public void onItemClick(AllCameraBean.Rows bean, int position) {
                 if (!TextUtils.isEmpty(bean.getChannelCode())) {
+                    Log.d("zhr1111", bean.getChannelCode());
                     startActivity(new Intent(MonitoringCenterActivity.this, ExoPlayerActivity.class).putExtra("id", bean.getChannelCode()));
                 } else {
                     ToastUtils.show("无视频源");
@@ -295,7 +297,7 @@ public class MonitoringCenterActivity extends BaseActivity {
         Params params = new Params();
         params.put("cameraName", viewModel.keyword.get());
         params.put("pageNum", currentPage);
-
+        params.put("reasonable", false);
         params.put("pageSize", 10);
         cameraListRequest.setParams(params);
         cameraListRequest.execute(new ProcessErrorSubscriber<AllCameraBean>() {
@@ -315,25 +317,24 @@ public class MonitoringCenterActivity extends BaseActivity {
                 if (beanList != null && beanList.getRows().size() > 0) {
 
                     list.addAll(beanList.getRows());
-                    for (Iterator<AllCameraBean.Rows> iterator = list.iterator(); iterator.hasNext(); ) {
-                        AllCameraBean.Rows bean = iterator.next();
-                        for (int i = 0; i < cameraTypeList.size(); i++) {
-
+                    for (int i = 0; i < list.size(); i++) {
+                        for (int j = 0; j < cameraTypeList.size(); j++) {
 
-                            if (bean.getCameraType().equals(cameraTypeList.get(i).getDictValue())) { // 例如,我们想修改名为"Banana"的元素的value属性
-                                bean.setCameraType(cameraTypeList.get(i).getDictLabel()); // 修改value属性
-                            }
+                            if (!TextUtils.isEmpty(list.get(i).getCameraType()) && null != list.get(i).getCameraType())
+                                if (list.get(i).getCameraType().equals(cameraTypeList.get(j).getDictValue())) { // 例如,我们想修改名为"Banana"的元素的value属性
+                                    list.get(i).setCameraType(cameraTypeList.get(j).getDictLabel()); // 修改value属性
+                                }
                         }
                     }
 
-                    for (Iterator<AllCameraBean.Rows> iterator = list.iterator(); iterator.hasNext(); ) {
-                        AllCameraBean.Rows bean = iterator.next();
-                        for (int i = 0; i < cameraTypeList2.size(); i++) {
+                    for (int i = 0; i < list.size(); i++) {
+                        for (int j = 0; j < cameraTypeList2.size(); j++) {
 
 
-                            if (bean.getCameraActuality().equals(cameraTypeList2.get(i).getDictValue())) { // 例如,我们想修改名为"Banana"的元素的value属性
-                                bean.setCameraActuality(cameraTypeList2.get(i).getDictLabel()); // 修改value属性
-                            }
+                            if (!TextUtils.isEmpty(list.get(i).getCameraActuality()) && null != list.get(i).getCameraActuality())
+                                if (list.get(i).getCameraActuality().equals(cameraTypeList2.get(j).getDictValue())) { // 例如,我们想修改名为"Banana"的元素的value属性
+                                    list.get(i).setCameraActuality(cameraTypeList2.get(j).getDictLabel()); // 修改value属性
+                                }
                         }
                     }
 
@@ -351,7 +352,7 @@ public class MonitoringCenterActivity extends BaseActivity {
         Params params = new Params();
         params.put("cameraName", viewModel.keyword.get());
         params.put("pageSize", 10);
-
+        params.put("reasonable", false);
         params.put("pageNum", currentPage + 1);
         cameraListRequest.setParams(params);
         cameraListRequest.execute(new ProcessErrorSubscriber<AllCameraBean>() {
@@ -369,24 +370,24 @@ public class MonitoringCenterActivity extends BaseActivity {
                 if (beanList != null && beanList.getRows().size() > 0) {
                     currentPage = currentPage + 1;
                     list.addAll(beanList.getRows());
-                    for (Iterator<AllCameraBean.Rows> iterator = list.iterator(); iterator.hasNext(); ) {
-                        AllCameraBean.Rows bean = iterator.next();
-                        for (int i = 0; i < cameraTypeList.size(); i++) {
+                    for (int i = 0; i < list.size(); i++) {
+                        for (int j = 0; j < cameraTypeList.size(); j++) {
 
-
-                            if (bean.getCameraType().equals(cameraTypeList.get(i).getDictValue())) { // 例如,我们想修改名为"Banana"的元素的value属性
-                                bean.setCameraType(cameraTypeList.get(i).getDictLabel()); // 修改value属性
-                            }
+                            if (!TextUtils.isEmpty(list.get(i).getCameraType()) && null != list.get(i).getCameraType())
+                                if (list.get(i).getCameraType().equals(cameraTypeList.get(j).getDictValue())) { // 例如,我们想修改名为"Banana"的元素的value属性
+                                    list.get(i).setCameraType(cameraTypeList.get(j).getDictLabel()); // 修改value属性
+                                }
                         }
                     }
-                    for (Iterator<AllCameraBean.Rows> iterator = list.iterator(); iterator.hasNext(); ) {
-                        AllCameraBean.Rows bean = iterator.next();
-                        for (int i = 0; i < cameraTypeList2.size(); i++) {
+
+                    for (int i = 0; i < list.size(); i++) {
+                        for (int j = 0; j < cameraTypeList2.size(); j++) {
 
 
-                            if (bean.getCameraActuality().equals(cameraTypeList2.get(i).getDictValue())) { // 例如,我们想修改名为"Banana"的元素的value属性
-                                bean.setCameraActuality(cameraTypeList2.get(i).getDictLabel()); // 修改value属性
-                            }
+                            if (!TextUtils.isEmpty(list.get(i).getCameraActuality()) && null != list.get(i).getCameraActuality())
+                                if (list.get(i).getCameraActuality().equals(cameraTypeList2.get(j).getDictValue())) { // 例如,我们想修改名为"Banana"的元素的value属性
+                                    list.get(i).setCameraActuality(cameraTypeList2.get(j).getDictLabel()); // 修改value属性
+                                }
                         }
                     }
                     adapter.refreshList(list);

+ 13 - 1
app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/MyVideoPlayerActivity.java

@@ -2,6 +2,7 @@ package com.sjkj.appthreefloor_tsgz.activity;
 
 import android.content.pm.ActivityInfo;
 import android.content.res.Configuration;
+import android.graphics.drawable.Drawable;
 import android.media.MediaPlayer;
 import android.net.Uri;
 import android.text.TextUtils;
@@ -11,10 +12,12 @@ import android.view.WindowManager;
 import android.widget.MediaController;
 
 import androidx.annotation.NonNull;
+import androidx.core.content.ContextCompat;
 import androidx.lifecycle.ViewModelProvider;
 
 import com.bumptech.glide.Glide;
 import com.bumptech.glide.request.RequestOptions;
+import com.gyf.immersionbar.ImmersionBar;
 import com.sjkj.appthreefloor_tsgz.R;
 import com.sjkj.appthreefloor_tsgz.activity.viewModel.VideoViewModel;
 import com.sjkj.appthreefloor_tsgz.databinding.ActivityMyVideoPlayerBinding;
@@ -53,7 +56,16 @@ public class MyVideoPlayerActivity extends BaseActivity {
     public void initView() {
         super.initView();
         getTitleView().setText("视频播放");
-        getSupportActionBar().show();
+        ImmersionBar.with(MyVideoPlayerActivity.this)
+                .statusBarDarkFont(true, 0.2f)
+                .statusBarColor(R.color.white)
+                .init();
+        getTitleView().setTextColor(getResources().getColor(R.color.black));
+        int drawableLeft = R.drawable.icon_back; // 替换为你的drawable资源ID
+        Drawable drawable = ContextCompat.getDrawable(MyVideoPlayerActivity.this, drawableLeft);
+        if (drawable != null) {
+            getBackView().setCompoundDrawablesRelativeWithIntrinsicBounds(drawable, null, null, null); // 使用Relative版本以支持RTL布局方向
+        }
         viewModel.videoUrl.set(getIntent().getStringExtra("videoUrl"));
         if (TextUtils.isEmpty(viewModel.videoUrl.get())){
             ToastUtils.show("视频资源有误");

+ 119 - 32
app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/ResourceDetailsActivity.java

@@ -5,12 +5,15 @@ import android.text.TextUtils;
 import android.view.Gravity;
 import android.view.View;
 import android.widget.ImageView;
+import android.widget.TextView;
 
 import androidx.core.content.ContextCompat;
 import androidx.lifecycle.ViewModelProvider;
 import androidx.recyclerview.widget.LinearLayoutManager;
 import androidx.recyclerview.widget.RecyclerView;
 
+import com.google.gson.Gson;
+import com.google.gson.GsonBuilder;
 import com.gyf.immersionbar.ImmersionBar;
 import com.hjq.permissions.OnPermissionCallback;
 import com.hjq.permissions.Permission;
@@ -22,7 +25,6 @@ import com.sjkj.appthreefloor_tsgz.activity.viewModel.ResureDetailsViewModel;
 import com.sjkj.appthreefloor_tsgz.adapter.ImagResourceDetailsAdapter;
 import com.sjkj.appthreefloor_tsgz.app.App;
 import com.sjkj.appthreefloor_tsgz.bean.ImageBean;
-import com.sjkj.appthreefloor_tsgz.bean.ResureDetailsBean;
 import com.sjkj.appthreefloor_tsgz.databinding.ActivityResureDetailsBinding;
 import com.sjkj.appthreefloor_tsgz.net.ResureDetailsRequest;
 import com.sjkj.appthreefloor_tsgz.utils.Method;
@@ -33,9 +35,14 @@ import com.sjkj.base_lib.utils.AppTools;
 import com.sjkj.base_lib.utils.LocationUtils;
 import com.sjkj.base_lib.utils.ToastUtils;
 import com.sjkj.base_lib.view.BaseActivity;
+import com.sjkj.base_lib.weight.LoadingDialog;
+
+import org.json.JSONException;
+import org.json.JSONObject;
 
 import java.util.ArrayList;
 import java.util.Arrays;
+import java.util.Iterator;
 import java.util.List;
 
 public class ResourceDetailsActivity extends BaseActivity {
@@ -152,24 +159,24 @@ public class ResourceDetailsActivity extends BaseActivity {
     public void initListener() {
         super.initListener();
 
-        binding.tvCall.setOnClickListener(new View.OnClickListener() {
-            @Override
-            public void onClick(View view) {
-                CallPhone(viewModel.phone.get());
-            }
-        });
-        binding.rlCall.setOnClickListener(new View.OnClickListener() {
-            @Override
-            public void onClick(View view) {
-                CallPhone(viewModel.phone.get());
-            }
-        });
-        binding.ivCall.setOnClickListener(new View.OnClickListener() {
-            @Override
-            public void onClick(View view) {
-                CallPhone(viewModel.phone.get());
-            }
-        });
+//        binding.tvCall.setOnClickListener(new View.OnClickListener() {
+//            @Override
+//            public void onClick(View view) {
+//                CallPhone(viewModel.phone.get());
+//            }
+//        });
+//        binding.rlCall.setOnClickListener(new View.OnClickListener() {
+//            @Override
+//            public void onClick(View view) {
+//                CallPhone(viewModel.phone.get());
+//            }
+//        });
+//        binding.ivCall.setOnClickListener(new View.OnClickListener() {
+//            @Override
+//            public void onClick(View view) {
+//                CallPhone(viewModel.phone.get());
+//            }
+//        });
     }
 
     @Override
@@ -181,25 +188,100 @@ public class ResourceDetailsActivity extends BaseActivity {
 //        params.put("tag", "waterintake");
 //        params.put("id", "1c6d2c6bb5a84077be00f1d96396c2b0");
         resureDetailsRequest.setParams(params);
-        resureDetailsRequest.execute(new ProcessErrorSubscriber<ResureDetailsBean>() {
+        resureDetailsRequest.execute(new ProcessErrorSubscriber<Object>() {
             @Override
             public void onError(Throwable e) {
                 super.onError(e);
             }
 
             @Override
-            public void onNext(ResureDetailsBean bean) {
-                super.onNext(bean);
-                if (bean.getDetail() != null) {
-                    viewModel.latitude.set(bean.getDetail().getLatitude());
-                    viewModel.longitude.set(bean.getDetail().getLongitude());
-                    viewModel.name.set(bean.getDetail().getName());
-                    viewModel.deptName.set(bean.getDetail().getDeptName());
-                    viewModel.deptNameAdm.set(bean.getDetail().getDeptNameAdm());
-                    viewModel.contact.set(bean.getDetail().getContact());
-                    viewModel.phone.set(bean.getDetail().getPhone());
-                    if (null != bean.getDetail().getUrl() && !TextUtils.isEmpty(bean.getDetail().getUrl())) {
-                        List<String> list = Arrays.asList(bean.getDetail().getUrl().split(","));
+            public void onNext(Object object) {
+//                if (bean.getDetail() != null) {
+//                    viewModel.latitude.set(bean.getDetail().getLatitude());
+//                    viewModel.longitude.set(bean.getDetail().getLongitude());
+//                    viewModel.name.set(bean.getDetail().getName());
+//                    viewModel.deptName.set(bean.getDetail().getDeptName());
+//                    viewModel.deptNameAdm.set(bean.getDetail().getDeptNameAdm());
+//                    viewModel.contact.set(bean.getDetail().getContact());
+//                    viewModel.phone.set(bean.getDetail().getPhone());
+//                    if (null != bean.getDetail().getUrl() && !TextUtils.isEmpty(bean.getDetail().getUrl())) {
+//                        List<String> list = Arrays.asList(bean.getDetail().getUrl().split(","));
+//                        List<ImageBean> imageBeanList = new ArrayList<>();
+//                        for (int i = 0; i < list.size(); i++) {
+//                            ImageBean imageBean = new ImageBean();
+//                            imageBean.setRealUrl(AppTools.getImageBaseUrl() + list.get(i));
+//                            imageBeanList.add(imageBean);
+//
+//                        }
+//                        adapter.refreshList(imageBeanList);
+//                    }
+//                }
+
+                super.onNext(object);
+                hideLoadingDialog(LoadingDialog.LOADING_SUCCESS);
+                try {
+                    GsonBuilder gsonbuilder = new GsonBuilder();
+                    gsonbuilder.serializeNulls();
+                    Gson gson = gsonbuilder.create();//禁止gson序列化  防止为null的字段不显示
+                    JSONObject detail = new JSONObject(gson.toJson(object));
+                    //JSONObject detail = jsonObject.getJSONObject("data");
+
+                    Iterator<String> keys = detail.keys();
+                    while (keys.hasNext()) {
+                        String key = keys.next();
+                        String value = detail.optString(key);
+                        View view = View.inflate(ResourceDetailsActivity.this, R.layout.view_resource_point, null);
+                        TextView tv_name = view.findViewById(R.id.tv_name);
+                        TextView tv_content = view.findViewById(R.id.tv_content);
+                        ImageView iv_call = view.findViewById(R.id.iv_call);
+
+                        if (key.contains("经度")) {
+                            viewModel.longitude.set(Double.parseDouble(value));
+                            view.setVisibility(View.GONE);
+                        }
+                        if (key.contains("纬度")) {
+                            viewModel.latitude.set(Double.parseDouble(value));
+                            view.setVisibility(View.GONE);
+                        }
+                        if (key.contains("名称")) {
+                            viewModel.name.set(value);
+                            view.setVisibility(View.GONE);
+                        }
+                        if (key.contains("图片")) {
+                            viewModel.imageUrl.set(value);
+                            view.setVisibility(View.GONE);
+                        }
+
+                        tv_name.setText(key + " : ");
+                        if (!value.equals("null") && !TextUtils.isEmpty(value)) {
+                            tv_content.setText(value);
+                        } else {
+                            tv_content.setText("无");
+                        }
+
+                        if (key.contains("联系方式") || key.contains("电话") || key.contains("手机号")) {
+                            if (!tv_content.getText().equals("无")) {
+                                iv_call.setVisibility(View.VISIBLE);
+                                iv_call.setOnClickListener(new View.OnClickListener() {
+                                    @Override
+                                    public void onClick(View view) {
+                                        CallPhone(value);
+                                    }
+                                });
+                                tv_content.setOnClickListener(new View.OnClickListener() {
+                                    @Override
+                                    public void onClick(View view) {
+                                        CallPhone(value);
+                                    }
+                                });
+                            }
+
+                        }
+                        binding.ll.addView(view);
+                    }
+
+                    if (null != viewModel.imageUrl.get() && !TextUtils.isEmpty(viewModel.imageUrl.get())) {
+                        List<String> list = Arrays.asList(viewModel.imageUrl.get().split(","));
                         List<ImageBean> imageBeanList = new ArrayList<>();
                         for (int i = 0; i < list.size(); i++) {
                             ImageBean imageBean = new ImageBean();
@@ -209,9 +291,14 @@ public class ResourceDetailsActivity extends BaseActivity {
                         }
                         adapter.refreshList(imageBeanList);
                     }
+
+                } catch (JSONException e) {
+                    e.printStackTrace();
+
                 }
 
             }
+
         });
     }
 }

+ 22 - 0
app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/viewModel/DisposalResultsViewModel.java

@@ -0,0 +1,22 @@
+package com.sjkj.appthreefloor_tsgz.activity.viewModel;
+
+import androidx.databinding.ObservableArrayList;
+import androidx.databinding.ObservableField;
+import androidx.databinding.ObservableInt;
+
+import com.sjkj.appthreefloor_tsgz.bean.EventBean;
+import com.sjkj.appthreefloor_tsgz.map.MapMarkBean;
+import com.sjkj.base_lib.view.SingleLiveData;
+import com.sjkj.base_lib.vm.BaseViewModel;
+
+import java.util.List;
+
+public class DisposalResultsViewModel extends BaseViewModel {
+    //public ObservableField<String> eventTypeValue = new ObservableField<>("");
+
+    public SingleLiveData<EventBean> singleLiveData = new SingleLiveData<>();
+
+    public void getData() {
+        singleLiveData.setValue(null);
+    }
+}

+ 1 - 0
app/src/main/java/com/sjkj/appthreefloor_tsgz/activity/viewModel/ResureDetailsViewModel.java

@@ -9,6 +9,7 @@ import com.sjkj.base_lib.vm.BaseViewModel;
 public class ResureDetailsViewModel extends BaseViewModel {
 
     public ObservableField<String> tag = new ObservableField<>("");
+    public ObservableField<String> imageUrl = new ObservableField<>("");
     public ObservableField<String> tagText = new ObservableField<>("");
     public ObservableField<String> id = new ObservableField<>("");
     public ObservableField<String> address = new ObservableField<>("");

+ 9 - 1
app/src/main/java/com/sjkj/appthreefloor_tsgz/adapter/EventDetailsAdapter.java

@@ -34,7 +34,11 @@ public class EventDetailsAdapter extends BaseRecAdapter<EventDetailsBean.DeptsBe
         } else {
             binding.llTitleBackground.setBackgroundColor(Color.parseColor("#F7F7F7"));
         }
-        if (bean.getStatus().equals("20")) {
+        if (bean.getStatus().equals("10")) {
+            //待确认
+            binding.tvStatus.setTextColor(Color.parseColor("#767676"));
+            binding.tvStatus.setText("待确认");
+        } else if (bean.getStatus().equals("20")) {
             //待签收
             binding.tvStatus.setTextColor(Color.parseColor("#04BF60"));
             binding.tvStatus.setText("待签收");
@@ -50,6 +54,10 @@ public class EventDetailsAdapter extends BaseRecAdapter<EventDetailsBean.DeptsBe
             //归档
             binding.tvStatus.setText("归档");
             binding.tvStatus.setTextColor(Color.parseColor("#5D5DFF"));
+        } else if (bean.getStatus().equals("0")) {
+            //死档
+            binding.tvStatus.setText("无需处理");
+            binding.tvStatus.setTextColor(Color.parseColor("#366CFF"));
         }
 
     }

+ 10 - 14
app/src/main/java/com/sjkj/appthreefloor_tsgz/adapter/ImageAdapter.java

@@ -2,13 +2,10 @@ package com.sjkj.appthreefloor_tsgz.adapter;
 
 import android.content.Context;
 import android.view.View;
-import android.view.ViewGroup;
-import android.widget.RelativeLayout;
 
 import com.sjkj.appthreefloor_tsgz.R;
 import com.sjkj.appthreefloor_tsgz.bean.ImageBean;
 import com.sjkj.appthreefloor_tsgz.databinding.ItemImageListBinding;
-import com.sjkj.appthreefloor_tsgz.utils.AppSystemUtils;
 import com.sjkj.appthreefloor_tsgz.utils.ItemSlideCallBack;
 import com.sjkj.base_lib.adapter.BaseRecAdapter;
 
@@ -28,7 +25,16 @@ public class ImageAdapter extends BaseRecAdapter<ImageBean, ItemImageListBinding
 
     @Override
     protected int getLayoutResId(int viewType) {
+
         return R.layout.item_image_list;
+
+
+    }
+
+    @Override
+    public int getItemViewType(int position) {
+
+        return list.get(position).getType();
     }
 
     /**
@@ -42,17 +48,7 @@ public class ImageAdapter extends BaseRecAdapter<ImageBean, ItemImageListBinding
     protected void onBindItem(ItemImageListBinding binding, ImageBean bean, int position) {
         binding.setModel(bean);
         binding.executePendingBindings();
-        if (AppSystemUtils.isGhb()) {
-            binding.rlImage.setLayoutParams(new RelativeLayout.LayoutParams(300, 300));
-            ViewGroup.LayoutParams params = binding.ivIcon.getLayoutParams();
-            params.height = 280;
-            params.width = 280;
-            binding.ivIcon.setLayoutParams(params);
-            ViewGroup.LayoutParams params_del = binding.deleteIv.getLayoutParams();
-            params_del.height = 75;
-            params_del.width = 75;
-            binding.deleteIv.setLayoutParams(params_del);
-        }
+
 //        binding.titleTv TODO
         binding.deleteIv.setOnClickListener(new View.OnClickListener() {
             @Override

+ 91 - 0
app/src/main/java/com/sjkj/appthreefloor_tsgz/adapter/ImageVideoAdapter.java

@@ -0,0 +1,91 @@
+package com.sjkj.appthreefloor_tsgz.adapter;
+
+import android.content.Context;
+import android.view.View;
+
+import com.bumptech.glide.Glide;
+import com.bumptech.glide.request.RequestOptions;
+import com.sjkj.appthreefloor_tsgz.R;
+import com.sjkj.appthreefloor_tsgz.bean.ImageBean;
+import com.sjkj.appthreefloor_tsgz.databinding.ItemImageVideoListBinding;
+import com.sjkj.appthreefloor_tsgz.utils.ItemSlideCallBack;
+import com.sjkj.base_lib.adapter.BaseRecAdapter;
+
+import java.util.Collections;
+import java.util.List;
+
+public class ImageVideoAdapter extends BaseRecAdapter<ImageBean, ItemImageVideoListBinding> implements ItemSlideCallBack {
+    private OnDeleteClick onDeleteClick;
+
+    public ImageVideoAdapter(Context context) {
+        super(context);
+    }
+
+    public ImageVideoAdapter(Context context, List<ImageBean> list) {
+        super(context, list);
+    }
+
+    @Override
+    protected int getLayoutResId(int viewType) {
+
+        return R.layout.item_image_video_list;
+
+
+    }
+
+    @Override
+    public int getItemViewType(int position) {
+
+        return list.get(position).getType();
+    }
+
+    /**
+     * 设置列表的点击事件回调接口
+     */
+    public void setOnDeleteClick(OnDeleteClick onDeleteClick) {
+        this.onDeleteClick = onDeleteClick;
+    }
+
+    @Override
+    protected void onBindItem(ItemImageVideoListBinding binding, ImageBean bean, int position) {
+        binding.setModel(bean);
+        binding.executePendingBindings();
+        if (bean.getType() == 1) {
+            binding.flHead.setVisibility(View.GONE);
+        } else {
+            binding.flHead.setVisibility(View.VISIBLE);
+        }
+        Glide.with(context)
+                .setDefaultRequestOptions(
+                        new RequestOptions()
+                                .frame(1000)
+                                .centerCrop()
+                )
+                .load(bean.getRealUrl())
+                .into(binding.ivIcon);
+//        binding.titleTv TODO
+        binding.deleteIv.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                if (list != null && list.size() > 0) {
+                    list.remove(position);
+                    notifyDataSetChanged();
+                }
+
+                if (onDeleteClick != null) {
+                    onDeleteClick.delete(bean, position);
+                }
+            }
+        });
+    }
+
+
+    @Override
+    public void onMove(int fromPosition, int toPosition) {
+        Collections.swap(list, fromPosition, toPosition);//交换数据
+        notifyItemMoved(fromPosition, toPosition);
+        notifyItemChanged(fromPosition);
+        notifyItemChanged(toPosition);
+
+    }
+}

+ 10 - 1
app/src/main/java/com/sjkj/appthreefloor_tsgz/bean/EventMessageDetailsBean.java

@@ -6,7 +6,16 @@ public class EventMessageDetailsBean {
    private String  createTime;
    private String  eventName;
    private String  files;
-   private String  remark;
+   private String remark;
+    private String deptName;
+
+    public String getDeptName() {
+        return deptName;
+    }
+
+    public void setDeptName(String deptName) {
+        this.deptName = deptName;
+    }
 
     public String getAddress() {
         return address;

+ 25 - 0
app/src/main/java/com/sjkj/appthreefloor_tsgz/bean/FileBean.java

@@ -11,7 +11,32 @@ public class FileBean {
     public void setWebName(String webName) {
         this.webName = webName;
     }
+    private String fileUrl;
+    private String fileName;
+    private String fileType;
+    public String getFileType() {
+        return fileType;
+    }
+
+    public void setFileType(String fileType) {
+        this.fileType = fileType;
+    }
+
+    public String getFileName() {
+        return fileName;
+    }
 
+    public void setFileName(String fileName) {
+        this.fileName = fileName;
+    }
+
+    public String getFileUrl() {
+        return fileUrl;
+    }
+
+    public void setFileUrl(String fileUrl) {
+        this.fileUrl = fileUrl;
+    }
     /**
      * 真实路径
      */

+ 14 - 0
app/src/main/java/com/sjkj/appthreefloor_tsgz/bean/ImageBean.java

@@ -2,12 +2,23 @@ package com.sjkj.appthreefloor_tsgz.bean;
 
 import android.net.Uri;
 
+import java.io.PipedReader;
 import java.io.Serializable;
 
 public class ImageBean implements Serializable {
     private String url;
     private String realUrl;
     private Uri uri;
+    private int type;
+
+
+    public int getType() {
+        return type;
+    }
+
+    public void setType(int type) {
+        this.type = type;
+    }
 
     public String getFileNname() {
         return fileNname;
@@ -20,6 +31,9 @@ public class ImageBean implements Serializable {
     private String path;
     private String fileNname;
 
+
+
+
     public String getUrl() {
         return url;
     }

+ 8 - 3
app/src/main/java/com/sjkj/appthreefloor_tsgz/fragment/EventDetailsFragment.java

@@ -1,5 +1,6 @@
 package com.sjkj.appthreefloor_tsgz.fragment;
 
+import android.content.Intent;
 import android.os.Bundle;
 import android.view.Gravity;
 import android.view.LayoutInflater;
@@ -13,6 +14,7 @@ import androidx.recyclerview.widget.RecyclerView;
 import com.kongzue.dialogx.dialogs.MessageDialog;
 import com.kongzue.dialogx.interfaces.OnDialogButtonClickListener;
 import com.sjkj.appthreefloor_tsgz.R;
+import com.sjkj.appthreefloor_tsgz.activity.DisposalResultsActivity;
 import com.sjkj.appthreefloor_tsgz.adapter.EventDetailsAdapter;
 import com.sjkj.appthreefloor_tsgz.app.App;
 import com.sjkj.appthreefloor_tsgz.bean.EventDetailsBean;
@@ -73,7 +75,8 @@ public class EventDetailsFragment extends BaseFragment {
         binding.tvFinish.setOnClickListener(new View.OnClickListener() {
             @Override
             public void onClick(View view) {
-                ChangeStatus("50", binding.tvFinish.getText().toString());
+                // ChangeStatus("50", binding.tvFinish.getText().toString());
+                startActivity(new Intent(getActivity(), DisposalResultsActivity.class));
             }
         });
         binding.tvRefuse.setOnClickListener(new View.OnClickListener() {
@@ -177,11 +180,13 @@ public class EventDetailsFragment extends BaseFragment {
                         //待签收
                         binding.tvCompleted.setVisibility(View.VISIBLE);
                         binding.tvRefuse.setVisibility(View.VISIBLE);
-                        binding.tvTime.setGravity(Gravity.RIGHT|Gravity.CENTER_VERTICAL);
+                        binding.tvNoNeed.setVisibility(View.VISIBLE);
+                        binding.tvTime.setGravity(Gravity.RIGHT | Gravity.CENTER_VERTICAL);
                     } else if (bean.getStatus().equals("30")) {
                         //处理中
                         binding.tvFinish.setVisibility(View.VISIBLE);
-                        binding.tvTime.setGravity(Gravity.RIGHT|Gravity.CENTER_VERTICAL);
+                        binding.tvReport.setVisibility(View.VISIBLE);
+                        binding.tvTime.setGravity(Gravity.RIGHT | Gravity.CENTER_VERTICAL);
                     } else {
                         binding.tvCompleted.setVisibility(View.GONE);
                         binding.tvRefuse.setVisibility(View.GONE);

+ 321 - 2
app/src/main/java/com/sjkj/appthreefloor_tsgz/fragment/EventMessageFragment.java

@@ -1,12 +1,24 @@
 package com.sjkj.appthreefloor_tsgz.fragment;
 
+import static android.app.Activity.RESULT_OK;
+
+import android.content.Context;
 import android.content.Intent;
+import android.hardware.camera2.CameraAccessException;
+import android.hardware.camera2.CameraManager;
+import android.net.Uri;
+import android.os.AsyncTask;
 import android.os.Bundle;
+import android.os.Environment;
+import android.provider.MediaStore;
 import android.text.TextUtils;
+import android.util.Log;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
 
+import androidx.annotation.Nullable;
+import androidx.core.content.FileProvider;
 import androidx.lifecycle.ViewModelProvider;
 import androidx.recyclerview.widget.LinearLayoutManager;
 import androidx.recyclerview.widget.RecyclerView;
@@ -16,13 +28,17 @@ import com.hjq.permissions.Permission;
 import com.hjq.permissions.XXPermissions;
 import com.sjkj.appthreefloor_tsgz.R;
 import com.sjkj.appthreefloor_tsgz.activity.MyVideoPlayerActivity;
+import com.sjkj.appthreefloor_tsgz.adapter.ImageVideoAdapter;
 import com.sjkj.appthreefloor_tsgz.adapter.MessageDetailsAdapter;
 import com.sjkj.appthreefloor_tsgz.app.App;
 import com.sjkj.appthreefloor_tsgz.bean.EventMessageDetailsBean;
+import com.sjkj.appthreefloor_tsgz.bean.FileBean;
+import com.sjkj.appthreefloor_tsgz.bean.ImageBean;
 import com.sjkj.appthreefloor_tsgz.databinding.FragmentEventMessageBinding;
 import com.sjkj.appthreefloor_tsgz.fragment.viewModel.EventFargmentViewModel;
 import com.sjkj.appthreefloor_tsgz.net.EventAddFeedBackRequest;
 import com.sjkj.appthreefloor_tsgz.net.EventMessageListRequest;
+import com.sjkj.appthreefloor_tsgz.net.UploadFileRequest;
 import com.sjkj.appthreefloor_tsgz.utils.DownLoadUtils;
 import com.sjkj.appthreefloor_tsgz.utils.ImageUtils;
 import com.sjkj.appthreefloor_tsgz.utils.OpenFileUtil;
@@ -30,15 +46,28 @@ import com.sjkj.appthreefloor_tsgz.weight.photoview.PhotoViewActivity;
 import com.sjkj.base_lib.app.AppManager;
 import com.sjkj.base_lib.entity.Params;
 import com.sjkj.base_lib.net.domain.interactor.ProcessErrorSubscriber;
+import com.sjkj.base_lib.net.utils.RealPathFromUriUtils;
 import com.sjkj.base_lib.utils.AppTools;
+import com.sjkj.base_lib.utils.Constants;
 import com.sjkj.base_lib.utils.ToastUtils;
 import com.sjkj.base_lib.view.BaseFragment;
 import com.sjkj.base_lib.weight.LoadingDialog;
+import com.sjkj.base_lib.weight.silicompressor.SiliCompressor;
 
+import java.io.File;
+import java.io.IOException;
+import java.net.URISyntaxException;
+import java.text.SimpleDateFormat;
 import java.util.ArrayList;
 import java.util.Arrays;
+import java.util.Date;
 import java.util.List;
 
+import top.zibin.luban.CompressionPredicate;
+import top.zibin.luban.Luban;
+import top.zibin.luban.OnCompressListener;
+import top.zibin.luban.OnRenameListener;
+
 public class EventMessageFragment extends BaseFragment {
     private FragmentEventMessageBinding binding;
     private EventFargmentViewModel viewModel;
@@ -47,6 +76,14 @@ public class EventMessageFragment extends BaseFragment {
     private EventAddFeedBackRequest addFeedBackRequest = new EventAddFeedBackRequest(App.getInstance());
     private boolean isauthorization = false;
     private List<EventMessageDetailsBean> feedBackDetailsBeanList = new ArrayList<>();
+    private static final int TYPE_IMAGE = 1;
+    private static final int TYPE_VIDEO = 2;
+    static String mCurrentPhotoPath;
+    static Uri capturedUri = null;
+    private List<ImageBean> imageBeans = new ArrayList<>();
+    private List<ImageBean> imageBeans_image = new ArrayList<>();
+    private UploadFileRequest uploadFileRequest = new UploadFileRequest(App.getInstance());
+    private ImageVideoAdapter imageAdapter;
 
     private void requestPermissionsReadAndWrite() {
         XXPermissions.with(AppManager.getAppManager().currentActivity())
@@ -90,22 +127,153 @@ public class EventMessageFragment extends BaseFragment {
 
     @Override
     public void initView() {
+        imageBeans_image.clear();
         LinearLayoutManager manager = new LinearLayoutManager(getActivity());
         manager.setOrientation(RecyclerView.VERTICAL);
         binding.fkRecyclerView.setLayoutManager(manager);
         adapter = new MessageDetailsAdapter(getActivity());
         binding.fkRecyclerView.setAdapter(adapter);
+        LinearLayoutManager manager1 = new LinearLayoutManager(getActivity());
+        manager1.setOrientation(RecyclerView.HORIZONTAL);
+        binding.imageRecyclerView.setLayoutManager(manager1);
+        imageAdapter = new ImageVideoAdapter(getActivity());
+        binding.imageRecyclerView.setAdapter(imageAdapter);
+    }
+
+    /**
+     * 判断是否有摄像头,摄像头是否可用
+     *
+     * @return
+     */
+    private boolean isCameraOpen() {
+        boolean isCamera = false;
+        try {
+            CameraManager cameraManager = (CameraManager) getActivity().getSystemService(Context.CAMERA_SERVICE);
+            String[] cameraIds = cameraManager.getCameraIdList();
+            if (cameraIds.length > 0) {
+                //摄像头存在
+                if (cameraIds[0] != null || cameraIds[1] != null) {
+                    isCamera = true;
+                }
+            }
+        } catch (IllegalStateException | CameraAccessException e) {
+            e.printStackTrace();
+        }
+        return isCamera;
+    }
+
+    private void dispatchTakeVideoIntent() {
+
+        Intent takeVideoIntent = new Intent(MediaStore.ACTION_VIDEO_CAPTURE);
+        takeVideoIntent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
+        if (takeVideoIntent.resolveActivity(getActivity().getPackageManager()) != null || isCameraOpen()) {
+            try {
+
+                takeVideoIntent.putExtra(MediaStore.EXTRA_DURATION_LIMIT, 10);
+                takeVideoIntent.putExtra(MediaStore.EXTRA_VIDEO_QUALITY, 1);
+                capturedUri = FileProvider.getUriForFile(getActivity(), AppTools.getPackageNameProvider(),
+                        createMediaFile(TYPE_VIDEO));
+
+                takeVideoIntent.putExtra(MediaStore.EXTRA_OUTPUT, capturedUri);
+                startActivityForResult(takeVideoIntent, 200);
+            } catch (IOException e) {
+                e.printStackTrace();
+            }
+
+        }
+
+
+    }
+
+    private File createMediaFile(int type) throws IOException {
+
+        // Create an image file name
+        String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss").format(new Date());
+        String fileName = (type == TYPE_IMAGE) ? "JPEG_" + timeStamp + "_" : "VID_" + timeStamp + "_";
+        File storageDir = Environment.getExternalStoragePublicDirectory(
+                type == TYPE_IMAGE ? Environment.DIRECTORY_PICTURES : Environment.DIRECTORY_MOVIES);
+        if (!storageDir.exists()) {
+            storageDir.mkdir();
+        }
+
+        File file = File.createTempFile(
+                fileName,  /* prefix */
+                type == TYPE_IMAGE ? ".jpg" : ".mp4",         /* suffix */
+                storageDir      /* directory */
+        );
+
+        // Get the path of the file created
+        mCurrentPhotoPath = file.getAbsolutePath();
+        return file;
+    }
+
+    public void chooseVideo() {
+
+        XXPermissions.with(AppManager.getAppManager().currentActivity())
+                // .permission(Permission.WRITE_EXTERNAL_STORAGE)
+                .permission(Permission.MANAGE_EXTERNAL_STORAGE)
+                .permission(Permission.CAMERA)
+                .request(new OnPermissionCallback() {
+                    @Override
+                    public void onGranted(List<String> permissions, boolean all) {
+                        if (all) {
+                            dispatchTakeVideoIntent();
+                        } else {
+                            ToastUtils.show("获取部分权限成功,但部分权限未正常授予");
+                        }
+                    }
+
+                    @Override
+                    public void onDenied(List<String> permissions, boolean never) {
+                        if (never) {
+                            ToastUtils.show("被永久拒绝授权,请手动授予权限");
+                            // 如果是被永久拒绝就跳转到应用权限系统设置页面
+                            XXPermissions.startPermissionActivity(AppManager.getAppManager().currentActivity(), permissions);
+                        } else {
+                            ToastUtils.show("获取权限失败");
+                        }
+                    }
+                });
     }
 
     @Override
     public void initListener() {
+        binding.ivPhoto.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View view) {
+                binding.llPhotoVideo.setVisibility(binding.llPhotoVideo.getVisibility() == View.VISIBLE ? View.GONE : View.VISIBLE);
+
+            }
+        });
+
+        binding.llPhoto.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                AppTools.chooseImageFragment(EventMessageFragment.this);
+
+            }
+        });
+        binding.llVideo.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View view) {
+                chooseVideo();
+            }
+        });
         binding.icSend.setOnClickListener(new View.OnClickListener() {
             @Override
             public void onClick(View view) {
-                if (TextUtils.isEmpty(binding.etContent.getText().toString())) {
-                    ToastUtils.show("请输入内容");
+
+
+                if (TextUtils.isEmpty(binding.etContent.getText().toString()) && imageAdapter.getList() == null) {
+                    ToastUtils.show("请输入内容或上传图片/视频");
                     return;
                 }
+                if (imageAdapter.getList() != null && imageAdapter.getList().size() > 0) {
+                    for (int i = 0; i < imageAdapter.getList().size(); i++) {
+                        Log.d("zhr1231", "===" + imageAdapter.getList().get(i).getRealUrl());
+
+                    }
+                }
                 showLoadingDialog();
                 Params params = new Params();
                 params.put("eventId", getActivity().getIntent().getStringExtra("id"));
@@ -246,4 +414,155 @@ public class EventMessageFragment extends BaseFragment {
             }
         });
     }
+
+    @Override
+    public void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
+        super.onActivityResult(requestCode, resultCode, data);
+
+        if (requestCode == Constants.SYSTEM_100 && resultCode == RESULT_OK) {
+            try {
+                List<Uri> list = AppTools.chooseImageResult(data);
+                Uri uri = list.get(0);
+                String path = RealPathFromUriUtils.getRealPathFromUri(getActivity(), uri);
+                File file = new File(path);
+                if (file.exists()) {
+                    showLoadingDialog();
+                    Luban.with(getActivity()).load(file).ignoreBy(100).setFocusAlpha(false).filter(new CompressionPredicate() {
+                        @Override
+                        public boolean apply(String path) {
+                            return !(TextUtils.isEmpty(path));
+                        }
+                    }).setRenameListener(new OnRenameListener() {
+                        @Override
+                        public String rename(String filePath) {
+                            String result = System.currentTimeMillis() + ".jpg";
+                            return result;
+                        }
+                    }).setCompressListener(new OnCompressListener() {
+                        @Override
+                        public void onStart() {
+                        }
+
+                        @Override
+                        public void onSuccess(File file) {
+                            //TODO 压缩成功后调用,返回压缩后的图片文件
+                            uploadFileRequest.setFile(file);
+                            uploadFileRequest.execute(new ProcessErrorSubscriber<FileBean>() {
+                                @Override
+                                public void onError(Throwable e) {
+                                    super.onError(e);
+                                    ToastUtils.show(e.getMessage());
+                                    hideLoadingDialog(LoadingDialog.LOADING_FAILED);
+                                }
+
+                                @Override
+                                public void onNext(FileBean bean) {
+                                    super.onNext(bean);
+                                    hideLoadingDialog(LoadingDialog.LOADING_SUCCESS);
+                                    ImageBean imageBean = new ImageBean();
+                                    imageBean.setRealUrl(AppTools.getImageBaseUrl() + bean.getFileUrl());
+                                    imageBean.setFileNname(bean.getFileName());
+                                    imageBean.setType(TYPE_IMAGE);
+                                    imageBeans.add(imageBean);
+                                    imageBeans_image.add(imageBean);
+                                    imageAdapter.refreshList(imageBeans_image);
+                                }
+                            });
+                        }
+
+                        @Override
+                        public void onError(Throwable e) {
+                            //TODO 当压缩过去出现问题时调用
+                            ToastUtils.show(e.getMessage() + "");
+                            hideLoadingDialog(LoadingDialog.LOADING_FAILED);
+                        }
+                    }).launch();
+                } else {
+                    ToastUtils.show("图片不存在");
+                }
+
+            } catch (Exception e) {
+                e.printStackTrace();
+            }
+
+
+        } else if (requestCode == Constants.CODE_SUCCESS && resultCode == RESULT_OK) {
+            if (data.getData() != null) {
+                showLoadingDialog();
+                try {
+
+                    File f = new File(Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_MOVIES) + "/IntegratedPlatform/videos");
+
+                    if (f.mkdirs() || f.isDirectory()) {
+                        new VideoCompressAsyncTask(getActivity()).execute(mCurrentPhotoPath, f.getPath());
+
+                    }
+                } catch (Exception e) {
+                    e.printStackTrace();
+                }
+            }
+        }
+    }
+
+    class VideoCompressAsyncTask extends AsyncTask<String, String, String> {
+
+        Context mContext;
+
+        public VideoCompressAsyncTask(Context context) {
+            mContext = context;
+        }
+
+        @Override
+        protected void onPreExecute() {
+            super.onPreExecute();
+        }
+
+        @Override
+        protected String doInBackground(String... paths) {
+            String filePath = null;
+            try {
+
+                filePath = SiliCompressor.with(mContext).compressVideo(paths[0], paths[1], 1080, 720, 4000000);
+
+            } catch (URISyntaxException e) {
+                e.printStackTrace();
+            }
+            return filePath;
+
+        }
+
+
+        @Override
+        protected void onPostExecute(String compressedFilePath) {
+            super.onPostExecute(compressedFilePath);
+
+            File imageFile = new File(compressedFilePath);
+
+            uploadFileRequest.setFile(imageFile);
+            uploadFileRequest.execute(new ProcessErrorSubscriber<FileBean>() {
+                @Override
+                public void onError(Throwable e) {
+                    super.onError(e);
+                    ToastUtils.show("上传失败" + e.getMessage());
+                    hideLoadingDialog(LoadingDialog.LOADING_FAILED);
+                }
+
+                @Override
+                public void onNext(FileBean bean) {
+                    super.onNext(bean);
+                    //ToastUtils.show("上传成功" + bean.getWebUrl() + "-=-=");
+                    hideLoadingDialog(LoadingDialog.LOADING_SUCCESS);
+                    ImageBean imageBean = new ImageBean();
+                    imageBean.setRealUrl(AppTools.getImageBaseUrl() + bean.getFileUrl());
+                    imageBean.setFileNname(bean.getFileName());
+                    imageBean.setType(TYPE_VIDEO);
+                    imageBeans.add(imageBean);
+                    imageBeans_image.add(imageBean);
+                    imageAdapter.refreshList(imageBeans_image);
+
+                }
+            });
+
+        }
+    }
 }

+ 2 - 3
app/src/main/java/com/sjkj/appthreefloor_tsgz/net/ResureDetailsRequest.java

@@ -2,7 +2,6 @@ package com.sjkj.appthreefloor_tsgz.net;
 
 import android.content.Context;
 
-import com.sjkj.appthreefloor_tsgz.bean.ResureDetailsBean;
 import com.sjkj.base_lib.entity.Params;
 import com.sjkj.base_lib.entity.ResponseBean;
 import com.sjkj.base_lib.net.RetrofitFactory;
@@ -37,9 +36,9 @@ public class ResureDetailsRequest extends UseCase {
 
     @Override
     protected Observable buildUseCaseObservable() {
-        return service.resureDetails(params).flatMap(new Func1<ResponseBean<ResureDetailsBean>, Observable<ResureDetailsBean>>() {
+        return service.resureDetails(params).flatMap(new Func1<ResponseBean<Object>, Observable<Object>>() {
             @Override
-            public Observable<ResureDetailsBean> call(ResponseBean<ResureDetailsBean> responseBean) {
+            public Observable<Object> call(ResponseBean<Object> responseBean) {
                 if (!ResponseBean.CODE_SUCCESS.
                         equals(responseBean.getCode())) {
                     return Observable.error(new BusinessException(responseBean.getMsg()));

+ 2 - 3
app/src/main/java/com/sjkj/appthreefloor_tsgz/net/RetrofitService.java

@@ -17,7 +17,6 @@ import com.sjkj.appthreefloor_tsgz.bean.NoticeListBean;
 import com.sjkj.appthreefloor_tsgz.bean.ProFileBean;
 import com.sjkj.appthreefloor_tsgz.bean.ResourceVisualizationBean;
 import com.sjkj.appthreefloor_tsgz.bean.ResourcesListBean;
-import com.sjkj.appthreefloor_tsgz.bean.ResureDetailsBean;
 import com.sjkj.appthreefloor_tsgz.bean.VersionBean;
 import com.sjkj.base_lib.entity.Params;
 import com.sjkj.base_lib.entity.ResponseBean;
@@ -56,7 +55,7 @@ public interface RetrofitService {
 
     //资源详情
     @GET("data/resourceDetail")
-    Observable<ResponseBean<ResureDetailsBean>> resureDetails(@QueryMap Params params);
+    Observable<ResponseBean<Object>> resureDetails(@QueryMap Params params);
 
     //首页-通知公告
     @GET("system/noticeList")
@@ -103,7 +102,7 @@ public interface RetrofitService {
 
     //上传文件
     @Multipart
-    @POST("AppFileController/appUpload")
+    @POST("system/upload")
     Observable<ResponseBean<FileBean>> upload(@Part MultipartBody.Part file);
 
     //校验版本信息

+ 2 - 1
app/src/main/java/com/sjkj/appthreefloor_tsgz/utils/MyVideoView.java

@@ -16,6 +16,7 @@ import com.google.android.exoplayer2.MediaMetadata;
 import com.google.android.exoplayer2.PlaybackException;
 import com.google.android.exoplayer2.PlaybackParameters;
 import com.google.android.exoplayer2.Player;
+import com.google.android.exoplayer2.SimpleExoPlayer;
 import com.google.android.exoplayer2.Timeline;
 import com.google.android.exoplayer2.audio.AudioAttributes;
 import com.google.android.exoplayer2.device.DeviceInfo;
@@ -78,7 +79,7 @@ public class MyVideoView extends RelativeLayout {
     public MyVideoView(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
         super(context, attrs, defStyleAttr, defStyleRes);
         this.context = context;
-        this.player = new ExoPlayer.Builder(context).build();
+        this.player = new SimpleExoPlayer.Builder(context).build();
         PlayerView videoView = new PlayerView(context);
         videoView.setPlayer(player);
         videoView.setUseController(false);

+ 62 - 0
app/src/main/java/com/sjkj/appthreefloor_tsgz/weight/RequiredTextView.java

@@ -0,0 +1,62 @@
+package com.sjkj.appthreefloor_tsgz.weight;
+
+import android.content.Context;
+import android.content.res.TypedArray;
+import android.graphics.Color;
+import android.text.Spannable;
+import android.text.SpannableString;
+import android.text.TextUtils;
+import android.text.style.ForegroundColorSpan;
+import android.util.AttributeSet;
+import android.util.Log;
+
+import androidx.annotation.Nullable;
+
+import com.sjkj.appthreefloor_tsgz.R;
+
+
+public class RequiredTextView extends androidx.appcompat.widget.AppCompatTextView {
+
+    private String prefix = " *";
+    private int prefixColor = Color.RED;
+
+    public RequiredTextView(Context context) {
+        super(context);
+    }
+
+    public RequiredTextView(Context context, @Nullable AttributeSet attrs) {
+        super(context, attrs);
+        init(context, attrs);
+    }
+
+    public RequiredTextView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
+        super(context, attrs, defStyleAttr);
+        init(context, attrs);
+    }
+
+    private void init(Context context, @Nullable AttributeSet attrs) {
+        TypedArray ta = context.obtainStyledAttributes(attrs, R.styleable.RequiredTextView);
+
+        prefix = ta.getString(R.styleable.RequiredTextView_prefix);
+        prefixColor = ta.getInteger(R.styleable.RequiredTextView_prefix_color, Color.RED);
+        String text = ta.getString(R.styleable.RequiredTextView_android_text);
+        if (TextUtils.isEmpty(prefix)) {
+            prefix = "* ";
+        }
+        if (TextUtils.isEmpty(text)) {
+            text = "";
+        }
+        ta.recycle();
+        setText(text, true);
+    }
+
+    public void setText(String text, boolean isRequired) {
+
+        if (isRequired) {
+            Spannable span = new SpannableString(prefix + text);
+            span.setSpan(new ForegroundColorSpan(prefixColor), 0, 2, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
+            setText(span);
+
+        } else setText(text);
+    }
+}

+ 8 - 0
app/src/main/java/com/sjkj/appthreefloor_tsgz/weight/photoview/PhotoViewActivity.java

@@ -48,6 +48,13 @@ public class PhotoViewActivity extends BaseActivity {
                 .statusBarDarkFont(true, 0.2f)
                 .statusBarColor(R.color.white)
                 .init();
+        getTitleView().setTextColor(getResources().getColor(R.color.black));
+        int drawableLeft = R.drawable.icon_back; // 替换为你的drawable资源ID
+        Drawable drawable = ContextCompat.getDrawable(PhotoViewActivity.this, drawableLeft);
+        if (drawable != null) {
+            getBackView().setCompoundDrawablesRelativeWithIntrinsicBounds(drawable, null, null, null); // 使用Relative版本以支持RTL布局方向
+        }
+        getSupportActionBar().setBackgroundDrawable(getResources().getDrawable(R.color.white));
         imageUrls = (ArrayList<String>) getIntent().getStringArrayListExtra("positionDataList");
         if (imageUrls != null) {
             currentPosition = getIntent().getIntExtra("position", 0);
@@ -55,6 +62,7 @@ public class PhotoViewActivity extends BaseActivity {
             binding.viewPager.setAdapter(adapter);
             binding.viewPager.setCurrentItem(currentPosition, false);
             viewModel.title.set(currentPosition + 1 + "/" + imageUrls.size());
+            getTitleView().setText(viewModel.title.get());
             binding.viewPager.addOnPageChangeListener(new ViewPager.OnPageChangeListener() {
                 @Override
                 public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) {

二進制
app/src/main/res/drawable-xxhdpi/icon_add.png


二進制
app/src/main/res/drawable-xxhdpi/icon_camera_bg.png


二進制
app/src/main/res/drawable-xxhdpi/icon_camera_phot.png


二進制
app/src/main/res/drawable-xxhdpi/icon_camera_video.png


二進制
app/src/main/res/drawable-xxhdpi/icon_photo.png


二進制
app/src/main/res/drawable-xxhdpi/icon_result_photo.png


二進制
app/src/main/res/drawable-xxhdpi/icon_result_video.png


+ 7 - 0
app/src/main/res/drawable/bg_event_noneed.xml

@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+    android:shape="rectangle">
+    <corners android:radius="5dp"/>
+    <solid android:color="#E4EBFF"/>
+    <stroke android:color="#366CFF" android:width="1dp"/>
+</shape>

+ 7 - 0
app/src/main/res/drawable/bg_event_report.xml

@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+    android:shape="rectangle">
+    <corners android:radius="5dp"/>
+    <solid android:color="#FFF3ED"/>
+    <stroke android:color="#FF5900" android:width="1dp"/>
+</shape>

+ 10 - 0
app/src/main/res/drawable/shape_dept_bg_blue.xml

@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+    android:shape="rectangle">
+    <corners android:radius="50dp" />
+    <gradient
+        android:angle="45"
+        android:startColor="#FF5AADFF"
+        android:endColor="#FF0080FF"
+        android:type="linear" />
+</shape>

+ 159 - 0
app/src/main/res/layout/activity_disposal_results.xml

@@ -0,0 +1,159 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layout xmlns:android="http://schemas.android.com/apk/res/android">
+
+    <data>
+
+        <variable
+            name="viewModel"
+            type="com.sjkj.appthreefloor_tsgz.activity.viewModel.DisposalResultsViewModel" />
+    </data>
+
+    <RelativeLayout
+        android:fadeScrollbars="true"
+        android:fitsSystemWindows="true"
+        android:layout_width="match_parent"
+        android:layout_height="match_parent">
+
+
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:background="#FFECEDF4"
+            android:orientation="vertical">
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="15dp"
+                android:orientation="horizontal">
+
+                <View
+
+                    android:layout_width="1.5dp"
+                    android:layout_height="15dp"
+                    android:layout_marginLeft="20dp"
+                    android:background="#FF005DFF"></View>
+
+                <com.sjkj.appthreefloor_tsgz.weight.RequiredTextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_gravity="center_vertical"
+                    android:layout_marginLeft="5dp"
+                    android:text="上传图片"
+                    android:textColor="#FF1A1A1A"
+                    android:textSize="12dp" />
+            </LinearLayout>
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="120dp"
+                android:layout_margin="15dp"
+                android:background="@drawable/round_corner_top_letf_right"
+                android:orientation="horizontal">
+
+                <ImageView
+                    android:id="@+id/image_add_iv"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginLeft="15dp"
+                    android:layout_marginTop="20dp"
+                    android:layout_marginRight="10dp"
+                    android:background="@drawable/icon_result_photo" />
+
+                <androidx.recyclerview.widget.RecyclerView
+                    android:id="@+id/image_recyclerView"
+                    android:layout_width="match_parent"
+                    android:layout_height="70dp"
+                    android:layout_marginTop="15dp"
+                    android:layout_marginRight="15dp"
+                    android:layout_marginBottom="15dp"
+                    android:overScrollMode="never"
+                    android:padding="3dp" />
+
+            </LinearLayout>
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="15dp"
+                android:orientation="horizontal">
+
+                <View
+
+                    android:layout_width="1.5dp"
+                    android:layout_height="15dp"
+                    android:layout_marginLeft="20dp"
+                    android:background="#FF005DFF"></View>
+
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_gravity="center_vertical"
+                    android:layout_marginLeft="5dp"
+                    android:text="上传视频"
+                    android:textColor="#FF1A1A1A"
+                    android:textSize="12dp" />
+            </LinearLayout>
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="120dp"
+                android:layout_margin="15dp"
+                android:background="@drawable/round_corner_top_letf_right"
+                android:orientation="horizontal">
+
+                <ImageView
+                    android:id="@+id/video_add"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginLeft="15dp"
+                    android:layout_marginTop="20dp"
+                    android:layout_marginRight="10dp"
+                    android:background="@drawable/icon_result_video" />
+
+                <androidx.recyclerview.widget.RecyclerView
+                    android:id="@+id/video_recyclerView"
+                    android:layout_width="match_parent"
+                    android:layout_height="70dp"
+                    android:layout_marginTop="15dp"
+                    android:layout_marginRight="15dp"
+                    android:layout_marginBottom="15dp"
+                    android:overScrollMode="never"
+                    android:padding="3dp" />
+
+            </LinearLayout>
+
+
+        </LinearLayout>
+
+        <TextView
+            android:id="@+id/submit"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_above="@+id/tv_tishi"
+            android:layout_marginLeft="48dp"
+            android:layout_marginRight="48dp"
+            android:layout_marginBottom="20dp"
+            android:background="@drawable/shape_fillet_bg_blue"
+            android:gravity="center"
+            android:paddingTop="10dp"
+            android:paddingBottom="10dp"
+            android:text="提交"
+            android:textColor="@color/color_white"
+            android:textSize="15dp" />
+
+        <TextView
+            android:id="@+id/tv_tishi"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_alignParentBottom="true"
+            android:layout_centerHorizontal="true"
+            android:layout_marginBottom="20dp"
+            android:gravity="bottom"
+            android:text="请上传现场情况图片/视频"
+            android:textColor="#8D8D8D"
+            android:textSize="14dp">
+
+        </TextView>
+    </RelativeLayout>
+</layout>

+ 30 - 20
app/src/main/res/layout/activity_exo.xml

@@ -1,23 +1,33 @@
 <?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="match_parent"
-    android:layout_height="match_parent"
-    xmlns:app="http://schemas.android.com/apk/res-auto"
-    android:orientation="vertical">
-    <com.sjkj.appthreefloor_tsgz.utils.MyVideoView
-        android:id="@+id/player_view"
+<layout xmlns:android="http://schemas.android.com/apk/res/android">
+
+    <data>
+
+        <variable
+            name="viewModel"
+            type="com.sjkj.appthreefloor_tsgz.activity.viewModel.PlayViewModel" />
+    </data>
+
+    <LinearLayout
         android:layout_width="match_parent"
-        android:layout_height="500dp"
-       />
-    <Button
-        android:id="@+id/btn_cut"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="one" />
+        android:layout_height="match_parent"
+        android:orientation="vertical">
+
+        <com.sjkj.appthreefloor_tsgz.utils.MyVideoView
+            android:id="@+id/player_view"
+            android:layout_width="match_parent"
+            android:layout_height="500dp" />
+
+        <Button
+            android:id="@+id/btn_cut"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:text="one" />
 
-    <Button
-        android:id="@+id/btn_cut2"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="two" />
-</LinearLayout>
+        <Button
+            android:id="@+id/btn_cut2"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:text="two" />
+    </LinearLayout>
+</layout>

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

@@ -9,6 +9,8 @@
     </data>
 
     <LinearLayout
+        android:fadeScrollbars="true"
+        android:fitsSystemWindows="true"
         android:layout_width="match_parent"
         android:layout_height="match_parent"
         android:background="@color/black"

+ 3 - 0
app/src/main/res/layout/activity_photo_view.xml

@@ -11,11 +11,14 @@
 
     <LinearLayout
         android:background="@color/white"
+        android:fadeScrollbars="true"
+        android:fitsSystemWindows="true"
         android:layout_width="match_parent"
         android:layout_height="match_parent"
         android:orientation="vertical">
 
         <RelativeLayout
+            android:visibility="gone"
             android:layout_marginTop="15dp"
             android:layout_width="match_parent"
             android:layout_height="45dp" >

+ 196 - 191
app/src/main/res/layout/activity_resure_details.xml

@@ -112,199 +112,204 @@
                         </TextView>
                     </LinearLayout>
                 </LinearLayout>
-
-                <RelativeLayout
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:layout_gravity="center_vertical"
-                    android:layout_marginLeft="15dp"
-                    android:layout_marginTop="10dp"
-                    android:layout_marginRight="15dp"
-                    android:background="@drawable/round_corner_top_letf_right"
-                    android:minHeight="44dp"
-                    android:orientation="horizontal">
-
-                    <TextView
-                        android:id="@+id/tv"
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_centerVertical="true"
-                        android:padding="10dp"
-
-                        android:text="地址:"
-                        android:textColor="@color/coler_evnet"
-                        android:textSize="12dp" />
-
-                    <TextView
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_alignParentRight="true"
-                        android:layout_centerVertical="true"
-                        android:layout_marginLeft="20dp"
-                        android:layout_marginRight="10dp"
-                        android:layout_toRightOf="@+id/tv"
-                        android:gravity="right"
-                        android:text='@{(TextUtils.isEmpty(viewModel.address)?"":viewModel.address)}'
-                        android:textColor="#181818"
-                        android:textSize="12dp" />
-                </RelativeLayout>
-
-                <RelativeLayout
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:layout_gravity="center_vertical"
-                    android:layout_marginLeft="15dp"
-                    android:layout_marginTop="10dp"
-                    android:layout_marginRight="15dp"
-                    android:background="@drawable/round_corner_top_letf_right"
-                    android:minHeight="44dp"
-                    android:orientation="horizontal">
-
-                    <TextView
-                        android:id="@+id/tv1"
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_centerVertical="true"
-                        android:padding="10dp"
-
-                        android:text="联系人:"
-                        android:textColor="@color/coler_evnet"
-                        android:textSize="12dp" />
-
-                    <TextView
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_alignParentRight="true"
-                        android:layout_centerVertical="true"
-                        android:layout_marginLeft="20dp"
-                        android:layout_marginRight="10dp"
-                        android:layout_toRightOf="@+id/tv1"
-                        android:gravity="right"
-                        android:text='@{(TextUtils.isEmpty(viewModel.contact)?"":viewModel.contact)}'
-                        android:textColor="#181818"
-                        android:textSize="12dp" />
-                </RelativeLayout>
-
-                <RelativeLayout
-                    android:id="@+id/rl_call"
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:layout_gravity="center_vertical"
-                    android:layout_marginLeft="15dp"
-                    android:layout_marginTop="10dp"
-                    android:layout_marginRight="15dp"
-                    android:background="@drawable/round_corner_top_letf_right"
-                    android:minHeight="44dp"
-                    android:orientation="horizontal">
-
-                    <TextView
-                        android:id="@+id/tv2"
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_centerVertical="true"
-                        android:padding="10dp"
-
-                        android:text="联系方式:"
-                        android:textColor="@color/coler_evnet"
-                        android:textSize="12dp" />
-
-                    <TextView
-                        android:id="@+id/tv_call"
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_centerVertical="true"
-                        android:layout_marginLeft="20dp"
-                        android:layout_marginRight="10dp"
-                        android:layout_toLeftOf="@+id/iv_call"
-                        android:layout_toRightOf="@+id/tv2"
-                        android:gravity="right"
-                        android:text='@{(TextUtils.isEmpty(viewModel.phone)?"":viewModel.phone)}'
-                        android:textColor="#181818"
-                        android:textSize="12dp" />
-
-                    <ImageView
-                        android:id="@+id/iv_call"
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_alignParentRight="true"
-                        android:layout_centerVertical="true"
-                        android:layout_marginRight="15dp"
-                        android:background="@drawable/icon_call" />
-                </RelativeLayout>
-
-                <RelativeLayout
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:layout_gravity="center_vertical"
-                    android:layout_marginLeft="15dp"
-                    android:layout_marginTop="10dp"
-                    android:layout_marginRight="15dp"
-                    android:background="@drawable/round_corner_top_letf_right"
-                    android:minHeight="44dp"
-                    android:orientation="horizontal">
-
-                    <TextView
-                        android:id="@+id/tv3"
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_centerVertical="true"
-                        android:padding="10dp"
-
-                        android:text="行政单位:"
-                        android:textColor="@color/coler_evnet"
-                        android:textSize="12dp" />
-
-                    <TextView
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_alignParentRight="true"
-                        android:layout_centerVertical="true"
-                        android:layout_marginLeft="20dp"
-                        android:layout_marginRight="10dp"
-                        android:layout_toRightOf="@+id/tv3"
-                        android:gravity="right"
-                        android:text='@{(TextUtils.isEmpty(viewModel.deptName)?"":viewModel.deptName)}'
-                        android:textColor="#181818"
-                        android:textSize="12dp" />
-
-
-                </RelativeLayout>
-
-                <RelativeLayout
+                <LinearLayout
+                    android:id="@+id/ll"
                     android:layout_width="match_parent"
                     android:layout_height="wrap_content"
-                    android:layout_gravity="center_vertical"
-                    android:layout_marginLeft="15dp"
-                    android:layout_marginTop="10dp"
-                    android:layout_marginRight="15dp"
-                    android:background="@drawable/round_corner_top_letf_right"
-                    android:minHeight="44dp"
-                    android:orientation="horizontal">
-
-                    <TextView
-                        android:id="@+id/tv4"
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_centerVertical="true"
-                        android:padding="10dp"
-
-                        android:text="行管单位:"
-                        android:textColor="@color/coler_evnet"
-                        android:textSize="12dp" />
-
-                    <TextView
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:layout_alignParentRight="true"
-                        android:layout_centerVertical="true"
-                        android:layout_marginLeft="20dp"
-                        android:layout_marginRight="10dp"
-                        android:layout_toRightOf="@+id/tv4"
-                        android:gravity="right"
-                        android:text='@{(TextUtils.isEmpty(viewModel.deptNameAdm)?"":viewModel.deptNameAdm)}'
-                        android:textColor="#181818"
-                        android:textSize="12dp" />
-                </RelativeLayout>
+                    android:orientation="vertical">
+                </LinearLayout>
+<!--                <RelativeLayout-->
+<!--                    android:layout_width="match_parent"-->
+<!--                    android:layout_height="wrap_content"-->
+<!--                    android:layout_gravity="center_vertical"-->
+<!--                    android:layout_marginLeft="15dp"-->
+<!--                    android:layout_marginTop="10dp"-->
+<!--                    android:layout_marginRight="15dp"-->
+<!--                    android:background="@drawable/round_corner_top_letf_right"-->
+<!--                    android:minHeight="44dp"-->
+<!--                    android:orientation="horizontal">-->
+
+<!--                    <TextView-->
+<!--                        android:id="@+id/tv"-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:padding="10dp"-->
+
+<!--                        android:text="地址:"-->
+<!--                        android:textColor="@color/coler_evnet"-->
+<!--                        android:textSize="12dp" />-->
+
+<!--                    <TextView-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_alignParentRight="true"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:layout_marginLeft="20dp"-->
+<!--                        android:layout_marginRight="10dp"-->
+<!--                        android:layout_toRightOf="@+id/tv"-->
+<!--                        android:gravity="right"-->
+<!--                        android:text='@{(TextUtils.isEmpty(viewModel.address)?"":viewModel.address)}'-->
+<!--                        android:textColor="#181818"-->
+<!--                        android:textSize="12dp" />-->
+<!--                </RelativeLayout>-->
+
+<!--                <RelativeLayout-->
+<!--                    android:layout_width="match_parent"-->
+<!--                    android:layout_height="wrap_content"-->
+<!--                    android:layout_gravity="center_vertical"-->
+<!--                    android:layout_marginLeft="15dp"-->
+<!--                    android:layout_marginTop="10dp"-->
+<!--                    android:layout_marginRight="15dp"-->
+<!--                    android:background="@drawable/round_corner_top_letf_right"-->
+<!--                    android:minHeight="44dp"-->
+<!--                    android:orientation="horizontal">-->
+
+<!--                    <TextView-->
+<!--                        android:id="@+id/tv1"-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:padding="10dp"-->
+
+<!--                        android:text="联系人:"-->
+<!--                        android:textColor="@color/coler_evnet"-->
+<!--                        android:textSize="12dp" />-->
+
+<!--                    <TextView-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_alignParentRight="true"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:layout_marginLeft="20dp"-->
+<!--                        android:layout_marginRight="10dp"-->
+<!--                        android:layout_toRightOf="@+id/tv1"-->
+<!--                        android:gravity="right"-->
+<!--                        android:text='@{(TextUtils.isEmpty(viewModel.contact)?"":viewModel.contact)}'-->
+<!--                        android:textColor="#181818"-->
+<!--                        android:textSize="12dp" />-->
+<!--                </RelativeLayout>-->
+
+<!--                <RelativeLayout-->
+<!--                    android:id="@+id/rl_call"-->
+<!--                    android:layout_width="match_parent"-->
+<!--                    android:layout_height="wrap_content"-->
+<!--                    android:layout_gravity="center_vertical"-->
+<!--                    android:layout_marginLeft="15dp"-->
+<!--                    android:layout_marginTop="10dp"-->
+<!--                    android:layout_marginRight="15dp"-->
+<!--                    android:background="@drawable/round_corner_top_letf_right"-->
+<!--                    android:minHeight="44dp"-->
+<!--                    android:orientation="horizontal">-->
+
+<!--                    <TextView-->
+<!--                        android:id="@+id/tv2"-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:padding="10dp"-->
+
+<!--                        android:text="联系方式:"-->
+<!--                        android:textColor="@color/coler_evnet"-->
+<!--                        android:textSize="12dp" />-->
+
+<!--                    <TextView-->
+<!--                        android:id="@+id/tv_call"-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:layout_marginLeft="20dp"-->
+<!--                        android:layout_marginRight="10dp"-->
+<!--                        android:layout_toLeftOf="@+id/iv_call"-->
+<!--                        android:layout_toRightOf="@+id/tv2"-->
+<!--                        android:gravity="right"-->
+<!--                        android:text='@{(TextUtils.isEmpty(viewModel.phone)?"":viewModel.phone)}'-->
+<!--                        android:textColor="#181818"-->
+<!--                        android:textSize="12dp" />-->
+
+<!--                    <ImageView-->
+<!--                        android:id="@+id/iv_call"-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_alignParentRight="true"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:layout_marginRight="15dp"-->
+<!--                        android:background="@drawable/icon_call" />-->
+<!--                </RelativeLayout>-->
+
+<!--                <RelativeLayout-->
+<!--                    android:layout_width="match_parent"-->
+<!--                    android:layout_height="wrap_content"-->
+<!--                    android:layout_gravity="center_vertical"-->
+<!--                    android:layout_marginLeft="15dp"-->
+<!--                    android:layout_marginTop="10dp"-->
+<!--                    android:layout_marginRight="15dp"-->
+<!--                    android:background="@drawable/round_corner_top_letf_right"-->
+<!--                    android:minHeight="44dp"-->
+<!--                    android:orientation="horizontal">-->
+
+<!--                    <TextView-->
+<!--                        android:id="@+id/tv3"-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:padding="10dp"-->
+
+<!--                        android:text="行政单位:"-->
+<!--                        android:textColor="@color/coler_evnet"-->
+<!--                        android:textSize="12dp" />-->
+
+<!--                    <TextView-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_alignParentRight="true"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:layout_marginLeft="20dp"-->
+<!--                        android:layout_marginRight="10dp"-->
+<!--                        android:layout_toRightOf="@+id/tv3"-->
+<!--                        android:gravity="right"-->
+<!--                        android:text='@{(TextUtils.isEmpty(viewModel.deptName)?"":viewModel.deptName)}'-->
+<!--                        android:textColor="#181818"-->
+<!--                        android:textSize="12dp" />-->
+
+
+<!--                </RelativeLayout>-->
+
+<!--                <RelativeLayout-->
+<!--                    android:layout_width="match_parent"-->
+<!--                    android:layout_height="wrap_content"-->
+<!--                    android:layout_gravity="center_vertical"-->
+<!--                    android:layout_marginLeft="15dp"-->
+<!--                    android:layout_marginTop="10dp"-->
+<!--                    android:layout_marginRight="15dp"-->
+<!--                    android:background="@drawable/round_corner_top_letf_right"-->
+<!--                    android:minHeight="44dp"-->
+<!--                    android:orientation="horizontal">-->
+
+<!--                    <TextView-->
+<!--                        android:id="@+id/tv4"-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:padding="10dp"-->
+
+<!--                        android:text="行管单位:"-->
+<!--                        android:textColor="@color/coler_evnet"-->
+<!--                        android:textSize="12dp" />-->
+
+<!--                    <TextView-->
+<!--                        android:layout_width="wrap_content"-->
+<!--                        android:layout_height="wrap_content"-->
+<!--                        android:layout_alignParentRight="true"-->
+<!--                        android:layout_centerVertical="true"-->
+<!--                        android:layout_marginLeft="20dp"-->
+<!--                        android:layout_marginRight="10dp"-->
+<!--                        android:layout_toRightOf="@+id/tv4"-->
+<!--                        android:gravity="right"-->
+<!--                        android:text='@{(TextUtils.isEmpty(viewModel.deptNameAdm)?"":viewModel.deptNameAdm)}'-->
+<!--                        android:textColor="#181818"-->
+<!--                        android:textSize="12dp" />-->
+<!--                </RelativeLayout>-->
 
 
                 <androidx.recyclerview.widget.RecyclerView

+ 23 - 3
app/src/main/res/layout/fragment_event_details.xml

@@ -80,7 +80,6 @@
                             android:id="@+id/tv_refuse"
                             android:layout_width="70dp"
                             android:layout_height="30dp"
-                            android:layout_marginRight="10dp"
                             android:background="@drawable/bg_event_refuse"
                             android:gravity="center_horizontal|center_vertical"
                             android:text="拒签"
@@ -91,15 +90,36 @@
 
                         <TextView
                             android:id="@+id/tv_finish"
+                            android:layout_marginLeft="10dp"
                             android:layout_width="70dp"
                             android:layout_height="30dp"
                             android:background="@drawable/bg_event_finish"
                             android:gravity="center_horizontal|center_vertical"
                             android:text="办结"
                             android:textColor="#EDAC00"
-                            android:visibility="gone">
+                            android:visibility="gone" />
 
-                        </TextView>
+                        <TextView
+                            android:id="@+id/tv_noNeed"
+                            android:layout_width="70dp"
+                            android:layout_height="30dp"
+                            android:layout_marginLeft="10dp"
+                            android:background="@drawable/bg_event_noneed"
+                            android:gravity="center_horizontal|center_vertical"
+                            android:text="无需处理"
+                            android:textColor="#366CFF"
+                            android:visibility="gone"></TextView>
+
+                        <TextView
+                            android:id="@+id/tv_report"
+                            android:layout_width="100dp"
+                            android:layout_height="30dp"
+                            android:layout_marginLeft="15dp"
+                            android:background="@drawable/bg_event_report"
+                            android:gravity="center_horizontal|center_vertical"
+                            android:text="上报应急事件"
+                            android:textColor="#FF5900"
+                            android:visibility="gone"></TextView>
 
                         <TextView
                             android:id="@+id/tv_time"

+ 74 - 3
app/src/main/res/layout/fragment_event_message.xml

@@ -25,15 +25,76 @@
             android:background="#ECEDF4">
 
             <androidx.recyclerview.widget.RecyclerView
-                android:layout_marginTop="15dp"
-                android:layout_marginBottom="15dp"
                 android:id="@+id/fk_recyclerView"
                 android:layout_width="match_parent"
                 android:layout_height="match_parent"
+                android:layout_marginTop="15dp"
+                android:layout_marginBottom="15dp"
                 android:overScrollMode="never"
                 android:padding="3dp" />
         </RelativeLayout>
 
+        <LinearLayout
+            android:id="@+id/ll_photo_video"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_above="@+id/rl_bootm"
+            android:background="@drawable/rounded_corners10"
+            android:orientation="vertical"
+            android:padding="15dp"
+            android:visibility="visible">
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:orientation="horizontal">
+
+                <LinearLayout
+                    android:id="@+id/ll_video"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_gravity="center_vertical"
+                    android:layout_marginLeft="15dp"
+                    android:orientation="vertical">
+
+                    <ImageView
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:background="@drawable/icon_camera_video" />
+
+
+                </LinearLayout>
+
+                <LinearLayout
+                    android:id="@+id/ll_photo"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_gravity="center_vertical"
+                    android:layout_marginLeft="20dp"
+                    android:orientation="vertical">
+
+                    <ImageView
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:background="@drawable/icon_camera_phot" />
+
+
+                </LinearLayout>
+
+            </LinearLayout>
+
+            <androidx.recyclerview.widget.RecyclerView
+                android:id="@+id/image_recyclerView"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginLeft="10dp"
+                android:layout_marginTop="10dp"
+                android:layout_marginRight="10dp"
+                android:overScrollMode="never"
+                android:padding="3dp" />
+
+        </LinearLayout>
+
         <RelativeLayout
             android:id="@+id/rl_bootm"
             android:layout_width="match_parent"
@@ -47,12 +108,22 @@
                 android:layout_height="40dp"
                 android:layout_centerVertical="true"
                 android:layout_marginLeft="15dp"
-                android:layout_toLeftOf="@+id/ic_send"
+                android:layout_toLeftOf="@+id/iv_photo"
                 android:background="@drawable/rounded_30"
                 android:hint="请输入内容"
                 android:paddingLeft="20dp" />
 
             <ImageView
+                android:id="@+id/iv_photo"
+                android:layout_width="35dp"
+                android:layout_height="35dp"
+                android:layout_centerVertical="true"
+                android:layout_marginLeft="15dp"
+                android:layout_marginRight="15dp"
+                android:layout_toLeftOf="@+id/ic_send"
+                android:background="@drawable/icon_photo" />
+
+            <ImageView
                 android:id="@+id/ic_send"
                 android:layout_width="35dp"
                 android:layout_height="35dp"

+ 4 - 4
app/src/main/res/layout/item_image_list.xml

@@ -11,13 +11,13 @@
 
     <RelativeLayout
         android:id="@+id/rl_image"
-        android:layout_width="65dp"
-        android:layout_height="65dp" >
+        android:layout_width="70dp"
+        android:layout_height="70dp" >
 
         <ImageView
             android:id="@+id/iv_icon"
-            android:layout_width="50dp"
-            android:layout_height="50dp"
+            android:layout_width="65dp"
+            android:layout_height="65dp"
             android:layout_centerInParent="true"
             android:layout_marginStart="5dp"
             android:layout_marginTop="5dp"

+ 51 - 0
app/src/main/res/layout/item_image_video_list.xml

@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layout xmlns:android="http://schemas.android.com/apk/res/android">
+
+    <data>
+
+        <variable
+            name="model"
+            type="com.sjkj.appthreefloor_tsgz.bean.ImageBean" />
+    </data>
+
+    <RelativeLayout
+        android:id="@+id/rl_image"
+        android:layout_width="65dp"
+        android:layout_height="65dp">
+
+        <ImageView
+            android:id="@+id/iv_icon"
+            android:layout_width="50dp"
+            android:layout_height="50dp"
+            android:layout_centerInParent="true"
+            android:layout_marginStart="5dp"
+            android:layout_marginTop="5dp"
+            android:layout_marginEnd="5dp"
+            android:layout_marginBottom="5dp"
+            android:scaleType="fitCenter" />
+
+        <ImageView
+            android:id="@+id/delete_iv"
+            android:layout_width="16dp"
+            android:layout_height="16dp"
+            android:layout_alignParentRight="true"
+            android:src="@drawable/icon_image_delete" />
+
+        <FrameLayout
+
+            android:id="@+id/fl_head"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_centerInParent="true"
+            android:layout_marginLeft="5dp"
+            android:layout_marginRight="5dp"
+            android:visibility="gone">
+
+            <ImageView
+                android:layout_width="20dp"
+                android:layout_height="20dp"
+                android:layout_gravity="center_vertical|center_horizontal"
+                android:background="@drawable/icon_scan" />
+        </FrameLayout>
+    </RelativeLayout>
+</layout>

+ 70 - 47
app/src/main/res/layout/item_message_details.xml

@@ -77,53 +77,76 @@
                 android:layout_height="wrap_content">
 
 
-            <TextView
-                android:layout_marginLeft="15dp"
-                android:layout_marginRight="15dp"
-
-                android:id="@+id/tv_name"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="10dp"
-                android:text="@{model.createName}"
-                android:textColor="#1A1A1A">
-
-            </TextView>
-
-            <TextView
-                android:id="@+id/tv_content"
-                android:layout_marginRight="15dp"
-                android:layout_marginLeft="15dp"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="10dp"
-                android:layout_marginBottom="10dp"
-                android:text="@{model.remark}"
-                android:textColor="#1A1A1A">
-
-            </TextView>
-
-            <androidx.recyclerview.widget.RecyclerView
-                android:id="@+id/recyclerView_image"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="5dp"
-                android:overScrollMode="never" />
-
-            <androidx.recyclerview.widget.RecyclerView
-                android:id="@+id/recyclerView_file"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="5dp"
-                android:overScrollMode="never" />
-
-            <androidx.recyclerview.widget.RecyclerView
-                android:id="@+id/recyclerView_video"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="5dp"
-                android:overScrollMode="never" />
-        </LinearLayout>
+                <LinearLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginLeft="15dp"
+                    android:layout_marginTop="10dp"
+                    android:orientation="horizontal">
+
+
+                    <TextView
+                        android:id="@+id/tv_name"
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_marginRight="15dp"
+                        android:text="@{model.createName}"
+                        android:textColor="#1A1A1A"
+                        android:textSize="18dp">
+
+                    </TextView>
+
+                    <TextView
+                        android:id="@+id/tv_deptname"
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+
+                        android:background="@drawable/shape_dept_bg_blue"
+                        android:paddingLeft="5dp"
+                        android:paddingTop="2dp"
+                        android:paddingRight="5dp"
+                        android:paddingBottom="2dp"
+                        android:text="@{model.deptName}"
+                        android:textColor="@color/white"
+                        android:textSize="12dp">
+
+                    </TextView>
+                </LinearLayout>
+
+                <TextView
+                    android:id="@+id/tv_content"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginLeft="15dp"
+                    android:layout_marginTop="10dp"
+                    android:layout_marginRight="15dp"
+                    android:layout_marginBottom="10dp"
+                    android:text="@{model.remark}"
+                    android:textColor="#1A1A1A">
+
+                </TextView>
+
+                <androidx.recyclerview.widget.RecyclerView
+                    android:id="@+id/recyclerView_image"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="5dp"
+                    android:overScrollMode="never" />
+
+                <androidx.recyclerview.widget.RecyclerView
+                    android:id="@+id/recyclerView_file"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="5dp"
+                    android:overScrollMode="never" />
+
+                <androidx.recyclerview.widget.RecyclerView
+                    android:id="@+id/recyclerView_video"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="5dp"
+                    android:overScrollMode="never" />
+            </LinearLayout>
         </LinearLayout>
     </LinearLayout>
 

+ 6 - 7
app/src/main/res/layout/item_video_del_list.xml

@@ -10,19 +10,18 @@
 
     <RelativeLayout
         android:id="@+id/rl_video"
-        android:layout_width="65dp"
-        android:layout_height="65dp">
+        android:layout_width="85dp"
+        android:layout_height="85dp">
 
         <ImageView
             android:id="@+id/iv_video"
-            android:layout_width="50dp"
-            android:layout_height="50dp"
+            android:layout_width="75dp"
+            android:layout_height="75dp"
             android:layout_centerInParent="true"
             android:layout_marginStart="5dp"
             android:layout_marginTop="5dp"
             android:layout_marginEnd="5dp"
-            android:layout_marginBottom="5dp"
-            android:background="@color/black" />
+            android:layout_marginBottom="5dp" />
 
         <ImageView
             android:id="@+id/delete_iv"
@@ -44,7 +43,7 @@
                 android:layout_width="20dp"
                 android:layout_height="20dp"
                 android:layout_gravity="center_vertical|center_horizontal"
-                android:background="@drawable/ic_san" />
+                android:background="@drawable/icon_scan" />
         </FrameLayout>
     </RelativeLayout>
 </layout>

+ 14 - 2
app/src/main/res/layout/player_activity.xml

@@ -21,9 +21,9 @@
 
             <com.google.android.exoplayer2.ui.PlayerView
                 android:id="@+id/player_view"
-                app:show_buffering="when_playing"
                 android:layout_width="match_parent"
-                android:layout_height="match_parent" />
+                android:layout_height="match_parent"
+                app:show_buffering="when_playing" />
 
             <Button
                 android:id="@+id/fullscreen_button"
@@ -33,6 +33,18 @@
                 android:layout_centerHorizontal="true"
                 android:text="全屏"
                 android:visibility="gone" />
+
+            <LinearLayout
+                android:layout_marginBottom="30dp"
+                android:id="@+id/ll"
+                android:layout_width="match_parent"
+                android:gravity="center_horizontal"
+                android:layout_height="wrap_content"
+                android:layout_alignParentBottom="true"
+                android:layout_centerHorizontal="true"
+                android:orientation="horizontal">
+
+            </LinearLayout>
         </RelativeLayout>
         <ImageView
             android:id="@+id/back"

+ 24 - 0
app/src/main/res/layout/view_exopayer_point.xml

@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:layout_gravity="center_horizontal"
+    android:gravity="center_horizontal"
+    android:orientation="horizontal">
+
+
+    <TextView
+        android:id="@+id/tv_title"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_centerVertical="true"
+        android:layout_gravity="center_horizontal"
+        android:layout_marginLeft="15dp"
+        android:background="@drawable/icon_camera_bg"
+        android:gravity="center_horizontal"
+        android:padding="15dp"
+        android:textColor="@color/white"
+        android:textSize="12dp" />
+
+
+</LinearLayout>

+ 51 - 0
app/src/main/res/layout/view_resource_point.xml

@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:orientation="horizontal">
+
+    <RelativeLayout
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_gravity="center_vertical"
+        android:layout_marginLeft="15dp"
+        android:layout_marginTop="10dp"
+        android:layout_marginRight="15dp"
+        android:background="@drawable/round_corner_top_letf_right"
+        android:minHeight="44dp"
+        android:orientation="horizontal">
+
+        <TextView
+            android:id="@+id/tv_name"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_centerVertical="true"
+            android:padding="10dp"
+            android:textColor="@color/coler_evnet"
+            android:textSize="12dp" />
+
+        <TextView
+            android:id="@+id/tv_content"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_centerVertical="true"
+            android:layout_marginLeft="20dp"
+            android:layout_marginRight="10dp"
+            android:layout_toLeftOf="@+id/iv_call"
+            android:layout_toRightOf="@+id/tv_name"
+            android:gravity="right"
+            android:textColor="#181818"
+            android:textSize="12dp" />
+
+        <ImageView
+            android:id="@+id/iv_call"
+
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_alignParentRight="true"
+            android:layout_centerVertical="true"
+            android:layout_marginRight="10dp"
+            android:background="@drawable/icon_call"
+            android:visibility="invisible" />
+    </RelativeLayout>
+</LinearLayout>

+ 2 - 2
app/src/main/res/values/colors.xml

@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8"?>
 <resources>
-    <color name="colorPrimary">#084AFF</color>
-    <color name="colorPrimaryDark">#084AFF</color>
+    <color name="colorPrimary">#ffffff</color>
+    <color name="colorPrimaryDark">#ffffff</color>
     <color name="colorAccent">#5394ff</color>
     <color name="color_input_red">#D81B60</color>
     <color name="green_color">#27be6d</color>

+ 14 - 4
base-lib/src/main/java/com/sjkj/base_lib/utils/AppTools.java

@@ -11,6 +11,7 @@ import android.util.Log;
 import android.view.KeyEvent;
 
 import androidx.appcompat.app.AlertDialog;
+import androidx.fragment.app.Fragment;
 
 import com.orhanobut.logger.AndroidLogAdapter;
 import com.orhanobut.logger.Logger;
@@ -475,13 +476,12 @@ public class AppTools {
     }
 
     public static String getBaseUrl() {
-        //return mmkv.decodeString("baseUrl", "http://192.168.4.82:8080/api/");
-        return mmkv.decodeString("baseUrl", "http://36.137.48.33:5520/api/");
+        return mmkv.decodeString("baseUrl", "http://192.168.4.82:8080/api/");
+        //return mmkv.decodeString("baseUrl", "http://36.137.48.33:5520/api/");
     }
 
     public static String getImageBaseUrl() {
-        // return mmkv.decodeString("baseUrl", "http://192.168.4.82:8080/api/");
-        return mmkv.decodeString("ImagebaseUrl", "http://36.137.48.33:5520");
+        return mmkv.decodeString("baseUrl", "http://192.168.4.26:80");
     }
 //    public static final String GATEWAY_URL = "sooka-mobile";
 //    public static final String GATEWAY_URL_SYSTEM = "system";
@@ -573,6 +573,16 @@ public class AppTools {
         }
     }
 
+    public static void chooseImageFragment(Fragment fragment) {
+        Matisse.from(fragment)
+                .choose(MimeType.ofImage())//图片类型
+                .countable(true)//true:选中后显示数字;false:选中后显示对号
+                .maxSelectable(1)//可选的最大数
+                .capture(true)//选择照片时,是否显示拍照
+                .captureStrategy(new CaptureStrategy(false, AppTools.getPackageNameProvider()))//参数1 true表示拍照存储在共有目录,false表示存储在私有目录;参数2与 AndroidManifest中authorities值相同,用于适配7.0系统 必须设置
+                .imageEngine(new GlideEngine())//图片加载引擎
+                .forResult(100);
+    }
 
     public static void chooseImage() {
 //        XXPermissions.with(AppManager.getAppManager().currentActivity())

二進制
base-lib/src/main/res/drawable-xxhdpi/icon_image_delete.png