冲突处理
This commit is contained in:
parent
4f260c5da3
commit
2ebfb6c9ef
|
|
@ -173,41 +173,6 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="protocol-handle" v-if="cardList.length > 0">
|
<div class="protocol-handle" v-if="cardList.length > 0">
|
||||||
<el-row style="margin: 15px 0">
|
|
||||||
<el-col :span="24">
|
|
||||||
<el-collapse v-model="activeNames">
|
|
||||||
<el-collapse-item :title="addressTitle" name="1">
|
|
||||||
<template v-if="addressList.length > 0">
|
|
||||||
<div
|
|
||||||
:key="index"
|
|
||||||
class="address-item"
|
|
||||||
@click="onSelectAddress(item.addressName)"
|
|
||||||
v-for="(item, index) in addressList"
|
|
||||||
>
|
|
||||||
{{ item.addressName }}
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<template v-else>
|
|
||||||
<div style="width: 100%; text-align: center; font-size: 14px">
|
|
||||||
当前没有收货地址...
|
|
||||||
<a
|
|
||||||
style="
|
|
||||||
color: #00a288;
|
|
||||||
cursor: pointer;
|
|
||||||
margin-left: 5px;
|
|
||||||
text-decoration: underline;
|
|
||||||
"
|
|
||||||
@click="onAddAddress"
|
|
||||||
>
|
|
||||||
点击新增
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
</el-collapse-item>
|
|
||||||
</el-collapse>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-row style="display: flex; align-items: center">
|
<el-row style="display: flex; align-items: center">
|
||||||
<el-col :span="16">
|
<el-col :span="16">
|
||||||
<div class="checkbox-container">
|
<div class="checkbox-container">
|
||||||
|
|
@ -288,7 +253,6 @@ import {
|
||||||
import moment, { max } from 'moment'
|
import moment, { max } from 'moment'
|
||||||
import { InfoFilled } from '@element-plus/icons-vue'
|
import { InfoFilled } from '@element-plus/icons-vue'
|
||||||
import CustomDatePickerButton from './components/date-picker-button.vue'
|
import CustomDatePickerButton from './components/date-picker-button.vue'
|
||||||
import { getAddressListApi } from 'http/api/address-manage/index'
|
|
||||||
import { useRoute, useRouter } from 'vue-router'
|
import { useRoute, useRouter } from 'vue-router'
|
||||||
import { useStore } from '../../store/user'
|
import { useStore } from '../../store/user'
|
||||||
import jsPreviewDocx from "@js-preview/docx";
|
import jsPreviewDocx from "@js-preview/docx";
|
||||||
|
|
@ -298,9 +262,6 @@ const router = useRouter()
|
||||||
const protocolChecked = ref<boolean>(false)
|
const protocolChecked = ref<boolean>(false)
|
||||||
const allKey = ref(0)
|
const allKey = ref(0)
|
||||||
const cardList = ref<any>([])
|
const cardList = ref<any>([])
|
||||||
const activeNames = ref('')
|
|
||||||
const addressTitle = ref('请选择收货地址')
|
|
||||||
const addressList = ref<any>([])
|
|
||||||
const getBookCarDetailsData = async () => {
|
const getBookCarDetailsData = async () => {
|
||||||
const res: any = await getBookCarDetailsApi()
|
const res: any = await getBookCarDetailsApi()
|
||||||
|
|
||||||
|
|
@ -475,14 +436,6 @@ const onCartSubmit = async () => {
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (addressTitle.value === '请选择收货地址') {
|
|
||||||
ElMessage({
|
|
||||||
showClose: false,
|
|
||||||
message: '请选择收货地址',
|
|
||||||
type: 'error',
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
let isDays = false
|
let isDays = false
|
||||||
try {
|
try {
|
||||||
|
|
@ -534,7 +487,6 @@ const onCartSubmit = async () => {
|
||||||
})
|
})
|
||||||
paramsList[index] = {
|
paramsList[index] = {
|
||||||
cost: 0,
|
cost: 0,
|
||||||
address: addressTitle.value.split(':')[1],
|
|
||||||
detailsList: itemsArray,
|
detailsList: itemsArray,
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
@ -570,31 +522,6 @@ const onCartSubmit = async () => {
|
||||||
// console.log(res, '预约车提交结果')
|
// console.log(res, '预约车提交结果')
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取收货地址
|
|
||||||
const getReceiptGoodsAddress = async () => {
|
|
||||||
const res: any = await getAddressListApi({})
|
|
||||||
addressList.value = res.rows.map((e: any) => {
|
|
||||||
return {
|
|
||||||
addressName: `${e.provinceName}${e.cityName}${e.areaName}${e.address}`,
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 选择收货地址
|
|
||||||
const onSelectAddress = (address: any) => {
|
|
||||||
addressTitle.value = '收货地址:' + address
|
|
||||||
activeNames.value = ''
|
|
||||||
}
|
|
||||||
// 去往地址管理
|
|
||||||
const onAddAddress = () => {
|
|
||||||
userStore.editcurrentMenuItem('address-manage')
|
|
||||||
setTimeout(() => {
|
|
||||||
router.push({
|
|
||||||
name: 'my-user',
|
|
||||||
})
|
|
||||||
}, 500)
|
|
||||||
}
|
|
||||||
|
|
||||||
getReceiptGoodsAddress()
|
|
||||||
const wordUrl = ref("")
|
const wordUrl = ref("")
|
||||||
const settleWordTitle = ref('')
|
const settleWordTitle = ref('')
|
||||||
const dialogFormVisibleSettleWord: any = ref(false)
|
const dialogFormVisibleSettleWord: any = ref(false)
|
||||||
|
|
@ -735,13 +662,4 @@ const handleViewWord = async() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.address-item {
|
|
||||||
margin: 0 auto;
|
|
||||||
padding: 6px 10px;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
.address-item:hover {
|
|
||||||
background-color: #c9e7e5;
|
|
||||||
}
|
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue