Commit 65932e87 authored by zhanglw's avatar zhanglw

路由调整

parent 8aaabe1d
...@@ -189,8 +189,18 @@ export default { ...@@ -189,8 +189,18 @@ export default {
methods: { methods: {
onDictReady(dict) { onDictReady(dict) {
this.areaOpts = [{ value: '', label: '全部' }, ...dict.area_province] this.areaOpts = [{ value: '', label: '全部' }, ...dict.area_province]
if (this.$route.query.areaText) {
this.query.area = this.areaOpts.filter(item => {
return item.label === this.$route.query.areaText
})[0].value
}
this.title = dict.product_type[this.query.productType - 1].label this.title = dict.product_type[this.query.productType - 1].label
this.subTypeOpts = [{ value: '', label: '全部' }, ...dict['product_type_' + this.query.productType]] this.subTypeOpts = [{ value: '', label: '全部' }, ...dict['product_type_' + this.query.productType]]
if (this.$route.query.subProductType) {
this.query.area = this.subTypeOpts.filter(item => {
return item.label === this.$route.query.subProductType
})[0].value
}
this.search() this.search()
}, },
search() { search() {
......
...@@ -247,6 +247,11 @@ export default { ...@@ -247,6 +247,11 @@ export default {
methods: { methods: {
onDictReady(dict) { onDictReady(dict) {
this.areaOpts = [{ value: '', label: '全部' }, ...dict.area_province] this.areaOpts = [{ value: '', label: '全部' }, ...dict.area_province]
if (this.$route.query.areaText) {
this.query.area = this.areaOpts.filter(item => {
return item.label === this.$route.query.areaText
})[0].value
}
this.search() this.search()
}, },
search() { search() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment