@ -0,0 +1,18 @@ |
||||
import request from '@/apis/request.js' |
||||
const { get, post } = request |
||||
|
||||
export const partnerOperatingList = (data) => { |
||||
return post('nakadai/nakadai/partner/article/management/partnerOperatingList', data) |
||||
} |
||||
|
||||
export const findById = id => { |
||||
return post('nakadai/nakadai/applets/partner/browse?contentId=' + id) |
||||
} |
||||
|
||||
export const queryClassificationByType = id => { |
||||
return post('nakadai/nakadai/partner/article/classification/queryClassificationByType?typeId=' + id) |
||||
} |
||||
|
||||
export const schemeList = data => { |
||||
return post('nakadai/nakadai/partner/schemeManagement/schemeList', data) |
||||
} |
@ -0,0 +1,223 @@ |
||||
<template> |
||||
<view> |
||||
<view class="filter"> |
||||
<uni-search-bar class="search" radius="30" placeholder="请输入文章名称,标签" v-model="keyword" clearButton="auto" cancelButton="none" /> |
||||
<view :class="['sort', sort]" @click="switchSort"></view> |
||||
<uni-icons class="icon" custom-prefix="iconfont" type="icon-filter" size="22" color="#007eff" @click="popup = true"></uni-icons> |
||||
</view> |
||||
|
||||
<template v-if="list.length"> |
||||
<view class="list"> |
||||
<view class="item" @click="toDetail(item)"> |
||||
<image class="pic" src="@/static/image/logo.png"></image> |
||||
<view class="right"> |
||||
<view class="title">测试标题</view> |
||||
<view class="labels"> |
||||
<view class="label">大赛</view> |
||||
<view class="label">大赛发动机可</view> |
||||
</view> |
||||
<view class="metas"> |
||||
<view class="meta"> |
||||
<uni-icons class="icon" type="eye" size="22" color="#007FFF"></uni-icons> |
||||
123人学过 |
||||
</view> |
||||
<view class="meta"> |
||||
<uni-icons class="icon" type="star" size="22" color="#007eff"></uni-icons> |
||||
123 |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<uni-load-more :status="status" /> |
||||
</template> |
||||
<empty v-else></empty> |
||||
|
||||
<filter-popup :data="filterData" :form.sync="filterForm" v-model="popup" title="全部筛选" height="1104rpx" @finsh="subFinsh"></filter-popup> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { queryCustomer } from '@/apis/modules/client.js' |
||||
import { list, del } from '@/apis/modules/order.js' |
||||
export default { |
||||
data() { |
||||
return { |
||||
popup: false, |
||||
//筛选表单数据 |
||||
filterData: [ |
||||
{ |
||||
children: false,//是否有子项 |
||||
title: "所属类型", |
||||
key: "classificationId", //键名 接收对象名字 |
||||
keyValue: "value", //获取的值是哪个 |
||||
isRadio: true, //是否单选 否则多选 |
||||
data: [ |
||||
{ |
||||
title: "待发货", |
||||
value: 0 |
||||
}, |
||||
{ |
||||
title: "已完成", |
||||
value: 1 |
||||
}, |
||||
], |
||||
} |
||||
], |
||||
filterForm: {}, |
||||
reachBottom: 0, // 是否是上拉加载。0->否,1->是,-1->加载完所有数据 |
||||
status: 'more', // 上拉加载状态 more|loading|noMore |
||||
searchTimer: null, |
||||
orderStatus: '', |
||||
sort: 'desc', |
||||
keyword: '', |
||||
list: [ |
||||
{ |
||||
name: '1' |
||||
} |
||||
], |
||||
page: 1, |
||||
pageSize: 10, |
||||
} |
||||
}, |
||||
watch: { |
||||
keyword () { |
||||
clearTimeout(this.searchTimer) |
||||
this.searchTimer = setTimeout(() => { |
||||
this.initList() |
||||
}, 500) |
||||
} |
||||
}, |
||||
// 下拉刷新 |
||||
onPullDownRefresh() { |
||||
this.initList() |
||||
setTimeout(() => { |
||||
uni.stopPullDownRefresh() |
||||
}, 1500) |
||||
}, |
||||
// 上拉加载 |
||||
onReachBottom() { |
||||
if (this.reachBottom >= 0) { |
||||
this.reachBottom = 1 |
||||
this.status = 'loading' |
||||
this.getList() |
||||
} |
||||
}, |
||||
onShow() { |
||||
// this.initRole() |
||||
}, |
||||
methods: { |
||||
// 初始化权限 |
||||
initRole() { |
||||
this.initList() |
||||
}, |
||||
getList() { |
||||
const data = { |
||||
keywords: this.keyword, |
||||
pageNum: this.page, |
||||
pageSize: this.pageSize, |
||||
sort: this.sort, |
||||
orderStatus: this.orderStatus, |
||||
type: this.curTab |
||||
} |
||||
uni.showLoading({ |
||||
title: '加载中' |
||||
}) |
||||
list(data).then(({ data }) => { |
||||
uni.hideLoading() |
||||
// 未加载完所有数据,并且不是筛选,则拼接list,否则直接赋值 |
||||
const list = data.records |
||||
list.map(e => { |
||||
e.toggle = e.orderContent.length < 14 // 超过了14个字才需要显示展开按钮 |
||||
}) |
||||
this.list = this.reachBottom > 0 ? [...this.list, ...list] : list |
||||
this.page++ // 每次获取了数据后page+1 |
||||
const noMore = this.list.length === data.total // 是否加载完所有数据 |
||||
this.status = noMore ? 'noMore' : 'more' // 加载完了则设置为noMore |
||||
this.reachBottom = noMore ? -1 : 0 // 加载完了则设置为-1 |
||||
}).catch(e => { |
||||
uni.hideLoading() |
||||
}) |
||||
}, |
||||
initList() { |
||||
this.page = 1 |
||||
this.reachBottom = 0 |
||||
this.getList() |
||||
}, |
||||
// 展开 |
||||
toggle(item) { |
||||
item.toggle = !item.toggle |
||||
}, |
||||
// 筛选确定回调 |
||||
subFinsh(val) { |
||||
const { orderStatus } = val |
||||
this.orderStatus = orderStatus.length ? orderStatus[0] : '' |
||||
this.initList() |
||||
}, |
||||
// 排序 |
||||
switchSort() { |
||||
this.sort = this.sort === 'desc' ? 'asc' : 'desc' |
||||
this.initList() |
||||
}, |
||||
// tab切换 |
||||
tabChange(tab) { |
||||
this.curTab = tab.id |
||||
this.initList() |
||||
}, |
||||
// 跳转详情 |
||||
toDetail(item) { |
||||
this.$util.to(`/team/article/article`) |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style scoped lang="scss"> |
||||
.list { |
||||
margin-top: 20rpx; |
||||
background-color: #fff; |
||||
.item { |
||||
display: flex; |
||||
justify-content: space-between; |
||||
align-items: center; |
||||
margin-top: 10rpx; |
||||
padding: 20rpx 40rpx; |
||||
border-bottom: 1px solid #f1f1f1; |
||||
} |
||||
.pic { |
||||
width: 200rpx; |
||||
height: 140rpx; |
||||
} |
||||
.right { |
||||
width: calc(100% - 230rpx); |
||||
} |
||||
.title { |
||||
font-size: 32rpx; |
||||
font-weight: 600; |
||||
color: #333; |
||||
} |
||||
.labels { |
||||
display: inline-flex; |
||||
align-items: center; |
||||
margin: 15rpx 0; |
||||
} |
||||
.label { |
||||
padding: 2px 6px; |
||||
margin-right: 20rpx; |
||||
font-size: 24rpx; |
||||
color: #fff; |
||||
background-color: #ccc; |
||||
border-radius: 4px; |
||||
} |
||||
.metas { |
||||
display: inline-flex; |
||||
align-items: center; |
||||
} |
||||
.meta { |
||||
display: inline-flex; |
||||
align-items: center; |
||||
margin-right: 20rpx; |
||||
font-size: 24rpx; |
||||
} |
||||
} |
||||
</style> |
@ -0,0 +1,174 @@ |
||||
<template> |
||||
<view class="page"> |
||||
<image class="logo" src="@/static/image/logo.png" mode=""></image> |
||||
<view class="wrap"> |
||||
<view v-if="form.isTeam !== 0" class="hello"> |
||||
{{ form.isTeam ? '或然科技城市合伙人,欢迎回来!' : '欢迎加入或然城市合伙人计划!请认真填写您的姓名和意向开展业务的区域。注册后,我们将会有区域运营与您联系沟通后续事宜。'}} |
||||
</view> |
||||
<view> |
||||
<uni-forms> |
||||
<uni-forms-item label="姓名"> |
||||
<uni-easyinput type="text" v-model="form.userName" placeholder="请输入姓名" /> |
||||
</uni-forms-item> |
||||
<uni-forms-item label="意向省份"> |
||||
<uni-data-picker placeholder="请选择省份" popup-title="请选择省份" preload :localdata="provinces" :map="{text: 'provinceName', value: 'provinceId'}" v-model="form.provinceId" @change="getCity"></uni-data-picker> |
||||
</uni-forms-item> |
||||
<uni-forms-item label="意向城市"> |
||||
<uni-data-picker placeholder="请选择城市" popup-title="请选择城市" preload :localdata="cities" :map="{text: 'cityName', value: 'cityId'}" v-model="form.cityId"></uni-data-picker> |
||||
</uni-forms-item> |
||||
</uni-forms> |
||||
<view class="btns"> |
||||
<button type="primary" @click="submit">{{ form.isTeam ? '登录' : form.isTeam === 0 ? '确定' : '注册' }}</button> |
||||
<button>取消</button> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { queryPartnerAccount, queryProvince, queryCity, partnerAccountApplication, loginByOpenid, checkWorkNumOrAccount } from '@/apis/modules/user.js' |
||||
export default { |
||||
data() { |
||||
return { |
||||
openid: '', |
||||
phone: '', |
||||
form: { |
||||
userName: '', |
||||
provinceId: '', |
||||
cityId: '', |
||||
}, |
||||
accountRepeat: false, |
||||
provinces: [], |
||||
cities: [] |
||||
} |
||||
}, |
||||
onShow() { |
||||
const pages = getCurrentPages() |
||||
const { options } = pages[pages.length - 1] |
||||
this.openid = options.openid |
||||
this.phone = options.phone |
||||
this.getProvince() |
||||
// 先授权用户信息,再授权手机号 |
||||
this.checkLogin() |
||||
}, |
||||
methods: { |
||||
// 检查登录状态 |
||||
checkLogin() { |
||||
if (uni.getStorageSync('token')) { |
||||
this.toIndex() |
||||
} else { |
||||
// 根据手机号获取是否注册过,如果有,则判断是否是队长(isTeam 1:队长,0:成员),如果没有返回team,则注册 |
||||
queryPartnerAccount(this.phone).then(({ team }) => { |
||||
if (team) { |
||||
if (team.isTeam) { |
||||
this.form = team |
||||
this.getCity() |
||||
} else { |
||||
this.form.userName = team.userName |
||||
uni.showModal({ |
||||
title: '提示', |
||||
content: `或然科技城市合伙人,欢迎回来! |
||||
您已在${team.teamName}的团队,是否要创建自己的团队?`, |
||||
success: function (res) { |
||||
if (res.confirm) { |
||||
console.log('用户点击确定'); |
||||
} else if (res.cancel) { |
||||
uni.redirectTo({ |
||||
url: '../login/login' |
||||
}) |
||||
} |
||||
} |
||||
}) |
||||
} |
||||
} |
||||
}).catch(e => {}) |
||||
} |
||||
}, |
||||
// 获取省份 |
||||
getProvince() { |
||||
queryProvince().then(({ list }) => { |
||||
this.provinces = list |
||||
}).catch(res => {}) |
||||
}, |
||||
// 获取城市 |
||||
getCity(val) { |
||||
if (this.form.provinceId) { |
||||
queryCity({ |
||||
provinceId: this.form.provinceId |
||||
}).then(({ list }) => { |
||||
this.cities = list |
||||
}).catch(res => {}) |
||||
} else { |
||||
this.cities = [] |
||||
} |
||||
if (val) this.form.cityId = '' |
||||
}, |
||||
// 提交 |
||||
submit() { |
||||
const { form } = this |
||||
if (!form.userName) return this.$util.errMsg('请输入姓名!') |
||||
if (!form.provinceId) return this.$util.errMsg('请选择意向省份!') |
||||
if (!form.cityId) return this.$util.errMsg('请选择意向城市!') |
||||
form.phone = this.phone |
||||
form.appOpenId = this.openid |
||||
form.uniqueIdentification = Date.now() |
||||
if (form.isTeam) { // 队长,直接登录 |
||||
loginByOpenid(this.openid).then(({ data }) => { |
||||
uni.setStorageSync('token', data.token) |
||||
this.toIndex() |
||||
}).catch(res => {}) |
||||
} else { // 新用户,注册。or 成员,创建自己的团队 |
||||
partnerAccountApplication(form).then(res => { |
||||
this.$util.sucMsg(form.isTeam === 0 ? '创建成功' : '注册成功') |
||||
setTimeout(() => { |
||||
uni.redirectTo({ |
||||
url: '../login/login' |
||||
}) |
||||
}, 1500) |
||||
}).catch(res => {}) |
||||
} |
||||
}, |
||||
// 跳转到首页 |
||||
toIndex() { |
||||
uni.reLaunch({ |
||||
url: '../index/index' |
||||
}) |
||||
} |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style scoped lang="scss"> |
||||
.page { |
||||
min-height: 100%; |
||||
text-align: center; |
||||
background: url(@/static/image/login1.png) 0 0/175rpx auto no-repeat, |
||||
url(@/static/image/login2.png) bottom right/123rpx auto no-repeat; |
||||
.logo { |
||||
width: 393rpx; |
||||
height: 93rpx; |
||||
margin: 100rpx 0 60rpx; |
||||
} |
||||
} |
||||
.wrap { |
||||
position: relative; |
||||
padding: 60rpx; |
||||
margin: 0 61rpx; |
||||
text-align: center; |
||||
border-radius: 8rpx; |
||||
background-color: #fff; |
||||
.hello { |
||||
margin-bottom: 30rpx; |
||||
font-size: 28rpx; |
||||
color: #333; |
||||
} |
||||
.btns { |
||||
display: flex; |
||||
button { |
||||
width: 200rpx; |
||||
font-size: 30rpx; |
||||
} |
||||
} |
||||
} |
||||
</style> |
@ -0,0 +1,226 @@ |
||||
<template> |
||||
<view> |
||||
<view class="filter"> |
||||
<uni-search-bar class="search" radius="30" placeholder="请输入文章名称,标签" v-model="keyword" clearButton="auto" cancelButton="none" /> |
||||
<view :class="['sort', sort]" @click="switchSort"></view> |
||||
<uni-icons class="icon" custom-prefix="iconfont" type="icon-filter" size="22" color="#007eff" @click="popup = true"></uni-icons> |
||||
</view> |
||||
|
||||
<template v-if="list.length"> |
||||
<view class="list"> |
||||
<view v-for="(item, i) in list" :key="i" class="item" @click="toDetail(item)"> |
||||
<image class="pic" :src="item.bannerImg"></image> |
||||
<view class="right"> |
||||
<view class="title">{{ item.title }}</view> |
||||
<view v-if="item.labelName" class="labels"> |
||||
<view v-for="(label, j) in item.labelName.split(',')" :key="j" class="label">{{ label }}</view> |
||||
</view> |
||||
<view class="metas"> |
||||
<view class="meta"> |
||||
<uni-icons class="icon" type="eye" size="22" color="#007FFF"></uni-icons> |
||||
{{ item.learnerNumber }}人学过 |
||||
</view> |
||||
<!-- <view class="meta"> |
||||
<uni-icons class="icon" type="star" size="22" color="#007eff"></uni-icons> |
||||
123 |
||||
</view> --> |
||||
</view> |
||||
<view v-if="item.lastReading" class="last">上次阅读</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<uni-load-more :status="status" /> |
||||
</template> |
||||
<empty v-else></empty> |
||||
|
||||
<filter-popup :data="filterData" :form.sync="filterForm" v-model="popup" title="全部筛选" height="1104rpx" @finsh="subFinsh"></filter-popup> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { partnerOperatingList, queryClassificationByType } from '@/apis/modules/article.js' |
||||
export default { |
||||
data() { |
||||
return { |
||||
popup: false, |
||||
//筛选表单数据 |
||||
filterData: [ |
||||
{ |
||||
children: false,//是否有子项 |
||||
title: "所属类型", |
||||
key: "classificationId", //键名 接收对象名字 |
||||
keyValue: "id", //获取的值是哪个 |
||||
isRadio: true, //是否单选 否则多选 |
||||
data: [], |
||||
} |
||||
], |
||||
filterForm: { |
||||
classificationId: [] |
||||
}, |
||||
classificationId: '', |
||||
reachBottom: 0, // 是否是上拉加载。0->否,1->是,-1->加载完所有数据 |
||||
status: 'more', // 上拉加载状态 more|loading|noMore |
||||
searchTimer: null, |
||||
articleNameSort: 'desc', |
||||
keyword: '', |
||||
list: [], |
||||
page: 1, |
||||
pageSize: 10, |
||||
} |
||||
}, |
||||
watch: { |
||||
keyword () { |
||||
clearTimeout(this.searchTimer) |
||||
this.searchTimer = setTimeout(() => { |
||||
this.initList() |
||||
}, 500) |
||||
} |
||||
}, |
||||
// 下拉刷新 |
||||
onPullDownRefresh() { |
||||
this.initList() |
||||
setTimeout(() => { |
||||
uni.stopPullDownRefresh() |
||||
}, 1500) |
||||
}, |
||||
// 上拉加载 |
||||
onReachBottom() { |
||||
if (this.reachBottom >= 0) { |
||||
this.reachBottom = 1 |
||||
this.status = 'loading' |
||||
this.getList() |
||||
} |
||||
}, |
||||
onShow() { |
||||
this.initRole() |
||||
}, |
||||
methods: { |
||||
// 初始化权限 |
||||
initRole() { |
||||
this.initList() |
||||
this.getClassification() |
||||
}, |
||||
getList() { |
||||
const data = { |
||||
keyWord: this.keyword, |
||||
pageNum: this.page, |
||||
pageSize: this.pageSize, |
||||
querySource: 4, |
||||
typeId: 1, |
||||
articleNameSort: this.articleNameSort, |
||||
classificationId: this.classificationId |
||||
} |
||||
uni.showLoading({ |
||||
title: '加载中' |
||||
}) |
||||
partnerOperatingList(data).then(({ data }) => { |
||||
uni.hideLoading() |
||||
// 未加载完所有数据,并且不是筛选,则拼接list,否则直接赋值 |
||||
const list = data.records |
||||
this.list = this.reachBottom > 0 ? [...this.list, ...list] : list |
||||
this.page++ // 每次获取了数据后page+1 |
||||
const noMore = this.list.length === data.total // 是否加载完所有数据 |
||||
this.status = noMore ? 'noMore' : 'more' // 加载完了则设置为noMore |
||||
this.reachBottom = noMore ? -1 : 0 // 加载完了则设置为-1 |
||||
}).catch(e => { |
||||
uni.hideLoading() |
||||
}) |
||||
}, |
||||
initList() { |
||||
this.page = 1 |
||||
this.reachBottom = 0 |
||||
this.getList() |
||||
}, |
||||
// 获取所属分类 |
||||
getClassification() { |
||||
queryClassificationByType(1).then(({ data }) => { |
||||
data.forEach(e => { |
||||
e.title = e.classificationName |
||||
e.value = e.id |
||||
}) |
||||
this.filterData[0].data = data |
||||
console.log(11, this.filterData[0].data) |
||||
}).catch(e => {}) |
||||
}, |
||||
// 展开 |
||||
toggle(item) { |
||||
item.toggle = !item.toggle |
||||
}, |
||||
// 筛选确定回调 |
||||
subFinsh(val) { |
||||
const { classificationId } = val |
||||
this.classificationId = classificationId.length ? classificationId[0] : '' |
||||
this.initList() |
||||
}, |
||||
// 排序 |
||||
switchSort() { |
||||
this.articleNameSort = this.articleNameSort === 'desc' ? 'asc' : 'desc' |
||||
this.initList() |
||||
}, |
||||
// 跳转详情 |
||||
toDetail(item) { |
||||
this.$util.to(`/team/article/article?id=` + item.id) |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style scoped lang="scss"> |
||||
.list { |
||||
margin-top: 20rpx; |
||||
background-color: #fff; |
||||
.item { |
||||
position: relative; |
||||
display: flex; |
||||
justify-content: space-between; |
||||
align-items: center; |
||||
margin-top: 10rpx; |
||||
padding: 20rpx 40rpx; |
||||
border-bottom: 1px solid #f1f1f1; |
||||
} |
||||
.pic { |
||||
width: 200rpx; |
||||
height: 140rpx; |
||||
} |
||||
.right { |
||||
width: calc(100% - 230rpx); |
||||
} |
||||
.title { |
||||
font-size: 32rpx; |
||||
font-weight: 600; |
||||
color: #333; |
||||
} |
||||
.labels { |
||||
display: flex; |
||||
flex-wrap: wrap; |
||||
align-items: center; |
||||
margin-top: 15rpx; |
||||
} |
||||
.label { |
||||
padding: 2px 6px; |
||||
margin-bottom: 15rpx; |
||||
margin-right: 20rpx; |
||||
font-size: 24rpx; |
||||
color: #fff; |
||||
background-color: #ccc; |
||||
border-radius: 4px; |
||||
} |
||||
.metas { |
||||
display: flex; |
||||
align-items: center; |
||||
} |
||||
.meta { |
||||
display: inline-flex; |
||||
align-items: center; |
||||
margin-right: 20rpx; |
||||
font-size: 24rpx; |
||||
} |
||||
.last { |
||||
position: absolute; |
||||
bottom: 20rpx; |
||||
right: 40rpx; |
||||
font-size: 28rpx; |
||||
color: #007FFF; |
||||
} |
||||
} |
||||
</style> |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 937 B |
After Width: | Height: | Size: 860 B |
After Width: | Height: | Size: 490 B |
Before Width: | Height: | Size: 859 B After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 784 B After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 680 B After Width: | Height: | Size: 457 B |
Before Width: | Height: | Size: 627 B After Width: | Height: | Size: 452 B |
After Width: | Height: | Size: 680 B |
After Width: | Height: | Size: 627 B |
@ -0,0 +1,93 @@ |
||||
<template> |
||||
<view class="wrap"> |
||||
<view class="title">{{ form.title }}</view> |
||||
<view class="metas"> |
||||
<view class="meta"> |
||||
<uni-icons class="icon" type="eye" size="22" color="#007FFF"></uni-icons> |
||||
{{ form.totalBrowsing }}人学过 |
||||
</view> |
||||
<view v-if="form.labelNameList" class="labels"> |
||||
<view v-for="(label, j) in form.labelNameList" :key="j" class="label">{{ label }}</view> |
||||
</view> |
||||
<!-- <view class="meta"> |
||||
<uni-icons class="icon" type="star" size="22" color="#007eff"></uni-icons> |
||||
123 |
||||
</view> --> |
||||
</view> |
||||
|
||||
<view class="text" v-html="form.mainBody"></view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { findById } from '@/apis/modules/article.js' |
||||
export default { |
||||
data() { |
||||
return { |
||||
id: '', |
||||
form: { |
||||
totalBrowsing: '' |
||||
} |
||||
} |
||||
}, |
||||
onShow() { |
||||
const pages = getCurrentPages() |
||||
const { options } = pages[pages.length - 1] |
||||
this.id = options.id |
||||
this.getInfo() |
||||
}, |
||||
methods: { |
||||
// 获取详情 |
||||
getInfo() { |
||||
uni.showLoading({ |
||||
title: '加载中' |
||||
}) |
||||
findById(this.id).then(({ message }) => { |
||||
this.form = message |
||||
uni.hideLoading() |
||||
}).catch(e => { |
||||
uni.hideLoading() |
||||
}) |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style scoped lang="scss"> |
||||
.wrap { |
||||
padding: 30rpx; |
||||
background-color: #fff; |
||||
} |
||||
.title { |
||||
font-size: 30rpx; |
||||
font-weight: 600; |
||||
color: #333; |
||||
} |
||||
.metas { |
||||
display: flex; |
||||
justify-content: space-between; |
||||
align-items: center; |
||||
margin: 20rpx 0; |
||||
.labels { |
||||
display: inline-flex; |
||||
align-items: center; |
||||
margin: 15rpx 0; |
||||
} |
||||
.label { |
||||
padding: 2px 6px; |
||||
margin-right: 20rpx; |
||||
font-size: 24rpx; |
||||
color: #fff; |
||||
background-color: #ccc; |
||||
border-radius: 4px; |
||||
} |
||||
.meta { |
||||
display: inline-flex; |
||||
align-items: center; |
||||
} |
||||
} |
||||
.text { |
||||
font-size: 28rpx; |
||||
line-height: 1.6; |
||||
} |
||||
</style> |