| | |
| | | <el-row :gutter="30"> |
| | | <el-col :span="12"> |
| | | <el-form-item label="开票人:" prop="invoicePerson"> |
| | | <el-input v-model="form.invoicePerson" placeholder="请输入" clearable/> |
| | | <el-input v-model="form.invoicePerson" placeholder="请输入" clearable disabled/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | type="date" |
| | | placeholder="请选择" |
| | | clearable |
| | | disabled |
| | | /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | commitFile, |
| | | registrationProductPage |
| | | } from "../../../api/salesManagement/invoiceLedger.js"; |
| | | import useUserStore from "@/store/modules/user.js"; |
| | | const { proxy } = getCurrentInstance() |
| | | const tableData = ref([]) |
| | | const productData = ref([]) |
| | |
| | | }) |
| | | const { searchForm, form, rules } = toRefs(data) |
| | | const currentId = ref('') |
| | | const userStore = useUserStore() |
| | | const upload = reactive({ |
| | | // 上传的地址 |
| | | url: import.meta.env.VITE_APP_BASE_API + "/invoiceLedger/uploadFile", |
| | |
| | | productData.value = [] |
| | | fileList.value = [] |
| | | currentId.value = row.id; |
| | | |
| | | invoiceLedgerProductInfo({id: row.id}).then(res => { |
| | | form.value = {...res.data} |
| | | fileList.value = res.data.fileList; |
| | | if(!form.value.invoicePerson){ |
| | | form.value.invoicePerson = userStore.nickName |
| | | form.value.entryDate = getCurrentDate(); |
| | | } |
| | | if(!form.value.invoiceDate){ |
| | | form.value.invoiceDate = getCurrentDate(); |
| | | } |
| | | }) |
| | | dialogFormVisible.value = true |
| | | } |
| | |
| | | |
| | | } |
| | | |
| | | // 获取当前日期并格式化为 YYYY-MM-DD |
| | | function getCurrentDate() { |
| | | const today = new Date(); |
| | | const year = today.getFullYear(); |
| | | const month = String(today.getMonth() + 1).padStart(2, '0'); // 月份从0开始 |
| | | const day = String(today.getDate()).padStart(2, '0'); |
| | | return `${year}-${month}-${day}`; |
| | | } |
| | | |
| | | getList() |
| | | </script> |
| | | |