ceshui
This commit is contained in:
parent
96d0fb5e81
commit
3558026d1e
29
App.vue
29
App.vue
@ -2,7 +2,10 @@
|
|||||||
//#ifdef APP-PLUS
|
//#ifdef APP-PLUS
|
||||||
const jpushModule = uni.requireNativePlugin("JG-JPush");
|
const jpushModule = uni.requireNativePlugin("JG-JPush");
|
||||||
// #endif
|
// #endif
|
||||||
import { loginShopAccount, userInfo } from "@/api/oaUser.js"
|
import {
|
||||||
|
loginShopAccount,
|
||||||
|
userInfo
|
||||||
|
} from "@/api/oaUser.js"
|
||||||
export default {
|
export default {
|
||||||
onLaunch: async function(info) {
|
onLaunch: async function(info) {
|
||||||
// let noticeArr = []
|
// let noticeArr = []
|
||||||
@ -21,17 +24,19 @@
|
|||||||
// uni.showModal({
|
// uni.showModal({
|
||||||
// content: info.referrerInfo.extraData
|
// content: info.referrerInfo.extraData
|
||||||
// })
|
// })
|
||||||
// console.log('App Launch:',info);
|
// console.log('App Launch:',info);
|
||||||
if (info.referrerInfo?.extraData?.uniMP) {
|
if (info.referrerInfo?.extraData?.uniMP) {
|
||||||
//监听宿主App通讯数据
|
//监听宿主App通讯数据
|
||||||
|
//#ifdef APP-PLUS
|
||||||
uni.onHostEventReceive((event, data) => {
|
uni.onHostEventReceive((event, data) => {
|
||||||
if(event=='getLocation') uni.$emit('uniMP_getLocation', data);
|
if (event == 'getLocation') uni.$emit('uniMP_getLocation', data);
|
||||||
else if(event=='im'){
|
else if (event == 'im') {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url:'/subpkg/chatMang/index'
|
url: '/subpkg/chatMang/index'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
// #endif
|
||||||
uni.setStorageSync('uniMP', info.referrerInfo?.extraData?.uniMP);
|
uni.setStorageSync('uniMP', info.referrerInfo?.extraData?.uniMP);
|
||||||
uni.setStorageSync('APP_token', info.referrerInfo?.extraData?.token);
|
uni.setStorageSync('APP_token', info.referrerInfo?.extraData?.token);
|
||||||
try {
|
try {
|
||||||
@ -76,23 +81,25 @@
|
|||||||
// // 设置音频文件地址
|
// // 设置音频文件地址
|
||||||
// audioContext.src = '/static/mp3/order.mp3'
|
// audioContext.src = '/static/mp3/order.mp3'
|
||||||
// 播放音频
|
// 播放音频
|
||||||
uni.onHostEventReceive((event,data)=>{
|
//#ifdef APP-PLUS
|
||||||
if(event=='im'){
|
uni.onHostEventReceive((event, data) => {
|
||||||
|
if (event == 'im') {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url:'/subpkg/chatMang/index'
|
url: '/subpkg/chatMang/index'
|
||||||
})
|
})
|
||||||
}else if(event=='re_id'){
|
} else if (event == 're_id') {
|
||||||
uni.setStorageSync("re_id",data)
|
uni.setStorageSync("re_id", data)
|
||||||
}
|
}
|
||||||
// console.log('Receive event('+event+') from HOST: '+JSON.stringify(data));
|
// console.log('Receive event('+event+') from HOST: '+JSON.stringify(data));
|
||||||
|
|
||||||
|
|
||||||
});
|
});
|
||||||
|
// #endif
|
||||||
//#ifdef APP-PLUS
|
//#ifdef APP-PLUS
|
||||||
jpushModule.initJPushService()
|
jpushModule.initJPushService()
|
||||||
jpushModule.addNotificationListener(res => {
|
jpushModule.addNotificationListener(res => {
|
||||||
const audioContext = uni.createInnerAudioContext()
|
const audioContext = uni.createInnerAudioContext()
|
||||||
if(res.content.includes(':')){
|
if (res.content.includes(':')) {
|
||||||
audioContext.src = '/static/mp3/im.wav'
|
audioContext.src = '/static/mp3/im.wav'
|
||||||
audioContext.play()
|
audioContext.play()
|
||||||
uni.vibrateLong();
|
uni.vibrateLong();
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import oahttp from "@/utils/oahttp.js";
|
import oahttp from "@/utils/oahttp.js";
|
||||||
import oahttp2 from "@/utils/logistics.js";
|
|
||||||
// http://logistics.lihaink.cn/api/getCarHistory
|
// http://logistics.lihaink.cn/api/getCarHistory
|
||||||
/**
|
/**
|
||||||
* 车辆列表
|
* 车辆列表
|
||||||
@ -15,9 +15,9 @@ export const applycarApi = (data) => oahttp.post('/vehicle/rentApply', data)
|
|||||||
// 显示轨迹
|
// 显示轨迹
|
||||||
export const locusApi = (data) => oahttp.post('/vehicle/vehicleTrack', data)
|
export const locusApi = (data) => oahttp.post('/vehicle/vehicleTrack', data)
|
||||||
// 获取可购买车辆列表
|
// 获取可购买车辆列表
|
||||||
export const canBuyCarListApi = (data) => oahttp.post('/vehicle/vehicleTrack', data)
|
export const canBuyCarListApi = (data) => oahttp.get('/vehicle/getFreeCars', data)
|
||||||
// 购买车辆
|
// 购买车辆
|
||||||
export const buyCarApi = (data) => oahttp.post('/vehicle/vehicleTrack', data)
|
export const buyCarApi = (data) => oahttp.post('/vehicle/buyCars', data)
|
||||||
// 当前车辆位置信息
|
// 当前车辆位置信息
|
||||||
// export const locusApi = (data) => oahttp.post('/vehicle/vehicleTrack', data)
|
// export const locusApi = (data) => oahttp.post('/vehicle/vehicleTrack', data)
|
||||||
// api / getCarLocal
|
// api / getCarLocal
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
let httpApiThree;
|
let httpApiThree;
|
||||||
let httpApi; // 总域名
|
let httpApi; // 总域名
|
||||||
let httpApiTwo; // 物流系统域名
|
let httpApiTwo; // 物流系统域名
|
||||||
let httpApiTest
|
|
||||||
|
|
||||||
const env = 'dev'; // 开发
|
const env = 'dev'; // 开发
|
||||||
// const env = 'prod'; // 生产
|
// const env = 'prod'; // 生产
|
||||||
@ -22,7 +22,7 @@ switch (env) {
|
|||||||
httpApi = 'https://ceshi-worker-task.lihaink.cn' //测试
|
httpApi = 'https://ceshi-worker-task.lihaink.cn' //测试
|
||||||
httpApiThree = 'https://ceshi-worker-task.lihaink.cn' //测试
|
httpApiThree = 'https://ceshi-worker-task.lihaink.cn' //测试
|
||||||
httpApiTwo = 'https://ceshi-logistics.lihaink.cn' //测试环境
|
httpApiTwo = 'https://ceshi-logistics.lihaink.cn' //测试环境
|
||||||
httpApiTest = 'http://192.168.1.11:8081' //测试环境
|
//测试环境
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -50,7 +50,7 @@ module.exports = {
|
|||||||
HTTP_REQUEST_URL: httpApi,
|
HTTP_REQUEST_URL: httpApi,
|
||||||
HTTP_REQUEST_URL_THREE: httpApiThree,
|
HTTP_REQUEST_URL_THREE: httpApiThree,
|
||||||
HTTP_REQUEST_URL_TWO: httpApiTwo,
|
HTTP_REQUEST_URL_TWO: httpApiTwo,
|
||||||
httpApiTest: httpApiTest,
|
|
||||||
|
|
||||||
// #ifdef H5
|
// #ifdef H5
|
||||||
//H5接口是浏览器地址
|
//H5接口是浏览器地址
|
||||||
|
@ -13,9 +13,15 @@
|
|||||||
{{item.create_time.slice(0, 10)}}
|
{{item.create_time.slice(0, 10)}}
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="">
|
<view class="" v-if="item.type==0">
|
||||||
{{item.company_b_name}}提出租赁车辆一辆
|
{{item.company_b_name}}提出租赁车辆一辆
|
||||||
</view>
|
</view>
|
||||||
|
<view class="" v-if="item.type==1">
|
||||||
|
{{item.company_b_name}}上传自有车辆一辆
|
||||||
|
</view>
|
||||||
|
<view class="" v-if="item.type==2">
|
||||||
|
{{item.company_b_name}}提出解除租赁
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
@ -64,6 +70,10 @@
|
|||||||
background-color: #FF7C32;
|
background-color: #FF7C32;
|
||||||
color: white;
|
color: white;
|
||||||
padding: 0 10rpx;
|
padding: 0 10rpx;
|
||||||
|
font-size: 24rpx;
|
||||||
|
// line-height: rpx;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
width: 200rpx;
|
width: 200rpx;
|
||||||
height: 50rpx;
|
height: 50rpx;
|
||||||
margin-right: 10rpx;
|
margin-right: 10rpx;
|
||||||
|
@ -13,29 +13,33 @@
|
|||||||
<view class="car-info">
|
<view class="car-info">
|
||||||
<view class="car-info-l">
|
<view class="car-info-l">
|
||||||
<view class="">
|
<view class="">
|
||||||
<u--image :src="a" width="150rpx" height="150rpx" style="margin-right:20rpx"></u--image>
|
<u--image :src="item.pic" width="150rpx" height="150rpx" style="margin-right:20rpx"></u--image>
|
||||||
</view>
|
</view>
|
||||||
<view class="car-info-c">
|
<view class="car-info-c">
|
||||||
<view class="lincense">
|
<view class="lincense">
|
||||||
车牌号: {{item.lincense}}
|
车牌号: {{item.license}}
|
||||||
</view>
|
</view>
|
||||||
<view class="lincense">
|
<!-- <view class="lincense">
|
||||||
行驶里程: 1212KM
|
行驶里程: 1212KM
|
||||||
|
</view> -->
|
||||||
|
<view class="lincense" v-if="item.flag">
|
||||||
|
当前状态: 当前使用中
|
||||||
</view>
|
</view>
|
||||||
<view class="lincense">
|
<view class="lincense" v-else>
|
||||||
当前状态: 平台公司闲置中
|
当前状态: 闲置中
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- -->
|
<!-- -->
|
||||||
<view class="car-info-r">
|
<view class="car-info-r">
|
||||||
<view class="" style="margin: 10rpx 50rpx;">
|
<view class="" style="margin: 10rpx 50rpx;">
|
||||||
<u-checkbox-group v-model="item.checked" placement="column" @change="checkboxChange(index)">
|
<u-checkbox-group v-model="item.checked" placement="column" @change="checkboxChange(item.id)">
|
||||||
<u-checkbox>
|
<u-checkbox>
|
||||||
</u-checkbox>
|
</u-checkbox>
|
||||||
</u-checkbox-group>
|
</u-checkbox-group>
|
||||||
</view>
|
</view>
|
||||||
<view class="" v-show="index==carCheckedArr[0]">
|
<view class="" v-show="item.id==carCheckedArr[0]">
|
||||||
选择该车辆为监管车辆
|
选择该车辆为监管车辆
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -55,12 +59,12 @@
|
|||||||
<u-popup :show="showPop" mode="bottom" @close="close" @open="open">
|
<u-popup :show="showPop" mode="bottom" @close="close" @open="open">
|
||||||
<view class="pop">
|
<view class="pop">
|
||||||
<view class="check-car-list" v-for="item,index in carList" v-show="item.checked.length" :key="index">
|
<view class="check-car-list" v-for="item,index in carList" v-show="item.checked.length" :key="index">
|
||||||
<u--image :src="a" width="150rpx" height="150rpx"></u--image>
|
<u--image :src="item.pic" width="150rpx" height="150rpx"></u--image>
|
||||||
<view class="" style="margin-top: 10rpx;">
|
<view class="" style="margin-top: 10rpx;">
|
||||||
{{item.lincense}}
|
{{item.license}}
|
||||||
</view>
|
</view>
|
||||||
<view class="pop-check">
|
<view class="pop-check">
|
||||||
<u-checkbox-group v-model="item.checked" @change="popChange(index)">
|
<u-checkbox-group v-model="item.checked" @change="popChange(item.id)">
|
||||||
<u-checkbox>
|
<u-checkbox>
|
||||||
</u-checkbox>
|
</u-checkbox>
|
||||||
</u-checkbox-group>
|
</u-checkbox-group>
|
||||||
@ -86,53 +90,54 @@
|
|||||||
queryCar: '',
|
queryCar: '',
|
||||||
a: "https://tse3-mm.cn.bing.net/th/id/OIP-C.0xzWZj1_A-nzJiUBxrk8XQHaEo?w=298&h=186&c=7&r=0&o=5&pid=1.7",
|
a: "https://tse3-mm.cn.bing.net/th/id/OIP-C.0xzWZj1_A-nzJiUBxrk8XQHaEo?w=298&h=186&c=7&r=0&o=5&pid=1.7",
|
||||||
carList: [],
|
carList: [],
|
||||||
carListI: [{
|
carListI: [],
|
||||||
checked: [],
|
|
||||||
lincense: '川Y103D1'
|
|
||||||
}, {
|
|
||||||
checked: [],
|
|
||||||
lincense: '川Y103D6'
|
|
||||||
}, {
|
|
||||||
checked: [],
|
|
||||||
lincense: '川Y103D5'
|
|
||||||
}, {
|
|
||||||
checked: [],
|
|
||||||
lincense: '川Y103D4'
|
|
||||||
}, {
|
|
||||||
checked: [],
|
|
||||||
lincense: '川Y103D3'
|
|
||||||
}, {
|
|
||||||
checked: [],
|
|
||||||
lincense: '川Y103D2'
|
|
||||||
}],
|
|
||||||
showPop: false,
|
showPop: false,
|
||||||
carCheckeList: [1, 1, 1, 1, 1, 1, 1, 1],
|
carCheckeList: [],
|
||||||
carCheckedArr: []
|
carCheckedArr: []
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
buyCarFn() {
|
buyCarFn() {
|
||||||
|
|
||||||
|
|
||||||
if (this.carCheckedArr.length == 0) {
|
if (this.carCheckedArr.length == 0) {
|
||||||
Toast("请先选择车辆!")
|
Toast("请先选择车辆!")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
// buyCarApi({}).then(res => {
|
|
||||||
// Toast("购买成功!")
|
let data = []
|
||||||
// setTimeout(() => {
|
this.carList.forEach(item => {
|
||||||
|
this.carCheckedArr.forEach(items => {
|
||||||
|
if (item.id == items) {
|
||||||
|
data.push({
|
||||||
|
id: item.id,
|
||||||
|
license: item.license
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
let datas = JSON.stringify(data)
|
||||||
|
|
||||||
|
buyCarApi({
|
||||||
|
cars: datas
|
||||||
|
}).then(res => {
|
||||||
|
Toast("申请成功!")
|
||||||
|
setTimeout(() => {
|
||||||
|
uni.redirectTo({
|
||||||
|
url: '/subpkg/property/index'
|
||||||
|
})
|
||||||
|
}, 1000)
|
||||||
|
|
||||||
|
})
|
||||||
// uni.navigateTo({
|
// uni.navigateTo({
|
||||||
// url: '/subpkg/property/index'
|
// url: '/subpkg/property/index'
|
||||||
// })
|
// })
|
||||||
// }, 500)
|
|
||||||
|
|
||||||
// })
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/subpkg/property/index'
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
queryCarFn() {
|
queryCarFn() {
|
||||||
this.carList = []
|
this.carList = []
|
||||||
this.carListI.forEach(item => {
|
this.carListI.forEach(item => {
|
||||||
if (item.lincense.includes(this.queryCar)) {
|
// console.log(item.license)
|
||||||
|
if (item.license.includes(this.queryCar)) {
|
||||||
this.carList.push(item)
|
this.carList.push(item)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -147,11 +152,11 @@
|
|||||||
} else {
|
} else {
|
||||||
this.carCheckedArr.push(i)
|
this.carCheckedArr.push(i)
|
||||||
}
|
}
|
||||||
// console.log(this.carCheckedArr)
|
console.log(this.carCheckedArr)
|
||||||
},
|
},
|
||||||
popChange(index) {
|
popChange(index) {
|
||||||
this.checkboxChange(index)
|
this.checkboxChange(index)
|
||||||
console.log(this.carCheckedArr)
|
// console.log(this.carCheckedArr)
|
||||||
},
|
},
|
||||||
close() {
|
close() {
|
||||||
this.showPop = false
|
this.showPop = false
|
||||||
@ -165,11 +170,18 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
onLoad() {
|
onLoad(option) {
|
||||||
// canBuyCarListApi({}).then(res => {
|
// console.log(option.license)
|
||||||
// this.carListI = res.data
|
canBuyCarListApi().then(res => {
|
||||||
// })
|
res.data.forEach(item => {
|
||||||
|
if (item.license == option.license) {
|
||||||
|
item.flag = true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
this.carListI = res.data
|
||||||
this.carList = Array.from(this.carListI);
|
this.carList = Array.from(this.carListI);
|
||||||
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -185,7 +197,6 @@
|
|||||||
padding: 20rpx;
|
padding: 20rpx;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
|
|
||||||
// padding-bottom: 200rpx;
|
|
||||||
.car-info {
|
.car-info {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
@ -220,7 +231,7 @@
|
|||||||
// margin-right: 30rpx;
|
// margin-right: 30rpx;
|
||||||
width: 182.5rpx;
|
width: 182.5rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
// justify-content: ;
|
// justify-tent: ;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
position: relative;
|
position: relative;
|
||||||
@ -238,7 +249,7 @@
|
|||||||
height: 100rpx;
|
height: 100rpx;
|
||||||
position: fixed;
|
position: fixed;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
z-index: 1000000;
|
z-index: 1000;
|
||||||
width: 100vw;
|
width: 100vw;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
border-radius: 30rpx 30rpx 0 0;
|
border-radius: 30rpx 30rpx 0 0;
|
||||||
|
@ -46,12 +46,12 @@
|
|||||||
<view class="car_type">
|
<view class="car_type">
|
||||||
<text>自有车辆</text>
|
<text>自有车辆</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="car_li">
|
<view class="car_li" v-for="(item,index) in dataList.cars_info">
|
||||||
<view class="" style="display: flex;justify-content: space-between;align-items: center;">
|
<view class="" style="display: flex;justify-content: space-between;align-items: center;">
|
||||||
<view class="" style="display: flex;align-items: center;">
|
<view class="" style="display: flex;align-items: center;">
|
||||||
<u--image :src="dataList.cars_info.pic" width="100rpx" height="100rpx"></u--image>
|
<u--image :src="item.pic" width="100rpx" height="100rpx"></u--image>
|
||||||
<view class="" style="margin-left: 10rpx;">
|
<view class="" style="margin-left: 10rpx;">
|
||||||
车牌号:{{dataList.cars_info.license}}
|
车牌号:{{item.license}}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@ -133,7 +133,7 @@
|
|||||||
<view class="name">{{typeFn( dataList.type) }}
|
<view class="name">{{typeFn( dataList.type) }}
|
||||||
</view>
|
</view>
|
||||||
<view>
|
<view>
|
||||||
<text>{{'2023-03-03'}}</text>
|
<text>{{dataList.update_time}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -202,11 +202,11 @@
|
|||||||
this.dataList = res.data.vehicleContract
|
this.dataList = res.data.vehicleContract
|
||||||
this.carList = res.data.vehicleRentCars
|
this.carList = res.data.vehicleRentCars
|
||||||
this.checked = [this.carList[0]?.car_id] || ''
|
this.checked = [this.carList[0]?.car_id] || ''
|
||||||
this.dataList.cars_info = JSON.parse(this.dataList.cars_info) || ""
|
|
||||||
// if (this.dataList.status == 3) {
|
// if (this.dataList.status == 3) {
|
||||||
// uni.navigateBack()
|
// uni.navigateBack()
|
||||||
// }
|
// }
|
||||||
console.log(this.dataList.cars_info.pic)
|
|
||||||
if (this.carList.length > 0 || this.dataList.cars_info) {
|
if (this.carList.length > 0 || this.dataList.cars_info) {
|
||||||
this.flag1 = false
|
this.flag1 = false
|
||||||
}
|
}
|
||||||
@ -244,7 +244,7 @@
|
|||||||
return "租赁合同"
|
return "租赁合同"
|
||||||
}
|
}
|
||||||
if (status == 1) {
|
if (status == 1) {
|
||||||
return "自有车两"
|
return "自有车辆"
|
||||||
}
|
}
|
||||||
if (status == 2) {
|
if (status == 2) {
|
||||||
"解除合同"
|
"解除合同"
|
||||||
|
@ -30,7 +30,7 @@
|
|||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
datasList: [1, 2, 3],
|
datasList: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
<u-loading-page :loading="showLoading"></u-loading-page>
|
<u-loading-page :loading="showLoading"></u-loading-page>
|
||||||
</view>
|
</view>
|
||||||
<view class="" v-else>
|
<view class="" v-else>
|
||||||
|
|
||||||
<!-- 小组公司 -->
|
<!-- 小组公司 -->
|
||||||
<view class="noCar" v-if='company_type==18'>
|
<view class="noCar" v-if='company_type==18'>
|
||||||
<!-- 申请 -->
|
<!-- 申请 -->
|
||||||
@ -43,7 +44,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="uplode" v-else>
|
<view class="uplode" v-else>
|
||||||
<u-icon name="plus-circle-fill" color="#0022C7" size="28"></u-icon>
|
<u-icon name="plus-circle-fill" color="#0022C7" size="28"></u-icon>
|
||||||
上传头像
|
上传车辆图片
|
||||||
<view class="up" style="opacity: 0;">
|
<view class="up" style="opacity: 0;">
|
||||||
<u-upload :fileList="imgUrl?[{url:imgUrl}]:[]"
|
<u-upload :fileList="imgUrl?[{url:imgUrl}]:[]"
|
||||||
@afterRead="afterReadAvatar" :maxCount="1">
|
@afterRead="afterReadAvatar" :maxCount="1">
|
||||||
@ -59,8 +60,6 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</u-modal>
|
</u-modal>
|
||||||
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 等待 -->
|
<!-- 等待 -->
|
||||||
@ -77,6 +76,7 @@
|
|||||||
<span class="dots">...</span>
|
<span class="dots">...</span>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 申请用车 -->
|
<!-- 申请用车 -->
|
||||||
<view v-if="datas.type ==0">
|
<view v-if="datas.type ==0">
|
||||||
<view class="loading">
|
<view class="loading">
|
||||||
@ -85,11 +85,10 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 购买车辆 -->
|
<!-- 购买车辆 -->
|
||||||
<view class="loading" v-if="datas.type==999999999999999">
|
<view class="loading" v-if="datas.type==3">
|
||||||
<span>您的购车申请已经提交,我们正在加快审核中,请耐心等待,在此期间您可以继续使用车辆完成配送任务哦~</span>
|
<span>您的购车申请已经提交,我们正在加快审核中,请耐心等待,在此期间您可以继续使用车辆完成配送任务哦~</span>
|
||||||
<span class="dots">...</span>
|
<span class="dots">...</span>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 审核结束 -->
|
<!-- 审核结束 -->
|
||||||
@ -106,16 +105,16 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="">
|
<view class="">
|
||||||
|
<mytn text='购买车辆' class="buyCar" :position="false" @click="navgo('/subpkg/property/buyCar')">
|
||||||
|
</mytn>
|
||||||
<view class="" style="margin: 20rpx 0;">
|
<view class="" style="margin: 20rpx 0;">
|
||||||
|
|
||||||
<mytn text='上传自有车辆' @click="show=true"></mytn>
|
<mytn text='上传自有车辆' @click="show=true"></mytn>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="">
|
<view class="">
|
||||||
|
|
||||||
|
|
||||||
<mytn text='申请用车' :position="false" class="upCar" @click="applycarFn"></mytn>
|
<mytn text='申请用车' :position="false" class="upCar" @click="applycarFn"></mytn>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<u-modal :show="show" @close="show=false" :showCancelButton="true" @confirm="upCarFn"
|
<u-modal :show="show" @close="show=false" :showCancelButton="true" @confirm="upCarFn"
|
||||||
:closeOnClickOverlay="true" @cancel="show=false" title="车辆上传">
|
:closeOnClickOverlay="true" @cancel="show=false" title="车辆上传">
|
||||||
<view class="slot-content">
|
<view class="slot-content">
|
||||||
@ -139,7 +138,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="uplode" v-else>
|
<view class="uplode" v-else>
|
||||||
<u-icon name="plus-circle-fill" color="#0022C7" size="28"></u-icon>
|
<u-icon name="plus-circle-fill" color="#0022C7" size="28"></u-icon>
|
||||||
上传头像
|
上传车辆图片
|
||||||
<view class="up" style="opacity: 0;">
|
<view class="up" style="opacity: 0;">
|
||||||
<u-upload :fileList="imgUrl?[{url:imgUrl}]:[]"
|
<u-upload :fileList="imgUrl?[{url:imgUrl}]:[]"
|
||||||
@afterRead="afterReadAvatar" :maxCount="1">
|
@afterRead="afterReadAvatar" :maxCount="1">
|
||||||
@ -213,7 +212,6 @@
|
|||||||
<u-icon name="arrow-right"></u-icon>
|
<u-icon name="arrow-right"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="personnel_list">
|
<view class="personnel_list">
|
||||||
@ -309,7 +307,7 @@
|
|||||||
leaseApi,
|
leaseApi,
|
||||||
upVehicleApi,
|
upVehicleApi,
|
||||||
getAgencyDetailApi,
|
getAgencyDetailApi,
|
||||||
getvehicleDetailApi,
|
// getvehicleDetailApi,
|
||||||
villageCompanyApi,
|
villageCompanyApi,
|
||||||
|
|
||||||
} from "@/api/property.js"
|
} from "@/api/property.js"
|
||||||
@ -352,7 +350,7 @@
|
|||||||
},
|
},
|
||||||
|
|
||||||
onLoad() {
|
onLoad() {
|
||||||
this.initIndex()
|
// this.initIndex()
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
this.flag = true
|
this.flag = true
|
||||||
})
|
})
|
||||||
@ -368,21 +366,27 @@
|
|||||||
methods: {
|
methods: {
|
||||||
// 初始化页面
|
// 初始化页面
|
||||||
initIndex() {
|
initIndex() {
|
||||||
let type = (JSON.parse(Cache.get("USER_INFO")).company.company_type)
|
let type = this.$store.state.app.userInfo.company.company_type
|
||||||
|
|
||||||
this.company_type = type
|
this.company_type = type
|
||||||
// 小组公司
|
// 小组公司
|
||||||
if (type == 18) {
|
if (type == 18) {
|
||||||
villageCompanyApi().then(res => {
|
villageCompanyApi().then(res => {
|
||||||
this.showLoading = false
|
this.showLoading = false
|
||||||
this.datas = res.data
|
this.datas = res.data
|
||||||
this.step = res.data?.status || 9999
|
console.log(res.data?.id)
|
||||||
|
if (res.data?.id) {
|
||||||
|
this.step = res.data?.status
|
||||||
|
} else {
|
||||||
|
this.step = 9999
|
||||||
|
|
||||||
|
}
|
||||||
if (this.step == 3) {
|
if (this.step == 3) {
|
||||||
uni.redirectTo({
|
uni.redirectTo({
|
||||||
url: `/subpkg/property/vehicle_a?id=${res.data.cars_info.id}`
|
url: `/subpkg/property/vehicle_a?id=${res.data.cars_info.id}`
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
// 镇街公司
|
// 镇街公司
|
||||||
else {
|
else {
|
||||||
@ -441,7 +445,6 @@
|
|||||||
})
|
})
|
||||||
}, 2000)
|
}, 2000)
|
||||||
})
|
})
|
||||||
|
|
||||||
this.show = false
|
this.show = false
|
||||||
this.noInfo = false
|
this.noInfo = false
|
||||||
|
|
||||||
|
@ -24,7 +24,9 @@
|
|||||||
<view class="right">
|
<view class="right">
|
||||||
<view class="li" style="display: flex;justify-content: space-between;">
|
<view class="li" style="display: flex;justify-content: space-between;">
|
||||||
<text>行驶总里程: {{datas.mileage}}</text>
|
<text>行驶总里程: {{datas.mileage}}</text>
|
||||||
<text v-if="datas.type" style="color: green;">自有车辆</text>
|
<text v-if="datas.type==2" style="color: green;">购买车辆</text>
|
||||||
|
<text v-if="datas.type==0" style="color: green;">租赁车辆</text>
|
||||||
|
<text v-if="datas.type==1" style="color: green;">自有车辆</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="li">
|
<view class="li">
|
||||||
<text>承租公司: </text>
|
<text>承租公司: </text>
|
||||||
@ -68,7 +70,9 @@
|
|||||||
<u--image :showLoading="true" src="../../static/img/contract/pdf.png" width="80px"
|
<u--image :showLoading="true" src="../../static/img/contract/pdf.png" width="80px"
|
||||||
height="80px"></u--image>
|
height="80px"></u--image>
|
||||||
<view class="text">
|
<view class="text">
|
||||||
<view class="name">《租赁合同》</view>
|
<view class="name" v-if="datas.type==0">《租赁合同》</view>
|
||||||
|
<view class="name" v-if="datas.type==1">《自有车辆合同》</view>
|
||||||
|
<view class="name" v-if="datas.type==2">《购车合同》</view>
|
||||||
<!-- <view class="name">《购买合同》</view> -->
|
<!-- <view class="name">《购买合同》</view> -->
|
||||||
<view>
|
<view>
|
||||||
<text>{{ datas.create_time}}</text>
|
<text>{{ datas.create_time}}</text>
|
||||||
@ -85,7 +89,8 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
|
||||||
<mybtn text="购买车辆" @click="navTo('/subpkg/property/buyCar')"></mybtn>
|
<mybtn text="购买车辆" @click="navTo2(`/subpkg/property/buyCar?license=${datas.car_license}`)"
|
||||||
|
v-if="company_type==18"></mybtn>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@ -173,6 +178,11 @@
|
|||||||
url
|
url
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
navTo2(url) {
|
||||||
|
uni.redirectTo({
|
||||||
|
url
|
||||||
|
})
|
||||||
|
},
|
||||||
// 计算到期时间
|
// 计算到期时间
|
||||||
overDateFn(date) {
|
overDateFn(date) {
|
||||||
var specifiedDate = new Date(date);
|
var specifiedDate = new Date(date);
|
||||||
@ -218,7 +228,7 @@
|
|||||||
end_time: `${this.queryData} 23:59:59`,
|
end_time: `${this.queryData} 23:59:59`,
|
||||||
start_time: `${this.queryData} 00:00:00`,
|
start_time: `${this.queryData} 00:00:00`,
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
console.log(res.data)
|
// console.log(res.data)
|
||||||
this.markers[0].latitude = res.data[0].latitude
|
this.markers[0].latitude = res.data[0].latitude
|
||||||
this.markers[0].longitude = res.data[0].longitude
|
this.markers[0].longitude = res.data[0].longitude
|
||||||
this.polyline = [{
|
this.polyline = [{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user