This commit is contained in:
weipengfei 2023-09-06 09:19:32 +08:00
commit 8d84fd1736
6 changed files with 432 additions and 424 deletions

View File

@ -1,4 +1,4 @@
<template> <template>
<view> <view>
<view v-if='showLoading'> <view v-if='showLoading'>
<u-loading-page :loading="showLoading"></u-loading-page> <u-loading-page :loading="showLoading"></u-loading-page>
@ -15,11 +15,13 @@
</map> </map>
<view class="map_address"> <view class="map_address">
<view style="display: flex;"> <view style="display: flex;">
<view style="flex-shrink: 0;margin-right: 16rpx;"><text class="cir" style="background-color: #40BC5E;"></text> 起点:</view> <view style="flex-shrink: 0;margin-right: 16rpx;"><text class="cir"
style="background-color: #40BC5E;"></text> 起点:</view>
<view>{{nowAddress}}</view> <view>{{nowAddress}}</view>
</view> </view>
<view style="display: flex;"> <view style="display: flex;">
<view style="flex-shrink: 0;margin-right: 16rpx;"><text class="cir" style="background-color: #FF7C32;"></text>终点:</view> <view style="flex-shrink: 0;margin-right: 16rpx;"><text class="cir"
style="background-color: #FF7C32;"></text>终点:</view>
<view>{{goodsDetil.logistics.shop_address}}</view> <view>{{goodsDetil.logistics.shop_address}}</view>
</view> </view>
</view> </view>
@ -92,16 +94,18 @@
</view> </view>
</template> </template>
<script> <script>
import { import {
getDetil getDetil
} from "@/api/logistics.js" } from "@/api/logistics.js"
import { import {
takeGoods takeGoods
} from "@/api/logistics.js" } from "@/api/logistics.js"
import { Toast } from "../../libs/uniApi"; import {
Toast
} from "../../libs/uniApi";
export default { export default {
data() { data() {
return { return {
@ -170,7 +174,7 @@ import { Toast } from "../../libs/uniApi";
let that = this; let that = this;
uni.getSystemInfo({ uni.getSystemInfo({
success(e) { success(e) {
if(e.platform ==='ios'){ if (e.platform === 'ios') {
// Toast(''); // Toast('');
// iOSmanifest // iOSmanifest
// manifest.jsonapp-plus->distribute->apple->urlschemewhitelist // manifest.jsonapp-plus->distribute->apple->urlschemewhitelist
@ -178,36 +182,41 @@ import { Toast } from "../../libs/uniApi";
plus.nativeUI.actionSheet({ plus.nativeUI.actionSheet({
title: "选择地图应用", title: "选择地图应用",
cancel: "取消", cancel: "取消",
buttons: [{title: "高德地图"}] buttons: [{
title: "高德地图"
}]
}, function(e) { }, function(e) {
if(e.index!=1)return; if (e.index != 1) return;
try{ try {
let url = `iosamap://viewMap?sourceApplication=applicationName&poiname=${that.goodsDetil.logistics.shop_name}&lat=${that.markers[0].latitude}&lon=${that.markers[0].longitude}&dev=0`; let url =
`iosamap://viewMap?sourceApplication=applicationName&poiname=${that.goodsDetil.logistics.shop_name}&lat=${that.markers[0].latitude}&lon=${that.markers[0].longitude}&dev=0`;
if (url != "") { if (url != "") {
url = encodeURI(url); url = encodeURI(url);
plus.runtime.openURL(url, function(e) { plus.runtime.openURL(url, function(e) {
plus.nativeUI.alert("您的手机没有安装高德地图"); plus.nativeUI.alert("您的手机没有安装高德地图");
}); });
} }
}catch(e){ } catch (e) {
console.log(e); console.log(e);
Toast('暂不支持唤起地图') Toast('暂不支持唤起地图')
} }
}) })
} } else {
else {
plus.nativeUI.actionSheet({ plus.nativeUI.actionSheet({
title: "选择地图应用", title: "选择地图应用",
cancel: "取消", cancel: "取消",
buttons: [{title: "高德地图"}] buttons: [{
title: "高德地图"
}]
}, function(e) { }, function(e) {
if(e.index!=1)return; if (e.index != 1) return;
try{ try {
var packageName = 'com.autonavi.minimap'; var packageName = 'com.autonavi.minimap';
var main = plus.android.runtimeMainActivity(); var main = plus.android.runtimeMainActivity();
var packageManager = main.getPackageManager(); var packageManager = main.getPackageManager();
var PackageManager = plus.android.importClass(packageManager) var PackageManager = plus.android.importClass(packageManager)
var packageInfo = packageManager.getPackageInfo(packageName, PackageManager.GET_ACTIVITIES); var packageInfo = packageManager.getPackageInfo(packageName,
PackageManager.GET_ACTIVITIES);
if (packageInfo) { if (packageInfo) {
var Uri = plus.android.importClass("android.net.Uri"); var Uri = plus.android.importClass("android.net.Uri");
var url = var url =
@ -223,8 +232,7 @@ import { Toast } from "../../libs/uniApi";
intent.setPackage("com.autonavi.minimap"); intent.setPackage("com.autonavi.minimap");
var main = plus.android.runtimeMainActivity(); var main = plus.android.runtimeMainActivity();
main.startActivity(intent); main.startActivity(intent);
} } else {
else {
// alert('' + packageName + '') // alert('' + packageName + '')
uni.showToast({ uni.showToast({
title: `您的手机没有安装高德地图`, title: `您的手机没有安装高德地图`,
@ -232,7 +240,7 @@ import { Toast } from "../../libs/uniApi";
}) })
} }
console.log("唤醒高德线路规划") console.log("唤醒高德线路规划")
}catch(e){ } catch (e) {
console.log(e); console.log(e);
Toast('启动出错') Toast('启动出错')
} }
@ -354,9 +362,9 @@ import { Toast } from "../../libs/uniApi";
}) })
}, },
} }
</script> </script>
<style lang='scss' scoped> <style lang='scss' scoped>
.custom-map /deep/ .polyline { .custom-map /deep/ .polyline {
stroke-width: 20px; stroke-width: 20px;
} }
@ -455,4 +463,4 @@ import { Toast } from "../../libs/uniApi";
transform: translateX(-50%); transform: translateX(-50%);
} }
</style> </style>

View File

@ -58,7 +58,7 @@
</view> </view>
<view class="car_info" v-if="carList.length"> <view class="car_info" v-if="carList.length">
<view class="car_type"> <view class="car_type">
<text v-if="true">空闲车辆</text> <text v-if="true">租赁车辆</text>
<text v-else>自有车辆</text> <text v-else>自有车辆</text>
</view> </view>
<view class="car_li" v-for="item,index in carList"> <view class="car_li" v-for="item,index in carList">
@ -105,7 +105,7 @@
</view> </view>
<!-- 审核中 --> <!-- 审核中 -->
<view class="" v-if="dataList.status==0"> <view class="" v-if="dataList.status==0">
<u-button :disabled="true" type="primary" text="合同已上传,等待审核" @tap="contractFn" color="grey"></u-button> <u-button :disabled="true" type="primary" text="合同已上传,等待审核" color="grey"></u-button>
</view> </view>
<!-- 审核通过 --> <!-- 审核通过 -->
<view class="" v-if="dataList.status==1||dataList.status==2"> <view class="" v-if="dataList.status==1||dataList.status==2">
@ -136,7 +136,6 @@
color="#0122C7"></u-button> color="#0122C7"></u-button>
</view> </view>
</view> </view>
<!--uview 组件 --> <!--uview 组件 -->
<view class=""> <view class="">
<u-modal :show="showPop" @close="showPop=false" @confirm="confirm" :closeOnClickOverlay="true" <u-modal :show="showPop" @close="showPop=false" @confirm="confirm" :closeOnClickOverlay="true"
@ -270,7 +269,7 @@
}).then(res => { }).then(res => {
this.navTo('/subpkg/property/success') this.navTo('/subpkg/property/success')
}) })
this.navTo('/subpkg/property/success') // this.navTo('/subpkg/property/success')
}, },
// sendcontractFn() { // sendcontractFn() {

View File

@ -13,7 +13,7 @@
</view> </view>
</view> </view>
<!-- <view class="right" @click="navToContract(dataList.file)"> --> <!-- <view class="right" @click="navToContract(dataList.file)"> -->
<view class="right" @click="showContractFn(item.file)"> <view class="right" @click="showContractFn(item.contract_url)">
<uni-icons type="paperclip" color="#3274F9"></uni-icons> <uni-icons type="paperclip" color="#3274F9"></uni-icons>
<view>查看</view> <view>查看</view>
</view> </view>

View File

@ -17,9 +17,12 @@
<script> <script>
export default { export default {
onLoad() { onLoad() {
setTimeout(() => {
uni.redirectTo({ uni.redirectTo({
url: '/subpkg/property/index' url: '/subpkg/property/index'
}) })
}, 3000)
} }
} }
</script> </script>

View File

@ -73,7 +73,8 @@
</view> </view>
</view> </view>
<!-- <view class="right" @click="navToContract(dataList.file)"> --> <!-- <view class="right" @click="navToContract(dataList.file)"> -->
<view class="right" @click="showContractFn(datas.contract.file)"> <!-- <view class="right" @click="showContractFn(datas.contract.file)"> -->
<view class="right" @click="showContractFn(datas.contract.contract_url)">
<uni-icons type="paperclip" color="#3274F9"></uni-icons> <uni-icons type="paperclip" color="#3274F9"></uni-icons>
<view>查看</view> <view>查看</view>
</view> </view>

View File

@ -51,10 +51,7 @@ function baseRequestTwo(url, method, data, {
url: Url + '/api' + url, url: Url + '/api' + url,
method: method || 'GET', method: method || 'GET',
header: { header: {
...header, ...header
...{
'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8'
}
}, },
data: method != 'GET' ? data || {} : {}, data: method != 'GET' ? data || {} : {},
params: method == 'GET' ? data : {}, params: method == 'GET' ? data : {},