-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 135189f
Showing
50 changed files
with
1,912 additions
and
0 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
{ | ||
"pages": [ | ||
"pages/home/index", | ||
"pages/index/index", | ||
"pages/userCenter/index", | ||
"pages/order/index", | ||
"pages/about/index" | ||
], | ||
"tabBar": { | ||
"color": "#666", | ||
"selectedColor": "#0152f6", | ||
"position": "bottom", | ||
"list": [ | ||
{ | ||
"pagePath": "pages/index/index", | ||
"iconPath": "assets/home.png", | ||
"selectedIconPath": "assets/homeHover.png", | ||
"text": "首页" | ||
}, | ||
{ | ||
"pagePath": "pages/userCenter/index", | ||
"iconPath": "assets/user.png", | ||
"selectedIconPath": "assets/userHover.png", | ||
"text": "个人中心" | ||
} | ||
] | ||
}, | ||
"window": { | ||
"backgroundTextStyle": "dark", | ||
"navigationBarBackgroundColor": "#1890ff", | ||
"navigationBarTitleText": "shopping", | ||
"navigationBarTextStyle": "white" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/**app.wxss**/ |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
Component({ | ||
options: { | ||
multipleSlots: true // 在组件定义时的选项中启用多slot支持 | ||
}, | ||
properties: { | ||
arrowData: Object | ||
}, | ||
data: { | ||
arrowData: { | ||
showArrow: true, | ||
arrowL: '', | ||
arrowR: '', | ||
icon: false | ||
} | ||
}, | ||
attached() { | ||
this.dataInit() | ||
}, | ||
methods: { | ||
dataInit() { | ||
this.setData({ | ||
showArrow: this.properties.arrowData.showArrow, | ||
arrowL: this.properties.arrowData.arrowL, | ||
arrowR: this.properties.arrowData.arrowR, | ||
icon: this.properties.arrowData.icon | ||
}) | ||
} | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"component": true, | ||
"usingComponents": {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<view class="arrowBtn"> | ||
<view class="arrowL"> | ||
<image wx:if="{{arrowData.icon}}" src="{{arrowData.icon}}"></image> | ||
<text>{{arrowData.arrowL}}</text> | ||
</view> | ||
<view class="arrowR"> | ||
<text>{{arrowData.arrowR}}</text> | ||
<image wx:if="{{arrowData.showArrow}}" src="../../assets/right.svg"></image> | ||
</view> | ||
</view> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
/**index.wxss**/ | ||
.arrowBtn{ | ||
display:flex;justify-content: space-between;align-items: center; | ||
padding:0 30rpx;background:#fff; | ||
height:100rpx; | ||
} | ||
.arrowBtn .arrowL{ | ||
display:flex;align-items: center; | ||
} | ||
.arrowBtn .arrowL image{ | ||
width:36rpx;height:36rpx; | ||
padding-right:10rpx; | ||
} | ||
.arrowBtn .arrowL text{ | ||
font-size:36rpx;font-family:"Microsoft Yahei"; | ||
} | ||
.arrowBtn .arrowR{ | ||
display:flex;align-items: center; | ||
} | ||
.arrowBtn .arrowR text{ | ||
font-size:32rpx;color:#999; | ||
padding-right:10rpx; | ||
} | ||
.arrowBtn .arrowR image{ | ||
width:32rpx;height:32rpx; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
const app = getApp() | ||
Component({ | ||
options: { | ||
multipleSlots: true // 在组件定义时的选项中启用多slot支持 | ||
}, | ||
properties: { | ||
item: Object | ||
}, | ||
data: { | ||
item:{} | ||
}, | ||
attached() { | ||
this.dataInit() | ||
}, | ||
methods: { | ||
dataInit(){ | ||
this.setData({ | ||
item: this.properties.item | ||
}) | ||
}, | ||
handlePlus(event) { | ||
let item = this.data.item | ||
item.num++ | ||
this.setData({ item }) | ||
app.globalData.cookList.map((element, index) => { | ||
element.cookBd.map((child, idx) => { | ||
if (child.id === item.id) { | ||
child.num = item.num | ||
} | ||
}) | ||
}) | ||
this.triggerEvent('changePrice') | ||
}, | ||
handleMinus(event) { | ||
let item = this.data.item | ||
item.num-- | ||
this.setData({ item }) | ||
app.globalData.cookList.map((element, index) => { | ||
element.cookBd.map((child, idx) => { | ||
if (child.id === item.id) { | ||
child.num = item.num | ||
} | ||
}) | ||
}) | ||
this.triggerEvent('changePrice') | ||
} | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"component": true, | ||
"usingComponents": {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<view class="item"> | ||
<image class="itemIcon" src="{{item.icon}}"></image> | ||
<view class="itemTxt"> | ||
<view class="cookName">{{item.cookName}}</view> | ||
<view class="cookInfo">{{item.cookIntro}}</view> | ||
<view class="cookInfo">月售{{item.sals}} 赞{{item.like}}</view> | ||
<view class="cookPrice"> | ||
<text class="cookPriceNum">¥{{item.price}}<text>/500g</text></text> | ||
<view class="changeNum"> | ||
<image class="cookIcon minus" wx:if="{{item.num > 0}}" bindtap="handleMinus" src="../../assets/minus.svg"></image> | ||
<view class="num" wx:if="{{item.num > 0}}">{{item.num}}</view> | ||
<image class="cookIcon plus" bindtap="handlePlus" src="../../assets/plus.svg"></image> | ||
</view> | ||
</view> | ||
</view> | ||
</view> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/**index.wxss**/ | ||
|
||
.item{ | ||
display:flex;justify-content:space-around;align-items: center; | ||
padding:20rpx;font-family: "Microsoft Yahei"; | ||
border-bottom:solid 2rpx #eee; | ||
} | ||
.item .itemIcon{ | ||
width:200rpx;height:200rpx; | ||
} | ||
.item .itemTxt{ | ||
display:flex;flex-direction: column;justify-content:space-between;align-items: flex-start;flex:1; | ||
margin-left:20rpx;height:200rpx; | ||
} | ||
.item .cookName{ | ||
font-size:36rpx;font-weight:bold;color:#666; | ||
} | ||
.item .cookInfo{ | ||
font-size:28rpx;color:#999; | ||
} | ||
.item .cookPrice{ | ||
display:flex;justify-content:space-between;align-items: center;width:100%; | ||
font-size:38rpx;font-weight:bold;color:#f00; | ||
} | ||
.item .cookPrice .cookPriceNum{ | ||
flex:1; | ||
} | ||
.item .cookPrice .cookPriceNum text{ | ||
font-weight:normal;font-size:30rpx;color:#ccc; | ||
} | ||
.item .cookPrice .changeNum{ | ||
display:flex;justify-content:flex-end;align-items: center; | ||
} | ||
.item .cookPrice .cookIcon{ | ||
width:48rpx;height:48rpx;border-radius:24rpx; | ||
} | ||
.item .cookPrice .num{ | ||
color:#333; | ||
flex:1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
//index.js | ||
//获取应用实例 | ||
const app = getApp() | ||
|
||
Page({ | ||
data: { | ||
}, | ||
//事件处理函数 | ||
bindViewTap: function() { | ||
}, | ||
onLoad: function () { | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"component": true, | ||
"usingComponents": {}, | ||
"navigationBarTitleText": "关于我们" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<!--index.wxml--> | ||
<view class="about"> | ||
<image src="../../assets/logo.png"></image> | ||
<view class="aboutCont"> | ||
<view>姓名:张孝德</view> | ||
<view>电话:15057159482</view> | ||
<view>门店:亢亢点单</view> | ||
<view>地址:杭州市西湖区</view> | ||
</view> | ||
</view> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
/**index.wxss**/ | ||
page{ | ||
height:100%;text-align:center; | ||
} | ||
.about image{ | ||
width:200rpx;height:200rpx; | ||
} | ||
.about .aboutCont{ | ||
text-align:left;width:80%;margin:0 auto; | ||
line-height:100rpx; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
//index.js | ||
//获取应用实例 | ||
const app = getApp() | ||
|
||
Page({ | ||
data: { | ||
}, | ||
//事件处理函数 | ||
bindViewTap: function() { | ||
}, | ||
startRecord() { | ||
// console.log(this.pusher) | ||
// this.pusher.start() | ||
// this.player.play() | ||
// wx.chooseVideo({ | ||
// maxDuration: 10, | ||
// success: function (res1) { | ||
// app.startOperating("上传中") | ||
// // 这个就是最终拍摄视频的临时路径了 | ||
// var tempFilePath = res1.tempFilePath; | ||
// }, | ||
// fail: function () { | ||
// console.error("获取本地视频时出错"); | ||
// } | ||
// }) | ||
}, | ||
endRecord() { | ||
}, | ||
onLoad: function () { | ||
setTimeout(()=>{ | ||
wx.switchTab({ | ||
url: '../index/index' | ||
}) | ||
},1000) | ||
|
||
// wx.authorize({ | ||
// scope: 'scope.userInfo' | ||
// }) | ||
// this.pusher = wx.createLivePusherContext('pusher') | ||
// this.player = wx.createLivePusherContext('player') | ||
|
||
// wx.startRecord() | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"navigationBarTitleText": "", | ||
"navigationBarBackgroundColor": "#c6f" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<!--index.wxml--> | ||
<view class="homePage"> | ||
<image src="../../assets/welcome.jpg"></image> | ||
<!-- <button open-type="getUserInfo">获取权限</button> | ||
<live-pusher id="pusher" url="https://domain/push_stream" mode="RTC" autopush /> | ||
<live-player id="player" url="https://domain/push_stream" mode="live" autoplay /> | ||
<button bindtap='startRecord'>开始录音</button> | ||
<button bindtap='endRecord'>结束录音</button> --> | ||
</view> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/**index.wxss**/ | ||
page{ | ||
height:100%; | ||
} | ||
.homePage{ | ||
height:100%;overflow:hidden;text-align:center; | ||
} | ||
.homePage image{ | ||
min-width:100%;min-height:100%; | ||
} |
Oops, something went wrong.