Commit 12c189d1 by 尹烁恒

完成开发

parent 8fcec1c1
......@@ -36,6 +36,12 @@
"name": "counter",
"pathName": "pages/counter/main",
"query": ""
},
{
"id": -1,
"name": "result",
"pathName": "pages/logs/main",
"query": ""
}
]
}
......
......@@ -31,7 +31,7 @@
scroll-y>
<div class="content-wrapper">
<div class="item-cell" v-for="(item, itemIndex) in itemList" :key="itemIndex" @click="handleItemCell(itemIndex)">
<!-- <img class="item-cell-image" src="../../assets/img/sel_box.png" :style="{ display: item.is_active ? 'none' : 'block'} "/> -->
<img class="item-cell-image" src="../../assets/img/sel_box.png" :style="{ display: item.is_active ? 'none' : 'block'} "/>
<img class="item-cell-image" src="../../assets/img/sel_box_sel.png" :style="{ display: item.is_active ? 'block' : 'none'} "/>
<img :src="item.img" class="item-img" mode="aspectFit" :lazy-load="true"/>
<text class="item-text" :style="{color: item.is_active ? '#fff' : '#282828'}">{{item.name}}</text>
......@@ -173,6 +173,11 @@ export default {
})
console.log(array, 'submit array')
console.log(JSON.stringify(array), 'json stringify array')
this.initData()
wx.redirectTo({
url: '/pages/logs/main'
})
this.initData()
},
// 获取详情
fetchDetail(brand = '', page = 1) {
......
<template>
<div class="index-page">
<img src="../../assets/img/index-bg.jpg" class="index-bg"/>
<img src="../../assets/img/index-bg-cover.jpg" class="index-bg-cover" />
<img src="../../assets/img/index-bg-cover.png" class="index-bg-cover" />
<img src="../../assets/img/index-start-button.jpg" class="index-start-button" @click="handleStart"/>
<img src="../../assets/img/btn-more.png" class="btn-more"/>
</div>
</template>
......@@ -59,6 +60,7 @@ export default {
height: 100vh;
background: #c9baa8;
text-align: center;
padding: 30rpx 0 0;
}
.index-bg {
position: absolute;
......@@ -66,25 +68,24 @@ export default {
height: 100%;
top: 0;
left: 0;
z-index: 1;
}
.index-bg-cover {
position: absolute;
position: relative;
width: 659rpx;
height: 798rpx;
top: 30rpx;
left: 50%;
transform: translate3d(-50%, 0 ,0);
z-index: 2;
z-index: 1;
}
.index-start-button {
position: absolute;
position: relative;
width: 489rpx;
height: 123rpx;
bottom: 180rpx;
left: 50%;
transform: translate3d(-50%, 0, 0);
z-index: 3;
margin: 50rpx 0 30rpx;
}
.btn-more {
position: relative;
width: 489rpx;
height: 123rpx;
z-index: 4;
}
</style>
<template>
<div>
<ul class="container log-list">
<li v-for="(log, index) in logs" :class="{ red: aa }" :key="index" class="log-item">
<card :text="(index + 1) + ' . ' + log"></card>
</li>
</ul>
<img src="../../assets/img/log-bg.jpg" class="log-bg"/>
<div class="fixed">
<ul class="list-container">
<li class="list-item">
<img src="../../assets/img/ic_zhuanfa.png" mode="widthFix"/><text class="text-zhuanfan">发送给朋友</text>
<button open-type="share" class="btn-share"></button>
</li>
<li class="list-item"><img src="../../assets/img/ic_share.png" mode="widthFix"/><text class="text-share">生成分享图</text></li>
<li class="list-item"><img src="../../assets/img/re_sel.png" mode="widthFix"/></li>
</ul>
</div>
</div>
</template>
<script>
import { formatTime } from '@/utils/index'
import card from '@/components/card'
export default {
onShareAppMessage() {
return {
title: '我的手机',
path: '/page/index/main'
}
},
components: {
card
},
data () {
return {
logs: []
}
},
created () {
const logs = (wx.getStorageSync('logs') || [])
this.logs = logs.map(log => formatTime(new Date(log)))
}
}
</script>
<style>
.log-list {
display: flex;
flex-direction: column;
padding: 40rpx;
<style lang="scss">
.fixed {
position: fixed;
bottom: 0;
left: 0;
width: 100%;
height: 180rpx;
background: rgba(#000, 0.7);
z-index: 100;
}
.log-bg {
position: absolute;
width: 100%;
height: 100%;
top: 0;
left: 0;
z-index: 1;
}
.list-container {
width: 100%;
height: 100%;
display: flex;
flex-flow: row nowrap;
align-items: center;
.log-item {
margin: 10rpx;
.list-item {
position: relative;
flex: 1;
display: flex;
flex-flow: column nowrap;
align-items: center;
padding: 20rpx 0;
font-size: 28rpx;
&:not(:last-child) {
border-right: 2rpx dashed #ddd1be;
}
&:first-child {
color: #ffde5e;
}
&:nth-child(2) {
color: #38eb95;
}
img {
width: 67rpx;
margin-bottom: 16rpx;
}
}
}
.btn-share {
position: absolute;
opacity: 0;
width: 100%;
height: 100%;
z-index: 1;
}
</style>
......@@ -3,9 +3,3 @@ import App from './index'
const app = new Vue(App)
app.$mount()
export default {
config: {
navigationBarTitleText: '查看启动日志'
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment