Skip to content

Commit

Permalink
Better group edit
Browse files Browse the repository at this point in the history
  • Loading branch information
Portree-Kid committed Aug 8, 2020
1 parent 54fc153 commit 63e08ca
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion src/renderer/components/ParkingGroupEdit.vue
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
<el-col :span="7">
<span class="label">Heading :</span>
</el-col>
<el-col :span="17">
<el-col :span="13">
<el-input-number
v-model="avgHeading" @change="headingChange"
:min="-361"
Expand All @@ -84,6 +84,11 @@
:disabled="!editing"
></el-input-number>
</el-col>
<el-col :span="4">
<el-button @click="rotate" class="button">
<i class="fas fa-ruler-combined"></i>
</el-button>
</el-col>
</el-row>
<!--
<el-row>
Expand Down Expand Up @@ -136,6 +141,16 @@ const convert = require('geo-coordinates-parser');
},
methods: {
rotate() {
this.avgHeading = this.avgHeading + 90;
while (this.avgHeading>=360) {
this.avgHeading -= 360
}
while (this.avgHeading<0) {
this.avgHeading += 360
}
this.headingChange(this.avgHeading);
},
show (idx) {
this.$parent.$parent.$parent.$refs.editLayer.show(idx)
},
Expand Down

0 comments on commit 63e08ca

Please sign in to comment.