123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- <template>
- <view class="privacy">
- <!-- 头部功能组件 -->
- <cu-loadding :show="show" />
- <!-- header -->
- <cu-custom bgColor="bg-gradual-blue" isBack><view slot="content">隐私声明</view></cu-custom>
- <!-- section -->
- <view class="padding">
- <rich-text :nodes="describe"></rich-text>
- </view>
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
- describe:"",
- show:true,//加载
- };
- },
- onLoad() {
- this.requestData();
- },
- methods: {
- // 请求富文本
- async requestData(){
- try{
- var res=await this.$global.request({method:"get",url:"/customer/statement/"});
- this.describe=this.$global.richTextChange(res.data.privacy_statement);
- }catch(err){
- this.showErr(err)
- }finally{
- this.show=false;
- }
- },
- // 报错
- showErr(content) {
- content = JSON.stringify(content) === '{}' ? '未知错误' : content;
- uni.showModal({
- content,
- showCancel: false,
- success: res => console.log(res)
- });
- },
-
- }
- };
- </script>
- <style lang="scss" scoped></style>
|