| | |
| | | |
| | | <script setup> |
| | | import {onMounted, ref} from 'vue'; |
| | | import {getSalesLedgerWithProducts} from "@/api/salesManagement/salesLedger"; |
| | | import {productList} from "@/api/salesManagement/salesLedger"; |
| | | |
| | | // 表单数据 |
| | | const form = ref({ |
| | |
| | | if (!editData.value) return; |
| | | |
| | | // 获取完整的产品信息 |
| | | getSalesLedgerWithProducts({ id: editData.value.id, type: 1 }).then((res) => { |
| | | productData.value = res.productData || []; |
| | | productList({ salesLedgerId: editData.value.id, type: 1 }).then((res) => { |
| | | productData.value = res.data || []; |
| | | form.value = {...editData.value} |
| | | }); |
| | | }; |