Browse Source

fix issue

tags/v1.22.8.2^2
zhoupzh 3 years ago
parent
commit
f5803bc06f
4 changed files with 28 additions and 22 deletions
  1. +2
    -2
      options/locale/locale_en-US.ini
  2. +1
    -1
      templates/repo/datasets/index.tmpl
  3. +23
    -17
      web_src/js/components/dataset/selectDataset.vue
  4. +2
    -2
      web_src/js/features/i18nVue.js

+ 2
- 2
options/locale/locale_en-US.ini View File

@@ -922,9 +922,9 @@ select_category = Select Category
select_task = Select Research Direction/Application Area
dataset_name_tooltips = Please enter letters, numbers, _ and - up to 100 characters.
dataset_no_create = No dataset has been created yet
dataset_explain = Dataset: CloudBrain I provides CPU/GPU resources, Cloudbrain II provides Ascend NPU resources, and the data set used for debugging also needs to be uploaded to the corresponding environment;
dataset_explain = Dataset: CloudBrain I provides CPU/GPU resources, Cloudbrain II provides Ascend NPU resources, and the data set used for debugging also needs to be uploaded to the corresponding environment.
dataset_instructions_for_use = Instructions for use: You can refer to Openi AI Collaboration Platform
dataset_camp_course = Newcomer Training Camp Course;
dataset_camp_course = Newcomer Training Camp Course.
dataset_upload = Upload
dataset_upload_status= Upload Status
dataset_file_name = File Name


+ 1
- 1
templates/repo/datasets/index.tmpl View File

@@ -417,7 +417,7 @@
<div class="bgtask-content">
<div class="bgtask-content-txt">{{.i18n.Tr "dataset.dataset_explain"}}</div>
<div class="bgtask-content-txt">{{.i18n.Tr "dataset.dataset_instructions_for_use"}}<a
href="https://git.openi.org.cn/zeizei/OpenI_Learning">{{.i18n.Tr "dataset.dataset_camp_course"}}</a></div>
href="https://git.openi.org.cn/zeizei/OpenI_Learning">&nbsp;{{.i18n.Tr "dataset.dataset_camp_course"}}</a></div>
</div>
</div>
</div>


+ 23
- 17
web_src/js/components/dataset/selectDataset.vue View File

@@ -11,9 +11,9 @@
v-if="benchmarkNew"
class="label-fix-width"
style="font-weight: normal"
>{{i18n.dataset_label}}</label
>{{ i18n.dataset_label }}</label
>
<label v-else>{{i18n.dataset_label}}</label>
<label v-else>{{ i18n.dataset_label }}</label>
<span
:class="
benchmarkNew === true ? 'dataset-train-span' : 'dataset-debug-span'
@@ -59,7 +59,7 @@
? 'select-dataset-button'
: 'select-dataset-button-color'
"
>{{i18n.dataset_select}}
>{{ i18n.dataset_select }}
</el-button>
<el-dialog
:title="i18n.dataset_select"
@@ -90,7 +90,11 @@
>
<el-tabs v-model="activeName" @tab-click="handleClick">
<!-- 当前项目的数据集 -->
<el-tab-pane :label="i18n.dataset_current_repo" name="first" v-loading="loadingCurrent">
<el-tab-pane
:label="i18n.dataset_current_repo"
name="first"
v-loading="loadingCurrent"
>
<el-row>
<el-tree
:data="currentDatasetList"
@@ -172,13 +176,13 @@
class="zip-loading"
v-if="data.DecompressState === 2"
>
{{i18n.dataset_unziping}}
{{ i18n.dataset_unziping }}
</span>
<span
class="unzip-failed"
v-if="data.DecompressState === 3"
>
{{i18n.dataset_unzip_failed}}
{{ i18n.dataset_unzip_failed }}
</span>
</span>
</span>
@@ -201,7 +205,11 @@
</div>
</el-tab-pane>
<!-- 我上传的数据集 -->
<el-tab-pane :label="i18n.dataset_my_upload" name="second" v-loading="loadingMy">
<el-tab-pane
:label="i18n.dataset_my_upload"
name="second"
v-loading="loadingMy"
>
<el-row>
<el-tree
:data="myDatasetList"
@@ -274,13 +282,13 @@
class="zip-loading"
v-if="data.DecompressState === 2"
>
{{i18n.dataset_unziping}}
{{ i18n.dataset_unziping }}
</span>
<span
class="unzip-failed"
v-if="data.DecompressState === 3"
>
{{i18n.dataset_unzip_failed}}
{{ i18n.dataset_unzip_failed }}
</span>
</span>
</span>
@@ -380,13 +388,13 @@
class="zip-loading"
v-if="data.DecompressState === 2"
>
{{i18n.dataset_unziping}}
{{ i18n.dataset_unziping }}
</span>
<span
class="unzip-failed"
v-if="data.DecompressState === 3"
>
{{i18n.dataset_unzip_failed}}
{{ i18n.dataset_unzip_failed }}
</span>
</span>
</span>
@@ -486,13 +494,13 @@
class="zip-loading"
v-if="data.DecompressState === 2"
>
{{i18n.dataset_unziping}}
{{ i18n.dataset_unziping }}
</span>
<span
class="unzip-failed"
v-if="data.DecompressState === 3"
>
{{i18n.dataset_unzip_failed}}
{{ i18n.dataset_unzip_failed }}
</span>
</span>
</span>
@@ -536,7 +544,7 @@
line-height: 40px;
"
>
{{i18n.dataset_selected}}
{{ i18n.dataset_selected }}
</div>
<div style="flex: 1; margin-top: 1.5rem">
<el-checkbox-group v-model="checkList">
@@ -558,7 +566,7 @@
color: #fff;
border: 1px solid #389e0d;
"
>{{i18n.dataset_ok}}</el-button
>{{ i18n.dataset_ok }}</el-button
>
</div>
</el-col>
@@ -732,7 +740,6 @@ export default {
.then((res) => {
this.loadingCurrent = false;
let data = JSON.parse(res.data.data);
console.log(data);
this.currentDatasetList = this.transformeTreeData(
data,
"currentTree",
@@ -996,7 +1003,6 @@ export default {
location.href.indexOf("train-job") !== -1 ||
location.href.indexOf("inference") !== -1
) {
console.log("this.benchmarkNew");
this.benchmarkNew = true;
}
if (


+ 2
- 2
web_src/js/features/i18nVue.js View File

@@ -148,10 +148,10 @@ export const i18nVue = {
downloads: "Downloads",
not_link_dataset: "No datasets have been linked yet",
no_link_dataset_tips1:
"You can display public datasets on the platform here by clicking the New Linked Dataset button.",
"You can display public datasets on the platform here by clicking the Linked Datasets button.",

dataset_instructions_for_use:
"Instructions for use: You can refer to Openi AI Collaboration Platform ",
"Instructions for use: You can refer to OpenI AI Collaboration Platform ",
dataset_camp_course: " Newcomer Training Camp Course",
dataset_link_success: "Linked dataset succeeded!",
dataset_link_failed: "Linked dataset Failed!",


Loading…
Cancel
Save