|
@@ -37,13 +37,15 @@
|
|
|
</div>
|
|
|
<div class="table" v-loading="loading">
|
|
|
<el-table :data="tableData.data" stripe style="width: 100%">
|
|
|
+ <!-- 文档名称 -->
|
|
|
<el-table-column
|
|
|
- label="文档名称"
|
|
|
+ :label="$t('key548')"
|
|
|
prop="name"
|
|
|
width="300"
|
|
|
></el-table-column>
|
|
|
+ <!-- label="文档类型" -->
|
|
|
<el-table-column
|
|
|
- label="文档类型"
|
|
|
+ :label="$t('key549')"
|
|
|
prop="type"
|
|
|
width="150"
|
|
|
:formatter="handlefileType"
|
|
@@ -137,20 +139,7 @@ export default {
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
- tableData: [
|
|
|
- {
|
|
|
- name: "教师培训公开课1",
|
|
|
- type: "ppt",
|
|
|
- creadTime: "2021-10-10 15:30",
|
|
|
- download: 1,
|
|
|
- },
|
|
|
- {
|
|
|
- name: "教师培训公开课2",
|
|
|
- type: "pdf",
|
|
|
- creadTime: "2021-10-10 15:30",
|
|
|
- download: 0,
|
|
|
- },
|
|
|
- ],
|
|
|
+ tableData: [],
|
|
|
fileList: null,
|
|
|
loading: false,
|
|
|
keyWord: "",
|
|
@@ -204,8 +193,6 @@ export default {
|
|
|
.catch((res) => {
|
|
|
this.loading = false;
|
|
|
});
|
|
|
- // let fileList1 = JSON.parse(JSON.stringify(fileList));
|
|
|
- // this.fileList = fileList1;
|
|
|
},
|
|
|
// 搜索
|
|
|
seekData() {
|
|
@@ -226,7 +213,7 @@ export default {
|
|
|
// 编辑
|
|
|
handleEdit(item) {
|
|
|
if (item.status == 4) {
|
|
|
- this.$message.warning("上架状态下不可以进行编辑操作");
|
|
|
+ this.$message.warning(this.$t("Key559"));
|
|
|
return;
|
|
|
}
|
|
|
this.$router.push({
|
|
@@ -239,12 +226,13 @@ export default {
|
|
|
// 删除
|
|
|
handleDel(item) {
|
|
|
if (item.status == 4) {
|
|
|
- this.$message.warning("上架状态下不可以进行删除操作");
|
|
|
+ //"上架状态下不可以进行删除操作"
|
|
|
+ this.$message.warning(this.$t("Key586"));
|
|
|
return;
|
|
|
}
|
|
|
- this.$confirm("确定要删除此学习资料吗?", "提示", {
|
|
|
- confirmButtonText: "确定",
|
|
|
- cancelButtonText: "取消",
|
|
|
+ this.$confirm("确定要删除此学习资料吗?", this.$t("Key361"), {
|
|
|
+ confirmButtonText: this.$t("Key94"), //"确定",
|
|
|
+ cancelButtonText: this.$t("Key83"), //"取消",
|
|
|
type: "warning",
|
|
|
})
|
|
|
.then(() => {
|
|
@@ -256,7 +244,7 @@ export default {
|
|
|
this.getdata();
|
|
|
this.$message({
|
|
|
type: "success",
|
|
|
- message: "删除成功",
|
|
|
+ message: this.$t("Key532"), //"删除成功",
|
|
|
});
|
|
|
})
|
|
|
.catch((res) => {
|
|
@@ -270,10 +258,12 @@ export default {
|
|
|
// 上架
|
|
|
up(item) {
|
|
|
if (item.status == 4) {
|
|
|
- this.$message.warning("该课程已经上架了");
|
|
|
+ // "该课程已经上架了"
|
|
|
+ this.$message.warning(this.$t("Key590"));
|
|
|
return;
|
|
|
}
|
|
|
if (!item.price || !item.teacher[0]) {
|
|
|
+ // "请先去完善信息再上架"
|
|
|
this.$message.warning("请先去完善信息再上架");
|
|
|
return;
|
|
|
}
|
|
@@ -286,7 +276,7 @@ export default {
|
|
|
this.getdata();
|
|
|
this.$message({
|
|
|
type: "success",
|
|
|
- message: "上架成功",
|
|
|
+ message: this.$t("Key501"), //"上架成功",
|
|
|
});
|
|
|
})
|
|
|
.catch(() => {
|
|
@@ -296,7 +286,8 @@ export default {
|
|
|
// 下架
|
|
|
down(item) {
|
|
|
if (item.status == 3) {
|
|
|
- this.$message.warning("该课程已经下架了");
|
|
|
+ //"该课程已经下架了"
|
|
|
+ this.$message.warning(this.$t("Key588"));
|
|
|
return;
|
|
|
}
|
|
|
this.loading = true;
|
|
@@ -308,7 +299,7 @@ export default {
|
|
|
this.getdata();
|
|
|
this.$message({
|
|
|
type: "success",
|
|
|
- message: "下架成功",
|
|
|
+ message: this.$t("Key501"), // "下架成功",
|
|
|
});
|
|
|
})
|
|
|
.catch(() => {
|
|
@@ -372,6 +363,8 @@ export default {
|
|
|
"Key9",
|
|
|
"Key39",
|
|
|
"Key46",
|
|
|
+ "Key83",
|
|
|
+ "Key94",
|
|
|
"Key123",
|
|
|
"Key124",
|
|
|
"Key125",
|
|
@@ -388,6 +381,14 @@ export default {
|
|
|
"Key245",
|
|
|
"Key246",
|
|
|
"Key232",
|
|
|
+ "Key361",
|
|
|
+ "Key532",
|
|
|
+ "Key548",
|
|
|
+ "Key549",
|
|
|
+ "Key559",
|
|
|
+ "Key586",
|
|
|
+ "Key588",
|
|
|
+ "Key590",
|
|
|
],
|
|
|
});
|
|
|
this.isData = true;
|