From dbae85a492c7cee07f1115757615df910583ad8a Mon Sep 17 00:00:00 2001
From: 小小儁爺 <1694218219@qq.com>
Date: 星期一, 05 一月 2026 10:59:24 +0800
Subject: [PATCH] 1.递交

---
 pages/scgl/scbg.vue |  114 +++++++++++++++++++++++++++++++++++++++++++-------------
 1 files changed, 87 insertions(+), 27 deletions(-)

diff --git a/pages/scgl/scbg.vue b/pages/scgl/scbg.vue
index ecb87a3..53fa0ef 100644
--- a/pages/scgl/scbg.vue
+++ b/pages/scgl/scbg.vue
@@ -40,8 +40,11 @@
 		<!-- 鎶樺彔闈㈡澘 -->
 		<!-- <u-collapse @change="change" @close="close" @open="open"> -->
 		<!-- @change="collapseChange" -->
-		<u-collapse style="max-height: 590px;overflow: auto;">
+
+
+		<u-collapse style="max-height: 62vh;overflow: auto;">
 			<!-- :value='parseFloat(item.ordergoodqty)+"/"+parseFloat(item.orderqty)' -->
+			<!-- 	<scroll-view scroll-y :style="{height: 590 + 'px'}" @scrolltolower="loadMore"> -->
 			<u-collapse-item style="position: relative;" :title="item.ordercode" :name='item.ordercode'
 				v-if='item.children.length!==0' :value='parseFloat(item.ordergoodqty)+"/"+parseFloat(item.orderqty)'
 				:label="item.children.length===0?'鏈淳鍙�':''" :disabled='item.children.length===0'
@@ -121,8 +124,16 @@
 
 
 			</u-collapse-item>
-
+			<!-- </scroll-view> -->
 		</u-collapse>
+
+
+
+
+		<view class="uni-pagination-box">
+			<uni-pagination show-icon :page-size="pageSize" :current="currentpage" :total="total"
+				@change="pageChange" />
+		</view>
 
 
 		<!-- 寮瑰嚭灞� -->
@@ -144,6 +155,10 @@
 					</u-radio-group>
 				</view>
 
+				<u--input :placeholder="'璇疯緭鍏�'+placeholder2" style="border: 1rpx solid #eee;" :clearable='true'
+					v-model="order"></u--input>
+
+
 				<view style="margin-top: 20px;display: flex;align-items: center;">
 
 					<view class="">
@@ -156,6 +171,7 @@
 
 				</view>
 
+
 				<view style="display: flex;flex-wrap: wrap;">
 					<u-tag style="width:220rpx;" :text="item.name" v-for="item in tagArr" :key="item.code"
 						:closable="true" :show="item.close" @close="tagClose(item)"></u-tag>
@@ -163,7 +179,7 @@
 
 
 
-				<view class="head" style="margin-top: 10px;">
+				<!-- 		<view class="head" style="margin-top: 10px;">
 					<view class="head_block" style="height: 80rpx; display: flex;justify-content: space-around;">
 						<u-button :plain='today' style="width: 70px;height: 25px;" @click="dateChange('today')"
 							type="primary" shape="circle" text="浠婃棩">
@@ -174,9 +190,9 @@
 						<u-button :plain='custom' style="width: 70px;height: 25px;" @click="dateChange('custom')"
 							type="primary" shape="circle" text="鑷畾涔�"></u-button>
 					</view>
-				</view>
+				</view> -->
 
-				<view v-if="!custom" class="flex_column"
+				<!-- 				<view v-if="!custom" class="flex_column"
 					style="display: flex;justify-content: space-around;width: 100%;">
 					<view class="" style="display: flex;justify-content: space-evenly;width: 100%;">
 						<view class="titleFont">寮�濮嬫棩鏈�</view>
@@ -189,7 +205,7 @@
 					</u-button>
 				</view>
 
-				<uni-calendar ref="calendar" :range='true' :insert="false" @confirm="calendarConfirm" />
+				<uni-calendar ref="calendar" :range='true' :insert="false" @confirm="calendarConfirm" /> -->
 
 			</view>
 		</u-popup>
@@ -202,21 +218,30 @@
 		<view @click="scan2">
 			<drag-ball :x='300' :y="600"></drag-ball>
 		</view>
+
+
+		<scan-code></scan-code>
+
 	</view>
 </template>
 
 
 <script>
 	import {
-		ProductionScheduleKanban
+		ProductOrderSearch
 	} from '../../config/api.js';
+	import scanCode from '@/components/scan-code/scan-code.vue'
+
 	export default {
+		components: {
+			scanCode
+		},
 		onLoad(option) {
 			const _this = this
 			uni.$off('scancodedate') // 姣忔杩涙潵鍏� 绉婚櫎鍏ㄥ眬鑷畾涔変簨浠剁洃鍚櫒
 			uni.$on('scancodedate', function(content) {
 				console.log("鎵弿鍒扮殑鍐呭涓�:", content)
-				_this.getCheckScanDeviceQrCodeData(content)
+				// _this.getCheckScanDeviceQrCodeData(content)
 			})
 
 
@@ -288,7 +313,11 @@
 					// 	code: '1006'
 					// },
 				], //宸查�変腑鐨勪骇鍝佹爣绛�
-
+				order: '', //鍗曞彿
+				placeholder2: '鐢熶骇璁㈠崟',
+				total: 10,
+				currentpage: 1, //绗嚑椤�
+				pageSize: 10, //姣忛〉鏄剧ず澶氬皯鏉�
 
 			}
 		},
