Browse Source

fix issue

tags/v1.22.4.2^2
zhoupzh 3 years ago
parent
commit
389f8e2e23
2 changed files with 1 additions and 13 deletions
  1. +0
    -1
      templates/repo/attachment/upload.tmpl
  2. +1
    -12
      web_src/js/components/MinioUploader.vue

+ 0
- 1
templates/repo/attachment/upload.tmpl View File

@@ -15,7 +15,6 @@
<el-form-item label='{{$.i18n.Tr "dataset.dataset_available_clusters"}}:' prop="title">
<el-button :class="{active:type==0}" :disabled="clusterFlag" size="small" style="margin: 0;border-radius: 0.28571429rem 0 0 0.28571429rem;" @click="uploadGpu">CPU/GPU</el-button>
<el-button :class="{active:type==1}" :disabled="clusterFlag" size="small" style="margin: 0 0 0 -4px;border-radius: 0 0.28571429rem 0.28571429rem 0;" @click="uploadNpu">NPU</el-button>
<!-- <span>请输入字母、数字、_和-,最长64个字符,且不能以中划线(-)结尾。</span> -->
</el-form-item>
<el-form-item label='{{$.i18n.Tr "dataset.file_description"}}:' prop="description">
<el-input type="textarea" :rows="3" maxlength="255" placeholder="{{$.i18n.Tr "repo.modelarts.train_job.new_place"}}" v-model="desc"></el-input>


+ 1
- 12
web_src/js/components/MinioUploader.vue View File

@@ -3,10 +3,6 @@
<div id="dataset" class="dropzone">
<div class="maxfilesize ui red message" style="display: none;margin: 2.5rem;"></div>
</div>
<!-- <p class="upload-info">
{{ file_status_text }}
<strong class="success text red">{{ status }}</strong>
</p> -->
<el-button style="background-color: #21ba45;margin-top: 2rem;" type="success" :disabled="btnFlag" @click="startUpload">{{upload}}</el-button>
<el-button type="info" @click="cancelDataset">{{cancel}}</el-button>
<div style="margin-top: 2rem;position: relative;">
@@ -26,10 +22,6 @@
</div>
</div>
<!-- <p>说明:<br>
- 只有zip格式的数据集才能发起云脑任务;<br>
- 云脑1提供 <span class="text blue">CPU / GPU</span> 资源,云脑2提供 <span class="text blue">Ascend NPU</span> 资源;调试使用的数据集也需要上传到对应的环境。</p> -->
</div>
</template>

@@ -103,7 +95,7 @@ export default {
const dropzoneUploader = await createDropzone($dropzone[0], {
url: '/todouploader',
maxFiles: this.maxFiles,
maxFilesize: 1024*10,
maxFilesize: 1024*200,
filesizeBase:1024,
parallelUploads: this.maxFiles,
timeout: 0,
@@ -238,7 +230,6 @@ export default {
spark = new SparkMD5.ArrayBuffer(),
fileReader = new FileReader();
let currentChunk = 0;
console.log("computeMD5-chunks:",chunks)
const time = new Date().getTime();
this.status = this.dropzoneParams.data('md5-computing');
file.totalChunkCounts = chunks;
@@ -326,8 +317,6 @@ export default {
//不同数据集上传同一个文件
if (file.datasetID != '') {
if (file.datasetName != "" && file.realName != "") {
// var info = "该文件已上传,对应数据集(" + file.datasetName + ")-文件(" + file.realName + ")";
// window.location.reload();
let info = `该文件已上传在数据集: ${file.datasetName}`
this.uploadError(file,info)
this.allUploadLength++


Loading…
Cancel
Save