|
@@ -28,16 +28,7 @@
|
|
</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 />
|
|
|
|
|
|
+ <productTypeAll placeholder="请选择产品分类" @change="changeProductType" v-model="productType" id="productInfoList-productType"></productTypeAll>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
<a-col :md="6" :sm="24">
|
|
<a-col :md="6" :sm="24">
|
|
@@ -98,16 +89,15 @@
|
|
|
|
|
|
<script>
|
|
<script>
|
|
import { commonMixin } from '@/utils/mixin'
|
|
import { commonMixin } from '@/utils/mixin'
|
|
-import { productBrandQuery } from '@/api/productBrand'
|
|
|
|
-import { productTypeQueryAll } from '@/api/productType'
|
|
|
|
import { queryNewProductPage } from '@/api/product'
|
|
import { queryNewProductPage } from '@/api/product'
|
|
import { STable, VSelect } from '@/components'
|
|
import { STable, VSelect } from '@/components'
|
|
import ProductBrand from '@/views/common/productBrand.js'
|
|
import ProductBrand from '@/views/common/productBrand.js'
|
|
|
|
+import productTypeAll from '@/views/common/productTypeAll.js'
|
|
import rangeDate from '@/views/common/rangeDate.vue'
|
|
import rangeDate from '@/views/common/rangeDate.vue'
|
|
export default {
|
|
export default {
|
|
name: 'NewProductList',
|
|
name: 'NewProductList',
|
|
mixins: [commonMixin],
|
|
mixins: [commonMixin],
|
|
- components: { STable, VSelect, rangeDate, ProductBrand },
|
|
|
|
|
|
+ components: { STable, VSelect, rangeDate, ProductBrand, productTypeAll },
|
|
data () {
|
|
data () {
|
|
return {
|
|
return {
|
|
spinning: false,
|
|
spinning: false,
|
|
@@ -160,8 +150,6 @@ export default {
|
|
},
|
|
},
|
|
openModal: false, // 查看详情 弹框
|
|
openModal: false, // 查看详情 弹框
|
|
itemId: '', // 当前产品productSn
|
|
itemId: '', // 当前产品productSn
|
|
- productBrandList: [], // 品牌下拉数据
|
|
|
|
- productTypeList: [] // 分类下拉数据
|
|
|
|
}
|
|
}
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
@@ -197,33 +185,11 @@ export default {
|
|
this.queryParam.productTypeSn2 = val[1] ? val[1] : ''
|
|
this.queryParam.productTypeSn2 = val[1] ? val[1] : ''
|
|
this.queryParam.productTypeSn3 = val[2] ? val[2] : ''
|
|
this.queryParam.productTypeSn3 = val[2] ? val[2] : ''
|
|
},
|
|
},
|
|
- // 产品品牌 列表
|
|
|
|
- getProductBrand () {
|
|
|
|
- productBrandQuery({}).then(res => {
|
|
|
|
- if (res.status == 200) {
|
|
|
|
- this.productBrandList = res.data
|
|
|
|
- } else {
|
|
|
|
- this.productBrandList = []
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- // 产品分类 列表
|
|
|
|
- getProductType () {
|
|
|
|
- productTypeQueryAll({}).then(res => {
|
|
|
|
- if (res.status == 200) {
|
|
|
|
- this.productTypeList = res.data
|
|
|
|
- } else {
|
|
|
|
- this.productTypeList = []
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
pageInit () {
|
|
pageInit () {
|
|
const _this = this
|
|
const _this = this
|
|
this.$nextTick(() => { // 页面渲染完成后的回调
|
|
this.$nextTick(() => { // 页面渲染完成后的回调
|
|
_this.setTableH()
|
|
_this.setTableH()
|
|
})
|
|
})
|
|
- this.getProductBrand()
|
|
|
|
- this.getProductType()
|
|
|
|
},
|
|
},
|
|
setTableH () {
|
|
setTableH () {
|
|
const tableSearchH = this.$refs.tableSearch.offsetHeight
|
|
const tableSearchH = this.$refs.tableSearch.offsetHeight
|