| | |
| | | <script setup> |
| | | import Record from "@/views/inventoryManagement/receiptManagement/Record.vue"; |
| | | |
| | | const activeTab = ref('qualified') |
| | | const type = ref(0) |
| | | const activeTab = ref('selfMade') |
| | | const type = ref(1) |
| | | const tabs = ref([ |
| | | { |
| | | label: '合格入库', |
| | | name: 'qualified', |
| | | type: '0' |
| | | label: '自制', |
| | | name: 'selfMade', |
| | | type: 1 |
| | | }, |
| | | { |
| | | label: '不合格入库', |
| | | name: 'unqualified', |
| | | type: '1' |
| | | label: '外购', |
| | | name: 'purchase', |
| | | type: 2 |
| | | }, |
| | | { |
| | | label: '委外', |
| | | name: 'outsourcing', |
| | | type: 3 |
| | | } |
| | | ]) |
| | | |
| | | const handleTabChange = (tabName) => { |
| | | activeTab.value = tabName; |
| | | type.value = tabName === 'qualified' ? 0 : 1 |
| | | const tab = tabs.value.find(t => t.name === tabName); |
| | | type.value = tab ? tab.type : 1; |
| | | } |
| | | </script> |