|
@@ -48,30 +48,12 @@
|
|
</a-col>
|
|
</a-col>
|
|
<a-col :md="6" :sm="24">
|
|
<a-col :md="6" :sm="24">
|
|
<a-form-item label="产品品牌">
|
|
<a-form-item label="产品品牌">
|
|
- <a-select
|
|
|
|
- placeholder="请选择产品品牌"
|
|
|
|
- id="bulkWarehousingOrderEdit-productBrandSn"
|
|
|
|
- allowClear
|
|
|
|
- v-model="queryParam.productBrandSn"
|
|
|
|
- :showSearch="true"
|
|
|
|
- option-filter-prop="children"
|
|
|
|
- :filter-option="filterOption">
|
|
|
|
- <a-select-option v-for="item in productBrandList" :key="item.brandSn" :value="item.brandSn">{{ item.brandName }}</a-select-option>
|
|
|
|
- </a-select>
|
|
|
|
|
|
+ <ProductBrand id="bulkWarehousingOrderEdit-productBrandSn" v-model="queryParam.productBrandSn"></ProductBrand>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
<a-col :md="6" :sm="24">
|
|
<a-col :md="6" :sm="24">
|
|
<a-form-item label="产品分类">
|
|
<a-form-item label="产品分类">
|
|
- <a-cascader
|
|
|
|
- @change="changeProductType"
|
|
|
|
- change-on-select
|
|
|
|
- v-model="productType"
|
|
|
|
- expand-trigger="hover"
|
|
|
|
- :options="productTypeList"
|
|
|
|
- :fieldNames="{ label: 'productTypeName', value: 'productTypeSn', children: 'children' }"
|
|
|
|
- id="productInfoList-productType"
|
|
|
|
- placeholder="请选择产品分类"
|
|
|
|
- allowClear />
|
|
|
|
|
|
+ <ProductType id="productInfoList-productType" @change="changeProductType" v-model="productType"></ProductType>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
<a-col :md="6" :sm="24" style="margin-bottom: 10px;">
|
|
<a-col :md="6" :sm="24" style="margin-bottom: 10px;">
|
|
@@ -237,15 +219,15 @@
|
|
import { STable, VSelect } from '@/components'
|
|
import { STable, VSelect } from '@/components'
|
|
import basicInfoModal from './basicInfoModal.vue'
|
|
import basicInfoModal from './basicInfoModal.vue'
|
|
import { getOperationalPrecision } from '@/libs/tools.js'
|
|
import { getOperationalPrecision } from '@/libs/tools.js'
|
|
-import { dealerProductBrandQuery } from '@/api/dealerProductBrand'
|
|
|
|
-import { dealerProductTypeList } from '@/api/dealerProductType'
|
|
|
|
import { sparePartsPurDetail, sparePartsPurDetailList, sparePartsPurDetailCount, sparePartsPurDetailSave, sparePartsPurDetailDel, sparePartsPurSubmit, sparePartsPurDetailPrint } from '@/api/sparePartsPur'
|
|
import { sparePartsPurDetail, sparePartsPurDetailList, sparePartsPurDetailCount, sparePartsPurDetailSave, sparePartsPurDetailDel, sparePartsPurSubmit, sparePartsPurDetailPrint } from '@/api/sparePartsPur'
|
|
-import { dealerProductList } from '@/api/dealerProduct'
|
|
|
|
|
|
+import { bulkProductList } from '@/api/dealerProduct'
|
|
import { warehouseCascadeList } from '@/api/warehouse'
|
|
import { warehouseCascadeList } from '@/api/warehouse'
|
|
|
|
+import ProductType from '../../common/productType.js'
|
|
|
|
+import ProductBrand from '../../common/productBrand.js'
|
|
import Print from '@/views/common/print.vue'
|
|
import Print from '@/views/common/print.vue'
|
|
import { hdPrint } from '@/libs/JGPrint'
|
|
import { hdPrint } from '@/libs/JGPrint'
|
|
export default {
|
|
export default {
|
|
- components: { STable, VSelect, basicInfoModal, Print },
|
|
|
|
|
|
+ components: { STable, VSelect, basicInfoModal, Print, ProductType, ProductBrand },
|
|
data () {
|
|
data () {
|
|
return {
|
|
return {
|
|
spinning: false,
|
|
spinning: false,
|
|
@@ -258,8 +240,6 @@ export default {
|
|
productTypeSn2: undefined,
|
|
productTypeSn2: undefined,
|
|
productTypeSn3: undefined
|
|
productTypeSn3: undefined
|
|
},
|
|
},
|
|
- productBrandList: [], // 产品品牌 下拉数据
|
|
|
|
- productTypeList: [], // 产品分类 下拉数据
|
|
|
|
productType: [],
|
|
productType: [],
|
|
warehouseCascadeData: [], // 仓库仓位
|
|
warehouseCascadeData: [], // 仓库仓位
|
|
disabled: false, // 查询、重置按钮是否可操作
|
|
disabled: false, // 查询、重置按钮是否可操作
|
|
@@ -280,13 +260,14 @@ export default {
|
|
loadData: parameter => {
|
|
loadData: parameter => {
|
|
this.disabled = true
|
|
this.disabled = true
|
|
parameter.sortAlias = 'dp'
|
|
parameter.sortAlias = 'dp'
|
|
- const params = Object.assign(parameter, this.queryParam)
|
|
|
|
|
|
+ const params = Object.assign(parameter, this.queryParam, { supplierSn: this.$route.params.supplierSn })
|
|
params.enabledFlag = 1
|
|
params.enabledFlag = 1
|
|
- return dealerProductList(params).then(res => {
|
|
|
|
|
|
+ return bulkProductList(params).then(res => {
|
|
const data = res.data
|
|
const data = res.data
|
|
const no = (data.pageNo - 1) * data.pageSize
|
|
const no = (data.pageNo - 1) * data.pageSize
|
|
for (var i = 0; i < data.list.length; i++) {
|
|
for (var i = 0; i < data.list.length; i++) {
|
|
data.list[i].no = no + i + 1
|
|
data.list[i].no = no + i + 1
|
|
|
|
+ data.list[i].putCost = data.list[i].purchasePrice || ''
|
|
if (this.defaultWarehouseCascade.length > 0) {
|
|
if (this.defaultWarehouseCascade.length > 0) {
|
|
data.list[i].warehouseCascade = this.defaultWarehouseCascade
|
|
data.list[i].warehouseCascade = this.defaultWarehouseCascade
|
|
data.list[i].warehouseSn = this.defaultWarehouseCascade[0]
|
|
data.list[i].warehouseSn = this.defaultWarehouseCascade[0]
|
|
@@ -599,37 +580,9 @@ export default {
|
|
}
|
|
}
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- // 产品品牌 列表
|
|
|
|
- getProductBrand () {
|
|
|
|
- // sysFlag传0,表示只查自建产品
|
|
|
|
- dealerProductBrandQuery({}).then(res => {
|
|
|
|
- if (res.status == 200) {
|
|
|
|
- this.productBrandList = res.data
|
|
|
|
- } else {
|
|
|
|
- this.productBrandList = []
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- // 产品分类 列表
|
|
|
|
- getProductType () {
|
|
|
|
- dealerProductTypeList({}).then(res => {
|
|
|
|
- if (res.status == 200) {
|
|
|
|
- this.productTypeList = res.data
|
|
|
|
- } else {
|
|
|
|
- this.productTypeList = []
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- filterOption (input, option) {
|
|
|
|
- return (
|
|
|
|
- option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
|
|
|
|
- )
|
|
|
|
- },
|
|
|
|
initPage () {
|
|
initPage () {
|
|
this.getWarehouseCascade()
|
|
this.getWarehouseCascade()
|
|
this.getDetail()
|
|
this.getDetail()
|
|
- this.getProductBrand()
|
|
|
|
- this.getProductType()
|
|
|
|
this.resetSearchForm()
|
|
this.resetSearchForm()
|
|
this.$refs.chooseTable.refresh(true)
|
|
this.$refs.chooseTable.refresh(true)
|
|
this.openModal = false
|
|
this.openModal = false
|