From eaea3c175b98c5a5c4ab1b4a7b4a7eb34652308d Mon Sep 17 00:00:00 2001
From: hongchao <3228015117@qq.com>
Date: Wed, 25 Jun 2025 18:24:21 +0800
Subject: [PATCH 1/4] =?UTF-8?q?=E7=94=B5=E5=AD=90=E6=A0=87=E7=AD=BE?=
=?UTF-8?q?=EF=BC=8C=E8=AE=BE=E5=A4=87=E7=BC=96=E7=A0=81=E6=9F=A5=E8=AF=A2?=
=?UTF-8?q?=EF=BC=8C=E4=BA=8C=E7=BB=B4=E7=A0=81=E6=9F=A5=E8=AF=A2?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/pages/devicesSearch/codeSearch.vue | 190 ++-
src/pages/devicesSearch/qrSearch.vue | 102 +-
.../integratedQuery/electronicTag/index.vue | 1167 ++++++++---------
src/services/picking/outbound.js | 16 +
4 files changed, 778 insertions(+), 697 deletions(-)
diff --git a/src/pages/devicesSearch/codeSearch.vue b/src/pages/devicesSearch/codeSearch.vue
index 6d26c25..0784427 100644
--- a/src/pages/devicesSearch/codeSearch.vue
+++ b/src/pages/devicesSearch/codeSearch.vue
@@ -19,6 +19,15 @@
>编码检索
+
+
+
@@ -27,66 +36,66 @@
-
- 激动角膜
+
+ {{formData?.maName ?? ''}}
-
- CJM-2
+
+ {{formData?.maModel ?? ''}}
-
- ceshi123
+
+ {{formData?.qrCode ?? ''}}
-
- ceshi123
+
+ {{formData?.maCode ?? ''}}
-
- 在用
+
+ {{formData?.maStatus ?? ''}}
+
+
+ {{formData?.thisCheckTime ?? ''}}
+
+
+ {{formData?.nextCheckTime ?? ''}}
+
+
+ {{formData?.inOutNum ?? ''}}
+
+
+ {{formData?.inTime ?? ''}}
+
+
+ {{formData?.serviceNum ?? ''}}
+
+
+ {{formData?.checkNum ?? ''}}
+
+
+ {{formData?.checkNum ?? ''}}
+
+
+ {{formData?.scrapTime ?? ''}}
+
+
+ {{}}
+
+
+ {{formData?.leaseUnit ?? ''}}
+
+
+ {{formData?.leaseProject ?? ''}}
+
+
+ {{formData?.leaseTime ?? ''}}
+
+
+ {{formData?.backUnit ?? ''}}
+
+
+ {{formData?.backProject ?? ''}}
+
+
+ {{formData?.backTime ?? ''}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -102,12 +111,36 @@
import { ref, computed, onUnmounted } from 'vue'
import { onLoad, onShow, } from '@dcloudio/uni-app'
import { debounce } from 'lodash-es'
+import { getDeviceListAPI } from '@/services/picking/outbound.js'
const queryParams = ref({})
-const formData = ref({})
+const formData = ref({
+ maName: '',
+ maModel: '',
+ qrCode: '',
+ maCode: '',
+ maStatus: '',
+ thisCheckTime: '',
+ nextCheckTime: '',
+ inOutNum: '',
+ inTime: '',
+ serviceNum: '',
+ checkNum: '',
+ scrapTime: '',
+ statusName: '',
+ leaseUnit: '',
+ leaseProject: '',
+ leaseTime: '',
+ backUnit: '',
+ backProject: '',
+ backTime: ''
+})
// 编码设备列表查询参数
const queryCodeParams = ref({
maCode: '',
+ maId:'',
})
+const maId = ref('')
+const optionList = ref([])
// 页面加载完毕
onLoad((options) => {})
@@ -121,12 +154,55 @@ const onCodeSearch = () => {
const getCodeDeviceInfoData = async () => {
console.log(queryCodeParams.value)
// const res = await getCodeDeviceListAPI(queryCodeParams.value)
- // console.log(res)
+ getDeviceListAPI({'maCode': queryCodeParams.value.maCode}).then(response => {
+ console.log("xxxxxxxxxxx",response)
+ if (response.data && response.data.length !== 0) {
+ optionList.value = response.data.map(option => ({
+ value: option.maId,
+ text: option.maCode
+ }))
+ if(response.data.length === 1){
+ formData.value = response.data[0]
+ }
+ }else{
+ uni.showToast({
+ title: '未查询到该编号信息',
+ icon: 'none',
+ duration: 2000
+ })
+ }
+ })
+ console.log(res)
}
+// 标签变更处理
+const changeTag = async () => {
+ if (!maId.value) return
+
+ try {
+ const response = await getDeviceListAPI({'maId': maId.value})
+ if (response.data && response.data.length !== 0) {
+ formData.value = response.data[0]
+ }
+ } catch (error) {
+ console.error("获取编号信息失败", error)
+ uni.showToast({
+ title: '获取信息失败',
+ icon: 'none',
+ duration: 2000
+ })
+ }
+}
+
+
+
+.select-container {
+ margin-top: 10px;
+
+ .data-select {
+ width: 100%;
+ z-index: 1000;
+ }
+}
+
+.certificate-card {
+ width: 100%;
+ min-height: 300px;
+ margin-top: 15px;
+ position: relative;
+ border-radius: 8px;
+ overflow: visible;
+
+ .certificate-content {
+ padding: 15px;
+ position: relative;
+ min-height: 300px;
+ }
+
+ .title {
+ text-align: center;
+ font-weight: 500;
+ font-size: 18px;
+ margin-bottom: 15px;
+ letter-spacing: 2px;
+ }
+
+ .info-row {
+ display: flex;
+ flex-wrap: wrap;
+ margin-bottom: 8px;
+ }
+
+ .info-item {
+ display: flex;
+ align-items: center;
+ font-size: 14px;
+ padding: 4px 0;
+ min-height: 24px;
+
+ &.full-width {
+ width: 100%;
+ }
+
+ &.align-right {
+ justify-content: flex-end;
+ }
+ }
+
+ .label {
+ font-weight: 500;
+ min-width: 90px;
+ }
+
+ .value {
+ margin-left: 10px;
+ flex: 1;
+ }
+
+ .conclusion {
+ color: #ef3e3e;
+ margin-right: 20px;
+ font-weight: bold;
+ }
+
+ .report-link {
+ margin-left: 10px;
+ text-decoration: underline;
+ cursor: pointer;
+ font-weight: 500;
+ transition: all 0.3s;
+
+ &:hover {
+ color: #0055aa;
+ transform: scale(1.05);
+ }
+ }
+
+ .stamp-container {
+ position: absolute;
+ bottom: 10px;
+ left: 10px;
+ width: 140px;
+ height: 140px;
+ z-index: 10;
+ overflow: visible; /* 确保印章不会裁剪 */
+ }
+
+ .stamp-canvas {
+ width: 140px;
+ height: 140px;
+ }
+}
+
+.green-certificate {
+ border: 6px solid #00904a;
+
+ .title {
+ color: #00904a;
+ }
+
+ .label {
+ color: #00904a;
+ }
+
+ .report-link {
+ color: #00904a;
+ }
+}
+
+.blue-certificate {
+ border: 6px solid #0055aa;
+
+ .title {
+ color: #0055aa;
+ }
+
+ .label {
+ color: #0055aa;
+ }
+
+ .report-link {
+ color: #0055aa;
+ }
+}
+
+:deep(.uni-select) {
+ z-index: 1001 !important;
+}
+
\ No newline at end of file
diff --git a/src/services/picking/outbound.js b/src/services/picking/outbound.js
index 1e3bd9c..297e627 100644
--- a/src/services/picking/outbound.js
+++ b/src/services/picking/outbound.js
@@ -76,6 +76,22 @@ export const getCodeScanAPI = (data) => {
data,
})
}
+
+export const getScanCodeAPI = (data) => {
+ return http({
+ method: 'GET',
+ url: '/material/ma_machine/getHisByQrcode',
+ data,
+ })
+}
+
+export const getDeviceListAPI = (data) => {
+ return http({
+ method: 'GET',
+ url: '/material/ma_machine/getHisByCode',
+ data,
+ })
+}
//出库退回
export const leaseOutBackApi = (data) => {
return http({
From 963a744d9c4d598c5555e3fb61f9cdf115155b5e Mon Sep 17 00:00:00 2001
From: bb_pan
Date: Thu, 26 Jun 2025 17:46:00 +0800
Subject: [PATCH 2/4] =?UTF-8?q?=E6=9D=90=E6=96=99=E7=AB=99=E8=81=94?=
=?UTF-8?q?=E8=B0=83?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/pages/materialsStation/index/index.vue | 2 +-
.../materialsStation/toolsBack/toolsAddBack.vue | 2 +-
.../materialsStation/toolsLease/codeOut.vue | 6 ++++--
.../toolsLease/toolsLeaseAdd.vue | 15 +++++++++------
src/services/materialsStation.js | 16 ++++++++--------
src/utils/http.js | 1 -
vite.config.js | 2 +-
7 files changed, 24 insertions(+), 20 deletions(-)
diff --git a/src/pages/materialsStation/index/index.vue b/src/pages/materialsStation/index/index.vue
index f9125ad..86a15e0 100644
--- a/src/pages/materialsStation/index/index.vue
+++ b/src/pages/materialsStation/index/index.vue
@@ -122,7 +122,7 @@ const getUserInfoByUserName = async () => {
const userName = userInfo.value.userName
console.log('🚀 ~ getUserInfoByUserName ~ userName:', userName)
const res = await getUserInfoByUserNameApi({ userName })
- idCard.value = res.data.idCard
+ idCard.value = res?.data?.idCard
console.log('🚀 ~ getUserInfoByUserName ~ idCard.value:', idCard.value)
uni.setStorageSync('idCard', idCard.value)
} catch (error) {
diff --git a/src/pages/materialsStation/toolsBack/toolsAddBack.vue b/src/pages/materialsStation/toolsBack/toolsAddBack.vue
index f421b8b..48148f1 100644
--- a/src/pages/materialsStation/toolsBack/toolsAddBack.vue
+++ b/src/pages/materialsStation/toolsBack/toolsAddBack.vue
@@ -218,7 +218,7 @@ const getTeamList = async () => {
const getProjectListApi = async () => {
console.log('🚀 ~ 工程')
try {
- const res = await getProjectList({ unitId: null, isApp: true, teamName: formData.teamName })
+ const res = await getProjectList({ unitId: null, isApp: true, teamId: formData.teamId })
if (!res.data || !res.data.length) return
console.log('🚀 ~ getProjectListApi ~ res:', res)
prodRange.value = res.data.map((item) => {
diff --git a/src/pages/materialsStation/toolsLease/codeOut.vue b/src/pages/materialsStation/toolsLease/codeOut.vue
index 88a13c9..8d6a3a7 100644
--- a/src/pages/materialsStation/toolsLease/codeOut.vue
+++ b/src/pages/materialsStation/toolsLease/codeOut.vue
@@ -135,7 +135,7 @@
规格型号:
- {{ item.materialModel }}
+ {{ item.typeName }}
@@ -191,7 +191,7 @@ const queryCodeParams = ref({
pageNum: 1,
pageSize: 9999,
typeId: '',
- maStatus: 1,
+ // maStatus: 1,
maCode: '',
})
const qrCodeScan = ref('')
@@ -217,6 +217,8 @@ onLoad((opt) => {
// queryParamsTemp.value.id = queryParamsTemp.value.parentId
console.log('xxxxxxxx', queryParamsTemp.value)
queryCodeParams.value.typeId = queryParamsTemp.value.typeId
+ queryCodeParams.value.proId = queryParamsTemp.value.proId
+ queryCodeParams.value.teamId = queryParamsTemp.value.teamId
queryParams.value = { ...queryParamsTemp.value }
if (queryParamsTemp.value.isBack) {
getCodeList() // 获取编码列表
diff --git a/src/pages/materialsStation/toolsLease/toolsLeaseAdd.vue b/src/pages/materialsStation/toolsLease/toolsLeaseAdd.vue
index b818625..37ea7b8 100644
--- a/src/pages/materialsStation/toolsLease/toolsLeaseAdd.vue
+++ b/src/pages/materialsStation/toolsLease/toolsLeaseAdd.vue
@@ -82,7 +82,7 @@
规格型号
在库数
在用数
- 预领数
+ 预领数
{{ opts.isOut ? '出库数' : '领用数' }}
操作
@@ -94,7 +94,7 @@
{{ item.storageNum }}
{{ item.useNum }}
- {{ item.preNum }}
+ {{ item.preNum }}