Browse Source

2.0 正式进入联调 修改了一点页面

hfll
hflllll 3 months ago
parent
commit
efe2780548
36 changed files with 527 additions and 597 deletions
  1. +4
    -4
      api/api.js
  2. +2
    -2
      api/http.js
  3. +8
    -205
      api/model/index.js
  4. +0
    -115
      api/model/info.js
  5. +2
    -2
      api/model/login.js
  6. +12
    -0
      api/model/order.js
  7. +0
    -20
      api/model/vip.js
  8. +0
    -4
      components/base/tabbar.vue
  9. +157
    -0
      components/config/PrivacyPopup.vue
  10. +1
    -1
      components/product/productItem.vue
  11. +1
    -1
      config.js
  12. +1
    -1
      main.js
  13. +16
    -13
      mixins/configList.js
  14. +28
    -26
      pages/index/category.vue
  15. +3
    -3
      pages/index/center.vue
  16. +1
    -1
      pages/index/order.vue
  17. +97
    -82
      pages_order/auth/wxLogin.vue
  18. +50
    -29
      pages_order/auth/wxUserInfo.vue
  19. +1
    -1
      pages_order/components/order/placeOrder.vue
  20. +1
    -1
      pages_order/mine/team.vue
  21. +1
    -1
      pages_order/mine/wallet.vue
  22. +5
    -5
      pages_order/order/newOrderDetail.vue
  23. BIN
      static/image/logo.png
  24. BIN
      static/image/logo.webp
  25. BIN
      static/image/红烧肉.png
  26. BIN
      static/image/红烧肉.webp
  27. +9
    -3
      static/js/mockAssets.js
  28. +11
    -6
      static/js/mockCartData.js
  29. +11
    -4
      static/js/mockCoupon.js
  30. +53
    -45
      static/js/mockOrders.js
  31. +8
    -3
      static/js/mockShare.js
  32. +10
    -3
      static/js/mockTeam.js
  33. +8
    -3
      static/js/mockTeamData.js
  34. +7
    -2
      static/js/mockUserInfo.js
  35. +7
    -2
      static/js/mockWallet.js
  36. +12
    -9
      store/store.js

+ 4
- 4
api/api.js View File

