Pārlūkot izejas kodu

修改审核问题

Alex 10 mēneši atpakaļ
vecāks
revīzija
00c7dcdbae

+ 71 - 75
pages/index/audit/express-order.vue

@@ -1,92 +1,88 @@
 <template>
-	<view class="container">
+    <view class="container">
 
-		<!-- 底部按钮 -->
-		<view class="footer">
-			<!-- 查询区域 -->
-			<view class="query-section">
-				<u-radio-group v-model="form.searchType">
-					<u-radio label="查订单" name="1" label-size="17" />
-					<u-radio label="查物流" custom-style="margin-left:20px" name="2" label-size="17" />
-				</u-radio-group>
+        <!-- 底部按钮 -->
+        <view class="footer">
+            <!-- 查询区域 -->
+            <view class="query-section">
+                <u-radio-group v-model="form.searchType">
+                    <u-radio label="查订单" name="1" label-size="17" />
+                    <u-radio label="查物流" custom-style="margin-left:20px" name="2" label-size="17" />
+                </u-radio-group>
 
-				<view class="search-box">
-					<u-input custom-style="width:100rpx" v-model="form.search" :placeholder="form.searchType == '1' ? '扫描/输入订单编号' : '扫描/输入物流单号'" border="surround"
-						clearable placeholder-style="font-size:32rpx" :custom-style="{ 'font-size': '32rpx' }">
-					</u-input>
-					<u-button color="#c8c8c8" text="查询" @click="handleSearch" />
-				</view>
-			</view>
+                <view class="search-box">
+                    <u-input custom-style="width:100rpx" v-model="form.search"
+                        :placeholder="form.searchType == '1' ? '扫描/输入订单编号' : '扫描/输入物流单号'" border="surround" clearable
+                        placeholder-style="font-size:32rpx" :custom-style="{ 'font-size': '32rpx' }">
+                    </u-input>
+                    <u-button color="#c8c8c8" text="查询" @click="handleSearch" />
+                </view>
+            </view>
 
-			<u-divider></u-divider>
+            <u-divider></u-divider>
 
-			<view style="display: flex;">
-				<u-button size="large" type="success" text="扫码" @click="handleScan" />
-			</view>
-		</view>
-	</view>
+            <view style="display: flex;">
+                <u-button size="large" type="success" text="扫码" @click="handleScan" />
+            </view>
+        </view>
+    </view>
 </template>
 
 <script setup>
-	import {
-		ref
-	} from 'vue';
-	import {
-		onLoad
-	} from '@dcloudio/uni-app'
+import {
+    ref
+} from 'vue';
+import {
+    onLoad
+} from '@dcloudio/uni-app'
 
-	const form = ref({
-		searchType: '2',
-		search: ''
-	});
+const form = ref({
+    searchType: '2',
+    search: ''
+});
 
-	// 处理查询
-	const handleSearch = () => {
-		console.log('查询:', form.value.search);
-		// TODO: 查询订单
-		uni.$u.http.get('/app/orderinfo/getOrderInfoForCheck', {
-			params: {
-				...form.value
-			}
-		}).then(res => {
-			if (res.code == 200) {
-				uni.setStorageSync('orderDetail', res.data)
-				uni.navigateTo({
-					url: `/pages/index/detail/index?id=${res.data.orderId}`
-				})
-			} else {
-				if (res.code == 500) {
-					let text = form.value.search + '订单不存在'
-					uni.$u.ttsModule.speak(text)
-				} else {
-					uni.$u.toast(res.msg)
-					uni.$u.ttsModule.speak(res.msg)
-				}
-			}
-		})
-	};
+// 处理查询
+const handleSearch = () => {
+    console.log('查询:', form.value.search);
+    // TODO: 查询订单
+    uni.$u.http.get('/app/orderinfo/getOrderInfoForCheck', {
+        params: {
+            ...form.value
+        }
+    }).then(res => {
+        if (res.code == 200) {
+            uni.setStorageSync('orderDetail', res.data)
+            uni.navigateTo({
+                url: `/pages/index/detail/index?id=${res.data.orderId}`
+            })
+        } else {
+            let text = form.value.search + res.msg
+            uni.$u.ttsModule.speak(text)
+        }
+    })
+};
 
-	// 处理扫码
-	const handleScan = () => {
-		uni.scanCode({
-			success: (res) => {
-				form.value.search = res.result;
-				handleSearch();
-			}
-		});
-	}
+// 处理扫码
+const handleScan = () => {
+    uni.scanCode({
+        success: (res) => {
+            form.value.search = res.result;
+            handleSearch();
+        }
+    });
+}
 
 
-	onLoad(() => {
-		// #ifdef APP-PLUS
-		uni.$u.useGlobalEvent((e) => {
-			form.value.search = e.barcode
-			handleSearch()
-		})
-		// #endif
-	})
+onLoad(() => {
+    // #ifdef APP-PLUS
+    uni.$u.useGlobalEvent((e) => {
+        form.value.search = e.barcode
+        handleSearch()
+    })
+    // #endif
+})
 </script>
 
 <style lang="scss" scoped>
-	@import '../components/common.scss';
+@import '../components/common.scss';
 </style>

+ 1 - 1
pages/index/audit/sender.vue

@@ -1,7 +1,7 @@
 <template>
     <view class="common-page" style="padding: 0;">
         <PageScroll requestStr="/app/orderinfo/getOrderListByUserInfo" @updateList="updateList" ref="scrollRef"
-            :otherParams="otherParams">
+            :otherParams="otherParams" :immediate="false">
             <u-sticky :customNavHeight="0">
                 <view class="search-area">
                     <u-search placeholder="请输入发件人姓名或电话" :searchIconSize="18" bgColor="#f6f7f6" @search="handleSearch"

+ 18 - 14
pages/index/detail/batch-audit.vue

@@ -1,6 +1,7 @@
 <template>
     <view class="batch-audit">
