ccjgmwz 3 anni fa
parent
commit
0bdfddf9a7

+ 2 - 2
config/index.js

@@ -1,6 +1,6 @@
 const dev = {
-	// baseUrlNew: 'https://apitest.eliangeyun.com',
-	baseUrlNew: 'http://192.168.1.114:8099',
+	baseUrlNew: 'https://apitest.eliangeyun.com',
+	// baseUrlNew: 'http://192.168.1.114:8099',
 	h5Appid: 'wxb66b599f7f61b46f',
 	debug: false
 }

+ 6 - 0
pages/news/index.vue

@@ -137,6 +137,9 @@
 				}
 				// #endif
 			},
+			cancelClick(){
+				this.isShowAlert = false
+			},
 			rightClick() {
 				uni.showLoading({
 					title: '加载中',
@@ -230,6 +233,9 @@
 						pageSize: page.size,
 						currentPage: page.num,
 					}).then(res => {
+						if(page.num == 1){
+							this.news = []; //追加新数据
+						}
 						this.news = this.news.concat(res.data.records); //追加新数据
 						this.mescroll.endBySize(res.data.records.length, res.data.total);
 					})

+ 1 - 1
pages/order/index.vue

@@ -103,7 +103,7 @@
 						</view>
 						<view class="flex align-center">
 							<view style="margin-right: 20rpx;">运距 {{good.distance}}km</view>
-							<view class="car">{{good.freight}}{{good.illingMethod==0?'元/吨':'元/车'}}</view>
+							<view class="car">{{good.freightInfo.freight}}{{good.illingMethod==0?'元/吨':'元/车'}}</view>
 						</view>
 						<!-- 		<view class="right">
 							<view class="flex fontsize-26 row">

+ 13 - 33
pages/order/orderDetails.vue

@@ -352,39 +352,19 @@
 				});
 			},
 			lookContract() {
-				this.$request.baseRequest('get', '/orderInfo/setPdf', {}).then(res => {
-						if (res.code == 200) {
-							debugger
-							this.contractSrc = res.data
-							uni.downloadFile({
-								url: res.data,
-								success: function(res) {
-									var filePath = res.tempFilePath;
-									uni.openDocument({
-							 		filePath: filePath,
-							  	showMenu: true,
-							  	success: function(res) {
-							  		console.log('打开文档成功');
-										}
-									});
-								}
-							});
-							// this.$refs.uToast.show({
-							// 	type: 'success',
-							// 	message: "提交成功",
-							// 	complete() {
-							// 		that.upCallback({
-							// 			size: 10,
-							// 			num: 1
-							// 		})
-							// 	}
-							// })
-
-						}
-					})
-					.catch(res => {
-						uni.$u.toast(res.message);
-					});
+				uni.downloadFile({
+					url: this.dataObj.ownerContractUrl,
+					success: function(res) {
+						var filePath = res.tempFilePath;
+						uni.openDocument({
+				 		filePath: filePath,
+				  	showMenu: true,
+				  	success: function(res) {
+				  		console.log('打开文档成功');
+							}
+						});
+					}
+				});
 			},
 			signContract() {
 				// this.lookAlert = true

+ 5 - 1
pages/order/signContract.vue

@@ -45,7 +45,7 @@
 			</view>
 			<view class='row-between'>
 				<view class="gray">运费</view>
-				<view class="">{{dataDetails.freight}}{{dataDetails.illingMethod==0?'元/吨':'元/车'}}</view>
+				<view class="">{{dataDetails.freightInfo.freight}}{{dataDetails.illingMethod==0?'元/吨':'元/车'}}</view>
 				<!-- 				<view class="flex"><input type="text" placeholder="请输入运费" v-model="dataDetails.freight"
 						class="text-align-right yf-input">{{dataDetails.freight}}元/车</view> -->
 			</view>
@@ -170,6 +170,10 @@
 								debugger
 								that.$request.baseRequest('get', '/orderInfo/setPdf', _obj).then(
 										res => {
+											uni.hideLoading()
+											uni.navigateBack({
+												delta:1
+											})
 											if (res.code == 200) {
 												debugger
 												// that.contractSrc = res.data

+ 4 - 1
pages/release/addAddress.vue

@@ -86,7 +86,10 @@
 									type: 'success',
 									message: "提交成功",
 									complete() {
-										uni.$u.route('/pages/release/selectAddress');
+										// uni.$u.route('/pages/release/selectAddress');
+										uni.navigateBack({
+											delta:1
+										})
 									}
 								})
 

+ 4 - 1
pages/release/editAddress.vue

@@ -86,7 +86,10 @@
 									type: 'success',
 									message: "提交成功",
 									complete() {
-										uni.$u.route('/pages/release/selectAddress');
+										// uni.$u.route('/pages/release/selectAddress');
+										uni.navigateBack({
+											delta:1
+										})
 									}
 								})
 

