-
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
cxi
committed
May 15, 2019
0 parents
commit 30e0d44
Showing
176 changed files
with
6,513 additions
and
0 deletions.
There are no files selected for viewing
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 @@ | ||
'use strict' | ||
|
||
const baseUrl = require('./index.js').config.baseUrl; | ||
|
||
const API = { | ||
list: baseUrl + '/ad/list.do', | ||
}; | ||
|
||
module.exports.Ad = API; |
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,12 @@ | ||
'use strict' | ||
|
||
const baseUrl = require('./index.js').config.baseUrl; | ||
|
||
const API = { | ||
deleteCart: baseUrl + '/cart/delete.do', | ||
list: baseUrl + '/cart/list.do', | ||
update: baseUrl + '/cart/update.do', | ||
save: baseUrl + '/cart/save.do', | ||
}; | ||
|
||
module.exports.Cart = API; |
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 @@ | ||
'use strict' | ||
|
||
const baseUrl = require('./index.js').config.baseUrl; | ||
|
||
const API = { | ||
list: baseUrl + '/class/list.do' | ||
}; | ||
|
||
module.exports.Class = API; |
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 @@ | ||
'use strict' | ||
|
||
const baseUrl = require('./index.js').config.baseUrl; | ||
|
||
const API = { | ||
deleteContacts: baseUrl + '/contacts/delete.do', | ||
list: baseUrl + '/contacts/list.do', | ||
update: baseUrl + '/contacts/update.do', | ||
save: baseUrl + '/contacts/save.do', | ||
getContacts: baseUrl + '/contacts/get.do', | ||
}; | ||
|
||
module.exports.Contacts = API; |
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 @@ | ||
'use strict' | ||
|
||
const baseUrl = require('./index.js').config.baseUrl; | ||
|
||
const API = { | ||
deleteCoodBook: baseUrl + '/cookbook/delete.do', | ||
list: baseUrl + '/cookbook/list.do', | ||
update: baseUrl + '/cookbook/update.do', | ||
save: baseUrl + '/cookbook/save.do', | ||
getCoodBook: baseUrl + '/cookbook/get.do', | ||
}; | ||
|
||
module.exports.Cookbook = API; |
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,7 @@ | ||
'use strict' | ||
|
||
const config = { | ||
baseUrl: 'https://meishijiapeisong.club/xcx' | ||
}; | ||
|
||
module.exports.config = config; |
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,18 @@ | ||
'use strict' | ||
|
||
const baseUrl = require('./index.js').config.baseUrl; | ||
|
||
const API = { | ||
cancel: baseUrl + '/order/cancel.do', | ||
comment: baseUrl + '/order/comment.do', | ||
confirm: baseUrl + '/order/confirm.do', | ||
getOrder: baseUrl + '/order/get.do', | ||
list: baseUrl + '/order/list.do', | ||
pay: baseUrl + '/order/pay.do', | ||
place: baseUrl + '/order/place.do', | ||
deliver: baseUrl + '/order/deliver.do', | ||
receive: baseUrl + '/order/receive.do', | ||
listComment: baseUrl + '/order/listComment.do', | ||
}; | ||
|
||
module.exports.Order = API; |
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 @@ | ||
'use strict' | ||
|
||
const baseUrl = require('./index.js').config.baseUrl; | ||
|
||
const API = { | ||
list: baseUrl + '/goods/list.do', | ||
getPro: baseUrl + '/goods/get.do', | ||
}; | ||
|
||
module.exports.Product = API; |
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 @@ | ||
'use strict' | ||
|
||
const baseUrl = require('./index.js').config.baseUrl; | ||
|
||
const API = { | ||
login: baseUrl + '/user/loginByXcx.do', | ||
logout: baseUrl + '/user/logout.do', | ||
sumbitWxUserInfo: baseUrl + '/user/sumbitWxUserInfo.do', | ||
}; | ||
|
||
module.exports.User = API; |
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,72 @@ | ||
//app.js | ||
// const bmap = require('./utils/bmap-wx.js'); | ||
const User = require('./api/user.js').User; | ||
|
||
App({ | ||
onLaunch: function () { | ||
let _this = this; | ||
// let BMap = new bmap.BMapWX({ | ||
// ak: 'elwxlzWPwvdFpbASxZwMt6L1W6W1bSiS' | ||
// }); | ||
// this.globalData.BMap = BMap; | ||
|
||
wx.getSystemInfo({ | ||
success: function (res) { | ||
_this.globalData.systemInfo = res; | ||
} | ||
}); | ||
}, | ||
|
||
getLogin () { | ||
let _this = this; | ||
return new Promise(function (resolve, reject) { | ||
wx.login({ | ||
success: function (res) { | ||
if (res.code) { | ||
_this.globalData.code = res.code; | ||
wx.request({ | ||
url: User.login, | ||
data: { | ||
code: res.code | ||
}, | ||
method: 'POST', | ||
success: function (data) { | ||
if (data.data.result.userLevel === '0') { | ||
wx.redirectTo({ | ||
url: '/pages/noRole/index', | ||
}); | ||
reject(false); | ||
} | ||
|
||
_this.globalData.token = data.data.result.token; | ||
_this.globalData.userType = data.data.result.userType; | ||
_this.globalData.userId = data.data.result.userId; | ||
if (data.data.result.userLevel !== '0') { | ||
_this.globalData.userLevelValue = data.data.result.userLevelValue; | ||
} | ||
resolve(true); | ||
}, | ||
fail: function (e) { | ||
wx.redirectTo({ | ||
url: '/pages/noRole/index', | ||
}); | ||
} | ||
}) | ||
} | ||
} | ||
}); | ||
}) | ||
}, | ||
globalData: { | ||
token: null, | ||
BMap: null, | ||
userType: '0', | ||
userLevelValue: null, | ||
userId: null, | ||
userInfo: null, | ||
location: { | ||
contacts: null | ||
}, | ||
selectProducts: [] | ||
} | ||
}) |
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,71 @@ | ||
{ | ||
"pages": [ | ||
"pages/index/index", | ||
"pages/categories/index", | ||
"pages/shoppingcar/index", | ||
"pages/home/index", | ||
"pages/address/index", | ||
"pages/address_detail/index", | ||
"pages/orders/index", | ||
"pages/order_detail/index", | ||
"pages/products/index", | ||
"pages/product_detail/index", | ||
"pages/comment/index", | ||
"pages/cuisines/index", | ||
"pages/noRole/index", | ||
"zanUI/toast/index", | ||
"pages/checkedOrder/index", | ||
"pages/selectAddress/index", | ||
"pages/userOrder/index", | ||
"pages/foodBook/index", | ||
"pages/cookbook_detail/index" | ||
], | ||
"window": { | ||
"backgroundTextStyle": "dark", | ||
"navigationBarBackgroundColor": "#fff", | ||
"navigationBarTextStyle": "black", | ||
"navigationBarTitleText": "美食家全民采购配送平台" | ||
}, | ||
"networkTimeout": { | ||
"request": 10000 | ||
}, | ||
"debug": false, | ||
"tabBar": { | ||
"selectedColor": "#ec7474", | ||
"color": "#b4b4b4", | ||
"borderStyle": "black", | ||
"backgroundColor": "#ffffff", | ||
"list": [ | ||
{ | ||
"pagePath": "pages/index/index", | ||
"text": "主页", | ||
"iconPath": "assets/poke-1.png", | ||
"selectedIconPath": "assets/poke-2.png" | ||
}, | ||
{ | ||
"pagePath": "pages/categories/index", | ||
"text": "分类", | ||
"iconPath": "assets/category-1.png", | ||
"selectedIconPath": "assets/category-2.png" | ||
}, | ||
{ | ||
"pagePath": "pages/cuisines/index", | ||
"text": "菜式", | ||
"iconPath": "assets/food-1.png", | ||
"selectedIconPath": "assets/food-2.png" | ||
}, | ||
{ | ||
"pagePath": "pages/shoppingcar/index", | ||
"text": "购物车", | ||
"iconPath": "assets/shoppingcar-1.png", | ||
"selectedIconPath": "assets/shoppingcar-2.png" | ||
}, | ||
{ | ||
"pagePath": "pages/home/index", | ||
"text": "我的", | ||
"iconPath": "assets/mine-1.png", | ||
"selectedIconPath": "assets/mine-2.png" | ||
} | ||
] | ||
} | ||
} |
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,37 @@ | ||
/**app.wxss**/ | ||
|
||
@import "zanUI/index.wxss"; | ||
|
||
.container { | ||
height: 100%; | ||
width: 100%; | ||
} | ||
|
||
.flex-row { | ||
display: flex; | ||
flex-direction: row; | ||
} | ||
|
||
.flex-col { | ||
display: flex; | ||
flex-direction: column; | ||
} | ||
|
||
.flex-center { | ||
justify-content: center; | ||
align-items: center; | ||
} | ||
|
||
.textCenter { | ||
text-align:center; | ||
} | ||
|
||
.noData { | ||
width: 100%; | ||
margin-top: 40rpx; | ||
font-size: 36rpx; | ||
color:#c5c9cc; | ||
} | ||
|
||
/** zanUI 的 Icon **/ | ||
@font-face{font-family:zanui-weapp-icon;src:url(https://b.yzcdn.cn/zanui-weapp/zanui-weapp-icon-eeb0d3c52a.eot);src:url(https://b.yzcdn.cn/zanui-weapp/zanui-weapp-icon-eeb0d3c52a.eot?#iefix) format('embedded-opentype'),url(https://b.yzcdn.cn/zanui-weapp/zanui-weapp-icon-eeb0d3c52a.woff2) format('woff2'),url(https://b.yzcdn.cn/zanui-weapp/zanui-weapp-icon-eeb0d3c52a.woff) format('woff'),url(https://b.yzcdn.cn/zanui-weapp/zanui-weapp-icon-eeb0d3c52a.ttf) format('truetype')}.zan-icon{display:inline-block}.zan-icon::before{font-family:zanui-weapp-icon!important;font-style:normal;font-weight:400;speak:none;display:inline-block;text-decoration:inherit;width:1em;text-align:center;font-variant:normal;text-transform:none;line-height:1em;-webkit-font-smoothing:antialiased}.zan-icon-qr-invalid:before{content:'\e800'}.zan-icon-qr:before{content:'\e801'}.zan-icon-exchange:before{content:'\e802'}.zan-icon-close:before{content:'\e803'}.zan-icon-location:before{content:'\e804'}.zan-icon-upgrade:before{content:'\e805'}.zan-icon-check:before{content:'\e806'}.zan-icon-checked:before{content:'\e807'}.zan-icon-like-o:before{content:'\e808'}.zan-icon-like:before{content:'\e809'}.zan-icon-chat:before{content:'\e80a'}.zan-icon-shop:before{content:'\e80b'}.zan-icon-photograph:before{content:'\e80c'}.zan-icon-add:before{content:'\e80d'}.zan-icon-minus:before{content:'\e80e'}.zan-icon-add2:before{content:'\e80f'}.zan-icon-photo:before{content:'\e810'}.zan-icon-logistics:before{content:'\e811'}.zan-icon-edit:before{content:'\e812'}.zan-icon-passed:before{content:'\e813'}.zan-icon-cart:before{content:'\e814'}.zan-icon-shopping-cart:before{content:'\e815'}.zan-icon-arrow:before{content:'\e816'}.zan-icon-gift:before{content:'\e817'}.zan-icon-search:before{content:'\e818'}.zan-icon-clear:before{content:'\e819'}.zan-icon-success:before{content:'\e81a'}.zan-icon-fail:before{content:'\e81b'}.zan-icon-contact:before{content:'\e81c'}.zan-icon-wechat:before{content:'\e81d'}.zan-icon-alipay:before{content:'\e81e'}.zan-icon-password-view:before{content:'\e81f'}.zan-icon-password-not-view:before{content:'\e820'}.zan-icon-wap-nav:before{content:'\e821'}.zan-icon-wap-home:before{content:'\e822'}.zan-icon-ecard-pay:before{content:'\e823'}.zan-icon-balance-pay:before{content:'\e824'}.zan-icon-peer-pay:before{content:'\e825'}.zan-icon-credit-pay:before{content:'\e826'}.zan-icon-debit-pay:before{content:'\e827'}.zan-icon-other-pay:before{content:'\e828'}.zan-icon-browsing-history:before{content:'\e829'}.zan-icon-goods-collect:before{content:'\e82a'}.zan-icon-shop-collect:before{content:'\e82b'}.zan-icon-receive-gift:before{content:'\e82c'}.zan-icon-send-gift:before{content:'\e82d'}.zan-icon-setting:before{content:'\e82e'}.zan-icon-points:before{content:'\e82f'}.zan-icon-coupon:before{content:'\e830'}.zan-icon-free-postage:before{content:'\e831'}.zan-icon-discount:before{content:'\e832'}.zan-icon-birthday-privilege:before{content:'\e833'}.zan-icon-member-day-privilege:before{content:'\e834'}.zan-icon-balance-details:before{content:'\e835'}.zan-icon-cash-back-record:before{content:'\e836'}.zan-icon-points-mall:before{content:'\e837'}.zan-icon-exchange-record:before{content:'\e838'}.zan-icon-pending-payment:before{content:'\e839'}.zan-icon-pending-orders:before{content:'\e83a'}.zan-icon-pending-deliver:before{content:'\e83b'}.zan-icon-pending-evaluate:before{content:'\e83c'}.zan-icon-gift-card-pay:before{content:'\e83d'}.zan-icon-cash-on-deliver:before{content:'\e83e'}.zan-icon-underway:before{content:'\e83f'}.zan-icon-point-gift:before{content:'\e840'}.zan-icon-after-sale:before{content:'\e841'}.zan-icon-edit-data:before{content:'\e842'}.zan-icon-question:before{content:'\e843'}.zan-icon-delete:before{content:'\e844'}.zan-icon-records:before{content:'\e845'}.zan-icon-description:before{content:'\e846'}.zan-icon-card:before{content:'\e847'}.zan-icon-gift-card:before{content:'\e848'}.zan-icon-clock:before{content:'\e849'}.zan-icon-gold-coin:before{content:'\e84a'}.zan-icon-completed:before{content:'\e84b'}.zan-icon-value-card:before{content:'\e84c'}.zan-icon-certificate:before{content:'\e84d'}.zan-icon-tosend:before{content:'\e84e'}.zan-icon-sign:before{content:'\e84f'}.zan-icon-home:before{content:'\e850'}.zan-icon-phone:before{content:'\e851'}.zan-icon-add-o:before{content:'\e852'}.zan-icon-minus-o:before{content:'\e853'}.zan-icon-play:before{content:'\e854'}.zan-icon-pause:before{content:'\e855'}.zan-icon-stop:before{content:'\e856'}.zan-icon-hot:before{content:'\e857'}.zan-icon-new:before{content:'\e858'}.zan-icon-new-arrival:before{content:'\e859'}.zan-icon-hot-sale:before{content:'\e85a'} |
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.
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.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.