| | |
| | | imgFiles: [], |
| | | |
| | | remark: '', |
| | | remarkDisable: false |
| | | remarkDisable: false, |
| | | |
| | | previewImageUrls:[], |
| | | previewCurrent: 0, |
| | | showPreview: false, |
| | | }, |
| | | |
| | | /** |
| | |
| | | ledger: data.ledger, |
| | | indexGroup: data.indexGroup |
| | | }) |
| | | if (data.barTitle) { |
| | | wx.setNavigationBarTitle({ |
| | | title: data.barTitle, |
| | | }) |
| | | } |
| | | |
| | | that.checkStatus() |
| | | }) |
| | |
| | | }, |
| | | |
| | | checkStatus() { |
| | | if (this.data.ledger.upLoad) { |
| | | if (this.data.ledger.path1) { |
| | | let imgFiles = this.data.ledger.path1 |
| | | let remark = this.data.ledger.remark1 == null ? '' : this.data.ledger.remark1 |
| | | let remarkDisable = true |
| | | this.setData({imgFiles, remark, remarkDisable}) |
| | | }else if (this.data.ledger.upLoad) { |
| | | var that = this |
| | | var userId = app.globalData.accessToken.userId |
| | | var typeId = this.data.ledger.ledgerSubTypeId |
| | |
| | | if (res.length > 0) { |
| | | let detail = res[0] |
| | | if (detail.upLoad) { |
| | | let imgFiles = detail.path1.split(';').map((value, index) => { |
| | | return $f.basePicUrl + value |
| | | }) |
| | | let imgFiles = detail.path1 |
| | | let remark = detail.remark1 == null ? '' : detail.remark1 |
| | | let remarkDisable = true |
| | | that.setData({imgFiles, remark, remarkDisable}) |
| | |
| | | complete (res) { |
| | | } |
| | | }) |
| | | } |
| | | }, |
| | | |
| | | previewImage(e) { |
| | | const { |
| | | index |
| | | } = e.currentTarget.dataset; |
| | | const previewImageUrls = this.data.imgFiles; |
| | | this.setData({ |
| | | previewImageUrls, |
| | | previewCurrent: index, |
| | | showPreview: true |
| | | }); |
| | | }, |
| | | }) |