feat:增加各种优化

This commit is contained in:
fanxb 2023-03-07 22:24:23 +08:00
parent e848ecc236
commit f90002b969
2 changed files with 52 additions and 20 deletions

View File

@ -10,11 +10,31 @@
<body>
<noscript>
<strong
>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to
>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please
enable it to
continue.</strong
>
</noscript>
<div id="app"></div>
<!-- built files will be auto injected -->
<!--&lt;!&ndash; 页面PV &ndash;&gt;-->
<!--<div style="text-align: center;">-->
<!-- <div id="qieziStatisticHtmlPost" style="display: none;">当前页面访问次数:<span id="qieziStatisticHtmlPostPv"></span>次&nbsp;-->
<!-- </div>-->
<!--</div>-->
<!--&lt;!&ndash; 网站整体UV/PV &ndash;&gt;-->
<!--<div style="text-align: center;">-->
<!-- <div id="qieziStatisticHtmlHostPv" style="display: none;">总访问次数:<span-->
<!-- id="qieziStatisticHtmlHostPvValue"></span>次&nbsp;-->
<!-- </div>-->
<!-- <div id="qieziStatisticHtmlHostUv" style="display: none;">&nbsp;总访客数:<span-->
<!-- id="qieziStatisticHtmlHostUvValue"></span>人-->
<!-- </div>-->
<!--</div>-->
<script>
//设置上一节获取到的key
window.qieziStatisticKey = "13ec82dd91294ae4a88b0d2cc6cbdf76";
</script>
<script src="https://qiezi.fleyx.com/qiezijs/1.0/qiezi_statistic.min.js" type="text/javascript"></script>
</body>
</html>

View File

@ -13,8 +13,17 @@
<div class="content">
<router-view/>
</div>
<div class="footer">版本{{ version }}&nbsp;&nbsp;开源地址:<a
href="https://github.com/FleyX/open-renamer">open-renamer</a></div>
<div class="footer">版本{{ version }}&nbsp;&nbsp;
<template v-if="latestVersion && latestVersion>version">
最新版本:
<el-tooltip effect="dark" content="点击查看更新文档" placement="top">
<a href="https://blog.fleyx.com/blog/detail/20221130/#%e5%8d%87%e7%ba%a7" target="_blank">{{
latestVersion
}}</a>
</el-tooltip>
</template>
开源地址:<a href="https://github.com/FleyX/open-renamer">open-renamer</a>
</div>
</div>
</template>
@ -25,13 +34,16 @@ export default {
name: "Home",
data() {
return {
version: "1.2",
version: 1.2,
latestVersion: null,
activeIndex: location.pathname,
};
},
async created() {
let token = localStorage.getItem("token");
window.token = token;
//
let config = await httpUtil.get("https://s3.fleyx.com/picbed/openRenamer/config.json");
this.latestVersion = config.version;
window.token = localStorage.getItem("token");
window.isWindows = await httpUtil.get("/file/isWindows");
console.log(this.$route);
console.log(this.activeIndex);