|
@@ -1,6 +1,6 @@
|
|
|
<template>
|
|
|
<!-- 教材详情 -->
|
|
|
- <div class="TextbookDetail" v-if="TextbookData">
|
|
|
+ <div class="TextbookDetail" v-if="TextbookData && isData">
|
|
|
<div class="nav">
|
|
|
<!-- 登录导航 -->
|
|
|
<Header />
|
|
@@ -29,7 +29,8 @@
|
|
|
></span>
|
|
|
</span>
|
|
|
<button @click="getPurchase" class="get">
|
|
|
- {{ bookIsBuy == "true" ? "去学习" : "购买" }}
|
|
|
+ <!-- Key390-去学习 Key72-购买 -->
|
|
|
+ {{ bookIsBuy == "true" ? this.$t("Key390") : this.$t("Key72") }}
|
|
|
</button>
|
|
|
<!-- <button class="acquired">
|
|
|
ACQUIRED
|
|
@@ -128,13 +129,13 @@
|
|
|
@click="SelectShowEvent('1')"
|
|
|
:class="SelectShow == '1' ? 'select' : ''"
|
|
|
>
|
|
|
- 目录
|
|
|
+ <!-- 目录 -->{{ $t("Key612") }}
|
|
|
</div>
|
|
|
<div
|
|
|
@click="SelectShowEvent('2')"
|
|
|
:class="SelectShow == '1' ? '' : 'select'"
|
|
|
>
|
|
|
- 资源
|
|
|
+ <!-- 资源 -->{{ $t("Key613") }}
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -153,9 +154,10 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
+ <!-- 商品详情 -->
|
|
|
<el-dialog
|
|
|
class="buyWindow"
|
|
|
- title="商品详情"
|
|
|
+ :title="$t('Key52')"
|
|
|
:visible.sync="NopymentShow"
|
|
|
width="720px"
|
|
|
:before-close="closeNoPyment"
|
|
@@ -167,8 +169,9 @@
|
|
|
ref="Confirmorder"
|
|
|
/>
|
|
|
</el-dialog>
|
|
|
+ <!-- 订单号 -->
|
|
|
<el-dialog
|
|
|
- :title="'订单号:' + orderNumber"
|
|
|
+ :title="$t('Key472') + ':' + orderNumber"
|
|
|
:visible.sync="PymentShow"
|
|
|
width="720px"
|
|
|
:before-close="closePyment"
|
|
@@ -191,6 +194,7 @@ import { TextbookAPI, LearnWebSI } from "@/api/ajax";
|
|
|
import Confirmorder from "@/components/pyment/Confirmorder";
|
|
|
import Payment from "@/components/pyment/Payment";
|
|
|
import BookView from "@/views/bookView"; // 教材预览
|
|
|
+import { updateWordPack } from "@/utils/i18n";
|
|
|
export default {
|
|
|
//import引入的组件需要注入到对象中才能使用
|
|
|
components: {
|
|
@@ -216,6 +220,7 @@ export default {
|
|
|
IsDownload: false, //是否可以下载
|
|
|
detailSHow: true, // 除教材预览外其他内容是否显示
|
|
|
bookIsBuy: "false", // 教材是否已购买
|
|
|
+ isData: false,
|
|
|
};
|
|
|
},
|
|
|
//计算属性 类似于data概念
|
|
@@ -282,7 +287,7 @@ export default {
|
|
|
};
|
|
|
LearnWebSI(Mname, data).then((res) => {
|
|
|
this.enshrine = "true";
|
|
|
- this.$message.success("收藏成功");
|
|
|
+ this.$message.success(this.$t("Key575")); //"收藏成功"
|
|
|
});
|
|
|
} else {
|
|
|
let Mname = "order-collection_manager-CancelMyGoodsCollection";
|
|
@@ -292,7 +297,7 @@ export default {
|
|
|
};
|
|
|
LearnWebSI(Mname, data).then((res) => {
|
|
|
this.enshrine = "false";
|
|
|
- this.$message.success("取消收藏成功");
|
|
|
+ this.$message.success(this.$t("Key396")); //"取消收藏成功"
|
|
|
});
|
|
|
}
|
|
|
},
|
|
@@ -349,7 +354,30 @@ export default {
|
|
|
},
|
|
|
},
|
|
|
//生命周期 - 创建完成(可以访问当前this实例)
|
|
|
- created() {
|
|
|
+ async created() {
|
|
|
+ await updateWordPack({
|
|
|
+ word_key_list: [
|
|
|
+ "Key52",
|
|
|
+ "Key53",
|
|
|
+ "Key54",
|
|
|
+ "Key55",
|
|
|
+ "Key72",
|
|
|
+ "Key94",
|
|
|
+ "Key108",
|
|
|
+ "Key109",
|
|
|
+ "Key116",
|
|
|
+ "Key390",
|
|
|
+ "Key396",
|
|
|
+ "Key472",
|
|
|
+ "Key473",
|
|
|
+ "Key474",
|
|
|
+ "Key475",
|
|
|
+ "Key575",
|
|
|
+ "Key612",
|
|
|
+ "Key613",
|
|
|
+ ],
|
|
|
+ });
|
|
|
+ this.isData = true;
|
|
|
this.getdetail();
|
|
|
},
|
|
|
//生命周期 - 挂载完成(可以访问DOM元素)
|