mirror of
https://gitee.com/java110/PropertyApp.git
synced 2026-06-11 06:07:28 +08:00
notice done
This commit is contained in:
parent
3bfb5c1517
commit
619777f933
@ -67,6 +67,12 @@
|
|||||||
"navigationBarTitleText": "修改密码"
|
"navigationBarTitleText": "修改密码"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
,{
|
||||||
|
"path" : "pages/notice/detail/noticeDetail",
|
||||||
|
"style" : {
|
||||||
|
"navigationBarTitleText": "通知页面详情"
|
||||||
|
}
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"globalStyle": {
|
"globalStyle": {
|
||||||
"navigationBarTextStyle": "white",
|
"navigationBarTextStyle": "white",
|
||||||
|
|||||||
63
pages/notice/detail/noticeDetail.vue
Normal file
63
pages/notice/detail/noticeDetail.vue
Normal file
@ -0,0 +1,63 @@
|
|||||||
|
<template>
|
||||||
|
<view class="notice">
|
||||||
|
<view class="title"> {{notice.title}} </view>
|
||||||
|
<view class="content">
|
||||||
|
<view ><text class="ad_au_text">{{notice.context}}</text></view>
|
||||||
|
</view>
|
||||||
|
<view class="footer"> 时间: {{notice.timeStr}}</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
notice:{}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onLoad: function(options) {
|
||||||
|
let _that = this;
|
||||||
|
let index = parseInt(options.index);
|
||||||
|
// this.checkLoginStatus();
|
||||||
|
let info = JSON.parse( uni.getStorageSync('notice-'+ (index)));
|
||||||
|
if (info) {
|
||||||
|
// this.setData({
|
||||||
|
// notice: info
|
||||||
|
// })
|
||||||
|
_that.notice = info
|
||||||
|
}
|
||||||
|
uni.clearStorageSync('notice-'+index);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
.user-container {
|
||||||
|
padding: 25rpx 10rpx;
|
||||||
|
background-color: #F0F0F0;
|
||||||
|
/*border: 1px solid black;*/
|
||||||
|
}
|
||||||
|
|
||||||
|
.notice {
|
||||||
|
margin: 10rpx 7rpx;
|
||||||
|
padding: 25rpx;
|
||||||
|
background-color: #ffffff;
|
||||||
|
border-radius: 7rpx;
|
||||||
|
}
|
||||||
|
.title {
|
||||||
|
border-bottom: 1rpx solid #dedede;
|
||||||
|
font-weight: 700;
|
||||||
|
font-size: 34rpx;
|
||||||
|
color: #00AA00;
|
||||||
|
}
|
||||||
|
.content{
|
||||||
|
padding: 15rpx 0;
|
||||||
|
font-size: 25rpx;
|
||||||
|
color: #7B7B7B;
|
||||||
|
}
|
||||||
|
.footer {
|
||||||
|
padding: 15rpx 0;
|
||||||
|
font-size: 22rpx;
|
||||||
|
color: #ADADAD;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="user-container">
|
<view class="user-container">
|
||||||
<block v-for="(item,index) in notices" :key="index" wx:key="index" >
|
<block v-for="(item,index) in notices" :key="index" wx:key="index" >
|
||||||
<view class="noticesList-list">
|
<view class="noticesList-list" @tap="_toDetailHref(item,index)">
|
||||||
<view class="title"> {{item.title}} </view>
|
<view class="title"> {{item.title}} </view>
|
||||||
<view class="content">
|
<view class="content">
|
||||||
<view ><text class="ad_au_text">{{item.context}}</text></view>
|
<view ><text class="ad_au_text">{{item.context}}</text></view>
|
||||||
@ -58,8 +58,18 @@
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
},
|
||||||
|
_toDetailHref:function(_item,_index){
|
||||||
|
let that= this;
|
||||||
|
console.log("_index",_index);
|
||||||
|
let index = _index;
|
||||||
|
console.log("json==>",JSON.stringify(_item));
|
||||||
|
uni.setStorageSync('notice-'+ index, JSON.stringify(_item));
|
||||||
|
|
||||||
|
uni.navigateTo({
|
||||||
|
url:'/pages/notice/detail/noticeDetail?index=' + index
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user