|
@@ -24,7 +24,7 @@
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="供应商名称">
|
|
|
- <supplier v-model="queryParam.supplierSn" placeholder="请输入供应商名称"></supplier>
|
|
|
+ <supplier v-model="queryParam.supplier.supplierSn" @change="getSupplierName" placeholder="请输入供应商名称"></supplier>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<template v-if="advanced">
|
|
@@ -40,22 +40,22 @@
|
|
|
</a-col>
|
|
|
<a-col :md="5" :sm="24">
|
|
|
<a-form-model-item label="产品编码">
|
|
|
- <a-input id="urchaseDetailReturn-productCode" v-model.trim="queryParam.productCode" allowClear placeholder="请输入产品编码"/>
|
|
|
+ <a-input id="urchaseDetailReturn-productCode" v-model.trim="queryParam.product.code" allowClear placeholder="请输入产品编码"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="产品名称">
|
|
|
- <a-input id="urchaseDetailReturn-productName" v-model.trim="queryParam.productName" allowClear placeholder="请输入产品名称"/>
|
|
|
+ <a-input id="urchaseDetailReturn-productName" v-model.trim="queryParam.product.name" allowClear placeholder="请输入产品名称"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="产品品牌">
|
|
|
- <ProductBrand id="urchaseDetailReturn-productBrandSn" v-model="queryParam.productBrandSn"></ProductBrand>
|
|
|
+ <ProductBrand id="urchaseDetailReturn-productBrandSn" v-model="queryParam.product.productBrandSn"></ProductBrand>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="品牌分类">
|
|
|
- <v-select code="BRAND_TYPE" id="urchaseDetailReturn-productBrandTypeSn" v-model="queryParam.productBrandTypeSn" allowClear placeholder="请选择品牌分类"></v-select>
|
|
|
+ <v-select code="BRAND_TYPE" id="urchaseDetailReturn-productBrandTypeSn" v-model="queryParam.product.brandType" allowClear placeholder="请选择品牌分类"></v-select>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<!-- <a-col :md="6" :sm="24">
|
|
@@ -81,22 +81,22 @@
|
|
|
<a-row>
|
|
|
<a-form-model-item label="地区">
|
|
|
<a-col span="7">
|
|
|
- <a-form-model-item prop="dealerProvinceSn" style="margin: 0;">
|
|
|
- <a-select v-model="queryParam.dealerProvinceSn" allowClear @change="getCityList" placeholder="请选择省">
|
|
|
+ <a-form-model-item prop="provinceSn" style="margin: 0;">
|
|
|
+ <a-select v-model="queryParam.supplier.provinceSn" allowClear @change="getCityList" placeholder="请选择省">
|
|
|
<a-select-option v-for="item in addrProvinceList" :value="item.id" :key="item.id + 'a'">{{ item.name }}</a-select-option>
|
|
|
</a-select>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<a-col span="7" offset="1">
|
|
|
- <a-form-model-item prop="dealerCitySn" style="margin: 0;">
|
|
|
- <a-select v-model="queryParam.dealerCitySn" allowClear @change="getAreaList" placeholder="请选择市">
|
|
|
+ <a-form-model-item prop="citySn" style="margin: 0;">
|
|
|
+ <a-select v-model="queryParam.supplier.citySn" allowClear @change="getAreaList" placeholder="请选择市">
|
|
|
<a-select-option v-for="item in addrCityList" :value="item.id" :key="item.id + 'b'">{{ item.name }}</a-select-option>
|
|
|
</a-select>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<a-col span="7" offset="1">
|
|
|
- <a-form-model-item prop="dealerCountySn" style="margin: 0;">
|
|
|
- <a-select v-model="queryParam.dealerCountySn" allowClear placeholder="请选择区/县">
|
|
|
+ <a-form-model-item prop="districtSn" style="margin: 0;">
|
|
|
+ <a-select v-model="queryParam.supplier.districtSn" allowClear placeholder="请选择区/县">
|
|
|
<a-select-option v-for="item in addrDistrictList" :value="item.id" :key="item.id + 'c'">{{ item.name }}</a-select-option>
|
|
|
</a-select>
|
|
|
</a-form-model-item>
|
|
@@ -229,18 +229,20 @@ export default {
|
|
|
beginDate: getDate.getCurrMonthDays().starttime,
|
|
|
endDate: getDate.getCurrMonthDays().endtime,
|
|
|
sparePartsReturnNo: '', // 采购退货单号
|
|
|
- supplierSn: '', // 供应商sn
|
|
|
returnReason: '',
|
|
|
- productCode: '',
|
|
|
- productName: '',
|
|
|
- productBrandTypeSn: undefined,
|
|
|
- productBrandSn: undefined, // 产品品牌
|
|
|
- // productTypeSn1: '', // 产品一级分类
|
|
|
- // productTypeSn2: '', // 产品二级分类
|
|
|
- // productTypeSn3: '', // 产品三级分类
|
|
|
- dealerProvinceSn: undefined,
|
|
|
- dealerCitySn: undefined,
|
|
|
- dealerCountySn: undefined
|
|
|
+ product: {
|
|
|
+ name: '',
|
|
|
+ code: '',
|
|
|
+ brandType: undefined,
|
|
|
+ productBrandSn: undefined
|
|
|
+ },
|
|
|
+ supplier: {
|
|
|
+ supplierSn: '',
|
|
|
+ supplierName: '',
|
|
|
+ provinceSn: undefined,
|
|
|
+ citySn: undefined,
|
|
|
+ districtSn: undefined
|
|
|
+ }
|
|
|
},
|
|
|
// productType: [],
|
|
|
rules: {
|
|
@@ -316,6 +318,10 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
+ getSupplierName (val, item) {
|
|
|
+ this.queryParam.supplier.supplierName = item.supplierName
|
|
|
+ this.queryParam.supplier.supplierSn = val
|
|
|
+ },
|
|
|
handleSearch () {
|
|
|
const _this = this
|
|
|
this.$refs.ruleForm.validate(valid => {
|
|
@@ -346,19 +352,16 @@ export default {
|
|
|
this.queryParam.beginDate = getDate.getCurrMonthDays().starttime
|
|
|
this.queryParam.endDate = getDate.getCurrMonthDays().endtime
|
|
|
this.queryParam.sparePartsReturnNo = ''
|
|
|
- this.queryParam.productCode = ''
|
|
|
- this.queryParam.productName = ''
|
|
|
- this.queryParam.supplierSn = ''
|
|
|
+ this.queryParam.product.code = ''
|
|
|
+ this.queryParam.product.name = ''
|
|
|
+ this.queryParam.supplier.supplierSn = ''
|
|
|
+ this.queryParam.supplier.supplierName = ''
|
|
|
this.queryParam.returnReason = undefined
|
|
|
- this.queryParam.productBrandTypeSn = undefined
|
|
|
- this.queryParam.productBrandSn = undefined
|
|
|
- // this.queryParam.productTypeSn1 = ''
|
|
|
- // this.queryParam.productTypeSn2 = ''
|
|
|
- // this.queryParam.productTypeSn3 = ''
|
|
|
- this.queryParam.dealerProvinceSn = undefined
|
|
|
- this.queryParam.dealerCitySn = undefined
|
|
|
- this.queryParam.dealerCountySn = undefined
|
|
|
- // this.productType = []
|
|
|
+ this.queryParam.product.productBrandTypeSn = undefined
|
|
|
+ this.queryParam.product.productBrandSn = undefined
|
|
|
+ this.queryParam.supplier.provinceSn = undefined
|
|
|
+ this.queryParam.supplier.citySn = undefined
|
|
|
+ this.queryParam.supplier.districtSn = undefined
|
|
|
this.totalData = null
|
|
|
this.$refs.ruleForm.resetFields()
|
|
|
this.$refs.table.clearTable()
|
|
@@ -382,12 +385,6 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
- // 产品分类 change
|
|
|
- changeProductType (val, opt) {
|
|
|
- this.queryParam.productTypeSn1 = val[0] ? val[0] : ''
|
|
|
- this.queryParam.productTypeSn2 = val[1] ? val[1] : ''
|
|
|
- this.queryParam.productTypeSn3 = val[2] ? val[2] : ''
|
|
|
- },
|
|
|
// 产品品牌 列表
|
|
|
getProductBrand () {
|
|
|
productBrandQuery({}).then(res => {
|