| | |
| | | import { getQuotationList, getDelQuotation } from "@/api/sales/quotation" |
| | | import pageMixin from "@/components/makepager/pager/mixin/pageMixin" |
| | | import DetailQuotation from "@/views/sales/quotation/DetailQuotation" |
| | | import { |
| | | getProductInventoryInfo, |
| | | } from "@/api/sales/salesDetails" |
| | | export default { |
| | | name: "QuotationView", |
| | | props: { |
| | |
| | | { label: "产品名称", prop: "name" }, |
| | | { label: "数量", prop: "amount" }, |
| | | { label: "单位", prop: "unit" }, |
| | | { label: "销售单价", prop: "salePrice" }, |
| | | { label: "成本单价", prop: "carrier" }, |
| | | { label: "毛利", prop: "waybillNumber" }, |
| | | { label: "毛利率", prop: "salePrice", price: true }, |
| | | { label: "销售单价", prop: "price" }, |
| | | { label: "成本单价", prop: "cost" }, |
| | | { label: "毛利", prop: "profit" }, |
| | | { label: "毛利率", prop: "margin",}, |
| | | { label: "价税合计", prop: "valorem", price: true } |
| | | ] |
| | | return { |
| | |
| | | { label: "有效期", prop: "validity_date", min: 100 }, // 修改时间 |
| | | // { label: "小计", prop: "subTotal" }, // 小计 |
| | | // { label: "合计", prop: "total" }, // 合计 |
| | | { label: "客戶名称", prop: "client_name", }, |
| | | { label: "数量", prop: "productNumber", isProductAmount: true }, |
| | | { label: "合计", prop: "priceTax", isProductTotal: true }, |
| | | { label: "状态", prop: "priceTax",} |
| | | { label: "客戶名称", prop: "client_name",min: 120,}, |
| | | { label: "状态", prop: "quotationStatus",} |
| | | ], |
| | | showCol: ["报价单号", "报价单名称", "销售负责人", "有效期", "客戶名称", "数量", "合计",'状态'], |
| | | showCol: ["报价单号", "报价单名称", "销售负责人", "有效期", "客戶名称","状态"], |
| | | selectRow: {}, |
| | | loading:false, |
| | | // 增加 产品信息列表 |
| | |
| | | }, |
| | | // 获取产品/库存信息 |
| | | async getProductInventoryInfo(row) { |
| | | if (row.status === 1) { |
| | | this.productTableList.tableInfomation = row.products || [] |
| | | } else { |
| | | await getProductInventoryInfo(row.number).then((res) => { |
| | | console.log(res) |
| | | this.productTableList.tableInfomation = res.data?.length > 0 ? res.data : [] |
| | | }) |
| | | } |
| | | this.productTableList.tableInfomation = row.products || [] |
| | | }, |
| | | // top 行点击 |
| | | tableRowClick(row) { |
| | |
| | | ...item, |
| | | client_name: item.client.name, |
| | | contact_name: item.contact.name, |
| | | member_name: item.member.username |
| | | member_name: item.member.username, |
| | | quotationStatus:item.quotation_status.name, |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |