上传证据,e证通sdk
This commit is contained in:
@@ -40,10 +40,10 @@
|
||||
<uni-easyinput :inputBorder="false" :disabled='true' v-model="formData.taskname"
|
||||
placeholder="" />
|
||||
</uni-forms-item>
|
||||
<uni-forms-item label="证据材料" name="headImage" required :disabled='true'>
|
||||
<uni-forms-item label="证据材料" name="evidenceMaterialList" required :disabled='true'>
|
||||
<!-- <img-upload :limit='3' :value.sync="formData.headImage" ></img-upload> -->
|
||||
<view class="imagearea">
|
||||
<image class="image" v-for="(item,index) in formData.headImage" :key="index" :src="formData.headImage[index].pics_small_url"
|
||||
<image class="image" v-for="(item,index) in formData.evidenceMaterialList" :key="index" :src="formData.evidenceMaterialList[index].annexPath"
|
||||
@click="getImgIndex(index)"></image>
|
||||
</view>
|
||||
</uni-forms-item>
|
||||
@@ -65,25 +65,22 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import ImgUpload from '@/components/imgUpload.vue'
|
||||
const app = getApp()
|
||||
import {respondentDetail} from '../../../api/handlecase/index.js'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
formData: {
|
||||
headImage: [{
|
||||
index: 1,
|
||||
pics_small_url: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg'
|
||||
},
|
||||
{
|
||||
index: 2,
|
||||
pics_small_url: 'https://img1.baidu.com/it/u=1310564963,1641173348&fm=253&fmt=auto&app=120&f=JPEG?w=1280&h=800'
|
||||
},
|
||||
{
|
||||
index: 3,
|
||||
pics_small_url: 'https://img1.baidu.com/it/u=1310564963,1641173348&fm=253&fmt=auto&app=120&f=JPEG?w=1280&h=800'
|
||||
},
|
||||
{
|
||||
index: 4,
|
||||
pics_small_url: 'https://img1.baidu.com/it/u=1310564963,1641173348&fm=253&fmt=auto&app=120&f=JPEG?w=1280&h=800'
|
||||
}
|
||||
]
|
||||
@@ -113,16 +110,21 @@
|
||||
arbitrationmethod(val) {
|
||||
console.log(val, "仲裁方式");
|
||||
},
|
||||
getData(parms){
|
||||
respondentDetail(parms).then(res=>{
|
||||
this.formData = res.data
|
||||
this.formData.loanEndDate = moment(this.formData.loanEndDate).format('YYYY-MM-DD HH:mm:ss');
|
||||
this.formData.loanStartDate = moment(this.formData.loanStartDate).format('YYYY-MM-DD HH:mm:ss');
|
||||
this.formData.evidenceMaterialList.forEach(item=>{
|
||||
item.annexPath = app.globalData.requestUrl + item.annexPath
|
||||
})
|
||||
})
|
||||
},
|
||||
getImgIndex(index) {
|
||||
// console.log(index);
|
||||
//准备一个装图片路径的 数组imgs
|
||||
let imgs = this.formData.headImage.map(item => {
|
||||
// console.log(item, 'item');
|
||||
//只返回图片路径
|
||||
return item.pics_small_url
|
||||
})
|
||||
// console.log(imgs);
|
||||
//调用预览图片的方法
|
||||
uni.previewImage({
|
||||
urls: imgs,
|
||||
current: index,
|
||||
@@ -130,6 +132,10 @@
|
||||
})
|
||||
},
|
||||
},
|
||||
onLoad(data){
|
||||
this.getData(data.id);
|
||||
// this.getArbitratorList()
|
||||
},
|
||||
components: {
|
||||
// 'img-upload': ImgUpload,
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user