Merge branch 'master' of https://gitee.com/beijing_hongye_huicheng/lilishop-uniapp
commit
031aa0f173
|
@ -28,3 +28,16 @@ export function getArticleDetail(type) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取文章详情
|
||||||
|
* @param type
|
||||||
|
*/
|
||||||
|
export function getArticleDetailByType(type) {
|
||||||
|
return http.request({
|
||||||
|
url: `/other/article/type/${type}`,
|
||||||
|
method: Method.GET,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,18 +1,18 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="wrapper">
|
<div class="wrapper">
|
||||||
<u-parse :show-with-animation="true" :lazy-load="true" :selectable="true" :html="res.content"></u-parse>
|
<u-parse :show-with-animation="true" :lazy-load="true" :selectable="true" :html="res.content" v-if="res"></u-parse>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getArticleDetail } from "@/api/article";
|
import { getArticleDetailByType } from "@/api/article";
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
res: "",
|
res: "",
|
||||||
way: {
|
way: {
|
||||||
user: {
|
user: {
|
||||||
title: "用户协议",
|
title: "服务协议",
|
||||||
type: "USER_AGREEMENT",
|
type: "USER_AGREEMENT",
|
||||||
},
|
},
|
||||||
privacy: {
|
privacy: {
|
||||||
|
@ -40,9 +40,10 @@ export default {
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
init(option) {
|
init(option) {
|
||||||
getArticleDetail(this.way[option.type].type).then((res) => {
|
getArticleDetailByType(this.way[option.type].type).then((res) => {
|
||||||
if (res.data.success) {
|
if (res.data.success) {
|
||||||
this.res = res.data.result;
|
this.res = res.data.result;
|
||||||
|
console.log(res)
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -20,10 +20,10 @@
|
||||||
<u-cell-item title="检查更新" @click="checkUpdate"></u-cell-item>
|
<u-cell-item title="检查更新" @click="checkUpdate"></u-cell-item>
|
||||||
<!-- #endif -->
|
<!-- #endif -->
|
||||||
|
|
||||||
<u-cell-item title="证照信息" @click="navigateTo('/pages/mine/help/tips?type=message')"></u-cell-item>
|
<u-cell-item title="证照信息" @click="navigateTo('/pages/mine/help/tips?type=LICENSE_INFORMATION')"></u-cell-item>
|
||||||
<u-cell-item title="服务协议" @click="navigateTo('/pages/mine/help/tips?type=user')"></u-cell-item>
|
<u-cell-item title="服务协议" @click="navigateTo('/pages/mine/help/tips?type=USER_AGREEMENT')"></u-cell-item>
|
||||||
<u-cell-item title="隐私协议" @click="navigateTo('/pages/mine/help/tips?type=privacy')"></u-cell-item>
|
<u-cell-item title="隐私协议" @click="navigateTo('/pages/mine/help/tips?type=PRIVACY_POLICY')"></u-cell-item>
|
||||||
<u-cell-item title="关于我们" :border-bottom="false" @click="navigateTo('/pages/mine/help/tips?type=about')"></u-cell-item>
|
<u-cell-item title="关于我们" :border-bottom="false" @click="navigateTo('/pages/mine/help/tips?type=ABOUT')"></u-cell-item>
|
||||||
|
|
||||||
</u-cell-group>
|
</u-cell-group>
|
||||||
|
|
||||||
|
|
|
@ -15,8 +15,9 @@
|
||||||
word-break: break-all;
|
word-break: break-all;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
|
white-space: pre-wrap;">
|
||||||
white-space: pre-wrap;">{{item.title}}
|
<view style="color:black;font-size:30rpx;font-weight:500;">{{item.title}}</view>
|
||||||
|
<view>{{item.content}}</view>
|
||||||
<view style="width:400rpx;padding: 10rpx 0;">{{item.createTime}}</view>
|
<view style="width:400rpx;padding: 10rpx 0;">{{item.createTime}}</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
@ -39,7 +40,9 @@
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
|
|
||||||
white-space: pre-wrap;">{{item.title}}
|
white-space: pre-wrap;">
|
||||||
|
<view style="color:black;font-size:30rpx;font-weight:500;">{{item.title}}</view>
|
||||||
|
<view>{{item.content}}</view>
|
||||||
<view style="width:400rpx;padding: 10rpx 0;">{{item.createTime}}</view>
|
<view style="width:400rpx;padding: 10rpx 0;">{{item.createTime}}</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
Loading…
Reference in New Issue