From e4e304318532574e418bc01b5a45b8836dac3e1a Mon Sep 17 00:00:00 2001
From: pan <antony1029@163.com>
Date: 星期四, 11 十二月 2025 23:26:20 +0800
Subject: [PATCH] 提交

---
 项目代码/WIDESEA_WMSClient/src/extension/inbound/extend/EmptyTrayInbound.vue |  113 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 113 insertions(+), 0 deletions(-)

diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WIDESEA_WMSClient/src/extension/inbound/extend/EmptyTrayInbound.vue" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WIDESEA_WMSClient/src/extension/inbound/extend/EmptyTrayInbound.vue"
new file mode 100644
index 0000000..d80b08e
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WIDESEA_WMSClient/src/extension/inbound/extend/EmptyTrayInbound.vue"
@@ -0,0 +1,113 @@
+<template>
+    <vol-box v-model="show" title="绌烘墭鍏ュ簱" :width="800" :height="1200">
+        <template #content>
+            <el-form ref="form" :model="form" label-width="90px">
+                <el-form-item label="鍏ュ簱鍖哄煙:">
+                    <el-select v-model="form.locationType" placeholder="璇烽�夋嫨鍏ュ簱鍖哄煙">
+                        <el-option v-for="item in locationTypes" :key="item.locationType" :label="item.locationTypeDesc"
+                            :value="item.locationType" />
+                    </el-select>
+                </el-form-item>
+
+                <el-form-item label="鎵樼洏鏉$爜:">
+                    <el-input v-model="form.palletCode" placeholder="璇锋壂鎻�/杈撳叆鎵樼洏鏉$爜" @keyup.enter="submit" @keyup.13="submit"
+                        clearable maxlength="50" @paste="handlePaste" @input="handleInput" />
+                </el-form-item>
+            </el-form>
+        </template>
+
+        <template #footer>
+            <div class="dialog-footer">
+                <el-button type="primary" @click="submit">纭</el-button>
+                <el-button @click="show = false">鍏抽棴</el-button>
+            </div>
+        </template>
+    </vol-box>
+</template>
+  
+<script>
+import VolBox from '@/components/basic/VolBox.vue'
+
+export default {
+    components: { VolBox },
+    props: {
+        value: { type: Boolean, default: false }
+    },
+    data() {
+        return {
+            show: false,
+            form: {
+                palletCode: '',
+                locationType: ''
+            },
+            locationTypes: []
+        }
+    },
+    methods: {
+        open() {
+            this.show = true
+            this.getData();
+        },
+
+        async getData() {
+            try {
+                const { data } = await this.http.post("api/LocationInfo/GetLocationTypes")
+                this.locationTypes = data
+            } catch (e) {
+                this.$message.error('鑾峰彇鍖哄煙绫诲瀷澶辫触')
+            }
+        },
+
+        async submit() {
+            if (!this.form.palletCode) {
+                this.$message.warning('璇疯緭鍏ユ墭鐩樻潯鐮�')
+                return
+            }
+
+            if (!this.form.locationType) {
+                this.$message.warning('璇烽�夋嫨鍏ュ簱鍖哄煙')
+                return
+            }
+
+            try {
+                let param = {
+                    WarehouseCode: this.form.locationType,
+                    PalletCode: this.form.palletCode
+                }
+
+                const { status, message } = await this.http.post(
+                    `/api/InboundOrder/EmptyMaterielGroup`,
+                    param
+                )
+
+                if (status) {
+                    this.$message.success("缁勭洏鎴愬姛")
+                    this.show = false
+                    this.$emit('refresh')
+                } else {
+                    this.$message.error(message || '鎿嶄綔澶辫触')
+                }
+            } catch (error) {
+                this.$message.error('璇锋眰寮傚父')
+            }
+        },
+
+        // 鎵弿鏋紭鍖栧鐞�
+        handleInput(value) {
+            // 杩囨护闈炴暟瀛楀拰鏉$爜甯哥敤瀛楃
+            this.form.palletCode = value.replace(/[^a-zA-Z0-9\-]/g, '')
+        },
+
+        handlePaste(e) {
+            // 绮樿创鏃惰嚜鍔ㄦ彁浜�
+            setTimeout(this.submit, 100)
+        }
+    }
+}
+</script>
+  
+<style scoped>
+.dialog-footer {
+    text-align: right;
+}
+</style>
\ No newline at end of file

--
Gitblit v1.9.3