| | |
| | | drag |
| | | action="https://jsonplaceholder.typicode.com/posts/" |
| | | :http-request="definedUpload" |
| | | accept=".jpg" |
| | | :on-change="onChange" |
| | | :show-file-list="false" |
| | | > |
| | |
| | | this.traceY = e.offsetY; |
| | | }, |
| | | onChange (file, fileList) { |
| | | if (file.raw.type == "image/jpeg") { |
| | | fileList = [file] |
| | | this.isShowCurPos = false; |
| | | } |
| | | |
| | | }, |
| | | definedUpload (params) { |
| | | let _this = this; |
| | |
| | | let param = new FormData(); |
| | | param.append('file', params.file) |
| | | putPanoramaPic(param).then(res=>{ |
| | | _this.panoramaPath = res.data.panoramaPath+'?'+Math.random() |
| | | console.log(_this.panoramaPath) |
| | | _this.panoramaPath = res.data.panoramaPath + '?' + Math.random(); |
| | | _this.$parent.$refs['tracePlot'] && _this.$parent.$refs['tracePlot'].getPanorama(); |
| | | }) |
| | | // let fileReader = new FileReader() |
| | | // fileReader.onload = () => { |