作者 lihongjuan

1

{
"pages": [
"pages/register/register",
"pages/zuji/zuji",
"pages/index/index",
"pages/messagedetail/messagedetail",
"pages/message/message",
... ... @@ -28,8 +30,8 @@
"pages/taocandetail/taocandetail",
"pages/taocanpay/taocanpay",
"pages/orderdetail/orderdetail",
"pages/xianshi/xianshi",
"pages/zuji/zuji"
"pages/xianshi/xianshi"
],
"window": {
"backgroundTextStyle": "light",
... ... @@ -57,6 +59,7 @@
"iconPath": "images/tabbar/icon_70.png",
"selectedIconPath": "images/tabbar/icon_73.png"
},
{
"pagePath": "pages/my/my",
"text": "我的",
... ...

3.3 KB | 宽: | 高:

3.3 KB | 宽: | 高:

  • 两方对比
  • 交换覆盖
  • 透明覆盖
... ... @@ -28,19 +28,19 @@ Page({
},
scroll(e){
console.log(e.detail.scrollTop)
if (e.detail.scrollTop >300){
console.log(8888)
this.setData({
stick:1
})
}else{
this.setData({
stick:0
})
}
console.log(this.data.stick)
// console.log(e.detail.scrollTop)
// if (e.detail.scrollTop >300){
// console.log(8888)
// this.setData({
// stick:1
// })
// }else{
// this.setData({
// stick:0
// })
// }
// console.log(this.data.stick)
},
moremiao(){
wx.navigateTo({
... ... @@ -287,6 +287,10 @@ date_format(micro_second) {
app.post(url, params).then((res) => {
wx.hideLoading()
if (type == 1) {
let obj={
name:'首页'
}
res.msg.unshift(obj)
that.setData({
nav_arr: res.msg
})
... ...
... ... @@ -7,8 +7,27 @@
</navigator>
</view>
<view class='list' wx:if="{{nav_index!=0}}">
<view class='list_item' wx:if="{{index < length_num}}" wx:for="{{class_arr}}" wx:key="index" data-id="{{item.id}}" data-index="{{index}}" catchtap="look_item">
<view class='item'>
<view class='item_img'>
<image src='{{item.image}}' mode='aspectFill' />
</view>
<view class='item_font'>{{item.name}}</view>
</view>
</view>
<view class='list_item' data-type="1" catchtap="show_all" wx:if="{{class_arr.length>9}}">
<view class='item'>
<view class='item_img'>
<image src='/images/all.png' />
</view>
<view class='item_font'>{{length_num == 9?'查看全部':'收起'}}</view>
</view>
</view>
</view>
<!-- 轮播图 -->
<view class="lunbo_box {{stick==1?'boxactive':''}}">
<view class="lunbo_box {{nav_index==0?'boxactive':''}}" wx:else>
<swiper interval="{{interval}}" duration="{{duration}}" circular="{{circular}}" current='{{current}}' bindchange='swiperChange' autoplay="{{autoplay}}" class='swiper_box'>
<swiper-item class='swiper-item' wx:for="{{imgurl}}" wx:key="index">
<image src='{{item.image}}' mode="aspectFill" data-id="{{item.thing_id}}" data-style="{{item.style}}" data-src="{{item.thing_id}}" catchtap="{{item.thing_id == 0?'':'look_more'}}" />
... ... @@ -21,17 +40,17 @@
</view>
</view>
<!-- 劳保 -->
<view class="fenlei">
<!-- <view class="fenlei">
<view class="fenleiitem">
劳保商城
</view>
<view class="fenleiitem">
差旅
</view>
</view>
</view> -->
<!-- 活动区域 -->
<view class="actity">
<view class="miaoshatop flextwo">
<view class="miaoshatopk flextwo">
<view class="miaoshatopleft flexone">
<view class="miaoshaoname">活动专区</view>
... ... @@ -41,7 +60,7 @@
<view class="active flexone">
<view wx:for="{{activity}}" wx:key="" bindtap="seeactive" data-id="{{item.id}}">
<view wx:for="{{activity}}" class="actbox" wx:key="" bindtap="seeactive" data-id="{{item.id}}">
<view class="activeitem">
<image src="{{item.image}}"></image>
</view>
... ... @@ -56,7 +75,7 @@
<!-- 秒杀商城 -->
<view class="miaosha">
<view class="miaosha xianshi">
<view class="miaoshatop flextwo">
<view class="miaoshatopleft flexone">
<view class="miaoshaoname">限时抢购</view>
... ... @@ -72,7 +91,7 @@
<view class="goodimg">
<image src="{{item.images[0]}}"></image>
</view>
<view class="price">{{item.price}}</view>
<view class="price">{{item.price}}</view>
<!-- <view class="oldprice">{{item.price}}</view> -->
</view>
... ... @@ -97,41 +116,27 @@
</navigator>
<!-- 大分类 -->
<view class="flexone {{stick==1?'navactive':''}}">
<view class="horizontal_nav ">
<!-- {{stick==1?'navactive':''}} -->
<view class="nav_item {{nav_index == index?'active':''}}" wx:for="{{nav_arr}}" wx:key="index" bindtap="select_nav" data-index="{{index}}" data-id="{{item.id}}">{{item.name}}</view>
<view class="navactive">
<view class="flexone">
<view class="horizontal_nav ">
<view class="nav_item {{nav_index == index?'active':''}}" wx:for="{{nav_arr}}" wx:key="index" bindtap="select_nav" data-index="{{index}}" data-id="{{item.id}}">{{item.name}}</view>
</view>
<view class="morebox" bindtap="more">
<view class="moreimg">
<image src="/images/more.png"></image>
</view>
</view>
</view>
<!-- 小分类 -->
<view class='list'>
<view class='list_item' wx:if="{{index < length_num}}" wx:for="{{class_arr}}" wx:key="index" data-id="{{item.id}}" data-index="{{index}}" catchtap="look_item">
<view class='item'>
<view class='item_img'>
<image src='{{item.image}}' mode='aspectFill' />
<view class="morebox" bindtap="more">
<view class="moreimg">
<image src="/images/more.png"></image>
</view>
<view class='item_font'>{{item.name}}</view>
</view>
</view>
<view class='list_item' data-type="1" catchtap="show_all" wx:if="{{class_arr.length>9}}">
<view class='item'>
<view class='item_img'>
<image src='/images/all.png' />
</view>
<view class='item_font'>{{length_num == 9?'查看全部':'收起'}}</view>
</view>
</view>
<!-- 小分类 -->
</view>
... ...
page {
width: 100%;
height: 100%;
background: #f9f9f9;
}
image {
... ... @@ -14,8 +15,8 @@ image {
.top {
width: 750rpx;
height: 128rpx;
padding: 28rpx 32rpx;
height: 98rpx;
padding: 15rpx 32rpx;
box-sizing: border-box;
background: rgba(61, 154, 248, 1);
position: fixed;
... ... @@ -27,10 +28,10 @@ image {
.lunbo_box {
border: none !important;
background: rgba(61, 154, 248, 1);
padding: 10rpx 32rpx 0;
padding: 20rpx 32rpx 25rpx;
box-sizing: border-box;
position: relative;
margin-top: 128rpx;
margin-top: 10rpx;
}
.search_box {
... ... @@ -111,13 +112,13 @@ image {
.navactive {
position: fixed;
top: 128rpx;
top: 99rpx;
left: 0;
z-index: 999;
}
.boxactive {
margin-top: 214rpx;
margin-top: 173rpx;
}
.nav_item {
... ... @@ -132,9 +133,11 @@ image {
.list {
width: 100%;
margin-top: 36rpx;
/* margin-top: 36rpx; */
display: flex;
flex-wrap: wrap;
margin-top:195rpx;
/* background: #fff; */
}
.list_item {
... ... @@ -334,7 +337,7 @@ image {
display: flex;
align-items: center;
justify-content: space-between;
padding: 32rpx 20rpx;
padding: 32rpx 32rpx;
box-sizing: border-box;
}
... ... @@ -350,13 +353,26 @@ image {
}
.activeitem {
width: 324rpx;
width: 325rpx;
height: 200rpx;
font-size: 0;
margin-right: 20rpx;
display: flex;
justify-content: center;
align-items: center;
border-radius: 16rpx;
}
.activeitem image{
border-radius: 16rpx;
}
.actbox {
display: flex;
justify-content: center;
flex-direction: column;
align-items: center;
margin-right: 12rpx;
margin-bottom:20rpx;
}
image {
... ... @@ -371,8 +387,11 @@ image {
}
.actity {
padding: 0 32rpx;
width:750rpx;
padding: 0 0rpx 0 64rpx;
box-sizing: border-box;
margin-top:10rpx;
background: #fff;
}
.miaosha {
... ... @@ -397,7 +416,7 @@ image {
}
.miaoshatop {
padding: 32rpx;
padding: 0 32rpx 32rpx;
box-sizing: border-box;
}
... ... @@ -405,30 +424,42 @@ image {
color: rgba(61, 154, 248, 1);
font-size: 28rpx;
}
.miaoshatopk{
padding: 32rpx 0;
box-sizing: border-box
}
.miaoshalist {
display: flex;
align-items: center;
flex-wrap: wrap
}
.miaoshalistitem {
width: 222rpx;
width: 217rpx;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
margin-right: 20rpx;
padding-bottom: 20rpx;
margin-right: 12rpx;
padding-bottom: 24rpx;
box-sizing: border-box;
}
.goodimg {
width: 100rpx;
height: 100rpx;
width: 180rpx;
height: 180rpx;
font-size: 0;
border-radius: 10rpx;
}
.goodimg image{
border-radius: 10rpx;
}
.price {
width:180rpx;
text-align: center;
color: rgba(61, 154, 248, 1);
font-size: 28rpx;
margin-top: 5rpx;
... ... @@ -443,7 +474,20 @@ image {
.activename {
color: rgba(156, 156, 156, 1);
font-size: 28rpx;
text-align: center;
text-align: left;
width: 324rpx;
margin-top: 10rpx;
}
.xianshi{
width:686rpx;
border-radius: 20rpx;
margin:20rpx auto 0;
background: #fff;
padding: 32rpx 0;
box-sizing: border-box
}
.topnav{
position: fixed;
top:0;
left:0
}
\ No newline at end of file
... ...
... ... @@ -93,6 +93,11 @@ Page({
wx.navigateTo({
url: '/pages/address/address',
})
} else if (index == 6) {
// 跳转地址列表
wx.navigateTo({
url: '/pages/zuji/zuji',
})
}
} else if (wx.getStorageSync("token") && index == 5) {
// 跳转关于列表
... ...
... ... @@ -104,6 +104,16 @@
</view>
<image src="/images/youjiantou.png" class="youjiantou" />
</view>
<view class="item" bindtap="jumpListFun" data-t="6">
<view class="left">
<view class="zujiimg">
<image src="/images/zuji.png" />
</view>
我的足迹
</view>
<image src="/images/youjiantou.png" class="youjiantou" />
</view>
<view class="item" bindtap="jumpListFun" data-t="4">
<view class="left">
<image src="/images/icon_32.png" style="width:26rpx;height:30rpx;" />我的地址
... ...
... ... @@ -145,6 +145,7 @@ page {
background: #fff;
padding: 0 30rpx;
box-sizing: border-box;
margin-bottom:150rpx;
}
.item {
... ... @@ -261,3 +262,15 @@ image {
.wuliustate {
width: 120rpx;
}
.zujiimg{
display:flex;
align-items: center;
justify-content: center;
}
.zujiimg image{
width:33rpx!important;
height:35rpx!important;
}
\ No newline at end of file
... ...
... ... @@ -12,7 +12,8 @@ Page({
dday:'',
hou:'',
min:'',
sec:''
sec:'',
showtime:false
},
... ... @@ -20,8 +21,15 @@ Page({
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
let that=this;
this.getxianshi();
this.getxianshik()
setTimeout(function(){
that.setData({
showtime: true
})
},1000)
},
... ... @@ -42,6 +50,7 @@ Page({
// status: r.msg.status,
endTime: r.msg.residue_time,
})
... ...
<view class="miaoshatime flexthree">
<view class="miaoshatime flexthree" wx:if="{{showtime==true}}">
<view class='miaoname'>距离开始</view>
<view class='miaotime miaohour boxsizing'>{{day}}</view>
<view class="miaoname">天</view>
... ...
... ... @@ -28,14 +28,7 @@ Page({
wx.navigateTo({
url: '/pages/shop_detail/shop_detail?id=' + id
})
// let style = e.currentTarget.dataset.style
// if (style == 2) {
// wx.navigateTo({
// url: '/pages/outerChain/outerChain?src=' + e.currentTarget.dataset.src
// })
// } else {
// }
},
getmorelist(){
... ...
... ... @@ -89,13 +89,12 @@ page {
width: 100%;
height: 100%;
}
.empty {
font-size: 36rpx;
font-family: PingFang SC;
font-weight: 400;
color: #ccc;
margin-top: 200rpx;
margin: 200rpx auto 0;
text-align: center;
}
.real_goods {
... ...
// pages/zuji/zuji.js
const app=getApp()
Page({
/**
* 页面的初始数据
*/
data: {
zujilist:[],
page:1,
pageNum:10
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getzujilist()
},
getzujilist(){
let that = this
let url = '/getopenid/product_view_log';
let data = {
}
app.post(url, data, "POST").then((r) => {
console.log(r)
that.setData({
zujilist: r.msg
})
console.log(that.data.zujilist)
}).catch((err) => { })
},
//轮播图
look_more(e) {
let id = e.currentTarget.dataset.id;
console.log(id)
wx.navigateTo({
url: '/pages/shop_detail/shop_detail?id=' + id
})
},
... ...
<!--pages/zuji/zuji.wxml-->
<text>pages/zuji/zuji.wxml</text>
<view class='page'>
<!-- 商品列表 -->
<view class='real_goods'>
<!-- <Model_item list="{{shop_arr}}" /> -->
<view class='real_goods' wx:if="{{zujilist.length>0}}">
<view class="real_goods_item" wx:for="{{zujilist}}" wx:key="index" data-id="{{item.product_id}}" bindtap="{{item.sold==0?'':'look_more'}}">
<view class='real_goods_img'>
<image src='{{item.images[0]}}' mode="aspectFill" />
<image src='/images/mei.png' class="tip" wx:if="{{item.sold == 0}}" />
</view>
<view class='real_goods_bottom'>
<view class='goods_title'>{{item.name}}</view>
<view class='goods_flex'>
<view class='score'>积分</view>
<view class='price'>{{item.price}}</view>
<view class='sell'>已卖出{{item.paynum}}件</view>
</view>
</view>
<view class="pink_cover" wx:if="{{item.sold == 0}}"/>
</view>
</view>
<view class="empty" wx:else>暂无更多数据</view>
</view>
</view>
\ No newline at end of file
... ...
/* pages/zuji/zuji.wxss */
\ No newline at end of file
page {
width: 100%;
height: 100%;
background: #f9f9f9;
}
.page {
width: 100%;
min-height: 100%;
}
.horizontal_nav {
width: 100%;
white-space: nowrap;
overflow-x: scroll;
height: 88rpx;
background: rgba(61, 154, 248, 1);
line-height: 88rpx;
font-size: 28rpx;
font-family: PingFang SC;
font-weight: 400;
color: rgba(174, 214, 255, 1);
padding: 0 12rpx;
box-sizing: border-box;
}
.horizontal_nav::-webkit-scrollbar {
display: none;
}
.nav_item {
padding: 0 40rpx;
box-sizing: border-box;
display: inline-block;
}
.nav_item.active {
color: #fff;
}
.select_box {
height: 88rpx;
width: 100%;
background: #fff;
padding: 0 98rpx;
box-sizing: border-box;
display: flex;
align-items: center;
justify-content: space-between;
}
.select_item {
font-size: 28rpx;
font-family: PingFang SC;
font-weight: 400;
line-height: 40rpx;
color: rgba(156, 156, 156, 1);
position: relative;
}
.select_item.active {
color: rgba(61, 154, 248, 1);
}
.select_item.active::after {
content: '';
width: 100%;
height: 4rpx;
border-radius: 4rpx 4rpx 0 0;
background: rgba(61, 154, 248, 1);
position: absolute;
bottom: -20rpx;
left: 0;
}
.select_img {
height: 22rpx;
width: 10rpx;
position: absolute;
right: -14rpx;
top: 50%;
transform: translateY(-50%);
display: flex;
justify-content: center;
align-items: center;
}
.select_img image {
width: 100%;
height: 100%;
}
.empty {
font-size: 36rpx;
font-family: PingFang SC;
font-weight: 400;
color: #ccc;
margin: 200rpx auto 0;
text-align: center;
}
.real_goods {
width: 708rpx;
margin: 0 auto;
background: #f9f9f9;
display: flex;
flex-wrap: wrap;
padding: 8rpx 11rpx 20rpx;
box-sizing: border-box;
}
.real_goods_item {
width: 50%;
margin-top: 20rpx;
border-radius: 10rpx;
background: #fff;
overflow: hidden;
position: relative;
}
.real_goods_img {
width: 332rpx;
height: 332rpx;
margin-bottom: 16rpx;
border-top-left-radius: 10rpx;
border-top-right-radius: 10rpx;
overflow: hidden;
position: relative;
}
.real_goods_img image {
width: 100%;
height: 100%;
}
.tip {
width: 87rpx !important;
height: 80rpx !important;
position: absolute;
right: 0;
top: 0;
z-index: 2;
}
.real_goods_bottom {
padding: 16rpx 16rpx 28rpx 16rpx;
box-sizing: border-box;
background: #fff;
}
.goods_title {
height: 72rpx;
font-size: 26rpx;
font-family: PingFang SC;
font-weight: 500;
line-height: 36rpx;
color: rgba(5, 9, 26, 1);
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
margin-bottom: 20rpx;
}
.goods_flex {
height: 50rpx;
display: flex;
align-items: center;
}
.score {
width: 64rpx;
height: 32rpx;
background: rgba(242, 0, 0, 1);
border-radius: 2rpx;
text-align: center;
color: #fff;
font-size: 22rpx;
font-family: PingFang SC;
font-weight: 400;
margin-right: 12rpx;
}
.price {
font-size: 36rpx;
font-family: PingFang SC;
font-weight: bold;
color: rgba(242, 0, 0, 1);
margin-right: 20rpx;
}
.sell {
font-size: 20rpx;
font-family: PingFang SC;
font-weight: 400;
color: rgba(156, 156, 156, 1);
}
.pink_cover{
width: 100%;
height: 100%;
background: #ccc;
opacity: 0.3;
position: absolute;
left: 0;
top: 0;
}
\ No newline at end of file
... ...
... ... @@ -54,7 +54,7 @@
"list": []
},
"miniprogram": {
"current": 6,
"current": 8,
"list": [
{
"id": 0,
... ... @@ -105,6 +105,20 @@
"id": -1,
"name": "活动套餐",
"pathName": "pages/search/search_result/search_result",
"query": "",
"scene": null
},
{
"id": -1,
"name": "足迹",
"pathName": "pages/zuji/zuji",
"query": "",
"scene": null
},
{
"id": -1,
"name": "首页",
"pathName": "pages/index/index",
"scene": null
}
]
... ...