+ 47 - 32
pages/release/release.vue

@@ -1,6 +1,13 @@
 <template>
 	<view class="content">
-		<view class="fixed1"></view>
+		<u-navbar  title="发布" :placeholder="true" rightText="记录" @rightClick="goToRecord" @leftClick="back()">
+			<!-- view class="u-nav-slot" slot="left">
+				<u-icon name="arrow-left" size="19"></u-icon>
+				<u-line direction="column" :hairline="false" length="16" margin="0 8px"></u-line>
+				<u-icon name="home" size="20"></u-icon>
+			</view> -->
+		</u-navbar>
+		<!-- <view class="fixed1"></view>
 		<view class='title top-title flex'>
 			<u-icon class="back" name="arrow-left" color="" size="20" @click="back"></u-icon>
 			<view class="nav-title">发布</view>
@@ -10,7 +17,7 @@
 					记录
 				</view>
 			</view>
-		</view>
+		</view> -->
 		<view class="content1">
 			<view class="row" @click="selectCargoOwner">
 				<view class="left select-sf">{{dataObj.cargoOwner?dataObj.cargoOwner:'选择货主身份'}}</view>
@@ -27,7 +34,7 @@
 			<view class="row1">
 				<view class="left">
 					<view class="top" @click="selectAddress(0)">
-						<view class="send"></view>
+						<view class="send"></view>
 						<view class="title">
 							{{dataObj.sendArea?(dataObj.sendPrivate + dataObj.sendCity+dataObj.sendArea):'选择发货地区'}}
 						</view>
