|
@@ -1,41 +1,39 @@
|
|
|
<template>
|
|
|
- <view class='app-container'>
|
|
|
+ <view class="app-container">
|
|
|
<uv-parse :content="form.content" selectable @linktap="linktap" />
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { detail } from '@/api/agreement.js'
|
|
|
+import { detail } from "@/api/explain.js";
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
// 表单
|
|
|
- form: {}
|
|
|
- }
|
|
|
+ form: {},
|
|
|
+ };
|
|
|
},
|
|
|
onLoad(e) {
|
|
|
- this.getDetail(e.type)
|
|
|
+ this.getDetail(e.id);
|
|
|
},
|
|
|
methods: {
|
|
|
- getDetail(type) {
|
|
|
- detail({
|
|
|
- type: type
|
|
|
- }).then(res => {
|
|
|
+ getDetail(id) {
|
|
|
+ detail(id).then((res) => {
|
|
|
if (res.code === 0) {
|
|
|
- this.form = res.data
|
|
|
+ this.form = res.data;
|
|
|
}
|
|
|
- })
|
|
|
+ });
|
|
|
},
|
|
|
// 点击链接
|
|
|
linktap(e) {
|
|
|
- window.location.href = e.href
|
|
|
- }
|
|
|
- }
|
|
|
-}
|
|
|
+ window.location.href = e.href;
|
|
|
+ },
|
|
|
+ },
|
|
|
+};
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
-.app-container{
|
|
|
+.app-container {
|
|
|
white-space: pre-wrap;
|
|
|
}
|
|
|
</style>
|