agreement.vue 1004 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. <template>
  2. <v-header :title="item.label" backgroundColor="#fff" scroll async @fetch="fetch">
  3. <view class="agreement-screen html-all" v-html="info"></view>
  4. </v-header>
  5. </template>
  6. <script>
  7. import vHeader from '@/components/v-header/main.vue';
  8. import params from '@/mixins/params';
  9. import data from './data/data';
  10. import html from '@/utils/tool/html';
  11. import globalMixins from '@/mixins/global';
  12. export default {
  13. name: "agreement",
  14. mixins:[params,globalMixins],
  15. data(){
  16. return {
  17. item:{},
  18. info:''
  19. }
  20. },
  21. components:{
  22. vHeader
  23. },
  24. methods:{
  25. fetch(obj){
  26. this.$request({
  27. url:'index/getConfigDate',
  28. cache:true,
  29. data:{
  30. word: this.item.type
  31. }
  32. }).then((data)=>{
  33. this.info = html.parseHtml(data.data);
  34. return obj.success();
  35. }).catch(obj.fail);
  36. }
  37. },
  38. onLoad(){
  39. this.item = data[this.$params.type] || data.privacy;
  40. }
  41. }
  42. </script>
  43. <style lang="scss" src="./style.scss">
  44. </style>