Browse Source

询价单报价界面

master
yanyan 1 day ago
parent
commit
9cec2782a9
  1. 4
      src/api/supplier/purReplyHist.js
  2. 34
      src/views/modules/supplier/com_inquiry_QuotationList.vue
  3. 91
      src/views/modules/supplier/purDetailList.vue
  4. 17
      src/views/modules/supplier/purHeaderList.vue
  5. 158
      src/views/modules/supplier/purReplyHistList.vue

4
src/api/supplier/purReplyHist.js

@ -0,0 +1,4 @@
import { createAPI } from '@/utils/httpRequest.js'
export const searchPurReplyHistList = (data) => createAPI(`/supplier/getPurReplyHist`, 'post', data)

34
src/views/modules/supplier/com_inquiry_QuotationList.vue

@ -44,8 +44,8 @@
fixed="right" fixed="right"
label="Actions"> label="Actions">
<template slot-scope="scope"> <template slot-scope="scope">
<a type="text" size="small" @click="editModel(scope.row)">Edit |</a>
<a type="text" size="small" @click="deleteData(scope.row)"> Delete</a>
<!-- <a type="text" size="small" @click="editModel(scope.row)">Edit |</a>
<a type="text" size="small" @click="deleteData(scope.row)"> Delete</a> -->
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -180,12 +180,9 @@
<script> <script>
// API // API
// import {
// searchQuotationList,
// createQuotation,
// updateQuotation,
// deleteQuotation
// } from '@/api/quote/quotation'
import {
searchPurReplyHistList
} from '@/api/supplier/purReplyHist.js'
export default { export default {
name: 'QuotationRecord', name: 'QuotationRecord',
@ -235,7 +232,7 @@ export default {
{ columnProp: 'partDesc', headerAlign: 'center', align: 'left', columnLabel: '物料名称', columnWidth: 150, fixed: '', columnHidden: false, columnSortable: false }, { columnProp: 'partDesc', headerAlign: 'center', align: 'left', columnLabel: '物料名称', columnWidth: 150, fixed: '', columnHidden: false, columnSortable: false },
{ columnProp: 'umid', headerAlign: 'center', align: 'center', columnLabel: '计量单位', columnWidth: 90, fixed: '', columnHidden: false, columnSortable: false }, { columnProp: 'umid', headerAlign: 'center', align: 'center', columnLabel: '计量单位', columnWidth: 90, fixed: '', columnHidden: false, columnSortable: false },
{ columnProp: 'qty', headerAlign: 'center', align: 'right', columnLabel: '询价数量', columnWidth: 100, fixed: '', columnHidden: false, columnSortable: false }, { columnProp: 'qty', headerAlign: 'center', align: 'right', columnLabel: '询价数量', columnWidth: 100, fixed: '', columnHidden: false, columnSortable: false },
{ columnProp: 'remark1', headerAlign: 'center', align: 'center', columnLabel: '状态', columnWidth: 100, fixed: '', columnHidden: false, columnSortable: false },
// { columnProp: 'remark1', headerAlign: 'center', align: 'center', columnLabel: '', columnWidth: 100, fixed: '', columnHidden: false, columnSortable: false },
{ columnProp: 'materialCost', headerAlign: 'center', align: 'right', columnLabel: '材料费用', columnWidth: 100, fixed: '', columnHidden: false, columnSortable: false }, { columnProp: 'materialCost', headerAlign: 'center', align: 'right', columnLabel: '材料费用', columnWidth: 100, fixed: '', columnHidden: false, columnSortable: false },
{ columnProp: 'produceFee', headerAlign: 'center', align: 'right', columnLabel: '加工费', columnWidth: 100, fixed: '', columnHidden: false, columnSortable: false }, { columnProp: 'produceFee', headerAlign: 'center', align: 'right', columnLabel: '加工费', columnWidth: 100, fixed: '', columnHidden: false, columnSortable: false },
{ columnProp: 'surfaceFee', headerAlign: 'center', align: 'right', columnLabel: '表面处理费', columnWidth: 110, fixed: '', columnHidden: false, columnSortable: false }, { columnProp: 'surfaceFee', headerAlign: 'center', align: 'right', columnLabel: '表面处理费', columnWidth: 110, fixed: '', columnHidden: false, columnSortable: false },
@ -272,20 +269,15 @@ export default {
searchTable() { searchTable() {
this.dataListLoading = true this.dataListLoading = true
// TODO: // TODO:
// searchQuotationList(this.searchData).then(({ data }) => {
// if (data && data.code === 0) {
// this.dataList = data.rows
// } else {
// this.dataList = []
// }
// this.dataListLoading = false
// })
// 使
setTimeout(() => {
searchPurReplyHistList(this.searchData).then(({ data }) => {
if (data && data.code === 0) {
this.dataList = data.rows
} else {
this.dataList = [] this.dataList = []
}
this.dataListLoading = false this.dataListLoading = false
}, 500)
})
}, },
// //
addModal() { addModal() {

91
src/views/modules/supplier/purDetailList.vue

@ -39,9 +39,11 @@
<el-form-item label="状态:"> <el-form-item label="状态:">
<el-select v-model="searchData.status" placeholder="请选择" clearable style="width: 120px"> <el-select v-model="searchData.status" placeholder="请选择" clearable style="width: 120px">
<el-option label="全部" value=""></el-option> <el-option label="全部" value=""></el-option>
<el-option label="进行中" value="进行中"></el-option>
<el-option label="已完成" value="已完成"></el-option>
<el-option label="已取消" value="已取消"></el-option>
<el-option label="待报价" value="待报价"></el-option>
<el-option label="已报价" value="已报价"></el-option>
<el-option label="已接受" value="已接受"></el-option>
<el-option label="未接受" value="未接受"></el-option>
<el-option label="已拒绝" value="已拒绝"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label=" "> <el-form-item label=" ">
@ -200,7 +202,7 @@ export default {
spec: '', spec: '',
qty: 0, qty: 0,
remark2: '', remark2: '',
status: '进行中',
status: '',
materialCost: 0, materialCost: 0,
produceFee: 0, produceFee: 0,
surfaceFee: 0, surfaceFee: 0,
@ -296,81 +298,40 @@ export default {
this.refreshCurrentTabTable() this.refreshCurrentTabTable()
}, },
refreshCurrentTabTable() { refreshCurrentTabTable() {
// - 使
if (!this.currentRow || !this.currentRow.orderNo) {
if (this.activeName === 'quotationList') {
if (this.$refs.quotationList) {
this.$refs.quotationList.init({ orderNo: '', itemNo: '', height: this.tabHeight })
}
} else if (this.activeName === 'attachments') {
if (this.$refs.attachments) {
this.$refs.attachments.init({
orderRef1: this.$store.state.user.site,
orderRef2: this.searchData.orderNo,
orderRef3: this.searchData.partNo,
orderReftype: 'purQuotationDetail',
height: this.tabHeight
})
if (this.currentRow === '' || this.currentRow === null) {
this.currentRow = {site: '', orderNo: ''}
} }
if (this.activeName === 'quotationList') {
this.refreshQuotationList()
} }
return
if (this.activeName === 'attachments') {
this.refreshAttachments()
} }
if (this.activeName === 'quotationList') {
if (this.$refs.quotationList) {
this.$refs.quotationList.init({
},
refreshQuotationList(){
let inData = {
site: this.currentRow.site,
orderNo: this.currentRow.orderNo, orderNo: this.currentRow.orderNo,
itemNo: this.currentRow.itemNo, itemNo: this.currentRow.itemNo,
type: 'view',
partNo: this.currentRow.partNo,
type: 'add',
height: this.tabHeight height: this.tabHeight
})
} }
} else if (this.activeName === 'attachments') {
if (this.$refs.attachments) {
this.$refs.attachments.init({
this.$refs.quotationList.init(inData)
},
refreshAttachments () {
let inData = {
orderRef1: this.currentRow.site, orderRef1: this.currentRow.site,
orderRef2: this.currentRow.orderNo, orderRef2: this.currentRow.orderNo,
orderRef3: this.currentRow.partNo, orderRef3: this.currentRow.partNo,
orderReftype: 'purQuotationDetail', orderReftype: 'purQuotationDetail',
height: this.tabHeight height: this.tabHeight
})
} }
this.$refs.attachments.init(inData)
} }
},
//
addInquiry() {
this.isAdd = true
this.currentInquiry = {
orderNo: '',
itemNo: '',
uploadFlag: 'N',
supplierId: '',
supplierName: '',
partNo: '',
partDesc: '',
umid: '',
spec: '',
qty: 0,
remark2: '',
status: '进行中',
materialCost: 0,
produceFee: 0,
surfaceFee: 0,
profit: 0,
price: 0,
taxRate: 13,
tax: 0,
duty: 0,
purchaseCycle: 0,
mouldFee: 0,
additionalCost: 0,
freight: 0,
orderDate: this.$dayjs().format('YYYY-MM-DD'),
remark: '',
lastUpdateBy: this.$store.state.user.name,
site: this.$store.state.user.site
}
this.inquiryDialogVisible = true
}
} }
} }

17
src/views/modules/supplier/purHeaderList.vue

@ -13,9 +13,12 @@
</el-form-item> </el-form-item>
<el-form-item :label="'状态'"> <el-form-item :label="'状态'">
<el-select v-model="searchData.status" placeholder="请选择" style="width:100px" clearable> <el-select v-model="searchData.status" placeholder="请选择" style="width:100px" clearable>
<el-option label="全部" value="" />
<el-option label="已计划" value="已计划" />
<el-option label="已下达" value="已下达" />
<el-option label="全部" value=""></el-option>
<el-option label="待报价" value="待报价"></el-option>
<el-option label="已报价" value="已报价"></el-option>
<el-option label="已接受" value="已接受"></el-option>
<el-option label="未接受" value="未接受"></el-option>
<el-option label="已拒绝" value="已拒绝"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label=" "> <el-form-item label=" ">
@ -27,7 +30,7 @@
<!-- 主表询价单列表 --> <!-- 主表询价单列表 -->
<el-table :data="dataList" :height="tableHeight" border highlight-current-row @row-click="selectInquiry" v-loading="loading" style="width:100%"> <el-table :data="dataList" :height="tableHeight" border highlight-current-row @row-click="selectInquiry" v-loading="loading" style="width:100%">
<el-table-column fixed="right" label="操作" header-align="center" align="center" width="140"> <el-table-column fixed="right" label="操作" header-align="center" align="center" width="140">
<template slot-scope="scope">
<template slot-scope="scope" v-if="scope.row.status === '待提交'">
<a class="customer-a" @click.stop="openDialog(scope.row)">编辑 |</a> <a class="customer-a" @click.stop="openDialog(scope.row)">编辑 |</a>
<a class="customer-a" @click.stop="handleDelete(scope.row)">删除</a> <a class="customer-a" @click.stop="handleDelete(scope.row)">删除</a>
<a class="customer-a" @click="updateQuoDetail(scope.row)">提交</a> <a class="customer-a" @click="updateQuoDetail(scope.row)">提交</a>
@ -520,7 +523,7 @@ export default {
contact: '', contact: '',
remark: '', remark: '',
printed : "N", printed : "N",
status: '已计划'
status: '待提交'
}, },
// //
currentInquiry: null, currentInquiry: null,
@ -835,7 +838,7 @@ export default {
contact: '', contact: '',
remark: '', remark: '',
printed : "N", printed : "N",
status: '已计划'
status: '待提交'
} }
} }
this.dialogVisible = true this.dialogVisible = true
@ -927,7 +930,7 @@ export default {
spec: '', spec: '',
qty: 0, qty: 0,
remark2: '', remark2: '',
status: '待提交'
status: '待报价'
} }
} }
this.materialDialogVisible = true this.materialDialogVisible = true

