Commit 7431cebe authored by “yiyousong”'s avatar “yiyousong”

perf: 优化

parent f90e82d8
...@@ -219,7 +219,7 @@ export default { ...@@ -219,7 +219,7 @@ export default {
background: url("./assets/img/reg-bg.jpg") no-repeat; background: url("./assets/img/reg-bg.jpg") no-repeat;
} }
.main-ksck-img { .main-ksck-img {
background: url("./assets/img/btn_kuaisu.png") no-repeat; background: url("./assets/img/reg-quickbg.png") no-repeat;
} }
//内页标题背景 //内页标题背景
.main-title-bg-img { .main-title-bg-img {
......
...@@ -162,8 +162,8 @@ ...@@ -162,8 +162,8 @@
</div> </div>
<div class="right flex flexc"> <div class="right flex flexc">
<div class="right-top"> <div class="right-top">
<router-link <div
to="/matterList" class="top_img_box main-ksck-img"
v-onEvent="{ v-onEvent="{
eventName: '点击', eventName: '点击',
eventCode: 'Click', eventCode: 'Click',
...@@ -171,15 +171,14 @@ ...@@ -171,15 +171,14 @@
businessName: '快速查看', businessName: '快速查看',
routers: $route, routers: $route,
}" }"
@click="$router.push('/matterList')"
> >
<div class="top_img_box">
<div class="top_img_text_box"> <div class="top_img_text_box">
<h3 class="text_box_title">快速查看</h3> <h3 class="text_box_title">快速查看</h3>
<p class="text_box_desc">多种样表快捷查看</p> <p class="text_box_desc">多种样表快捷查看</p>
</div> </div>
<img src="../../assets/img/reg-quickbg.png" alt="" /> <!-- <img src="../../assets/img/reg-quickbg.png" alt="" /> -->
</div> </div>
</router-link>
</div> </div>
<!-- 热门事项 --> <!-- 热门事项 -->
<div class="right-bottom flex flexc"> <div class="right-bottom flex flexc">
...@@ -634,6 +633,9 @@ export default { ...@@ -634,6 +633,9 @@ export default {
padding-bottom: 20px; padding-bottom: 20px;
.top_img_box { .top_img_box {
width: 100%;
height: 160px;
cursor: pointer;
position: relative; position: relative;
.top_img_text_box { .top_img_text_box {
position: absolute; position: absolute;
......
...@@ -8,14 +8,16 @@ ...@@ -8,14 +8,16 @@
import { mapMutations, mapGetters } from "vuex"; import { mapMutations, mapGetters } from "vuex";
export default { export default {
data() { data() {
return {}; return {
}, defaultTimes: 300,
computed: { };
...mapGetters(["times", "defaultTimes"]),
}, },
created() { created() {
this.isTimeOut(); this.isTimeOut();
}, },
computed: {
...mapGetters(["times"]),
},
methods: { methods: {
...mapMutations(["SET_times"]), ...mapMutations(["SET_times"]),
// 返回首页 // 返回首页
......
...@@ -26,7 +26,9 @@ ...@@ -26,7 +26,9 @@
:key="v.id" :key="v.id"
v-show="active === i" v-show="active === i"
> >
<div class="short">{{ v.materialName }}</div> <div class="short">
{{ v.materialName }}
</div>
<div class="full-name">材料全称:{{ v.materiaFullName }}</div> <div class="full-name">材料全称:{{ v.materiaFullName }}</div>
<div <div
class="preview-img-box flex aic jcc" class="preview-img-box flex aic jcc"
...@@ -453,10 +455,12 @@ export default { ...@@ -453,10 +455,12 @@ export default {
// } // }
} }
.short { .short {
text-align: center;
font-size: 34px; font-size: 34px;
color: var(--main-theme-color); color: var(--main-theme-color);
} }
.full-name { .full-name {
text-align: center;
margin-top: 10px; margin-top: 10px;
margin-bottom: 24px; margin-bottom: 24px;
font-size: 30px; font-size: 30px;
......
import Vue from "vue"; import Vue from "vue";
import Vuex from "vuex"; import Vuex from "vuex";
import createPersistedState from "vuex-persistedstate"; // import createPersistedState from "vuex-persistedstate";
import SecureLS from "secure-ls"; // import SecureLS from "secure-ls";
var ls = new SecureLS({ isCompression: false }); // var ls = new SecureLS({ isCompression: false });
Vue.use(Vuex); Vue.use(Vuex);
export default new Vuex.Store({ export default new Vuex.Store({
...@@ -56,17 +56,17 @@ export default new Vuex.Store({ ...@@ -56,17 +56,17 @@ export default new Vuex.Store({
actions: {}, actions: {},
modules: {}, modules: {},
// 持久化插件 // 持久化插件
plugins: [ // plugins: [
// // createPersistedState({
// // storage: window.sessionStorage,
// // }),
// createPersistedState({ // createPersistedState({
// storage: window.sessionStorage, // key: "info",
// storage: {
// getItem: (key) => ls.get(key),
// setItem: (key, value) => ls.set(key, value),
// removeItem: (key) => ls.remove(key),
// },
// }), // }),
createPersistedState({ // ],
key: "info",
storage: {
getItem: (key) => ls.get(key),
setItem: (key, value) => ls.set(key, value),
removeItem: (key) => ls.remove(key),
},
}),
],
}); });
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment