Commit b6a9069810ed41433837e04d35153337fb4c2b64
1 parent
b51f185e
优化图片方大问题
Showing
2 changed files
with
8 additions
and
14 deletions
src/components/system/viewImage.vue
| @@ -3,7 +3,7 @@ | @@ -3,7 +3,7 @@ | ||
| 3 | <el-dialog | 3 | <el-dialog |
| 4 | :visible.sync="visible" | 4 | :visible.sync="visible" |
| 5 | :fullscreen="true" | 5 | :fullscreen="true" |
| 6 | - :show-close="false" | 6 | + :show-close="true" |
| 7 | custom-class="image-viewer-dialog" | 7 | custom-class="image-viewer-dialog" |
| 8 | > | 8 | > |
| 9 | <div class="image-wrapper"> | 9 | <div class="image-wrapper"> |
src/views/room/listPropertyRightRegistrationDetailList.vue
| @@ -30,7 +30,7 @@ | @@ -30,7 +30,7 @@ | ||
| 30 | <template slot-scope="scope"> | 30 | <template slot-scope="scope"> |
| 31 | <div v-if="scope.row.securities === '001'"> | 31 | <div v-if="scope.row.securities === '001'"> |
| 32 | <div v-for="(item, index) in scope.row.idCardUrlShow" :key="index" class="image-container" | 32 | <div v-for="(item, index) in scope.row.idCardUrlShow" :key="index" class="image-container" |
| 33 | - @click="showImg(item)"> | 33 | + > |
| 34 | <el-image :src="item" :preview-src-list="scope.row.idCardUrlShow" fit="cover" | 34 | <el-image :src="item" :preview-src-list="scope.row.idCardUrlShow" fit="cover" |
| 35 | style="width: 50px; height: 50px"> | 35 | style="width: 50px; height: 50px"> |
| 36 | <div slot="error" class="image-slot"> | 36 | <div slot="error" class="image-slot"> |
| @@ -42,9 +42,9 @@ | @@ -42,9 +42,9 @@ | ||
| 42 | </div> | 42 | </div> |
| 43 | <div v-else-if="scope.row.securities === '002'"> | 43 | <div v-else-if="scope.row.securities === '002'"> |
| 44 | <div v-for="(item, index) in scope.row.housePurchaseUrlShow" :key="index" class="image-container" | 44 | <div v-for="(item, index) in scope.row.housePurchaseUrlShow" :key="index" class="image-container" |
| 45 | - @click="showImg(item)"> | 45 | + > |
| 46 | <el-image :src="item" :preview-src-list="scope.row.housePurchaseUrlShow" fit="cover" | 46 | <el-image :src="item" :preview-src-list="scope.row.housePurchaseUrlShow" fit="cover" |
| 47 | - style="width: 50px; height: 50px"> | 47 | + style="width: 50px; height: 50px" > |
| 48 | <div slot="error" class="image-slot"> | 48 | <div slot="error" class="image-slot"> |
| 49 | <img src="/img/noPhoto.jpg" style="width: 50px; height: 50px"> | 49 | <img src="/img/noPhoto.jpg" style="width: 50px; height: 50px"> |
| 50 | </div> | 50 | </div> |
| @@ -54,9 +54,9 @@ | @@ -54,9 +54,9 @@ | ||
| 54 | </div> | 54 | </div> |
| 55 | <div v-else-if="scope.row.securities === '003'"> | 55 | <div v-else-if="scope.row.securities === '003'"> |
| 56 | <div v-for="(item, index) in scope.row.repairUrlShow" :key="index" class="image-container" | 56 | <div v-for="(item, index) in scope.row.repairUrlShow" :key="index" class="image-container" |
| 57 | - @click="showImg(item)"> | 57 | + > |
| 58 | <el-image :src="item" :preview-src-list="scope.row.repairUrlShow" fit="cover" | 58 | <el-image :src="item" :preview-src-list="scope.row.repairUrlShow" fit="cover" |
| 59 | - style="width: 50px; height: 50px"> | 59 | + style="width: 50px; height: 50px" > |
| 60 | <div slot="error" class="image-slot"> | 60 | <div slot="error" class="image-slot"> |
| 61 | <img src="/img/noPhoto.jpg" style="width: 50px; height: 50px"> | 61 | <img src="/img/noPhoto.jpg" style="width: 50px; height: 50px"> |
| 62 | </div> | 62 | </div> |
| @@ -66,9 +66,9 @@ | @@ -66,9 +66,9 @@ | ||
| 66 | </div> | 66 | </div> |
| 67 | <div v-else-if="scope.row.securities === '004'"> | 67 | <div v-else-if="scope.row.securities === '004'"> |
| 68 | <div v-for="(item, index) in scope.row.deedTaxUrlShow" :key="index" class="image-container" | 68 | <div v-for="(item, index) in scope.row.deedTaxUrlShow" :key="index" class="image-container" |
| 69 | - @click="showImg(item)"> | 69 | + > |
| 70 | <el-image :src="item" :preview-src-list="scope.row.deedTaxUrlShow" fit="cover" | 70 | <el-image :src="item" :preview-src-list="scope.row.deedTaxUrlShow" fit="cover" |
| 71 | - style="width: 50px; height: 50px"> | 71 | + style="width: 50px; height: 50px" > |
| 72 | <div slot="error" class="image-slot"> | 72 | <div slot="error" class="image-slot"> |
| 73 | <img src="/img/noPhoto.jpg" style="width: 50px; height: 50px"> | 73 | <img src="/img/noPhoto.jpg" style="width: 50px; height: 50px"> |
| 74 | </div> | 74 | </div> |
| @@ -94,7 +94,6 @@ | @@ -94,7 +94,6 @@ | ||
| 94 | </el-card> | 94 | </el-card> |
| 95 | 95 | ||
| 96 | <edit-property-right-registration-detail ref="editPropertyRightRegistrationDetail" @success="handleSuccess" /> | 96 | <edit-property-right-registration-detail ref="editPropertyRightRegistrationDetail" @success="handleSuccess" /> |
| 97 | - <view-image ref="viewImage" /> | ||
| 98 | </div> | 97 | </div> |
| 99 | </template> | 98 | </template> |
| 100 | 99 | ||
| @@ -102,13 +101,11 @@ | @@ -102,13 +101,11 @@ | ||
| 102 | import { listPropertyRightRegistrationDetail } from '@/api/room/listPropertyRightRegistrationDetailApi' | 101 | import { listPropertyRightRegistrationDetail } from '@/api/room/listPropertyRightRegistrationDetailApi' |
| 103 | import { getCommunityId } from '@/api/community/communityApi' | 102 | import { getCommunityId } from '@/api/community/communityApi' |
| 104 | import EditPropertyRightRegistrationDetail from '@/components/room/editPropertyRightRegistrationDetail' | 103 | import EditPropertyRightRegistrationDetail from '@/components/room/editPropertyRightRegistrationDetail' |
| 105 | -import ViewImage from '@/components/system/viewImage' | ||
| 106 | 104 | ||
| 107 | export default { | 105 | export default { |
| 108 | name: 'ListPropertyRightRegistrationDetail', | 106 | name: 'ListPropertyRightRegistrationDetail', |
| 109 | components: { | 107 | components: { |
| 110 | EditPropertyRightRegistrationDetail, | 108 | EditPropertyRightRegistrationDetail, |
| 111 | - ViewImage | ||
| 112 | }, | 109 | }, |
| 113 | data() { | 110 | data() { |
| 114 | return { | 111 | return { |
| @@ -187,9 +184,6 @@ export default { | @@ -187,9 +184,6 @@ export default { | ||
| 187 | _openEditPropertyRightRegistrationDetailModel(row) { | 184 | _openEditPropertyRightRegistrationDetailModel(row) { |
| 188 | this.$refs.editPropertyRightRegistrationDetail.open(row) | 185 | this.$refs.editPropertyRightRegistrationDetail.open(row) |
| 189 | }, | 186 | }, |
| 190 | - showImg(url) { | ||
| 191 | - this.$refs.viewImage.open(url) | ||
| 192 | - }, | ||
| 193 | _goBack() { | 187 | _goBack() { |
| 194 | this.$router.go(-1) | 188 | this.$router.go(-1) |
| 195 | }, | 189 | }, |