From c1c99506314644355c105de2a525ea3a248fd91f Mon Sep 17 00:00:00 2001
From: jinlin <jinlin>
Date: 星期二, 11 六月 2024 08:56:55 +0800
Subject: [PATCH] 修改
---
web/src/views/modules/basicInfo/ProductModelTree.vue | 40 +++++++++++++++++++++++++++-------------
1 files changed, 27 insertions(+), 13 deletions(-)
diff --git a/web/src/views/modules/basicInfo/ProductModelTree.vue b/web/src/views/modules/basicInfo/ProductModelTree.vue
index 79e571f..a8edb11 100644
--- a/web/src/views/modules/basicInfo/ProductModelTree.vue
+++ b/web/src/views/modules/basicInfo/ProductModelTree.vue
@@ -30,7 +30,12 @@
export default {
name: 'ProductModelTree',
- props: {},
+ props: {
+ showXdy: {
+ type: Boolean,
+ default: true
+ },
+ },
data() {
return {
@@ -41,28 +46,37 @@
label: 'name'
}
}
- },
+ }
+ ,
watch: {
filterText(val) {
this.$refs.tree.filter(val)
}
- },
+ }
+ ,
components: {
AddOrUpdate
- },
+ }
+ ,
mounted() {
this.getProductList()
- },
+ }
+ ,
methods: {
// 鑾峰彇绯荤粺鍒楄〃
async getProductList() {
- let res = await this.$http.get('/basicInfo/XhProductModel/tree')
+ let params = {
+ showXdy:this.showXdy
+ }
+ let res = await this.$http.get('/basicInfo/XhProductModel/tree',{params:params})
this.productList = res.data
- console.log(res.data,'async getProductList()')
- },
+ console.log(res.data, 'async getProductList()')
+ }
+ ,
add() {
- this.$refs.AddOrUpdate.$refs.dialog.init(null,{id: null, type: 'tree'})
- },
+ this.$refs.AddOrUpdate.$refs.dialog.init(null, {id: null, type: 'tree'})
+ }
+ ,
filterNode(value, data) {
if (!value) return true
return data.name.indexOf(value) !== -1
@@ -74,7 +88,7 @@
}
</script>
<style>
-.product-tree-container{
- height: 100%;
-}
+ .product-tree-container {
+ height: 100%;
+ }
</style>
--
Gitblit v1.9.1