77 Commits

Author SHA1 Message Date
dee9cd779a 二手拖车,进入详情页调保存信息记录接口,注释打印代码 2025-07-03 17:56:57 +08:00
0b0749f04a 二手拖车,进入详情页调保存信息记录接口,获取id,关闭页面,id传入接口 2025-07-03 17:56:34 +08:00
61da53bfe0 二手拖车,进入详情页调保存信息记录接口,获取id,关闭页面,id传入接口 2025-07-03 17:56:32 +08:00
d1d246d871 二手拖车,进入详情页调保存信息记录接口,获取id,关闭页面,id传入接口 2025-07-03 17:56:30 +08:00
ee8fdb16c4 task#6524 添加刷新按钮 2025-06-20 11:44:51 +08:00
7ff13628b5 task#6524 滚动测试 2025-06-20 10:36:02 +08:00
eae60d1000 task#6524 修改地址 2025-06-20 10:20:57 +08:00
3a1e4a6ae2 task#6524 滚动问题 2025-06-20 10:19:45 +08:00
5bd9db3165 task#6524 颜色兼容 2025-06-20 10:10:21 +08:00
fbce498e94 task#6524 头部颜色兼容 2025-06-20 09:49:18 +08:00
6ab2e0b1d7 task#6524 头部兼容 2025-06-20 09:41:40 +08:00
001683f215 task#6524 下拉刷新 2025-06-19 20:32:16 +08:00
bb13a6e34e task#6524 获取定位城市,时间默认当前 2025-06-19 19:55:32 +08:00
16d4425e07 task#6524 有订单才访问 2025-06-19 18:00:36 +08:00
a73434fd4d task#6524 textarea修改 2025-06-18 14:15:02 +08:00
75d20beb77 task#6524 http兼容司机app 2025-06-18 13:42:10 +08:00
9a21834741 task#6524 报备防重复点击 2025-06-18 11:09:51 +08:00
749daae26e task#6524 报备 2025-06-12 10:27:59 +08:00
0fc0d33742 story#6606,二手拖车系统优化,浏览单位加人 2025-06-09 09:32:13 +08:00
d1efe578d4 story#6606,二手拖车系统优化 2025-06-09 08:59:34 +08:00
899ea612f4 task#5914 添加报备页面,地图页面 2025-06-06 09:38:55 +08:00
5552b48ec4 story#6462,二手车,下架状态不展示想要按钮 2025-05-22 19:26:23 +08:00
56e56c7839 story#6462,筛选项问题 2025-05-22 11:55:08 +08:00
851a0e7260 story#6462,二手拖车信息需求 2025-05-22 11:43:06 +08:00
d2f124e901 story#6462,二手拖车信息需求 2025-05-22 10:58:35 +08:00
8bc734273b story#6462,二手拖车信息需求 2025-05-22 10:58:04 +08:00
643ee2c5eb story#6462,发布省市和日期去除clearable属性 2025-05-21 14:32:39 +08:00
881ae7e47b story#6462,发布日期清除事件和图标 2025-05-21 14:27:14 +08:00
d5af7692f8 story#6462,自定义清除事件和图标 2025-05-21 14:21:34 +08:00
aa52bd2f31 story#6462,自定义清除事件和图标 2025-05-21 14:17:35 +08:00
9df87ac518 story#6462,阻止输入框默认行为 2025-05-21 14:10:45 +08:00
8e20adbba3 story#6462,阻止输入框默认行为 2025-05-21 14:02:32 +08:00
cc083b7551 story#6462,阻止输入框默认行为 2025-05-21 14:00:04 +08:00
0a668e6f57 story#6462,阻止输入框默认行为 2025-05-21 13:55:09 +08:00
c2cc09aef1 story#6462,省市选择弹出框不要× 2025-05-21 13:48:33 +08:00
037fbf74fb story#6462,筛选输入框设置只读 2025-05-21 13:18:00 +08:00
de252fceb2 story#6462,列表添加发布省市和发布时间筛选项 2025-05-21 10:55:16 +08:00
6a53749cdc 样式调整 2025-05-08 14:07:38 +08:00
d71e3679ef 添加展示测试 2025-05-08 13:41:38 +08:00
c626aab606 添加展示 2025-05-08 13:06:42 +08:00
7594e56cda story#5360,web端拨打电话的确定事件弹框消失 2025-04-21 09:34:47 +08:00
95c8095518 story#5314 图片变形 2025-04-17 14:06:45 +08:00
0aa3630adb story#5360,web端拨打电话改为确定 2025-04-16 16:48:38 +08:00
75eba22e9e story#5360,将所有露出的“二手车”字样,全部改为“二手拖车”字样 2025-04-16 16:42:30 +08:00
a162c3fdcc story#5314 底部图片修改 2025-04-14 09:26:58 +08:00
33f4857427 story#5314 banner图样式3 2025-04-11 18:51:42 +08:00
432f35a403 story#5314 banner图样式2 2025-04-11 18:45:05 +08:00
ae0bd3b169 story#5314 banner图样式 2025-04-11 18:39:37 +08:00
6b27859358 二手车交易,刷新函数添加调列表接口 2025-04-11 13:51:52 +08:00
99edd5d431 story#5314 二手车系统优化需求 2025-04-11 11:01:47 +08:00
9ac5860ef8 story#5314 二手车系统优化需求 2025-04-11 10:52:57 +08:00
e56de7ff8b story#5314 二手车系统的优化需求 2025-04-11 09:28:56 +08:00
4a70d881b8 story#5256 供应商整改界面完善20250327 2025-04-09 16:26:27 +08:00
5de1efc5fb story#5314 二手车系统的优化需求 需要UI和接口的修改 2025-04-07 16:07:02 +08:00
7b7e926f8a story#5314 照片显示比例失调的问题需要优化 2025-04-02 13:23:18 +08:00
ba1cd9fcac story#5314 含税价格--> 售价(含税) 2025-04-02 11:42:03 +08:00
3fe67c1015 story#5314 在查看车源列表的界面,鼠标在移动到可以点击的区域时,改成手指的样式。 2025-04-02 11:00:19 +08:00
cdc63e6c42 story#5314 h5端 点击车源查看详情的照片,无法再点击放大,需要改成可以点击查看大图 2025-04-02 10:56:30 +08:00
0e138e22f4 story#5314 web端 点击车源查看详情的照片,无法再点击放大,需要改成可以点击查看大图2 2025-04-02 10:46:55 +08:00
b5c5f24c49 story#5314 web端 点击车源查看详情的照片,无法再点击放大,需要改成可以点击查看大图。 2025-04-02 10:43:13 +08:00
d3d6226bcd story#5314 点击车源查看详情的照片:一是要改成照片自动滚动播放,二是左右切换照片的按钮改为更明显的样式,三是照片张数显示改为更明显的样式,目前的按钮不醒目 2 2025-04-02 10:38:55 +08:00
a426b67a51 story#5314 点击车源查看详情的照片:一是要改成照片自动滚动播放,二是左右切换照片的按钮改为更明显的样式,三是照片张数显示改为更明显的样式,目前的按钮不醒目 2025-04-02 10:31:53 +08:00
efe76bb675 story#5314 二、名称优化,含税价格,点击车源查看详情的照片部分优化 2025-04-02 10:24:08 +08:00
de9d73a642 二手车交易,发布列表的navBar自定义 2025-03-25 14:54:19 +08:00
044813f411 二手车交易,售价输入0开头时,后边不允许输入任何数字 2025-03-25 14:15:57 +08:00
b90b7ea89c 二手车交易,发布时,求购可以输入0,但不允许输入多个0 2025-03-25 13:16:06 +08:00
4c02dcd075 二手车交易,求购发布样式优化 2025-03-25 11:38:30 +08:00
3cd768b973 二手车交易,排放标准添加国三选项 2025-03-25 11:05:02 +08:00
db6a3facae 二手车交易,行驶公里保留一位小数 2025-03-19 18:00:01 +08:00
48ab0cfb52 二手车交易,后台点击弹框关闭时记录浏览量 2025-03-19 10:14:13 +08:00
c5176ebc02 二手车交易,测试记录浏览量1 2025-03-19 09:48:27 +08:00
f666d9bcb4 二手车交易,测试记录浏览量 2025-03-19 09:23:17 +08:00
6864a1330f 二手车交易,记录浏览量 2025-03-19 09:08:34 +08:00
e373acb818 二手车交易,用户离开记录浏览量 2025-03-18 21:22:33 +08:00
fe71adf6e3 二手车交易,用户离开记录浏览量 2025-03-18 21:21:00 +08:00
b6d0ae476c 二手车交易,用户离开记录浏览量 2025-03-18 20:58:50 +08:00
c80a2f6e6b 二手车交易,行驶公里换行显示 2025-03-18 20:53:01 +08:00
40 changed files with 1479 additions and 115 deletions

View File

@ -26,10 +26,11 @@
<van-number-keyboard safe-area-inset-bottom />
<script type="text/javascript">
window._AMapSecurityConfig = {
serviceHost: 'https://api.sinoassist.com/_AMapService',
// serviceHost: 'https://api.sinoassist.com/_AMapService',
securityJsCode:'91ab1ebc492d5479a68b11527bd73dc9',
}
</script>
<script src="https://webapi.amap.com/maps?v=1.4.15&key=2560bbf04daef66c810c5e6a97e8c508&plugin=AMap.Polyline"></script>
<script type="text/javascript" src="https://webapi.amap.com/maps?v=2.0&key=2560bbf04daef66c810c5e6a97e8c508&plugin=AMap.AutoComplete,AMap.PlaceSearch,AMap.Geolocation,AMap.Geocoder,AMap.Marker,AMap.Driving"></script>
<!-- <script src="https://unpkg.com/vconsole@latest/dist/vconsole.min.js"></script>-->
<script>
// VConsole 默认会挂载到 `window.VConsole` 上

