|
@@ -1,14 +1,14 @@
|
|
|
<script setup lang="ts">
|
|
|
import {
|
|
|
- exportFile,
|
|
|
- readvaildation,
|
|
|
- Storehouse_ProductClass_List,
|
|
|
- updatevaildation,
|
|
|
- uploadFile,
|
|
|
- validation_add,
|
|
|
- validation_del,
|
|
|
- validation_List,
|
|
|
- validation_update
|
|
|
+ exportFile,
|
|
|
+ readValidation,
|
|
|
+ validationTool_class_list,
|
|
|
+ updateValidation,
|
|
|
+ uploadFile,
|
|
|
+ validation_add,
|
|
|
+ validation_del,
|
|
|
+ validation_List,
|
|
|
+ validation_update
|
|
|
} from '@/api/storehouse'
|
|
|
import TableBase from '@/components/TableBase/index.vue'
|
|
|
import { computed, onMounted, reactive, ref } from 'vue'
|
|
@@ -77,8 +77,8 @@ const deleteFun = (row: any) => {
|
|
|
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
|
|
.catch(() => {})
|
|
|
}
|
|
|
-//导出文件execl
|
|
|
-const exportExecl = async () => {
|
|
|
+//导出文件excel
|
|
|
+const exportExcel = async () => {
|
|
|
try {
|
|
|
const response: any = await exportFile({
|
|
|
User_tokey: globalStore.GET_User_tokey,
|
|
@@ -131,8 +131,8 @@ const Pruductoptions = ref<any[]>([
|
|
|
T_name: ''
|
|
|
}
|
|
|
])
|
|
|
-const getProductClassList = async () => {
|
|
|
- const res: any = await Storehouse_ProductClass_List({ page: 1, page_z: 999 })
|
|
|
+const getValidationToolClassList = async () => {
|
|
|
+ const res: any = await validationTool_class_list({ page: 1, page_z: 999 })
|
|
|
Pruductoptions.value = res.Data.Data
|
|
|
}
|
|
|
|
|
@@ -169,7 +169,7 @@ const submitInStorageForm = () => {
|
|
|
ElMessage.warning('已存在相同的SN,不能添加')
|
|
|
return
|
|
|
}
|
|
|
- const result: any = await readvaildation({ sn: extractedSN })
|
|
|
+ const result: any = await readValidation({ sn: extractedSN })
|
|
|
if ((result.Code==200)&&(result.Data.T_state == 2)) {
|
|
|
//1-已出库 2-待使用 3-待维修
|
|
|
ElMessage.warning('当前SN已入库不能重复入库')
|
|
@@ -198,7 +198,7 @@ const submitRepaidForm = () => {
|
|
|
ElMessage.warning('已存在相同的SN,不能添加')
|
|
|
return
|
|
|
}
|
|
|
- const result: any = await readvaildation({ sn: extractedSN })
|
|
|
+ const result: any = await readValidation({ sn: extractedSN })
|
|
|
if (result.Code !== 200) {
|
|
|
ElMessage.warning('当前SN未入库不能归还')
|
|
|
return
|
|
@@ -298,7 +298,7 @@ const submitLendForm = () => {
|
|
|
ElMessage.warning('已存在相同的SN,不能添加')
|
|
|
return
|
|
|
}
|
|
|
- const result: any = await readvaildation({ sn: extractedSN })
|
|
|
+ const result: any = await readValidation({ sn: extractedSN })
|
|
|
if (result.Code !== 200) {
|
|
|
ElMessage.warning('当前SN未入库不能借出')
|
|
|
return
|
|
@@ -374,7 +374,7 @@ const Repaid = () => {
|
|
|
|
|
|
const previewEdit = async (row: any) => {
|
|
|
showEditForm.value = true
|
|
|
- const result: any = await readvaildation({ sn: row.T_sn })
|
|
|
+ const result: any = await readValidation({ sn: row.T_sn })
|
|
|
if (result.Code === 200) {
|
|
|
Object.assign(editForm, result.Data)
|
|
|
} else {
|
|
@@ -385,7 +385,7 @@ const previewEdit = async (row: any) => {
|
|
|
const submitEditForm = () => {
|
|
|
editFormRef.value?.validate(async (valid: boolean): Promise<void> => {
|
|
|
if (valid) {
|
|
|
- const result: any = await updatevaildation(editForm)
|
|
|
+ const result: any = await updateValidation(editForm)
|
|
|
if (result.Code === 200) {
|
|
|
ElMessage.success('编辑成功')
|
|
|
showEditForm.value = false
|
|
@@ -438,7 +438,7 @@ const submitUpload = async () => {
|
|
|
}
|
|
|
|
|
|
onMounted(() => {
|
|
|
- getProductClassList()
|
|
|
+ getValidationToolClassList()
|
|
|
})
|
|
|
</script>
|
|
|
<template>
|
|
@@ -537,7 +537,7 @@ onMounted(() => {
|
|
|
<el-button type="primary" @click="showLendForm = true">借出</el-button>
|
|
|
<el-button type="primary" @click="showrRepaidForm = true">归还</el-button>
|
|
|
<el-button type="success" @click="ImportEdit = true">模板导入</el-button>
|
|
|
- <el-button type="success" @click="exportExecl">导出</el-button>
|
|
|
+ <el-button type="success" @click="exportExcel">导出</el-button>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
</div>
|
|
@@ -603,7 +603,7 @@ onMounted(() => {
|
|
|
<template #footer>
|
|
|
<span class="dialog-footer">
|
|
|
<el-button @click="showInStorageForm = false">取消</el-button>
|
|
|
- <el-button type="primary" @click="submitInStorageForm">添加到暂存11</el-button>
|
|
|
+ <el-button type="primary" @click="submitInStorageForm">添加到暂存</el-button>
|
|
|
<!-- 新增提交按钮 -->
|
|
|
<el-button type="primary" @click="submitInStoragePendingItems">提交</el-button>
|
|
|
</span>
|