| | |
| | | import com.dayu.pipirrapp.net.BaseResponse; |
| | | import com.dayu.pipirrapp.net.Constants; |
| | | import com.dayu.pipirrapp.net.subscribers.SubscriberListener; |
| | | import com.dayu.pipirrapp.tool.BigimageUtils; |
| | | import com.dayu.pipirrapp.tool.FullyGridLayoutManager; |
| | | import com.dayu.pipirrapp.utils.ToastUtil; |
| | | import com.dayu.pipirrapp.view.ConfirmDialog; |
| | |
| | | // 添加间距装饰,确保图片有合适的间隔 |
| | | mRecyclerView.addItemDecoration(new GridSpacingItemDecoration(4, DensityUtil.dip2px(this, 8), false)); |
| | | mAdapter = new ImageAdapter(this, images, (v, position) -> { |
| | | ImagePreview.getInstance().with(IssueDetailActivity.this).setIndex(position).setMediaInfoList(imageInfoList).start(); |
| | | BigimageUtils.showImages(this, position, imageInfoList); |
| | | }); |
| | | mRecyclerView.setAdapter(mAdapter); |
| | | } |
| | |
| | | binding.setData(orderDetailResult); |
| | | binding.setItemclidk(IssueDetailActivity.this); |
| | | state = orderDetailResult.getStateId(); |
| | | if (!t.getContent().getImages().isEmpty()){ |
| | | for (ImageResult imageResult:t.getContent().getImages()){ |
| | | ImageBean imageBean=new ImageBean(); |
| | | if (!t.getContent().getImages().isEmpty()) { |
| | | for (ImageResult imageResult : t.getContent().getImages()) { |
| | | ImageBean imageBean = new ImageBean(); |
| | | imageBean.setId(imageResult.getId()); |
| | | imageBean.setWebPath(imageResult.getWebPath()); |
| | | imageBean.setType(UplodFileState.IMG_TYPE); |
| | | images.add(imageBean); |
| | | ImageInfo info=new ImageInfo(); |
| | | ImageInfo info = new ImageInfo(); |
| | | info.setOriginUrl(imageResult.getWebPath()); |
| | | info.setType(Type.IMAGE); |
| | | imageInfoList.add(info); |
| | | } |
| | | } |
| | | if (!t.getContent().getVideos().isEmpty()){ |
| | | for (ImageResult imageResult:t.getContent().getVideos()){ |
| | | ImageBean imageBean=new ImageBean(); |
| | | if (!t.getContent().getVideos().isEmpty()) { |
| | | for (ImageResult imageResult : t.getContent().getVideos()) { |
| | | ImageBean imageBean = new ImageBean(); |
| | | imageBean.setId(imageResult.getId()); |
| | | imageBean.setWebPath(imageResult.getWebPath()); |
| | | imageBean.setType(UplodFileState.VIDEO_TYPE); |
| | | images.add(imageBean); |
| | | ImageInfo info=new ImageInfo(); |
| | | ImageInfo info = new ImageInfo(); |
| | | info.setOriginUrl(imageResult.getWebPath()); |
| | | info.setType(Type.VIDEO); |
| | | imageInfoList.add(info); |