158
src/views/modules/supplier/purReplyHistList.vue

@ -78,7 +78,13 @@
width="180" width="180"
label="Action"> label="Action">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link style="cursor: pointer" @click="openQuoteDialog(scope.row)">报价</el-link>
<el-link
v-if="scope.row.status === '待报价'"
style="cursor: pointer"
@click="openQuoteDialog(scope.row)">
报价
</el-link>
<!-- <el-link style="cursor: pointer" @click="openQuoteDialog(scope.row)">报价</el-link> -->
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -123,19 +129,20 @@
<!-- 基础信息 --> <!-- 基础信息 -->
<div class="form-section"> <div class="form-section">
<div class="section-title">基础信息</div>
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="6"> <el-col :span="6">
<el-form-item label="物料编码" prop="partNo"> <el-form-item label="物料编码" prop="partNo">
<el-input v-model="quoteForm.partNo" :disabled="true" placeholder="物料编码"></el-input> <el-input v-model="quoteForm.partNo" :disabled="true" placeholder="物料编码"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6">
<el-col :span="18">
<el-form-item label="物料名称" prop="partDesc"> <el-form-item label="物料名称" prop="partDesc">
<el-input v-model="quoteForm.partDesc" :disabled="true" placeholder="物料名称"></el-input> <el-input v-model="quoteForm.partDesc" :disabled="true" placeholder="物料名称"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6">
</el-row>
<el-row :gutter="20">
<el-col :span="18">
<el-form-item label="规格型号" prop="spec"> <el-form-item label="规格型号" prop="spec">
<el-input v-model="quoteForm.spec" :disabled="true" placeholder="规格型号"></el-input> <el-input v-model="quoteForm.spec" :disabled="true" placeholder="规格型号"></el-input>
</el-form-item> </el-form-item>
@ -147,67 +154,62 @@
</el-col> </el-col>
</el-row> </el-row>
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="18">
<el-form-item label="其他要求" prop="otherCondition">
<el-input v-model="quoteForm.otherCondition" type="text" :disabled="true" :rows="1" placeholder="其他要求"></el-input>
</el-form-item>
</el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="计量单位" prop="umid"> <el-form-item label="计量单位" prop="umid">
<el-input v-model="quoteForm.umid" :disabled="true" placeholder="计量单位"></el-input> <el-input v-model="quoteForm.umid" :disabled="true" placeholder="计量单位"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
</div> </div>
<!-- 费用信息 --> <!-- 费用信息 -->
<div class="form-section"> <div class="form-section">
<div class="section-title">费用信息</div>
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="6"> <el-col :span="6">
<el-form-item label="材料费用" prop="materialCost"> <el-form-item label="材料费用" prop="materialCost">
<el-input-number v-model="quoteForm.materialCost" :precision="2" :min="0" style="width: 100%"></el-input-number>
<el-input-number v-model="quoteForm.materialCost" @change="calculatePrice" :precision="2" :min="0" style="width: 100%"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="加工费" prop="produceFee"> <el-form-item label="加工费" prop="produceFee">
<el-input-number v-model="quoteForm.produceFee" :precision="2" :min="0" style="width: 100%"></el-input-number>
<el-input-number v-model="quoteForm.produceFee" @change="calculatePrice" :precision="2" :min="0" style="width: 100%"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="表面处理费" prop="surfaceFee"> <el-form-item label="表面处理费" prop="surfaceFee">
<el-input-number v-model="quoteForm.surfaceFee" :precision="2" :min="0" style="width: 100%"></el-input-number>
<el-input-number v-model="quoteForm.surfaceFee" @change="calculatePrice" :precision="2" :min="0" style="width: 100%"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="利润" prop="profit"> <el-form-item label="利润" prop="profit">
<el-input-number v-model="quoteForm.profit" :precision="2" :min="0" style="width: 100%"></el-input-number>
<el-input-number v-model="quoteForm.profit" @change="calculatePrice" :precision="2" :min="0" style="width: 100%"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<!-- 价格信息 -->
<div class="form-section">
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="6"> <el-col :span="6">
<el-form-item label="模具费" prop="mouldFee">
<el-input-number v-model="quoteForm.mouldFee" :precision="2" :min="0" style="width: 100%"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="附加费用" prop="additionalCost">
<el-input-number v-model="quoteForm.additionalCost" :precision="2" :min="0" style="width: 100%"></el-input-number>
<el-form-item label="未税单价" prop="price">
<el-input-number v-model="quoteForm.price" :disabled="true" :precision="4" :min="0" style="width: 100%" @change="calculateTax"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="运费" prop="freight">
<el-input-number v-model="quoteForm.freight" :precision="2" :min="0" style="width: 100%"></el-input-number>
<el-form-item label="税率(%)" prop="taxRate">
<el-input-number v-model="quoteForm.taxRate" :disabled="true" :precision="2" :min="0" :max="100" style="width: 100%" @change="calculateTax"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="采购周期(天)" prop="purchaseCycle">
<el-input-number v-model="quoteForm.purchaseCycle" :min="0" :precision="0" style="width: 100%"></el-input-number>
<el-form-item label="含税单价" prop="tax">
<el-input-number v-model="quoteForm.tax" :disabled="true" :precision="4" :min="0" style="width: 100%"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row>
<el-row :gutter="20">
<el-col :span="6"> <el-col :span="6">
<el-form-item label="关税" prop="duty"> <el-form-item label="关税" prop="duty">
<el-input-number v-model="quoteForm.duty" :precision="2" :min="0" style="width: 100%"></el-input-number> <el-input-number v-model="quoteForm.duty" :precision="2" :min="0" style="width: 100%"></el-input-number>
@ -215,24 +217,25 @@
</el-col> </el-col>
</el-row> </el-row>
</div> </div>
<!-- 价格信息 -->
<div class="form-section">
<div class="section-title">价格信息</div>
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="8">
<el-form-item label="未税单价" prop="price">
<el-input-number v-model="quoteForm.price" :precision="4" :min="0" style="width: 100%" @change="calculateTax"></el-input-number>
<el-col :span="6">
<el-form-item label="采购周期(天)" prop="purchaseCycle">
<el-input-number v-model="quoteForm.purchaseCycle" :min="0" :precision="0" style="width: 100%"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="税率(%)" prop="taxRate">
<el-input-number v-model="quoteForm.taxRate" :precision="2" :min="0" :max="100" style="width: 100%" @change="calculateTax"></el-input-number>
<el-col :span="6">
<el-form-item label="模具费" prop="mouldFee">
<el-input-number v-model="quoteForm.mouldFee" :precision="2" :min="0" style="width: 100%"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="含税单价" prop="tax">
<el-input-number v-model="quoteForm.tax" :precision="4" :min="0" style="width: 100%"></el-input-number>
<el-col :span="6">
<el-form-item label="附加费用" prop="additionalCost">
<el-input-number v-model="quoteForm.additionalCost" :precision="2" :min="0" style="width: 100%"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="运费" prop="freight">
<el-input-number v-model="quoteForm.freight" :precision="2" :min="0" style="width: 100%"></el-input-number>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -240,18 +243,10 @@
<!-- 其他信息 --> <!-- 其他信息 -->
<div class="form-section"> <div class="form-section">
<div class="section-title">其他信息</div>
<el-row :gutter="20">
<el-col :span="24">
<el-form-item label="其他要求" prop="otherCondition">
<el-input v-model="quoteForm.otherCondition" type="textarea" :rows="1" placeholder="其他要求"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="24"> <el-col :span="24">
<el-form-item label="特殊要求" prop="remark2"> <el-form-item label="特殊要求" prop="remark2">
<el-input v-model="quoteForm.remark2" type="textarea" :rows="1" placeholder="请输入特殊要求"></el-input>
<el-input v-model="quoteForm.remark2" type="textarea" :disabled="true" :rows="1" placeholder="请输入特殊要求"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -456,47 +451,44 @@ export default {
this.currentRow = row ? JSON.parse(JSON.stringify(row)) : { site: '', orderNo: '', itemNo: '' } this.currentRow = row ? JSON.parse(JSON.stringify(row)) : { site: '', orderNo: '', itemNo: '' }
this.refreshCurrentTabTable() this.refreshCurrentTabTable()
}, },
tabClick() { tabClick() {
this.refreshCurrentTabTable() this.refreshCurrentTabTable()
}, },
refreshCurrentTabTable() { refreshCurrentTabTable() {
if (!this.currentRow || !this.currentRow.orderNo) {
if (this.activeName === 'quotationList') {
if (this.$refs.quotationList) {
this.$refs.quotationList.init({ orderNo: '', itemNo: '', height: this.tabHeight })
if (this.currentRow === '' || this.currentRow === null) {
this.currentRow = {site: '', orderNo: ''}
} }
} else if (this.activeName === 'attachments') {
if (this.$refs.attachments) {
this.$refs.attachments.init({
orderRef1: this.$store.state.user.site,
orderRef2: this.searchData.orderNo,
orderRef3: this.searchData.partNo,
orderReftype: 'purQuotationDetail',
height: this.tabHeight
})
if (this.activeName === 'quotationList') {
this.refreshQuotationList()
} }
if (this.activeName === 'attachments') {
this.refreshAttachments()
} }
return
}
if (this.activeName === 'quotationList') {
if (this.$refs.quotationList) {
this.$refs.quotationList.init({
},
refreshQuotationList(){
let inData = {
site: this.currentRow.site,
orderNo: this.currentRow.orderNo, orderNo: this.currentRow.orderNo,
itemNo: this.currentRow.itemNo, itemNo: this.currentRow.itemNo,
partNo: this.currentRow.partNo,
type: 'add',
height: this.tabHeight height: this.tabHeight
})
} }
} else if (this.activeName === 'attachments') {
if (this.$refs.attachments) {
this.$refs.attachments.init({
this.$refs.quotationList.init(inData)
},
refreshAttachments () {
let inData = {
orderRef1: this.currentRow.site, orderRef1: this.currentRow.site,
orderRef2: this.currentRow.orderNo, orderRef2: this.currentRow.orderNo,
orderRef3: this.currentRow.partNo, orderRef3: this.currentRow.partNo,
orderReftype: 'purQuotationDetail', orderReftype: 'purQuotationDetail',
height: this.tabHeight height: this.tabHeight
})
}
} }
this.$refs.attachments.init(inData)
}, },
// //
openQuoteDialog(row) { openQuoteDialog(row) {
@ -539,16 +531,27 @@ export default {
site: this.$store.state.user.site, site: this.$store.state.user.site,
createdBy: this.$store.state.user.name createdBy: this.$store.state.user.name
} }
//
this.calculateTax()
// :
this.calculatePrice()
// this.calculateTax()
this.quoteDialogVisible = true this.quoteDialogVisible = true
}, },
calculatePrice(){
//=+++
this.quoteForm.price = this.quoteForm.materialCost + this.quoteForm.produceFee +
this.quoteForm.surfaceFee + this.quoteForm.profit
this.calculateTax()
},
// //
calculateTax() { calculateTax() {
//=*(1+)
if (this.quoteForm.price && this.quoteForm.taxRate) { if (this.quoteForm.price && this.quoteForm.taxRate) {
this.quoteForm.tax = this.quoteForm.price * (1 + this.quoteForm.taxRate / 100) this.quoteForm.tax = this.quoteForm.price * (1 + this.quoteForm.taxRate / 100)
} }
}, },
// //
submitQuote() { submitQuote() {
this.$refs.quoteForm.validate((valid) => { this.$refs.quoteForm.validate((valid) => {
@ -618,7 +621,6 @@ export default {
.dialog-content { .dialog-content {
width: 100%; width: 100%;
} }
/* 产品表单样式 */ /* 产品表单样式 */
.part-form { .part-form {
width: 100%; width: 100%;
@ -642,10 +644,6 @@ export default {
/* 表单分组样式 */ /* 表单分组样式 */
.form-section { .form-section {
margin-bottom: 5px; margin-bottom: 5px;
font-size: 12px;
font-weight: 600;
color: #409EFF;
margin: 5px 0 5px 0;
} }
.form-section:last-child { .form-section:last-child {

Loading…
Cancel
Save