Commit e95d99c2 authored by Matěj Lang's avatar Matěj Lang
Browse files

'Approved image' flag is set when editing sticks.

parent ad600ed2
Loading
Loading
Loading
Loading
+19 −8
Original line number Original line Diff line number Diff line
@@ -313,6 +313,18 @@ export default {
      this.$selectorTop.attr('cursor', 'grab')
      this.$selectorTop.attr('cursor', 'grab')
      this.$selectorMiddle.attr('cursor', 'grab')
      this.$selectorMiddle.attr('cursor', 'grab')
      this.$selectorBottom.attr('cursor', 'grab')
      this.$selectorBottom.attr('cursor', 'grab')

      this.$store.dispatch('setFlagStickCorrectedByUser', {
        cameraID: this.cameraID,
        imageName: this.imageName,
        stickID: this.stickID,
        flagState: true
      })
      this.$store.dispatch('setFlagImageApprovedByUser', {
        cameraID: this.cameraID,
        imageName: this.imageName,
        flagState: true
      })
    },
    },
    dragTop(event) {
    dragTop(event) {
      const x = this.pointTop.x + event.dx
      const x = this.pointTop.x + event.dx
@@ -372,14 +384,8 @@ export default {
    revertChangeToSticks() {
    revertChangeToSticks() {
      this.pointTop = this.backup.top
      this.pointTop = this.backup.top
      this.pointBottom = this.backup.bottom
      this.pointBottom = this.backup.bottom
      this.snowHeight = this.backup.snowHeight


      this.$store.dispatch('setStickSnowHeight', {
        cameraID: this.cameraID,
        imageName: this.imageName,
        stickID: this.stickID,
        snowHeight: this.backup.snowHeight,
        sendDataToServer: false
      })
      this.$store.dispatch('setFlagStickCorrectedByUser', {
      this.$store.dispatch('setFlagStickCorrectedByUser', {
        cameraID: this.cameraID,
        cameraID: this.cameraID,
        imageName: this.imageName,
        imageName: this.imageName,
@@ -439,7 +445,12 @@ export default {
      })
      })


    this.$snowMarker
    this.$snowMarker
      .call(d3.drag().on('drag', this.dragMarker))
      .call(
        d3
          .drag()
          .on('drag', this.dragMarker)
          .on('end', this.dragEnded)
      )
      .on('mouseover', () => {
      .on('mouseover', () => {
        this.$snowMarker.classed('select-full', true)
        this.$snowMarker.classed('select-full', true)
      })
      })