| | |
| | | width="60" |
| | | /> |
| | | <el-table-column label="产品大类" prop="productCategory" /> |
| | | <el-table-column label="规格型号" prop="specificationModel" /> |
| | | <el-table-column |
| | | label="规格型号" |
| | | prop="specificationModel" |
| | | width="150" |
| | | /> |
| | | <el-table-column label="单位" prop="unit" width="70" /> |
| | | <el-table-column label="数量" prop="quantity" width="70" /> |
| | | <el-table-column label="税率(%)" prop="taxRate" width="70" /> |
| | |
| | | </el-row> |
| | | <el-row :gutter="30"> |
| | | <el-col :span="12"> |
| | | <el-form-item label="录入人"> |
| | | <el-form-item label="录入人" prop="createUer"> |
| | | <el-input v-model="form.createUer" placeholder="请输入录入人" /> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | width="60" |
| | | /> |
| | | <el-table-column label="产品大类" prop="productCategory" /> |
| | | <el-table-column label="规格型号" prop="specificationModel" /> |
| | | <el-table-column |
| | | label="规格型号" |
| | | prop="specificationModel" |
| | | width="150" |
| | | /> |
| | | <el-table-column label="单位" prop="unit" /> |
| | | <el-table-column label="数量" prop="quantity" width="70" /> |
| | | <el-table-column label="税率(%)" prop="taxRate" width="70" /> |
| | |
| | | ></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="未开票数" prop="noInvoiceNum"> |
| | | <el-table-column label="未开票数" prop="noInvoiceNum" width="100"> |
| | | <template #default="scope"> |
| | | <el-input |
| | | type="number" |
| | |
| | | ></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="登记人" prop="register"> |
| | | <template #default="{ row }"> |
| | | <el-input v-model="row.register" placeholder="请输入登记人" /> |
| | | </template> |
| | | <el-table-column label="登记人" prop="register" width="100"> |
| | | <!-- <template #default="{ row }"> |
| | | <el-input |
| | | v-model="row.register" |
| | | placeholder="请输入登记人" |
| | | disabled |
| | | /> |
| | | </template> --> |
| | | </el-table-column> |
| | | <el-table-column label="登记日期" prop="registerDate"> |
| | | <template #default="{ row }"> |
| | | <el-table-column label="登记日期" prop="registerDate" width="150"> |
| | | <!-- <template #default="{ row }"> |
| | | <el-date-picker |
| | | style="width: 100%" |
| | | v-model="row.registerDate" |
| | |
| | | type="date" |
| | | placeholder="请选择" |
| | | clearable |
| | | disabled |
| | | /> |
| | | </template> |
| | | </template> --> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-form> |
| | |
| | | import { invoiceRegistrationSave } from "@/api/salesManagement/invoiceRegistration.js"; |
| | | import useFormData from "@/hooks/useFormData"; |
| | | import useUserStore from "@/store/modules/user"; |
| | | import dayjs from "dayjs"; |
| | | |
| | | const { proxy } = getCurrentInstance(); |
| | | const userStore = useUserStore(); |
| | |
| | | projectName: "", |
| | | productData: [], |
| | | invoiceNo: "", |
| | | createUer: "", |
| | | issueDate: "", |
| | | createUer: userStore.nickName, |
| | | issueDate: dayjs().format("YYYY-MM-DD"), |
| | | }, |
| | | rules: { |
| | | salesLedgerId: [{ required: true, message: "请选择", trigger: "change" }], |
| | | createUer: [{ required: true, message: "请选择", trigger: "blur" }], |
| | | issueDate: [{ required: true, message: "请选择", trigger: "change" }], |
| | | createTime: [{ required: true, message: "请选择", trigger: "change" }], |
| | | }, |
| | | }); |
| | | const { form, rules } = toRefs(data); |
| | |
| | | }; |
| | | |
| | | const formattedInputNumber = (value) => { |
| | | return parseFloat(value).toFixed(2); |
| | | return value ? parseFloat(value).toFixed(2) : 0; |
| | | }; |
| | | |
| | | // 查询列表 |
| | |
| | | productList({ salesLedgerId: row.id, type: 1 }).then((res) => { |
| | | const index = tableData.value.findIndex((item) => item.id === row.id); |
| | | if (index > -1) { |
| | | tableData.value[index].children = res; |
| | | tableData.value[index].children = res.data; |
| | | } |
| | | expandedRowKeys.value.push(row.id); |
| | | }); |
| | |
| | | productData.value = []; |
| | | getSalesLedgerWithProducts({ id: selectedRows.value[0].id }).then((res) => { |
| | | form.value = { ...res }; |
| | | form.value.createTime = dayjs().format("YYYY-MM-DD"); |
| | | form.value.createUer = userStore.nickName; |
| | | productData.value = form.value.productData.map((item) => { |
| | | return item; |
| | | }); |