Compare commits
2 Commits
03c9a8e845
...
a4a81a5873
Author | SHA1 | Date | |
---|---|---|---|
a4a81a5873 | |||
f3c73df905 |
4
env/.env
vendored
@ -6,6 +6,7 @@ VITE_APP_ENV=development
|
||||
|
||||
# 接口地址
|
||||
VITE_API_BASE_URL=http://www.caipu.com:8545
|
||||
# VITE_API_BASE_URL=http://ceshi-recipeapi.lihaink.cn/
|
||||
|
||||
# 端口号
|
||||
VITE_APP_PORT=9527
|
||||
@ -13,8 +14,9 @@ VITE_APP_PORT=9527
|
||||
# h5是否需要配置代理
|
||||
VITE_APP_PROXY=true
|
||||
|
||||
# API代理前缀
|
||||
# API代理前缀
|
||||
VITE_API_PREFIX= http://www.caipu.com:8545
|
||||
# VITE_API_PREFIX= http://ceshi-recipeapi.lihaink.cn/
|
||||
|
||||
# 删除console
|
||||
VITE_DROP_CONSOLE=false
|
||||
|
2
env/.env.development
vendored
@ -2,7 +2,7 @@
|
||||
VITE_APP_ENV=development
|
||||
|
||||
# 接口地址
|
||||
VITE_API_BASE_URL=http://www.caipu.com:8545
|
||||
VITE_API_BASE_URL=http://ceshi-recipeapi.lihaink.cn
|
||||
|
||||
# 删除console
|
||||
VITE_DROP_CONSOLE=false
|
||||
|
2
env/.env.production
vendored
@ -2,7 +2,7 @@
|
||||
VITE_APP_ENV=production
|
||||
|
||||
# 接口地址
|
||||
VITE_API_BASE_URL=http://www.caipu.com:8545
|
||||
VITE_API_BASE_URL=http://ceshi-recipeapi.lihaink.cn
|
||||
|
||||
# 删除console
|
||||
VITE_DROP_CONSOLE=true
|
||||
|
@ -63,7 +63,7 @@
|
||||
"desc" : "获取您的位置"
|
||||
}
|
||||
},
|
||||
"requiredPrivateInfos" : [ "getLocation", "chooseAddress" , "chooseLocation" ]
|
||||
"requiredPrivateInfos" : ["login" ,"getLocation", "chooseAddress" , "chooseLocation" ]
|
||||
},
|
||||
"mp-alipay" : {
|
||||
"usingComponents" : true
|
||||
@ -81,7 +81,7 @@
|
||||
"h5" : {
|
||||
"router" : {
|
||||
"mode" : "hash",
|
||||
"base" : "/uniapp-vue3-template/"
|
||||
"base" : "/caipu_uni/"
|
||||
},
|
||||
"sdkConfigs" : {
|
||||
"maps" : {
|
||||
|
@ -62,28 +62,32 @@
|
||||
"style": {
|
||||
"navigationBarTitleText": "菜谱详情",
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},
|
||||
"needLogin": true
|
||||
},
|
||||
{
|
||||
"path": "goods/pay_order",
|
||||
"style": {
|
||||
"navigationBarTitleText": "订单详情",
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},
|
||||
"needLogin": true
|
||||
},
|
||||
{
|
||||
"path": "goods/order",
|
||||
"style": {
|
||||
"navigationBarTitleText": "订单详情",
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},
|
||||
"needLogin": true
|
||||
},
|
||||
{
|
||||
"path": "goods/order_detail",
|
||||
"style": {
|
||||
"navigationBarTitleText": "订单详情",
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},
|
||||
"needLogin": true
|
||||
}
|
||||
|
||||
|
||||
@ -102,20 +106,20 @@
|
||||
"borderStyle": "black",
|
||||
"backgroundColor": "#ffffff",
|
||||
"list": [{
|
||||
"iconPath": "static/images/tabbar/icon_home.png",
|
||||
"selectedIconPath": "static/images/tabbar/icon_home_selected.png",
|
||||
"iconPath": "static/images/tabbar/shouye.png",
|
||||
"selectedIconPath": "static/images/tabbar/shouye_selected.png",
|
||||
"pagePath": "pages/tab/home/index",
|
||||
"text": "菜单分类"
|
||||
},
|
||||
{
|
||||
"iconPath": "static/images/tabbar/icon_list.png",
|
||||
"selectedIconPath": "static/images/tabbar/icon_list_selected.png",
|
||||
"iconPath": "static/images/tabbar/bofang.png",
|
||||
"selectedIconPath": "static/images/tabbar/bofang_selected.png",
|
||||
"pagePath": "pages/tab/list/index",
|
||||
"text": "食谱清单"
|
||||
},
|
||||
{
|
||||
"iconPath": "static/images/tabbar/icon_me.png",
|
||||
"selectedIconPath": "static/images/tabbar/icon_me_selected.png",
|
||||
"iconPath": "static/images/tabbar/wode.png",
|
||||
"selectedIconPath": "static/images/tabbar/wode_selected.png",
|
||||
"pagePath": "pages/tab/user/index",
|
||||
"text": "我的"
|
||||
}]
|
||||
|
@ -1,240 +0,0 @@
|
||||
<template>
|
||||
<view >
|
||||
<view class="address-window popup-main bg-f" :class="address.address==true?'on':''">
|
||||
<view class='title font-500'>选择地址<text class='iconfont icon-ic_close popup-close' @tap='close'></text></view>
|
||||
<scroll-view scroll-y="true" class='list'>
|
||||
<view class='item acea-row row-between-wrapper' :class='active==index?"t-color":""' v-for="(item,index) in addressList"
|
||||
@tap='tapAddress(index,item.address_id)' :key='index'>
|
||||
<text class='iconfont icon-ic_location5' :class='active==index?"t-color":""'></text>
|
||||
<view class='address'>
|
||||
<view class='name font-bold' :class='active==index?"t-color":""'>{{item.real_name}}<text class='phone'>{{item.phone}}</text></view>
|
||||
<view class='line1'>{{item.province}}{{item.city}}{{item.district}}{{item.street || ''}}{{item.detail}}</view>
|
||||
</view>
|
||||
<text class='iconfont icon-complete' :class='active==index?"t-color":""'></text>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<!-- 无地址 -->
|
||||
<view class='pictrue' v-if="!is_loading && !addressList.length">
|
||||
<image :src="`${domain}/static/images/noAddress.png`"></image>
|
||||
<view>暂无地址</view>
|
||||
</view>
|
||||
<view class='addressBnt' @tap='goAddressPages'>添加新地址</view>
|
||||
</view>
|
||||
<view class='mask' catchtouchmove='true' :hidden='address.address==false' @tap='close'></view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// +----------------------------------------------------------------------
|
||||
// | CRMEB [ CRMEB赋能开发者,助力企业发展 ]
|
||||
// +----------------------------------------------------------------------
|
||||
// | Copyright (c) 2016~2024 https://www.crmeb.com All rights reserved.
|
||||
// +----------------------------------------------------------------------
|
||||
// | Licensed CRMEB并不是自由软件,未经许可不能去掉CRMEB相关版权
|
||||
// +----------------------------------------------------------------------
|
||||
// | Author: CRMEB Team <admin@crmeb.com>
|
||||
// +----------------------------------------------------------------------
|
||||
// import { getAddressList } from '@/api/user.js';
|
||||
// import {
|
||||
// orderAddressLst,
|
||||
// }from "@/api/order";
|
||||
// import { mapGetters } from "vuex";
|
||||
// import { HTTP_REQUEST_URL } from '@/config/app';
|
||||
export default {
|
||||
props: {
|
||||
pagesUrl: {
|
||||
type: String,
|
||||
default: '',
|
||||
},
|
||||
uid: {
|
||||
type: Number,
|
||||
default: 0,
|
||||
},
|
||||
tourist_unique_key: {
|
||||
type: String,
|
||||
default: '',
|
||||
},
|
||||
address: {
|
||||
type: Object,
|
||||
default: function() {
|
||||
return {
|
||||
address: true,
|
||||
addressId: 0,
|
||||
};
|
||||
}
|
||||
},
|
||||
isLog: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
},
|
||||
// computed: mapGetters(['viewColor']),
|
||||
data() {
|
||||
return {
|
||||
domain: '',
|
||||
active: 0,
|
||||
//地址列表
|
||||
addressList: [
|
||||
{
|
||||
province: '广东省',
|
||||
city: '广州市',
|
||||
district: '天河区',
|
||||
street: '东风路',
|
||||
detail: '123号',
|
||||
real_name: '张三',
|
||||
phone: '13811111111',
|
||||
address_id: 1,
|
||||
|
||||
},
|
||||
{
|
||||
province: '广东省',
|
||||
city: '广州市',
|
||||
district: '天河区',
|
||||
street: '东风路',
|
||||
detail: '123号',
|
||||
real_name: '张三',
|
||||
phone: '13811111111',
|
||||
address_id: 1,
|
||||
|
||||
},
|
||||
{
|
||||
province: '广东省',
|
||||
city: '广州市',
|
||||
district: '天河区',
|
||||
street: '东风路',
|
||||
detail: '123号',
|
||||
real_name: '张三',
|
||||
phone: '13811111111',
|
||||
address_id: 1,
|
||||
|
||||
}
|
||||
],
|
||||
is_loading: true
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
tapAddress: function(index, addressid) {
|
||||
this.active = index;
|
||||
this.$emit('OnChangeAddress', addressid);
|
||||
},
|
||||
close: function() {
|
||||
this.$emit('changeClose');
|
||||
// this.$emit('changeTextareaStatus');
|
||||
},
|
||||
goAddressPages: function() {
|
||||
this.$emit('changeClose');
|
||||
// this.$emit('changeTextareaStatus');
|
||||
uni.navigateTo({
|
||||
url: this.pagesUrl
|
||||
});
|
||||
},
|
||||
getAddressList: function() {
|
||||
let that = this;
|
||||
// orderAddressLst({
|
||||
// page: 1,
|
||||
// limit: 5,
|
||||
// uid: that.uid,
|
||||
// tourist_unique_key: that.tourist_unique_key,
|
||||
// }).then(res => {
|
||||
// let addressList = res.data.list;
|
||||
// //处理默认选中项
|
||||
// for (let i = 0; i < res.data.list.length; i++) {
|
||||
// if (addressList[i].address_id == that.address.addressId) {
|
||||
// that.active = i;
|
||||
// }
|
||||
// }
|
||||
// that.$set(that, 'addressList', addressList);
|
||||
// that.is_loading = false;
|
||||
// })
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style scoped lang="scss">
|
||||
|
||||
/* #ifndef APP-NVUE */
|
||||
// 由于uView是基于nvue环境进行开发的,此环境中普通元素默认为flex-direction: column;
|
||||
// 所以在非nvue中,需要对元素进行重置为flex-direction: column; 否则可能会表现异常
|
||||
view, scroll-view, swiper-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex-shrink: 0;
|
||||
flex-grow: 0;
|
||||
flex-basis: auto;
|
||||
align-items: stretch;
|
||||
align-content: flex-start;
|
||||
}
|
||||
/* #endif */
|
||||
|
||||
// 隐藏scroll-view的滚动条
|
||||
::-webkit-scrollbar {
|
||||
display: none;
|
||||
width: 0 !important;
|
||||
height: 0 !important;
|
||||
-webkit-appearance: none;
|
||||
background: transparent;
|
||||
}
|
||||
.address-window .title {
|
||||
height: 123rpx;
|
||||
line-height: 123rpx;
|
||||
}
|
||||
.address-window .title .iconfont {
|
||||
position: absolute;
|
||||
right: 28rpx;
|
||||
top: 30rpx;
|
||||
}
|
||||
.address-window .list{
|
||||
max-height: 650rpx;
|
||||
}
|
||||
.address-window .list .item {
|
||||
margin-left: 30rpx;
|
||||
padding-right: 30rpx;
|
||||
border-bottom: 1px solid #f5f5f5;
|
||||
height: 129rpx;
|
||||
font-size: 25rpx;
|
||||
color: #333;
|
||||
}
|
||||
.address-window .list .item .iconfont {
|
||||
font-size: 37rpx;
|
||||
color: #2c2c2c;
|
||||
}
|
||||
.address-window .list .item .iconfont.icon-complete {
|
||||
font-size: 30rpx;
|
||||
color: #fff;
|
||||
}
|
||||
.address-window .list .item .address {
|
||||
width: 560rpx;
|
||||
}
|
||||
.address-window .list .item .address .name {
|
||||
font-size: 28rpx;
|
||||
color: #282828;
|
||||
margin-bottom: 4rpx;
|
||||
}
|
||||
.address-window .list .item .address .name .phone {
|
||||
margin-left: 18rpx;
|
||||
}
|
||||
.address-window .addressBnt {
|
||||
font-size: 28rpx;
|
||||
color: #fff;
|
||||
width: 690rpx;
|
||||
height: 88rpx;
|
||||
border-radius: 50rpx;
|
||||
text-align: center;
|
||||
line-height: 88rpx;
|
||||
margin: 85rpx auto;
|
||||
background-color: var(--view-theme);
|
||||
}
|
||||
.address-window .pictrue {
|
||||
text-align: center;
|
||||
}
|
||||
.address-window .pictrue image,.address-window .pictrue uni-image {
|
||||
width: 414rpx;
|
||||
height: 305rpx;
|
||||
}
|
||||
.address-window .pictrue view{
|
||||
color: #999;
|
||||
}
|
||||
.t-color {
|
||||
color: var(--view-theme)!important;
|
||||
}
|
||||
</style>
|
@ -58,16 +58,19 @@
|
||||
|
||||
</view>
|
||||
</view>
|
||||
<view class="flex box-border flex-sub-cart" @click="addCart" v-if="is_add">
|
||||
<u-icon custom-style="margin: 20rpx;" size="80rpx" slot="right" color="#59CB56"
|
||||
name="shopping-cart-fill"></u-icon>
|
||||
<u-text class=""
|
||||
custom-style="width: calc(100vw - 220rpx);text-align:center;display: flex; justify-content: center; align-items: center;height: 70rpx;border: 2px solid #59cb56;border-radius: 40rpx;background-color: #5acb5617;margin: 0rpx 20rpx!important;"
|
||||
color="#59CB56" size="26rpx" :text="'加入食谱清单'" :flex1="true" align="center" wordWrap="normal"
|
||||
:show="true" iconStyle="26rpx" decoration="none">
|
||||
</u-text>
|
||||
</view>
|
||||
|
||||
<view class="flex box-border flex-sub-cart" @click="addCart" v-if="is_add">
|
||||
<!-- <u-icon custom-style="margin: 20rpx;" size="80rpx" slot="right" color="#59CB56"
|
||||
name="shopping-cart-fill"></u-icon> -->
|
||||
|
||||
<view style="margin: 20rpx;">
|
||||
<u-text class=""
|
||||
custom-style="width: calc(100vw - 120rpx);text-align:center;display: flex; justify-content: center; align-items: center;height: 70rpx;border: 2px solid #59cb56;border-radius: 40rpx;background-color: #5acb5617;margin: 0rpx 20rpx!important;"
|
||||
color="#59CB56" size="26rpx" :text="'加入食谱清单'" :flex1="true" align="center" wordWrap="normal"
|
||||
:show="true" iconStyle="26rpx" decoration="none">
|
||||
</u-text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
@ -19,14 +19,14 @@
|
||||
height="80rpx" leftIconSize="38rpx" leftIconColor="#303133" :safeAreaInsetTop="true" :placeholder="true"
|
||||
:fixed="true"></up-navbar>
|
||||
<up-search v-model="search_sp.keyword" class="flex,flex-row p-1" style="" shape="round" bgColor="#f2f2f2"
|
||||
placeholder="输入食谱" :clearabled="true" :showAction="false" inputAlign="left" borderColor="transparent"
|
||||
placeholder="输入订单编号" :clearabled="true" :showAction="false" inputAlign="left" borderColor="transparent"
|
||||
searchIconColor="#909399" color="#606266" placeholderColor="#909399" searchIcon="search" margin="10rpx"
|
||||
maxlength="-1" height="60rpx" @change="searchSP()">
|
||||
</up-search>
|
||||
|
||||
<z-paging :fixed="false" height="calc(100vh - 320rpx)" width="calc(100vw - 50rpx)"
|
||||
:paging-style="{ 'background-color': '#FFFFFFFF', 'padding': '20rpx' }" ref="pagingRefSP"
|
||||
v-model="matchedItems_sp" @query="changeSP()" class="fv-page flex-col ">
|
||||
v-model="matchedItems_sp" @query="changeSP" class="fv-page flex-col ">
|
||||
<view v-for="(item, index) in matchedItems_sp" :key="index">
|
||||
<view class="address_box">
|
||||
<view class=" pt-2 pb-2 ps-2 pe-2" style="">
|
||||
@ -54,9 +54,9 @@
|
||||
iconStyle="font-size:32rpx;color:#59CB56;margin-right:10rpx;" lines="1"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
<view @click.stop="getopenLocation(item)">
|
||||
<!-- <view @click.stop="getopenLocation(item)">
|
||||
<u-icon slot="right" label="查看地图" name="map"></u-icon>
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
|
||||
<view class="h-50 flex">
|
||||
@ -128,7 +128,11 @@ export default defineComponent({
|
||||
this.$refs.pagingRefSP?.reload();
|
||||
},
|
||||
//列表分页
|
||||
changeSP () {
|
||||
changeSP (pageNo: number) {
|
||||
|
||||
console.log('列表分页',pageNo);
|
||||
this.search_sp.page = pageNo;
|
||||
console.log('列表分页',this.search_sp);
|
||||
CommonApi.commonGet('/api/order/list', this.search_sp).catch((res) => {
|
||||
if (res.code === 1) {
|
||||
this.$refs.pagingRefSP?.complete(res.data);
|
||||
@ -139,7 +143,7 @@ export default defineComponent({
|
||||
// this.createOrderData.cart_ids.push(item.id);
|
||||
// }
|
||||
// });
|
||||
|
||||
|
||||
} else {
|
||||
uni.$u.toast(res.msg);
|
||||
}
|
||||
|
@ -24,33 +24,41 @@
|
||||
leftIconColor="#303133" :safeAreaInsetTop="true" :placeholder="true" :fixed="true"></up-navbar>
|
||||
<view class="address_box">
|
||||
<view class=" pt-2 pb-2 ps-2 pe-2" style="">
|
||||
<u-cell class="" style="line-height: 60rpx;" :border="false" >
|
||||
<u-cell class="" style="line-height: 60rpx;" :border="false">
|
||||
<template #title>
|
||||
<view class="h-50 flex">
|
||||
<up-text class="" size="28rpx" color="#59CB56"
|
||||
:text="` 配送时间:${matchedItems_sc.delivery_date} ${matchedItems_sc.delivery_time} `" :flex1="true" align="left"
|
||||
prefixIcon="clock" wordWrap="normal" :show="true"
|
||||
:text="` 配送时间:${matchedItems_sc.delivery_date} ${matchedItems_sc.delivery_time} `"
|
||||
:flex1="true" align="left" prefixIcon="clock" wordWrap="normal" :show="true"
|
||||
iconStyle="font-size:32rpx;color:#59CB56;margin-right:10rpx;" lines="1"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
</view>
|
||||
<view class="h-50 flex">
|
||||
<up-text class="" size="28rpx"
|
||||
:text="`${matchedItems_sc.customer_name} ${matchedItems_sc.phone} `" :flex1="true" align="left"
|
||||
wordWrap="normal" :show="true" prefixIcon="map"
|
||||
<!-- <up-text class="" size="28rpx"
|
||||
:text="`${matchedItems_sc.customer_name} ${matchedItems_sc.phone} `" :flex1="true"
|
||||
align="left" wordWrap="normal" :show="true" prefixIcon="map"
|
||||
iconStyle="font-size:32rpx;color:#59CB56;margin-right:10rpx;" lines="1"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
</up-text> -->
|
||||
<u-icon customStyle="margin: 40rpx;" :name="matchedItems_sc.customer_name" slot="left" icon
|
||||
labelSize="28rpx" size="28rpx" :label="matchedItems_sc.phone"></u-icon>
|
||||
</view>
|
||||
<view class="h-50 flex">
|
||||
<up-text class="" size="28rpx" :text="matchedItems_sc.address" margin="40rpx" :flex1="true"
|
||||
<view class="flex" style="margin: 10rpx;">
|
||||
<!-- <text style="margin-left:40rpx;">
|
||||
{{ matchedItems_sc.address }}
|
||||
</text> -->
|
||||
|
||||
<u-icon customStyle="margin: 12rpx;" slot="left"
|
||||
labelSize="28rpx" :label="`${matchedItems_sc.address}`"></u-icon>
|
||||
<!-- <up-text class="" size="28rpx" :text="matchedItems_sc.address" margin="40rpx" :flex1="true"
|
||||
align="left" wordWrap="normal" :show="true" prefixIcon=""
|
||||
iconStyle="font-size:28rpx;color:#59CB56;margin-right:10rpx;" lines="1"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
<view @click="getopenLocation(matchedItems_sc)">
|
||||
</up-text> -->
|
||||
<!-- <view @click="getopenLocation(matchedItems_sc)">
|
||||
<u-icon slot="right" label="查看地图" name="map" color="#59CB56" labelColor="#59CB56"></u-icon>
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
|
||||
<view class="h-50 flex">
|
||||
@ -59,8 +67,8 @@
|
||||
iconStyle="font-size:32rpx;color:#59CB56;margin-right:10rpx;" lines="1"
|
||||
decoration="none">
|
||||
</up-text> -->
|
||||
<u-icon customStyle="margin: 16rpx;" slot="left" label="订单编号:"></u-icon>
|
||||
<u-icon slot="right" :label="matchedItems_sc.order_sn" ></u-icon>
|
||||
<u-icon customStyle="margin: 16rpx;" slot="left" label="订单编号:"></u-icon>
|
||||
<u-icon slot="right" labelSize="28rpx" :label="matchedItems_sc.order_sn"></u-icon>
|
||||
</view>
|
||||
|
||||
<view class="h-50 flex">
|
||||
@ -69,8 +77,8 @@
|
||||
iconStyle="font-size:32rpx;color:#59CB56;margin-right:10rpx;" lines="1"
|
||||
decoration="none">
|
||||
</up-text> -->
|
||||
<u-icon customStyle="margin: 16rpx;" slot="left" label="创建时间:"></u-icon>
|
||||
<u-icon slot="right" :label="matchedItems_sc.create_time" ></u-icon>
|
||||
<u-icon customStyle="margin: 16rpx;" slot="left" label="创建时间:"></u-icon>
|
||||
<u-icon slot="right" labelSize="28rpx" :label="matchedItems_sc.create_time"></u-icon>
|
||||
</view>
|
||||
<view class="h-50 flex">
|
||||
<!-- <up-text class="" size="28rpx" :text="`付款金额:¥${matchedItems_sc.pay_amount}`" margin="40rpx"
|
||||
@ -78,12 +86,12 @@
|
||||
iconStyle="font-size:32rpx;color:#59CB56;margin-right:10rpx;" lines="1"
|
||||
decoration="none">
|
||||
</up-text> -->
|
||||
<u-icon customStyle="margin: 16rpx;" slot="left" label="应付金额:"></u-icon>
|
||||
<u-icon slot="right" :label="`¥${matchedItems_sc.pay_amount}`" ></u-icon>
|
||||
<u-icon customStyle="margin: 16rpx;" slot="left" label="应付金额:"></u-icon>
|
||||
<u-icon slot="right" labelSize="28rpx" :label="`¥${matchedItems_sc.pay_amount}`"></u-icon>
|
||||
</view>
|
||||
<view class="h-50 flex">
|
||||
<u-icon customStyle="margin: 16rpx;" slot="left" label="实付金额:"></u-icon>
|
||||
<u-icon slot="right" :label="`¥${matchedItems_sc.pay_amount}`" ></u-icon>
|
||||
<u-icon customStyle="margin: 16rpx;" slot="left" label="实付金额:"></u-icon>
|
||||
<u-icon slot="right" labelSize="28rpx" :label="`¥${matchedItems_sc.pay_amount}`"></u-icon>
|
||||
</view>
|
||||
</template>
|
||||
</u-cell>
|
||||
@ -92,7 +100,7 @@
|
||||
|
||||
|
||||
<view class="detail_box">
|
||||
<!-- <up-cell class=" " style="" :title="matchedItems_sc.name" :label="matchedItems_sc.intro">
|
||||
<!-- <up-cell class=" " style="" :title="matchedItems_sc.name" labelSize="28rpx" :label="matchedItems_sc.intro">
|
||||
</up-cell> -->
|
||||
<view class="p-2">
|
||||
<view class="flex box-border flex-row pb-2 ps-2 pe-2" style="" @click="changeTab">
|
||||
@ -100,40 +108,68 @@
|
||||
line-color="#18C936" line-width="40rpx" line-height="6rpx" line-bg-size="cover"
|
||||
:scrollable="true" />
|
||||
</view>
|
||||
<z-paging v-if="!currentTab" :fixed="false" height="calc(100vh - 700rpx)" width="calc(100vw - 50rpx)"
|
||||
:paging-style="{ 'background-color': '#FFFFFFFF', 'padding': '20rpx' }" class="fv-page flex-col ">
|
||||
<view class="flex" style="padding: 0rpx 40rpx;width: calc(100vw - 140rpx);">
|
||||
<up-text class="" size="28rpx" color="#9b9b9b" text="菜谱" :flex1="true" align="left"
|
||||
wordWrap="normal" :show="true" lines="1" decoration="none">
|
||||
</up-text>
|
||||
<up-text class="" color="#9b9b9b" size="24rpx" text="数量" :flex1="true" align="right"
|
||||
wordWrap="normal" :show="true"
|
||||
iconStyle="font-size: 28rpx;font-weight: bold;margin-right:10rpx;color: #59CB56;"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
<up-text class="" color="#9b9b9b" size="24rpx" text="价格" :flex1="true" align="right"
|
||||
wordWrap="normal" :show="true"
|
||||
iconStyle="font-size: 28rpx;font-weight: bold;margin-right:10rpx;color: #59CB56;"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
</view>
|
||||
<z-paging v-if="!currentTab" :fixed="false" height="calc(100vh - 800rpx)" width="calc(100vw - 100rpx)"
|
||||
:paging-style="{ 'background-color': '#FFFFFFFF', 'padding': '0rpx 20rpx' }"
|
||||
class="fv-page flex-col ">
|
||||
<view class="flex" style="padding:20rpx" v-for="(item, index) in matchedItems_sc.orderDishes"
|
||||
:key="index">
|
||||
<up-text class="" size="28rpx" color="#9b9b9b" :text="item.dishes_info.name" :flex1="true"
|
||||
align="left" wordWrap="normal" :show="true" lines="1" decoration="none">
|
||||
</up-text>
|
||||
<up-text class="" color="#9b9b9b" size="24rpx" :text="`${item.num}/份 ¥${item.price}`"
|
||||
:flex1="true" align="right" wordWrap="normal" :show="true"
|
||||
<up-text class="" color="#9b9b9b" size="24rpx" :text="` x${item.num}`" :flex1="true"
|
||||
align="right" wordWrap="normal" :show="true"
|
||||
iconStyle="font-size: 28rpx;font-weight: bold;margin-right:10rpx;color: #59CB56;"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
<up-text class="" color="#9b9b9b" size="24rpx" :text="`¥${item.price}`" :flex1="true"
|
||||
align="right" wordWrap="normal" :show="true"
|
||||
iconStyle="font-size: 28rpx;font-weight: bold;margin-right:10rpx;color: #59CB56;"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
</view>
|
||||
</z-paging>
|
||||
<z-paging v-if="currentTab" :fixed="false" height="calc(100vh - 700rpx)" width="calc(100vw - 50rpx)"
|
||||
:paging-style="{ 'background-color': '#FFFFFFFF', 'padding': '20rpx' }" class="fv-page flex-col ">
|
||||
<z-paging v-if="currentTab" :fixed="false" height="calc(100vh - 800rpx)" width="calc(100vw - 100rpx)"
|
||||
:paging-style="{ 'background-color': '#FFFFFFFF', 'padding': '0rpx 20rpx' }"
|
||||
class="fv-page flex-col ">
|
||||
<view class="flex" style="padding:20rpx" v-for="(item, index) in matchedItems_sc.orderProduct"
|
||||
:key="index">
|
||||
<up-text class="" size="28rpx" color="#9b9b9b" :text="item.product_info.name" :flex1="true"
|
||||
align="left" wordWrap="normal" :show="true" lines="1" decoration="none">
|
||||
</up-text>
|
||||
<up-text class="" color="#9b9b9b" size="24rpx" :text="`${item.num}/份 ¥${item.price}`"
|
||||
:flex1="true" align="right" wordWrap="normal" :show="true"
|
||||
<up-text class="" color="#9b9b9b" size="24rpx" :text="` x${item.num}`" :flex1="true"
|
||||
align="right" wordWrap="normal" :show="true"
|
||||
iconStyle="font-size: 28rpx;font-weight: bold;margin-right:10rpx;color: #59CB56;"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
<up-text class="" color="#9b9b9b" size="24rpx" :text="`¥${item.price}`" :flex1="true"
|
||||
align="right" wordWrap="normal" :show="true"
|
||||
iconStyle="font-size: 28rpx;font-weight: bold;margin-right:10rpx;color: #59CB56;"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
|
||||
</view>
|
||||
</z-paging>
|
||||
</view>
|
||||
</view>
|
||||
<view class="flex box-border flex-sub-cart">
|
||||
<!-- <view>
|
||||
<u-icon custom-style="margin: 20rpx;" slot="right" :label="`总数:¥${matchedItems_sc.total_num} `" name="map" color="#59CB56"></u-icon>
|
||||
<u-icon custom-style="margin: 20rpx;" slot="right" :label="`总数:¥${matchedItems_sc.total_amount} `" name="map" color="#59CB56"></u-icon>
|
||||
<u-icon custom-style="margin: 20rpx;" slot="right" labelSize="28rpx" :label="`总数:¥${matchedItems_sc.total_num} `" name="map" color="#59CB56"></u-icon>
|
||||
<u-icon custom-style="margin: 20rpx;" slot="right" labelSize="28rpx" :label="`总数:¥${matchedItems_sc.total_amount} `" name="map" color="#59CB56"></u-icon>
|
||||
</view> -->
|
||||
<!-- <u-text class=""
|
||||
custom-style="width: calc(100vw - 220rpx);text-align:center;display: flex; justify-content: center; align-items: center;height: 160rpx;border: 2px solid #59cb56;border-radius: 40rpx;background-color: #5acb5617;margin: 0rpx 20rpx!important;"
|
||||
@ -193,17 +229,17 @@ export default defineComponent({
|
||||
},
|
||||
goBackHome () {
|
||||
uni.switchTab({
|
||||
|
||||
|
||||
url: '/pages/tab/user/index'
|
||||
});
|
||||
},
|
||||
// 打开地图
|
||||
getopenLocation (res) {
|
||||
useLocation().openLocation(res.latitude, res.longitude,res.address,res.address)
|
||||
useLocation().openLocation(res.latitude, res.longitude, res.address, res.address)
|
||||
},
|
||||
},
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
</script>
|
@ -44,20 +44,23 @@
|
||||
type="tips"></up-text>
|
||||
</template>
|
||||
</up-input>
|
||||
<up-input placeholder="请选择地址" v-model="addFrom_address" @click="getopenLocation(0)">
|
||||
<template #prefix>
|
||||
<up-text align="left" customStyle="width:120rpx" text="所在地区" margin="0 8px 0 0"
|
||||
type="tips"></up-text>
|
||||
</template>
|
||||
<template #suffix>
|
||||
|
||||
<!-- <up-button @tap="getCode" text="2312312" type="success" size="mini"></up-button> -->
|
||||
<up-text class="" color="#59CB56" size="24rpx" text="定位" :flex1="true"
|
||||
prefix-icon="map" align="left" word-wrap="normal" :show="true"
|
||||
icon-style="font-size: 36rpx;font-weight: bold;color:#59CB56;"
|
||||
decoration="none" @click.stop="getopenLocation(1)" />
|
||||
</template>
|
||||
</up-input>
|
||||
<view @click="getopenLocation(0)">
|
||||
<up-input placeholder="请选择地址" v-model="addFrom_address">
|
||||
<template #prefix>
|
||||
<up-text align="left" customStyle="width:120rpx" text="所在地区"
|
||||
margin="0 8px 0 0" type="tips"></up-text>
|
||||
</template>
|
||||
<template #suffix>
|
||||
|
||||
<!-- <up-button @tap="getCode" text="2312312" type="success" size="mini"></up-button> -->
|
||||
<up-text class="" color="#59CB56" size="24rpx" text="定位" :flex1="true"
|
||||
prefix-icon="map" align="left" word-wrap="normal" :show="true"
|
||||
icon-style="font-size: 36rpx;font-weight: bold;color:#59CB56;"
|
||||
decoration="none" @click.stop="getopenLocation(1)" />
|
||||
</template>
|
||||
</up-input>
|
||||
</view>
|
||||
<up-input placeholder="请输入详细地址" v-model="addFrom.detail">
|
||||
<template #prefix>
|
||||
<up-text align="left" customStyle="width:120rpx" text="详细地址" margin="0 8px 0 0"
|
||||
@ -96,13 +99,15 @@
|
||||
<view style="padding: 20rpx;">
|
||||
<u-cell class="" style="line-height: 60rpx;" :border="true">
|
||||
<template #title>
|
||||
<view class="h-50 flex" @click="closeProp">
|
||||
<view class="h-50 flex">
|
||||
<text class="ellipsis" style="font-size: 26rpx;font-weight: bold;">
|
||||
选择地址
|
||||
</text>
|
||||
<up-text class="pe-2" size="22rpx" text="收起" :flex1="true" suffix-icon="arrow-up"
|
||||
align="right" word-wrap="normal" :show="true" type="#59CB56"
|
||||
icon-style="font-size: 22rpx; " decoration="none" />
|
||||
<view @click="closeProp">
|
||||
<up-text class="pe-2" size="22rpx" text="收起" :flex1="true" suffix-icon="arrow-up"
|
||||
align="right" word-wrap="normal" :show="true" type="#59CB56"
|
||||
icon-style="font-size: 22rpx; " decoration="none" />
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
</u-cell>
|
||||
@ -118,8 +123,8 @@
|
||||
:iconStyle="item.id === createOrderData.address_id ? 'color:#59CB56;font-size:32rpx;margin-right:10rpx;' : '' + 'font-size:32rpx;margin-right:10rpx;'"
|
||||
lines="1" decoration="none">
|
||||
</u-text>
|
||||
<view @click.stop="editAddress(item)"> <u-icon slot="right"
|
||||
name="edit-pen" label="修改" ></u-icon> </view>
|
||||
<view @click.stop="editAddress(item)"> <u-icon size="38rpx" slot="right"
|
||||
name="edit-pen" label=" "></u-icon> </view>
|
||||
|
||||
<!-- <u-text class="" size="26rpx" :text="item.phone" :flex1="true" align="left"
|
||||
wordWrap="normal" :show="true"
|
||||
@ -133,8 +138,8 @@
|
||||
:color="item.id === createOrderData.address_id ? '#59CB56' : ''"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
<view @click.stop="deleteAddress(item.id)"> <u-icon slot="right"
|
||||
name="trash" label="删除"></u-icon></view>
|
||||
<view @click.stop="deleteAddress(item.id)"> <u-icon size="38rpx" slot="right"
|
||||
name="trash" label=" "></u-icon></view>
|
||||
</view>
|
||||
|
||||
</template>
|
||||
@ -149,9 +154,9 @@
|
||||
</view>
|
||||
</u-popup>
|
||||
|
||||
<u-datetime-picker ref="datetimePicker" @close="cancelDelivery" :show="showDelivery" v-model="time_value"
|
||||
:formatter="formatter" mode="datetime" @confirm="confirmDelivery"
|
||||
@cancel="cancelDelivery"></u-datetime-picker>
|
||||
<u-datetime-picker title="配送时间" confirmColor="#59CB56" closeOnClickOverlay="true" ref="datetimePicker"
|
||||
@close="cancelDelivery" :show="showDelivery" v-model="time_value" :formatter="formatter" mode="datetime"
|
||||
@confirm="confirmDelivery" @cancel="cancelDelivery"></u-datetime-picker>
|
||||
|
||||
<up-navbar class=" " :autoBack="true" style="font-weight: bold;" leftIcon="arrow-left" title="提交订单"
|
||||
titleColor="#303133" bgColor="#FFFFFFFF" titleWidth="600rpx" height="80rpx" leftIconSize="40rpx"
|
||||
@ -206,22 +211,27 @@
|
||||
</up-image>
|
||||
</template>
|
||||
<template #title>
|
||||
<view class="h-60 flex">
|
||||
<view class="h-50 flex">
|
||||
<text class="ellipsis" style="font-size: 28rpx;">
|
||||
{{ item.cartDishes.name }}
|
||||
</text>
|
||||
<up-text class="text-black" size="24rpx" :text="` ${item.cartDishes.people}人份`"
|
||||
:flex1="true" suffix-icon="" align="right" word-wrap="normal" :show="true"
|
||||
type="#59CB56" icon-style="font-size: 36rpx;font-weight: bold;" decoration="none" />
|
||||
<up-text class="text-black" size="24rpx" :text="` ${item.people_number}人份`" :flex1="true"
|
||||
suffix-icon="" align="right" word-wrap="normal" :show="true" type="#59CB56"
|
||||
icon-style="font-size: 36rpx;font-weight: bold;" decoration="none" />
|
||||
</view>
|
||||
</template>
|
||||
<template #label>
|
||||
<view class="h-60 flex">
|
||||
<text class=" text-gray ellipsis" style="font-size: 22rpx;"> 主料:{{ item.cartDishes.intro
|
||||
<view class="h-100 flex">
|
||||
<up-text color="#767676" size="24rpx" :text="`${item.cartDishes.intro}`" :flex1="true"
|
||||
align="left" wordWrap="normal" :show="true" prefixIcon=""
|
||||
iconStyle="font-size:26rpx;color:#59CB56;margin-right:10rpx;" lines="2"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
<!-- <text class=" text-gray ellipsis" style="font-size: 22rpx;"> {{ item.cartDishes.intro
|
||||
}}</text>
|
||||
<up-text class="text-black" size="24rpx" :text="`销量:${item.cartDishes.sale_num} `"
|
||||
:flex1="true" suffix-icon="" align="right" word-wrap="normal" :show="true"
|
||||
type="#59CB56" icon-style="font-size: 36rpx;font-weight: bold;" decoration="none" />
|
||||
type="#59CB56" icon-style="font-size: 36rpx;font-weight: bold;" decoration="none" /> -->
|
||||
</view>
|
||||
</template>
|
||||
</u-cell>
|
||||
@ -229,12 +239,15 @@
|
||||
</view>
|
||||
</z-paging>
|
||||
<view class="flex box-border flex-sub" style=" bottom: 20rpx;">
|
||||
<u-text class="" style="margin: 0rpx 0rpx 0rpx 20rpx;" color="#59CB56" size="26rpx"
|
||||
:text="'共计' + cartNUM + '件'" :flex1="true" align="left" wordWrap="normal" :show="true" iconStyle="26rpx"
|
||||
decoration="none">
|
||||
</u-text>
|
||||
|
||||
<view style="margin: 0rpx 0rpx 0rpx 20rpx;">
|
||||
<u-text class="" style="margin: 0rpx 0rpx 0rpx 20rpx;" color="#59CB56" size="26rpx"
|
||||
:text="'共计' + cartNUM + '件'" :flex1="true" align="left" wordWrap="normal" :show="true"
|
||||
iconStyle="26rpx" decoration="none">
|
||||
</u-text>
|
||||
</view>
|
||||
<up-button class="" style="" text="提交订单" type="primary" color="#59CB56" shape="circle" size="normal"
|
||||
custom-style="width:200rpx" @click="handleSubmit">
|
||||
custom-style="width:200rpx;float:right;margin-right:0rpx;" @click="handleSubmit">
|
||||
</up-button>
|
||||
</view>
|
||||
</view>
|
||||
@ -464,7 +477,7 @@ export default defineComponent({
|
||||
that.addFrom.city = res.data.address_component.city
|
||||
that.addFrom.district = res.data.address_component.district
|
||||
that.addFrom.latitude = res.data.location.lat
|
||||
that.addFrom.longitude = res.data.location.long
|
||||
that.addFrom.longitude = res.data.location.lng
|
||||
// that.addFrom.detail = res.data.address_component.street
|
||||
} else {
|
||||
uni.$u.toast(res.msg);
|
||||
@ -527,14 +540,31 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
deleteAddress (id) {
|
||||
CommonApi.commonPost('/api/user/deleteAddress',{id:id}).catch((res) => {
|
||||
if (res.code === 1) {
|
||||
// this.propShowAddress = false;
|
||||
this.getAddressInfoListData();
|
||||
} else {
|
||||
uni.$u.toast(res.msg);
|
||||
}
|
||||
|
||||
useModal().showModal('success', {
|
||||
title: '删除提示',
|
||||
content: '确定删除当前地址吗?',
|
||||
showCancel: true,
|
||||
confirmText: '确定',
|
||||
cancelText: '取消',
|
||||
success: (res) => {
|
||||
if (res.confirm) {
|
||||
CommonApi.commonPost('/api/user/deleteAddress', { id: id }).catch((res) => {
|
||||
if (res.code === 1) {
|
||||
// this.propShowAddress = false;
|
||||
this.getAddressInfoListData();
|
||||
} else {
|
||||
uni.$u.toast(res.msg);
|
||||
}
|
||||
});
|
||||
}
|
||||
else if (res.cancel) {
|
||||
// console.log('用户点击取消');
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
},
|
||||
//修改地址
|
||||
editAddress (itme) {
|
||||
|
@ -2,40 +2,42 @@
|
||||
<view>
|
||||
<view class="login-form-wrap">
|
||||
<view class="title">
|
||||
欢迎登录
|
||||
<u-icon size="35" label="欢迎登录" name="weixin-fill" color="#59CB56" labelColor="#59CB56" />
|
||||
</view>
|
||||
<!-- <input v-model="account" class="u-border-bottom" type="number" placeholder="请输入手机号"> -->
|
||||
<u--input v-model="account" placeholder="请输入手机号" type="number" />
|
||||
<view v-if="loginType" class="u-border-bottom my-40rpx flex">
|
||||
<!-- <input v-model="code" class="flex-1" type="number" placeholder="请输入验证码"> -->
|
||||
<u--input v-model="code" placeholder="请输入验证码" type="number" />
|
||||
<view>
|
||||
<u-code ref="uCodeRef" @change="codeChange" />
|
||||
<u-button :text="tips" type="success" size="mini" @click="getCode" />
|
||||
<view style="height: 300rpx;">
|
||||
<view v-if="isWechat">
|
||||
<u--input v-model="account" placeholder="请输入手机号" type="number" />
|
||||
<view v-if="loginType" class="u-border-bottom my-40rpx flex">
|
||||
<u--input v-model="code" placeholder="请输入验证码" type="number" />
|
||||
<view>
|
||||
<u-code ref="uCodeRef" @change="codeChange" />
|
||||
<u-button :text="tips" type="success" size="mini" @click="getCode" />
|
||||
</view>
|
||||
</view>
|
||||
<view v-if="!loginType" class="u-border-bottom my-40rpx flex">
|
||||
<u--input v-model="password" placeholder="请输密码" type="password" />
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view v-if="!loginType" class="u-border-bottom my-40rpx flex">
|
||||
<u--input v-model="password" placeholder="请输密码" type="password" />
|
||||
<!-- <input v-model="password" class="flex-1" type="password" placeholder="请输密码"> -->
|
||||
</view>
|
||||
|
||||
<button class="login-btn" :style="[inputStyle]" @tap="submit">
|
||||
登录 <text class="i-mdi-login" />
|
||||
<button class="login-btn" :style="[inputStyle]" @tap="wechatLogin">
|
||||
授权登录 <text class="i-mdi-login" />
|
||||
</button>
|
||||
<view class="alternative">
|
||||
|
||||
<view class="alternative" v-if="isWechat">
|
||||
<view v-if="loginType" class="password" @click="changLoginType(0)">
|
||||
密码登录
|
||||
</view>
|
||||
<view v-if="!loginType" class="password" @click="changLoginType(1)">
|
||||
验证码登录
|
||||
</view>
|
||||
|
||||
<!--
|
||||
<view class="issue flex items-center">
|
||||
遇到问题 <text class="i-mdi-help" />
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
</view>
|
||||
<view class="login-type-wrap">
|
||||
<!-- <view class="login-type-wrap">
|
||||
<view class="item wechat">
|
||||
<view class="icon">
|
||||
<u-icon size="35" name="weixin-fill" color="rgb(83,194,64)" />
|
||||
@ -48,14 +50,17 @@
|
||||
</view>
|
||||
QQ
|
||||
</view>
|
||||
</view> -->
|
||||
<view class=" box-border flex" style="margin-top: 50rpx;">
|
||||
<view class="hint">
|
||||
登录代表同意
|
||||
<text class="link">
|
||||
用户协议、隐私政策,
|
||||
</text>
|
||||
并授权使用您的账号信息(如昵称、头像、收获地址)以便您统一管理
|
||||
</view>
|
||||
</view>
|
||||
<view class="hint">
|
||||
登录代表同意
|
||||
<text class="link">
|
||||
用户协议、隐私政策,
|
||||
</text>
|
||||
并授权使用您的账号信息(如昵称、头像、收获地址)以便您统一管理
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
@ -63,10 +68,15 @@
|
||||
import type { CSSProperties } from 'vue';
|
||||
import { HOME_PATH, isTabBarPath, LOGIN_PATH, removeQueryString } from '@/router';
|
||||
import { useUserStore } from '@/store';
|
||||
import { setToken ,getToken , isLogin } from '@/utils/auth';
|
||||
import { setToken, getToken, isLogin } from '@/utils/auth';
|
||||
import uCode from 'uview-plus/components/u-code/u-code.vue';
|
||||
|
||||
const userStore = useUserStore();
|
||||
const isWechat = ref(false);
|
||||
// #ifdef H5
|
||||
isWechat.value = true;
|
||||
// #endif
|
||||
|
||||
|
||||
const loginType = ref(0);
|
||||
const account = ref<string>('18181941463');
|
||||
@ -81,20 +91,20 @@ const inputStyle = computed<CSSProperties>(() => {
|
||||
const style = {} as CSSProperties;
|
||||
if (account.value && code.value) {
|
||||
style.color = '#fff';
|
||||
style.backgroundColor = uni.$u.color.warning;
|
||||
style.backgroundColor = uni.$u.color.success;
|
||||
}
|
||||
return style;
|
||||
});
|
||||
|
||||
function codeChange(text: string) {
|
||||
function codeChange (text: string) {
|
||||
tips.value = text;
|
||||
}
|
||||
|
||||
function changLoginType(text: number) {
|
||||
function changLoginType (text: number) {
|
||||
loginType.value = text;
|
||||
}
|
||||
|
||||
function getCode() {
|
||||
function getCode () {
|
||||
if (uCodeRef.value?.canGetCode) {
|
||||
// 模拟向后端请求验证码
|
||||
uni.showLoading({
|
||||
@ -111,7 +121,53 @@ function getCode() {
|
||||
uni.$u.toast('倒计时结束后再发送');
|
||||
}
|
||||
}
|
||||
async function submit() {
|
||||
|
||||
|
||||
|
||||
async function wechatLogin () {
|
||||
|
||||
if (!isWechat.value) {
|
||||
|
||||
uni.login({
|
||||
provider: 'weixin',
|
||||
// onlyAuthorize: true,// 微信登录仅请求授权认证
|
||||
success: function (event) {
|
||||
console.log('微信登录', event);
|
||||
// const { code } = event
|
||||
//客户端成功获取授权临时票据(code),向业务服务器发起登录请求。
|
||||
// uni.request({
|
||||
// url: 'https://www.example.com/loginByWeixin', //仅为示例,并非真实接口地址。
|
||||
// data: {
|
||||
// code: event.code
|
||||
// },
|
||||
// success: (res) => {
|
||||
// //获得token完成登录
|
||||
// uni.setStorageSync('token', res.token)
|
||||
// }
|
||||
// });
|
||||
userStore.login({ account: account.value, code: event.code }).catch(() => {
|
||||
if (res.code === 1) {
|
||||
// const token = res.data.token;
|
||||
// if (token) {
|
||||
// setToken(token.token_type+' '+token.token);
|
||||
// }
|
||||
uni.$u.toast('登录成功');
|
||||
}
|
||||
else {
|
||||
uni.$u.toast(`登录失败,${res.message}`);
|
||||
}
|
||||
});
|
||||
|
||||
},
|
||||
fail: function (err) {
|
||||
// 登录授权失败
|
||||
// err.code是错误码
|
||||
}
|
||||
})
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
if (!uni.$u.test.mobile(Number(account.value))) {
|
||||
uni.$u.toast('请输入正确的手机号');
|
||||
return;
|
||||
@ -124,11 +180,11 @@ async function submit() {
|
||||
await userStore.passwordLogin({ account: account.value, password: password.value }).catch((res) => {
|
||||
console.log(res);
|
||||
if (res.code === 1) {
|
||||
// const token = res.data.token;
|
||||
// if (token) {
|
||||
// setToken(token.token_type+' '+token.token);
|
||||
// }
|
||||
uni.$u.toast('登录成功');
|
||||
// const token = res.data.token;
|
||||
// if (token) {
|
||||
// setToken(token.token_type+' '+token.token);
|
||||
// }
|
||||
uni.$u.toast('登录成功');
|
||||
}
|
||||
else {
|
||||
uni.$u.toast(`登录失败,${res.message}`);
|
||||
@ -142,10 +198,10 @@ async function submit() {
|
||||
}
|
||||
await userStore.login({ account: account.value, code: password.value }).catch(() => {
|
||||
if (res.code === 1) {
|
||||
// const token = res.data.token;
|
||||
// if (token) {
|
||||
// setToken(token.token_type+' '+token.token);
|
||||
// }
|
||||
// const token = res.data.token;
|
||||
// if (token) {
|
||||
// setToken(token.token_type+' '+token.token);
|
||||
// }
|
||||
uni.$u.toast('登录成功');
|
||||
}
|
||||
else {
|
||||
@ -153,7 +209,7 @@ async function submit() {
|
||||
}
|
||||
});
|
||||
}
|
||||
if(isLogin()){
|
||||
if (isLogin()) {
|
||||
// await userStore.info()
|
||||
setTimeout(() => {
|
||||
uni.$u.route({
|
||||
@ -161,11 +217,11 @@ async function submit() {
|
||||
url: redirect,
|
||||
});
|
||||
}, 800);
|
||||
}else{
|
||||
uni.$u.toast('登录失败,请重新登录 ');
|
||||
} else {
|
||||
uni.$u.toast('登录失败,请重新登录 ');
|
||||
setToken('');
|
||||
}
|
||||
|
||||
|
||||
// setToken('1234567890');
|
||||
|
||||
}
|
||||
@ -189,7 +245,7 @@ body {
|
||||
@apply mt-80rpx mx-auto mb-0 w-600rpx;
|
||||
|
||||
.title {
|
||||
@apply mb-100rpx text-60rpx text-left font-500;
|
||||
@apply mb-200rpx text-60rpx text-left font-500;
|
||||
}
|
||||
|
||||
input {
|
||||
|
@ -25,16 +25,20 @@
|
||||
:lazy-load="true" duration="500" bg-color="#f3f4f6NaN" :show-menu-by-longpress="true" />
|
||||
</template>
|
||||
<template #label>
|
||||
<view class="h-50">
|
||||
<text class="ellipsis text-gray" style="font-size: 22rpx;">
|
||||
主料:{{ goods_info.dishes_name }}
|
||||
</text>
|
||||
<view class="h-100 flex">
|
||||
<!-- <text class="ellipsis text-gray" style="font-size: 22rpx;">
|
||||
主料:{{ goods_info.dishes_name }} 附近登陆放假啦放假啦付款就拉萨附近洛杉矶发拉法兰三级分类看见发生盎司附近
|
||||
</text> -->
|
||||
<up-text color="#767676" size="24rpx" :text="`${goods_info.dishes_name}`" :flex1="true" align="left"
|
||||
wordWrap="normal" :show="true" prefixIcon=""
|
||||
iconStyle="font-size:26rpx;color:#59CB56;margin-right:10rpx;" lines="2" decoration="none">
|
||||
</up-text>
|
||||
</view>
|
||||
<view class="h-50 flex">
|
||||
<!-- <view class="h-50 flex">
|
||||
<text class="ellipsis text-gray" style="font-size: 22rpx;">
|
||||
营养:{{ goods_info.dishes_name }}
|
||||
</text>
|
||||
</view>
|
||||
</view> -->
|
||||
</template>
|
||||
</u-cell>
|
||||
|
||||
@ -106,8 +110,8 @@
|
||||
:paging-style="{ 'background-color': '#FFFFFFFF', 'padding': '20rpx' }" v-if="!currentTab" ref="pagingRefSP"
|
||||
v-model="matchedItems_sp" class="fv-page flex-col " @query="changeSP">
|
||||
<up-checkbox-group v-model="checkboxValue" placement="column" @change="checkboxChange">
|
||||
<up-cell-group class=" " style="" :border="true">
|
||||
<view v-for="(item, index) in matchedItems_sp" :key="index">
|
||||
<up-cell-group :border="false">
|
||||
<view class="detail-box" v-for="(item, index) in matchedItems_sp" :key="index">
|
||||
<u-cell :border="false" @click="goodsDetail(item.dishes_id)">
|
||||
<template #title>
|
||||
<view class="h-50 flex">
|
||||
@ -115,6 +119,11 @@
|
||||
:show="true" prefixIcon="" iconStyle="font-size:26rpx;color:#59CB56;margin-right:10rpx;" lines="1"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
<view>
|
||||
<u-icon labelPos="left" slot="right" :label="`x ${item.people_number}人份`" labelSize="28rpx"
|
||||
size="28rpx" name=" "></u-icon>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
@ -126,26 +135,22 @@
|
||||
</template>
|
||||
|
||||
<template #label>
|
||||
<view class="h-50 flex">
|
||||
<!-- <text class="ellipsis text-gray" style="font-size: 22rpx;">
|
||||
主料: <span v-for="(product, index) in item.cartProduct"> {{ product.product_name }}{{ index ===
|
||||
item.cartProduct.length - 1 ? '' : '、' }} </span>
|
||||
</text> -->
|
||||
<!-- <view class="h-50 flex">
|
||||
|
||||
<up-text color="#767676" size="24rpx" :text="`营养:${item.dishes_name}`" :flex1="true" align="left"
|
||||
wordWrap="normal" :show="true" prefixIcon=""
|
||||
iconStyle="font-size:26rpx;color:#59CB56;margin-right:10rpx;" lines="1" decoration="none">
|
||||
</up-text>
|
||||
|
||||
</view>
|
||||
<view class="h-50 flex">
|
||||
|
||||
<up-text color="#767676" size="24rpx" :text="`营养:${item.dishes_name}`" :flex1="true" align="left"
|
||||
</view> -->
|
||||
<view class="h-100 flex">
|
||||
<up-text color="#767676" size="24rpx" :text="`${item.dishes_name}`" :flex1="true" align="left"
|
||||
wordWrap="normal" :show="true" prefixIcon=""
|
||||
iconStyle="font-size:26rpx;color:#59CB56;margin-right:10rpx;" lines="1" decoration="none">
|
||||
</up-text>
|
||||
<view @click.stop="handleClickPropSC(item.id)">
|
||||
<u-icon labelPos="left" slot="right" label="食材配置" size="28rpx" name="arrow-right" color="#59CB56"
|
||||
labelColor="#59CB56"></u-icon>
|
||||
<u-icon labelPos="left" slot="right" label="食材配置" labelSize="28rpx" size="28rpx" name="arrow-right"
|
||||
color="#59CB56" labelColor="#59CB56"></u-icon>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
@ -159,46 +164,50 @@
|
||||
<z-paging :fixed="false" height="calc(100vh - 400rpx)" width="calc(100vw - 50rpx)"
|
||||
:paging-style="{ 'background-color': '#FFFFFFFF', 'padding': '20rpx' }" v-if="currentTab" ref="pagingRefSC"
|
||||
v-model="matchedItems_sc" class="fv-page flex-col " @query="changeSC">
|
||||
<view v-for="(item, index) in matchedItems_sc" :key="index">
|
||||
<u-cell :border="false">
|
||||
<template #icon>
|
||||
<up-image class="flex flex-row" style="border:1px solid #59CB56;border-radius: 100%;" :src="item.image"
|
||||
mode="aspectFill" width="120rpx" height="120rpx" shape="circle" :lazy-load="true" duration="500"
|
||||
bg-color="#f3f4f6NaN" :show-menu-by-longpress="true" />
|
||||
</template>
|
||||
<template #title>
|
||||
<view class="h-60 flex">
|
||||
<up-text size="28rpx" :text="item.product_name" :flex1="true" align="left" wordWrap="normal" :show="true"
|
||||
prefixIcon="" iconStyle="font-size:28rpx;color:#59CB56;margin-right:10rpx;" lines="1" decoration="none">
|
||||
</up-text>
|
||||
<view>
|
||||
<u-icon slot="right"
|
||||
:label="`${item.nums * item.cart_num}${item.unit_name}/${item.cart_num}人份`"></u-icon>
|
||||
<up-cell-group :border="false">
|
||||
<view class="detail-box" v-for="(item, index) in matchedItems_sc" :key="index">
|
||||
<u-cell :border="false">
|
||||
<template #icon>
|
||||
<up-image class="flex flex-row" style="border:1px solid #59CB56;border-radius: 100%;" :src="item.image"
|
||||
mode="aspectFill" width="120rpx" height="120rpx" shape="circle" :lazy-load="true" duration="500"
|
||||
bg-color="#f3f4f6NaN" :show-menu-by-longpress="true" />
|
||||
</template>
|
||||
<template #title>
|
||||
<view class="h-60 flex">
|
||||
<up-text size="28rpx" :text="item.product_name" :flex1="true" align="left" wordWrap="normal"
|
||||
:show="true" prefixIcon="" iconStyle="font-size:28rpx;color:#59CB56;margin-right:10rpx;" lines="1"
|
||||
decoration="none">
|
||||
</up-text>
|
||||
<view>
|
||||
<u-icon slot="right"
|
||||
:label="`${item.nums * item.people_number}${item.unit_name}/${item.people_number}份`"></u-icon>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
<template #label>
|
||||
<view class="h-60 flex">
|
||||
|
||||
</view>
|
||||
</template>
|
||||
<template #label>
|
||||
<view class="h-60 flex">
|
||||
<up-text color="#767676" size="24rpx" :text="`菜谱:${item.dishes_name}`" :flex1="true" align="left"
|
||||
wordWrap="normal" :show="true" prefixIcon=""
|
||||
iconStyle="font-size:26rpx;color:#59CB56;margin-right:10rpx;" lines="1" decoration="none">
|
||||
</up-text>
|
||||
<u-number-box @change="editNum" v-model="item.people_number" input-width="80rpx" :name="item.id" />
|
||||
|
||||
<up-text color="#767676" size="24rpx" :text="`菜谱:${item.dishes_name}`" :flex1="true" align="left"
|
||||
wordWrap="normal" :show="true" prefixIcon=""
|
||||
iconStyle="font-size:26rpx;color:#59CB56;margin-right:10rpx;" lines="1" decoration="none">
|
||||
</up-text>
|
||||
<u-number-box @change="editNum" v-model="item.cart_num" input-width="80rpx" :name="item.product_id" />
|
||||
|
||||
</view>
|
||||
</template>
|
||||
</u-cell>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
</u-cell>
|
||||
</view>
|
||||
</up-cell-group>
|
||||
</z-paging>
|
||||
|
||||
<view class="flex-sub box-border flex">
|
||||
<u-text class="" style="margin: 0rpx 0rpx 0rpx 20rpx;" color="#59CB56" size="26rpx"
|
||||
:text="`购物车菜谱${cartNUM}个`" :flex1="true" align="left" word-wrap="normal" :show="true"
|
||||
icon-style="26rpx" decoration="none" />
|
||||
<view style="margin: 0rpx 0rpx 0rpx 20rpx;">
|
||||
<u-text class="" color="#59CB56" size="26rpx" :text="`购物车菜谱${cartNUM}个`" :flex1="true" align="left"
|
||||
word-wrap="normal" :show="true" icon-style="26rpx" decoration="none" />
|
||||
</view>
|
||||
<up-button class="" style="" text="提交订单" type="primary" color="#59CB56" shape="circle" size="normal"
|
||||
custom-style="width:200rpx" @click="handleSubmit" />
|
||||
custom-style="width:200rpx;float:right;margin-right:0rpx;" @click="handleSubmit" />
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@ -242,6 +251,7 @@ export default defineComponent({
|
||||
onShow () {
|
||||
//进入页面时刷新数据--避免加入购物车不显示
|
||||
this.searchSP();
|
||||
this.searchSC();
|
||||
},
|
||||
onLoad () {
|
||||
// if (isLogin()) {
|
||||
@ -370,7 +380,7 @@ export default defineComponent({
|
||||
if (res.confirm) {
|
||||
console.log(that.aloneChecked);
|
||||
//删除购物车菜品
|
||||
CommonApi.commonPost('/api/cart/delete', { id: this.checkboxValue }).catch((res) => {
|
||||
CommonApi.commonPost('/api/cart/delete', { ids: this.checkboxValue }).catch((res) => {
|
||||
if (res.code === 1) {
|
||||
that.aloneChecked = false;
|
||||
this.aloneCheckedValue = []
|
||||
@ -400,10 +410,10 @@ export default defineComponent({
|
||||
},
|
||||
//修改商品数量
|
||||
changeProductNumber (e) {
|
||||
// console.log(e);
|
||||
console.log(e);
|
||||
this.goods_sc = this.matchedItems_sc.find(item => item.product_id === e.name);
|
||||
// console.log(this.goods_sc);
|
||||
CommonApi.commonPost('/api/cart/changeNumber', { id: e.name, nums: (this.goods_sc.nums * this.goods_sc.cart_num) }).catch((res) => {
|
||||
CommonApi.commonPost('/api/cart/changeNumber', { id: e.name, people_number: e.value }).catch((res) => {
|
||||
if (res.code === 1) {
|
||||
} else {
|
||||
uni.$u.toast(res.msg);
|
||||
@ -412,10 +422,10 @@ export default defineComponent({
|
||||
},
|
||||
//修改人数
|
||||
changePeopleNumber (e) {
|
||||
CommonApi.commonPost('/api/cart/changePeopleNumber', { totalNum: this.totalNum }).catch((res) => {
|
||||
CommonApi.commonPost('/api/cart/changePeopleNumber', { people_number: this.totalNum }).catch((res) => {
|
||||
if (res.code === 1) {
|
||||
this.matchedItems_sc.forEach((item, index) => {
|
||||
this.matchedItems_sc[index].cart_num = e.value;
|
||||
this.matchedItems_sc[index].people_number = e.value;
|
||||
});
|
||||
} else {
|
||||
uni.$u.toast(res.msg);
|
||||
@ -432,6 +442,10 @@ export default defineComponent({
|
||||
CommonApi.commonPost('/api/cart/count').catch((res) => {
|
||||
if (res.code === 1) {
|
||||
this.cartNUM = res.data.count;
|
||||
if (this.totalNum == 1) {
|
||||
this.totalNum = res.data.peopleNumber
|
||||
}
|
||||
|
||||
}
|
||||
});
|
||||
},
|
||||
|
@ -2,7 +2,7 @@
|
||||
<view class="page-wrap p-2">
|
||||
<view class="detail-box flex bg-white p-4">
|
||||
<view class="mr-10rpx">
|
||||
<u-avatar :src="userStore.user.avatar " size="70" />
|
||||
<u-avatar :src="userStore.user.avatar" size="70" />
|
||||
</view>
|
||||
<view class="flex-1">
|
||||
<view class="pb-20rpx font-size-36rpx">
|
||||
@ -12,43 +12,33 @@
|
||||
{{ userStore.user.phone }}
|
||||
</view>
|
||||
</view>
|
||||
<view class="ml-10rpx p-10rpx">
|
||||
<!-- <view class="ml-10rpx p-10rpx">
|
||||
<u-icon name="scan" color="#969799" />
|
||||
</view>
|
||||
<view class="ml-10rpx p-10rpx">
|
||||
<u-icon name="arrow-right" color="#969799" />
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
|
||||
<view class="detail-box bg-white">
|
||||
<u-cell
|
||||
icon="" title="昵称" is-link right-icon="lock" :value="userStore.user.nickname" :border="false" size="large"
|
||||
custom-style="padding:20rpx;font-size:28rpx"
|
||||
/>
|
||||
<u-cell icon="" title="昵称" is-link right-icon="lock" :value="userStore.user.nickname" :border="false" size="large"
|
||||
custom-style="padding:20rpx;font-size:28rpx" />
|
||||
|
||||
<u-cell
|
||||
icon="" title="ID" is-link right-icon="lock" :value="userStore.user.id" :border="false" size="large"
|
||||
custom-style="padding:20rpx;font-size:28rpx"
|
||||
/>
|
||||
<u-cell icon="" title="ID" is-link right-icon="lock" :value="userStore.user.id" :border="false" size="large"
|
||||
custom-style="padding:20rpx;font-size:28rpx" />
|
||||
|
||||
<u-cell
|
||||
icon="" title="微信号" is-link right-icon="lock" :value="userStore.user.code" :border="false" size="large"
|
||||
custom-style="padding:20rpx;font-size:28rpx"
|
||||
/>
|
||||
<u-cell icon="" title="微信号" is-link right-icon="lock" :value="userStore.user.code" :border="false" size="large"
|
||||
custom-style="padding:20rpx;font-size:28rpx" />
|
||||
|
||||
<u-cell
|
||||
icon="order" title="订单详情" is-link value="" :border="false" size="large"
|
||||
custom-style="padding:20rpx;font-size:28rpx"
|
||||
@click="orderList"
|
||||
/>
|
||||
<u-cell icon="order" title="订单详情" is-link value="" :border="false" size="large"
|
||||
custom-style="padding:20rpx;font-size:28rpx" @click="orderList" />
|
||||
</view>
|
||||
|
||||
<view class="bg-white p-2">
|
||||
<u-button
|
||||
class="p-2" size="large" text="退出登录" type="primary" color="#59CB56" shape="circle"
|
||||
custom-style="width:100%;" @click="loginOut"
|
||||
/>
|
||||
<u-button class="p-2" size="large" text="退出登录" type="primary" color="#59CB56" shape="circle"
|
||||
custom-style="width:100%;" @click="loginOut" />
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
@ -76,7 +66,7 @@ const toCopy = async () => {
|
||||
console.log('[ data ] >', data);
|
||||
};
|
||||
|
||||
function loginOut() {
|
||||
function loginOut () {
|
||||
showModal('success', {
|
||||
title: '提示',
|
||||
content: '确定退出登录?',
|
||||
@ -87,23 +77,23 @@ function loginOut() {
|
||||
if (res.confirm) {
|
||||
// 退出请求
|
||||
// loginOuts();
|
||||
setToken('');
|
||||
uni.$u.route({
|
||||
type: isTabBarPath(redirect) ? 'switchTab' : 'redirectTo',
|
||||
url: redirect,
|
||||
});
|
||||
setToken('');
|
||||
uni.$u.route({
|
||||
type: isTabBarPath(redirect) ? 'switchTab' : 'redirectTo',
|
||||
url: redirect,
|
||||
});
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
function orderList() {
|
||||
function orderList () {
|
||||
uni.$u.route({
|
||||
type: 'navigateTo',
|
||||
url: '/pages/common/goods/order',
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
async function loginOuts() {
|
||||
async function loginOuts () {
|
||||
// 退出请求
|
||||
await userStore.logout().catch(() => {
|
||||
setToken('');
|
||||
@ -121,17 +111,3 @@ onShow(async () => {
|
||||
console.log(hasPermission ? '已登录' : '未登录,拦截跳转');
|
||||
});
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.detail-box {
|
||||
margin: 20rpx;
|
||||
background-color: #fff;
|
||||
border: 1rpx solid #dfdfdf;
|
||||
border-radius: 20rpx;
|
||||
}
|
||||
|
||||
html,
|
||||
body {
|
||||
height: 0;
|
||||
}
|
||||
</style>
|
||||
|
BIN
src/static/images/tabbar/bofang.png
Normal file
After Width: | Height: | Size: 6.6 KiB |
BIN
src/static/images/tabbar/bofang_selected.png
Normal file
After Width: | Height: | Size: 4.3 KiB |
BIN
src/static/images/tabbar/shezhi.png
Normal file
After Width: | Height: | Size: 6.6 KiB |
BIN
src/static/images/tabbar/shouye.png
Normal file
After Width: | Height: | Size: 6.2 KiB |
BIN
src/static/images/tabbar/shouye_selected.png
Normal file
After Width: | Height: | Size: 3.4 KiB |
BIN
src/static/images/tabbar/wode.png
Normal file
After Width: | Height: | Size: 6.9 KiB |
BIN
src/static/images/tabbar/wode_selected.png
Normal file
After Width: | Height: | Size: 3.8 KiB |
@ -3,6 +3,27 @@ page {
|
||||
color: $u-main-color;
|
||||
background-color: $u-bg-color;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
html,
|
||||
body {
|
||||
height: 100vh;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.detail-box {
|
||||
margin: 10rpx;
|
||||
background-color: #fff;
|
||||
border: 1rpx solid #dfdfdf;
|
||||
border-radius: 20rpx;
|
||||
padding: 20rpx;
|
||||
}
|
||||
.tab-bar{
|
||||
display: flex; position: fixed; left: 0px;right: 0px; bottom: 0rpx;
|
||||
}
|
||||
// .category-item {
|
||||
// display: inline-flex;
|
||||
// flex-direction: column;
|
||||
|
@ -3,7 +3,7 @@ import type { HttpRequestConfig, HttpResponse } from 'uview-plus/libs/luch-reque
|
||||
import type { IResponse } from './types';
|
||||
import Request from 'uview-plus/libs/luch-request/index';
|
||||
import { requestInterceptors, responseInterceptors } from './interceptors';
|
||||
|
||||
import { useClipboard, useModal, usePermission } from '@/hooks';
|
||||
const http = new Request();
|
||||
|
||||
// 引入拦截器配置
|
||||
@ -28,9 +28,15 @@ export function request<T = any>(config: HttpRequestConfig): Promise<T> {
|
||||
console.log('[ res ] >', res);
|
||||
const { result } = res.data;
|
||||
resolve(result as T);
|
||||
}).catch((err: any) => {
|
||||
}).catch((res: any) => {
|
||||
if(res.data.code==401){
|
||||
//未登录拦截跳转
|
||||
uni.$u.toast(res.data.msg);
|
||||
usePermission();
|
||||
return;
|
||||
}
|
||||
// console.error('[ err ] >', err);
|
||||
reject(err);
|
||||
reject(res);
|
||||
});
|
||||
});
|
||||
}
|
||||
|