@ -5,7 +5,7 @@ import utils from '../utils/utils.js'
let limit = {}
let debounce = {}
const models = ['login', 'index', 'vip', 'info']
const models = ['login', 'index', 'order']
const config = {
// 示例
@ -14,7 +14,7 @@ const config = {
// limit : 1000
// },
getConfig : {url : '/config_common/getConfig', method : 'GET', limit : 500},
getConfig : {url : '/teambuy/config/queryConfigList', method : 'GET', limit : 500},
}
@ -46,7 +46,7 @@ export function api(key, data, callback, loadingTitle) {
}
//必须登录 - 注释掉登录检查
/*
if (req.auth) {
if (!uni.getStorageSync('token')) {
utils.toLogin()
@ -54,7 +54,7 @@ export function api(key, data, callback, loadingTitle) {
return Promise.reject()
}
}
*/
// 接口防抖
if(req.debounce){


+ 2
- 2
api/http.js View File

@ -32,7 +32,7 @@ function http(uri, data, callback, method = 'GET', showLoading, title) {
}
// 注释掉登录状态检查
/*
if(res.statusCode == 401 ||
res.data.message == '操作失败,token非法无效!' ||
res.data.message == '操作失败,用户不存在!'){
@ -40,7 +40,7 @@ function http(uri, data, callback, method = 'GET', showLoading, title) {
console.error('登录过期');
utils.toLogin()
}
*/
if(res.statusCode == 200 && res.data.code != 200
&& res.data.code != 902){


+ 8
- 205
api/model/index.js View File

@ -1,214 +1,17 @@
// 首页相关接口
const api = {
// 获取首页轮播图
getRiceBanner: {
url: '/index_common/getRiceBanner',
// 查看商品分类列表
queryCategoryList: {
url: '/teambuy/goods/queryCategoryList',
method: 'GET',
limit: 500,
},
// 获取首页常规产品【废弃】
// getRiceCommonProductList: {
// url: '/index_common/getRiceCommonProductList',
// method: 'GET',
// },
// 获取首页跳转图标
getRiceIconList: {
url: '/index_common/getRiceIconList',
// 查看商品列表
queryGoodsList: {
url: '/teambuy/goods/queryGoodsList',
method: 'GET',
},
// 获取首页新闻详情
getRiceNewsDetail: {
url: '/index_common/getCommonNewsDetail',
method: 'GET',
},
// 获取首页新闻列表
getRiceNewsList: {
url: '/index_common/getRiceNewsList',
method: 'GET',
},
// 获取首页公告列表
getRiceNoticeList: {
url: '/index_common/getRiceNoticeList',
method: 'GET',
},
// 获取首页商品详情
getRiceProductDetail: {
url: '/index_common/getRiceProductDetail',
method: 'GET',
},
// 获取首页体验产品
getRiceProductList: {
url: '/index_common/getRiceProductList',
method: 'GET',
},
// 查询分类接口
getCategoryList: {
url: '/index_common/getCategoryList',
method: 'GET',
},
// 新查询分类以及商品数据接口
getCategoryPidList: {
url: '/index_common/getCategoryPidList',
method: 'GET',
debounce : 250,
},
// 查询一级分类接口
getPidList: {
url: '/index_common/getCategoryPidList',
method: 'GET',
},
// 获取分类分页商品列表接口
getClassShopPageList: {
url: '/index_common/getClassShopPageList',
method: 'GET',
},
// 加入购物车
addCart: {
url: '/index_common/addCart',
method: 'GET',
auth: true,
showLoading: true,
limit : 500,
},
// 删除购物车信息
deleteCart: {
url: '/index_common/deleteCart',
method: 'DELETE',
auth: true,
showLoading: true,
},
// 修改购物车信息数量
updateCartNum: {
url: '/index_common/updateCartNum',
method: 'POST',
auth: true,
debounce: 300,
},
// 创建订单
createOrder: {
url: '/index_common/createOrder',
method: 'GET',
auth: true,
limit: 1000,
showLoading: true,
},
// 创建订单-再次支付
createOrderTwo: {
url: '/index_common/createOrderTwo',
method: 'GET',
auth: true,
limit: 1000,
showLoading: true,
},
// 多商品创建订单
createSumOrder: {
url: '/index_common/createSumOrder',
method: 'POST',
auth: true,
limit: 1000,
showLoading: true,
},
// 多商品订单再次支付
createSumOrderAgain: {
url: '/index_common/createSumOrderAgain',
method: 'POST',
auth: true,
limit: 1000,
showLoading: true,
},
// 确认收货
confirmOrder: {
url: '/index_common/confirmOrder',
method: 'GET',
auth: true,
limit: 1000,
showLoading: true,
},
// 取消订单
cancelOrder: {
url: '/index_common/cancelOrder',
method: 'GET',
auth: true,
limit: 1000,
showLoading: true,
},
// 获取首页广告列表
getRiceProductList: {
url: '/index_common/getRiceAdList',
method: 'GET',
},
// 获取首页广告列表
getRiceAdDetail: {
url: '/index_common/getRiceAdDetail',
method: 'GET',
},
//获取优惠券信息
getRiceCouponList: {
url: '/info_common/getRiceCouponList',
method: 'GET',
},
//增加或者修改合伙人申请信息
addOrUpdateCommonUser: {
url: '/index_common/addOrUpdateCommonUser',
method: 'POST',
},
//根据用户查询渠合伙人申请信息表单
getCommonUser: {
url: '/index_common/getCommonUser',
method: 'GET'
},
//提交反馈信息
addFeedback: {
url: '/info_common/addFeedback',
method: 'POST'
},
// 获取我的直接推荐间接推荐用户列表带分页
getHanHaiMemberUser: {
url: '/info_common/getHanHaiMemberUser',
method: 'GET'
},
// 获取祝福背景图
getRiceBlessing: {
url: '/index_common/getRiceBlessing',
method: 'GET'
},
// 随机获取祝福语
getRiceBlessingWords: {
url: '/index_common/getRiceBlessingWords',
method: 'GET'
},
// 根据订单标识修改订单祝福语背景
updateOrderBlessing: {
url: '/index_common/updateOrderBlessing',
method: 'POST',
auth : true,
limit : 1000,
},
// 1.收礼流程 =》点击收礼
getGiveShop: {
url: '/index_common/getGiveShop',
method: 'GET',
auth : true,
limit : 1000,
},
// 2.点击抽奖 =》抽奖
getGiveShopLottery: {
url: '/index_common/getGiveShopLottery',
method: 'GET',
auth : true,
limit : 1000,
},
// 获取我的礼品订单
getMyGiftOrder: {
url: '/index_common/getMyGiftOrder',
method: 'GET',
auth : true,
},
// 获取我的礼品订单详情
getMyGiftOrderDetail: {
url: '/index_common/getMyGiftOrderDetail',
method: 'GET',
auth : true,
limit: 500,
},
}

+ 0
- 115
api/model/info.js View File

@ -1,115 +0,0 @@
// 个人相关接口
const api = {
// 充值
recharge: {
url: '/info_common/withdraw',
method: 'GET',
auth: true,
limit: 1000,
showLoading: true,
},
// 提现
withdraw: {
url: '/info_common/withdraw',
method: 'GET',
auth: true,
limit: 1000,
showLoading: true,
},
// 获取地址列表带分页
getAddressPageList: {
url: '/info_common/getAddressPageList',
method: 'GET',
auth: true,
},
// 增加或修改地址信息
addOrUpdateAddress: {
url: '/info_common/addOrUpdateAddress',
method: 'POST',
limit: 500,
auth: true,
showLoading: true,
},
// 删除地址
deleteAddress: {
url: '/info_common/deleteAddress',
method: 'GET',
limit: 500,
auth: true,
showLoading: true,
},
// 修改默认地址
updateDefaultAddress: {
url: '/info_common/updateDefaultAddress',
method: 'GET',
auth: true,
limit: 1000,
},
// 获取粉丝列表带分页
getFansPageList: {
url: '/info_common/getFansPageList',
method: 'GET',
auth: true,
},
// 获取相关介绍
getInfoIntroduce: {
url: '/info_common/getInfoIntroduce',
method: 'GET',
auth: true,
},
// 获取个人邀请码
getInviteCode: {
url: '/info_common/getInviteCode',
method: 'GET',
auth: true,
},
// 获取订单列表带分页
getOrderPageList: {
url: '/info_common/getOrderPageList',
method: 'GET',
auth: true,
},
// 获取订单详情
getOrderDetail: {
url: '/info_common/getOrderDetail',
method: 'GET',
auth: true,
},
// 获取流水记录带分页
getWaterPageList: {
url: '/info_common/getWaterPageList',
method: 'GET',
auth: true,
},
// 获取相关介绍
getInfoIntroduce: {
url: '/info_common/getInfoIntroduce',
method: 'GET',
},
// 获取相关介绍详情
getInfoIntroduceDetail: {
url: '/info_common/getRiceNewsDetail',
method: 'GET',
},
// 查询个人信息相关
getRiceInfo: {
url: '/info_common/getRiceInfo',
method: 'GET',
limit: 500,
},
// 获取购物车信息列表带分页
getCartPageList: {
url: '/info_common/getCartPageList',
method: 'GET',
},
// 领取新人优惠券
getRiceCoupon: {
url: '/info_common/getRiceCoupon',
method: 'GET',
limit: 500,
auth: true,
},
}
export default api

+ 2
- 2
api/model/login.js View File

@ -3,13 +3,13 @@
const api = {
// 微信登录接口
wxLogin: {
url: '/login_common/appletLogin',
url: '/teambuy/login/login',
method: 'GET',
limit: 500,
},
// 获取绑定手机号码
bindPhone: {
url: '/login_common/bindPhone',
url: '/teambuy/login/bindPhone',
method: 'GET',
// auth: true,
},


+ 12
- 0
api/model/order.js View File

@ -0,0 +1,12 @@
// 首页相关接口
const api = {
// 订单-查询团餐订单列表-详情
queryLeaderOrderList: {
url: '/teambuy/order/queryLeaderOrderList',
method: 'GET',
limit: 500,
},
}
export default api

+ 0
- 20
api/model/vip.js View File

@ -1,20 +0,0 @@
// vip相关接口
const api = {
// 获取会员权益列表
getRiceVipList: {
url: '/index_common/getVipInfoList',
method: 'GET',
},
// 申请成为会员
applyRiceVip: {
url: '/rice_vip/applyRiceVip',
method: 'POST',
limit : 500,
auth : true,
showLoading : true,
},
}
export default api

+ 0
- 4
components/base/tabbar.vue View File

@ -17,14 +17,10 @@
</template>
<script>
import {
mapGetters
} from 'vuex'
export default {
name: "tabbar",
props: ['select'],
computed: {
...mapGetters(['userShop']),
},
data() {
return {


+ 157
- 0
components/config/PrivacyPopup.vue View File

@ -0,0 +1,157 @@
<template>
<view class="privacy-popup">
<uv-popup ref="privacyPopup"
mode="center"
:round="10"
:closeable="false"
:maskClick="false"
:closeOnClickOverlay="false"
:safeAreaInsetBottom="false"
:customStyle="{backgroundColor: '#fff', padding: 0, width: '85%'}"
overlayOpacity="0.7">
<view class="privacy-container">
<!-- 标题 -->
<view class="privacy-title">
{{ title }}
</view>
<!-- 内容区域 - 使用插槽 -->
<scroll-view scroll-y class="privacy-content">
<slot></slot>
</scroll-view>
<!-- 底部按钮 -->
<view class="privacy-actions">
<view class="action-btn reject-btn" hover-class="active-btn" @tap="handleReject">{{ rejectText }}</view>
<view class="action-btn agree-btn" hover-class="active-btn" @tap="handleAgree">{{ agreeText }}</view>
</view>
</view>
</uv-popup>
</view>
</template>
<script>
export default {
name: 'PrivacyPopup',
props: {
//
title: {
type: String,
default: '隐私政策'
},
//
rejectText: {
type: String,
default: '拒绝'
},
//
agreeText: {
type: String,
default: '同意'
}
},
data() {
return {
}
},
methods: {
//
open() {
this.$refs.privacyPopup.open();
},
//
close() {
this.$refs.privacyPopup.close();
},
//
handleReject() {
this.$emit('reject');
this.close();
},
//
handleAgree() {
this.$emit('agree');
this.close();
}
}
}
</script>
<style lang="scss" scoped>
.privacy-popup {
// padding: 0;
.privacy-container {
display: flex;
flex-direction: column;
justify-content: space-between;
width: 100%;
background-color: #fff;
}
.privacy-title {
font-size: 36rpx;
font-weight: bold;
text-align: center;
padding: 30rpx 0;
// border-bottom: 1rpx solid #e6e6e6;
background-color: #fff;
}
.privacy-content {
flex: 1;
padding: 30rpx;
box-sizing: border-box;
height: 600rpx;
background-color: #fff;
max-height: 50vh;
}
.privacy-actions {
display: flex;
border-top: 4rpx solid #e6e6e6;
height: 100rpx;
background-color: #fff;
.action-btn {
flex: 1;
display: flex;
justify-content: center;
align-items: center;
font-size: 32rpx;
position: relative;
background-color: #fff;
transition: all 0.3s ease;
// &::after {
// content: '';
// position: absolute;
// right: 0;
// top: 20rpx;
// bottom: 20rpx;
// width: 1rpx;
// background-color: #e6e6e6;
// }
&:last-child::after {
display: none;
}
}
.reject-btn {
color: #999;
// background-color: red;
border-right: 4rpx solid #e6e6e6;
}
.agree-btn {
color: $uni-color;
}
.active-btn {
background-color: $uni-color;
color: #fff;
}
}
}
</style>

+ 1
- 1
components/product/productItem.vue View File

@ -5,7 +5,7 @@
<!-- <image :src="item.image &&
item.image.split(',')[0]" mode="aspectFill">
</image> -->
<image src="@/static/image/红烧肉.png" mode="aspectFill" class="item-image-img">
<image src="@/static/image/红烧肉.webp" mode="aspectFill" class="item-image-img">
</image>
</view>


+ 1
- 1
config.js View File

@ -18,7 +18,7 @@ const config = {
baseUrl: 'http://h5.xzaiyp.top/jewelry-admin',
},
test: {
baseUrl: 'https://jewelry-admin.hhlm1688.com/jewelry-admin',
baseUrl: 'https://www.gwrx666.com/teambuy-api',
},
prod: {
baseUrl: 'https://admin.momeirenzhubao.com/jewelry-admin',


+ 1
- 1
main.js View File

@ -14,8 +14,8 @@ import store from '@/store/store'
import './config'
import './utils/index.js'
// 全局混入
import mixinConfigList from '@/mixins/configList.js'
Vue.mixin(mixinConfigList)
//组件注册


+ 16
- 13
mixins/configList.js View File

@ -1,5 +1,8 @@
// 这个已经在全局混入了
import { mapState } from 'vuex'
export default {
data() {
@ -13,21 +16,21 @@ export default {
}
},
computed: {
...mapState(['configList', 'userInfo', 'riceInfo']),
currentPagePath() {
const pages = getCurrentPages();
const currentPage = pages[pages.length - 1];
let path = `/${currentPage.route}`;
...mapState(['configList', 'userInfo']),
// currentPagePath() {
// const pages = getCurrentPages();
// const currentPage = pages[pages.length - 1];
// let path = `/${currentPage.route}`;
// 获取当前页面的参数
const options = currentPage.options;
if (options && Object.keys(options).length > 0) {
const params = this.$utils.objectToUrlParams(options);
path += `?${params}`;
}
// // 获取当前页面的参数
// const options = currentPage.options;
// if (options && Object.keys(options).length > 0) {
// const params = this.$utils.objectToUrlParams(options);
// path += `?${params}`;
// }
return path;
},
// return path;
// },
},
// 定义全局分享
// 1.发送给朋友


+ 28
- 26
pages/index/category.vue View File

@ -5,7 +5,7 @@
<!-- 搜索栏 -->
<view class="search">
<image src="/static/image/logo.png" mode="aspectFill" class="search-img" @tap="testUtiles" />
<image src="/static/image/logo.webp" mode="aspectFill" class="search-img" @tap="testUtiles" />
<view style="position: relative;">
<uv-search placeholder="陕西苹果" bgColor="#fff" @search="search" @change="search" @custom="search"
:searchIconSize="40" v-model="queryParams.title" height="75rpx" :showAction="false"
@ -29,7 +29,7 @@
@tap="clickTabs"></uv-tabs>
</view> -->
<uv-vtabs :list="category[2].children" :barStyle="{
<uv-vtabs :list="category" :barStyle="{
boxShadow: '0 0 18rpx 0rpx rgba(0, 0, 0, 0.1)',
fontWeight: '600',
textAlign: 'center',
@ -48,10 +48,19 @@
<uv-vtabs-item>
<view class="category-item">
<productItem :item="pro" v-for="(pro, i) in categoryList.shopList" :key="i"
@tap="navigateToDetail(pro.id)" />
<uv-empty v-if="categoryList.shopList.length == 0" text="还没有呢" />
<!-- 这里加载更多数据需要你使用scroll-view 因为你的列表在uv-vtabs里面 -->
<scroll-view
scroll-y="true"
@scrolltolower="loadMoreData"
style="height: calc(100vh - 470rpx);">
<productItem :item="pro" v-for="(pro, i) in list" :key="i"
@tap="navigateToDetail(pro.id)" />
</scroll-view>
<uv-empty v-if="list.length == 0" text="还没有呢" />
</view>
</uv-vtabs-item>
</uv-vtabs>
@ -64,6 +73,8 @@
<script>
import productItem from '@/components/product/productItem.vue';
// list
import mixinsList from '@/mixins/list.js'
import {
mapState
@ -79,46 +90,37 @@ export default {
},
data() {
return {
mixinsListApi: 'getClassShopPageList',
//
mixinsListApi: 'queryGoodsList',
current: 0,
currentChildren: 0,
}
},
computed: {
...mapState(['category']),
categoryList() {
// return this.category[this.current].children[this.currentChildren]
return this.category[2].children[this.currentChildren]
},
},
onLoad({
search,
cid
}) {
if (search) {
this.queryParams.title = search
}
// this.$store.commit('getCategoryList')
if (this.category.length > 0 && cid) {
this.category.forEach((n, i) => {
if (n.id == cid) {
this.current = i
}
})
// this.queryParams.classId = cid
} else if (this.category.length > 0) {
// this.queryParams.classId = this.category[0].id
}
//
// this.queryParams.test = 11111
},
methods: {
change(e) {
// this.queryParams.classId = this.category[e].id
this.currentChildren = e
//
this.getData()
},
clickTabs({ index }) {
this.current = index
this.currentChildren = 0
//
this.getData()
},
search() {
for (let i = 0; i < 10; i++) {


+ 3
- 3
pages/index/center.vue View File

@ -1,7 +1,7 @@
<template>
<view class="center-page">
<!-- 顶部背景和个人信息 -->
<view class="header" :style="{ 'background-image': 'url(/static/image/红烧肉.png)' }">
<view class="header" :style="{ 'background-image': 'url(/static/image/红烧肉.webp)' }">
<view class="user-info">
<image class="avatar" :src="userInfo.avatarUrl" mode="aspectFill"></image>
@ -183,14 +183,13 @@
<script>
import tabber from '@/components/base/tabbar.vue'
import { mockUserInfo } from '@/static/js/mockUserInfo.js'
import shareConfig from '@/mixins/configList.js'
// import { unix } from 'dayjs'
export default {
components: {
tabber
},
mixins: [shareConfig],
data() {
return {
userInfo: mockUserInfo,
@ -231,6 +230,7 @@ export default {
}
},
onLoad (){
this.$store.commit('getUserInfo')
uni.setStorageSync('identity', 0) //
this.identity = uni.getStorageSync('identity') //
}


+ 1
- 1
pages/index/order.vue View File

@ -155,7 +155,7 @@
4: 'completed' //
},
current: 0,
mixinsListApi: 'getOrderPageList',
mixinsListApi: 'queryLeaderOrderList',
orderList: [],
groupMeals: [],
identity: uni.getStorageSync('identity')


+ 97
- 82
pages_order/auth/wxLogin.vue View File

@ -1,108 +1,123 @@
<template>
<view class="login">
<view class="logo">
<image :src="configList.logo_image" mode=""></image>
<image :src="configList.config_logo" mode="aspectFill" />
</view>
<!-- <view class="title">
欢迎使用{{ configList.logo_name }}
</view> -->
<view class="title">
<!-- 欢迎使用{{ configList.logo_name }} -->
敢为人鲜
欢迎使用{{ $store.state.configList.config_app_name }}
</view>
<view class="btn mt"
@tap="wxLogin">
<!-- <view class="icon">
<image src="../static/auth/wx.png" mode=""></image>
</view> -->
<view class="btn mt" @tap="wxLogin">
<view class="">
手机号授权登录
</view>
</view>
<view class="btn b2"
@tap="qux">
<view class="btn b2" @tap="qux">
取消登录
<view class="config">
<uv-checkbox-group
v-model="checkboxValue"
shape="circle">
<view class="content">
<view
style="display: flex; align-items: start;">
<uv-checkbox
size="34rpx"
icon-size="26rpx"
activeColor="#019245"
:name="1"
style="margin-top: 6rpx;"
></uv-checkbox>
<text class="text-privacy">阅读并同意我们的<text @tap="$refs.popup.open('user_xy')">服务协议与隐私条款</text>以及<text @tap="$refs.popup.open('user_ys')">个人信息保护指引</text></text>
</view>
<!-- <view class="">
<view class="config" @tap.stop>
<uv-checkbox-group v-model="checkboxValue" shape="circle">
<view class="content">
<view style="display: flex; align-items: start;">
<uv-checkbox size="34rpx" icon-size="26rpx" activeColor="#019245" :name="1"
style="margin-top: 6rpx;" />
<!-- <text class="text-privacy">阅读并同意我们的<text
@tap="$refs.popup.open('user_xy')">服务协议与隐私条款</text>以及<text
@tap="$refs.popup.open('user_ys')">个人信息保护指引</text></text> -->
<text class="text-privacy">
阅读并同意我们的
<text @tap="openPrivacyPopup(0)">
服务协议与隐私条款
</text>
以及
<text @tap="openPrivacyPopup(1)">
个人信息保护指引
</text>
</text>
</view>
<!-- <view class="">
以及<text @tap="$refs.popup.open('user_ys')">隐私政策</text>
</view> -->
</view>
</uv-checkbox-group>
</view>
</view>
</uv-checkbox-group>
</view>
</view>
<configPopup ref="popup"></configPopup>
<configPopup ref="popup" />
<PrivacyPopup ref="privacyPopup" :title="title">
<view>
<view>
<text>{{ serviceAgreement }}</text>
</view>
</view>
</PrivacyPopup>
</view>
</template>
<script>
export default {
name : 'Login',
data() {
return {
checkboxValue : [],
config : {},
import PrivacyPopup from '@/components/config/PrivacyPopup.vue'
export default {
name : 'Login',
components: {
PrivacyPopup
},
data() {
return {
checkboxValue : [],
config : {},
serviceAgreement:
'用户服务协议为使用小程序名称的服务,您应当阅读并遵守《用户服务协议》(以下简称"本协议")。请您务必审慎阅读、充分理解各条款内容,特别是免除或者限制责任的条款,所有加粗字体为我方重点提示的内容。如果您未满18周岁,或者不具备完全民事行为能力,请在法定监护人的陪同下阅读本协议,并特别注意未成年人使用条款。否则小程序名称对于该等后续注册、使用网站服务等行为而对您所发生的不利后果不承担责任,并有权在知晓该等情况后解除双方间的服务协议。一、【协议的范围】本协议及《隐私政策》是您与小程序名称经营者之间关于用户使用小程序名称旗下产品相关服务所订立的协议。小程序名称的经营者是指法律认可的经营瀚用户服务协议为使用小程序名称的服务,您应当阅读并遵守《用户服务协议》(以下简称"本协议")。请您务必审慎阅读、充分理解各条款内容,特别是免除或者限制责任的条款,所有加粗字体为我方重点提示的内容。如果您未满18周岁,或者不具备完全民事行为能力,请在法定监护人的陪同下阅读本协议,并特别注意未成年人使用条款。否则小程序名称对于该等后续注册、使用网站服务等行为而对您所发生的不利后果不承担责任,并有权在知晓该等情况后解除双方间的服务协议。一、【协议的范围】本协议及《隐私政策》是您与小程序名称经营者之间关于用户使用小程序名称旗下产品相关服务所订立的协议。小程序名称的经营者是指法律认可的经营瀚',
personalInformationProtectionGuidelines: '用户服务协议为使用小程序名称的服务,您应当阅读并遵守《用户服务协议》(以下简称"本协议")。请您务必审慎阅读、充分理解各条款内容,特别是免除或者限制责任的条款,所有加粗字体为我方重点提示的内容。如果您未满18周岁,或者不具备完全民事行为能力,请在法定监护人的陪同下阅读本协议,并特别注意未成年人使用条款。否则小程序名称对于该等后续注册、使用网站服务等行为而对您所发生的不利后果不承担责任,并有权在知晓该等情况后解除双方间的服务协议。一、【协议的范围】本协议及《隐私政策》是您与小程序名称经营者之间关于用户使用小程序名称旗下产品相关服务所订立的协议。小程序名称的经营者是指法律认可的经营瀚用户服务协议为使用小程序名称的服务,您应当阅读并遵守《用户服务协议》(以下简称"本协议")。请您务必审慎阅读、充分理解各条款内容,特别是免除或者限制责任的条款,所有加粗字体为我方重点提示的内容。如果您未满18周岁,或者不具备完全民事行为能力,请在法定监护人的陪同下阅读本协议,并特别注意未成年人使用条款。否则小程序名称对于该等后续注册、使用网站服务等行为而对您所发生的不利后果不承担责任,并有权在知晓该等情况后解除双方间的服务协议。一、【协议的范围】本协议及《隐私政策》是您与小程序名称经营者之间关于用户使用小程序名称旗下产品相关服务所订立的协议。小程序名称的经营者是指法律认可的经营瀚',
title: '服务协议'
}
},
onLoad(query) {
if (query.shareId) {
uni.setStorageSync('shareId', query.shareId) // Id
}
if(query.path){
this.config = query //
}
console.log(this.configList.config_app_name);
},
methods: {
openPrivacyPopup(index){
if (index == 0) {
this.title = '服务协议'
} else {
this.title = '隐私政策'
}
this.$refs.privacyPopup.open()
},
onLoad(query) {
if (query.shareId) {
uni.setStorageSync('shareId', query.shareId) // Id
}
if(query.path){
this.config = query //
}
getPhoneNumber(e){
console.log(e, e.detail.code);
this.wxLogin(phoneCode)
},
methods: {
getPhoneNumber(e){
console.log(e, e.detail.code);
this.wxLogin(phoneCode)
},
wxLogin(phoneCode){
if(!this.checkboxValue.length){
return uni.showToast({
title: '请先同意隐私协议',
icon:'none'
})
}
this.$store.commit('login', this.config)
},
//
openConfigDetail(key){
this.$refs.popup.open(key)
},
qux(){
uni.reLaunch({
url: '/pages/index/index'
wxLogin(phoneCode){
if(!this.checkboxValue.length){
return uni.showToast({
title: '请先同意隐私协议',
icon:'error'
})
},
}
}
this.$store.commit('login', this.config)
},
//
openConfigDetail(key){
this.$refs.popup.open(key)
},
qux(){
uni.reLaunch({
url: '/pages/index/category'
})
},
}
}
</script>
<style scoped lang="scss">


+ 50
- 29
pages_order/auth/wxUserInfo.vue View File

@ -3,23 +3,29 @@
<!-- <view class="logo">
<image :src="configList.logo_image" mode=""></image>
</view> -->
<view class="title">
{{ configList.logo_name }}
<view class="logo">
<image src="@/static/image/logo.webp" mode="aspectFill"></image>
</view>
<view class="title" v-if="configList.config_app_name">
{{ configList.config_app_name }}
</view>
<view class="app-name" v-else>
敢为人鲜
</view>
<view class="title">
申请获取你的头像昵称
申请获取的头像昵称
</view>
<button class="chooseAvatar" open-type="chooseAvatar" @chooseavatar="onChooseAvatar">
<view class="line">
<button class=" reset-button" open-type="chooseAvatar" @chooseavatar="onChooseAvatar" style="margin-top: 80rpx;">
<view class="line" style="border-top: 2rpx solid #00000020;">
<view class="">
头像
</view>
<view class="">
<image :src="userInfoForm.headImage" v-if="userInfoForm.headImage" style="width: 60rpx;height: 60rpx;"
mode=""></image>
mode="" />
<image src="../static/auth/headImage.png" v-else style="width: 50rpx;height: 50rpx;" mode=""></image>
<image src="../static/auth/headImage.png" v-else style="width: 50rpx;height: 50rpx;" mode="" />
</view>
</view>
</button>
@ -47,18 +53,17 @@
<view class=""
v-else>
<button
class="getPhoneNumber"
class="getPhoneNumber reset-button"
open-type="getPhoneNumber"
@getphonenumber="getPhone">
获取电话号码
获取手机号
</button>
</view>
</view>
<view class="btn" @tap="submit">
</view>
</view>
</template>
@ -149,21 +154,27 @@
flex-direction: column;
justify-content: center;
align-items: center;
height: 80vh;
height: 90vh;
.app-name{
font-size: 40rpx;
color: black;
font-weight: 500;
margin-bottom: 20rpx;
}
.logo{
height: 140rpx;
width: 140rpx;
height: 300rpx;
width: 300rpx;
image{
height: 140rpx;
width: 140rpx;
border-radius: 30rpx;
height: 300rpx;
width: 300rpx;
border-radius: 50%;
}
margin-bottom: 20rpx;
margin: 30rpx 0;
}
.title {
line-height: 45rpx;
font-weight: 900;
// font-weight: 900;
}
.line {
@ -171,16 +182,26 @@
justify-content: space-between;
align-items: center;
width: 80%;
border-bottom: 1px solid #00000023;
padding: 30rpx 0;
border-bottom: 2rpx solid #00000020;
padding: 25rpx 0;
margin: 0 auto;
}
.chooseAvatar {
.reset-button {
width: 100%;
padding: 0;
margin: 0;
margin-top: 10vh;
margin-top: 6vh;
// background-color: transparent;
// padding: 0;
margin: 0;
line-height: normal;
font-size: inherit;
color: inherit;
}
/* 去除按钮边框 */
.reset-button::after {
border: none;
}
@ -188,10 +209,10 @@
// background: $uni-linear-gradient-btn-color;
background: $uni-color;
color: #fff;
width: 80%;
padding: 20rpx 0;
width: 76%;
padding: 30rpx 0;
text-align: center;
border-radius: 15rpx;
border-radius: 50rpx;
margin-top: 10vh;
}
.getPhoneNumber{
@ -203,8 +224,8 @@
background: $uni-color;
color: #fff;
width: 200rpx;
height: 60rpx;
border-radius: 30rpx;
height: 90rpx;
border-radius: 45rpx;
font-size: 24rpx;
}
}

+ 1
- 1
pages_order/components/order/placeOrder.vue View File

@ -35,7 +35,7 @@
<!-- 货品信息 -->
<view class="item">
<image src="@/static/image/红烧肉.png" mode="aspectFill" class="item-image"></image>
<image src="@/static/image/红烧肉.webp" mode="aspectFill" class="item-image"></image>
<view style="font-size: 36rpx;">
<view>豆角炒鸡蛋</view>
<view style="color: red; ">9.9</view>


+ 1
- 1
pages_order/mine/team.vue View File

@ -6,7 +6,7 @@
<!-- 顶部图片区域 -->
<view class="banner" v-if="!identity">
<image src="/static/image/红烧肉.png" mode="aspectFill" class="banner-image"></image>
<image src="/static/image/红烧肉.webp" mode="aspectFill" class="banner-image"></image>
</view>
<view class="content-area">


+ 1
- 1
pages_order/mine/wallet.vue View File

@ -4,7 +4,7 @@
<navbar title="钱包" leftClick @leftClick="$utils.navigateBack" bgColor="#019245" color="#fff" />
<!-- 总余额展示区 -->
<view class="balance-card" :style="{ backgroundImage: 'url(/static/image/红烧肉.png)' }">
<view class="balance-card" :style="{ backgroundImage: 'url(/static/image/红烧肉.webp)' }">
<view class="balance-info">
<view class="balance-title">总余额</view>
<view class="balance-amount">{{ walletData.balance.toFixed(2) }}</view>


+ 5
- 5
pages_order/order/newOrderDetail.vue View File

@ -145,7 +145,7 @@
{
id: 1,
name: '茄子肉沫',
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
price: 9.9,
count: 1,
soldCount: 100
@ -153,7 +153,7 @@
{
id: 2,
name: '豆角炒鸡蛋',
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
price: 9.9,
count: 1,
soldCount: 100
@ -161,7 +161,7 @@
{
id: 3,
name: '酸辣土豆丝',
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
price: 9.9,
count: 1,
soldCount: 100
@ -169,7 +169,7 @@
{
id: 3,
name: '酸辣土豆丝',
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
price: 9.9,
count: 1,
soldCount: 100
@ -177,7 +177,7 @@
{
id: 3,
name: '酸辣土豆丝',
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
price: 9.9,
count: 1,
soldCount: 100


BIN
static/image/logo.png View File

Before After
Width: 561  |  Height: 447  |  Size: 266 KiB

BIN
static/image/logo.webp View File

Before After

BIN
static/image/红烧肉.png View File

Before After
Width: 660  |  Height: 880  |  Size: 932 KiB

BIN
static/image/红烧肉.webp View File

Before After

+ 9
- 3
static/js/mockAssets.js View File

@ -1,5 +1,5 @@
// 资产明细的mock数据
export const assetsData = {
const assetsData = {
// 收入明细
incomeList: [
{
@ -58,7 +58,7 @@ export const assetsData = {
}
// 这是团长用的静态资产明细
export const assetsDataForHead = {
const assetsDataForHead = {
// 收入明细
incomeList: [
{
@ -114,4 +114,10 @@ export const assetsDataForHead = {
time: '2020-12-15 18:22:10'
}
]
}
}
// 统一导出
module.exports = {
assetsData,
assetsDataForHead
}

+ 11
- 6
static/js/mockCartData.js View File

@ -1,4 +1,4 @@
export const mockCartData = {
const mockCartData = {
totalPrice: 0.0,
selectedCount: 0,
items: [
@ -6,7 +6,7 @@ export const mockCartData = {
id: 1,
name: '豆角炒鸡蛋',
price: 9.9,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
quantity: 1,
sold: 235
},
@ -14,7 +14,7 @@ export const mockCartData = {
id: 2,
name: '豆角炒鸡蛋',
price: 9.9,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
quantity: 1,
sold: 235
},
@ -22,7 +22,7 @@ export const mockCartData = {
id: 3,
name: '豆角炒鸡蛋',
price: 9.9,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
quantity: 1,
sold: 235
},
@ -30,9 +30,14 @@ export const mockCartData = {
id: 4,
name: '豆角炒鸡蛋',
price: 9.9,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
quantity: 1,
sold: 235
}
]
}
}
// 统一导出
module.exports = {
mockCartData
}

+ 11
- 4
static/js/mockCoupon.js View File

@ -1,5 +1,5 @@
// 未使用优惠券
export const unusedCoupons = [
const unusedCoupons = [
{
id: '001',
amount: 2,
@ -24,7 +24,7 @@ export const unusedCoupons = [
]
// 已使用优惠券
export const usedCoupons = [
const usedCoupons = [
{
id: '004',
amount: 5,
@ -42,7 +42,7 @@ export const usedCoupons = [
]
// 已过期优惠券
export const expiredCoupons = [
const expiredCoupons = [
{
id: '006',
amount: 3,
@ -57,4 +57,11 @@ export const expiredCoupons = [
validTime: '2024/1/15 23:59',
status: 2
}
]
]
// 统一导出
module.exports = {
unusedCoupons,
usedCoupons,
expiredCoupons
}

+ 53
- 45
static/js/mockOrders.js View File

@ -1,16 +1,16 @@
export const mockOrders = [
const mockOrders = [
{
id: '20241223184523001',
shopName: '轻奢时代芙蓉兴盛',
shopLogo: '/static/image/古茗店面.webp',
foods: [
{ id: 1, name: '红烧肉', image: '/static/image/红烧肉.png' },
{ id: 2, name: '青椒炒肉', image: '/static/image/红烧肉.png' },
{ id: 3, name: '香菇炒肉', image: '/static/image/红烧肉.png' },
{ id: 4, name: '豆角炒肉', image: '/static/image/红烧肉.png' },
{ id: 5, name: '豆角炒肉', image: '/static/image/红烧肉.png' },
{ id: 6, name: '豆角炒肉', image: '/static/image/红烧肉.png' },
{ id: 7, name: '豆角炒肉', image: '/static/image/红烧肉.png' }
{ id: 1, name: '红烧肉', image: '/static/image/红烧肉.webp' },
{ id: 2, name: '青椒炒肉', image: '/static/image/红烧肉.webp' },
{ id: 3, name: '香菇炒肉', image: '/static/image/红烧肉.webp' },
{ id: 4, name: '豆角炒肉', image: '/static/image/红烧肉.webp' },
{ id: 5, name: '豆角炒肉', image: '/static/image/红烧肉.webp' },
{ id: 6, name: '豆角炒肉', image: '/static/image/红烧肉.webp' },
{ id: 7, name: '豆角炒肉', image: '/static/image/红烧肉.webp' }
],
foodCount: 10,
orderTime: '2024-12-23 18:45:23',
@ -22,13 +22,13 @@ export const mockOrders = [
shopName: '轻奢时代芙蓉兴盛',
shopLogo: '/static/image/古茗店面.webp',
foods: [
{ id: 1, name: '红烧肉', image: '/static/image/红烧肉.png' },
{ id: 2, name: '青椒炒肉', image: '/static/image/红烧肉.png' },
{ id: 3, name: '香菇炒肉', image: '/static/image/红烧肉.png' },
{ id: 4, name: '豆角炒肉', image: '/static/image/红烧肉.png' },
{ id: 5, name: '豆角炒肉', image: '/static/image/红烧肉.png' },
{ id: 6, name: '豆角炒肉', image: '/static/image/红烧肉.png' },
{ id: 7, name: '豆角炒肉', image: '/static/image/红烧肉.png' }
{ id: 1, name: '红烧肉', image: '/static/image/红烧肉.webp' },
{ id: 2, name: '青椒炒肉', image: '/static/image/红烧肉.webp' },
{ id: 3, name: '香菇炒肉', image: '/static/image/红烧肉.webp' },
{ id: 4, name: '豆角炒肉', image: '/static/image/红烧肉.webp' },
{ id: 5, name: '豆角炒肉', image: '/static/image/红烧肉.webp' },
{ id: 6, name: '豆角炒肉', image: '/static/image/红烧肉.webp' },
{ id: 7, name: '豆角炒肉', image: '/static/image/红烧肉.webp' }
],
foodCount: 10,
orderTime: '2024-12-23 18:45:23',
@ -40,13 +40,13 @@ export const mockOrders = [
shopName: '轻奢时代芙蓉兴盛',
shopLogo: '/static/image/古茗店面.webp',
foods: [
{ id: 1, name: '红烧肉', image: '/static/image/红烧肉.png' },
{ id: 2, name: '青椒炒肉', image: '/static/image/红烧肉.png' },
{ id: 3, name: '香菇炒肉', image: '/static/image/红烧肉.png' },
{ id: 4, name: '豆角炒肉', image: '/static/image/红烧肉.png' },
{ id: 5, name: '豆角炒肉', image: '/static/image/红烧肉.png' },
{ id: 6, name: '豆角炒肉', image: '/static/image/红烧肉.png' },
{ id: 7, name: '豆角炒肉', image: '/static/image/红烧肉.png' }
{ id: 1, name: '红烧肉', image: '/static/image/红烧肉.webp' },
{ id: 2, name: '青椒炒肉', image: '/static/image/红烧肉.webp' },
{ id: 3, name: '香菇炒肉', image: '/static/image/红烧肉.webp' },
{ id: 4, name: '豆角炒肉', image: '/static/image/红烧肉.webp' },
{ id: 5, name: '豆角炒肉', image: '/static/image/红烧肉.webp' },
{ id: 6, name: '豆角炒肉', image: '/static/image/红烧肉.webp' },
{ id: 7, name: '豆角炒肉', image: '/static/image/红烧肉.webp' }
],
foodCount: 10,
orderTime: '2024-12-23 18:45:23',
@ -58,10 +58,10 @@ export const mockOrders = [
shopName: '爷爷不泡茶奶茶店(鲁北路)',
shopLogo: '/static/image/古茗店面.webp',
foods: [
{ id: 1, name: '红烧肉', image: '/static/image/红烧肉.png' },
{ id: 2, name: '青椒炒肉', image: '/static/image/红烧肉.png' },
{ id: 3, name: '香菇炒肉', image: '/static/image/红烧肉.png' },
{ id: 4, name: '豆角炒肉', image: '/static/image/红烧肉.png' }
{ id: 1, name: '红烧肉', image: '/static/image/红烧肉.webp' },
{ id: 2, name: '青椒炒肉', image: '/static/image/红烧肉.webp' },
{ id: 3, name: '香菇炒肉', image: '/static/image/红烧肉.webp' },
{ id: 4, name: '豆角炒肉', image: '/static/image/红烧肉.webp' }
],
foodCount: 10,
orderTime: '2024-12-23 18:45:23',
@ -73,8 +73,8 @@ export const mockOrders = [
shopName: '芙蓉兴盛小文轩便利店',
shopLogo: '/static/image/古茗店面.webp',
foods: [
{ id: 5, name: '回锅肉', image: '/static/image/红烧肉.png' },
{ id: 6, name: '豆角炒鸡蛋', image: '/static/image/红烧肉.png' }
{ id: 5, name: '回锅肉', image: '/static/image/红烧肉.webp' },
{ id: 6, name: '豆角炒鸡蛋', image: '/static/image/红烧肉.webp' }
],
foodCount: 4,
orderTime: '2024-12-23 17:30:15',
@ -86,8 +86,8 @@ export const mockOrders = [
shopName: '晨光文具店',
shopLogo: '/static/image/古茗店面.webp',
foods: [
{ id: 5, name: '回锅肉', image: '/static/image/红烧肉.png' },
{ id: 6, name: '豆角炒鸡蛋', image: '/static/image/红烧肉.png' }
{ id: 5, name: '回锅肉', image: '/static/image/红烧肉.webp' },
{ id: 6, name: '豆角炒鸡蛋', image: '/static/image/红烧肉.webp' }
],
foodCount: 4,
orderTime: '2024-12-23 17:30:15',
@ -99,8 +99,8 @@ export const mockOrders = [
shopName: 'KFC肯德基中山路店',
shopLogo: '/static/image/古茗店面.webp',
foods: [
{ id: 5, name: '回锅肉', image: '/static/image/红烧肉.png' },
{ id: 6, name: '豆角炒鸡蛋', image: '/static/image/红烧肉.png' }
{ id: 5, name: '回锅肉', image: '/static/image/红烧肉.webp' },
{ id: 6, name: '豆角炒鸡蛋', image: '/static/image/红烧肉.webp' }
],
foodCount: 4,
orderTime: '2024-12-23 17:30:15',
@ -112,8 +112,8 @@ export const mockOrders = [
shopName: '轩宇蛋炒饭',
shopLogo: '/static/image/古茗店面.webp',
foods: [
{ id: 5, name: '回锅肉', image: '/static/image/红烧肉.png' },
{ id: 6, name: '豆角炒鸡蛋', image: '/static/image/红烧肉.png' }
{ id: 5, name: '回锅肉', image: '/static/image/红烧肉.webp' },
{ id: 6, name: '豆角炒鸡蛋', image: '/static/image/红烧肉.webp' }
],
foodCount: 4,
orderTime: '2024-12-23 17:30:15',
@ -122,7 +122,7 @@ export const mockOrders = [
},
];
export const mockFoodMember =
const mockFoodMember =
[
{
id: '1',
@ -189,21 +189,21 @@ export const mockFoodMember =
name: '茄子肉沫',
price: 9.9,
quantity: 1,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
sold: 235
},
{
name: '豆角炒鸡蛋',
price: 9.9,
quantity: 1,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
sold: 235
},
{
name: '酸辣土豆丝',
price: 9.9,
quantity: 1,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
sold: 235
}
]
@ -217,14 +217,14 @@ export const mockFoodMember =
name: '茄子肉沫',
price: 9.9,
quantity: 1,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
sold: 235
},
{
name: '豆角炒鸡蛋',
price: 9.9,
quantity: 1,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
sold: 235
}
]
@ -238,7 +238,7 @@ export const mockFoodMember =
name: '茄子肉沫',
price: 9.9,
quantity: 1,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
sold: 235
}
]
@ -252,7 +252,7 @@ export const mockFoodMember =
name: '茄子肉沫',
price: 9.9,
quantity: 1,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
sold: 235
}
]
@ -266,14 +266,14 @@ export const mockFoodMember =
name: '茄子肉沫',
price: 9.9,
quantity: 1,
image: '/static/image/红烧肉.png',
image: '/static/image/红烧肉.webp',
sold: 235
}
]
}
]
export const mockGroupMeals =
const mockGroupMeals =
[
{
id: '1',
@ -335,4 +335,12 @@ export const mockGroupMeals =
price: '18.00',
status: 'delivered'
},
]
]
// 统一导出
module.exports = {
mockOrders,
mockFoodMember,
mockGroupMeals
}

+ 8
- 3
static/js/mockShare.js View File

@ -1,5 +1,5 @@
// 推广链接相关数据
export const shareData = {
const shareData = {
// 用户信息
userInfo: {
avatar: '/static/image/中森明菜.webp',
@ -10,5 +10,10 @@ export const shareData = {
inviteCode: '888888',
// 小程序码图片,应当使用标准微信小程序码样式的图片
// qrCodeImage: '/static/image/miniprogram-qrcode.png' // 替换为标准微信小程序码图片
qrCodeImage: '/static/image/红烧肉.png'
}
qrCodeImage: '/static/image/红烧肉.webp'
}
// 统一导出
module.exports = {
shareData
}

+ 10
- 3
static/js/mockTeam.js View File

@ -1,4 +1,4 @@
export const currentPickupPoint = {
const currentPickupPoint = {
id: 1,
name: '轻奢时代茶香兴盛',
address: '长沙市雨花区时代阳光大道轻奢时代茶香兴盛',
@ -6,7 +6,7 @@ export const currentPickupPoint = {
image: '/static/image/古茗店面.webp'
}
// 附近取餐点列表
export const nearbyPickupPoints = [
const nearbyPickupPoints = [
{
id: 2,
name: '古茗中山街店',
@ -21,4 +21,11 @@ export const nearbyPickupPoints = [
phone: '15070023168',
image: '/static/image/古茗店面.webp'
}
]
]
// 统一导出
module.exports = {
currentPickupPoint,
nearbyPickupPoints
}

+ 8
- 3
static/js/mockTeamData.js View File

@ -1,9 +1,9 @@
// 团长的团队数据mock
export const teamData = {
const teamData = {
// 团队信息
teamInfo: {
shopName: '回美寿洪店',
shopImage: '/static/image/红烧肉.png', // 使用红烧肉图片代替
shopImage: '/static/image/红烧肉.webp', // 使用红烧肉图片代替
memberCount: 150
},
@ -70,4 +70,9 @@ export const teamData = {
joinTime: '2020.08.06'
}
]
}
}
// 统一导出
module.exports = {
teamData
}

+ 7
- 2
static/js/mockUserInfo.js View File

@ -1,4 +1,4 @@
export const mockUserInfo = {
const mockUserInfo = {
avatarUrl: "/static/image/中森明菜.webp",
nickName: "李向西",
userId: "123456",
@ -8,4 +8,9 @@ export const mockUserInfo = {
deliveringCount: 3,
pickupCount: 0,
completedCount: 0
}
}
// 统一导出
module.exports = {
mockUserInfo
}

+ 7
- 2
static/js/mockWallet.js View File

@ -1,5 +1,5 @@
// 钱包相关mock数据
export const walletData = {
const walletData = {
// 钱包余额
balance: 1500.00,
@ -33,4 +33,9 @@ export const walletData = {
'单日提现次数上限为5次,单笔提现上限200',
'直接提现至微信账户,无法提现至支付宝'
]
}
}
// 统一导出
module.exports = {
walletData
}

+ 12
- 9
store/store.js View File

@ -25,12 +25,12 @@ const store = new Vuex.Store({
...state.configList,
}
if (res.code == 200) {
res.result.forEach(n => {
configList[n.keyName] = n.keyContent;
configList[n.keyName + '_keyValue'] = n.keyValue;
res.result.records.forEach(n => {
state.configList[n.paramCode] = n.paramValueText ||
n.paramValue ||
n.paramValueImage
});
console.log(configList);
console.log('configList', state.configList);
}
state.configList = configList
uni.$emit('initConfig', state.configList)
@ -164,11 +164,11 @@ const store = new Vuex.Store({
getQrCode(state) {
let that = this;
// 注释掉登录检查
/*
if(!uni.getStorageSync('token')){
return
}
*/
uni.getImageInfo({
src: `${Vue.prototype.$config.baseUrl}/info_common/getInviteCode?token=${uni.getStorageSync('token')}`,
success : res => {
@ -180,9 +180,12 @@ const store = new Vuex.Store({
},
// 查询分类接口
getCategoryList(state) {
api('getCategoryPidList', res => {
api('queryCategoryList', {
pageNo : 1,
pageSize : 99999,
}, res => {
if (res.code == 200) {
state.category = res.result
state.category = res.result.records
}
})
},


Loading…
Cancel
Save