|
|
@ -21,8 +21,11 @@ |
|
|
|
<el-input v-model="formobj.contractNumber" placeholder="" class="item_input" clearable /> |
|
|
|
</div> |
|
|
|
<div class="item"> |
|
|
|
<span class="item_text">供货商:</span> |
|
|
|
<el-input v-model="formobj.supplierSid" placeholder="" class="item_input" clearable /> |
|
|
|
<span class="item_text">供货商名称:</span> |
|
|
|
<el-select v-model="formobj.supplierName" filterable placeholder="请选择供货商名称" class="item_input" |
|
|
|
@change="getSupplier"> |
|
|
|
<el-option v-for="item in supplierList" :key="item.sid" :label="item.name" :value="item.sid" /> |
|
|
|
</el-select> |
|
|
|
</div> |
|
|
|
<div class="item"> |
|
|
|
<span class="item_text">合同日期:</span> |
|
|
@ -85,7 +88,7 @@ |
|
|
|
|
|
|
|
<script> |
|
|
|
import req from '@/api/oilTypeInAndOutBound/oilTypeInAndOutBound' |
|
|
|
import req2 from '@/api/oilTank/oilTank' |
|
|
|
import req3 from '@/api/supplier/supplier' |
|
|
|
import upload from '@/components/uploadFile/upload_yanchejianchaTuBiao' |
|
|
|
export default { |
|
|
|
components: { |
|
|
@ -94,6 +97,8 @@ |
|
|
|
data() { |
|
|
|
return { |
|
|
|
submitdisabled: false, |
|
|
|
supplierLists: [], |
|
|
|
supplierList: [], |
|
|
|
crudeLists: [], |
|
|
|
crudeList: [], |
|
|
|
tankLists: [], |
|
|
@ -112,17 +117,37 @@ |
|
|
|
weight: "", |
|
|
|
value: "", |
|
|
|
supplierSid: "", |
|
|
|
supplierName: "", |
|
|
|
licensePlateNumber: "", |
|
|
|
remarks: "", |
|
|
|
crudeOilStorageFile:[], |
|
|
|
crudeOilStorageFile: [], |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
created() { |
|
|
|
this.supplierInfoList() |
|
|
|
this.crudeinfoList() |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
supplierInfoList() { |
|
|
|
req3.supplierList().then((res) => { |
|
|
|
if (res.success) { |
|
|
|
console.log(">>>>>>>>>2222222", res.data) |
|
|
|
this.supplierLists = res.data |
|
|
|
for (var i = 0; i < this.supplierLists.length; i++) { |
|
|
|
|
|
|
|
let item = { |
|
|
|
name: this.supplierLists[i].supplierName, |
|
|
|
sid: this.supplierLists[i].sid, |
|
|
|
|
|
|
|
} |
|
|
|
this.supplierList.push(item) |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
crudeinfoList() { |
|
|
|
req.crudeinfoList().then((res) => { |
|
|
|
if (res.success) { |
|
|
@ -146,7 +171,7 @@ |
|
|
|
if (res.success) { |
|
|
|
console.log(">>>>>>>>>111111111111wwwwwwwwww", res.data) |
|
|
|
this.tankLists = res.data |
|
|
|
this.tankList =[] |
|
|
|
this.tankList = [] |
|
|
|
for (var i = 0; i < this.tankLists.length; i++) { |
|
|
|
|
|
|
|
let item = { |
|
|
@ -184,7 +209,7 @@ |
|
|
|
supplierSid: "", |
|
|
|
licensePlateNumber: "", |
|
|
|
remarks: "", |
|
|
|
crudeOilStorageFile:[], |
|
|
|
crudeOilStorageFile: [], |
|
|
|
|
|
|
|
} |
|
|
|
this.imgList = [] |
|
|
@ -199,6 +224,13 @@ |
|
|
|
this.$store.dispatch('tagsView/delView', this.$route) |
|
|
|
this.$router.go(-1) |
|
|
|
}, |
|
|
|
getSupplier(value) { |
|
|
|
console.log(">>>>>>>>>getType", value) |
|
|
|
const choose = this.supplierLists.filter((item) => item.sid === value) |
|
|
|
console.log(">>>>>>>>>getType", choose[0]) |
|
|
|
this.formobj.supplierName = choose[0].supplierName |
|
|
|
this.formobj.supplierSid = value |
|
|
|
}, |
|
|
|
getType(value) { |
|
|
|
console.log(">>>>>>>>>getType", value) |
|
|
|
const choose = this.crudeLists.filter((item) => item.sid === value) |
|
|
|