公告优化

This commit is contained in:
GaoHao
2025-01-09 17:03:25 +08:00
parent 9f193da9b6
commit 6f70c40f84
2 changed files with 5 additions and 3 deletions

View File

@@ -126,7 +126,7 @@
</template>
<script>
import { $cache_config } from '@/store/cashe.js'
import { $cache_config, $cache_index } from '@/store/cashe.js'
import { init } from '@/utils/init.js'
export default {
data() {
@@ -173,7 +173,7 @@
isWithdraw: false,
withdrawNum: $cache_config.withdrawNum,
ruleIndex: 0,
ruleList: []
ruleList: $cache_config.ruleIndex||[]
};
},
onLoad() {
@@ -182,6 +182,7 @@
this.$Request.getT("app/announcement", {type: 1}).then(res => {
if (res.code == 0) {
this.ruleList = res.data
$cache_config.set('ruleIndex',this.ruleList)
this.ruleInit()
}
});

View File

@@ -281,7 +281,7 @@
rule_title: '',
rule_content: '',
ruleIndex: 0,
ruleList: []
ruleList: $cache_config.ruleIndex || []
};
},
onShareAppMessage(res) {
@@ -438,6 +438,7 @@
if (res.code == 0) {
this.ruleShow = true
this.ruleList = res.data
$cache_config.set('ruleIndex',this.ruleList)
this.ruleInit()
}
});