|
@@ -80,7 +80,7 @@
|
|
|
</div>
|
|
</div>
|
|
|
<!-- btn group -->
|
|
<!-- btn group -->
|
|
|
<footer class="">
|
|
<footer class="">
|
|
|
- <el-button type="primary" @click="publish" class="btn-save" v-bind:disabled="isPublishing">保存</el-button>
|
|
|
|
|
|
|
+ <el-button type="primary" @click="publish" class="btn-save" v-bind:disabled="isPublishing">{{ submitText }}</el-button>
|
|
|
<!-- <el-button @click="cancel">取消</el-button>-->
|
|
<!-- <el-button @click="cancel">取消</el-button>-->
|
|
|
</footer>
|
|
</footer>
|
|
|
</div>
|
|
</div>
|
|
@@ -139,7 +139,22 @@
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
mixins: [oos],
|
|
mixins: [oos],
|
|
|
- computed: {},
|
|
|
|
|
|
|
+ computed: {
|
|
|
|
|
+ /**
|
|
|
|
|
+ * 提交保存时的文字:
|
|
|
|
|
+ * 1. 没有作品资源时,文案为“保存”
|
|
|
|
|
+ * 2. 有作品资源时,文案为“保存并提交审核”
|
|
|
|
|
+ */
|
|
|
|
|
+ submitText () {
|
|
|
|
|
+ let res = '保存'
|
|
|
|
|
+
|
|
|
|
|
+ if (this.uploadFileList && this.uploadFileList.length) {
|
|
|
|
|
+ res = '保存并提交审核'
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ return res
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
mounted() {
|
|
mounted() {
|
|
|
this.needLogin();
|
|
this.needLogin();
|
|
|
this.getWorkCate();
|
|
this.getWorkCate();
|
|
@@ -277,7 +292,13 @@
|
|
|
this.goHome();
|
|
this.goHome();
|
|
|
}
|
|
}
|
|
|
if (res.status === 1) {
|
|
if (res.status === 1) {
|
|
|
- this.$message.success("编辑作品成功!");
|
|
|
|
|
|
|
+ if (this.uploadFileList && this.uploadFileList.length) {
|
|
|
|
|
+ // 有作品资源时
|
|
|
|
|
+ this.$message.success("提交成功,系统将在1-3个工作日完成审核");
|
|
|
|
|
+ } else {
|
|
|
|
|
+ // 无作品资源时
|
|
|
|
|
+ this.$message.success("编辑作品成功!");
|
|
|
|
|
+ }
|
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
|
//window.location.href = `/wo/${self.$store.state.userinfo.uid}/works`;
|
|
//window.location.href = `/wo/${self.$store.state.userinfo.uid}/works`;
|
|
|
window.location.href = res.data.work_url;
|
|
window.location.href = res.data.work_url;
|
|
@@ -295,7 +316,13 @@
|
|
|
this.goHome();
|
|
this.goHome();
|
|
|
}
|
|
}
|
|
|
if (res.status === 1) {
|
|
if (res.status === 1) {
|
|
|
- this.$message.success("添加作品成功!");
|
|
|
|
|
|
|
+ if (this.uploadFileList && this.uploadFileList.length) {
|
|
|
|
|
+ // 有作品资源时
|
|
|
|
|
+ this.$message.success("提交成功,系统将在1-3个工作日完成审核");
|
|
|
|
|
+ } else {
|
|
|
|
|
+ // 无作品资源时
|
|
|
|
|
+ this.$message.success("添加作品成功!");
|
|
|
|
|
+ }
|
|
|
this.wid = res.data.wid || ''
|
|
this.wid = res.data.wid || ''
|
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
|
window.location.href = res.data.work_url;
|
|
window.location.href = res.data.work_url;
|