| | |
| | | <el-icon><Plus /></el-icon> |
| | | <template #file="{ file }"> |
| | | <div> |
| | | <img |
| | | <el-image |
| | | class="el-upload-list__item-thumbnail" |
| | | :src="file.url" |
| | | fit="cover" |
| | | alt="" |
| | | /> |
| | | <span class="el-upload-list__item-actions"> |
| | |
| | | <template #tip> |
| | | <div class="el-upload__tip"> |
| | | {{ |
| | | `请选择小于500kb的jpg/png图片,最多${maxImageCount}张` |
| | | `请选择小于5MB的jpg/png图片,最多${maxImageCount}张` |
| | | }} |
| | | </div> |
| | | </template> |
| | |
| | | <MapSearch |
| | | v-model:show="mapDialogShow" |
| | | :defaultCoor=" |
| | | formObj.coordinate |
| | | ? formObj.coordinate.split(',') |
| | | : undefined |
| | | formObj.coordinate ? formObj.coordinate.split(',') : undefined |
| | | " |
| | | @on-submit="selectAddress" |
| | | ></MapSearch> |
| | |
| | | import clueQuestionApi from '@/api/clue/clueQuestionApi'; |
| | | import { $clue } from '@/api/index'; |
| | | import MapSearch from '@/components/map/MapSearch.vue'; |
| | | |
| | | // 图片限定大小(单位:B) |
| | | const IMG_MAX_SIZE = 4 * 1024 * 1024; |
| | | |
| | | // 决定当前是否是内部线索相关操作 |
| | | const isInternal = inject('isInternal', false); |
| | |
| | | } |
| | | |
| | | function handleFileChange(file, files) { |
| | | fileList.value = files; |
| | | // console.log('fileSelect', file); |
| | | // 判断 |
| | | if (file.size > IMG_MAX_SIZE) { |
| | | const index = files.indexOf(file); |
| | | files.splice(index, 1); |
| | | ElMessage({ |
| | | message: '图片大小超过限制', |
| | | type: 'error' |
| | | }); |
| | | } else { |
| | | fileList.value = files; |
| | | } |
| | | edit.value = true; |
| | | } |
| | | |