diff --git a/src/components/quill/index.vue b/src/components/quill/index.vue
index 5b3d283..1117f09 100644
--- a/src/components/quill/index.vue
+++ b/src/components/quill/index.vue
@@ -43,7 +43,6 @@ import 'quill/dist/quill.core.css';
import 'quill/dist/quill.snow.css';
import 'quill/dist/quill.bubble.css';
import toolbarOptions from './options'
-import axios from 'axios'
import { mavonEditor } from 'mavon-editor'
import 'mavon-editor/dist/css/index.css'
import Upload from '@/components/upload';
diff --git a/src/utils/editor.js b/src/utils/editor.js
index baee08b..037a2c3 100644
--- a/src/utils/editor.js
+++ b/src/utils/editor.js
@@ -336,8 +336,6 @@ export default {
input.setAttribute("accept", ".mp4");
input.onchange = function(){
let file = this.files[0];
- let fd = new FormData();
- fd.append("file", file);
const load = Loading.service()
Oss.upload(file).then(res => {
load.close()
diff --git a/src/views/course/contentSettings.vue b/src/views/course/contentSettings.vue
index 5136d2c..3053163 100644
--- a/src/views/course/contentSettings.vue
+++ b/src/views/course/contentSettings.vue
@@ -348,7 +348,6 @@ import { Loading } from "element-ui";
import Pdf from "@/components/pdf";
import Upload from '@/components/upload';
import Oss from '@/components/upload/upload.js'
-import axios from 'axios'
import Util from '@/libs/util'
export default {
diff --git a/src/views/information/addArticle/index.vue b/src/views/information/addArticle/index.vue
index cfe0c2c..cd020e7 100644
--- a/src/views/information/addArticle/index.vue
+++ b/src/views/information/addArticle/index.vue
@@ -174,14 +174,11 @@ export default {
},
// 封面自定义上传
async handleRequest ({ file }) {
+ this.form.coverUrl && Oss.del(this.form.coverUrl)
Oss.upload(file).then(res => {
this.form.coverUrl = res.url
})
},
- uploadSuccess (res, file, fileList) {
- Oss.del(this.form.coverUrl)
- this.form.coverUrl = res.data.filesResult.fileUrl;
- },
uploadError (err, file, fileList) {
this.$message({
message: "上传出错,请重试!",
diff --git a/src/views/match/add/step1.vue b/src/views/match/add/step1.vue
index caa4223..1e761f0 100644
--- a/src/views/match/add/step1.vue
+++ b/src/views/match/add/step1.vue
@@ -271,15 +271,11 @@ import util from "@/libs/util";
import quill from "@/components/quill";
import Upload from '@/components/upload';
import Oss from '@/components/upload/upload.js'
-import { Loading } from 'element-ui'
export default {
props: ['editing'],
data () {
const that = this
return {
- headers: {
- token: sessionStorage.getItem('token')
- },
form: {
id: this.$route.query.id || '',
platformSource: 0, // 平台来源(0:中台,1:职站)
diff --git a/src/views/match/add/step3.vue b/src/views/match/add/step3.vue
index d9bb366..f9b2c80 100644
--- a/src/views/match/add/step3.vue
+++ b/src/views/match/add/step3.vue
@@ -64,10 +64,8 @@
:on-error="uploadError"
:before-remove="beforeRemove"
action=""
- :headers="headers"
:file-list="item.competitionStageContentSetting.fileList"
- :http-request="res => handleRequest(res, item)"
- name="file">
+ :http-request="res => handleRequest(res, item)">
每个团队参赛人数限制:{{ rule.teamNumLimit || '不限制' }}
团队成绩计算方式:{{ teamCalculationMethods.find(e => e.id == rule.teamCalculationMethod) && teamCalculationMethods.find(e => e.id == rule.teamCalculationMethod).name }}
-阶段比赛结束后{{ rule.resultAnnouncementTime }}小时,公布阶段比赛成绩。
+晋级规则:
@@ -183,6 +183,7 @@ export default { }, mounted () { this.handleAnnex() + console.log("🚀 ~ file: index.vue:187 ~ mounted ~ this.form:", this.form) if (this.form.id) { this.getProgress() this.getNotice() diff --git a/src/views/theoreticalCourse/add/index.vue b/src/views/theoreticalCourse/add/index.vue index ce2bb0e..9c6651f 100644 --- a/src/views/theoreticalCourse/add/index.vue +++ b/src/views/theoreticalCourse/add/index.vue @@ -470,6 +470,7 @@ export default { util.warningMsg("当前限制选择 1 个文件,如需更换,请删除上一个文件再重新选择!"); }, handleRequest ({ file }) { + this.form.coverUrl && Oss.del(this.form.coverUrl) Oss.upload(file).then(res => { this.form.coverUrl = res.url })