Browse Source

fix issue

tags/v1.22.4.1^2
zhoupzh 3 years ago
parent
commit
7039f26892
4 changed files with 44 additions and 7 deletions
  1. +2
    -2
      templates/custom/select_dataset.tmpl
  2. +2
    -2
      templates/custom/select_dataset_train.tmpl
  3. +17
    -3
      web_src/js/components/images/selectImages.vue
  4. +23
    -0
      web_src/js/index.js

+ 2
- 2
templates/custom/select_dataset.tmpl View File

@@ -15,8 +15,8 @@
width="50%"
>
<div class="ui icon input" style="z-index: 9999;position: absolute;right: 50px;height:30px;">
<i class="search icon" style="cursor: pointer;pointer-events:auto" @click="searchDataset()"></i>
<input type="text" placeholder="{{.i18n.Tr "dataset.search_dataset"}}" v-model="searchDataItem" @keyup.enter="searchDataset()">
<i class="search icon"></i>
<input type="text" placeholder="{{.i18n.Tr "dataset.search_dataset"}}" v-model="searchDataItem">
</div>
<el-tabs v-model="activeName" @tab-click="handleClick('{{.RepoLink}}',activeName,{{.cloudbraintype}})">


+ 2
- 2
templates/custom/select_dataset_train.tmpl View File

@@ -15,8 +15,8 @@
width="50%"
>
<div class="ui icon input" style="z-index: 9999;position: absolute;right: 50px;height:30px;">
<i class="search icon" style="cursor: pointer;pointer-events:auto" @click="searchDataset()"></i>
<input type="text" placeholder="{{.i18n.Tr "dataset.search_dataset"}}" v-model="searchDataItem" @keyup.enter="searchDataset()">
<i class="search icon"></i>
<input type="text" placeholder="{{.i18n.Tr "dataset.search_dataset"}}" v-model="searchDataItem">
</div>
<el-tabs v-model="activeName" @tab-click="handleClick('{{.RepoLink}}',activeName,{{.cloudbraintype}})">


+ 17
- 3
web_src/js/components/images/selectImages.vue View File

@@ -13,8 +13,8 @@
width="50%"
>
<div class="ui icon input" style="z-index: 9999;position: absolute;right: 50px;height:30px;">
<i class="search icon" style="cursor: pointer;pointer-events:auto" @click="searchName()"></i>
<input type="text" placeholder="搜镜像Tag/描述/标签..." v-model="search" @keyup.enter.prevent="searchName()">
<i class="search icon" style="cursor: pointer;pointer-events:auto"></i>
<input type="text" placeholder="搜镜像Tag/描述/标签..." v-model="search">
</div>
<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="公开镜像" name="first" v-loading="loadingPublic">
@@ -278,13 +278,27 @@ export default {
},
selectImages(place){
console.log("================")
this.imageAddress = place
this.dialogVisible = false
},

},
watch:{
search(val){
if(this.activeName=='first'){
this.paramsPublic.q = val
this.getImageListPublic()
}
if(this.activeName=='second'){
this.paramsCustom.q = val
this.getImageListCustom()
}
if(this.activeName=='third'){
this.paramsStar.q = val
this.getImageListStar()
}
}

},
mounted() {
this.getImageListPublic()


+ 23
- 0
web_src/js/index.js View File

@@ -4286,6 +4286,29 @@ function initVueDataset() {
}
}
},
watch:{
searchDataItem(){
switch(this.activeName){
case 'first':
this.page = 1
this.getCurrentRepoDataset(this.repolink,this.cloudbrainType)
break
case 'second':
this.page = 1
this.getMyDataset(this.repolink,this.cloudbrainType)
break
case 'third':
this.page = 1
this.getPublicDataset(this.repolink,this.cloudbrainType)
break
case 'fourth':
this.page = 1
this.getStarDataset(this.repolink,this.cloudbrainType)
break
}
}

},
});

}


Loading…
Cancel
Save