2.3.2 版本发布
parent
11d4919201
commit
dc1edb8495
@ -0,0 +1,64 @@
|
|||||||
|
package com.rehome.zhdcoa.adapter;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.graphics.Color;
|
||||||
|
import android.text.Html;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
|
import androidx.annotation.NonNull;
|
||||||
|
|
||||||
|
import com.rehome.zhdcoa.base.BaseViewBindingAdapter;
|
||||||
|
import com.rehome.zhdcoa.bean.WorkRiskLevelListBean;
|
||||||
|
import com.rehome.zhdcoa.bean.WorkRiskListReportBean;
|
||||||
|
import com.rehome.zhdcoa.databinding.AdapterWorkRiskLevelListBinding;
|
||||||
|
import com.rehome.zhdcoa.databinding.AdapterWorkRiskListReportBinding;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class WorkRiskListReportAdapter extends BaseViewBindingAdapter<AdapterWorkRiskListReportBinding> {
|
||||||
|
|
||||||
|
private final Context context;
|
||||||
|
private List<WorkRiskListReportBean.WorkRiskListReportDataListBean> datas;
|
||||||
|
|
||||||
|
public WorkRiskListReportAdapter(Context context, List<WorkRiskListReportBean.WorkRiskListReportDataListBean> datas) {
|
||||||
|
super(context);
|
||||||
|
this.context = context;
|
||||||
|
this.datas = datas;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void handleData(int position, @NonNull AdapterWorkRiskListReportBinding binding) {
|
||||||
|
WorkRiskListReportBean.WorkRiskListReportDataListBean item = datas.get(position);
|
||||||
|
if (item != null) {
|
||||||
|
binding.tvHbr.setText(item.getReporterName());
|
||||||
|
binding.tvHbbm.setText(item.getReporterDepartment());
|
||||||
|
binding.tvHbsj.setText(item.getReportTime());
|
||||||
|
binding.tvLevel.setText(item.getLevel());
|
||||||
|
binding.tvHbnr.setText(item.getContent());
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected AdapterWorkRiskListReportBinding getBinding(@NonNull LayoutInflater inflater, ViewGroup parent) {
|
||||||
|
return AdapterWorkRiskListReportBinding.inflate(inflater, parent, false);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getCount() {
|
||||||
|
return datas.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Object getItem(int position) {
|
||||||
|
return datas.get(position);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public long getItemId(int position) {
|
||||||
|
return Long.valueOf(position);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,181 @@
|
|||||||
|
package com.rehome.zhdcoa.bean;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class WorkRiskListReportBean extends AIRiskListBaseBean{
|
||||||
|
|
||||||
|
private RowsBean data;
|
||||||
|
|
||||||
|
public RowsBean getData() {
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setData(RowsBean data) {
|
||||||
|
this.data = data;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class RowsBean {
|
||||||
|
|
||||||
|
//id
|
||||||
|
private int pageNo;
|
||||||
|
//id
|
||||||
|
private int pageSize;
|
||||||
|
//id
|
||||||
|
private int totalRow;
|
||||||
|
//id
|
||||||
|
private int totalPage;
|
||||||
|
|
||||||
|
private List<WorkRiskListReportDataListBean> dataList;
|
||||||
|
|
||||||
|
public int getPageNo() {
|
||||||
|
return pageNo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPageNo(int pageNo) {
|
||||||
|
this.pageNo = pageNo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getPageSize() {
|
||||||
|
return pageSize;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPageSize(int pageSize) {
|
||||||
|
this.pageSize = pageSize;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getTotalRow() {
|
||||||
|
return totalRow;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTotalRow(int totalRow) {
|
||||||
|
this.totalRow = totalRow;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getTotalPage() {
|
||||||
|
return totalPage;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTotalPage(int totalPage) {
|
||||||
|
this.totalPage = totalPage;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<WorkRiskListReportDataListBean> getDataList() {
|
||||||
|
return dataList;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDataList(List<WorkRiskListReportDataListBean> dataList) {
|
||||||
|
this.dataList = dataList;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class WorkRiskListReportDataListBean {
|
||||||
|
//id
|
||||||
|
private int id;
|
||||||
|
//工作票id
|
||||||
|
private int ticketId;
|
||||||
|
//报告人工号
|
||||||
|
private String reporterNo;
|
||||||
|
private String reporterName;
|
||||||
|
private String reporterDepartment;
|
||||||
|
private String reportTime;
|
||||||
|
private String content;
|
||||||
|
private String level;
|
||||||
|
|
||||||
|
private List<AttachmentListBean> attachmentList;
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getTicketId() {
|
||||||
|
return ticketId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTicketId(int ticketId) {
|
||||||
|
this.ticketId = ticketId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getReporterNo() {
|
||||||
|
return reporterNo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setReporterNo(String reporterNo) {
|
||||||
|
this.reporterNo = reporterNo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getReporterName() {
|
||||||
|
return reporterName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setReporterName(String reporterName) {
|
||||||
|
this.reporterName = reporterName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getReporterDepartment() {
|
||||||
|
return reporterDepartment;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setReporterDepartment(String reporterDepartment) {
|
||||||
|
this.reporterDepartment = reporterDepartment;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getReportTime() {
|
||||||
|
return reportTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setReportTime(String reportTime) {
|
||||||
|
this.reportTime = reportTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getContent() {
|
||||||
|
return content;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setContent(String content) {
|
||||||
|
this.content = content;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLevel() {
|
||||||
|
return level;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setLevel(String level) {
|
||||||
|
this.level = level;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<AttachmentListBean> getAttachmentList() {
|
||||||
|
return attachmentList;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setAttachmentList(List<AttachmentListBean> attachmentList) {
|
||||||
|
this.attachmentList = attachmentList;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class AttachmentListBean {
|
||||||
|
//id
|
||||||
|
private int id;
|
||||||
|
//图片地址
|
||||||
|
private String url;
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getUrl() {
|
||||||
|
return url;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setUrl(String url) {
|
||||||
|
this.url = url;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,149 @@
|
|||||||
|
package com.rehome.zhdcoa.ui.activity;
|
||||||
|
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.content.pm.ApplicationInfo;
|
||||||
|
import android.graphics.Bitmap;
|
||||||
|
import android.graphics.BitmapFactory;
|
||||||
|
import android.graphics.drawable.BitmapDrawable;
|
||||||
|
import android.graphics.drawable.Drawable;
|
||||||
|
import android.os.Bundle;
|
||||||
|
import androidx.annotation.Nullable;
|
||||||
|
import androidx.appcompat.app.AppCompatActivity;
|
||||||
|
import android.text.TextUtils;
|
||||||
|
import android.util.Log;
|
||||||
|
import android.view.WindowManager;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.Toast;
|
||||||
|
import com.rehome.zhdcoa.Contans;
|
||||||
|
import com.rehome.zhdcoa.R;
|
||||||
|
import com.rehome.zhdcoa.utils.NohttpUtils;
|
||||||
|
import com.yolanda.nohttp.NoHttp;
|
||||||
|
import com.yolanda.nohttp.rest.CacheMode;
|
||||||
|
import com.yolanda.nohttp.rest.OnResponseListener;
|
||||||
|
import com.yolanda.nohttp.rest.Request;
|
||||||
|
import com.yolanda.nohttp.rest.RequestQueue;
|
||||||
|
import com.yolanda.nohttp.rest.Response;
|
||||||
|
import javax.net.ssl.HostnameVerifier;
|
||||||
|
import javax.net.ssl.SSLSession;
|
||||||
|
import javax.net.ssl.SSLSocketFactory;
|
||||||
|
|
||||||
|
|
||||||
|
public class PhotoRiskViewActivity extends AppCompatActivity {
|
||||||
|
|
||||||
|
private ImageView iv;
|
||||||
|
private RequestQueue queue;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onCreate(@Nullable Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
queue = NoHttp.newRequestQueue(1);
|
||||||
|
//设置全屏
|
||||||
|
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN);
|
||||||
|
setContentView(R.layout.activity_photo_risk_view);
|
||||||
|
initView();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void initView() {
|
||||||
|
setTitle(getIntent().getExtras().getString("fileName"));
|
||||||
|
iv = findViewById(R.id.iv);
|
||||||
|
String path = getIntent().getExtras().getString("path");
|
||||||
|
String imageUrl = getIntent().getExtras().getString("url");
|
||||||
|
showLog(path);
|
||||||
|
showLog(imageUrl);
|
||||||
|
|
||||||
|
|
||||||
|
Request<Bitmap> request = NoHttp.createImageRequest(imageUrl);
|
||||||
|
//request.setCacheMode(CacheMode.ONLY_REQUEST_NETWORK);
|
||||||
|
request.setCacheMode(CacheMode.NONE_CACHE_REQUEST_NETWORK);
|
||||||
|
|
||||||
|
if(Contans.BASE_URL_AI_3D_SERVER.equals(Contans.BASE_URL_AI_3D_SERVER_EXTRANET)){
|
||||||
|
SSLSocketFactory socketFactory = NohttpUtils.getSSLSocketFactory(this);
|
||||||
|
if (socketFactory != null) {
|
||||||
|
request.setSSLSocketFactory(socketFactory);
|
||||||
|
request.setHostnameVerifier(new HostnameVerifier() {
|
||||||
|
@Override
|
||||||
|
public boolean verify(String s, SSLSession sslSession) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
queue.add(3, request, new OnResponseListener<>() {
|
||||||
|
@Override
|
||||||
|
public void onStart(int what) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onSucceed(int what, Response<Bitmap> response) {
|
||||||
|
Bitmap bitmap = response.get();
|
||||||
|
Drawable drawable = new BitmapDrawable(getResources(), bitmap);
|
||||||
|
iv.setImageDrawable(drawable);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onFailed(int what, Response<Bitmap> response) {
|
||||||
|
Bitmap bitmap = BitmapFactory.decodeResource(getResources(), R.drawable.head_photo);
|
||||||
|
Drawable drawable = new BitmapDrawable(getResources(), bitmap);
|
||||||
|
iv.setImageDrawable(drawable);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onFinish(int what) {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// if (!TextUtils.isEmpty(url)) {
|
||||||
|
// Glide.with(PhotoRiskViewActivity.this)
|
||||||
|
// .load(url)
|
||||||
|
// .dontAnimate()
|
||||||
|
// .skipMemoryCache(true)
|
||||||
|
// .diskCacheStrategy(DiskCacheStrategy.NONE)
|
||||||
|
// .placeholder(R.drawable.head_photo)
|
||||||
|
// .into(iv);
|
||||||
|
// } else {
|
||||||
|
// if (!TextUtils.isEmpty(path)) {
|
||||||
|
// Bitmap bitmap = BitmapFactory.decodeFile(path);
|
||||||
|
// iv.setImageBitmap(bitmap);
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
|
||||||
|
public Drawable bitmapToDrawable(Bitmap bitmap) {
|
||||||
|
return new BitmapDrawable(getResources(), bitmap);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void showLog(String logText) {
|
||||||
|
if (isApkInDebug(this)) {
|
||||||
|
if(TextUtils.isEmpty(logText)){
|
||||||
|
Log.i("app", "logText is null");
|
||||||
|
}else{
|
||||||
|
Log.i("app", logText);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 判断当前应用是否是debug状态
|
||||||
|
*/
|
||||||
|
|
||||||
|
public static boolean isApkInDebug(Context context) {
|
||||||
|
try {
|
||||||
|
ApplicationInfo info = context.getApplicationInfo();
|
||||||
|
return (info.flags & ApplicationInfo.FLAG_DEBUGGABLE) != 0;
|
||||||
|
} catch (Exception e) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void showToast(String msg) {
|
||||||
|
Toast.makeText(this, msg, Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,109 @@
|
|||||||
|
package com.rehome.zhdcoa.ui.activity
|
||||||
|
|
||||||
|
import android.content.Context
|
||||||
|
import android.content.Intent
|
||||||
|
import android.os.Looper
|
||||||
|
import android.text.TextUtils
|
||||||
|
import android.view.View
|
||||||
|
import androidx.recyclerview.widget.GridLayoutManager
|
||||||
|
import com.bumptech.glide.Glide
|
||||||
|
import com.luck.picture.lib.decoration.GridSpacingItemDecoration
|
||||||
|
import com.luck.picture.lib.utils.DensityUtil
|
||||||
|
import com.rehome.zhdcoa.Contans
|
||||||
|
import com.rehome.zhdcoa.adapter.WorkRiskListReportAttachmentAdapter
|
||||||
|
import com.rehome.zhdcoa.base.BaseActivityOaToolbarViewBinding
|
||||||
|
import com.rehome.zhdcoa.bean.WorkRiskListReportBean
|
||||||
|
import com.rehome.zhdcoa.bean.WorkRiskListReportBean.AttachmentListBean
|
||||||
|
import com.rehome.zhdcoa.databinding.ActivityWorkRiskListHuiBaoDetailBinding
|
||||||
|
import com.rehome.zhdcoa.utils.FullyGridLayoutManager
|
||||||
|
import com.rehome.zhdcoa.utils.GsonUtils
|
||||||
|
|
||||||
|
class WorkRiskListHuiBaoDetailActivity : BaseActivityOaToolbarViewBinding<ActivityWorkRiskListHuiBaoDetailBinding>() {
|
||||||
|
|
||||||
|
private lateinit var item: WorkRiskListReportBean.WorkRiskListReportDataListBean
|
||||||
|
|
||||||
|
private lateinit var mAdapter: WorkRiskListReportAttachmentAdapter
|
||||||
|
|
||||||
|
private var datas: MutableList<WorkRiskListReportBean.AttachmentListBean> = mutableListOf()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
override fun getViewBinding() = ActivityWorkRiskListHuiBaoDetailBinding.inflate(layoutInflater)
|
||||||
|
|
||||||
|
override fun getToolbar() = binding.toolbarView.toolbar
|
||||||
|
|
||||||
|
override fun initView() {
|
||||||
|
initToolbar("每日工作报告详情")
|
||||||
|
setLeftOnClickListener {
|
||||||
|
finish()
|
||||||
|
}
|
||||||
|
|
||||||
|
var itemStr = intent.getStringExtra("item")!!
|
||||||
|
item = GsonUtils.GsonToBean(itemStr,WorkRiskListReportBean.WorkRiskListReportDataListBean::class.java)
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun initData() {
|
||||||
|
binding.tvHbr.text = item.reporterName
|
||||||
|
binding.tvHbbm.text = item.reporterDepartment
|
||||||
|
binding.tvHbsj.text = item.reportTime
|
||||||
|
binding.tvLevel.text = item.level
|
||||||
|
binding.etMs.setText(item.content)
|
||||||
|
|
||||||
|
//WorkRiskListReportAttachmentAdapter
|
||||||
|
|
||||||
|
clearImageDiskCache(this)
|
||||||
|
|
||||||
|
val manager: FullyGridLayoutManager = FullyGridLayoutManager(
|
||||||
|
this,
|
||||||
|
4, GridLayoutManager.VERTICAL, false
|
||||||
|
)
|
||||||
|
binding.recycle.setLayoutManager(manager)
|
||||||
|
binding.recycle.addItemDecoration(
|
||||||
|
GridSpacingItemDecoration(
|
||||||
|
4,
|
||||||
|
DensityUtil.dip2px(this, 8f), false
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
if(item.attachmentList!=null&&item.attachmentList.size>0){
|
||||||
|
binding.llPhoto.visibility= View.VISIBLE
|
||||||
|
datas.addAll(item.attachmentList)
|
||||||
|
}else{
|
||||||
|
binding.llPhoto.visibility= View.GONE
|
||||||
|
}
|
||||||
|
|
||||||
|
mAdapter = WorkRiskListReportAttachmentAdapter(this, datas)
|
||||||
|
binding.recycle.setAdapter(mAdapter)
|
||||||
|
|
||||||
|
mAdapter.setOnItemClickListener { v, position ->
|
||||||
|
val item: AttachmentListBean = item.attachmentList[position]
|
||||||
|
val st = Intent(context, PhotoRiskViewActivity::class.java)
|
||||||
|
if (!TextUtils.isEmpty(item.url)) {
|
||||||
|
var fullPath = Contans.BASE_URL_AI_3D_SERVER + "sc_v1" + item.url
|
||||||
|
st.putExtra("url", fullPath)
|
||||||
|
}
|
||||||
|
st.putExtra("fileName", "图片预览")
|
||||||
|
st.putExtra("path", "/")
|
||||||
|
startActivity(st)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 清除图片磁盘缓存
|
||||||
|
*/
|
||||||
|
private fun clearImageDiskCache(context: Context?) {
|
||||||
|
try {
|
||||||
|
if (Looper.myLooper() == Looper.getMainLooper()) {
|
||||||
|
Thread { Glide.get(context!!).clearDiskCache() }.start()
|
||||||
|
} else {
|
||||||
|
Glide.get(context!!).clearDiskCache()
|
||||||
|
}
|
||||||
|
} catch (e: Exception) {
|
||||||
|
e.printStackTrace()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,17 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:background="#000000"
|
||||||
|
android:orientation="vertical"
|
||||||
|
tools:context=".ui.activity.PhotoRiskViewActivity">>
|
||||||
|
|
||||||
|
<!--<include layout="@layout/toolbar"></include>-->
|
||||||
|
|
||||||
|
<uk.co.senab.photoview.PhotoView
|
||||||
|
android:id="@+id/iv"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent" />
|
||||||
|
</LinearLayout>
|
||||||
@ -0,0 +1,224 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:id="@+id/activity_sqxgdlr3"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
tools:context=".ui.activity.WorkRiskListHuiBaoDetailActivity">
|
||||||
|
|
||||||
|
<include
|
||||||
|
android:id="@+id/toolbarView"
|
||||||
|
layout="@layout/layout_base" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:orientation="vertical"
|
||||||
|
tools:ignore="UselessParent">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical"
|
||||||
|
tools:ignore="UselessParent">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/dagerDetailLeftStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="汇报人:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_hbr"
|
||||||
|
style="@style/dagerDetailRightStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
</LinearLayout>
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/dagerDetailLeftStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="部门:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_hbbm"
|
||||||
|
style="@style/dagerDetailRightStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/dagerDetailLeftStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="风险等级:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_level"
|
||||||
|
style="@style/dagerDetailRightStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
</LinearLayout>
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/dagerDetailLeftStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textSize="12sp"
|
||||||
|
android:text="汇报时间:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_hbsj"
|
||||||
|
style="@style/dagerDetailRightStyle"
|
||||||
|
android:textSize="12sp"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical">
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center_horizontal"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="10dp"
|
||||||
|
android:layout_marginEnd="10dp"
|
||||||
|
android:gravity="center|left">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_xydj"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:gravity="right|center_vertical"
|
||||||
|
android:textSize="18sp"
|
||||||
|
android:text="汇报内容:" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="300px"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:gravity="center">
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/et_ms"
|
||||||
|
style="@style/editTextTheme"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="300px"
|
||||||
|
android:gravity="top|left"
|
||||||
|
android:enabled="false"
|
||||||
|
android:inputType="textMultiLine"
|
||||||
|
android:textSize="18sp" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/ll_photo"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:minHeight="90dp"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:background="@drawable/radius"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/cb_crop"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:visibility="gone"
|
||||||
|
android:text="是否裁剪图片"
|
||||||
|
android:textColor="#53575e"
|
||||||
|
android:textSize="14sp" />
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/cb_compress"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:visibility="gone"
|
||||||
|
android:checked="true"
|
||||||
|
android:text="是否压缩图片"
|
||||||
|
android:textColor="#53575e"
|
||||||
|
android:textSize="14sp" />
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/cb_editor"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:checked="true"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:text="是否开启图片编辑"
|
||||||
|
android:visibility="gone"
|
||||||
|
android:textColor="#53575e"
|
||||||
|
android:textSize="14sp" />
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/recycle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="8dp"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
android:overScrollMode="never" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
@ -0,0 +1,142 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:id="@+id/ll"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:background="#dddddd"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:orientation="vertical"
|
||||||
|
tools:ignore="UselessParent">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical"
|
||||||
|
tools:ignore="UselessParent">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/dagerDetailLeftStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="汇报人:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_hbr"
|
||||||
|
style="@style/dagerDetailRightStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
</LinearLayout>
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/dagerDetailLeftStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="部门:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_hbbm"
|
||||||
|
style="@style/dagerDetailRightStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/dagerDetailLeftStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="风险等级:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_level"
|
||||||
|
style="@style/dagerDetailRightStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
</LinearLayout>
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/dagerDetailLeftStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textSize="12sp"
|
||||||
|
android:text="汇报时间:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_hbsj"
|
||||||
|
style="@style/dagerDetailRightStyle"
|
||||||
|
android:textSize="12sp"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
<LinearLayout
|
||||||
|
style="@style/dagerListMarginTopStyle"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/dagerDetailLeftStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:text="汇报内容:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_hbnr"
|
||||||
|
style="@style/dagerDetailRightStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content" />
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
@ -0,0 +1,13 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<com.luck.picture.lib.widget.SquareRelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/fiv"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
tools:src="@color/app_color_f6" />
|
||||||
|
|
||||||
|
</com.luck.picture.lib.widget.SquareRelativeLayout>
|
||||||
@ -0,0 +1,46 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<com.zhy.autolayout.AutoLinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:background="@drawable/dialog_radius"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/lay_dialog_title"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:visibility="visible">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/dialog_title"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:gravity="center"
|
||||||
|
android:paddingLeft="10dp"
|
||||||
|
android:paddingRight="10dp"
|
||||||
|
android:paddingTop="10dp"
|
||||||
|
android:text="时间"
|
||||||
|
android:textColor="#000000"
|
||||||
|
android:textSize="40px"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<DatePicker
|
||||||
|
android:id="@+id/datePicker"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:calendarViewShown="false"
|
||||||
|
android:datePickerMode="spinner" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<include layout="@layout/layout_dialog_bottom" />
|
||||||
|
|
||||||
|
</com.zhy.autolayout.AutoLinearLayout>
|
||||||
Loading…
Reference in New Issue