@@ -220,7 +227,7 @@
 	export default {
 		data() {
 			return {
-				showCancelButton:true,
+				showCancelButton: true,
 				qyList: [],
 				isShowAlert: false,
 				alertTitle: '确定发布运输任务?',
@@ -341,7 +348,7 @@
 				this.isShowAlert = true
 				this.alertTitle = '账号审核中'
 				this.confirmText = '退出APP'
-				this.showCancelButton=false
+				this.showCancelButton = false
 				return
 			} else {
 				console.log(1231233212332312312213)
@@ -352,7 +359,7 @@
 			let _faddress = uni.getStorageSync('storage_faddress');
 			let _saddress = uni.getStorageSync('storage_saddress');
 			if (_faddress) {
-			
+
 				this.dataObj.sendCity = _faddress.city
 				this.dataObj.sendArea = _faddress.area
 				this.dataObj.sendPrivate = _faddress.province
@@ -378,20 +385,22 @@
 			}
 			if (this.dataObj.sendLatitude && this.dataObj.sendLongitude && this.dataObj.unsendLatitude && this.dataObj
 				.unsendLongitude) {
-				this.dataObj.distance = this.$helper.getDistance(this.dataObj.unsendLatitude, this.dataObj.unsendLongitude,
+				this.dataObj.distance = this.$helper.getDistance(this.dataObj.unsendLatitude, this.dataObj
+					.unsendLongitude,
 					this.dataObj.sendLatitude, this.dataObj.sendLongitude)
 			}
 			this.dataObj.loadingDateStart = '随时'
 			this.dataObj.loadingDateEnd = '随时'
 			this.dataObj.taskValidity = '长期'
-			
-			
+
+
 		},
 		computed: {
 			...mapState(['hasLogin', 'userInfo']),
 		},
 		methods: {
-			getSFList() {debugger
+			getSFList() {
+				debugger
 				this.dataObj.commonId = this.userInfo.id
 				this.$request.baseRequest('get', '/cargoOwnerCompInfo/cargoOwnerList', {
 						commonId: this.userInfo.id
@@ -405,7 +414,7 @@
 						let _self = res.data.companyInfoList
 						//代理货主
 						let _dlhz = res.data.cargoOwnerCompInfoList
-						if(!_dlhz) _dlhz=[]
+						if (!_dlhz) _dlhz = []
 						for (let i = 0; i < _self.length; i++) {
 							if (_self[i].status == '已认证') {
 								this.qyList.push(_self[i])
@@ -575,18 +584,18 @@
 
 			},
 			confirmClick() {
-							// #ifdef APP-PLUS
-								if (this.alertTitle == '账号审核中') {
-									if (uni.getSystemInfoSync().platform == 'ios') {
-										plus.ios.import("UIApplication").sharedApplication().performSelector("exit")
-									} else if (uni.getSystemInfoSync().platform == 'android') {
-										plus.runtime.quit();
-									}
-									return
-								}
-								// #endif
+				// #ifdef APP-PLUS
+				if (this.alertTitle == '账号审核中') {
+					if (uni.getSystemInfoSync().platform == 'ios') {
+						plus.ios.import("UIApplication").sharedApplication().performSelector("exit")
+					} else if (uni.getSystemInfoSync().platform == 'android') {
+						plus.runtime.quit();
+					}
+					return
+				}
+				// #endif
 				this.isShowAlert = false
-				
+
 				if (this.dataObj.billingMethod == '元/吨') {
 					this.dataObj.billingMethod = 0
 				} else {
@@ -617,7 +626,7 @@
 							type: 'success',
 							message: "发布成功",
 							complete() {
-								
+
 								_this.dataObj = {
 									commonId: '',
 									cargoOwner: '',
@@ -688,6 +697,8 @@
 								this.dataObj.sendDetailedAddress = res.data[i].detailedAddress
 								this.dataObj.sendLongitude = res.data[i].longitude
 								this.dataObj.sendLatitude = res.data[i].latitude
+								this.dataObj.sender = res.data[i].contacts
+								this.dataObj.senderPhone = res.data[i].contactPhone
 							}
 							if (res.data[i].defaultReceipt == 1 && type == 1) {
 								this.dataObj.unloadDetailedAddress = res.data[i].detailedAddress
@@ -696,6 +707,8 @@
 								this.dataObj.unloadPrivate = res.data[i].province
 								this.dataObj.unsendLongitude = res.data[i].longitude
 								this.dataObj.unsendLatitude = res.data[i].latitude
+								this.dataObj.receiver = res.data[i].contacts
+								this.dataObj.receiverPhone = res.data[i].contactPhone
 							}
 						}
 						if (this.dataObj.sendLatitude && this.dataObj.sendLongitude && this.dataObj.unsendLatitude &&
@@ -845,8 +858,8 @@
 			submit() {
 				if (this.validate()) return
 				this.isShowAlert = true;
-				
-				
+
+
 			},
 		}
 	}
@@ -893,7 +906,7 @@
 
 	.content1 {
 		background: white;
-		margin: 100rpx 20rpx 0 20rpx;
+		margin: 40rpx 20rpx 0 20rpx;
 		border-radius: 20rpx;
 		padding: 40rpx;
 
@@ -935,15 +948,17 @@
 		display: flex;
 		justify-content: flex-end;
 	}
-	.top-title{
-		background:#fff;
-		padding:20rpx;
+
+	.top-title {
+		background: #fff;
+		padding: 20rpx;
 		position: fixed;
-		z-index:100;
-		top:0;
+		z-index: 100;
+		top: 0;
 		box-sizing: border-box;
-		width:100%;
+		width: 100%;
 	}
+
 	.content2 {
 		padding: 40rpx;
 

+ 7 - 5
pages/release/selectAddress.vue

@@ -68,8 +68,10 @@
 				radiovalue: '',
 				dataList: [],
 				searchKeyWord: '',
-				radiolist1: [{
-						name: '默认收货',
+				radiolist1: [
+					
+					{
+						name: '默认装货',
 						disabled: false
 					},
 					{
@@ -113,10 +115,10 @@
 							this.dataList = res.data.records
 							for (let i = 0; i < this.dataList.length; i++) {
 								if (this.dataList[i].defaultShipment == 1) {
-									this.dataList[i].radiovalue = '默认货'
+									this.dataList[i].radiovalue = '默认货'
 								}
 								if (this.dataList[i].defaultReceipt == 1) {
-									this.dataList[i].radiovalue = '默认货'
+									this.dataList[i].radiovalue = '默认货'
 								}
 							}
 							uni.hideLoading()
@@ -135,7 +137,7 @@
 				console.log('radioChange', n);
 				console.log('radioChange', val);
 				let _flag;
-				if (n == '默认货') {
+				if (n == '默认货') {
 					_flag = 2
 				} else {
 					_flag = 1