文档服务地址:http://47.92.0.57:3000/ 周报索引地址:http://47.92.0.57:3000/s/NruNXRYmV

Commit ad3029de by 李梓桢

image

parent 13c7deaa
......@@ -32,6 +32,7 @@
<el-radio-button label="矩形标注"></el-radio-button>
<el-radio-button label="多边形标注"></el-radio-button>
</el-radio-group>
<el-button @click="save()">保存</el-button>
</div>
</div>
</el-aside>
......@@ -552,7 +553,7 @@ export default {
var children = this.data[this.pictureId].children
var tmp = this.canvasAll[id]
this.labelName = children[index].label
this.labelName = children[index].labelName
this.labelPosition = ''
var lenTmp = tmp[index].length / 2;
var i = 0;
......@@ -813,19 +814,20 @@ export default {
}
var self = this
let res = await this.axios({
method: 'get',
method: 'post',
url: '/image/getImage',
data: params
})
if (res.code === 1) {
let imageList = res.data
// console.log(imageList.imageList[0].imageUrl)
self.$store.commit('clearImageData')
self.$store.commit('setImageData', imageList.imageList)
console.log("!!!!!!!!!!!!!!!!")
console.log(this.$store.state.imageData)
}
} catch (err) {
this.$store.commit('clearImageData')
self.$store.commit('clearImageData')
console.log(err)
alert('请求出错!')
}
......@@ -853,14 +855,16 @@ export default {
confirmButtonText: '确定',
cancelButtonText: '取消'
}).then(({ value }) => {
if (value == null)
value = 'iss'
labelName = value
let currentImageId = this.pictureId
const newLabel = {label: labelName}
const newLabel = {labelName: labelName}
this.data[currentImageId].children.push(newLabel)
}).catch(() => {
labelName = 'iss'
let currentImageId = this.pictureId
const newLabel = {label: labelName}
const newLabel = {labelName: labelName}
this.data[currentImageId].children.push(newLabel)
})
},
......@@ -1004,12 +1008,17 @@ export default {
}
outputData.push(newData)
})
/**
* 这里还有问题,再添加标签时只有标签名
*/
console.log("outputdata")
console.log(outputData)
this.imageNum = this.data.len
this.axios({
method: 'post',
url: '/image',
url: '/image/saveImage',
data: {
outputData
imageList: outputData
}
}).then(res => {
console.log(res)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment