Bläddra i källkod

Merge branch 'master' of http://git.zthymaoyi.com/gdc/yiliangyiyun-app into dev

wangchao 3 år sedan
förälder
incheckning
9e3932800f

+ 49 - 18
pages/erpbusiness/acquisitionInformation.vue

@@ -2,21 +2,27 @@
 	<view class="wrap">
 		<view class='content1'>
 			<view class='row content-item'>
-				<view class="left" style="color: #878C9C ;">仓库</view>
-				<view class="right" @click='show1=true'>
+				<view class="left" @click='show1=true'>
 					<view>{{warehouseName}}</view>
 					<u-icon name="arrow-right" color=""></u-icon>
-					<u-picker @confirm="warehousechange" range-key='warehouseName' mode="selector" v-model="show1"
-						:range="warehouseList"></u-picker>
+					<u-picker @confirm="warehousechange" range-key='warehouseName' mode="selector" v-model="show1" :range="warehouseList"></u-picker>
 				</view>
 			</view>
-			<view class='row content-item'>
+			<view class="content-item">
+				<view class="left">收购信息</view>
+				<view class='row'>
 				<textarea placeholder="请输入仓库信息" class="textarea" maxlength="2000" v-model="textareaValue"></textarea>
 				<view class="textarea-bottom">{{textareaValue?textareaValue.length:'0'}}/2000字</view>
 			</view>
-			<view class='row content-item'>
-				<u-checkbox activeColor="#19be6b" v-model="value" @change="checkBoxChange">显示在易粮易运收购信息中</u-checkbox>
+			<view class='row row_css'>
+				显示在易粮易运收购信息中
+				<!-- <u-checkbox activeColor="#19be6b" v-model="value" @change="checkBoxChange">显示在易粮易运收购信息中</u-checkbox> -->
+				<view class="right">
+					<u-switch v-model="value" active-color="#19be6b" inactive-color="#eee" size='40' @change="checkBoxChange"></u-switch>
+				</view>
 			</view>
+			</view>
+			
 		</view>
 		<view class="bottom-btn">
 			<u-button type="primary" class="submit" hover-class="none" @click="submit()">提交</u-button>
@@ -219,9 +225,9 @@
 				this.isShowAlert = false
 			},
 			checkBoxChange(e) {
-				console.log("e-----", e)
+				// console.log("e-----", e)
 				this.value = !this.value
-				console.log("value----", this.value)
+				// console.log("value----", this.value)
 			},
 			submit() {
 				this.isShowAlert1 = true
@@ -238,12 +244,28 @@
 	}
 
 	.wrap {
-		background: #fff;
+		/* background: #fff; */
 		margin: 10px;
 		border-radius: 10px;
-		padding: 10px;
+		/* padding: 10px; */
+		height: calc(100vh - 55px);
 
 	}
+	
+	.content-item{
+		/* height: 104rpx; */
+		border-radius: 14rpx;
+		background: #fff;
+		padding: 40rpx 30rpx;
+		margin-bottom: 20rpx;
+	}
+	.left{
+		align-items: center;
+		color: #333333;
+		font-size: 34rpx;
+		font-weight: 600;
+		}
+	
 
 	.row {
 		display: flex;
@@ -256,23 +278,32 @@
 			// color: #333333;
 		}
 
-		.right {
+		.left {
 			display: flex;
 			align-items: center;
+			color: #333333;
+			font-size: 34rpx;
+			font-weight: 600;
 		}
 	}
+	.row_css{
+		font-size: 26rpx;
+		color: #333333;
+		margin-top: 60rpx;
+		font-weight: 500;
+	}
 
 	.textarea {
 		background: #F9F9FA;
-		font-size: 12px;
+		font-size: 28rpx;
 		text-align: left;
 		width: 100%;
-		height: 60px;
-		padding: 10px;
+		padding: 30rpx;
 		border-radius: 5px;
-		margin-top: 10px;
-		height: 50vh;
+		margin-top: 30rpx;
+		height: 45vh;
 		padding-bottom: 20rpx;
+		color: #AFB3BF ;
 	}
 
 	.textarea-bottom {
@@ -285,7 +316,7 @@
 	.submit {
 		/* width: 90%; */
 		background: #22C572;
-		border-radius: 10rpx;
+		border-radius: 50rpx;
 	}
 
 	.bottom-btn {

+ 107 - 142
pages/task/audit/acquisition_information_approval.vue

@@ -2,45 +2,26 @@
 	<view class="wrap">
 		<view class='content1'>
 			<view class='row'>
-				<view class="left">鲅鱼圈库</view>
-				<!-- <view class="right">鲅鱼圈库</view> -->
+				<view class="left">{{dataList.warehouseName}}</view>
 			</view>
 			<view class='row '>
-				<textarea placeholder="请输入仓库信息" class="textarea" maxlength="2000" v-model="textareaValue"></textarea>
-				<view class="textarea-bottom">{{textareaValue?textareaValue.length:'0'}}/2000字</view>
+				<textarea placeholder="请输入仓库信息" class="textarea" maxlength="2000"
+					v-model="dataList.acquisitionInformation" disabled></textarea>
+				<view class="textarea-bottom">
+					{{dataList.acquisitionInformation?dataList.acquisitionInformation.length:'0'}}/2000字</view>
 			</view>
 			<view class='row content-item'>
 				<!-- <u-checkbox activeColor="#19be6b" v-model="value" @change="checkBoxChange">显示在易粮易运收购信息中</u-checkbox> -->
 				显示在易粮易运收购信息中
 				<view class="right">
-					<u-switch v-model="checked" active-color="#22C572" inactive-color="#eee" size='40' @change="checkBoxChange" disabled="disabled"></u-switch>
+					<u-switch v-model="checked" active-color="#22C572" inactive-color="#eee" size='40' disabled="disabled"></u-switch>
 				</view>
 			</view>
 		</view>
-		<view v-if='show' class="shade">
-			<view class="wrap">
-				<view class="alert-top">
-					<view class="title">
-						{{title}}
-					</view>
-					<u-icon name="close" class="close" color="#8890B1" @click="close()"></u-icon>
-				</view>
-				<view class="u-textarea-style">
-					<view class="right-bottom">
-						{{auditMind.length}}/100个字
-					</view>
-					<u-input class="" v-model='auditMind' placeholder="请在此输入审核意见" type="textarea" height="414"
-						maxlength="100" />
-				</view>
-				<view @click='close()' class="cancel">取消</view>
-				<view @click='passSubmit()' class="confirm">确定</view>
-			</view>
-		</view>
 		<u-toast ref="uToast" />
 		<view style='padding:10px;' class='flex bottom-btn'>
-			<!-- getRoles("acquisitionQuality.initial") -->
 			<u-button v-if='isSHowBtn' @click='reject' type="error" class="btn1" hover-class='none'>驳回</u-button>
-			<u-button v-if='isSHowBtn' @click='pass' type="success" class="btn2">通过</u-button>
+			<u-button v-if='isSHowBtn' @click='passSubmit' type="success" class="btn2">通过</u-button>
 		</view>
 		<u-modal v-model="isShowAlert" :title-style="{fontSize: '18px',fontWeight:'500'}"
 			:content-style="{fontSize: '14px',fontWeight:'400'}" confirm-color='#22C572' confirm-text='确定' title='登录提示'
@@ -51,130 +32,111 @@
 	import {
 		mapState
 	} from 'vuex';
-
 	export default {
-		components: {
-
-		},
+		components: {},
 		data() {
 			return {
 				isSHowBtn: true,
 				isShowAlert: false,
 				content: '当前登入信息验证失败,是否重新登录?',
-				textareaValue: '',
-				value: '',
-				show:false,
-				title:"",
-				auditMind:"", //审核意见
-			    checked: false,
+				// textareaValue: '',
+				// value: '',
+				// show: false,
+				// title: "",
+				// auditMind: "", //审核意见
+				checked: false,
+				toexamineId: "",
+				isShow: false,
+				dataList: {},
+				everyCheck: "",
 			}
 		},
-
-		onLoad() {
-
+		onBackPress(e) {
+			if (this.everyCheck) {
+				uni.navigateTo({
+					url: "/pages/task/my_task"
+				})
+				return true;
+			}
+		},
+		onLoad(options) {
+			this.toexamineId = options.id
+			this.isShow = options.isShowbtn
+			this.everyCheck = uni.getStorageSync("everyTask")
 		},
 		computed: {
 			...mapState(['hasLogin', 'userInfo']),
 		},
 		onShow() {
-			this.$api.doRequest('get', '/commonUser/api/checkSession').then(res => {
-				console.log("checkSession", res)
-				if (res.data.data == "INVALID") {
-					this.isShowAlert = true;
-					// uni.showModal({
-					// 	title: '登录提示',
-					// 	content: '当前登入信息验证失败,是否重新登录?',
-					// 	showCancel: true,
-					// 	confirmText: '登录',
-					// 	success: (e) => {
-					// 		if (e.confirm) {
-					// 			uni.navigateTo({
-					// 				url: '/pages/public/login'
-					// 			})
-					// 		}
-					// 	},
-					// 	fail: () => {},
-					// 	complete: () => {}
-					// })
-				}
-			})
-			console.log("hasLogin", this.hasLogin)
+			this.getList()
 		},
 		methods: {
-			pass(){
-				this.title = "审核意见(通过)"
-				this.show = true
-			},
-			reject(){
-				this.title = "驳回原因(驳回)"
-				this.show = true
-			},
-			close(){
-				this.show = false
-			},
-			passSubmit(item){
-				if(this.title == "审核意见(通过)"){
-					this.$api.doRequest('post', '/workflow/api/handle', {
-						taskId: item.taskId,
-						approved: true,
-						auditMind: this.auditMind ? this.auditMind : "34",
-						needReapply:true
-					}).then(res => {
-						if (res.data.code == 200) {
-					      this.$api.msg('通过成功')
+			getList() {
+				this.$api.doRequest('get', '/acquisitionInfo/getAcquisition', {
+					id: this.toexamineId
+				}).then(res => {
+					if (res.data.code == 200) {
+						this.dataList = res.data.data
+						if (this.dataList.checkFlag == 1) {
+							this.checked = true
+						} else {
+							this.checked = false
 						}
-					})
-					
-				}else if(this.title == "驳回原因(驳回)"){
-					if(!this.auditMind){
-						this.$api.msg('驳回原因不能为空!')
-						return
 					}
-					this.$api.doRequest('post', '/workflow/api/handle', {
-						taskId: item.taskId,
-						approved: false,
-						auditMind: this.auditMind ? this.auditMind : "34",
-						needReapply:true
-					}).then(res => {
-						if (res.data.code == 200) {
-					      this.$api.msg('驳回成功')
-						}
-					})
-				}
-			},
-			
-			
-			/**
-			 * 统一跳转接口,拦截未登录路由
-			 * navigator标签现在默认没有转场动画,所以用view
-			 */
-			navTo(url) {
-				if (!this.hasLogin) {
-					url = '/pages/public/login';
-				}
-				uni.navigateTo({
-					url
 				})
 			},
-			alertBtn() {
-				uni.navigateTo({
-					url: '/pages/public/login'
+			reject() {
+				var that = this
+				uni.showModal({
+					content: "确定驳回该条收购信息审核?",
+					showCancel: true,
+					confirmText: '确定',
+					success: function(res) {
+						if (res.confirm) {
+							that.$api.doRequest('post', '/acquisitionInfo/api/examine', {
+								flag: 2,
+								id: that.toexamineId
+							}).then(res => {
+								if (res.data.code == 200) {
+									that.$api.msg('驳回成功')
+									setTimeout(function() {
+										uni.hideLoading()
+										uni.navigateBack()
+									}, 1000);
+								}
+							})
+						}
+					}
 				})
 			},
-			cancelClick() {
-				this.isShowAlert = false
+			passSubmit(item) {
+				var that = this
+				uni.showModal({
+					content: "确定通过该条收购信息审核?",
+					showCancel: true,
+					confirmText: '确定',
+					success: function(res) {
+						if (res.confirm) {
+							that.$api.doRequest('post', '/acquisitionInfo/api/examine', {
+								flag: 1,
+								id: that.toexamineId
+							}).then(res => {
+								if (res.data.code == 200) {
+									that.$api.msg('通过成功')
+									setTimeout(function() {
+										uni.hideLoading()
+										uni.navigateBack()
+									}, 1000);
+								}
+							})
+						}
+					}
+				})
 			},
-			checkBoxChange(e) {
-				console.log(e)
-			}
 		}
 	}
 </script>
 <style lang='scss' scoped>
-	page {
-		background: #F5F6FA;
-	}
-
 	.wrap {
 		background: #fff;
 		margin: 10px;
@@ -182,7 +144,8 @@
 		padding: 40rpx 30rpx;
 
 	}
-	.content-item{
+
+	.content-item {
 		margin-top: 50rpx;
 		font-size: 28rpx;
 	}
@@ -191,13 +154,15 @@
 		display: flex;
 		justify-content: space-between;
 		position: relative;
+
 		/* border-bottom: 1px solid #EEEEEE; */
 		.right,
 		input {
 			font-size: 28rpx;
 			// color: #333333;
 		}
-		.left{
+
+		.left {
 			font-size: 34rpx;
 			color: #333333;
 			font-weight: 600;
@@ -215,7 +180,7 @@
 		margin-top: 40rpx;
 		height: 50vh;
 		padding-bottom: 20rpx;
-		color: #AFB3BF ;
+		color: #AFB3BF;
 	}
 
 	.textarea-bottom {
@@ -224,6 +189,7 @@
 		right: 20rpx;
 		color: #606266;
 	}
+
 	.bottom-btn {
 		width: 100%;
 		position: fixed;
@@ -233,20 +199,21 @@
 		left: 0;
 		background-color: #f8f8f8;
 		flex-direction: column;
-	
+
 		.btn1,
 		.btn2 {
 			width: 100%;
 			margin-bottom: 26rpx;
 			border-radius: 90rpx;
 		}
-	
+
 		.btn1 {
 			background: white;
 			color: #00C265;
 		}
 	}
-	.shade {
+
+	/* .shade {
 		position: fixed;
 		top: 0;
 		left: 0;
@@ -254,7 +221,7 @@
 		width: 100%;
 		background: rgba(0, 0, 0, 0.4);
 		z-index: 3;
-	
+
 		.wrap {
 			position: absolute;
 			left: 0;
@@ -267,7 +234,7 @@
 			height: 700rpx;
 			border-radius: 20rpx;
 			padding: 20rpx;
-	
+
 			.alert-top {
 				padding: 33rpx;
 				display: flex;
@@ -275,19 +242,20 @@
 				align-items: center;
 				position: relative;
 			}
-	
+
 			.title {
 				font-size: 32rpx;
 				font-weight: 600;
 				color: #333333;
 			}
-	
+
 			.close {
 				position: absolute;
 				right: 33rpx;
 			}
 		}
-	}
+	} */
+
 	.cancel,
 	.confirm {
 		position: absolute;
@@ -299,17 +267,18 @@
 		border-top: 1px solid #eee;
 		font-size: 34rpx;
 	}
-	
+
 	.cancel {
 		left: 0;
 		border-right: 1px solid #eee;
 		color: #AFB3BF;
 	}
-	
+
 	.confirm {
 		right: 0;
 		color: #22C572;
 	}
+
 	.u-textarea-style {
 		margin: 20rpx;
 		background: #F9F9FA;
@@ -317,7 +286,7 @@
 		border: 1px solid #EEEEEE;
 		padding: 10rpx 20rpx;
 		position: relative;
-	
+
 		.right-bottom {
 			position: absolute;
 			right: 20rpx;
@@ -325,8 +294,4 @@
 			color: #AFB3BF;
 		}
 	}
-	
-	/deep/.u-input__textarea {
-		height: 300rpx !important;
-	}
 </style>

+ 125 - 88
pages/task/audit/acquisition_information_details.vue

@@ -1,156 +1,131 @@
 <template>
 	<view class="wrap">
 		<view class='content1'>
-			<view class='row content-item'>
-				<view class="left" style="color: #878C9C ;">仓库</view>
-				<view class="right">鲅鱼圈库</view>
+			<view class='row'>
+				<view class="left">{{dataList.warehouseName}}</view>
 			</view>
-			<view class='row content-item'>
-				<textarea disabled placeholder="请输入仓库信息" class="textarea" maxlength="2000" v-model="textareaValue"></textarea>
-				<view class="textarea-bottom">{{textareaValue?textareaValue.length:'0'}}/2000字</view>
+			<view class='row '>
+				<textarea placeholder="请输入仓库信息" class="textarea" maxlength="2000"
+					v-model="dataList.acquisitionInformation" disabled></textarea>
+				<view class="textarea-bottom">
+					{{dataList.acquisitionInformation?dataList.acquisitionInformation.length:'0'}}/2000字</view>
 			</view>
 			<view class='row content-item'>
-				<u-checkbox disabled activeColor="#19be6b" v-model="value">显示在易粮易运收购信息中</u-checkbox>
+				显示在易粮易运收购信息中
+				<view class="right">
+					<u-switch v-model="checked" active-color="#22C572" inactive-color="#eee" size='40' disabled="disabled"></u-switch>
+				</view>
 			</view>
 		</view>
-		<u-modal v-model="isShowAlert" :title-style="{fontSize: '18px',fontWeight:'500'}"
-			:content-style="{fontSize: '14px',fontWeight:'400'}" confirm-color='#22C572' confirm-text='确定' title='登录提示'
-			showCancelButton='false' :content="content" @confirm="alertBtn" @cancel="cancelClick"></u-modal>
+		<u-toast ref="uToast" />
+		<view style='padding:10px;' class='flex bottom-btn'>
+			<u-button  @click='returnPage' type="error" class="btn1" hover-class='none'>返回</u-button>
+		</view>
 	</view>
 </template>
 <script>
 	import {
 		mapState
 	} from 'vuex';
-
 	export default {
-		components: {
-
-		},
+		components: {},
 		data() {
 			return {
 				isSHowBtn: true,
 				isShowAlert: false,
-				content: '当前登入信息验证失败,是否重新登录?',
-				textareaValue: '',
-				value: ''
+				checked: false,
+				toexamineId: "",
+				isShow: false,
+				dataList: {},
+				everyCheck: "",
 			}
 		},
-
-		onLoad() {
-
-		},
-		// #ifndef MP
-		onNavigationBarButtonTap(e) {
-			const index = e.index;
-			if (index === 0) {
-				this.navTo('/pages/set/set');
-			} else if (index === 1) {
-				// #ifdef APP-PLUS
-				const pages = getCurrentPages();
-				const page = pages[pages.length - 1];
-				const currentWebview = page.$getAppWebview();
-				currentWebview.hideTitleNViewButtonRedDot({
-					index
-				});
-				// #endif
+		onBackPress(e) {
+			if (this.everyCheck) {
 				uni.navigateTo({
-					url: '/pages/notice/notice'
+					url: "/pages/task/my_task"
 				})
+				return true;
 			}
 		},
-		// #endif
+		onLoad(options) {
+			this.toexamineId = options.id
+			this.isShow = options.isShowbtn
+			this.everyCheck = uni.getStorageSync("everyTask")
+		},
 		computed: {
 			...mapState(['hasLogin', 'userInfo']),
 		},
 		onShow() {
-			this.$api.doRequest('get', '/commonUser/api/checkSession').then(res => {
-				console.log("checkSession", res)
-				if (res.data.data == "INVALID") {
-					this.isShowAlert = true;
-					// uni.showModal({
-					// 	title: '登录提示',
-					// 	content: '当前登入信息验证失败,是否重新登录?',
-					// 	showCancel: true,
-					// 	confirmText: '登录',
-					// 	success: (e) => {
-					// 		if (e.confirm) {
-					// 			uni.navigateTo({
-					// 				url: '/pages/public/login'
-					// 			})
-					// 		}
-					// 	},
-					// 	fail: () => {},
-					// 	complete: () => {}
-					// })
-				}
-			})
-			console.log("hasLogin", this.hasLogin)
+			this.getList()
 		},
 		methods: {
-			/**
-			 * 统一跳转接口,拦截未登录路由
-			 * navigator标签现在默认没有转场动画,所以用view
-			 */
-			navTo(url) {
-				if (!this.hasLogin) {
-					url = '/pages/public/login';
-				}
-				uni.navigateTo({
-					url
-				})
-			},
-			alertBtn() {
-				uni.navigateTo({
-					url: '/pages/public/login'
+			getList() {
+				this.$api.doRequest('get', '/acquisitionInfo/getAcquisition', {
+					id: this.toexamineId
+				}).then(res => {
+					if (res.data.code == 200) {
+						this.dataList = res.data.data
+						if (this.dataList.checkFlag == 1) {
+							this.checked = true
+						} else {
+							this.checked = false
+						}
+					}
 				})
 			},
-			cancelClick() {
-				this.isShowAlert = false
+			returnPage(){
+				uni.navigateBack()
 			},
-			checkBoxChange(e) {
-				console.log(e)
-			}
 		}
 	}
 </script>
 <style lang='scss' scoped>
-	page {
-		background: #F5F6FA;
-	}
 
 	.wrap {
 		background: #fff;
 		margin: 10px;
 		border-radius: 10px;
-		padding: 10px;
+		padding: 40rpx 30rpx;
+
+	}
 
+	.content-item {
+		margin-top: 50rpx;
+		font-size: 28rpx;
 	}
 
 	.row {
 		display: flex;
 		justify-content: space-between;
 		position: relative;
-		/* border-bottom: 1px solid #EEEEEE; */
 
+		/* border-bottom: 1px solid #EEEEEE; */
 		.right,
 		input {
 			font-size: 28rpx;
 			// color: #333333;
 		}
+
+		.left {
+			font-size: 34rpx;
+			color: #333333;
+			font-weight: 600;
+		}
 	}
 
 	.textarea {
 		background: #F9F9FA;
-		font-size: 12px;
+		font-size: 26rpx;
 		text-align: left;
 		width: 100%;
 		height: 60px;
-		padding: 10px;
-		border-radius: 5px;
-		margin-top: 10px;
+		padding: 32rpx;
+		border-radius: 10rpx;
+		margin-top: 40rpx;
 		height: 50vh;
 		padding-bottom: 20rpx;
+		color: #AFB3BF;
 	}
 
 	.textarea-bottom {
@@ -159,4 +134,66 @@
 		right: 20rpx;
 		color: #606266;
 	}
+
+	.bottom-btn {
+		width: 100%;
+		position: fixed;
+		bottom: 0;
+		display: flex;
+		z-index: 2;
+		left: 0;
+		background-color: #f8f8f8;
+		flex-direction: column;
+
+		.btn1,
+		.btn2 {
+			width: 100%;
+			margin-bottom: 26rpx;
+			border-radius: 90rpx;
+		}
+
+		.btn1 {
+			background: white;
+			color: #00C265;
+		}
+	}
+
+	.cancel,
+	.confirm {
+		position: absolute;
+		display: inline-block;
+		width: 50%;
+		text-align: center;
+		bottom: 0;
+		padding: 10px;
+		border-top: 1px solid #eee;
+		font-size: 34rpx;
+	}
+
+	.cancel {
+		left: 0;
+		border-right: 1px solid #eee;
+		color: #AFB3BF;
+	}
+
+	.confirm {
+		right: 0;
+		color: #22C572;
+	}
+
+	.u-textarea-style {
+		margin: 20rpx;
+		background: #F9F9FA;
+		border-radius: 10px;
+		border: 1px solid #EEEEEE;
+		padding: 10rpx 20rpx;
+		position: relative;
+
+		.right-bottom {
+			position: absolute;
+			right: 20rpx;
+			bottom: 20rpx;
+			color: #AFB3BF;
+		}
+	}
 </style>

+ 14 - 0
pages/task/my_task.vue

@@ -398,6 +398,10 @@
 								if (this.taskInfo[i].businessCode == 'TRAN-TASK-APPROVE') {
 									this.taskInfo[i].messageTitle = '运费设置'
 								}
+							}else if (this.taskInfo[i].businessType == 'ACQ') {
+								if (this.taskInfo[i].businessCode == 'ACQUISITION-SETTLEMENT-APPRPVE') {
+									this.taskInfo[i].messageTitle = '收购信息审核'
+								}
 							}
 						}
 						if (res.data.data.records.length == 0) {
@@ -540,6 +544,16 @@
 								"&isShowbtn=true"
 						})
 					}
+				}else if (item.businessCode == 'ACQUISITION-SETTLEMENT-APPRPVE') {
+					if (this.statusFlag == 1) {
+						uni.navigateTo({
+							url: `/pages/task/audit/acquisition_information_approval?id=` + item.businessId + "&isShowbtn=true"
+						})
+					} else {
+						uni.navigateTo({
+							url: `/pages/task/audit/acquisition_information_details?id=` + item.businessId + "&isShowbtn=true"
+						})
+					}
 				}
 				if (item.taskType == "入库任务") {
 

+ 141 - 1
pages/user/contractLook/purchaseContract.vue

@@ -1,8 +1,148 @@
 <template>
+	<view>
+		<view class='content'>
+			<view class='content-item' v-for='item in contractList'>
+				<view style='padding:10px 0;' class="flex justify-between">
+					<view class="title">合同编号</view>
+					<view>{{item.contractNo}}</view>
+				</view>
+				<view style='padding:10px 0;' class="flex justify-between">
+					<view class="title">客户</view>
+					<view>{{item.seller}}</view>
+				</view>
+				<view style='padding:10px 0;' class="flex justify-between">
+					<view class="title">合同重量(吨)</view>
+					<view>{{item.weight}}</view>
+				</view>
+				<view style='padding:10px 0;' class="flex justify-between">
+					<view class="title">合同单价(元)</view>
+					<view>{{item.unitContractPrice}}</view>
+				</view>
+				<view style='padding:10px 0;' class="flex justify-between">
+					<view class="title">合同总价(元)</view>
+					<view>{{item.totalContractPrice}}</view>
+				</view>
+				<view style='padding:10px 0;' class="flex justify-between">
+					<view class="title">已付款(元)</view>
+					<view>{{item.mildewGrain}}</view>
+				</view>
+				<view style='padding:10px 0;' class="flex justify-between">
+					<view class="title">已开发票 (元)</view>
+					<view>{{item.goodsNames}}</view>
+				</view>
+			</view>
+		</view>
+	</view>
 </template>
 
 <script>
+	export default {
+		data() {
+			return {
+				chartlist: [],
+				carCount1: '',
+				carCount2: '',
+				carCount3: '',
+				inventoryCost: '',
+				inventoryValue: '',
+				ZChart: {},
+				// url:"https://datav.aliyuncs.com/share/235518097ffd673bc1eb05011b9a02b6",
+				url: '',
+				flag: true,
+				chartData: {},
+				ringoptions: {},
+				contractType:2,
+				contractList:[],
+				currentPage:1,
+				pageSize:10
+			}
+		},
+		onLoad: function(option) {
+			uni.showLoading({
+				title: "加载中",
+				mask: true
+			})
+			this.init()
+		},
+		methods: {
+			skipContent(index){
+				console.log(index)
+				if(index<2){
+					uni.navigateTo({
+						url:'/pages/user/contractLook/purchaseContract'
+					})
+				}else if(index>2&&index<6){
+					uni.navigateTo({
+						url:'/pages/user/contractLook/salesContract'
+					})
+				}
+			},
+			init() {
+				this.$api.doRequest('get', '/contractManagementInfo/selectInfo',
+				{compId:uni.getStorageSync('pcUserInfo').compId,
+				contractType: this.contractType,goodsType:1,currentPage: this.currentPage,pageSize: this.pageSize}).then(res => {
+					uni.hideLoading()
+					this.contractList=res.data.data.records
+				})
+			},
+			getdata(e) {
+				console.log(e)
+			}
+		}
+	}
 </script>
 
-<style>
+
+
+<style scoped lang="scss">
+	.content{
+		background:#F5F6FA;
+	}
+	.content-item{
+		background:#fff;
+		margin:10px;
+		padding:10px;
+		border-radius:6px;
+		font-size:14px;
+		.title {
+			color:#9698A2;
+			font-size:26rpx;
+		}
+	}
+	charts-box {
+		// background: black;
+		position: relative;
+		// top: 70vh;
+	}
+
+	.content2 .row,
+	.content4 .row {
+		display: flex;
+		justify-content: space-around;
+		background: #24262d;
+		padding: 40rpx 20rpx;
+
+		.item-top,
+		.item-bottom {
+			color: #d5d5d5;
+		}
+
+		.item-bottom {
+			display: flex;
+			align-items: center;
+		}
+	}
+
+	.bottom-tip {
+		position: absolute;
+		z-index: 11;
+		color: #8c8c8d;
+		right: 10px;
+		bottom: 10px;
+	}
+
+	.title-margin {
+		bottom: 120rpx;
+	}
 </style>
+

+ 148 - 1
pages/user/contractLook/salesContract.vue

@@ -1,8 +1,155 @@
 <template>
+	<view class='content'>
+		<view v-for='item in contractList'>
+			<view class="flex justify-between">
+				<view>合同编号</view>
+				<view>{{item.contractNo}}</view>
+			</view>
+			<view class="flex justify-between">
+				<view>客户</view>
+				<view>{{item.seller}}</view>
+			</view>
+			<view class="flex justify-between">
+				<view>合同重量(吨)</view>
+				<view>{{item.weight}}</view>
+			</view>
+			<view class="flex justify-between">
+				<view>合同单价(元)</view>
+				<view>{{item.unitContractPrice}}</view>
+			</view>
+			<view class="flex justify-between">
+				<view>合同总价(元)</view>
+				<view>{{item.totalContractPrice}}</view>
+			</view>
+			<view class="flex justify-between">
+				<view>已付款(元)</view>
+				<view>{{item.mildewGrain}}</view>
+			</view>
+			<view class="flex justify-between">
+				<view>已开发票 (元)</view>
+				<view>{{item.goodsNames}}</view>
+			</view>
+		</view>
+	</view>
 </template>
 
 <script>
+	export default {
+		data() {
+			return {
+				chartlist: [],
+				carCount1: '',
+				carCount2: '',
+				carCount3: '',
+				inventoryCost: '',
+				inventoryValue: '',
+				ZChart: {},
+				// url:"https://datav.aliyuncs.com/share/235518097ffd673bc1eb05011b9a02b6",
+				url: '',
+				flag: true,
+				chartData: {},
+				ringoptions: {},
+				contractType:2,
+				contractList:[],
+				currentPage:1,
+				pageSize:10
+			}
+		},
+		onLoad: function(option) {
+			uni.showLoading({
+				title: "加载中",
+				mask: true
+			})
+			this.init()
+		},
+		methods: {
+			skipContent(index){
+				console.log(index)
+				if(index<2){
+					uni.navigateTo({
+						url:'/pages/user/contractLook/purchaseContract'
+					})
+				}else if(index>2&&index<6){
+					uni.navigateTo({
+						url:'/pages/user/contractLook/salesContract'
+					})
+				}
+			},
+			init() {
+				this.$api.doRequest('get', '/contractManagementInfo/selectInfo',
+				{compId:uni.getStorageSync('pcUserInfo').compId,
+				contractType: this.contractType,goodsType:1,currentPage: this.currentPage,pageSize: this.pageSize}).then(res => {
+					uni.hideLoading()
+					this.contractList=res.data.data.records
+				})
+			},
+			getdata(e) {
+				console.log(e)
+			}
+		}
+	}
 </script>
 
-<style>
+
+
+<style scoped lang="scss">
+	.content{
+		
+	}
+	.map {
+		top: 90rpx;
+		height: 60vh;
+		width: 100%;
+		border: 0;
+	}
+
+	.title {
+		background: black;
+		color: white;
+		text-align: center;
+		font-size: 1.25rem;
+		padding: 0.625rem;
+	}
+
+	.content {
+		background: #fff;
+		padding-bottom: 100rpx;
+	}
+
+	.charts-box {
+		// background: black;
+		position: relative;
+		// top: 70vh;
+	}
+
+	.content2 .row,
+	.content4 .row {
+		display: flex;
+		justify-content: space-around;
+		background: #24262d;
+		padding: 40rpx 20rpx;
+
+		.item-top,
+		.item-bottom {
+			color: #d5d5d5;
+		}
+
+		.item-bottom {
+			display: flex;
+			align-items: center;
+		}
+	}
+
+	.bottom-tip {
+		position: absolute;
+		z-index: 11;
+		color: #8c8c8d;
+		right: 10px;
+		bottom: 10px;
+	}
+
+	.title-margin {
+		bottom: 120rpx;
+	}
 </style>
+

+ 13 - 1
pages/user/report.vue

@@ -2,7 +2,7 @@
 	<view class="content">
 		<view class="title">库点流向分布</view>
 		<iframe id="mainIframe" ref="mainIframe" name="mainIframe" :src="url" class="map"></iframe>
-		<view class="charts-box" v-for="(item,index) in chartlist" :key='index'>
+		<view @click='skipContent(index)' class="charts-box" v-for="(item,index) in chartlist" :key='index'>
 			<div class="bottom-tip" v-if='index==0||index==3'>统计单位:吨</div>
 			<div class="bottom-tip" v-if='index!=0&&index!=3' :class='index==2?"title-margin":""'>统计单位:元</div>
 			<view v-if="index==0" class="title">采购合同完成进度</view>
@@ -84,6 +84,18 @@
 			this.init()
 		},
 		methods: {
+			skipContent(index){
+				console.log(index)
+				if(index<2){
+					uni.navigateTo({
+						url:'/pages/user/contractLook/purchaseContract'
+					})
+				}else if(index>2&&index<6){
+					uni.navigateTo({
+						url:'/pages/user/contractLook/salesContract'
+					})
+				}
+			},
 			init() {
 				this.$api.doRequest('get', '/biInfoController/selectBiInfo?compId='+uni.getStorageSync('pcUserInfo').compId).then(res => {
 					console.log(res)