|
@@ -1,4 +1,4 @@
|
|
|
-<!-- <!--收购管理新增-->
|
|
|
+<!-- 收购管理新增-->
|
|
|
<template>
|
|
|
<el-container class="container">
|
|
|
<!-- <div class="type">{{type}}</div> -->
|
|
@@ -11,8 +11,8 @@
|
|
|
<el-row class="base-info">
|
|
|
<el-col :span="2" style="line-height: 32px;">基本信息</el-col>
|
|
|
<el-col :span="22">
|
|
|
- <el-button :type="isSolidFood?'primary':''" @click="typeChange()">以水分定价</el-button>
|
|
|
- <el-button :type="isSolidFood?'primary':''" @click="typeChange(1)">以容重定价</el-button>
|
|
|
+ <el-button :type="!isSolidFood?'primary':''" @click="typeChange()" v-if="type == '新增'">以水分定价</el-button>
|
|
|
+ <el-button :type="isSolidFood?'primary':''" @click="typeChange(1)" v-if="type == '新增'">以容重定价</el-button>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
<div class="row1">
|
|
@@ -110,7 +110,7 @@
|
|
|
<div class="right">
|
|
|
<div class="line"></div>
|
|
|
<div class="jt-style"></div>
|
|
|
- <div v-for="(item1, index) in item.detailList">
|
|
|
+ <div v-for="(item1, index) in item.detailList" :key="index">
|
|
|
<div class="item-style">
|
|
|
<div v-if="item1.type != 4" class="item-style-title">
|
|
|
<span>{{ item1.name }}{{ item1.index }}</span>
|
|
@@ -345,6 +345,9 @@ export default {
|
|
|
},
|
|
|
|
|
|
activated() {
|
|
|
+ debugger
|
|
|
+
|
|
|
+ console.log(this.$route.query.type)
|
|
|
// 货名
|
|
|
let _goodsNameList = []
|
|
|
_goodsNameList = this.$route.query.goodsNameList
|
|
@@ -372,21 +375,20 @@ export default {
|
|
|
if (_goodsNameList.length == 0) {
|
|
|
this.goodnameList = response
|
|
|
this.selectVal = response[0].constValue
|
|
|
- if (this.selectVal == '玉米淀粉' ||
|
|
|
- this.selectVal == '玉米(机收)' ||
|
|
|
- this.selectVal == '玉米(酒精)' ||
|
|
|
- this.selectVal == '玉米(筛漏)' ||
|
|
|
- this.selectVal == '玉米(陈粮)' ||
|
|
|
- this.selectVal == '玉米(棒)' ||
|
|
|
- this.selectVal == '玉米'
|
|
|
- ) {
|
|
|
- this.isSolidFood = true
|
|
|
- this.baseInfoForm.bulkDensityStandard = 1
|
|
|
- } else {
|
|
|
- this.isSolidFood = false
|
|
|
- this.baseInfoForm.bulkDensityStandard = ''
|
|
|
- }
|
|
|
-
|
|
|
+ // if (this.selectVal == '玉米淀粉' ||
|
|
|
+ // this.selectVal == '玉米(机收)' ||
|
|
|
+ // this.selectVal == '玉米(酒精)' ||
|
|
|
+ // this.selectVal == '玉米(筛漏)' ||
|
|
|
+ // this.selectVal == '玉米(陈粮)' ||
|
|
|
+ // this.selectVal == '玉米(棒)' ||
|
|
|
+ // this.selectVal == '玉米'
|
|
|
+ // ) {
|
|
|
+ // this.isSolidFood = true
|
|
|
+ // this.baseInfoForm.bulkDensityStandard = 1
|
|
|
+ // } else {
|
|
|
+ // this.isSolidFood = false
|
|
|
+ // this.baseInfoForm.bulkDensityStandard = ''
|
|
|
+ // }
|
|
|
// this.isSolidFood = false
|
|
|
// this.baseInfoForm.bulkDensityStandard = ''
|
|
|
this.baseInfoForm.goodsNameKey = response[0].constKey
|
|
@@ -395,24 +397,23 @@ export default {
|
|
|
if (_list.length != 0) {
|
|
|
this.selectVal = _list[0].constValue
|
|
|
this.selectVal = _goodsNameList[0]
|
|
|
- if (this.selectVal == '玉米淀粉' ||
|
|
|
- this.selectVal == '玉米(机收)' ||
|
|
|
- this.selectVal == '玉米(酒精)' ||
|
|
|
- this.selectVal == '玉米(筛漏)' ||
|
|
|
- this.selectVal == '玉米(陈粮)' ||
|
|
|
- this.selectVal == '玉米(棒)' ||
|
|
|
- this.selectVal == '玉米'
|
|
|
- ) {
|
|
|
- this.isSolidFood = true
|
|
|
- this.baseInfoForm.bulkDensityStandard = 1
|
|
|
- } else {
|
|
|
- this.isSolidFood = false
|
|
|
- this.baseInfoForm.bulkDensityStandard = ''
|
|
|
- }
|
|
|
+ // if (this.selectVal == '玉米淀粉' ||
|
|
|
+ // this.selectVal == '玉米(机收)' ||
|
|
|
+ // this.selectVal == '玉米(酒精)' ||
|
|
|
+ // this.selectVal == '玉米(筛漏)' ||
|
|
|
+ // this.selectVal == '玉米(陈粮)' ||
|
|
|
+ // this.selectVal == '玉米(棒)' ||
|
|
|
+ // this.selectVal == '玉米'
|
|
|
+ // ) {
|
|
|
+ // this.isSolidFood = true
|
|
|
+ // this.baseInfoForm.bulkDensityStandard = 1
|
|
|
+ // } else {
|
|
|
+ // this.isSolidFood = false
|
|
|
+ // this.baseInfoForm.bulkDensityStandard = ''
|
|
|
+ // }
|
|
|
this.baseInfoForm.goodsNameKey = _list[0].constKey
|
|
|
-
|
|
|
- this.isSolidFood = false
|
|
|
- this.baseInfoForm.bulkDensityStandard = ''
|
|
|
+ // this.isSolidFood = false
|
|
|
+ // this.baseInfoForm.bulkDensityStandard = ''
|
|
|
}
|
|
|
}
|
|
|
})
|
|
@@ -544,6 +545,13 @@ export default {
|
|
|
//构造查看priceList数据
|
|
|
this.priceList = []
|
|
|
this.makeLookPriceList()
|
|
|
+ if(this.baseInfoForm.bulkDensityStandard == 1){
|
|
|
+ this.isSolidFood = true
|
|
|
+ this.baseInfoForm.bulkDensityStandard = 1
|
|
|
+ }else{
|
|
|
+ this.isSolidFood = false
|
|
|
+ this.baseInfoForm.bulkDensityStandard = ""
|
|
|
+ }
|
|
|
// if (this.selectVal == '玉米淀粉' ||
|
|
|
// this.selectVal == '玉米(机收)' ||
|
|
|
// this.selectVal == '玉米(酒精)' ||
|
|
@@ -584,16 +592,7 @@ export default {
|
|
|
})
|
|
|
},
|
|
|
goodsChange(e) {
|
|
|
- if (e == '玉米淀粉' ||
|
|
|
- e == '玉米(机收)' ||
|
|
|
- e == '玉米(酒精)' ||
|
|
|
- e == '玉米(筛漏)' ||
|
|
|
- e == '玉米(陈粮)' ||
|
|
|
- e == '玉米(棒)' ||
|
|
|
- e == '玉米'
|
|
|
- ) {
|
|
|
- // this.isSolidFood = true //true
|
|
|
- this.baseInfoForm = {
|
|
|
+ this.baseInfoForm = {
|
|
|
//防止填完数据 后切换货名不清空多余数据
|
|
|
warehouseId: '',
|
|
|
warehouseName: '',
|
|
@@ -615,10 +614,20 @@ export default {
|
|
|
detailPrints: [],
|
|
|
paramType: '1',
|
|
|
}
|
|
|
+ if (e == '玉米淀粉' ||
|
|
|
+ e == '玉米(机收)' ||
|
|
|
+ e == '玉米(酒精)' ||
|
|
|
+ e == '玉米(筛漏)' ||
|
|
|
+ e == '玉米(陈粮)' ||
|
|
|
+ e == '玉米(棒)' ||
|
|
|
+ e == '玉米'
|
|
|
+ ) {
|
|
|
this.baseInfoForm.warehouseId = this.$route.query.warehouseId
|
|
|
this.baseInfoForm.warehouseName = this.$route.query.warehouseName
|
|
|
this.baseInfoForm.compId = this.$route.query.compId
|
|
|
this.baseInfoForm.bulkDensityStandard = 1
|
|
|
+ }else{
|
|
|
+ this.baseInfoForm.bulkDensityStandard = ""
|
|
|
}
|
|
|
for (let num = 0; num < this.goodnameList.length; num++) {
|
|
|
if (e == this.goodnameList[num].constValue) {
|