-        <BookItem v-for="item in scannedBooksDetail" :key="item.isbn" :item="item" showClose />
+        <BookItem v-for="(item, index) in scannedBooksDetail" :key="item.isbn" :item="item" showClose
+            @close="(isbn) => handleClose(index, isbn)" />
 
         <view class="fixed-bottom">
             <u-button type="warning" size="large" @click="handleScanCode">扫码</u-button>
@@ -39,10 +40,15 @@ const getBookInfo = (isbn) => {
         }
     })
 }
+
+const handleClose = (index, isbn) => {
+    scannedBooksDetail.value.splice(index, 1)
+    scannedBooks.value = scannedBooks.value.filter(item => item != isbn)
+}
 //isbn正则校验是否符合
 function checkIsbn(isbn) {
-    let reg = /(?:[0-9]+\-?){9}[0-9X]|(?:978|979)\-?(?:[0-9]+\-?){10}/
-    if (reg.test(isbn)) {
+    const isbn13Regex = /^(?:97[89]-?\d{1,5}-?\d{1,7}-?\d{1,6}-?\d)$/;
+    if (isbn13Regex.test(isbn)) {
         return true
     }
     return false
@@ -59,31 +65,25 @@ function handleScan(isbn) {
 
     let isbns = orderDetail.value.detailVoList.map(item => item.isbn)
     //订单总数本
-    let totalNum = orderDetail.value.totalNum
     if (isbns.includes(isbn)) {
         let book = orderDetail.value.detailVoList.find(item => item.isbn == isbn)
-        if (book.num == book.auditCommentList?.length) {
+
+        if (book.auditCommentList?.length > 0) {
             let text = ''
             if (book.auditCommentList.every(item => item.sts == 1)) {
                 text = `${isbn}已审核为良好`
                 uni.$u.ttsModule.speak(text)
                 return
-            } else {
-                text = `${isbn}已审核为极差`
-                scannedBooks.value.push(isbn)
-                uni.$u.ttsModule.speak(text)
-                getBookInfo(isbn)
             }
-        } else {
+
             //已审核数量
-            let hasAuditNum = book.auditCommentList?.length || 0
+            let hasAuditNum = book.auditCommentList.filter(item => item.sts !== 0).length || 0
             //未审核数量
-            let notAuditNum = book.num - hasAuditNum
+            let notAuditNum = book.auditCommentList.filter(item => item.sts === 0).length || 0
             //极差数量
             let poorNum = book.auditCommentList?.filter(item => item.sts == 3).length || 0
             //已扫描书籍中当前isbn的数量
             let scannedNum = scannedBooks.value.filter(item => item == isbn).length || 0
-            console.log(scannedNum,poorNum,notAuditNum, 'scannedNum')
 
             if (scannedNum >= notAuditNum + poorNum) {
                 let text = `${isbn}已超出订单中的数量`
@@ -187,6 +187,10 @@ onLoad((options) => {
     })
     // #endif
 })
+onShow(() => {
+    checkUserId.value = uni.getStorageSync('userInfo')?.userId
+    orderDetail.value = uni.getStorageSync('orderDetail')
+})
 </script>
 
 

+ 15 - 25
pages/index/detail/book-audit.vue

@@ -14,21 +14,21 @@
             <view class="flex">
                 <view class="flex flex-a-c flex-1">
                     <text class="label">定价</text>
-                    <text class="content">{{ detail.price }}</text>
+                    <text class="content">¥{{ detail.price }}</text>
                 </view>
                 <view class="flex flex-a-c flex-1">
                     <text class="label">回收折扣</text>
-                    <text class="content">{{ detail.recycleDiscount }}</text>
+                    <text class="content">{{ detail.recycleDiscount }}</text>
                 </view>
             </view>
             <view class="flex flex-a-c">
                 <view class="flex flex-a-c flex-1">
                     <text class="label">预估金额</text>
-                    <text class="content">{{ detail.price }}</text>
+                    <text class="content">¥{{ auditBook.expectMoney }}</text>
                 </view>
                 <view class="flex flex-a-c flex-1">
                     <text class="label">审核金额</text>
-                    <text class="content">{{ '0.00' }}</text>
+                    <text class="content">¥{{ auditBook.finalMoney }}</text>
                 </view>
             </view>
         </view>
@@ -36,7 +36,7 @@
         <view class="mt-20">
             <u-subsection :list="list" mode="subsection" :current="current"
                 @change="handleSectionChange"></u-subsection>
-            <AuditInfo v-if="current == 0" :detail="auditBook"  ref="auditInfoRef" />
+            <AuditInfo v-if="current == 0" :detail="auditBook" ref="auditInfoRef" />
             <FileInfo v-if="current == 2" :orderId="orderId" :annexType="2" :isbn="auditBook.isbn" />
         </view>
 
@@ -74,7 +74,7 @@ const auditData = ref([])
 const handleAuditSelected = (data) => {
     auditData.value = data.map((item, index) => {
         item.idx = index
-        console.log(index,item.com, 'item.com',Array.isArray(item.com))
+        console.log(index, item.com, 'item.com', Array.isArray(item.com))
         item.com = Array.isArray(item.com) ? item.com.join(',') : item.com
         return item
     })
@@ -85,8 +85,8 @@ const handleAuditSelected = (data) => {
 const scannedBooks = ref([])
 //isbn正则校验是否符合
 function checkIsbn(isbn) {
-    let reg = /(?:[0-9]+\-?){9}[0-9X]|(?:978|979)\-?(?:[0-9]+\-?){10}/
-    if (reg.test(isbn)) {
+    const isbn13Regex = /^(?:97[89]-?\d{1,5}-?\d{1,7}-?\d{1,6}-?\d)$/;
+    if (isbn13Regex.test(isbn)) {
         return true
     }
     return false
@@ -100,31 +100,22 @@ function handleScan(isbn) {
     }
 
     let isbns = orderDetail.value.detailVoList.map(item => item.isbn)
-    //订单总数本
-    let totalNum = orderDetail.value.totalNum
 
     if (isbns.includes(isbn)) {
         let book = orderDetail.value.detailVoList.find(item => item.isbn == isbn)
-        if (book.num == book.auditCommentList?.length) {
+
+        if (book.auditCommentList?.length > 0) {
             let text = ''
             if (book.auditCommentList.every(item => item.sts == 1)) {
                 text = `${isbn}已审核为良好`
                 uni.$u.ttsModule.speak(text)
                 return
-            } else {
-                text = `${isbn}已审核为极差`
-                scannedBooks.value.push(isbn)
-                uni.$u.ttsModule.speak(text)
-                uni.setStorageSync('scannedBooks', scannedBooks.value)
-                uni.navigateTo({
-                    url: `/pages/index/detail/batch-audit?orderId=${orderId.value}`
-                })
             }
-        } else {
+           
             //已审核数量
-            let hasAuditNum = book.auditCommentList?.length || 0
+            let hasAuditNum = book.auditCommentList.filter(item => item.sts !== 0).length || 0
             //未审核数量
-            let notAuditNum = book.num - hasAuditNum
+            let notAuditNum = book.auditCommentList.filter(item => item.sts === 0).length || 0
             //极差数量
             let poorNum = book.auditCommentList?.filter(item => item.sts == 3).length || 0
             //已扫描书籍中当前isbn的数量
@@ -150,15 +141,12 @@ function handleScan(isbn) {
                 }
 
                 scannedBooks.value.push(isbn)
-                console.log(scannedBooks.value, 'book-audit')
                 uni.setStorageSync('scannedBooks', scannedBooks.value)
                 uni.navigateTo({
                     url: `/pages/index/detail/batch-audit?orderId=${orderId.value}`
                 })
             }
         }
-
-
     } else {
         let text = `此订单中不存在${isbn}这本书 `
         uni.$u.ttsModule.speak(text)
@@ -222,6 +210,8 @@ onLoad((options) => {
 })
 onShow(() => {
     checkUserId.value = uni.getStorageSync('userInfo')?.userId
+    auditBook.value = uni.getStorageSync('auditBook')
+    orderDetail.value = uni.getStorageSync('orderDetail')
 })
 </script>
 

+ 36 - 21
pages/index/detail/components/BookInfo.vue

@@ -82,33 +82,47 @@ const formatBookList = (list) => {
     //获取所有的首字母
     const allFirstLetter = [];
 
+    const handleBookCategorization = (book) => {
+        let firstLetter;
+        const char = book.bookName.charAt(0);
+        if (/^[A-Za-z]$/.test(char)) {
+            firstLetter = char.toUpperCase();
+        } else if (/^[\u4E00-\u9FA5]$/.test(char)) { //中文
+            firstLetter = toPinyin.chineseToInitials(toPinyin.chineseToPinYin(char));
+        } else {
+            firstLetter = char
+        }
+        let bool = otherBooks.some(item => item.title == firstLetter);
+        if (!bool) {
+            otherBooks.push({ id: firstLetter, title: firstLetter, list: [{ ...book }] });
+            allFirstLetter.push(firstLetter)
+            emit('get-all-firstLetter', allFirstLetter)
+        } else {
+            otherBooks.find(item => item.title == firstLetter).list.push(book);
+        }
+    };
+
     list.forEach(book => {
+        console.log(book, 'book')
         book.goodNum = book.auditCommentList?.filter(v => v.sts == 1).length || 0
         book.badNum = book.auditCommentList?.filter(v => v.sts == 3).length || 0
 
-        if (book.badNum > 0) {
-            poorBooks.list.push(book);
-        } else if (book.goodNum > 0) {
-            goodBooks.list.push(book);
-        } else {
-            let firstLetter;
-            const char = book.bookName.charAt(0);
-            if (/^[A-Za-z]$/.test(char)) {
-                firstLetter = char.toUpperCase();
-            } else if (/^[\u4E00-\u9FA5]$/.test(char)) { //中文
-                firstLetter = toPinyin.chineseToInitials(toPinyin.chineseToPinYin(char));
+        // Check if book is fully audited (all items have been reviewed)
+        const totalAudited = book.auditCommentList?.filter(v => v.sts !== 0).length || 0;
+        const isFullyAudited = totalAudited === book.num;
+
+        if (isFullyAudited) {
+            // If any audit result is poor (sts === 3), push to poorBooks
+            if (book.auditCommentList.some(v => v.sts === 3)) {
+                poorBooks.list.push(book);
+            } else if (book.auditCommentList.every(v => v.sts === 1)) {
+                // If all audit results are good (sts === 1), push to goodBooks
+                goodBooks.list.push(book);
             } else {
-                firstLetter = char
-            }
-            let bool = otherBooks.some(item => item.title == firstLetter);
-            if (!bool) {
-                otherBooks.push({ id: firstLetter, title: firstLetter, list: [{ ...book }] });
-                allFirstLetter.push(firstLetter)
-
-                emit('get-all-firstLetter', allFirstLetter)
-            } else {
-                otherBooks.find(item => item.title == firstLetter).list.push(book);
+                handleBookCategorization(book);
             }
+        } else {
+            handleBookCategorization(book);
         }
     });
 
@@ -122,6 +136,7 @@ watch(() => props.bookList, (newVal) => {
     let poor = poorBooks.list.length > 0 ? poorBooks : {}
     let good = goodBooks.list.length > 0 ? goodBooks : {}
     formatList.value = [...otherBooks, poor, good]
+    console.log(formatList.value, 'xxxxx')
 
 }, { immediate: true, deep: true });
 

+ 2 - 1
pages/index/detail/components/OrderInfo.vue

@@ -9,7 +9,7 @@
             <text class="label">预估金额</text>
             <text class="content">{{ detail.expectMoney }}</text>
             <text class="label border-left">审核金额</text>
-            <text class="content">{{ detail.expectMoney }}</text>
+            <text class="content">{{ detail.finalMoney }}</text>
         </view>
         <view class="info-item">
             <text class="label">用户备注</text>
@@ -147,6 +147,7 @@ function confirmRemark() {
             uni.$u.toast('保存成功')
             uni.$u.ttsModule.speak('保存成功')
             showModal.value = false;
+            getOrderDetail()
         } else {
             uni.$u.toast(res.msg)
         }

+ 55 - 12
pages/index/detail/components/UserInfoCard.vue

@@ -27,10 +27,15 @@
             @confirm="showModal = false" class="log-modal">
 
             <view class="log-container">
+                <view class="log-header">
+                    <text>描述</text>
+                    <text>操作人</text>
+                    <text>时间</text>
+                </view>
                 <view class="log-item" v-for="(log, index) in detail.logVoList" :key="index">
-                    <view class="log-item-content">{{ log.content }}</view>
-                    <view class="log-item-name common-text">操作人:{{ log.createName }}</view>
-                    <view class="log-item-time common-text">操作时间:{{ log.createTime }}</view>
+                    <text class="log-item-content">{{ log.statusName }}</text>
+                    <text class="log-item-name">{{ log.createName }}</text>
+                    <text class="log-item-time">{{ log.createTime }}</text>
                 </view>
             </view>
 
@@ -111,22 +116,60 @@ const confirmBlacklist = () => {
         }
     }
 
+    .log-container {
+        max-height: 60vh;
+        overflow-y: auto;
+        background: #fff;
+        width: 100%;
+    }
+
+    .log-header {
+        display: flex;
+        padding: 20rpx;
+        background: #f2f2f2;
+        font-size: 28rpx;
+        color: #333;
+        text-align: center;
+
+        text:nth-child(1) {
+            flex: 1.2;
+            flex-shrink: 0;
+        }
+        text:nth-child(2),
+        text:nth-child(3) {
+            flex: 1;
+            flex-shrink: 0;
+        }
+    }
+
     .log-item {
-        background-color: #f8f8f8;
-        padding: 14rpx 20rpx;
-        margin-bottom: 10rpx;
-        border-radius: 10rpx;
+        display: flex;
+        padding: 20rpx;
+        border-bottom: 1px solid #f2f2f2;
+        font-size: 28rpx;
+        color: #666;
+
+        .log-item-content {
+            flex: 1.2;
+            text-align: center;
+            flex-shrink: 0;
+        }
+        .log-item-name,
+        .log-item-time {
+            flex: 1;
+            text-align: center;
+            flex-shrink: 0;
+        }
+
+        &:last-child {
+            border-bottom: none;
+        }
     }
 
     :deep(.u-modal__content) {
         padding: 20rpx !important;
     }
 
-    .log-container {
-        max-height: 60vh;
-        overflow-y: auto;
-    }
-
     :deep(.reason-textarea .uni-textarea-wrapper) {
         background-color: #f8f8f8;
         border-radius: 10rpx;

+ 11 - 19
pages/index/detail/index.vue

@@ -140,26 +140,18 @@ function handleLogisticsConfirm() {
 
 //确认收货 /app/orderinfo/confirmOrder
 function handleConfirm() {
-    uni.showModal({
-        title: '提示',
-        content: '是否确认收货?',
-        success: (res) => {
-            if (res.confirm) {
-                uni.showLoading({ title: '加载中...', mask: true })
-                uni.$u.http.post('/app/orderinfo/confirmOrder', {
-                    searchType: 1,
-                    "search": orderDetail.value.orderId
-                }).then(res => {
-                    if (res.code == 200) {
-                        uni.showToast({ title: '确认收货成功', icon: 'none' })
-                        uni.$u.ttsModule.speak('确认收货成功')
-                        getOrderDetail()
-                    }
-                }).finally(() => {
-                    uni.hideLoading()
-                })
-            }
+    uni.showLoading({ title: '加载中...', mask: true })
+    uni.$u.http.post('/app/orderinfo/confirmOrder', {
+        searchType: 1,
+        "search": orderDetail.value.orderId
+    }).then(res => {
+        if (res.code == 200) {
+            uni.showToast({ title: '确认收货成功', icon: 'none' })
+            uni.$u.ttsModule.speak('确认收货成功')
+            getOrderDetail()
         }
+    }).finally(() => {
+        uni.hideLoading()
     })
 }
 //完成

+ 127 - 123
unpackage/dist/dev/app-plus/app-service.js

@@ -15934,7 +15934,7 @@ This will fail in production.`);
         search: ""
       });
       const handleSearch = () => {
-        formatAppLog("log", "at pages/index/audit/express-order.vue:45", "查询:", form.value.search);
+        formatAppLog("log", "at pages/index/audit/express-order.vue:46", "查询:", form.value.search);
         uni.$u.http.get("/app/orderinfo/getOrderInfoForCheck", {
           params: {
             ...form.value
@@ -15946,13 +15946,8 @@ This will fail in production.`);
               url: `/pages/index/detail/index?id=${res2.data.orderId}`
             });
           } else {
-            if (res2.code == 500) {
-              let text = form.value.search + "订单不存在";
-              uni.$u.ttsModule.speak(text);
-            } else {
-              uni.$u.toast(res2.msg);
-              uni.$u.ttsModule.speak(res2.msg);
-            }
+            let text = form.value.search + res2.msg;
+            uni.$u.ttsModule.speak(text);
           }
         });
       };
@@ -16554,6 +16549,7 @@ This will fail in production.`);
             uni.$u.toast("保存成功");
             uni.$u.ttsModule.speak("保存成功");
             showModal.value = false;
+            getOrderDetail();
           } else {
             uni.$u.toast(res2.msg);
           }
@@ -16614,7 +16610,7 @@ This will fail in production.`);
             vue.createElementVNode(
               "text",
               { class: "content" },
-              vue.toDisplayString($props.detail.expectMoney),
+              vue.toDisplayString($props.detail.finalMoney),
               1
               /* TEXT */
             )
@@ -16907,6 +16903,11 @@ This will fail in production.`);
       }, {
         default: vue.withCtx(() => [
           vue.createElementVNode("view", { class: "log-container" }, [
+            vue.createElementVNode("view", { class: "log-header" }, [
+              vue.createElementVNode("text", null, "描述"),
+              vue.createElementVNode("text", null, "操作人"),
+              vue.createElementVNode("text", null, "时间")
+            ]),
             (vue.openBlock(true), vue.createElementBlock(
               vue.Fragment,
               null,
@@ -16916,23 +16917,23 @@ This will fail in production.`);
                   key: index2
                 }, [
                   vue.createElementVNode(
-                    "view",
+                    "text",
                     { class: "log-item-content" },
-                    vue.toDisplayString(log.content),
+                    vue.toDisplayString(log.statusName),
                     1
                     /* TEXT */
                   ),
                   vue.createElementVNode(
-                    "view",
-                    { class: "log-item-name common-text" },
-                    "操作人:" + vue.toDisplayString(log.createName),
+                    "text",
+                    { class: "log-item-name" },
+                    vue.toDisplayString(log.createName),
                     1
                     /* TEXT */
                   ),
                   vue.createElementVNode(
-                    "view",
-                    { class: "log-item-time common-text" },
-                    "操作时间:" + vue.toDisplayString(log.createTime),
+                    "text",
+                    { class: "log-item-time" },
+                    vue.toDisplayString(log.createTime),
                     1
                     /* TEXT */
                   )
@@ -17710,32 +17711,42 @@ This will fail in production.`);
         const goodBooks = { title: "良好", list: [], backgroundColor: "#81b337", id: "good" };
         const otherBooks = [];
         const allFirstLetter = [];
+        const handleBookCategorization = (book) => {
+          let firstLetter;
+          const char = book.bookName.charAt(0);
+          if (/^[A-Za-z]$/.test(char)) {
+            firstLetter = char.toUpperCase();
+          } else if (/^[\u4E00-\u9FA5]$/.test(char)) {
+            firstLetter = toPinyin.chineseToInitials(toPinyin.chineseToPinYin(char));
+          } else {
+            firstLetter = char;
+          }
+          let bool = otherBooks.some((item) => item.title == firstLetter);
+          if (!bool) {
+            otherBooks.push({ id: firstLetter, title: firstLetter, list: [{ ...book }] });
+            allFirstLetter.push(firstLetter);
+            emit2("get-all-firstLetter", allFirstLetter);
+          } else {
+            otherBooks.find((item) => item.title == firstLetter).list.push(book);
+          }
+        };
         list.forEach((book) => {
-          var _a, _b;
+          var _a, _b, _c;
+          formatAppLog("log", "at pages/index/detail/components/BookInfo.vue:106", book, "book");
           book.goodNum = ((_a = book.auditCommentList) == null ? void 0 : _a.filter((v) => v.sts == 1).length) || 0;
           book.badNum = ((_b = book.auditCommentList) == null ? void 0 : _b.filter((v) => v.sts == 3).length) || 0;
-          if (book.badNum > 0) {
-            poorBooks.list.push(book);
-          } else if (book.goodNum > 0) {
-            goodBooks.list.push(book);
-          } else {
-            let firstLetter;
-            const char = book.bookName.charAt(0);
-            if (/^[A-Za-z]$/.test(char)) {
-              firstLetter = char.toUpperCase();
-            } else if (/^[\u4E00-\u9FA5]$/.test(char)) {
-              firstLetter = toPinyin.chineseToInitials(toPinyin.chineseToPinYin(char));
-            } else {
-              firstLetter = char;
-            }
-            let bool = otherBooks.some((item) => item.title == firstLetter);
-            if (!bool) {
-              otherBooks.push({ id: firstLetter, title: firstLetter, list: [{ ...book }] });
-              allFirstLetter.push(firstLetter);
-              emit2("get-all-firstLetter", allFirstLetter);
+          const totalAudited = ((_c = book.auditCommentList) == null ? void 0 : _c.filter((v) => v.sts !== 0).length) || 0;
+          const isFullyAudited = totalAudited === book.num;
+          if (isFullyAudited) {
+            if (book.auditCommentList.some((v) => v.sts === 3)) {
+              poorBooks.list.push(book);
+            } else if (book.auditCommentList.every((v) => v.sts === 1)) {
+              goodBooks.list.push(book);
             } else {
-              otherBooks.find((item) => item.title == firstLetter).list.push(book);
+              handleBookCategorization(book);
             }
+          } else {
+            handleBookCategorization(book);
           }
         });
         return { poorBooks, goodBooks, otherBooks };
@@ -17746,6 +17757,7 @@ This will fail in production.`);
         let poor = poorBooks.list.length > 0 ? poorBooks : {};
         let good = goodBooks.list.length > 0 ? goodBooks : {};
         formatList.value = [...otherBooks, poor, good];
+        formatAppLog("log", "at pages/index/detail/components/BookInfo.vue:139", formatList.value, "xxxxx");
       }, { immediate: true, deep: true });
       const __returned__ = { props: props2, emit: emit2, auditNum, handleBookClick, getAuditCateNum, formatBookList, formatList, ref: vue.ref, watch: vue.watch, computed: vue.computed, BookItem: BookItem$2, get toPinyin() {
         return toPinyin;
@@ -18292,26 +18304,18 @@ This will fail in production.`);
         });
       }
       function handleConfirm() {
-        uni.showModal({
-          title: "提示",
-          content: "是否确认收货?",
-          success: (res2) => {
-            if (res2.confirm) {
-              uni.showLoading({ title: "加载中...", mask: true });
-              uni.$u.http.post("/app/orderinfo/confirmOrder", {
-                searchType: 1,
-                "search": orderDetail.value.orderId
-              }).then((res3) => {
-                if (res3.code == 200) {
-                  uni.showToast({ title: "确认收货成功", icon: "none" });
-                  uni.$u.ttsModule.speak("确认收货成功");
-                  getOrderDetail();
-                }
-              }).finally(() => {
-                uni.hideLoading();
-              });
-            }
+        uni.showLoading({ title: "加载中...", mask: true });
+        uni.$u.http.post("/app/orderinfo/confirmOrder", {
+          searchType: 1,
+          "search": orderDetail.value.orderId
+        }).then((res2) => {
+          if (res2.code == 200) {
+            uni.showToast({ title: "确认收货成功", icon: "none" });
+            uni.$u.ttsModule.speak("确认收货成功");
+            getOrderDetail2();
           }
+        }).finally(() => {
+          uni.hideLoading();
         });
       }
       function handleComplete() {
@@ -18339,7 +18343,7 @@ This will fail in production.`);
         }
       }
       const orderDetail = vue.ref({ status: 0 });
-      function getOrderDetail() {
+      function getOrderDetail2() {
         if (!orderId.value)
           return;
         uni.showLoading({
@@ -18406,10 +18410,10 @@ This will fail in production.`);
           return;
         }
         let isbns = orderDetail.value.detailVoList.map((item) => item.isbn);
-        formatAppLog("log", "at pages/index/detail/index.vue:262", isbns.includes(isbn), "isbns");
+        formatAppLog("log", "at pages/index/detail/index.vue:254", isbns.includes(isbn), "isbns");
         if (isbns.includes(isbn)) {
           let book = orderDetail.value.detailVoList.find((item) => item.isbn == isbn);
-          formatAppLog("log", "at pages/index/detail/index.vue:266", orderDetail.value.detailVoList, book, "book");
+          formatAppLog("log", "at pages/index/detail/index.vue:258", orderDetail.value.detailVoList, book, "book");
           if (book.auditCommentList.every((item) => item.sts == 1)) {
             let text = `${isbn}已审核为良好`;
             return uni.$u.ttsModule.speak(text);
@@ -18435,7 +18439,7 @@ This will fail in production.`);
       function handleScanCode() {
         uni.scanCode({
           success: (res2) => {
-            formatAppLog("log", "at pages/index/detail/index.vue:298", typeof res2.result, "res");
+            formatAppLog("log", "at pages/index/detail/index.vue:290", typeof res2.result, "res");
             res2.result && handleScan(res2.result);
           }
         });
@@ -18445,7 +18449,7 @@ This will fail in production.`);
       const type2 = vue.ref(1);
       onLoad((option) => {
         orderId.value = option.id;
-        getOrderDetail();
+        getOrderDetail2();
         isOnLoad.value = true;
         type2.value = option.type || 1;
         uni.removeStorageSync("scannedBooks");
@@ -18456,9 +18460,9 @@ This will fail in production.`);
         });
       });
       onShow(() => {
-        getOrderDetail();
+        getOrderDetail2();
       });
-      const __returned__ = { showAuditorSelector, selectedAuditor, handleAuditorSelected, toView, scrollToView, scrollToTop, handleBindCode, list, current, handleSectionChange, allLetters, onGetAllFirstLetter, handleLogisticsConfirm, handleConfirm, handleComplete, orderDetail, getOrderDetail, checkIsbn, handleScan, handleScanCode, orderId, isOnLoad, type: type2, ref: vue.ref, get onLoad() {
+      const __returned__ = { showAuditorSelector, selectedAuditor, handleAuditorSelected, toView, scrollToView, scrollToTop, handleBindCode, list, current, handleSectionChange, allLetters, onGetAllFirstLetter, handleLogisticsConfirm, handleConfirm, handleComplete, orderDetail, getOrderDetail: getOrderDetail2, checkIsbn, handleScan, handleScanCode, orderId, isOnLoad, type: type2, ref: vue.ref, get onLoad() {
         return onLoad;
       }, get onShow() {
         return onShow;
@@ -18836,61 +18840,50 @@ This will fail in production.`);
       };
       const scannedBooks = vue.ref([]);
       function checkIsbn(isbn) {
-        let reg = /(?:[0-9]+\-?){9}[0-9X]|(?:978|979)\-?(?:[0-9]+\-?){10}/;
-        if (reg.test(isbn)) {
+        const isbn13Regex = /^(?:97[89]-?\d{1,5}-?\d{1,7}-?\d{1,6}-?\d)$/;
+        if (isbn13Regex.test(isbn)) {
           return true;
         }
         return false;
       }
       function handleScan(isbn) {
-        var _a, _b, _c;
+        var _a, _b;
         if (!checkIsbn(isbn)) {
           let text = `不是正确的ISBN码`;
           uni.$u.ttsModule.speak(text);
           return;
         }
         let isbns = orderDetail.value.detailVoList.map((item) => item.isbn);
-        orderDetail.value.totalNum;
         if (isbns.includes(isbn)) {
           let book = orderDetail.value.detailVoList.find((item) => item.isbn == isbn);
-          if (book.num == ((_a = book.auditCommentList) == null ? void 0 : _a.length)) {
+          if (((_a = book.auditCommentList) == null ? void 0 : _a.length) > 0) {
             let text = "";
             if (book.auditCommentList.every((item) => item.sts == 1)) {
               text = `${isbn}已审核为良好`;
               uni.$u.ttsModule.speak(text);
               return;
-            } else {
-              text = `${isbn}已审核为极差`;
-              scannedBooks.value.push(isbn);
-              uni.$u.ttsModule.speak(text);
-              uni.setStorageSync("scannedBooks", scannedBooks.value);
-              uni.navigateTo({
-                url: `/pages/index/detail/batch-audit?orderId=${orderId.value}`
-              });
             }
-          } else {
-            let hasAuditNum = ((_b = book.auditCommentList) == null ? void 0 : _b.length) || 0;
-            let notAuditNum = book.num - hasAuditNum;
-            let poorNum = ((_c = book.auditCommentList) == null ? void 0 : _c.filter((item) => item.sts == 3).length) || 0;
+            book.auditCommentList.filter((item) => item.sts !== 0).length || 0;
+            let notAuditNum = book.auditCommentList.filter((item) => item.sts === 0).length || 0;
+            let poorNum = ((_b = book.auditCommentList) == null ? void 0 : _b.filter((item) => item.sts == 3).length) || 0;
             let scannedNum = scannedBooks.value.filter((item) => item == isbn).length || 0;
             if (scannedNum >= notAuditNum + poorNum) {
-              let text = `${isbn}已超出订单中的数量`;
-              return uni.$u.ttsModule.speak(text);
+              let text2 = `${isbn}已超出订单中的数量`;
+              return uni.$u.ttsModule.speak(text2);
             } else {
               if (book.suit == 1) {
-                let text = `${isbn}请注意套装书是否齐全`;
-                uni.$u.ttsModule.speak(text);
+                let text2 = `${isbn}请注意套装书是否齐全`;
+                uni.$u.ttsModule.speak(text2);
               }
               if (book.bookWarn == 1) {
-                let text = `请注意${isbn}需要取出`;
-                uni.$u.ttsModule.speak(text);
+                let text2 = `请注意${isbn}需要取出`;
+                uni.$u.ttsModule.speak(text2);
               }
               if (scannedNum >= notAuditNum && scannedNum < notAuditNum + poorNum) {
-                let text = `${isbn}已审核为极差`;
-                uni.$u.ttsModule.speak(text);
+                let text2 = `${isbn}已审核为极差`;
+                uni.$u.ttsModule.speak(text2);
               }
               scannedBooks.value.push(isbn);
-              formatAppLog("log", "at pages/index/detail/book-audit.vue:153", scannedBooks.value, "book-audit");
               uni.setStorageSync("scannedBooks", scannedBooks.value);
               uni.navigateTo({
                 url: `/pages/index/detail/batch-audit?orderId=${orderId.value}`
@@ -18952,6 +18945,8 @@ This will fail in production.`);
       onShow(() => {
         var _a;
         checkUserId.value = (_a = uni.getStorageSync("userInfo")) == null ? void 0 : _a.userId;
+        auditBook.value = uni.getStorageSync("auditBook");
+        orderDetail.value = uni.getStorageSync("orderDetail");
       });
       const __returned__ = { detail, getBookInfo, list, current, handleSectionChange, auditData, handleAuditSelected, scannedBooks, checkIsbn, handleScan, handleScanCode, auditInfoRef, handleAudit, auditBook, checkUserId, orderId, orderDetail, ref: vue.ref, get onLoad() {
         return onLoad;
@@ -19025,7 +19020,7 @@ This will fail in production.`);
             vue.createElementVNode(
               "text",
               { class: "content" },
-              vue.toDisplayString($setup.detail.price),
+              "¥" + vue.toDisplayString($setup.detail.price),
               1
               /* TEXT */
             )
@@ -19035,7 +19030,7 @@ This will fail in production.`);
             vue.createElementVNode(
               "text",
               { class: "content" },
-              vue.toDisplayString($setup.detail.recycleDiscount),
+              vue.toDisplayString($setup.detail.recycleDiscount) + "折",
               1
               /* TEXT */
             )
@@ -19047,14 +19042,20 @@ This will fail in production.`);
             vue.createElementVNode(
               "text",
               { class: "content" },
-              vue.toDisplayString($setup.detail.price),
+              "¥" + vue.toDisplayString($setup.auditBook.expectMoney),
               1
               /* TEXT */
             )
           ]),
           vue.createElementVNode("view", { class: "flex flex-a-c flex-1" }, [
             vue.createElementVNode("text", { class: "label" }, "审核金额"),
-            vue.createElementVNode("text", { class: "content" }, vue.toDisplayString("0.00"))
+            vue.createElementVNode(
+              "text",
+              { class: "content" },
+              "¥" + vue.toDisplayString($setup.auditBook.finalMoney),
+              1
+              /* TEXT */
+            )
           ])
         ])
       ]),
@@ -19245,62 +19246,58 @@ This will fail in production.`);
           if (res2.code == 200) {
             detailMap.value[isbn] = res2.data;
             scannedBooksDetail.value.push(res2.data);
-            formatAppLog("log", "at pages/index/detail/batch-audit.vue:38", scannedBooksDetail.value, "xxaaxx");
+            formatAppLog("log", "at pages/index/detail/batch-audit.vue:39", scannedBooksDetail.value, "xxaaxx");
           }
         });
       };
+      const handleClose = (index2, isbn) => {
+        scannedBooksDetail.value.splice(index2, 1);
+        scannedBooks.value = scannedBooks.value.filter((item) => item != isbn);
+      };
       function checkIsbn(isbn) {
-        let reg = /(?:[0-9]+\-?){9}[0-9X]|(?:978|979)\-?(?:[0-9]+\-?){10}/;
-        if (reg.test(isbn)) {
+        const isbn13Regex = /^(?:97[89]-?\d{1,5}-?\d{1,7}-?\d{1,6}-?\d)$/;
+        if (isbn13Regex.test(isbn)) {
           return true;
         }
         return false;
       }
       const scannedBooks = vue.ref([]);
       function handleScan(isbn) {
-        var _a, _b, _c;
+        var _a, _b;
         if (!checkIsbn(isbn)) {
           let text = `不是正确的ISBN码`;
           uni.$u.ttsModule.speak(text);
           return;
         }
         let isbns = orderDetail.value.detailVoList.map((item) => item.isbn);
-        orderDetail.value.totalNum;
         if (isbns.includes(isbn)) {
           let book = orderDetail.value.detailVoList.find((item) => item.isbn == isbn);
-          if (book.num == ((_a = book.auditCommentList) == null ? void 0 : _a.length)) {
+          if (((_a = book.auditCommentList) == null ? void 0 : _a.length) > 0) {
             let text = "";
             if (book.auditCommentList.every((item) => item.sts == 1)) {
               text = `${isbn}已审核为良好`;
               uni.$u.ttsModule.speak(text);
               return;
-            } else {
-              text = `${isbn}已审核为极差`;
-              scannedBooks.value.push(isbn);
-              uni.$u.ttsModule.speak(text);
-              getBookInfo(isbn);
             }
-          } else {
-            let hasAuditNum = ((_b = book.auditCommentList) == null ? void 0 : _b.length) || 0;
-            let notAuditNum = book.num - hasAuditNum;
-            let poorNum = ((_c = book.auditCommentList) == null ? void 0 : _c.filter((item) => item.sts == 3).length) || 0;
+            book.auditCommentList.filter((item) => item.sts !== 0).length || 0;
+            let notAuditNum = book.auditCommentList.filter((item) => item.sts === 0).length || 0;
+            let poorNum = ((_b = book.auditCommentList) == null ? void 0 : _b.filter((item) => item.sts == 3).length) || 0;
             let scannedNum = scannedBooks.value.filter((item) => item == isbn).length || 0;
-            formatAppLog("log", "at pages/index/detail/batch-audit.vue:86", scannedNum, poorNum, notAuditNum, "scannedNum");
             if (scannedNum >= notAuditNum + poorNum) {
-              let text = `${isbn}已超出订单中的数量`;
-              return uni.$u.ttsModule.speak(text);
+              let text2 = `${isbn}已超出订单中的数量`;
+              return uni.$u.ttsModule.speak(text2);
             } else {
               if (book.suit == 1) {
-                let text = `${isbn}请注意套装书是否齐全`;
-                uni.$u.ttsModule.speak(text);
+                let text2 = `${isbn}请注意套装书是否齐全`;
+                uni.$u.ttsModule.speak(text2);
               }
               if (book.bookWarn == 1) {
-                let text = `请注意${isbn}需要取出`;
-                uni.$u.ttsModule.speak(text);
+                let text2 = `请注意${isbn}需要取出`;
+                uni.$u.ttsModule.speak(text2);
               }
               if (scannedNum >= notAuditNum && scannedNum < notAuditNum + poorNum) {
-                let text = `${isbn}已审核为极差`;
-                uni.$u.ttsModule.speak(text);
+                let text2 = `${isbn}已审核为极差`;
+                uni.$u.ttsModule.speak(text2);
               }
               scannedBooks.value.push(isbn);
               getBookInfo(isbn);
@@ -19369,7 +19366,12 @@ This will fail in production.`);
           }
         });
       });
-      const __returned__ = { detailMap, scannedBooksDetail, getBookInfo, checkIsbn, scannedBooks, handleScan, handleScanCode, checkUserId, orderId, orderDetail, showModal, isQualitySelected, showQualityModal, closeModal, toggleQuality, handleAudit, ref: vue.ref, get onLoad() {
+      onShow(() => {
+        var _a;
+        checkUserId.value = (_a = uni.getStorageSync("userInfo")) == null ? void 0 : _a.userId;
+        orderDetail.value = uni.getStorageSync("orderDetail");
+      });
+      const __returned__ = { detailMap, scannedBooksDetail, getBookInfo, handleClose, checkIsbn, scannedBooks, handleScan, handleScanCode, checkUserId, orderId, orderDetail, showModal, isQualitySelected, showQualityModal, closeModal, toggleQuality, handleAudit, ref: vue.ref, get onLoad() {
         return onLoad;
       }, get onShow() {
         return onShow;
@@ -19385,12 +19387,13 @@ This will fail in production.`);
       (vue.openBlock(true), vue.createElementBlock(
         vue.Fragment,
         null,
-        vue.renderList($setup.scannedBooksDetail, (item) => {
+        vue.renderList($setup.scannedBooksDetail, (item, index2) => {
           return vue.openBlock(), vue.createBlock($setup["BookItem"], {
             key: item.isbn,
             item,
-            showClose: ""
-          }, null, 8, ["item"]);
+            showClose: "",
+            onClose: (isbn) => $setup.handleClose(index2, isbn)
+          }, null, 8, ["item", "onClose"]);
         }),
         128
         /* KEYED_FRAGMENT */
@@ -19500,7 +19503,8 @@ This will fail in production.`);
         requestStr: "/app/orderinfo/getOrderListByUserInfo",
         onUpdateList: $setup.updateList,
         ref: "scrollRef",
-        otherParams: $setup.otherParams
+        otherParams: $setup.otherParams,
+        immediate: false
       }, {
         default: vue.withCtx(() => [
           vue.createVNode(_component_u_sticky, { customNavHeight: 0 }, {

+ 42 - 8
unpackage/dist/dev/app-plus/pages/index/detail/index.css

@@ -1541,19 +1541,53 @@ uni-view[data-v-f667648f], uni-scroll-view[data-v-f667648f], uni-swiper-item[dat
   height: 50px;
   border-radius: 50%;
 }
+.user-info-card .log-container[data-v-42a1a738] {
+  max-height: 60vh;
+  overflow-y: auto;
+  background: #fff;
+  width: 100%;
+}
+.user-info-card .log-header[data-v-42a1a738] {
+  display: flex;
+  padding: 0.625rem;
+  background: #f2f2f2;
+  font-size: 0.875rem;
+  color: #333;
+  text-align: center;
+}
+.user-info-card .log-header uni-text[data-v-42a1a738]:nth-child(1) {
+  flex: 1.2;
+  flex-shrink: 0;
+}
+.user-info-card .log-header uni-text[data-v-42a1a738]:nth-child(2),
+.user-info-card .log-header uni-text[data-v-42a1a738]:nth-child(3) {
+  flex: 1;
+  flex-shrink: 0;
+}
 .user-info-card .log-item[data-v-42a1a738] {
-  background-color: #f8f8f8;
-  padding: 0.4375rem 0.625rem;
-  margin-bottom: 0.3125rem;
-  border-radius: 0.3125rem;
+  display: flex;
+  padding: 0.625rem;
+  border-bottom: 1px solid #f2f2f2;
+  font-size: 0.875rem;
+  color: #666;
+}
+.user-info-card .log-item .log-item-content[data-v-42a1a738] {
+  flex: 1.2;
+  text-align: center;
+  flex-shrink: 0;
+}
+.user-info-card .log-item .log-item-name[data-v-42a1a738],
+.user-info-card .log-item .log-item-time[data-v-42a1a738] {
+  flex: 1;
+  text-align: center;
+  flex-shrink: 0;
+}
+.user-info-card .log-item[data-v-42a1a738]:last-child {
+  border-bottom: none;
 }
 .user-info-card[data-v-42a1a738] .u-modal__content {
   padding: 0.625rem !important;
 }
-.user-info-card .log-container[data-v-42a1a738] {
-  max-height: 60vh;
-  overflow-y: auto;
-}
 .user-info-card[data-v-42a1a738] .reason-textarea .uni-textarea-wrapper {
   background-color: #f8f8f8;
   border-radius: 0.3125rem;