View File

@ -44,10 +44,10 @@
<body>
<div class="container">
<h3>声明</h3>
<p>本平台为二手车买卖双方提供免费信息发布服务。在您使用本平台之前,请仔细阅读并理解本免责声明。一旦使用本平台,即视为您已阅读、理解并同意接受本免责声明的所有条款。</p>
<p>本平台为二手车买卖双方提供免费信息发布服务。在您使用本平台之前,请仔细阅读并理解本免责声明。一旦使用本平台,即视为您已阅读、理解并同意接受本免责声明的所有条款。</p>
<h4>一、平台性质</h4>
<p>1. 本平台仅为信息发布平台,不参与任何二手车交易环节,包括但不限于交易洽谈、合同签订、款项支付、车辆交付等,实际交易价格由买卖双方自行协商确定。</p>
<p>1. 本平台仅为信息发布平台,不参与任何二手车交易环节,包括但不限于交易洽谈、合同签订、款项支付、车辆交付等,实际交易价格由买卖双方自行协商确定。</p>
<p>2. 本平台不对发布信息的真实性、准确性、完整性、合法性进行任何形式的担保或保证,用户应自行判断信息的真实性并承担由此产生的风险。</p>
<h4>二、用户责任</h4>

37
src/api/report.js Normal file
View File

@ -0,0 +1,37 @@
import request from '@/utils/http'
// 根据订单 获取报备类型
export function getReportListByOrder(key){
return request({
url: '/order/baseDriverReportConfigs/getByOrderId',
method:'GET',
params: key
})
}
// 添加报备
export function newOrderReporting(data){
return request({
url: '/supplierAppV2/dispatchApp/order/newOrderReporting',
method:'POST',
contentType: 'application/json',
data
})
}
// 获取报备列表
export function reportHistory(data){
return request({
url: '/supplierAppV2/dispatchApp/order/reportHistory',
method:'POST',
data
})
}
// 获取订单信息
export function getOrderInfo(data){
return request({
url: '/supplierAppV2/dispatchApp/order/reportOrderDetail',
method:'POST',
data
})
}

View File

