From 3539a3d350c9d5fa51871fa44a2745474c721410 Mon Sep 17 00:00:00 2001
From: yangan <yangan0921@163.com>
Date: 星期一, 02 十二月 2024 17:36:25 +0800
Subject: [PATCH] feat:电子提煤单下载

---
 pages/sampling-page/index.vue |   82 ++++++++++++++++++++++++++++++++++++++--
 1 files changed, 77 insertions(+), 5 deletions(-)

diff --git a/pages/sampling-page/index.vue b/pages/sampling-page/index.vue
index 1c1c164..b31a572 100644
--- a/pages/sampling-page/index.vue
+++ b/pages/sampling-page/index.vue
@@ -12,10 +12,12 @@
 						iconSize="1000"
 						v-if="CoalNameList.length == 0"></u-empty>
 				</view> -->
+				
                 <view class="title"><u-icon  size='26' color="#" name="order"></u-icon><i>寰呮鍖�</i></view>
 				<view class="body">
 					<!-- <selectTarget ref='selectTarget'></selectTarget> -->
                     <view class="collection-form">
+						<u-tabs :list="tabList" :activeStyle="{fontSize:'26rpx'} " @click="tabClick"></u-tabs>
                         <view style="position: relative;">
 					<u-empty mode="data"
 						icon="http://cdn.uviewui.com/uview/empty/data.png"
@@ -73,7 +75,7 @@
 						<view class="third-line">
 							<view class="time-icon">
 								<view
-									style="width: 24rpx;height: 24rpx;li ne-height: 24rpx;background: url('https://mr1.res.jzeg.cn:9096/appimg/image/banner/clock.png') no-repeat;background-size: cover">
+									style="width: 24rpx;height: 24rpx;line-height: 24rpx;background: url('https://mr1.res.jzeg.cn:9096/appimg/image/banner/clock.png') no-repeat;background-size: cover">
 								</view>
 							</view>
 							<view class="send-date">{{ item.sendDate }}</view>
@@ -87,6 +89,7 @@
 							</view>
 						</view>
 					</view>
+					<view class="bottom"></view>
                     
 				</view>
 				</view>
@@ -121,9 +124,20 @@
 		data() {
 			return {
                 orderPlanData:[],
+				tagName:'澶栭攢',
                 activeObj:{},
 				timer:null,
                 showFlag:false,
+				tabList:[{
+					name:'澶栭攢'
+						},
+						{
+							name:'澶栬喘'
+						},
+						{
+							name:'鍐呰喘'
+						}
+					]
 			};
 		},
 		onLoad() {
@@ -132,7 +146,16 @@
 		methods: {
 			init() {
 				this.$nextTick(() => {
-					this.getListData();
+					if(this.tagName == '澶栬喘'){
+						this.getWaiData();
+					}else if(this.tagName == '鍐呰喘'){
+						this.getNeiData();
+					} else{
+						this.getListData();
+					}
+					
+					
+					
 				})
 			},
             getListData(){
@@ -174,13 +197,59 @@
 			timerFun(){
 			this.timer = window.setInterval(() => {
 					setTimeout(() => {
-						this.getListData() //璋冪敤鎺ュ彛鐨勬柟娉�
+						if(this.tagName == '澶栬喘'){
+							this.getWaiData()
+						}else if(this.tagName == '鍐呰喘'){
+							this.getNeiData();
+						}
+						else{
+							this.getListData() //璋冪敤鎺ュ彛鐨勬柟娉�
+						}
 						console.log(1111111111)
 					}, 0)
-				}, 10000);
+				}, 60000);
 			},
 			clearTime(){
 				window.clearInterval(this.timer)
+			},
+			tabClick(val){
+				console.log(val,'valll')
+					this.tagName = val.name;
+					if(val.name == '澶栬喘'){
+						this.getWaiData();
+					}else if(val.name === '鍐呰喘'){
+						this.getNeiData();
+					}
+					else{
+						this.getListData();
+					}
+				
+
+			},
+			getWaiData(){
+				this.$reqGet('inspectedTaskPage',{inspectionStatus:1,orderType:'澶栬喘'}).then(res=>{
+							if(res.code == 0){
+						if(res.data.records.length){
+							this.orderPlanData  = res.data.records;
+						}else{
+							this.orderPlanData = [];
+						}
+                     
+                    }
+						})
+			},
+			//鍐呰喘
+			getNeiData(){
+				this.$reqGet('inspectedTaskPage',{inspectionStatus:1,orderType:'鍐呰喘'}).then(res=>{
+							if(res.code == 0){
+						if(res.data.records.length){
+							this.orderPlanData  = res.data.records;
+						}else{
+							this.orderPlanData = [];
+						}
+                     
+                    }
+						})
 			}
 		},  
 	}
@@ -237,15 +306,18 @@
 	}
     .body{
         position: absolute;
-        height: 500rpx;
         top: 38%;
         width: 97%;
         left: 50%;
         margin-left: -47%;
+	
         // box-shadow: 0 2px 18px 0 rgba(0, 0, 0, .2);
         // background: #fff;
         border-radius: 20rpx;
     }
+	.bottom{
+		height: 200rpx;
+	}
     .title{
         position: absolute;
         top: 34%;

--
Gitblit v1.9.1