change
This commit is contained in:
@@ -19,10 +19,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="box2 buttons_wrapper">
|
<div class="box2 buttons_wrapper">
|
||||||
<button class="button_control" @click="toSure(selectObj.point_code, '3')"><p>{{ $t('carrypoint.button1') }}</p></button>
|
<!-- <button class="button_control" :class="{'button_control_disabled':returnObj}" @click="toSure(startObj, '3')"><p>{{ $t('carrypoint.button1') }}</p></button> -->
|
||||||
<button class="button_control" @click="toSure(selectObj.point_code, '4')"><p>{{ $t('carrypoint.button2') }}</p></button>
|
<button class="button_control" @click="toSure(startObj, '3')"><p>{{ $t('carrypoint.button1') }}</p></button>
|
||||||
|
<button class="button_control" @click="toSure(startObj, '4')"><p>{{ $t('carrypoint.button2') }}</p></button>
|
||||||
<button class="button_control" @click="showDialog('1')"><p>{{ $t('carrypoint.button3') }}</p></button>
|
<button class="button_control" @click="showDialog('1')"><p>{{ $t('carrypoint.button3') }}</p></button>
|
||||||
<!-- <button class="button_control" @click="toSure(selectObj.point_code, '1')"><p>{{ $t('carrypoint.button4') }}</p></button> -->
|
|
||||||
<!-- <button class="button_control" @click="showDialog('2')"><p>{{ $t('carrypoint.button4') }}</p></button> -->
|
<!-- <button class="button_control" @click="showDialog('2')"><p>{{ $t('carrypoint.button4') }}</p></button> -->
|
||||||
<button class="button_control" @click="toSure(startObj, '1', returnObj)"><p>{{ $t('carrypoint.button4') }}</p></button>
|
<button class="button_control" @click="toSure(startObj, '1', returnObj)"><p>{{ $t('carrypoint.button4') }}</p></button>
|
||||||
</div>
|
</div>
|
||||||
@@ -114,7 +114,6 @@ export default {
|
|||||||
preventClickEvent: false
|
preventClickEvent: false
|
||||||
},
|
},
|
||||||
statusbg: false,
|
statusbg: false,
|
||||||
pkId: '',
|
|
||||||
selectObj: {},
|
selectObj: {},
|
||||||
startObj: '', // 起始点
|
startObj: '', // 起始点
|
||||||
returnObj: '', // 返回点
|
returnObj: '', // 返回点
|
||||||
@@ -240,6 +239,8 @@ export default {
|
|||||||
this.$refs.child.active = true
|
this.$refs.child.active = true
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case '1':
|
case '1':
|
||||||
|
this.startObj = ''
|
||||||
|
this.returnObj = ''
|
||||||
this.pointcode = ''
|
this.pointcode = ''
|
||||||
this.returnsitecode = ''
|
this.returnsitecode = ''
|
||||||
this.unclick = true
|
this.unclick = true
|
||||||
@@ -258,7 +259,7 @@ export default {
|
|||||||
break
|
break
|
||||||
case '2':
|
case '2':
|
||||||
if (this.value) {
|
if (this.value) {
|
||||||
this.confirmPoint(this.pkId, '1', this.value)
|
this.confirmPoint(this.startObj, '1', this.value)
|
||||||
this.value = ''
|
this.value = ''
|
||||||
}
|
}
|
||||||
break
|
break
|
||||||
@@ -269,7 +270,7 @@ export default {
|
|||||||
case '1':
|
case '1':
|
||||||
break
|
break
|
||||||
case '2':
|
case '2':
|
||||||
this.confirmPoint(this.pkId, '1', '')
|
this.confirmPoint(this.startObj, '1', '')
|
||||||
this.value = ''
|
this.value = ''
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
@@ -314,32 +315,43 @@ export default {
|
|||||||
},
|
},
|
||||||
toRadio (e) {
|
toRadio (e) {
|
||||||
console.log('seletobj====', e)
|
console.log('seletobj====', e)
|
||||||
// this.pkId = this.pkId === e.point_code ? '' : e.point_code
|
|
||||||
this.selectObj = e
|
this.selectObj = e
|
||||||
// this.toast('终点已选中')
|
|
||||||
|
|
||||||
if (this.startObj && this.returnObj) {
|
if (this.startObj && this.returnObj) {
|
||||||
// 已选中情况下清空
|
// 已选中情况下清空
|
||||||
this.startObj = ''
|
this.startObj = ''
|
||||||
this.returnObj = ''
|
this.returnObj = ''
|
||||||
this.toast('已选点已清空')
|
// this.toast('已选点已清空')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (!this.startObj) {
|
if (!this.startObj) {
|
||||||
this.startObj = e.point_code
|
this.startObj = e.point_code
|
||||||
this.toast('终点已选中')
|
let tipText = this.$i18n.locale === 'en-us' ? 'End point selected' : '终点已选中'
|
||||||
|
this.toast(tipText)
|
||||||
|
// this.toast('终点已选中')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (this.startObj && !this.returnObj) {
|
if (this.startObj && !this.returnObj) {
|
||||||
this.returnObj = e.point_code
|
let tipText = this.$i18n.locale === 'en-us' ? 'End point selected' : '终点已选中'
|
||||||
this.toast('返回点已选中')
|
this.toast(tipText)
|
||||||
|
// this.toast('终点已选中')
|
||||||
|
if (this.startObj !== e.point_code) {
|
||||||
|
this.returnObj = e.point_code
|
||||||
|
let tipText = this.$i18n.locale === 'en-us' ? 'Return point selected' : '返回点已选中'
|
||||||
|
this.toast(tipText)
|
||||||
|
// this.toast('返回点已选中')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
toSure (pcode, type, ncode) {
|
toSure (pcode, type, ncode) {
|
||||||
this.confirmPoint(pcode, type, ncode)
|
if ((type === '3' || type === '4') && this.returnObj) {
|
||||||
},
|
return
|
||||||
toClear () {
|
}
|
||||||
this.selectObj = {}
|
if ((type === '3' || type === '4') && this.startObj) {
|
||||||
|
this.confirmPoint(pcode, type, ncode)
|
||||||
|
}
|
||||||
|
if (type === '1' && this.startObj) {
|
||||||
|
this.confirmPoint(pcode, type, ncode)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// handleMouseenter (e) {
|
// handleMouseenter (e) {
|
||||||
// console.log('ee', e)
|
// console.log('ee', e)
|
||||||
|
|||||||
Reference in New Issue
Block a user