@ -54,14 +54,14 @@ export function userFeedback(data){
data
})
}
//二手车信息擦亮
//二手车信息擦亮
export function usedCarPolish(data){
return request({
url: `/toc-user/car-app/usedCarPolish/${data}`,
method:'POST',
})
}
//二手车信息下架
//二手车信息下架
export function usedCarRemove(data){
return request({
url: '/toc-user/car-app/usedCarRemove',
@ -70,7 +70,7 @@ export function usedCarRemove(data){
data
})
}
//二手车信息重新上架
//二手车信息重新上架
export function usedCarReShelf(data){
return request({
url: `/toc-user/car-app/usedCarReShelf/${data}`,

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 589 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1022 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 355 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.3 KiB

View File

@ -4,6 +4,7 @@ Vue.use(VueRouter);
import kpiRouter from './kpi-router'
import invoiceRouter from "@/router/invoice-router";
import secondHandRouter from "@/router/second-hand-router";
import reportRouter from "@/router/report-router"
const routes = [
{
path: '/',
@ -277,6 +278,7 @@ const routes = [
...kpiRouter,
...invoiceRouter,
...secondHandRouter,
...reportRouter
]
const router = new VueRouter({

View File

@ -0,0 +1,21 @@
const reportRouter = [
{
path: '/reportIndex',
name: 'reportIndex',
component: () => import('@/views/report/reportIndex'),
meta:{
title: '道路救援',
cache: true,
modalState: false,
}
},
{
path: '/addressMap',
name: 'addressMap',
component: () => import('@/views/report/addressMap'),
meta:{
title: '道路救援',
}
},
]
export default reportRouter

View File

@ -11,7 +11,11 @@ const service = axios.create({
})
const urlParams = new URLSearchParams(window.location.search);
let token = urlParams.get('token');
localStorage.setItem('token', token);
if( token ) {
localStorage.setItem('token', token);
} else {
localStorage.setItem('token', '');
}
service.interceptors.request.use(
config => {
let reqUrl=config.url
@ -21,11 +25,13 @@ service.interceptors.request.use(
}
config.headers['Content-Type'] = config.contentType || 'application/x-www-form-urlencoded'
let token = localStorage.getItem('token');
// let token='4099761587129c46b03c9316c9e866c9'
// let token='eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJBTkNIQU5HIiwidXNlcklkIjo0NTY3MSwibmFtZSI6IuWuieeVhSIsInVzZXJOYW1lIjoiQU5DSEFORyIsInN1cHBsaWVySWQiOjExMjgsImlzWmQiOjAsImV4cCI6MTc1MjEzNDc2M30.q1O7C8thZzEMVKYDhBQ-N_14Fh9Bqejj7j11EKLF5Aw'
// let token='eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJTSEhQWEIiLCJ1c2VySWQiOjU0NzI2LCJuYW1lIjoiI-a1i-ivleWwj-eZveeZvSIsInVzZXJOYW1lIjoiU0hIUFhCIiwic3VwcGxpZXJJZCI6MTAwMDE2NSwiZXhwIjoxNzQ0NTEwNzkwfQ.JPk0OA7slYJN3FIi_uhW4Y0CiWRvl6R1dK8MRTbyhD8'
if(!(reqUrl=='/supplier/supplierTraining/trainingTask' || reqUrl=='/supplier/supplierTraining/normalList' || reqUrl=='/supplier/supplierTraining/trainingList')){
if(token) {
config.headers['Authorization'] = `${token}`;
config.headers['token'] = `${token}`;
}
}
return config
},

View File

@ -36,6 +36,7 @@ export function getAddress(mapContext, lnglat) {
} else {
console.log(result)
alert(JSON.stringify(result))
reject(result)
}
})
})
@ -44,7 +45,7 @@ export function getAddress(mapContext, lnglat) {
// 输入提示
export function searchFun(mapContext, cityCode, keyword) {
return new Promise((resolve, reject) => {
return new Promise((resolve) => {
mapContext.plugin('AMap.AutoComplete', function(){
var autoOptions = {
city: cityCode || '全国',
@ -57,7 +58,7 @@ export function searchFun(mapContext, cityCode, keyword) {
if(result.info == 'OK') {
resolve(result.tips)
} else {
reject(result)
resolve([])
}
})
})
@ -90,6 +91,7 @@ export function getRoad( mapContext, startLng, startLat, endLng, endLat ) {
}
/*
function drawRoute(route, map) {
let path = parseRouteToPath(route)
@ -106,3 +108,4 @@ function drawRoute(route, map) {
map.add(routeLine);
}
*/

View File

@ -0,0 +1,213 @@
<template>
<div class="address_wrap">
<div class="map_wrap" id="mapId">
</div>
<div class="button_wrap">
<div class="cancel_btn" @click="cancelHandler">取消</div>
<div class="confirm_btn" @click="successHandler">完成</div>
</div>
<div class="search_wrap">
<div class="section">
<input type="text" v-model="keyword" @change="searchHandler" placeholder="请输入地址" />
</div>
<div class="server_list" v-if="keyword">
<div class="text_box" v-for="(item, index) in addressList" :key="index" @click="chooseHandler(item, index)" :class="{'active': index == activeIndex}">
<div class="address_name">{{ item.name }}</div>
<div class="address_detail">{{ ( item.district || '' ) + ( item.address || '' ) }}</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { searchFun, getLocal, getAddress } from '@/utils/map'
export default {
name: "addressMap",
data() {
return {
keyword: '',
addressList: [],
activeIndex: '',
map: '',
marker: null,
cityCode: ''
}
},
watch: {
keyword() {
this.searchHandler()
}
},
async mounted() {
sessionStorage.setItem('reportAddress', '')
await this.initMap()
},
methods: {
async initMap() { // 初始化地图
this.map = new AMap.Map('mapId', {
viewMode: '2D', // 默认使用 2D 模式
zoom:11, //初始化地图层级
})
let res = await getLocal(this.map);
let lnglat = new AMap.LngLat(res?.lng, res?.lat);
let location = await getAddress(this.map, lnglat)
this.cityCode = location?.regeocode.addressComponent.adcode
//location?.regeocode?.addressComponent?.city || location?.regeocode?.addressComponent?.province
console.log('location', location);
},
async searchHandler() {
this.activeIndex = null
if( this.keyword ) {
this.addressList = await searchFun(this.map, this.cityCode, this.keyword,)
this.addressList = this.addressList.filter(item => !!item.location)
} else {
this.addressList = []
}
},
chooseHandler(item, index) {
this.activeIndex = index;
this.addMarker()
},
addMarker() {
if( this.marker ) {
this.map.remove(this.marker)
}
let content = '<div class="dest-position"></div>';
let activeObj = this.addressList[this.activeIndex];
this.marker = new AMap.Marker({
position: new AMap.LngLat( activeObj.location.lng, activeObj.location.lat ),
content: content,
offset: new AMap.Pixel(-13, -30)
});
this.map.add(this.marker)
this.map.setCenter([activeObj.location.lng, activeObj.location.lat])
},
successHandler() {
if( this.activeIndex == null ) {
this.$toast('请选择具体地址')
return
}
let activeObj = this.addressList[this.activeIndex];
let _tempObj = {
startPoiAddress: activeObj?.district + activeObj?.address + activeObj?.name,
startLat: activeObj?.location?.lat,
startLng: activeObj?.location?.lng,
adCode: activeObj?.adcode,
}
sessionStorage.setItem('reportAddress', JSON.stringify(_tempObj))
setTimeout(() => {
this.$router.go(-1)
}, 1)
},
// 取消 返回上一页
cancelHandler() {
this.$router.go(-1)
},
}
}
</script>
<style>
.dest-position {
width: 30px;
height: 36px;
background-size: 100% 100%;
background-image: url("~@/assets/report/destMarker.png");
}
</style>
<style scoped lang="scss">
.address_wrap {
height: 100%;
}
.map_wrap {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 60%;
z-index: -1;
}
.button_wrap {
width: 100%;
padding: 5px;
box-sizing: border-box;
zoom: 1;
position: fixed;
top: 0;
.cancel_btn {
width: 50px;
height: 27px;
background: #F37877;
font-size: 12px;
text-align: center;
line-height: 27px;
color: #fff;
border-radius: 3px;
float: left;
}
.confirm_btn {
width: 50px;
height: 27px;
background: rgba(5,193,98,1);
font-size: 12px;
text-align: center;
line-height: 27px;
color: #fff;
border-radius: 3px;
float: right;
}
}
.search_wrap {
background-color: #fff;
position: fixed;
width: 100%;
height: 60%;
bottom: 0;
left: 0;
overflow: auto;
.section {
height: 35px;
width: 100%;
background-color: #fff;
position: fixed;
top: 40%;
padding-top: 10px;
input {
width: 90%;
margin: 0 auto;
display: block;
border: none;
height: 30px;
border-radius: 3px;
padding: 0 10px;
background: #e2e0e0;
font-size: 14px;
}
}
.server_list {
overflow-y: auto;
padding-top: 30px;
.text_box {
margin: 10px 25px;
padding-top: 10px;
.address_name {
font-size: 14px !important;
color: rgba(0,0,0,0.8);
}
.address_detail {
margin-top: 3px;
color: #c3c3c3 !important;
font-size: 12px !important;
}
}
.active {
.address_name {
color: green !important;
}
.address_detail {
color: green !important;
}
}
}
}
</style>

View File

@ -0,0 +1,57 @@
<template>
<div class="bottom_wrap">
<div class="report_item" v-for="(item, index) in reportList" @click="goReportHandler(item)" :key="index">
<img class="report_icon" :src="item?.iconUrl" alt="">
<div class="report_title">{{item.name}}</div>
</div>
</div>
</template>
<script>
export default {
name: "report-list-item",
data() {
return {
addressReportCode: '',
}
},
props: ['reportList'],
methods: {
goReportHandler(data) {
this.$emit('getReport', data);
},
}
}
</script>
<style scoped lang="scss">
.bottom_wrap {
width: 100%;
/*position: fixed;*/
bottom: 0;
/*padding: 0 34px 20px;*/
padding-bottom: 20px;
display: flex;
flex-wrap: wrap;
background: #FFFFFF;
box-shadow: 0px 0px 20px 0px rgba(53,73,93,0.2);
box-sizing: border-box;
.report_item {
width: 25%;
margin-top: 20px;
text-align: center;
.report_icon {
width: 45px;
height: 45px;
}
.report_title {
color: rgba(53, 53, 53, 0.67);
font-size: 11px;
line-height: 16px;
margin-top: 6px;
}
}
}
</style>

View File

@ -0,0 +1,112 @@
<template>
<div class="wrap">
<div class="service_title">
<span class="name">{{orderInfo?.serviceName}}</span>
<span class="status">
{{orderInfo?.orderStatusString}}
<span class="refresh_btn" @click="refreshHandler">刷新</span>
</span>
</div>
<!-- <img class="report_line" src="@/assets/report/report_line.png" alt="">-->
<div class="service_content">
<div class="content_left">
<img class="report_logo" src="@/assets/report/report_logo.png" alt="">
</div>
<div class="content_right">
<div class="order_code">单号{{orderInfo?.userOrderCode}}</div>
<div class="company">单位{{orderInfo?.supplierName}}</div>
<div class="driver_info">
<span class="driver_name">{{orderInfo?.driverName}}</span>
<span>{{orderInfo?.phone}}</span>
</div>
</div>
</div>
</div>
</template>
<script>
export default {
name: "service-item",
props: ['orderInfo'],
methods: {
refreshHandler() {
this.$emit('refresh')
}
}
}
</script>
<style scoped lang="scss">
.wrap {
width: calc(100% - 20px);
background: #FFFFFF;
box-shadow: 0px 0px 9px 0px rgba(53,73,93,0.2);
border-radius: 8px;
border: 1px solid #E6E6E6;
backdrop-filter: blur(5.602678571428572px);
margin: 0 auto;
}
.service_title {
height: 40px;
line-height: 42px;
padding-left: 22px;
padding-right: 14px;
background: #F9FDFF;
display: flex;
justify-content: space-between;
border-bottom: 1px solid #EFEFEF;
border-top-left-radius: 8px;
border-top-right-radius: 8px;
.name {
font-size: 16px;
font-weight: bold;
color: rgba(0, 0, 0, 0.9);
}
.status {
font-size: 13px;
color: #F19028;
}
.refresh_btn {
background-color: #267EF0;
color: #fff;
padding: 6px 12px;
margin-left: 5px;
border-radius: 3px;
}
}
.service_content {
padding: 11px 16px 18px;
display: flex;
.content_left {
.report_logo {
width: 56px;
height: 56px;
margin-right: 14px;
}
}
.content_right {
.order_code {
color: #323643;
font-size: 16px;
font-weight: 600;
margin-bottom: 1px;
}
.company {
color: #323643;
font-size: 13px;
margin-bottom: 3px;
}
.driver_info {
color: rgba(50, 54, 67, 0.65);
font-size: 12px;
margin-bottom: 3px;
.driver_name {
margin-right: 10px;
}
}
}
}
.report_line {
}
</style>

View File

@ -0,0 +1,568 @@
<template>
<!-- <van-pull-refresh v-model="isLoading" class="custom-pull-refresh safe-pull-refresh" @refresh="onRefresh">-->
<div class="main_wrap">
<div class="top_bg" :class="{'dispatch' : type == 1 , 'driver' : type != 1}">
<!-- <div class="title">报备中心</div>-->
</div>
<div class="service_wrap">
<service-item :order-info="orderInfo" @refresh="onRefreshHandler"></service-item>
</div>
<div class="chat_list" ref="chatList" >
<!--ai对话框 s -->
<div v-for="(item, index) in recordList" :key="index">
<template v-if="item.messageType == 4">
<div class="top_tip_wrap">为了快速解决问题请选择下方咨询类型</div>
<div class="ai_chat" >
<div class="ai_left">
<img class="report_ai" src="@/assets/report/report_ai.png" alt="">
</div>
<div class="ai_right">
<div class="ai_title">{{ orderInfo?.driverName }}你好请选择报备内容</div>
<ul>
<li v-for="_item in item.content" :key="_item.id" @click="addReportHandler(_item)">{{_item.name}}</li>
</ul>
</div>
</div>
</template>
<template v-if="[2, 3].includes(Number(item.messageType))">
<!--ai对话框 e -->
<div class="tip_wrap">{{item.createTime}}</div>
<!--客服对话框 s -->
<div class="customer_item mb20">
<div class="customer_left">
<img class="profile_photo mr" src="@/assets/report/report_customer.png" alt="">
</div>
<div class="common_right customer_cls">
<div class="customer_status">{{item.reportConfigName}}</div>
<div class="response_con">{{item.remark}}</div>
</div>
</div>
</template>
<template v-if="item.messageType == 1">
<!--服务人员对话框 e -->
<div class="tip_wrap">{{item.createTime}}</div>
<!--服务人员对话框 s -->
<div class="server_item mb20">
<div class="common_right service_cls">
<div class="service_status">{{item.reportConfigName}}</div>
<div class="response_con">{{item.remark}}</div>
</div>
<div class="customer_left">
<img class="profile_photo ml" v-if="type == 1" src="@/assets/report/report_dispatch.png" alt="">
<img class="profile_photo ml" v-else src="@/assets/report/report_driver.png" alt="">
</div>
</div>
<!--服务人员对话框 e -->
</template>
</div>
</div>
<report-list-item :report-list.sync="reportList" @getReport="getReportHandler" />
<van-popup ref="addReportModal" v-model="addReportShow" :close-on-click-overlay="false" closeable duration="0" round position="bottom">
<div class="dialog_wrap">
<img class="add_report_bg" src="@/assets/report/add_report_bg.png" alt="">
<div class="report_content">
<template v-if="currentInfo.component == 'time'">
<!--预约时间报备 s -->
<div class="report_title">
<img class="dot" src="@/assets/report/add_report_dot.png" alt="">
<span>预约时间</span>
</div>
<div class="report_time_content" @click="showDatetime = true">
<div class="report_time_left">
<img class="add_report_time" src="@/assets/report/add_report_time.png" alt="">
<span>{{appointTime || '请选择时间'}}</span>
</div>
<img class="report_arrow" src="@/assets/report/add_report_arrow.png" alt="">
</div>
<!--预约时间报备 e -->
</template>
<template v-if="currentInfo.component == 'address'">
<!--修改地址报备 s -->
<div class="report_title">
<img class="dot" src="@/assets/report/add_report_dot.png" alt="">
<span>修改地址</span>
</div>
<div class="report_time_content" @click="goPage('addressMap')">
<div class="report_time_left">
<img class="add_report_time" src="@/assets/report/add_report_address.png" alt="">
<span>{{address || '请选择地址'}}</span>
</div>
<img class="report_arrow" src="@/assets/report/add_report_arrow.png" alt="">
</div>
<!--修改地址报备 e -->
</template>
<div class="report_title">
<img class="dot" src="@/assets/report/add_report_dot.png" alt="">
<span>补充报备内容</span>
</div>
<div class="report_common_content">
<textarea class="report_textarea" id="text-input" rows="4" placeholder="点击这里输入补充报备内容" v-model.trim="remark"></textarea>
<!-- <van-field-->
<!-- v-model="remark"-->
<!-- class="report_textarea"-->
<!-- placeholder="点击这里输入补充报备内容" />-->
</div>
</div>
<div class="report_btn" @click="saveHandler">
提交报备
</div>
</div>
</van-popup>
<van-popup v-model="showDatetime" round position="bottom">
<van-datetime-picker
class="dataTime"
v-if="showDatetime"
v-model="appointTime"
type="datetime"
:min-date="minDate"
@confirm="onConfirm"
@cancel="showDatetime = false"
/>
</van-popup>
</div>
<!-- </van-pull-refresh>-->
</template>
<script>
import { getReportListByOrder, reportHistory, newOrderReporting, getOrderInfo } from "@/api/report"
import { myMixins} from "@/utils/myMixins";
import {timeFormat} from "@/utils/common";
import reportListItem from '@/views/report/components/report-list-item'
import serviceItem from "@/views/report/components/service-item"
import {Dialog, Toast} from "vant";
export default {
name: "reportIndex",
components: { serviceItem, reportListItem },
mixins: [myMixins],
data() {
return {
addReportShow: false,
remark: '',
showDatetime: false,
appointTime: '',
minDate: new Date(),
address: '',
lat: '',
lng: '',
reportList: [],
recordList: [],
orderInfo: {},
type: '', // 1 调度 2 司机
currentInfo: '',
userOrderId: '',
userOrderCode: '',
driverId: '',
clickFlag: true,
isLoading: false,
}
},
async mounted() {
const urlParams = new URLSearchParams(window.location.search);
this.userOrderId = this.$route.query.userOrderId || urlParams.get('userOrderId');
this.userOrderCode = this.$route.query.userOrderCode || urlParams.get('userOrderCode');
this.type = this.$route.query.type || urlParams.get('type');
this.driverId = this.$route.query.driverId || urlParams.get('driverId');
await this.getReportList();
await this.getDetail();
await this.getRecordList();
await this.scrollToBottom();
},
activated() {
let addressSession = sessionStorage.getItem('reportAddress');
if(addressSession) {
let _obj = JSON.parse(addressSession)
this.address = _obj.startPoiAddress;
this.lat = _obj.startLat;
this.lng = _obj.startLng;
this.adCode = _obj.adCode;
}
},
methods: {
onRefreshHandler() {
setTimeout(async () => {
try {
this.recordList = [];
await this.getReportList();
await this.getDetail();
await this.getRecordList();
await this.scrollToBottom();
} finally {
this.isLoading = false; // 结束加载状态
}
}, 100)
},
// 添加滚动方法
scrollToBottom() {
this.$nextTick(() => {
const container = this.$refs.chatList
container.scrollTop = container.scrollHeight
})
},
async getRecordList() {
let recordList = await reportHistory({
userOrderId: this.userOrderId,
userOrderCode: this.userOrderCode,
driverId: this.driverId,
source: Number(this.type),
})
this.recordList = recordList.data;
},
async saveHandler() {
if( this.clickFlag ) {
let data = {
source: Number(this.type),
reportContent: this.remark,
userOrderId: Number(this.userOrderId),
reportConfigId: this.currentInfo.id,
userOrderCode: this.userOrderCode,
driverId: this.driverId,
}
if(this.currentInfo.component == 'time') {
if( !this.appointTime ) {
Toast('预约时间不能为空')
return
}
if( new Date(this.appointTime).getTime() <= new Date().getTime() ) {
Toast('预约时间不能小于当前时间')
return
}
data.time = this.appointTime
}
if(this.currentInfo.component == 'address') {
if( !this.address ) {
Toast('地址不能为空')
return
}
data.address = this.address
data.lat = this.lat;
data.lng = this.lng;
}
if( !this.remark ) {
Toast('备注内容不能为空')
return
}
this.clickFlag = false;
try {
await newOrderReporting(data)
Dialog.alert({
title: '提示',
message: "报备添加成功"
}).then(async () => {
await this.getRecordList()
this.addReportShow = false
this.scrollToBottom();
this.initDialogData();
this.clickFlag = true
});
} finally {
this.clickFlag = true
}
}
},
initDialogData() {
this.appointTime = '';
this.address = '';
this.lat = '';
this.lng = '';
this.remark = '';
},
addReportHandler(data) { // 点击添加报备弹框
this.currentInfo = data;
this.addReportShow = true
},
getReportHandler(data) { // 点击获取当前报备信息
this.recordList.push({
messageType: 4,
content: data.child
})
this.scrollToBottom();
},
async getDetail(){ // 订单详情
if(this.userOrderId) {
let result = await getOrderInfo({
userOrderId: this.userOrderId,
userOrderCode: this.userOrderCode
})
this.orderInfo = result.data
} else {
this.orderInfo = {}
}
},
async getReportList() { // 报备大类
let res = await getReportListByOrder({
orderId: this.userOrderId
});
this.reportList = res.data
},
onConfirm(data) {
this.appointTime = timeFormat(new Date(data))
this.showDatetime = false;
}
}
}
</script>
<style lang="scss">
.custom-pull-refresh {
height: 100% !important;
}
</style>
<style lang="scss" scoped>
#app {
background: #F9FCFF !important;
height: 100%;
}
.main_wrap {
width: 100%;
height: 100%;
background: #F9FCFF !important;
display: flex;
flex-direction: column;
// 添加以下样式确保正确的高度计算
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
}
.top_bg {
width: 100%;
height: 87px;
/*.title {
color: #fff;
text-align: center;
padding-top: 52px;
font-size: 17px;
line-height: 24px;
}*/
}
.dispatch { // 调度app头部背景色
background: #354683;
}
.driver { // 司机app头部背景色
background: #334885;
}
.service_wrap {
margin-top: -75px;
/*margin-bottom: 20px;*/
}
.chat_list {
flex: 1;
/*overflow: auto;*/
overflow-y: auto;
overflow-x: hidden;
-webkit-overflow-scrolling: touch; // 为了iOS平滑滚动
padding-top: 10px;
/* 修复 iOS 滚动问题 */
transform: translateZ(0);
.top_tip_wrap {
color: #7C8698;
text-align: center;
font-size: 13px;
}
.tip_wrap {
color: #7C8698;
text-align: center;
font-size: 13px;
margin-bottom: 10px;
}
.ai_chat {
padding: 25px 10px 20px;
display: flex;
.ai_left {
.report_ai {
width: 44px;
height: 44px;
margin-right: 12px;
}
}
.ai_right {
.ai_title {
color: #203152;
font-size: 15px;
font-weight: 600;
margin-bottom: 15px;
}
li {
font-size: 13px;
color: #267EF0;
line-height: 18px;
margin-bottom: 15px;
font-weight: bold;
}
li::before {
content: "";
display: inline-block;
width: 8px;
height: 8px;
background-color: #5680FA;
border-radius: 50%; /* 圆形 */
margin-right: 10px;
}
}
}
}
/*客服人员,服务人员对话弹框样式 s*/
.profile_photo {
width: 44px;
height: 44px;
}
.mr {
margin-right: 10px;
}
.ml {
margin-left: 10px;
}
.mb20 {
margin-bottom: 20px;
}
.customer_item {
display: flex;
padding-left: 10px;
padding-right: 64px;
.customer_left {
}
}
.common_right {
padding: 11px 13px;
flex: 1;
.customer_status::before {
content: "";
display: inline-block;
width: 8px;
height: 8px;
background-color: #5680FA;
border-radius: 50%; /* 圆形 */
margin-right: 10px;
}
.customer_status {
font-size: 14px;
color: #267EF0;
line-height: 20px;
font-weight: bold;
}
.service_status {
font-size: 14px;
color: #F07926;
line-height: 20px;
font-weight: bold;
}
.service_status::before {
content: "";
display: inline-block;
width: 8px;
height: 8px;
background-color: #F07926;
border-radius: 50%; /* 圆形 */
margin-right: 10px;
}
}
.customer_cls {
border-radius: 0px 6px 6px 6px;
background: #E3F0FF;
}
.service_cls {
background: #FAEBD8;
border-radius: 0px 6px 6px 6px;
}
.server_item {
display: flex;
padding-right: 10px;
padding-left: 64px;
}
.response_con {
font-size: 13px;
color: #242A37;
line-height: 18px;
font-weight: bold;
margin-top: 5px;
}
/*客服人员,服务人员对话弹框样式 e*/
.dialog_wrap {
.add_report_bg {
width: 100%;
height: 76px;
}
.report_content {
width: calc(100% - 12px);
margin: -30px auto 0;
padding-right: 14px;
padding-left: 20px;
box-sizing: border-box;
background: #fff;
position: relative;
padding-top: 25px;
border-radius: 10px;
.report_title {
font-size: 16px;
font-weight: 600;
color: #267EF0;
line-height: 22px;
margin-bottom: 10px;
.dot {
width: 7px;
height: 6px;
margin-right: 12px;
}
}
.report_time_content {
padding: 13px;
background: #F2F7FF;
border-radius: 6px;
border: 1px solid #E2EAF6;
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 30px;
.report_time_left {
font-size: 14px;
font-weight: bold;
color: rgba(0, 0, 0, 0.9);
display: flex;
align-items: flex-start;
}
.add_report_time {
width: 18px;
height: 18px;
margin-right: 8px;
}
.report_arrow {
width: 8px;
height: 12px;
margin-left: 5px;
}
}
.report_common_content {
margin-bottom: 27px;
.report_textarea {
width: 100%;
box-sizing: border-box;
background: #F8FAFC;
border-radius: 6px;
min-height: 95px;
border: 1px solid #E2EAF6;
padding: 10px;
font-size: 13px;
}
}
}
.report_btn {
width: calc(100% - 80px);
height: 46px;
line-height: 46px;
background: #005DD5;
border-radius: 23px;
color: #FFFFFF;
font-size: 15px;
font-weight: bold;
text-align: center;
margin: 0 auto 40px;
}
}
::v-deep .van-popup__close-icon {
color: #0F458E;
}
</style>

View File

@ -25,6 +25,8 @@
:text="'行驶证照片'" :multiple="false" :files.sync="vehicleLicensePhotoList"/>
<upload-common @success2="getPlateColor" @delete2="deleteImg2"
:text="'车辆45度照'" :multiple="false" :files.sync="vehicleAnglePhotoList" />
<upload-common @success4="getBackPhoto" @delete4="deleteImgBack"
:text="'车辆后方45度'" :multiple="false" :files.sync="vehicleRearPhotoList" />
<upload-common @success3="getOtherImg" @delete3="handleDeleteOtherImg"
:text="'其他照片0/6'" :multiple="true" :files.sync="otherImgSrcList"/>
</div>
@ -40,18 +42,18 @@
<div class="item vehicleTypeItem">
<span> <span class="star">*</span>车辆类型 </span>
<van-radio-group v-model="form.vehicleType" direction="horizontal" class="radioWrap">
<van-radio name="拖车" :class="{'checked':form.vehicleType=='拖车','vehicleRadio':true}">拖车</van-radio>
<van-radio name="平板拖车" :class="{'checked':form.vehicleType=='平板拖车','vehicleRadio':true}">平板拖车</van-radio>
<van-radio name="地库车" :class="{'checked':form.vehicleType=='地库车','vehicleRadio':true}">地库车</van-radio>
<van-radio name="牵引车" :class="{'checked':form.vehicleType=='牵引车','vehicleRadio':true}">牵引车</van-radio>
<van-radio name="随车吊" :class="{'checked':form.vehicleType=='随车吊','vehicleRadio':true}">随车吊</van-radio>
</van-radio-group>
</div>
<div class="item" v-if="form.vehicleType=='拖车'">
<div class="item" v-if="form.vehicleType=='平板拖车'">
<span> <span class="star">*</span>落板方式 </span>
<van-radio-group v-model="form.boardType" direction="horizontal" class="radioWrap">
<van-radio name="1" :class="{'checked':form.boardType==1}">全落地</van-radio>
<van-radio name="2" :class="{'checked':form.boardType==2}">斜落</van-radio>
<van-radio name="3" :class="{'checked':form.boardType==3}">一般平</van-radio>
<van-radio name="2" :class="{'checked':form.boardType==2}">斜落一体</van-radio>
<van-radio name="3" :class="{'checked':form.boardType==3}">普通斜</van-radio>
</van-radio-group>
</div>
<div class="item">
@ -63,6 +65,13 @@
<van-radio name="6" :class="{'checked':form.emissionStandard==6}">国6</van-radio>
</van-radio-group>
</div>
<div class="item">
<span> <span class="star">*</span>刹车系统 </span>
<van-radio-group v-model="form.brakeSystem" direction="horizontal" class="radioWrap">
<van-radio name="1" :class="{'checked':form.brakeSystem==1}">气刹</van-radio>
<van-radio name="2" :class="{'checked':form.brakeSystem==2}">油刹</van-radio>
</van-radio-group>
</div>
<div class="item">
<span> <span class="star">*</span>所在城市 </span>
<van-field
@ -99,10 +108,9 @@
> </van-field>
</div>
<div class="item">
<span> <span class="star">*</span>售价</span>
<span> <span class="star">*</span>售价(含税)</span>
<van-field
type="number"
style="border: none"
class="radioWrap"
v-model="form.minPrice"
@input="validatePrice"
@ -113,6 +121,15 @@
</template>
</van-field>
</div>
<div class="item" style="margin-bottom:20px">
<span> <span class="star">*</span>底盘品牌</span>
<van-field
class="radioWrap"
v-model="form.underpanBrand"
input-align="right"
>
</van-field>
</div>
</div>
<div class="line lastLine"></div>
<div class="threeContent content">
@ -126,7 +143,7 @@
<img v-show="radio==1" @click="radio=0" class="radioIcon" src="@/assets/secondHandCar/checked.png" />
<img v-show="radio==0" @click="radio=1" class="radioIcon" src="@/assets/secondHandCar/uncheck.png" />
<span>我已阅读并同意</span>
<span @click="viewPrivacy">二手车交易条款</span>
<span @click="viewPrivacy">二手车交易条款</span>
</div>
<div class="btnWrap" >
<div v-if="type==1" class="btn commonBtn" @click="noMultipleClicks(submitHandle)">发布</div>
@ -163,6 +180,7 @@ export default {
type:1,
vehicleLicensePhoto:'',
vehicleAnglePhoto:'',
vehicleRearPhoto: '',
otherPhoto:'',
licenseType:'',
brandModel:'',
@ -178,6 +196,8 @@ export default {
contactNumber:'',
minPrice:'',
desc:'',
underpanBrand: '',
brakeSystem: '',
},
radio: 0,
type:'',//1为发布&修改 2为审核
@ -191,6 +211,7 @@ export default {
areaName:'',
vehicleLicensePhotoList:[],
vehicleAnglePhotoList:[],
vehicleRearPhotoList: [],
otherImgSrcList:[],
otherImgSrc:[],
status:'',
@ -225,6 +246,7 @@ export default {
}
this.vehicleLicensePhotoList=[{url:res.data?.vehicleLicensePhoto}]
this.vehicleAnglePhotoList=[{url:res.data?.vehicleAnglePhoto}]
this.vehicleRearPhotoList = [{ url: res.data?.vehicleRearPhoto }]
}
let carSourceFormInfo=localStorage.getItem("carSourceFormInfo") ? JSON.parse(localStorage.getItem("carSourceFormInfo")) : ''
if(!carSourceFormInfo){
@ -242,6 +264,9 @@ export default {
}
if(this.form.vehicleAnglePhoto){
this.vehicleAnglePhotoList=[{url:this.form.vehicleAnglePhoto}]
}
if( this.form.vehicleRearPhoto ) {
this.vehicleRearPhotoList = [{url: this.form.vehicleRearPhoto}]
}
// console.log("carSourceFormInfo",carSourceFormInfo)
if(carSourceFormInfo.otherImgSrc0){
@ -319,7 +344,7 @@ export default {
this.form.vinCode=data.info.vin
this.form.plateNumber=data.info.plateNo
this.form.registerDate=data.info.registerDate +' 00:00:00'
this.form.vehicleType=data.info.vehicleType
// this.form.vehicleType=data.info.vehicleType
},
deleteImg1(){
this.form.vehicleLicensePhoto=''
@ -336,6 +361,13 @@ export default {
getOtherImg(data){
this.otherImgSrc.push(data.url)
},
getBackPhoto(data) {
console.log("datadata",data)
this.form.vehicleRearPhoto = data.url
},
deleteImgBack() {
this.form.vehicleRearPhoto = '';
},
handleDeleteOtherImg(file,index) {
this.otherImgSrc = this.otherImgSrc.filter((item,i) => index !== i);
this.otherImgSrcList = this.otherImgSrcList.filter((item,i) => index !== i);
@ -354,22 +386,36 @@ export default {
this.$toast('车辆45度不能为空')
return
}
if(!this.form.vehicleRearPhoto && type == 1) {
this.$toast('车辆后方45度不能为空')
return
}
let flag=this.validateHandle()
if(flag){
this.$toast(flag)
return
}
if (this.form.vehicleType=='拖车' && !this.form.boardType) {
if (this.form.vehicleType=='平板拖车' && !this.form.boardType) {
this.$toast('落板方式不能为空')
return
}else if(this.form.vehicleType !=='拖车'){
}else if(this.form.vehicleType !=='平板拖车'){
this.form.boardType=''
}
let rule = this.validationRules.find(item =>
item.value === null ||
item.value === undefined ||
item.value === ''
)
let rule
if( type == 1 ) {
rule = this.validationRules.find(item =>
item.value === null ||
item.value === undefined ||
item.value === ''
)
} else {
rule = this.validationRulesSimple.find(item =>
item.value === null ||
item.value === undefined ||
item.value === ''
)
}
if(rule){
this.$toast(rule.name)
return
@ -404,15 +450,19 @@ export default {
this.$toast('车辆45度不能为空')
return
}
if(!this.form.vehicleRearPhoto) {
this.$toast('车辆后方45度不能为空')
return
}
let flag=this.validateHandle()
if(flag){
this.$toast(flag)
return
}
if (this.form.vehicleType=='拖车' && !this.form.boardType) {
if (this.form.vehicleType=='平板拖车' && !this.form.boardType) {
this.$toast('落板方式不能为空')
return
}else if(this.form.vehicleType !=='拖车'){
}else if(this.form.vehicleType !=='平板拖车'){
this.form.boardType=''
}
let rule = this.validationRules.find(item =>
@ -469,6 +519,18 @@ export default {
},
computed: {
validationRules() {
return [
{ value: this.form.vehicleType, name: '车辆类型不能为空' },
{ value: this.form.emissionStandard, name: '排放标准不能为空' },
{ value: this.form.brakeSystem, name: '刹车系统不能为空' },
{ value: this.form.areaCode, name: '所在城市不能为空' },
{ value: this.form.mileage, name: '行驶里程不能为空' },
{ value: this.form.contactNumber, name: '联系方式不能为空' },
{ value: this.form.minPrice, name: '售价不能为空' },
{ value: this.form.underpanBrand, name: '底盘品牌不能为空' },
];
},
validationRulesSimple() {
return [
{ value: this.form.vehicleType, name: '车辆类型不能为空' },
{ value: this.form.emissionStandard, name: '排放标准不能为空' },

View File

@ -89,6 +89,8 @@ export default {
this.$emit("delete1");
} else if (this.text === "车辆45度照") {
this.$emit("delete2");
} else if(this.text == '车辆后方45度') {
this.$emit("delete4");
} else {
console.log("file, detail", file, detail)
this.$emit("delete3", file, detail.index);
@ -122,6 +124,8 @@ export default {
let num = this.getVehicleLicense(result.data.color)
let data = {url: res?.data, colorStr: result.data.color, colorStatus: num, plateType: result.data.number}
this.$emit('success2', data)
} else if(this.text == '车辆后方45度') {
this.$emit('success4', {url: res?.data, uid: file.uid})
} else {
this.$emit('success3', {url: res?.data, uid: file.uid})
}
@ -253,4 +257,4 @@ export default {
::v-deep .van-uploader__preview-delete-icon {
display: none !important; /* 强制隐藏伪元素 */
}
</style>
</style>

View File

@ -3,18 +3,24 @@
<div class="headerWrap">
<div v-if="isWebFunc()" style="opacity: 0;" class="back"></div>
<img v-else class="back" @click="h5GoBack" src="@/assets/secondHandCar/back.png" />
<span>在售</span>
<span>{{detailInfo?.status?.code !== 6 ? '在售' : '已售出'}}</span>
<div style="opacity: 0;" class="back"></div>
</div>
<van-loading v-show="!detailInfo" class="loadingWrap" type="spinner" color="#1989fa" />
<div class="contentWrap" v-show="detailInfo">
<el-carousel v-if="isWebFunc()" trigger="click" height="215px" :autoplay="false">
<el-carousel v-if="isWebFunc()" trigger="click" height="215px" :autoplay="true">
<el-carousel-item v-for="(item,i) in imgSrcList" :key="i">
<img v-if="item" class="swipeImg" :src="item" />
<el-image
:src="item"
v-if="item"
:preview-src-list="[item]"
class="swipeImg"
/>
<!-- <img v-if="item" class="swipeImg" :src="item" />-->
</el-carousel-item>
</el-carousel>
<van-swipe v-else @change="onChange" >
<van-swipe-item v-for="(item,i) in imgSrcList" :key="i">
<van-swipe v-else @change="onChange" :autoplay="3000">
<van-swipe-item v-for="(item,i) in imgSrcList" :key="i" @click="showImagePreview(i)">
<img v-if="item" class="swipeImg" :src="item" />
</van-swipe-item>
<template #indicator>
@ -34,9 +40,13 @@
<div class="time">
<span>{{ detailInfo.createTime?.substring(0,10) }}</span><span>{{ detailInfo.areaName }}</span><span>发布</span>
</div>
<div class="price">
<span>{{ formatNumber(detailInfo.minPrice) }}</span>
<span></span>
<div class="priceWrap">
<div class="price">
售价含税
<span>{{ formatNumber(detailInfo.minPrice) }}</span>
<span></span>
</div>
<div class="viewNum">{{detailInfo.attentionCount}}人想要<span>{{detailInfo.browseCount}}人浏览</span></div>
</div>
</div>
<div class="detailInfoWrap wrapCommon">
@ -51,12 +61,12 @@
<div class="suGang"></div>
<div class="itemInfo">
<span>{{ detailInfo.vehicleType }}</span>
<span>车类型</span>
<span>类型</span>
</div>
<div class="suGang"></div>
<div class="itemInfo">
<span>{{ detailInfo.boardType?.label }}&nbsp;&nbsp;</span>
<span>拖车落板</span>
<span>落板方式</span>
</div>
</div>
<div class="descItem descCommon">
@ -70,14 +80,24 @@
<span>排放标准</span>
</div>
<div class="suGang"></div>
<div class="itemInfo">
<span>{{ detailInfo.brakeSystem == 2 ? '油刹' : '汽刹' }}</span>
<span>刹车系统</span>
</div>
</div>
<div class="descItem descCommon">
<div class="itemInfo">
<span>{{ detailInfo.underpanBrand }}</span>
<span>底盘品牌</span>
</div>
<div class="suGang"></div>
<div class="itemInfo">
<el-tooltip class="item" effect="dark" :content="formatToWan(detailInfo.mileage)+'公里'" placement="top">
<span style="display: inline-block;width:100%;cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;">{{ formatToWan(detailInfo.mileage)}}公里</span>
</el-tooltip>
<span>行驶公里</span>
</div>
</div>
<div class="descItem descCommon">
<div class="suGang"></div>
<div class="itemInfo dateItemInfo">
<span>{{ detailInfo.registerDate?.substring(0,10) }}</span>
<span>注册日期</span>
@ -89,7 +109,7 @@
<div class="descCommon desc">{{detailInfo.desc}}</div>
</div>
<div class="btnWrap" >
<div v-if="isList && !detailInfo.selfSupplierPublish" class="btn commonBtn" @click="noMultipleClicks(handle)">我想要</div>
<div v-if="isList && !detailInfo.selfSupplierPublish && detailInfo.status.code !== 6" class="btn commonBtn" @click="noMultipleClicks(handle)">我想要</div>
</div>
</div>
</div>
@ -100,7 +120,7 @@
import {myMixins} from "@/utils/myMixins"
import {carInfoDetail,saveRecord} from "@/api/secondHandCar";
import { Dialog } from 'vant';
import { ImagePreview, Dialog } from 'vant';
export default {
name: "forSale",
mixins:[myMixins],
@ -116,6 +136,7 @@ export default {
startTime: null, // 记录进入时间
recordType:1,
isList:false,//是否是首页列表跳转过来的
recordResponseId:'',//信息记录获取的id用于关闭界面掉接口所需参数
}
},
async mounted() {
@ -137,19 +158,33 @@ export default {
queryType:this.queryType ,
})
this.detailInfo=res?.data
// console.log("this.detailInfo",this.detailInfo)
const municipalities = ['北京市', '天津市', '上海市', '重庆市'];
const isMunicipality = municipalities.some(city => res.data.areaName.includes(city));
this.detailInfo.areaName= isMunicipality ? res.data.areaName?.substring(0, 3) : res.data.areaName;
if(res.data.otherPhoto){
this.imgSrcList=res.data.otherPhoto.split(',') || []
}
if( res?.data?.vehicleRearPhoto ) {
this.imgSrcList.unshift(res?.data?.vehicleRearPhoto)
}
this.imgSrcList.unshift(res?.data?.vehicleAnglePhoto)
let result=await saveRecord({type: 1, carInfoId: this.id, duration:'',id:''});
// console.log('resultresult',result)
this.recordResponseId=result?.data?.id
}
},
destroyed() {
this.getDuration(1)
},
methods:{
showImagePreview(index) {
ImagePreview({
images: this.imgSrcList.map(item => item),
startPosition: index,
closeable: true
});
},
formatToWan(num) {
let result = (num / 10000).toString(); // 转换为万单位
if (result.includes('.')) {
@ -167,16 +202,18 @@ export default {
this.saveRecord(duration,type);
},
async saveRecord(duration,type){
await saveRecord({type: type, carInfoId: this.id, duration})
await saveRecord({type: type, carInfoId: this.id, duration,id:this.recordResponseId || ''})
},
handle(){
this.getDuration(2)
Dialog.alert({
message:this.detailInfo.contactNumber ,
confirmButtonText:'拨打电话',
confirmButtonText:this.isWebFunc() ? '确定' : '拨打电话',
showCancelButton:true,
}).then(async() => {
window.location.href = `tel:${this.detailInfo.contactNumber}`;
if(!this.isWebFunc()){
window.location.href = `tel:${this.detailInfo.contactNumber}`;
}
}).catch(() => {
// on cancel
});
@ -263,6 +300,18 @@ export default {
margin-left: 10px;
}
}
.priceWrap{
display: flex;
justify-content: space-between;
align-items: center;
.viewNum{
//color: #ccc;
margin-right: 15px;
span{
margin-left: 10px;
}
}
}
.price{
color: #FF5533;
line-height: 28px;
@ -303,6 +352,7 @@ export default {
display: flex;
flex-direction: column;
width: 23%;
flex: 1;
span:first-child{
font-weight: bold;
font-size: 14px;
@ -322,6 +372,7 @@ export default {
height: 8px;
border-right: 1px solid #999999;
opacity: 0.5;
margin-right: 30px;
}
.desc{
font-weight: 400;
@ -365,5 +416,25 @@ export default {
.swipeImg{
width: 100%;
height: 100%;
object-fit: cover; /* 保持比例填充容器,裁剪多余部分 */
object-position: center; /* 居中显示 */
}
::v-deep .el-carousel__button {
height: 0.15rem !important;
width: 0.3rem;
}
::v-deep .el-carousel__indicators--horizontal {
padding: 0.32rem 0.08rem;
}
::v-deep .el-carousel__arrow {
background-color: rgba(31, 45, 61, 1);
font-size: 0.5rem;
}
::v-deep .el-carousel__indicators--horizontal {
bottom: 10px;
}
::v-deep .el-image__inner {
object-fit: cover;
object-position: center;
}
</style>

View File

@ -1,5 +1,16 @@
<template>
<div class="wrap">
<div class="navBar">
<van-nav-bar
title="二手拖车信息"
left-arrow
left-arrow-color="#FFFFFF"
:border="false"
:fixed="true"
:safe-area-inset-top="true"
@click-left="goBack"
/>
</div>
<div class="headerWrap">
<img class="bg" src="@/assets/secondHandCar/bg.png" />
<img class="mine" src="@/assets/secondHandCar/mine.png" @click="goMine" />
@ -62,6 +73,32 @@
:value="item.value">
</el-option>
</el-select>
<el-select v-model="proprietary" placeholder="发布方" :class="{'customSel':true , 'has-value': (proprietary || proprietary === 0) ? true : false }" clearable>
<el-option
v-for="item in proprietaryOption"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
<el-input readonly @focus="areaShow = true" v-model="areaName" placeholder="请选择发布省市" :class="{'customSel':true,'customInput':true , 'has-value': areaName }" >
<template #suffix>
<i
v-if="areaName"
class="el-icon-circle-close el-input__icon"
@click="areaName = ''"
></i>
</template>
</el-input>
<el-input readonly @focus="showDatePicker = true" v-model="dateVal" placeholder="请选择发布日期" :class="{'customSel':true,'customInput':true , 'has-value': dateVal }" >
<template #suffix>
<i
v-if="dateVal"
class="el-icon-circle-close el-input__icon"
@click="dateVal = ''"
></i>
</template>
</el-input>
</div>
<div class="contentWrap" v-show="!show">
<van-pull-refresh v-model="isLoading" @refresh="onRefresh" style="min-height:85vh">
@ -74,6 +111,8 @@
<div class="contentItem">
<div class="item" v-for="(item,index) in pageList" :key="index" @click="viewCarSource(item)">
<div class="left">
<img class="owner_logo" v-if="item.proprietary == 1" src="@/assets/secondHandCar/icon_zdOwner.png" alt="">
<img class="saled_logo" v-if="item.status.code == 6 && item.downReason == '已售出'" src="@/assets/secondHandCar/icon_saled.png" alt="">
<img class="img" v-if="item.vehicleAnglePhoto" :src="item.vehicleAnglePhoto" />
<div v-else class="qiugou">{{item.vehicleType?.substring(0,2)}}</div>
</div>
@ -83,11 +122,20 @@
{{ item.brandModel?.match(/^[\u4e00-\u9fa5]+/)?.[0]?.replace(/$/, '') }} | {{item.emissionStandard?.label}} | {{ formatToWan(item.mileage) }}公里</div>
<div v-else class="type">{{ item.boardType?.label ? item.boardType?.label+' | ' : ''}} {{item.emissionStandard?.label}}</div>
<div class="date" v-show="activeTab==0 && item.registerDate">注册日期 {{item.registerDate?.substring(0,10)}}</div>
<div v-if="activeTab==0" class="price"><span></span> <span>{{formatNumber(item.minPrice) }}</span> <span></span> </div>
<div v-else class="priceRange">
<span class="num">{{formatNumber(item.minPrice) }}</span> <span class="danwei"></span>
<span class="su">~</span>
<span class="num">{{formatNumber(item.maxPrice) }}</span> <span class="danwei"></span>
<div class="priceWrap" v-if="activeTab==0" >
<div class="price">
售价含税<span></span> <span>{{formatNumber(item.minPrice) }}</span> <span></span>
</div>
<div class="viewNum">{{item.attentionCount}}人想要<span>{{item.browseCount}}人浏览</span></div>
</div>
<div v-else class="priceWrap">
<div class="priceRange">
售价含税
<span class="num">{{formatNumber(item.minPrice) }}</span> <span class="danwei"></span>
<span class="su">~</span>
<span class="num">{{formatNumber(item.maxPrice) }}</span> <span class="danwei"></span>
</div>
<div class="viewNum">{{item.attentionCount}}人想卖<span>{{item.browseCount}}人浏览</span></div>
</div>
<div class="line"></div>
</div>
@ -112,20 +160,74 @@
</div>
</div>
</van-popup>
<van-calendar v-model="showDatePicker" :min-date="minDate"
:max-date="maxDate" type="range" @confirm="onConfirm" />
<van-popup
v-model="areaShow"
position="bottom"
>
<van-area title="标题" :area-list="areaList" :columns-num="2" closeable="true" :value="areaCode ? String(areaCode) : ''"
@cancel="areaShow = false" @confirm="confirmHandle"/>
</van-popup>
</div>
</template>
<script>
import {myMixins} from "@/utils/myMixins"
import {appPageList,userFeedback } from "@/api/secondHandCar"
import {areaList} from "@vant/area-data";
export default {
name: "indexList",
mixins:[myMixins],
data(){
return{
areaList: areaList,
pageList:[],
topSearch:'',
activeTab:0,
isLoading:"",
loading: false,
finished: false,
pageNum:1,
pageSize:10,
total:'',
licenseType:'',
vehicleType:'',
priceSort:'',
emissionStandard:'',
boardType:'',
proprietary: '',
areaCode:'',
areaName:'',
startTime:'',
endTime:'',
licenseTypeOption:[
{value:2,label:'黄牌'},{value:3,label:'绿牌'},{value:1,label:'蓝牌'},
],
vehicleTypeOption:[
{value:1,label:'拖车'},{value:2,label:'地库车'},{value:3,label:'牵引车'},{value:4,label:'随车吊'},{value:5,label:'其他'},
],
priceOption:[
{value:1,label:'5~6'},{value:2,label:'7~8'},{value:3,label:'8~9'}
],
emissionStandardOption:[
{value:1,label:'不限'},{value:3,label:'国三'},{value:4,label:'国四'},{value:5,label:'国五'},{value:6,label:'国六'}
],
boardTypeOption:[
{value:1,label:'全落地'},{value:2,label:'斜落一体'},{value:3,label:'普通斜板'},{value:9,label:'不限'}
],
proprietaryOption: [{value: 1, label: '中道自营'}, {value: 0, label: '服务商发布'}],
poupShow:false,
suggestContent:'',
dateVal: '',
showDatePicker: false,
areaShow:false,
isClearing:false,
minDate: new Date(1970, 0, 1), // 设置最小可选日期1970年1月1日
maxDate: new Date(2099, 11, 31) // 设置最大可选日期2099年12月31日
}
},
watch:{
/* topSearch(){
this.setSearchVal();
this.getList()
},*/
licenseType(){
this.setSearchVal();
this.getList()
@ -142,41 +244,29 @@ export default {
this.setSearchVal();
this.getList()
},
},
data(){
return{
pageList:[],
topSearch:'',
activeTab:0,
isLoading:"",
loading: false,
finished: false,
pageNum:1,
pageSize:10,
total:'',
licenseType:'',
vehicleType:'',
priceSort:'',
emissionStandard:'',
boardType:'',
licenseTypeOption:[
{value:2,label:'黄牌'},{value:3,label:'绿牌'},{value:1,label:'蓝牌'},
],
vehicleTypeOption:[
{value:1,label:'拖车'},{value:2,label:'地库车'},{value:3,label:'牵引车'},{value:4,label:'随车吊'},{value:5,label:'其他'},
],
priceOption:[
{value:1,label:'5~6'},{value:2,label:'7~8'},{value:3,label:'8~9'}
],
emissionStandardOption:[
{value:1,label:'不限'},{value:3,label:'国三'},{value:4,label:'国四'},{value:5,label:'国五'},{value:6,label:'国六'}
],
boardTypeOption:[
{value:1,label:'全落地'},{value:2,label:'斜落地'},{value:3,label:'一般斜板'},{value:9,label:'不限'}
],
poupShow:false,
suggestContent:'',
}
proprietary() {
this.setSearchVal();
this.getList()
},
areaName() {
if (!this.areaName){
this.areaCode=''
}
this.setSearchVal();
this.getList()
},
dateVal(val){
if(val){
let res= this.formatDateTimeRange(val)
this.startTime=res.startTime
this.endTime=res.endTime
}else{
this.startTime=''
this.endTime=''
}
this.setSearchVal();
this.getList()
},
},
mounted() {
this.getSearchVal();
@ -186,12 +276,29 @@ export default {
if (state == 'hidden') { // 用户离开了
}
if (state == 'visible') {
console.log('visible')
// console.log('visible')
}
});
},
methods:{
confirmHandle(val){
if(val[0].name.includes('市')){
this.areaName=val[0].name
this.areaCode=val[0].code
}else{
this.areaName=val[0].name +val[1].name
this.areaCode=val[1].code
}
this.areaShow=false
},
formatDate(date) {
return `${date.getFullYear()}/${date.getMonth() + 1}/${date.getDate()}`;
},
onConfirm(date) {
const [start, end] = date;
this.showDatePicker = false;
this.dateVal = `${this.formatDate(start)} - ${this.formatDate(end)}`;
},
formatToWan(num) {
let result = (num / 10000).toString();
if (result.includes('.')) {
@ -243,6 +350,10 @@ export default {
sessionStorage.setItem('licenseType',String(this.licenseType));
sessionStorage.setItem('emissionStandard',String(this.emissionStandard));
sessionStorage.setItem('boardType',String(this.boardType));
sessionStorage.setItem('proprietary',String(this.proprietary));
sessionStorage.setItem('areaCode',String(this.areaCode));
sessionStorage.setItem('areaName',this.areaName);
sessionStorage.setItem('dateVal',this.dateVal);
},
getSearchVal(){
this.activeTab = Number(sessionStorage.getItem('indexActiveTab')) || 0;
@ -252,6 +363,10 @@ export default {
this.licenseType = Number(sessionStorage.getItem('licenseType')) || '';
this.emissionStandard = Number(sessionStorage.getItem('emissionStandard')) || '';
this.boardType = Number(sessionStorage.getItem('boardType')) || '';
this.proprietary = Number(sessionStorage.getItem('proprietary')) || '';
this.areaCode=Number(sessionStorage.getItem('areaCode')) || '';
this.areaName=sessionStorage.getItem('areaName') || '';
this.dateVal=sessionStorage.getItem('dateVal') || '';
},
goMine(){//我的发布
this.$router.push({ name: "mineRelease"})
@ -291,6 +406,7 @@ export default {
},
onRefresh() {
this.pageNum=1
this.getList()
setTimeout(() => {
this.$toast('刷新成功');
this.isLoading = false;
@ -308,6 +424,10 @@ export default {
priceSort:this.priceSort,
boardType:this.boardType,
emissionStandard:this.emissionStandard,
proprietary: this.proprietary,
areaCode:this.areaCode,
startTime:this.startTime,
endTime:this.endTime,
})
this.total=res.total
if(this.pageNum == 1){// 第一页直接赋值
@ -328,7 +448,18 @@ export default {
window.android.sendMessage("goBack");
}
},
},
formatDateTimeRange(str) {
const [startStr, endStr] = str.split(' - ').map(s => s.trim());
const startDate = new Date(startStr);
const startTime = `${startDate.getFullYear()}-${(startDate.getMonth() + 1).toString().padStart(2, '0')}-${startDate.getDate().toString().padStart(2, '0')} 00:00:00`;
const endDate = new Date(endStr);
const endTime = `${endDate.getFullYear()}-${(endDate.getMonth() + 1).toString().padStart(2, '0')}-${endDate.getDate().toString().padStart(2, '0')} 23:59:59`;
return {
startTime,
endTime
};
},
},
computed:{
show() {
return (this.pageList.length < 0 || this.pageList.length == 0); // 判断数组长度是否大于 0
@ -344,14 +475,18 @@ export default {
width: 100%;
height: 100%;
}
.navBar{
margin-bottom: 46px;
}
.fixImg{
width: 210px;
height: 102px;
position: absolute;
position: fixed;
bottom: 0;
left: 50%;
transform: translateX(-50%);
z-index: 11;
cursor: pointer;
}
.headerWrap{
width: 100%;
@ -413,28 +548,39 @@ export default {
}
}
.filterWrap {
width: 100%;
width: calc(100% - 5px);
padding-right: 5px;
display: flex;
justify-content: space-around;
/*justify-content: space-around;*/
overflow-x: auto; /* 允许横向滚动 */
white-space: nowrap; /* 防止子元素换行 */
padding-bottom: 10px;
-webkit-overflow-scrolling: touch; /* 在iOS上平滑滚动 */
scrollbar-width: none; /* Firefox */
padding-bottom: 10px;
&::-webkit-scrollbar {
display: none; /* Chrome/Safari */
}
.customSel {
width: 69px;
flex: 0 0 auto; /* 防止子元素被压缩 */
width: 80px;
height: 25px;
background: #F5F5F5;
border-radius: 4px;
font-size: 12px;
font-size: 10px;
color: #323233;
margin-left: 5px;
::v-deep .el-input__inner{
padding: 0 2px;
height: 25px;
font-size: 12px;
font-size: 10px;
background: #F5F5F5;
border-radius: 4px;
border: none;
}
::v-deep .el-input__icon{
line-height: 25px;
font-size: 12px;
font-size: 10px;
width: 18px;
color: #2A5094;
}
@ -442,6 +588,9 @@ export default {
right: 2px;
}
}
.customInput{
width: 130px;
}
.has-value ::v-deep .el-input__inner{
background: #F1F6FF ;
color: #007BE9;
@ -470,7 +619,7 @@ export default {
}
.contentWrap{
width: 100%;
height: calc(100% - 80px);
height: calc(100% - 126px);
overflow-y: auto;
background-color: #F2F2F2 ;
box-sizing: border-box;
@ -485,8 +634,12 @@ export default {
.item{
display: flex;
justify-content: space-between;
cursor: pointer;
}
.left{
width: 115px;
height: 77px;
position: relative;
.img, .qiugou{
width: 115px;
height: 77px;
@ -501,6 +654,24 @@ export default {
letter-spacing: 5px;
background-color: #6C81CD;
}
.img {
object-fit: cover; /* 保持比例填充容器,裁剪多余部分 */
object-position: center; /* 居中显示 */
}
.owner_logo {
width: 60px;
height: 23px;
position: absolute;
left: -4px;
top: -3px;
}
.saled_logo {
width: 76px;
height: 48px;
position: absolute;
left: 24px;
top: 16px;
}
}
.right{
.title{
@ -543,6 +714,18 @@ export default {
line-height: 16px;
}
}
.priceWrap{
/* display: flex;
justify-content: space-between;
align-items: center;*/
.viewNum{
//color: #ccc;
margin-right: 15px;
span{
margin-left: 10px;
}
}
}
.priceRange{
color: #FF5533;
display: flex;

View File

@ -40,8 +40,9 @@
<div v-else class="type">{{ item.boardType?.label ? item.boardType?.label+' | ' : ''}}
{{item.vehicleType }} | {{item.emissionStandard?.label}}</div>
<div v-if="item.type==1" class="price"><span>{{formatNumber(item.minPrice) }}</span> <span></span> </div>
<div v-if="item.type==1" class="price">售价含税<span>{{formatNumber(item.minPrice) }}</span> <span></span> </div>
<div v-else class="priceRange">
售价含税
<span class="num">{{formatNumber(item.minPrice) }}</span> <span class="danwei"></span>
<span class="su">~</span>
<span class="num">{{formatNumber(item.maxPrice) }}</span> <span class="danwei"></span>
@ -328,6 +329,8 @@ export default {
height: 77px;
border-radius: 7px;
margin-right: 10px;
object-fit: cover;
object-position: center;
}
.smallImg{
position: absolute;

View File

@ -24,7 +24,7 @@
<span> <span class="star">*</span>求购类型 </span>
<div class="radioWrap">
<van-radio-group v-model="form.vehicleType" direction="horizontal">
<van-radio name="拖车" :class="{'checked':form.vehicleType=='拖车','vehicleRadio':true}">拖车</van-radio>
<van-radio name="拖车" :class="{'checked':form.vehicleType=='拖车','vehicleRadio':true}">平板拖车</van-radio>
<van-radio name="地库车" :class="{'checked':form.vehicleType=='地库车','vehicleRadio':true}">地库车</van-radio>
<van-radio name="牵引车" :class="{'checked':form.vehicleType=='牵引车','vehicleRadio':true}">牵引车</van-radio>
<van-radio name="随车吊" :class="{'checked':form.vehicleType=='随车吊','vehicleRadio':true}">随车吊</van-radio>
@ -41,8 +41,8 @@
<span> <span class="star">*</span>落板方式 </span>
<van-radio-group v-model="form.boardType" direction="horizontal" class="radioWrap">
<van-radio name="1" :class="{'checked':form.boardType==1}">全落地</van-radio>
<van-radio name="2" :class="{'checked':form.boardType==2}">斜落</van-radio>
<van-radio name="3" :class="{'checked':form.boardType==3}">一般平</van-radio>
<van-radio name="2" :class="{'checked':form.boardType==2}">斜落一体</van-radio>
<van-radio name="3" :class="{'checked':form.boardType==3}">普通斜</van-radio>
<van-radio name="9" :class="{'checked':form.boardType==9}">不限</van-radio>
</van-radio-group>
</div>
@ -93,7 +93,7 @@
<img v-show="radio==1" @click="radio=0" class="radioIcon" src="@/assets/secondHandCar/checked.png" />
<img v-show="radio==0" @click="radio=1" class="radioIcon" src="@/assets/secondHandCar/uncheck.png" />
<span>我已阅读并同意</span>
<span @click="viewPrivacy">二手车交易条款</span>
<span @click="viewPrivacy">二手车交易条款</span>
</div>
<div class="btnWrap" >
<div v-if="type==1" class="btn commonBtn" @click="noMultipleClicks(submitHandle)">发布</div>

View File

@ -14,10 +14,14 @@
<div class="time">
<span>{{ detailInfo.createTime?.substring(0,10) }}</span><span>发布</span>
</div>
<div class="price">
<span class="num">{{formatNumber(detailInfo.minPrice) }}</span> <span class="danwei"></span>
<span class="su">~</span>
<span class="num">{{formatNumber(detailInfo.maxPrice) }}</span> <span class="danwei"></span>
<div class="priceWrap">
<div class="price">
售价含税
<span class="num">{{formatNumber(detailInfo.minPrice) }}</span> <span class="danwei"></span>
<span class="su">~</span>
<span class="num">{{formatNumber(detailInfo.maxPrice) }}</span> <span class="danwei"></span>
</div>
<div class="viewNum">{{detailInfo.attentionCount}}人想卖<span>{{detailInfo.browseCount}}人浏览</span></div>
</div>
</div>
<div class="detailInfoWrap wrapCommon">
@ -29,12 +33,12 @@
<el-tooltip class="item" effect="dark" :content="detailInfo.vehicleType" placement="top">
<span style="cursor: pointer">{{ detailInfo.vehicleType }}</span>
</el-tooltip>
<span>车类型</span>
<span>类型</span>
</div>
<div class="suGang"></div>
<div class="itemInfo">
<span>{{ detailInfo.boardType?.label }}&nbsp;&nbsp;</span>
<span>拖车落板</span>
<span>落板方式</span>
</div>
<div class="suGang"></div>
<div class="itemInfo">
@ -68,6 +72,7 @@ export default {
duration:'',
startTime: null, // 记录进入时间
isList:false,
recordResponseId:'',//信息记录获取的id用于关闭界面掉接口所需参数
}
},
async mounted() {
@ -88,6 +93,8 @@ export default {
queryType: this.queryType,
})
this.detailInfo = res?.data
let result=await saveRecord({type: 1, carInfoId: this.id, duration:'',id:''});
this.recordResponseId=result?.data?.id
}
},
destroyed() {
@ -100,16 +107,18 @@ export default {
this.saveRecord(duration,type);
},
async saveRecord(duration,type){
await saveRecord({type:type,carInfoId:this.id,duration})
await saveRecord({type:type,carInfoId:this.id,duration,id:this.recordResponseId || ''})
},
handle(){
this.getDuration(2)
Dialog.alert({
message:this.detailInfo.contactNumber ,
confirmButtonText:'拨打电话',
confirmButtonText:this.isWebFunc() ? '确定' : '拨打电话',
showCancelButton:true,
}).then(() => {
window.location.href = `tel:${this.detailInfo.contactNumber}`;
if(!this.isWebFunc()){
window.location.href = `tel:${this.detailInfo.contactNumber}`;
}
}).catch(() => {
// on cancel
});
@ -179,6 +188,18 @@ export default {
margin-right: 20px;
}
}
.priceWrap{
display: flex;
justify-content: space-between;
align-items: center;
.viewNum{
//color: #ccc;
margin-right: 15px;
span{
margin-left: 10px;
}
}
}
.price{
color: #FF5533;
font-weight: 600;