@@ -297,7 +326,7 @@
 			let that = this
 			uni.startPullDownRefresh({
 				success() {
-					that.getProductionScheduleKanban()
+					that.getProductOrderSearch(that.currentpage)
 					uni.showToast({
 						title: "涓嬫媺鍒锋柊",
 						icon: 'none'
@@ -314,7 +343,7 @@
 		mounted() {
 			this.init()
 
-			this.getProductionScheduleKanban()
+			this.getProductOrderSearch(1)
 		},
 		methods: {
 			init() {
@@ -346,8 +375,14 @@
 				})
 			},
 
+			// 椤垫暟鏀瑰彉鏃�  鍒嗛〉瑙﹀彂
+			pageChange(e) {
+				this.currentpage = e.current
+				this.getProductOrderSearch(e.current)
+			},
+
 			// 鎺ュ彛鑾峰彇
-			async getProductionScheduleKanban() {
+			async getProductOrderSearch(current) {
 				let ordertype = '' // SO锛氶攢鍞鍗�  MO锛氱敓浜ц鍗�  PO锛氱敓浜у伐鍗�
 				switch (this.radiovalue) {
 					case '鐢熶骇宸ュ崟':
@@ -356,12 +391,14 @@
 						ordertype = 'PO'
 						break
 					case '鐢熶骇璁㈠崟':
-						this.alertTitle = '鐢熶骇璁㈠崟鏁伴噺锛堝叡/涓級'
+						// this.alertTitle = '鐢熶骇璁㈠崟鏁伴噺锛堝叡/涓級'
+						this.alertTitle = '宸ュ崟鏁伴噺锛堝叡/涓級'
 						this.placeholder = '璇疯緭鍏ョ敓浜ц鍗曚俊鎭�'
 						ordertype = 'MO'
 						break
 					case '閿�鍞鍗�':
-						this.alertTitle = '閿�鍞鍗曟暟閲忥紙鍏�/涓級'
+						// this.alertTitle = '閿�鍞鍗曟暟閲忥紙鍏�/涓級'
+						this.alertTitle = '宸ュ崟鏁伴噺锛堝叡/涓級'
 						this.placeholder = '璇疯緭鍏ラ攢鍞鍗曚俊鎭�'
 						ordertype = 'SO'
 						break
@@ -371,20 +408,29 @@
 				const data = {
 					ordertype,
 					partcode: this.tagArr.map(i => i.code).join(','),
-					Ratetime: this.calendarRange,
+					ordercode: this.order,
+					Ratetime: '',
+					// Ratetime: this.calendarRange,
+
+					page: current,
+					rows: this.pageSize,
+					prop: 'lm_date',
+					sortorder: 'desc'
 
 				}
-				const {
-					data: res
-				} = await ProductionScheduleKanban(data)
+				const res = await ProductOrderSearch(data)
 
-				this.collapseArr = res
-				this.collapseArrAll = res
-				this.alertTitle = this.alertTitle.split('/')[0] + this.collapseArr.length + this.alertTitle.split('/')[
+				this.total = res.count
+
+				this.collapseArr = res.data
+				this.collapseArrAll = res.data
+				this.alertTitle = this.alertTitle.split('/')[0] + this.total + this.alertTitle.split('/')[
 					1]
 
 			},
+			loadMore() {
 
+			},
 
 			//杈撳叆妗嗗洖杞︾‘璁や簨浠�
 			confirmInputBoxValue(val) {
@@ -395,17 +441,20 @@
 
 				switch (this.radiovalue) {
 					case '鐢熶骇宸ュ崟':
-						this.alertTitle = '宸ュ崟鏁伴噺锛堝叡/涓級'
+						this.alertTitle = '宸ュ崟鏁伴噺锛堝叡' + this.total + '涓級'
 						break
 					case '鐢熶骇璁㈠崟':
-						this.alertTitle = '鐢熶骇璁㈠崟鏁伴噺锛堝叡/涓級'
+						this.alertTitle = '宸ュ崟鏁伴噺锛堝叡' + this.total + '涓級'
 						break
 					case '閿�鍞鍗�':
-						this.alertTitle = '閿�鍞鍗曟暟閲忥紙鍏�/涓級'
+						this.alertTitle = '宸ュ崟鏁伴噺锛堝叡' + this.total + '涓級'
 						break
 				}
-				this.alertTitle = this.alertTitle.split('/')[0] + this.collapseArr.length + this.alertTitle.split('/')[
-					1]
+
+
+
+				// this.alertTitle = this.alertTitle.split('/')[0] + this.collapseArr.length + this.alertTitle.split('/')[
+				// 	1]
 
 			},
 
@@ -476,7 +525,7 @@
 
 			// 寮瑰嚭灞傛敹璧�
 			popupClose() {
-				this.getProductionScheduleKanban()
+				this.getProductOrderSearch(1)
 				this.popupShow = false
 			},
 
@@ -561,6 +610,7 @@
 			// 鍗曢�夋寜閽垏鎹�
 			groupChange(val) {
 				console.log(val)
+				this.placeholder2 = val
 			},
 
 
@@ -653,4 +703,14 @@
 	::v-deep .u-cell__body {
 		padding-bottom: 40rpx;
 	}
+
+	.uni-pagination-box {
+		height: 4vh;
+		margin: 1vh 0;
+
+		display: flex;
+		align-items: center;
+		justify-content: center;
+		// background-color: #fff;
+	}
 </style>
\ No newline at end of file

--
Gitblit v1.9.3