Browse Source

2024-03-27 测试修改

master
zelian_wu 2 years ago
parent
commit
ac8dccef75
  1. 1
      src/api/quotation/quoteOfRouting.js
  2. 83
      src/views/modules/quotation/sellForQuotation/quotationDetail/billOfMateriel.vue
  3. 67
      src/views/modules/quotation/sellForQuotation/quotationDetail/quoteRouting.vue
  4. 8
      src/views/modules/quotation/sellForQuotation/quoteDetail.vue
  5. 3
      src/views/modules/test/testSoAttribute/testAttribute.vue
  6. 2
      src/views/modules/test/testSoBom/testTable.vue

1
src/api/quotation/quoteOfRouting.js

@ -5,4 +5,5 @@ export const searchQuoteRoutingHeader = (data)=>createAPI(`/quote/routing/header
export const updateQuoteRoutingList = (data)=>createAPI(`/quote/routing/update`,'post',data);
export const searchQuoteRoutingList = (data)=>createAPI(`/quote/routing/list`,'post',data);
export const searchQuoteRoutingAlternativeNo = (data)=>createAPI(`/quote/routing/version/list`,'post',data);
export const searchQuoteRoutingDetailList = (data)=>createAPI(`/quote/routing/detail/list`,'post',data);

83
src/views/modules/quotation/sellForQuotation/quotationDetail/billOfMateriel.vue

@ -1,6 +1,6 @@
<script>
import {
getBomTreeStructure, searchQuoteBOMAlternativeNo,
getBomTreeStructure, searchQuoteBOMAllCost, searchQuoteBOMAlternativeNo,
searchQuoteBomList,
searchQuoteBOMVersion,
updateQuoteBomList
@ -29,6 +29,20 @@ export default {
totalCost:{
type:Number,
default:-1,
},
allSearchFlag:{
type:Boolean,
default:false,
},
},
computed:{
BOMAllSearchFlag:{
get(){
return this.allSearchFlag;
},
set(val){
this.$emit("update:allSearchFlag",val)
}
}
},
data(){
@ -65,6 +79,23 @@ export default {
status: true,
fixed: '',
columnWidth: 50,
},{
userId: this.$store.state.user.name,
functionId: 102003,
serialNumber: '102003Table4PartNo',
tableId: "102003Table4",
tableName: "报价材料信息",
columnProp: 'partNo',
headerAlign: "center",
align: "center",
columnLabel: '产品编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 100,
},{
userId: this.$store.state.user.name,
functionId: 102003,
@ -74,7 +105,7 @@ export default {
columnProp: 'componentPart',
headerAlign: "center",
align: "center",
columnLabel: '物料编码',
columnLabel: '零部件编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
@ -311,20 +342,38 @@ export default {
},
searchQuoteBomListPost(params){
this.dataListLoading = true;
searchQuoteBomList(params).then(({data})=>{
if (data && data.code === 0){
this.bomDetailList = data.rows
this.computedQuoteBomCost();
}else {
this.$message.warning(data.msg)
}
this.dataListLoading = false;
this.$emit("update:loadingStatus",this.dataListLoading)
}).catch((error)=>{
this.dataListLoading = false;
this.$emit("update:loadingStatus",this.dataListLoading)
this.$message.error(error)
})
if (this.BOMAllSearchFlag){
searchQuoteBomList(params).then(({data})=>{
if (data && data.code === 0){
this.bomDetailList = data.rows
this.computedQuoteBomCost();
}else {
this.$message.warning(data.msg)
}
this.dataListLoading = false;
this.$emit("update:loadingStatus",this.dataListLoading)
}).catch((error)=>{
this.dataListLoading = false;
this.$emit("update:loadingStatus",this.dataListLoading)
this.$message.error(error)
})
}else {
// this.dataListLoading = false;
searchQuoteBOMAllCost(params).then(({data})=>{
if (data && data.code === 0){
this.bomDetailList = data.rows
this.computedQuoteBomCost();
}else {
this.$message.warning(data.msg)
}
this.dataListLoading = false;
this.$emit("update:loadingStatus",this.dataListLoading)
}).catch((error)=>{
this.$message.error(error)
this.dataListLoading = false;
this.$emit("update:loadingStatus",this.dataListLoading)
})
}
},
computedQuoteBomCost(){
this.$emit("update:loadingStatus",true)
@ -468,6 +517,8 @@ export default {
<div>
<div style="margin-bottom: 5px">
<el-link style="cursor:pointer;" v-if="this.selectBom.length === 6 && bomTreeStructure.length >= 0" @click="clickVersionCheck">切换版本</el-link>
<span style="display: inline-block;width: 20px"></span>
<el-checkbox v-model="BOMAllSearchFlag">全级BOM结构</el-checkbox>
</div>
<el-container>
<el-aside width="24%" style="padding: 0;" :style="{height: height}" v-loading="treeLoading">

67
src/views/modules/quotation/sellForQuotation/quotationDetail/quoteRouting.vue

@ -1,6 +1,6 @@
<script>
import {
getRoutingTreeStructure, searchQuoteRoutingAlternativeNo,
getRoutingTreeStructure, searchQuoteRoutingAlternativeNo, searchQuoteRoutingDetailList,
searchQuoteRoutingList,
updateQuoteRoutingList
} from "../../../../../api/quotation/quoteOfRouting";
@ -26,6 +26,20 @@ export default {
type:Boolean,
default:false,
},
allSearchFlag:{
type:Boolean,
default:false,
},
},
computed:{
RoutingAllSearchFlag:{
get(){
return this.allSearchFlag;
},
set(val){
this.$emit("update:allSearchFlag",val)
}
}
},
data(){
return{
@ -479,20 +493,37 @@ export default {
}
this.routingDetailList = [];
this.dataListLoading = true;
searchQuoteRoutingList(params).then(({data})=>{
this.dataListLoading = false;
if (data && data.code === 0){
this.routingDetailList = data.rows
this.computedQuoteRoutingCost();
}else {
this.$message.warning(data.msg)
}
this.$emit("update:loadingStatus",this.dataListLoading)
}).catch((error)=>{
this.dataListLoading = false;
this.$emit("update:loadingStatus",this.dataListLoading)
this.$message.error(error)
})
if (this.RoutingAllSearchFlag){
searchQuoteRoutingList(params).then(({data})=>{
this.dataListLoading = false;
if (data && data.code === 0){
this.routingDetailList = data.rows
this.computedQuoteRoutingCost();
}else {
this.$message.warning(data.msg)
}
this.$emit("update:loadingStatus",this.dataListLoading)
}).catch((error)=>{
this.dataListLoading = false;
this.$emit("update:loadingStatus",this.dataListLoading)
this.$message.error(error)
})
}else {
searchQuoteRoutingDetailList(params).then(({data})=>{
this.dataListLoading = false;
if (data && data.code === 0){
this.routingDetailList = data.rows
this.computedQuoteRoutingCost();
}else {
this.$message.warning(data.msg)
}
this.$emit("update:loadingStatus",this.dataListLoading)
}).catch((error)=>{
this.dataListLoading = false;
this.$emit("update:loadingStatus",this.dataListLoading)
this.$message.error(error)
})
}
},
computedQuoteRoutingCost(){
for (let i = 0; i < this.routingDetailList.length; i++) {
@ -624,7 +655,11 @@ export default {
<template>
<div>
<div style="margin-bottom: 5px"><el-link style="cursor:pointer;" v-if="this.selectRouting.length === 6" @click="clickVersionCheck">切换版本</el-link></div>
<div style="margin-bottom: 5px">
<el-link style="cursor:pointer;" v-if="this.selectRouting.length === 6" @click="clickVersionCheck">切换版本</el-link>
<span style="display: inline-block;width: 20px"></span>
<el-checkbox v-model="RoutingAllSearchFlag">全级Routing结构</el-checkbox>
</div>
<el-container>
<el-aside width="24%" style="padding: 0;" :style="{height: height}" v-loading="treeLoading">
<el-tree :data="routingTreeStructure"

8
src/views/modules/quotation/sellForQuotation/quoteDetail.vue

@ -57,6 +57,8 @@ export default {
})
};
return{
allSearchFlagBom:false,
allSearchFlagRouting:false,
BOMCost:0,
ToolCost:0,
packInfoCost:0,
@ -882,6 +884,8 @@ export default {
})
},
searchQuoteBomList(){
this.allSearchFlagBom = false;
this.allSearchFlagRouting = false;
let params = {
site:this.$store.state.user.site,
quoteDetailId:this.quotationDetail.quotationDetailId,
@ -1083,10 +1087,10 @@ export default {
</el-form>
<el-tabs v-model="activeName" @tab-click="tabClick" :style="{height:`${fullscreen?740:500}px`}" border stripe>
<el-tab-pane name="bom" label="材料">
<bill-of-materiel ref="bom" :total-cost.sync="BOMCost" :loading-status.sync="loadingStatus" :updateTree.sync="update" v-if="quotationDetailFlag" :height="fullscreen?655:415" :detail="quotationDetail"></bill-of-materiel>
<bill-of-materiel ref="bom" :all-search-flag.sync="allSearchFlagBom" :total-cost.sync="BOMCost" :loading-status.sync="loadingStatus" :updateTree.sync="update" v-if="quotationDetailFlag" :height="fullscreen?655:415" :detail="quotationDetail"></bill-of-materiel>
</el-tab-pane>
<el-tab-pane name="routing" label="工艺">
<quote-routing ref="routing" v-if="quotationDetailFlag" :loading-status.sync="loadingStatus" :height="fullscreen?655:415" :detail="quotationDetail"></quote-routing>
<quote-routing ref="routing" :all-search-flag.sync="allSearchFlagRouting" v-if="quotationDetailFlag" :loading-status.sync="loadingStatus" :height="fullscreen?655:415" :detail="quotationDetail"></quote-routing>
</el-tab-pane>
<el-tab-pane name="tool" label="工具">
<tool-quotation ref="tool" :total-cost.sync="ToolCost" v-if="quotationDetailFlag" :height="fullscreen?660:420" :detail="quotationDetail"></tool-quotation>

3
src/views/modules/test/testSoAttribute/testAttribute.vue

@ -12,7 +12,8 @@ export default {
default:320
},
attributeList:{
type:Array
type:Array,
default: ()=>[]
}
},
data(){

2
src/views/modules/test/testSoBom/testTable.vue

@ -18,7 +18,7 @@ export default {
props:{
dataList:{
type: Array,
default:[],
default: ()=>[],
},
testNo:{
type:String,

Loading…
Cancel
Save