作者 吴孟雨

拼单页,搜索页,搜索结果页

... ... @@ -33,6 +33,20 @@ App({
}
})
},
//获取当前日期
nowDate() {
let date = new Date();
let month = date.getMonth() + 1;
let day = date.getDate();
// let hours = date.getHours();
// let minutes = date.getMinutes();
let Y = date.getFullYear() + '-' + (month > 9 ? month : ('0' + month)) + '-' + (day > 9 ? day : ('0' + day));
// let H = (hours>9?hours:('0'+hours)) + ':' +(minutes>9?minutes:('0'+minutes));
let time = [];
time.push(Y);
// let new_time = time.join(' ');
return time;
},
globalData: {
userInfo: null
}
... ...
{
"pages":[
"pages": [
"pages/spell-list/spell-list",
"pages/index/index",
"pages/logs/logs"
"pages/logs/logs",
"pages/order/order",
"pages/my/my",
"pages/search/search"
],
"window":{
"backgroundTextStyle":"light",
"window": {
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#fff",
"navigationBarTitleText": "WeChat",
"navigationBarTextStyle":"black"
"navigationBarTextStyle": "black"
}
}
}
\ No newline at end of file
... ...
... ... @@ -2,11 +2,11 @@
@font-face {font-family: "iconfont";
src: url('//at.alicdn.com/t/font_961048_ey8uu8eyju6.eot?t=1544523215072'); /* IE9*/
src: url('//at.alicdn.com/t/font_961048_ey8uu8eyju6.eot?t=1544523215072#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('data:application/x-font-woff;charset=utf-8;base64,d09GRgABAAAAAASkAAsAAAAABvgAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABHU1VCAAABCAAAADMAAABCsP6z7U9TLzIAAAE8AAAARAAAAFY8dkgvY21hcAAAAYAAAABUAAABhmU+0M1nbHlmAAAB1AAAANgAAADYbiAdb2hlYWQAAAKsAAAALwAAADYTiqGcaGhlYQAAAtwAAAAcAAAAJAfeA4RobXR4AAAC+AAAAAwAAAAMDAAAAGxvY2EAAAMEAAAACAAAAAgAFABsbWF4cAAAAwwAAAAfAAAAIAERAD5uYW1lAAADLAAAAUUAAAJtPlT+fXBvc3QAAAR0AAAALgAAAD+v3CrleJxjYGRg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T/c4UBAvTPXFO6stJ5Ok+BPV8bUnV0K27LnpQ0kV7NSRKyQl7WtlRC6gE2ZVeOEXpc0Yk/KGdI/wAJWm7IAAAAeJxjYGKAAC4G7ICZkYmRmZGFgSuxqCi/XDclvzyPIyc/ObEkMz+PgQEAXj4HlwAA') format('woff'),
url('//at.alicdn.com/t/font_961048_ey8uu8eyju6.ttf?t=1544523215072') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
url('//at.alicdn.com/t/font_961048_ey8uu8eyju6.svg?t=1544523215072#iconfont') format('svg'); /* iOS 4.1- */
src: url('//at.alicdn.com/t/font_961048_s4pm998br9.eot?t=1545469706627'); /* IE9*/
src: url('//at.alicdn.com/t/font_961048_s4pm998br9.eot?t=1545469706627#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('data:application/x-font-woff;charset=utf-8;base64,d09GRgABAAAAAAW8AAsAAAAACEQAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABHU1VCAAABCAAAADMAAABCsP6z7U9TLzIAAAE8AAAARAAAAFY8dkgvY21hcAAAAYAAAABdAAABnLOMGw1nbHlmAAAB4AAAAdEAAAH8ozr8/mhlYWQAAAO0AAAALwAAADYTp4QZaGhlYQAAA+QAAAAcAAAAJAfeA4VobXR4AAAEAAAAAA4AAAAQEAAAAGxvY2EAAAQQAAAACgAAAAoBEgBsbWF4cAAABBwAAAAfAAAAIAETAGluYW1lAAAEPAAAAUUAAAJtPlT+fXBvc3QAAAWEAAAAOAAAAEkByYdDeJxjYGRgYOBikGPQYWB0cfMJYeBgYGGAAJAMY05meiJQDMoDyrGAaQ4gZoOIAgCKIwNPAHicY2BkYWCcwMDKwMHUyXSGgYGhH0IzvmYwYuRgYGBiYGVmwAoC0lxTGByeMTyzZW7438AQw9zA0AAUZgTJAQDhrAwgeJztkLENgDAMBM9JQBFCyiKUiC7LpGLyrBEcm4IheOss+2W5eGABonIoCeRGmGrqivmRzfzEpXvWCtDppdcxvpNJ7CLrFPyDrPzar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t0uqca1vEJlODoF9JU51pW91T7NdD5yIVWZOqCas6SYzKrdnq0AUb5/JRrxeJHoQm5Vhj/rbGAo5xBYUlDowxQhhkiMro6DtVZvSvsUPCXntWPc3ndFsU1P9zhQEC9M9cU7qy0nk6T4E9XxtSdXQrbsuelDSRXs1JErJCXta2VELqATZlV44RelzRiT8oZ0j/AAlabsgAAAB4nGNgYoAALgbsgIWRiZGZkYWRlYErsagov1w3Jb88jyMnPzmxJDM/j704IzEvOaOUgQEArdEKjw==') format('woff'),
url('//at.alicdn.com/t/font_961048_s4pm998br9.ttf?t=1545469706627') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
url('//at.alicdn.com/t/font_961048_s4pm998br9.svg?t=1545469706627#iconfont') format('svg'); /* iOS 4.1- */
}
.iconfont {
... ... @@ -21,4 +21,7 @@
.icon-location:before { content: "\e600"; }
.icon-shanchu:before { content: "\e60f"; }
... ...
const notice = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABAEAYAAAD6+a2dAAAABGdBTUEAALGPC/xhBQAAAAFzUkdCAK7OHOkAAAAgY0hSTQAAeiYAAICEAAD6AAAAgOgAAHUwAADqYAAAOpgAABdwnLpRPAAAAAZiS0dEAAAAAAAA+UO7fwAAAAlwSFlzAAAASAAAAEgARslrPgAAEChJREFUeNrtnHlcVHX3xz/nDjAD5kK45IKmAyiW5JIB7lba83PPAE0zlBRlVVBRe7TcMtxQR4FENBSTUh9w7wk1ccUtMssdJJfsUdFyYy7L3PP7Q4bf7yVc7iCOoz7z/g/uuZ97vvd75t7zPd/v9wJWrFixYsWKFStWrLyosOTr03K9nZ3+elA9rdrfX6wWHO2iW71aHxX0s/Z0XNyDB0FBWm27dpb282lDlnbA3Bg7VkiiGLq5Zg0CMB51W7YsY5iLFI4pLuZFHI0Zvr4OK+JH5/y0aZOl/Tc3L2wA6GOCr7nohg6FG85jW2Ii3sF6XNRoFE/8FtV5z5kz9iPi5uY4lxMoLxgvTAAwf86A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MQJU6uk3ZAKjacFXr6pRyAdClwbrU6UeZAOjaUF3rJqEHQPcG6r4O/DTM8nXhx6GWrzOwAOjSENvWLX0zyGvAK15yk6WSag2Qre0bU5o2neqDubHYQiIhuz7pAfAefmTpdiuhddE6/YLg7orzTqNQkF1XeNvBlgy+WdtBCOgZQdLRY+IOo9k/8XSt9ldkb8Zfbm0FdYpTHfWhuT/e4/UAAAAAAAAAAAAAAADO4D9cvzD+Ik3LBAAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAxOC0wNy0yOFQyMjo1MjoyMiswODowMMq1zi4AAAAldEVYdGRhdGU6bW9kaWZ5ADIwMTgtMDctMjhUMjI6NTI6MjIrMDg6MDC76HaSAAAASHRFWHRzdmc6YmFzZS11cmkAZmlsZTovLy9ob21lL2FkbWluL2ljb24tZm9udC90bXAvaWNvbl83NW1saHp1bGx3NS9jbG9zZS5zdmcxNhK3AAAAAElFTkSuQmCC'
Component({
externalClasses: ['wux-class'],
options: {
multipleSlots: true,
},
properties: {
icon: {
type: String,
value: notice,
},
content: {
type: String,
value: '',
},
mode: {
type: String,
value: '',
},
action: {
type: String,
value: close,
},
loop: {
type: Boolean,
value: false,
},
leading: {
type: Number,
value: 500,
},
trailing: {
type: Number,
value: 800,
},
speed: {
type: Number,
value: 25,
},
},
data: {
animatedWidth: 0,
overflowWidth: 0,
visible: true,
},
methods: {
clearMarqueeTimer() {
if (this.marqueeTimer) {
clearTimeout(this.marqueeTimer)
this.marqueeTimer = null
}
},
startAnimation() {
this.clearMarqueeTimer()
const { overflowWidth, loop, leading, trailing, speed } = this.data
const isLeading = this.data.animatedWidth === 0
const timeout = isLeading ? leading : speed
const animate = () => {
let animatedWidth = this.data.animatedWidth + 1
const isRoundOver = animatedWidth > overflowWidth
// 判断是否完成一次滚动
if (isRoundOver) {
if (!loop) {
return false
}
// 重置初始位置
animatedWidth = 0
}
// 判断是否等待一段时间后进行下一次滚动
if (isRoundOver && trailing) {
setTimeout(() => {
this.setData({
animatedWidth,
})
this.marqueeTimer = setTimeout(animate, speed)
}, trailing)
} else {
this.setData({
animatedWidth,
})
this.marqueeTimer = setTimeout(animate, speed)
}
}
if (this.data.overflowWidth !== 0) {
this.marqueeTimer = setTimeout(animate, timeout)
}
},
initAnimation() {
const query = wx.createSelectorQuery().in(this)
query.select('.wux-notice-bar__marquee-container').boundingClientRect()
query.select('.wux-notice-bar__marquee').boundingClientRect()
query.exec((rects) => {
if (rects.filter((n) => !n).length) {
return false
}
const [container, text] = rects
const overflowWidth = text.width - container.width
if (overflowWidth !== this.data.overflowWidth) {
this.setData({ overflowWidth }, this.startAnimation)
}
})
},
onAction() {
if (this.data.mode === 'closable') {
this.clearMarqueeTimer()
this.setData({
visible: false
})
}
this.triggerEvent('click')
},
onClick() {
this.triggerEvent('click')
},
},
ready() {
this.initAnimation()
},
detached() {
this.clearMarqueeTimer()
},
})
\ No newline at end of file
... ...
{
"component": true
}
\ No newline at end of file
... ...
<view class="wux-class wux-notice-bar" wx:if="{{ visible }}" bindtap="onClick">
<view class="wux-notice-bar__hd">
<image class="wux-notice-bar__icon" src="{{ icon }}" wx:if="{{ icon }}" />
<block wx:else>
<slot name="header"></slot>
</block>
</view>
<view class="wux-notice-bar__bd">
<view class="wux-notice-bar__marquee-container">
<view class="wux-notice-bar__marquee" style="transform: translate3d({{ -animatedWidth + 'px' }}, 0px, 0px)">
<block wx:if="{{ content }}">{{ content }}</block>
<slot></slot>
</view>
</view>
</view>
<view class="wux-notice-bar__ft" catchtap="onAction" wx:if="{{ mode === 'closable' || mode === 'link' }}">
<image class="wux-notice-bar__action" src="{{ action }}" wx:if="{{ action }}" />
<block wx:else>
<slot name="footer"></slot>
</block>
</view>
</view>
\ No newline at end of file
... ...
.wux-notice-bar {
background-color: #fefcec;
height: 72rpx;
overflow: hidden;
font-size: 28rpx;
line-height: 72rpx;
color: #f76a24;
display: -webkit-box;
display: -webkit-flex;
display: flex;
padding: 0 20rpx;
}
.wux-notice-bar__icon {
width: 30rpx;
height: 30rpx;
margin-right: 20rpx;
}
.wux-notice-bar__action {
width: 30rpx;
height: 30rpx;
margin-left: 20rpx;
}
.wux-notice-bar__hd {
display: -webkit-box;
display: -webkit-flex;
display: flex;
-webkit-box-align: center;
-webkit-align-items: center;
align-items: center;
}
.wux-notice-bar__bd {
-webkit-box-flex: 1;
-webkit-flex: 1;
flex: 1;
width: 100%;
width: auto;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.wux-notice-bar__marquee-container {
overflow: hidden;
}
.wux-notice-bar__marquee {
position: relative;
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
white-space: nowrap;
display: inline-block;
}
.wux-notice-bar__ft {
display: -webkit-box;
display: -webkit-flex;
display: flex;
-webkit-box-align: center;
-webkit-align-items: center;
align-items: center;
}
... ...
... ... @@ -21,11 +21,25 @@ Page({
],
banner: [{image: '../../images/banner.png'}, {image: '../../images/b1@2x (1).png'}, {image: '../../images/b1@2x (2).png'}, {image: '../../images/banner.png'}],
currentBannerIndex:0,
tabcurrent: {tab: 0,bubble: ''},
noticeList:[{url:'',name:'奥拉维尔·埃利亚松北京首展 https://github.com/wux-weapp/wux-weapp'}],
motto: 'Hello World',
userInfo: {},
hasUserInfo: false,
canIUse: wx.canIUse('button.open-type.getUserInfo')
},
onClick() {
wx.navigateTo({
url: '/pages/search/search',
})
},
//搜索
search() {
wx.navigateTo({
url: '/pages/search/search',
})
},
bannerChange(e){
// console.log(e,'current', current);
const current = e.detail.current;
... ... @@ -60,4 +74,88 @@ Page({
console.log('refresh completed,加载更多')
})
},
//首页-导航
service(e) {
var tindex = e.currentTarget.dataset.tindex;
var tabcurrent = this.data.tabcurrent;
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
wx.redirectTo({
url: '/pages/index/index',
})
}
},
//拼单-导航
consult(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
// wx.showToast({
// title: '该功能正在开发中',
// icon: 'none'
// })
wx.redirectTo({
url: '/pages/spell-list/spell-list',
})
}
},
//发布按钮
release(e) {
let that = this;
that.setData({
releasepopup: true
})
},
//取消发布弹窗
cancelPopup() {
let that = this;
that.setData({
releasepopup: false
})
},
//订单-导航
wish(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
// wx.showToast({
// title: '该功能正在开发中',
// icon: 'none'
// })
wx.redirectTo({
url: '/pages/order/order',
})
}
},
//我的-导航
my(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
wx.redirectTo({
url: '/pages/my/my',
})
}
},
})
... ...
{
"navigationBarTitleText": "火柴西路",
"enablePullDownRefresh": false,
"usingComponents": {
"masonry": "../components/masonry/masonry",
"img-box": "../components/img-box/img-box"
}
"enablePullDownRefresh": false,
"usingComponents": {
"masonry": "../components/masonry/masonry",
"img-box": "../components/img-box/img-box",
"wux-notice-bar": "../../dist/notice-bar/index"
}
}
\ No newline at end of file
... ...
... ... @@ -8,8 +8,8 @@
<text>北京</text>
<view class="iconfont icon-arrow-down"></view>
</view>
<view class="right">
<input type="text"/>
<view class="right" bindtap="search">
<view class="input"></view>
<view class="iconfont icon-arrow-down"></view>
</view>
</view>
... ... @@ -37,7 +37,12 @@
<view class="area-box">
<image src="../../images/haowai@2x.png"></image>
<text>奥拉维尔·埃利亚松北京首展</text>
<!--<text>奥拉维尔·埃利亚松北京首展</text>-->
<view wx:for="{{noticeList}}" wx:key="index">
<wux-notice-bar mode="link" icon="" action="" content="{{item.name}}" bind:click="onClick">
<!--<text slot="footer" style="color: #a1a1a1; margin-left: 10px;">去看看</text>-->
</wux-notice-bar>
</view>
</view>
<view class="tandian-box">
... ... @@ -51,7 +56,7 @@
</view>
</view>
<!--swiper-->
<!--banner-->
<view class='people_box rel bb1'>
<!--<scroll-view scroll-x class='scroll_view'>-->
<!--<view class="people_list_box">-->
... ... @@ -62,13 +67,14 @@
<!--</view>-->
<!--</view>-->
<!--</scroll-view>-->
<swiper class="bannerBox" autoplay="false" interval="3000" duration="1000" indicator-dots="true"
<swiper class="bannerBox" autoplay="true" interval="3000" duration="2000"
previous-margin="50rpx" next-margin="50rpx" bindchange="bannerChange" current="{{index}}">
<block wx:for="{{banner}}" wx:key="index">
<swiper-item>
<div class="fix pl5 pr5 box_bb">
<!--<navigator url="">-->
<image class="banner mt10 {{currentBannerIndex==index?'active':''}}" src="{{item.image}}" mode="aspectFill" />
<text>Opera Bombana 2018.4.28</text>
<!--</navigator>-->
</div>
</swiper-item>
... ... @@ -89,6 +95,10 @@
<view class="masonry-box">
<masonry generic:masonry-item="img-box" id="masonry" interval-width="20rpx"></masonry>
</view>
<!--底部tab-->
<import src="/templates/templates.wxml" />
<template is="tabBar" data='{{...tabcurrent}}' />
<!--swiper-->
<!--<view class="banner-box">-->
<!--<swiper indicator-dots="{{true}}"-->
... ...
/**index.wxss**/
@import "../../templates/templates.wxss";
.userinfo {
display: flex;
flex-direction: column;
... ... @@ -68,7 +69,7 @@
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.position input {
.position .input {
color: #ffffff;
padding-left: 20rpx;
font-size: 28rpx;
... ... @@ -276,7 +277,16 @@ swiper {
/*banner start*/
.bannerBox{
height: 208px;
height: 383rpx;
}
.bannerBox text {
width: 100%;
display: block;
line-height: 60rpx;
padding: 0 14rpx;
text-align: left;
color:#333333;
font-size: 24rpx;
}
.banner{
overflow: hidden;
... ... @@ -293,19 +303,20 @@ swiper {
.bannerDots{
width: 100%;
left: 0;
bottom: 40px;
bottom: 100rpx;
height: 6px;
}
.dot{
width: 6px;
height: 6px;
width: 8px;
height: 8px;
margin: 0 3px;
border-radius: 3px;
background-color: #fff;
border-radius: 50%;
background: rgba(255,255,255,.3);
opacity: 0.3;
}
.dot.active{
width: 15px;
background-color: #7090E8;
opacity: 1;
background-color: #FEE2BB;
}
.fix {
zoom: 1;
... ... @@ -322,6 +333,8 @@ swiper {
padding-right: 5px;
}
.box_bb {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.flex_c {
... ...
// pages/my/my.js
Page({
/**
* 页面的初始数据
*/
data: {
tabcurrent: {tab: 4,bubble: ''},
},
//首页-导航
service(e) {
var tindex = e.currentTarget.dataset.tindex;
var tabcurrent = this.data.tabcurrent;
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
wx.redirectTo({
url: '/pages/index/index',
})
}
},
//拼单-导航
consult(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
// wx.showToast({
// title: '该功能正在开发中',
// icon: 'none'
// })
wx.redirectTo({
url: '/pages/spell-list/spell-list',
})
}
},
//发布按钮
release(e) {
let that = this;
that.setData({
releasepopup: true
})
},
//取消发布弹窗
cancelPopup() {
let that = this;
that.setData({
releasepopup: false
})
},
//订单-导航
wish(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
// wx.showToast({
// title: '该功能正在开发中',
// icon: 'none'
// })
wx.redirectTo({
url: '/pages/order/order',
})
}
},
//我的-导航
my(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
wx.redirectTo({
url: '/pages/my/my',
})
}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{}
\ No newline at end of file
... ...
<!--pages/my/my.wxml-->
<!--底部tab-->
<import src="/templates/templates.wxml" />
<template is="tabBar" data='{{...tabcurrent}}' />
... ...
/* pages/my/my.wxss */
@import "../../templates/templates.wxss";
... ...
// pages/order/order.js
Page({
/**
* 页面的初始数据
*/
data: {
tabcurrent: {tab: 3,bubble: ''},
},
//首页-导航
service(e) {
var tindex = e.currentTarget.dataset.tindex;
var tabcurrent = this.data.tabcurrent;
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
wx.redirectTo({
url: '/pages/index/index',
})
}
},
//拼单-导航
consult(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
// wx.showToast({
// title: '该功能正在开发中',
// icon: 'none'
// })
wx.redirectTo({
url: '/pages/spell-list/spell-list',
})
}
},
//发布按钮
release(e) {
let that = this;
that.setData({
releasepopup: true
})
},
//取消发布弹窗
cancelPopup() {
let that = this;
that.setData({
releasepopup: false
})
},
//订单-导航
wish(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
// wx.showToast({
// title: '该功能正在开发中',
// icon: 'none'
// })
wx.redirectTo({
url: '/pages/order/order',
})
}
},
//我的-导航
my(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
wx.redirectTo({
url: '/pages/my/my',
})
}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{}
\ No newline at end of file
... ...
<!--pages/order/order.wxml-->
<!--底部tab-->
<import src="/templates/templates.wxml" />
<template is="tabBar" data='{{...tabcurrent}}' />
... ...
/* pages/order/order.wxss */
@import "../../templates/templates.wxss";
... ...
// pages/service/renting/search/search.js
const app = getApp();
Page({
/**
* 页面的初始数据
*/
data: {
searchValue: '',
postList: [],
searchHistory:[{keyword:'法国巴黎'},{keyword:'埃菲尔铁塔'},{keyword:'北京'},{keyword:'西雅图'},{keyword:'美国洛杉矶'},{keyword:'北京'},{keyword:'北京'},{keyword:'北京'},],
currentModal: 0,
currentPost: 0,
hidden_img: false,
hasMore: true,
pageNumber: 0,
avatar: [],
},
//初始化postList
initPostList() {
this.setData({
pageNumber: 0,
hasMore: true,
});
this.data.postList = []
},
inputFocus() {
this.setData({postList:[]})
},
//输入搜索内容
inputKey(e) {
this.setData({searchValue: e.detail.value})
},
//点击搜索(搜索结果)
startSearch() {
let self = this;
if(!self.data.hasMore) return;
self.setData({hasMore: false});
let url = '/home/home/search';
let params = {
keyword: self.data.searchValue,
page: self.data.pageNumber,
};
let header = {
"XX-Token": wx.getStorageSync('token')
};
if(self.data.searchValue === '') {
wx.showToast({title:'搜索内容不能为空~',icon: 'none'})
}else {
self.getSearchHistory();
app.post(url, params, header).then((res) => {
// console.log('搜索结果', res);
if(+res.page < res.page_size) {
self.data.hasMore = true;
}
const list = res.data.map((item, index) => {
return {...item, showlabel_box: false, more: item.more !== '' ? JSON.parse(item.more) : ''}
});
self.setData({
postList: self.data.postList.concat(list)
});
// console.log('搜索结果', self.data.postList);
})
}
},
//点击量
hit(current) {
let url = '/home/home/hits';
let params = {
id: this.data.postList[current].id,
};
let header = { "XX-Token": wx.getStorageSync('token') };
app.post(url, params, header).then((res) => {
// console.log('点击量',res);
if(res.message == "操作成功") {
const post_hits = this.data.postList[current].post_hits +1
this.setData({
[`postList[${current}].post_hits`]: post_hits
});
}
})
},
//清空输入框
clearInput() {
this.setData({searchValue: ''})
},
//搜索历史列表
getSearchHistory() {
let self = this;
let url = '/home/home/search_history';
let header = {
"XX-Token": wx.getStorageSync('token')
};
app.post(url, {}, header).then((res) => {
// console.log('搜索历史列表', res);
self.setData({
searchHistory: res
});
})
},
//点击搜索历史
clickHistory(e) {
const current = e.currentTarget.dataset.index;
const list = [{title:'温哥华+翡翠岛+路易斯湖五日游',time:'2018.4.28',name:'旦巴 在多伦多'}]//假数据
this.setData({
searchValue: this.data.searchHistory[current].keyword,
postList:list,
});
this.startSearch()
},
//清空历史搜索
clearHistory() {
let self = this;
let url = '/home/home/clear_search';
let header = {
"XX-Token": wx.getStorageSync('token')
};
app.post(url, {}, header).then((res) => {
// console.log('清空搜索历史列表', res);
self.getSearchHistory()
})
},
//个人信息弹框
showModal(e) {
let that = this;
const current = e.currentTarget.dataset.index;
if(that.data.currentModal === current) {
that.data.postList[current].showlabel_box = !that.data.postList[current].showlabel_box;
}else {
that.data.postList[current].showlabel_box = !that.data.postList[current].showlabel_box;
that.data.postList[that.data.currentModal].showlabel_box = false;
}
that.setData({
postList: that.data.postList,
currentModal: current
});
},
//复制微信号
clickCopy(e) {
const current = e.currentTarget.dataset.index;
wx.setClipboardData({
data: this.data.postList[current].wxn,
success:function (res) {
// console.log('复制微信号',res);
}
});
this.setData({
[`postList[${this.data.currentModal}].showlabel_box`]: false
});
},
//进入主页
enterHomePage(e) {
let self = this;
const current = e.currentTarget.dataset.index;
wx.navigateTo({
url: '/pages/service/myindex/myindex?user_id=' + self.data.postList[current].user_id
});
self.setData({
[`postList[${self.data.currentModal}].showlabel_box`]: false
});
},
//举报
report(e) {
let self = this;
const current = e.currentTarget.dataset.index;
const to_user_id = self.data.postList[current].user_id;
const post_id = self.data.postList[current].id;
wx.navigateTo({url:'/pages/report/report?to_user_id=' + to_user_id + '&post_id=' + post_id});
self.setData({
[`postList[${self.data.currentModal}].showlabel_box`]: false
});
},
//查看文章详情
goPostDetail(e) {
const current = e.currentTarget.dataset.index;
const list = this.data.postList.map((item,index) => {
return {...item, showlabel_box: false}
});//进入详情时关闭所有弹框
this.setData({
postList: list,
currentPost: current
});
this.hit(current);
wx.navigateTo({
url: '../../rentingDetail/rentingDetail?post_id=' + this.data.postList[current].id,
})
},
//收藏、取消收藏
delArticles(e) {
let self = this;
const current = e.currentTarget.dataset.index;
let url = '/home/home/collect';
let url_del = '/home/home/collect_del';
let header = {
"XX-Token": wx.getStorageSync('token')
};
let params = {
id: self.data.postList[current].id,
};
if(self.data.postList[current].is_hits) {
app.post(url_del, params, header).then((res) => {
// console.log('取消收藏', res);
if(res.message == "操作成功") {
self.setData({
[`postList[${current}].is_hits`]: 0
});
}
})
}else {
app.post(url, params, header).then((res) => {
// console.log('收藏', res);
if(res.message == "操作成功") {
self.setData({
[`postList[${current}].is_hits`]: 1
});
}
})
}
},
//点赞/取消赞
clickZan(e) {
let self = this;
let current = e.currentTarget.dataset.index;
let postList = self.data.postList;
let url = '/home/home/like';
let url_del = '/home/home/like_del';
let header = {
"XX-Token": wx.getStorageSync('token')
};
let params = {
id: self.data.postList[current].id,
};
if(postList[current].is_paise) {
app.post(url_del, params, header).then((res) => {
// console.log('取消赞', res);
if(res.message == "操作成功") {//局部刷新赞数和头像
const post_like = postList[current].post_like - 1;
self.setData({
[`postList[${current}].is_paise`]: 0,
[`postList[${current}].post_like`]: post_like,
});
const paise_user = [];
postList[current].paise_user.map((item) => {
if(item !== res.data) {
paise_user.push(item)
}
});
self.setData({
[`postList[${current}].paise_user`]: paise_user,
})
}
})
}else {
app.post(url, params, header).then((res) => {
// console.log('点赞', res);
if(res.message == "操作成功") {//局部刷新赞数和头像
const post_like = postList[current].post_like + 1;
self.setData({
[`postList[${current}].is_paise`]: 1,
[`postList[${current}].post_like`]: post_like,
});
if(postList[current].paise_user !== undefined) {
const paise_user = postList[current].paise_user;
self.setData({
[`postList[${current}].paise_user`]: paise_user.concat(res.data),
})
}else {
const paise_user = [];
paise_user.push(res.data);
self.setData({
[`postList[${current}].paise_user`]: paise_user,
})
}
}
})
}
},
//去评论
goComment() {
wx.navigateTo({
url: '/pages/service/comment/comment?post_id=' +
this.data.postList[this.data.currentPost].id +
'&is_post_list=' + true
})
},
//获取用户id
personInfo() {
let url = '/home/me/index';
let header = {
"XX-Token": wx.getStorageSync('token')
};
let params = {}
app.post(url, params, header).then((res) => {
console.log(res)
this.setData({
userId: res.id,
});
console.log(this.data.userId)
})
},
onLoad: function (options) {
const self = this;
self.setData({
id: +options.id,
order: +options.order,
select_id: +options.select_id,
});
self.personInfo();
self.getSearchHistory();
},
refreshPostCollect() {
const postList = this.data.postList;
const currentPost = this.data.currentPost;
// console.log('刷新前长度', postList[currentPost].is_hits);
if(this.data.is_collect) {
this.setData({
[`postList[${currentPost}].is_hits`]: 1,
})
}else {
this.setData({
[`postList[${currentPost}].is_hits`]: 0,
})
}
// console.log('刷新后长度', postList[currentPost].is_hits);
},
refreshPostComment() {
const postList = this.data.postList;
const currentPost = this.data.currentPost;
// console.log('刷新前长度', postList[currentPost].comments.length);
if(this.data.is_comment) {
this.setData({[`postList[${currentPost}].comments[0].length`]: this.data.length})
}
// console.log('刷新后长度', postList[currentPost].comments[0].length);
},
refreshPostLike() {
const postList = this.data.postList;
const currentPost = this.data.currentPost;
if(this.data.is_paise) {
const post_like = postList[currentPost].post_like +1;
this.setData({
[`postList[${currentPost}].is_paise`]: 1,
[`postList[${currentPost}].post_like`]: post_like,
[`postList[${currentPost}].paise_user`]: this.data.paise_user,
})
// console.log('点赞', postList[currentPost].post_like);
}else {
const post_like = postList[currentPost].post_like -1;
this.setData({
[`postList[${currentPost}].is_paise`]: 0,
[`postList[${currentPost}].post_like`]: post_like,
[`postList[${currentPost}].paise_user`]: this.data.paise_user,
})
// console.log('取消赞', postList[currentPost].post_like);
}
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
const self = this;
if (!self.data.hasMore) {
wx.showToast({
title: '没有更多数据了~',
icon: 'none'
});
console.log('reach bottom', self.data.hasMore);
} else {
console.log('reach bottom', self.data.hasMore);
self.data.pageNumber++;
self.startSearch();
}
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"navigationBarTitleText": "搜索"
}
\ No newline at end of file
... ...
<!--pages/service/renting/search/search.wxml-->
<view class="container">
<view class="head_search_box">
<view class="input">
<image src="../../images/search@2x.png"></image>
<input placeholder='请输入搜索相关内容' bindfocus="inputFocus" bindinput="inputKey" value="{{searchValue}}" bindconfirm="startSearch" placeholder-class='input_size'/>
<view class="iconfont icon-jia1 jia1" catchtap="clearInput"></view>
</view>
<!--<view class="search-text" bindtap="startSearch">搜索</view>-->
</view>
<view class="history_box" wx:if="{{postList.length<=0}}">
<view class="head">
<view class="title">热门搜索</view>
</view>
<view class="history_list {{searchHistory.length === 0?'text-center':''}}">
<text wx:if="{{searchHistory.length === 0}}">暂无搜索历史~</text>
<view wx:elseif wx:for="{{searchHistory}}" wx:key="index" bindtap="clickHistory" data-index="{{index}}">{{item.keyword}}</view>
</view>
</view>
<view class="history_box history" wx:if="{{postList.length<=0}}">
<view class="head">
<view class="title">搜索历史</view>
<view class="clear" bindtap="clearHistory">
<view class="iconfont icon-shanchu"></view>
<text>清空历史记录</text>
</view>
</view>
<view class="history_list {{searchHistory.length === 0?'text-center':''}}">
<text wx:if="{{searchHistory.length === 0}}">暂无搜索历史~</text>
<view wx:elseif wx:for="{{searchHistory}}" wx:key="index" bindtap="clickHistory" data-index="{{index}}">{{item.keyword}}</view>
</view>
</view>
<!--文章内容-->
<view class='content_box post_box' wx:if="{{postList.length > 0}}">
<view class='content_item' wx:for="{{postList}}" wx:key="index" bindtap='goPostDetail' data-index="{{index}}">
<image src="../../images/lishi@2x.png" class="thumb"></image>
<view class="lish-right">
<view class="title">{{item.title}}</view>
<view class="time">{{item.time}}</view>
<view class="name-box">
<image src="../../images/avatar@2x.png" class="avatar"></image>
<text>{{item.name}}</text>
</view>
</view>
</view>
</view>
</view>
... ...
/* pages/service/renting/search/search.wxss */
/*@import '../renting.wxss';*/
page {
background-color: #fff;
padding: 0;
}
.head_search_box {
display: flex;
align-items: center;
justify-content: space-between;
/*height: 64rpx;*/
line-height: 64rpx;
padding: 12rpx 32rpx;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
background-color: #fff;
position: fixed;
top: 0;
left: 0;
width: 100%;
z-index: 20;
}
.content_box {
padding: 10rpx 20rpx;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
border-top: 1rpx solid #eeeeee;
}
.post_box {
margin-top: 100rpx;
}
.content_item {
display: flex;
align-items: center;
justify-content: flex-start;
padding: 30rpx 0;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
border-bottom: 1rpx solid #eeeeee;
}
.content_item .thumb {
width: 170rpx;
height: 170rpx;
margin-right: 26rpx;
}
.lish-right {
height: 166rpx;
display: flex;
flex-direction: column;
justify-content: space-around;
}
.lish-right .title, .lish-right .time{
font-size: 24rpx;
color: #333333;
}
.lish-right .name-box {
display: flex;
align-items: center;
color: #666666;
font-size: 22rpx;
}
.lish-right .name-box .avatar{
width: 40rpx;
height: 40rpx;
margin-right: 16rpx;
}
.input {
width: 100%;
display: flex;
align-items: center;
background: #F2F2F2;
border-radius: 10rpx;
padding:0 10rpx;
}
.input input {
font-size: 28rpx;
color: #666666;
}
.input_size {
font-size: 28rpx;
}
.input image {
width: 34rpx;
height: 34rpx;
margin: 0 20rpx;
}
.fangdajing {
margin-left: 24rpx;
margin-right: 22rpx;
color: #999999;
}
.jia1 {
margin-right: 20rpx;
color: #97A0A8;
}
.head_serach_box input {
font-size: 30rpx;
}
.search-text {
font-size: 26rpx;
}
.history_box {
display: flex;
flex-direction: column;
padding: 36rpx 38rpx;
background-color: #fff;
margin-top: 76rpx;
}
.history {
margin-top: 0;
}
.head {
display: flex;
justify-content: space-between;
margin-bottom: 18rpx;
}
.title {
color: #333333;
font-size: 30rpx;
font-weight: bold;
}
.icon-shanchu {
margin-right: 10rpx;
color: #999999;
font-size: 28rpx;
}
.clear {
display: flex;
align-items: center;
}
.clear text {
font-size: 24rpx;
color: #999999;
}
.history_list {
display: flex;
justify-content: flex-start;
align-items: center;
flex-wrap: wrap;
border-top: 1rpx solid #E8E8E8;
}
.text-center {
text-align: center;
display: block;
}
.history_list view {
padding: 12rpx 26rpx;
/* background-color: #F4F4F4; */
font-size: 28rpx;
color: #999999;
margin-right: 10rpx;
margin-bottom: 10rpx;
margin-left: 20rpx;
border-radius: 8rpx;
}
.history_list text {
font-size: 26rpx;
color: #999999;
}
.list_comment_box {
position: relative;
}
.triangle1 {
width: 0;
height: 0;
border-bottom: 11rpx solid #ebecf0;
border-left: 13rpx solid transparent;
border-right: 13rpx solid transparent;
position: absolute;
top: -8rpx;
left: 20rpx;
}
\ No newline at end of file
... ...
// pages/spell-list/spell-list.js
const app = getApp();
// const date = new Date();
// const years = [];
// const months = [];
// const days = [];
//
// for (let i = 1990; i <= date.getFullYear(); i++) {
// years.push(i)
// }
//
// for (let i = 1; i <= 12; i++) {
// months.push(i)
// }
//
// for (let i = 1; i <= 31; i++) {
// days.push(i)
// }
Page({
/**
* 页面的初始数据
*/
data: {
tabcurrent: {tab: 1,bubble: ''},
current: 0,//0拼餐,1拼活动
is_showSort: false,
is_showSelect: false,
currentSort: 0,
currentSelect: 0,
start_time_date: app.nowDate(),
end_time_date: app.nowDate(),
type:[
{name:'粤菜',id:1},{name:'川菜',id:2},{name:'其他中餐',id:3},{name:'粤菜',id:4},{name:'粤菜',id:5},{name:'粤菜',id:6},{name:'粤菜',id:7},
{name:'粤菜',id:8},{name:'川菜',id:9},{name:'其他中餐',id:10},{name:'粤菜',id:11},{name:'粤菜',id:12},{name:'粤菜',id:13},{name:'粤菜',id:14},
],
sort: [{id: 0, name: '最具人气'}, {id: 1, name: '距离最近'}],
sort_id: 0,//选择的排序id,默认是0
is_all: true,
list:[
{area:'Opera Bombana 2018.4.28',num:1,name:'巴旦 出发地朝阳区'},
{area:'Opera Bombana 2018.4.28',num:1,name:'巴旦 出发地朝阳区'},
{area:'Opera Bombana 2018.4.28',num:1,name:'巴旦 出发地朝阳区'},
]
},
//搜索
search() {
wx.navigateTo({
url: '/pages/search/search',
})
},
//tab点击事件
chargeTab(e) {
this.setData({
current: e.currentTarget.dataset.current
})
},
//点击智能排序按钮
clickSort() {
let that = this;
that.setData({
// down: !that.data.down,
is_showSort: !that.data.is_showSort,
is_showSelect: false
// showrent_mask: false
})
},
//点击筛选按钮
clickSelect() {
let that = this;
that.setData({
// down: !that.data.down,
is_showSelect: !that.data.is_showSelect,
is_showSort: false,
// showrent_mask: false
})
},
//关闭排序列表
closeMask() {
let that = this;
that.setData({
// showrent_mask: false,
is_showSort: false,
is_showSelect: false,
})
},
//保持筛选列表开启
openMask() {
this.setData({is_showSelect: true,})
},
//点击默认/热度排序
chooseSort(e) {
const current = e.currentTarget.dataset.index;
this.setData({
sort_id: this.data.sort[current].id,
currentSort: current,
is_showSort: false,
// down: !this.data.down,
});
this.initPortalPost();
this.getuser_recommend()
},
//选择开始时间
changeStartTime: function(e) {
console.log('picker发送选择改变,携带值为', e.detail.value)
this.setData({
start_time_date: e.detail.value,
is_showSelect: true,
// is_birth_change: true,
})
},
//选择结束时间
changeEndTime: function(e) {
console.log('picker发送选择改变,携带值为', e.detail.value)
this.setData({
end_time_date: e.detail.value,
is_showSelect: true,
// is_birth_change: true,
})
},
//选择全部分类
chooseAll() {
this.setData({is_all: true,is_showSelect:false,current_type:null})
},
//选择分类
chooseType(e) {
const current = e.currentTarget.dataset.index;
this.setData({current_type: current,is_all:false,is_showSelect:false,is_showSort: false,})
},
//首页-导航
service(e) {
var tindex = e.currentTarget.dataset.tindex;
var tabcurrent = this.data.tabcurrent;
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
wx.redirectTo({
url: '/pages/index/index',
})
}
},
//拼单-导航
consult(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
// wx.showToast({
// title: '该功能正在开发中',
// icon: 'none'
// })
wx.redirectTo({
url: '/pages/spell-list/spell-list',
})
}
},
//发布按钮
release(e) {
let that = this;
that.setData({
releasepopup: true
})
},
//取消发布弹窗
cancelPopup() {
let that = this;
that.setData({
releasepopup: false
})
},
//订单-导航
wish(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
// wx.showToast({
// title: '该功能正在开发中',
// icon: 'none'
// })
wx.redirectTo({
url: '/pages/order/order',
})
}
},
//我的-导航
my(e) {
var tindex = e.currentTarget.dataset.tindex
var tabcurrent = this.data.tabcurrent
if (tabcurrent == tindex) {
return false
} else {
this.setData({
tabcurrent: tindex
})
wx.redirectTo({
url: '/pages/my/my',
})
}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
\ No newline at end of file
... ...
{
"navigationBarTitleText": "拼单"
}
\ No newline at end of file
... ...
<!--pages/spell-list/spell-list.wxml-->
<view class="fix-box">
<view class="head">
<view class="position">
<view class="left">
<view class="iconfont icon-location"></view>
<text>北京</text>
<view class="iconfont icon-arrow-down"></view>
</view>
<view class="right" bindtap="search">
<view class="input"></view>
<image src="../../images/search@2x.png"></image>
<!--<view class="iconfont icon-arrow-down"></view>-->
</view>
</view>
</view>
<view class='tab_box'>
<view class="tab_item {{current==0?'active':''}}" data-current='0' bindtap='chargeTab'>拼餐</view>
<view class="tab_item {{current==1?'active':''}}" data-current='1' bindtap='chargeTab'>拼活动</view>
</view>
<view class="sort-select-box">
<!--智能排序按钮-->
<view class="sort-box" bindtap='clickSort'>
<view class='' class="sort-btn">智能排序</view>
<view class="iconfont icon-arrow-down"></view>
</view>
<!--筛选按钮-->
<view class="select-box" bindtap='clickSelect'>
<view class='' class="select-btn">筛选</view>
<view class="iconfont icon-arrow-down"></view>
</view>
</view>
<!--智能排序列表-->
<view class='rent_mask' wx:if='{{is_showSort}}' bindtap="closeMask">
<view class='rent_popup'>
<view class="rent_item {{currentSort===index?'active':''}}" wx:for="{{sort}}" wx:key="index"
catchtap='chooseSort' data-index="{{index}}">{{item.name}}</view>
</view>
</view>
<!--筛选列表-->
<view class='rent_mask' wx:if='{{is_showSelect}}' bindtap="closeMask">
<view class='rent_popup time-box' catchtap="openMask">
<text class="title">时间:</text>
<view class="picker-box">
<picker bindchange="changeStartTime" value="{{start_time_date}}" mode="date">
<view class="time-select-box">
<view class="select-picker">
<view class="picker">
{{start_time_date}}
</view>
</view>
<view class="iconfont icon-arrow-down arrow"></view>
</view>
</picker>
<text>-</text>
<picker bindchange="changeEndTime" value="{{end_time_date}}" mode="date">
<view class="time-select-box">
<view class="select-picker">
<view class="picker">
{{end_time_date}}
</view>
</view>
<view class="iconfont icon-arrow-down arrow"></view>
</view>
</picker>
</view>
<text class="title">菜系:</text>
<view class="type">
<text catchtap="chooseAll" class="{{is_all?'change-color':''}}">全部</text>
<text class="{{current_type === index?'change-color':''}}"
wx:for="{{type}}" wx:key="index" catchtap="chooseType"
data-index="{{index}}">{{item.name}}</text>
</view>
<!--<view class="rent_item {{currentSelect===index?'active':''}}" wx:for="{{select}}" wx:key="index"-->
<!--catchtap='chooseSort' data-index="{{index}}">{{item.name}}</view>-->
</view>
</view>
</view>
<!--拼餐-->
<view class='content_box' wx:if='{{current==0}}'>
<view class="no-data" wx:if="{{list.length === 0}}">暂无拼餐活动</view>
<view class='content_item' wx:for='{{list}}' wx:key="index" wx:if="{{list.length>0}}"
bindtap='gouserrecommend_detail' data-index="{{index}}">
<image src="../../images/activity_img@2x.png"></image>
<view class="title">
<text class="area">{{item.area}}</text>
<text class="num">还差{{item.num}}人</text>
</view>
<view class="user">
<image src="../../images/avatar@2x.png" class="avatar"></image>
<text>{{item.name}}</text>
</view>
</view>
</view>
<!--拼活动-->
<view class="content_box" wx:if='{{current==1}}'>
<view class="no-data" wx:if="{{list.length === 0}}">暂无拼餐活动</view>
<view class='content_item' wx:for='{{list}}' wx:key="index" wx:if="{{list.length>0}}"
bindtap='gouserrecommend_detail' data-index="{{index}}">
<image src="../../images/b1@2x (1).png"></image>
<view class="title">
<text class="area">{{item.area}}</text>
<text class="num">还差{{item.num}}人</text>
</view>
<view class="user">
<image src="../../images/avatar@2x.png" class="avatar"></image>
<text>{{item.name}}</text>
</view>
</view>
</view>
<!--底部tab-->
<import src="/templates/templates.wxml" />
<template is="tabBar" data='{{...tabcurrent}}' />
... ...
/* pages/spell-list/spell-list.wxss */
@import "../../templates/templates.wxss";
@keyframes content_box {
0% { opacity: 0; }
100% { opacity: 1; }
}
.fix-box {
width:100%;
position: fixed;
top: 0;
left: 0;
z-index: 10;
background: #fff;
}
.position {
width: 100%;
display: flex;
align-items: center;
justify-content: space-between;
padding: 20rpx;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
border-bottom: 1rpx solid #f2f2f2;
}
.position .left {
display: flex;
align-items: center;
}
.position .left .icon-location {
font-size: 44rpx;
color: #000000;
margin-right: 14rpx;
}
.position .left .icon-arrow-down {
font-size: 36rpx;
color: #000000;
margin-left: 18rpx;
}
.position text {
color: #000000;
font-size: 28rpx;
}
.position .right {
width: 70%;
height: 52rpx;
position: relative;
background-color: rgba(255,255,255,0.35);
display: flex;
align-items: center;
justify-content: space-between;
border-radius: 10rpx;
padding: 0 20rpx;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.position .right image {
width: 34rpx;
height: 34rpx;
position: absolute;
right: 36rpx;
top: 8rpx;
}
.position .input {
width: 100%;
height: 54rpx;
color: #000000;
padding-left: 20rpx;
font-size: 28rpx;
border: 1rpx solid #e5e5e5;
border-radius: 26rpx;
}
.tab_box {
padding: 0 100rpx;
height: 90rpx;
line-height: 90rpx;
display: flex;
align-items: center;
justify-content: center;
border-bottom: 20rpx solid #f5f5f5;
overflow: hidden;
white-space: nowrap;
flex-wrap: nowrap;
}
.tab_item {
display: inline-block;
width: 160rpx;
font-size: 32rpx;
color: #0E050A;
position: relative;
text-align: center;
/* border: 1rpx solid red; */
}
.active {
color: #0E050A;
}
.tab_box .active::after {
content: "";
/*border: 2rpx solid #DB4E2A;*/
position: absolute;
bottom: 0rpx;
left: 50%;
transform: translateX(-50%);
width: 120rpx;
height: 4rpx;
background: #DB4E2A;
}
.sort-select-box {
display: flex;
align-items: center;
justify-content: space-between;
padding: 24rpx 20rpx;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.sort-box, .select-box {
display: flex;
align-items: center;
}
.sort-btn {
color: #333333;
font-size: 24rpx;
margin-right: 10rpx;
}
.select-btn {
color: #666666;
font-size: 24rpx;
margin-right: 10rpx;
}
.sort-select-box .icon-arrow-down {
font-size: 30rpx;
color: #666666;
}
.rent_mask {
width: 100%;
height: 100%;
background: RGBA(0, 0, 0, 0.2);
position: fixed;
top: 282rpx;
left: 0;
z-index: 10;
overflow: hidden;
}
.rent_popup {
background: #fafafa;
padding: 0 30rpx;
}
.time-box {
padding: 20rpx 30rpx;
}
.rent_item {
width: 100%;
height: 73rpx;
border-bottom: 1rpx solid #ebebeb;
font-size: 30rpx;
color: #b3b3b3;
text-align: center;
line-height: 73rpx;
}
.rent_item.active {
color: #DB4E2A;
}
.rent_item:last-child {
border-bottom: 0;
}
.picker-box {
display: flex;
align-items: center;
justify-content: space-between;
padding: 20rpx 0;
}
.picker-box picker {
width: 50%;
height: 50rpx;
line-height: 50rpx;
border: 1rpx solid #e5e5e5;
border-radius: 40rpx;
}
.time-select-box {
display: flex;
align-items: center;
justify-content: space-between;
}
.select-picker {
width: 90%;
text-align: center;
}
.select-picker .picker {
color: #666666;
font-size: 28rpx;
}
.time-box .title {
font-size: 30rpx;
color: #333333;
}
.time-select-box .arrow {
margin-right: 20rpx;
}
.time-box .type {
width: 100%;
display: flex;
align-items: flex-start;
flex-wrap: wrap;
padding: 10rpx 0;
}
.time-box .type text {
color: #666666;
font-size: 28rpx;
padding: 10rpx 10rpx;
}
.time-box .type .change-color{
color: #DB4E2A;
}
.content_box {
background: #fff;
animation: content_box 1s both;
margin-top: 284rpx;
padding: 10rpx 20rpx 120rpx 20rpx;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.content_item {
padding: 16rpx;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
box-shadow: 2rpx 8rpx 38rpx rgba(89, 89, 89, 0.14);
border-radius: 8rpx;
}
.content_item image {
width: 100%;
height: 340rpx;
}
.content_item .title, .content_item .user {
display: flex;
align-items: center;
justify-content: space-between;
}
.content_item .user {
justify-content: flex-start;
margin-top: 10rpx;
}
.content_item .title .area {
color: #333333;
font-size: 24rpx;
}
.content_item .title .num {
color: #666666;
font-size: 22rpx;
}
.content_item .user image {
width: 40rpx;
height: 40rpx;
border-radius: 50%;
margin-right: 10rpx;
}
.content_item .user text {
color: #666666;
font-size: 22rpx;
}
\ No newline at end of file
... ...
<template name="tabBar">
<view class='tabbar_box'>
<view class='tabbar_item' data-tindex='0' bindtap='service'>
<!--<view class="iconfont icon-zonghe {{tab==0?'tab_active':''}}"></view>-->
<image src="../../images/shouye1@2x.png" wx:if="{{tab==0}}"></image>
<image src="../../images/shouye@2x.png" wx:else></image>
<!--<view class="tabbar_title {{tab==0?'tab_active':''}}">首页</view>-->
</view>
<view class='tabbar_item' data-tindex='1' bindtap='consult'>
<!--<view class="iconfont icon-pinglun1 {{tab==1?'tab_active':''}}"></view>-->
<image src="../../images/pindan1@2x.png" wx:if="{{tab==1}}"></image>
<image src="../../images/pindan@2x.png" wx:else></image>
<!--<view class="tabbar_title {{tab==1?'tab_active':''}}">拼单</view>-->
</view>
<view class='release_box' data-tindex='2' bindtap='release'>
<!--<view class='iconfont icon-xiangji'></view>-->
<image src="../../images/fabu@2x.png" class="fabu"></image>
</view>
<view class='tabbar_item' data-tindex='3' bindtap='wish'>
<!--<view class="iconfont icon-xiangqu {{tab==3?'tab_active':''}}"></view>-->
<image src="../../images/order1@2x.png" wx:if="{{tab==3}}"></image>
<image src="../../images/order@2x.png" wx:else></image>
<!--<view class="tabbar_title {{tab==3?'tab_active':''}}">订单</view>-->
</view>
<view class='tabbar_item' data-tindex='4' bindtap='my'>
<!--<view class="iconfont icon-wode {{tab==4?'tab_active':''}}"></view>-->
<image src="../../images/my1@2x.png" wx:if="{{tab==4}}"></image>
<image src="../../images/my@2x.png" wx:else></image>
<!--<view class="tabbar_title {{tab==4?'tab_active':''}}">我的</view>-->
<!--<view class="tip-point" wx:if="{{bubble == 2}}"></view>-->
</view>
</view>
</template>
\ No newline at end of file
... ...
/* pages/template/template.wxss */
/* 公共tabbar */
.tabbar_box {
width: 100%;
height: 100rpx;
display: flex;
align-items: center;
justify-content: space-between;
padding: 0 60rpx;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
border: 1rpx solid #EBEBEB;
position: fixed;
bottom: 0;
left: 0;
background: #333333;
}
.release_box {
width: 104rpx;
height: 136rpx;
display: flex;
align-items: center;
justify-content: center;
margin-top:-50rpx;
}
.release_box image {
width: 100%;
height: 100%;
}
.icon-xiangji {
font-size: 56rpx;
color: #fff;
}
.icon-pinglun1{
font-size: 38rpx;
}
.tabbar_box .iconfont {
text-align: center;
}
.tabbar_title {
font-size: 24rpx;
color: #666;
text-align: center;
}
.tab_active{
color: #E0492C;
}
.tabbar_item {
position: relative;
display: flex;
align-items: center;
}
.tabbar_item image {
width: 48rpx;
height:76rpx;
}
.tip-point {
width: 16rpx;
height: 16rpx;
background-color: #53A6FA;
position: absolute;
top: 2rpx;
right: 6rpx;
border-radius: 50%;
}
... ...