| | |
| | | }) |
| | | } |
| | | |
| | | function getfilesApi(param) { |
| | | return $$.request({ |
| | | url: 'fileInfo/listByMainIdAndType', |
| | | type: 'get', |
| | | submitData: param || {}, |
| | | service: 'sys' |
| | | }) |
| | | } |
| | | |
| | | |
| | | |
| | | Page({ |
| | | |
| | | /** |
| | |
| | | */ |
| | | data: { |
| | | imgUrl: $$.url.img, |
| | | fileUrl: $$.baseUrl + $$.url.fileShowUrl, |
| | | search: { |
| | | page: 1, |
| | | size: 10, |
| | |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | // 关闭协议要点 |
| | | agreeContentClosePopup(e) { |
| | | this.setData({ |
| | | showData: { |
| | |
| | | }) |
| | | }, |
| | | |
| | | // 查看协议文书 |
| | | async agreeClick(e) { |
| | | let item = e.currentTarget.dataset.item; |
| | | $$.showLoading(); |
| | | |
| | | const res = await getfilesApi({ |
| | | mainId: item.id, |
| | | ownerType: '22_00018-302', |
| | | }); |
| | | $$.hideLoading(); |
| | | if (res.type) { |
| | | let data = res.data || []; |
| | | if (data?.length === 0) { |
| | | $$.showToast({ |
| | | title: '暂无协议文书', |
| | | duration: 1000 |
| | | }); |
| | | } |
| | | wx.previewImage({ |
| | | current: `${this.data.fileUrl}${data[0].showUrl}`, |
| | | urls: data.map(item => `${this.data.fileUrl}${item.showUrl}`) // 需要预览的图片http链接列表 |
| | | }); |
| | | } |
| | | }, |
| | | |
| | | // 评价 |
| | | evaluate(e) { |
| | | let id = e.currentTarget.dataset.id; |