|
|
@@ -13,7 +13,7 @@
|
|
|
<!--</th>-->
|
|
|
<th width="615">产品信息</th>
|
|
|
<th width="95">采购数量(PCS)</th>
|
|
|
- <th width="114">生产日期</th>
|
|
|
+ <!--<th width="114">生产日期</th>-->
|
|
|
<th width="136"><i class="red-text">*</i>截止时间</th>
|
|
|
<th width="186">操作</th>
|
|
|
</tr>
|
|
|
@@ -41,11 +41,11 @@
|
|
|
<li v-for="code in item.codeWord" @click="modifyItemByWord(index, code.code, 'code')" :title="code.code">{{code.code}}</li>
|
|
|
</ul>
|
|
|
</div>
|
|
|
- <div class="prod-item prod-item-small">
|
|
|
+ <!--<div class="prod-item prod-item-small">
|
|
|
<span class="pi-title">单价预算:</span>
|
|
|
<div class="pi-content over-ell" v-if="item.unitPrice">{{(item.currency === 'RMB' ? '¥' : '$') + item.unitPrice}}</div>
|
|
|
<div class="pi-content over-ell" v-else="!item.unitPrice">-</div>
|
|
|
- </div>
|
|
|
+ </div>-->
|
|
|
<div class="prod-item prod-item-large" :title="item.brand">
|
|
|
<span class="pi-title"><i class="red-text">*</i>品牌:</span>
|
|
|
<div class="pi-content over-ell" v-if="item.brand && (!item.brandWord || item.brandWord.length == 0)" :title="item.brand">{{item.brand}}</div>
|
|
|
@@ -59,22 +59,22 @@
|
|
|
<span class="pi-title">规格:</span>
|
|
|
<div class="pi-content over-ell">{{item.spec || '-'}}</div>
|
|
|
</div>
|
|
|
- <div class="prod-item prod-item-small" :title="item.encapsulation">
|
|
|
+ <!--<div class="prod-item prod-item-small" :title="item.encapsulation">
|
|
|
<span class="pi-title">封装:</span>
|
|
|
<div class="pi-content over-ell">
|
|
|
{{item.encapsulation || '-'}}
|
|
|
</div>
|
|
|
- </div>
|
|
|
+ </div>-->
|
|
|
</div>
|
|
|
</td>
|
|
|
<td>
|
|
|
<div class="over-ell" :title="item.amount">{{item.amount || '-'}}</div>
|
|
|
</td>
|
|
|
- <td>
|
|
|
+ <!--<td>
|
|
|
<div class="over-ell" :title="item.produceDate">
|
|
|
{{item.produceDate || '-'}}
|
|
|
</div>
|
|
|
- </td>
|
|
|
+ </td>-->
|
|
|
<td>
|
|
|
<span v-if="item.deadline">{{item.deadline | date}}</span>
|
|
|
<span class="red-text" v-if="!item.deadline">请完善信息</span>
|
|
|
@@ -88,7 +88,7 @@
|
|
|
</td>
|
|
|
</tr>
|
|
|
<tr class="spot-goods" v-if="item.showSpotGoods">
|
|
|
- <td colspan="8">
|
|
|
+ <td colspan="4">
|
|
|
<div class="spot-goods-body">
|
|
|
<div class="spot-goods-title">商城现货({{spotGoodsData.length || 0}})</div>
|
|
|
<table>
|
|
|
@@ -151,14 +151,14 @@
|
|
|
<li v-for="sCode in similarCode" @click="setCode(sCode.code)">{{sCode.code}}</li>
|
|
|
</ul>
|
|
|
</div>
|
|
|
- <div class="prod-item prod-item-small pi-select">
|
|
|
+ <!--<div class="prod-item prod-item-small pi-select">
|
|
|
<span class="pi-title">单价预算:</span>
|
|
|
<select class="form-control" v-model="modifyObj.currency">
|
|
|
<option value="RMB">¥</option>
|
|
|
<option value="USD">$</option>
|
|
|
</select>
|
|
|
<input class="form-control" type="number" v-model="modifyObj.unitPrice" :class="{'error': !validObj.unitPrice}" @blur="checkUnitPrice" @input="onUnitPriceInput">
|
|
|
- </div>
|
|
|
+ </div>-->
|
|
|
<div class="prod-item prod-item-large">
|
|
|
<span class="pi-title"><i class="red-text">*</i>品牌:</span>
|
|
|
<input type="text" class="form-control" v-model="modifyObj.brand" :class="{'error': !validObj.brand}" @blur="checkBrand" @input="onBrandChange">
|
|
|
@@ -170,18 +170,18 @@
|
|
|
<span class="pi-title">规格:</span>
|
|
|
<input type="text" class="form-control" v-model="modifyObj.spec" :class="{'error': !validObj.spec}" @input="onSpecInput" @blur="checkSpec">
|
|
|
</div>
|
|
|
- <div class="prod-item prod-item-small">
|
|
|
+ <!--<div class="prod-item prod-item-small">
|
|
|
<span class="pi-title">封装:</span>
|
|
|
<input type="text" class="form-control" v-model="modifyObj.encapsulation" @input="onEncapsulationChange">
|
|
|
- </div>
|
|
|
+ </div>-->
|
|
|
</div>
|
|
|
</td>
|
|
|
<td>
|
|
|
<input type="text" class="form-control" v-model="modifyObj.amount" :class="{'error': !validObj.amount}" @blur="checkAmount" @input="onAmountInput">
|
|
|
</td>
|
|
|
- <td>
|
|
|
+ <!--<td>
|
|
|
<input type="text" class="form-control" v-model="modifyObj.produceDate" @input="onProduceDateChange">
|
|
|
- </td>
|
|
|
+ </td>-->
|
|
|
<td>
|
|
|
<el-date-picker
|
|
|
v-model="modifyObj.deadline"
|
|
|
@@ -254,30 +254,51 @@
|
|
|
showSimilarCodeList: false,
|
|
|
showSimilarBrandList: false,
|
|
|
spotGoodsData: [],
|
|
|
- fragments: []
|
|
|
+ fragments: [],
|
|
|
+ bomList: {}
|
|
|
}
|
|
|
},
|
|
|
components: {
|
|
|
Page
|
|
|
},
|
|
|
+ watch: {
|
|
|
+ '$store.state.applyPurchase.bomMaterial.bomList.data': {
|
|
|
+ handler: function (val) {
|
|
|
+ let _this = this
|
|
|
+ let list = JSON.parse(JSON.stringify(val))
|
|
|
+ list.content = list.content.slice()
|
|
|
+ for (let i = 0; i < list.content.length; i++) {
|
|
|
+ _this.$set(list.content[i], 'checked', false)
|
|
|
+ _this.$set(list.content[i], 'active', false)
|
|
|
+ _this.$set(list.content[i], 'showCodeWord', false)
|
|
|
+ _this.$set(list.content[i], 'showBrandWord', false)
|
|
|
+ _this.$set(list.content[i], 'showSpotGoods', false)
|
|
|
+ }
|
|
|
+ this.bomList = list
|
|
|
+ },
|
|
|
+ immediate: true
|
|
|
+ }
|
|
|
+ },
|
|
|
computed: {
|
|
|
- bomList () {
|
|
|
- let _this = this
|
|
|
- let list = this.$store.state.applyPurchase.bomMaterial.bomList.data
|
|
|
- for (let i = 0; i < list.content.length; i++) {
|
|
|
- _this.$set(list.content[i], 'checked', false)
|
|
|
- _this.$set(list.content[i], 'active', false)
|
|
|
- _this.$set(list.content[i], 'showCodeWord', false)
|
|
|
- _this.$set(list.content[i], 'showBrandWord', false)
|
|
|
- _this.$set(list.content[i], 'showSpotGoods', false)
|
|
|
-// list.content[i].checked = false
|
|
|
-// list.content[i].active = false
|
|
|
-// if (!list.content[i].code || list.content[i].brand || !list.content[i].deadline || !this.isValidDate(list.content[i].deadline)) {
|
|
|
-// _this.validList = false
|
|
|
-// }
|
|
|
- }
|
|
|
- return list
|
|
|
- },
|
|
|
+// bomList () {
|
|
|
+// let _this = this
|
|
|
+// let list = JSON.parse(JSON.stringify(this.$store.state.applyPurchase.bomMaterial.bomList.data))
|
|
|
+// list.content = list.content.slice()
|
|
|
+// for (let i = 0; i < list.content.length; i++) {
|
|
|
+// _this.$set(list.content[i], 'checked', false)
|
|
|
+// _this.$set(list.content[i], 'active', false)
|
|
|
+// _this.$set(list.content[i], 'showCodeWord', false)
|
|
|
+// _this.$set(list.content[i], 'showBrandWord', false)
|
|
|
+// _this.$set(list.content[i], 'showSpotGoods', false)
|
|
|
+// // list.content[i].checked = false
|
|
|
+// // list.content[i].active = false
|
|
|
+// // if (!list.content[i].code || list.content[i].brand || !list.content[i].deadline || !this.isValidDate(list.content[i].deadline)) {
|
|
|
+// // _this.validList = false
|
|
|
+// // }
|
|
|
+// }
|
|
|
+// console.log(list)
|
|
|
+// return list
|
|
|
+// },
|
|
|
bomNumber () {
|
|
|
return this.$store.state.applyPurchase.bomMaterial.bomNumber.data
|
|
|
},
|
|
|
@@ -1090,10 +1111,10 @@
|
|
|
line-height: 30px;
|
|
|
float: left;
|
|
|
margin-right: 5px;
|
|
|
- &:nth-child(n + 4) {
|
|
|
+ &:nth-child(n + 3) {
|
|
|
margin-top: 9px;
|
|
|
}
|
|
|
- &:nth-child(3n) {
|
|
|
+ &:nth-child(2n) {
|
|
|
margin-right: 0;
|
|
|
}
|
|
|
.pi-title {
|
|
|
@@ -1111,7 +1132,7 @@
|
|
|
}
|
|
|
&.prod-item-large {
|
|
|
.pi-content {
|
|
|
- width: 145px;
|
|
|
+ width: 226px;
|
|
|
}
|
|
|
.pi-title {
|
|
|
width: 62px;
|
|
|
@@ -1137,7 +1158,7 @@
|
|
|
overflow-y: auto;
|
|
|
overflow-x: hidden;
|
|
|
border-radius: 2px;
|
|
|
- width: 145px;
|
|
|
+ width: 228px;
|
|
|
li {
|
|
|
height: 30px;
|
|
|
line-height: 30px;
|
|
|
@@ -1165,7 +1186,7 @@
|
|
|
padding: 0 22px 0 5px;
|
|
|
background: url('/images/all/select-icon-full.png') no-repeat;
|
|
|
background-color: #fff;
|
|
|
- background-position: 125px 10px;
|
|
|
+ background-position: 194px 10px;
|
|
|
cursor: default;
|
|
|
border-radius: 2px;
|
|
|
& + ul {
|
|
|
@@ -1330,7 +1351,7 @@
|
|
|
position: relative;
|
|
|
&.prod-item-large {
|
|
|
input {
|
|
|
- width: 145px;
|
|
|
+ width: 226px;
|
|
|
}
|
|
|
}
|
|
|
&.prod-item-small {
|