im_change
@ -301,6 +301,7 @@ const onContactInfoEmitSubmit = (item: any) => {
|
||||
};
|
||||
|
||||
const onContactInfoButtonClicked = (item: any) => {
|
||||
|
||||
item.onClick
|
||||
&& item.onClick({
|
||||
contactInfoData: contactInfoData.value,
|
||||
@ -396,6 +397,7 @@ function onUserBlacklistUpdated(userBlacklist: IBlackListUserItem[]) {
|
||||
}
|
||||
|
||||
async function onCurrentContactInfoUpdated(contactInfo: IContactInfoType) {
|
||||
console.log('contactInfo-----', contactInfo);
|
||||
if (
|
||||
contactInfoData.value
|
||||
&& contactInfo
|
||||
|
128
TUIKit/components/TUIContact/contact-info/style/h5.css
Normal file
@ -0,0 +1,128 @@
|
||||
.tui-contact-info-h5 {
|
||||
padding: 0;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-header {
|
||||
background-color: #fff;
|
||||
padding: 10px !important;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-header-title {
|
||||
flex: 1;
|
||||
text-align: center;
|
||||
font-weight: 500;
|
||||
font-size: 14px;
|
||||
margin-right: 30px;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-basic {
|
||||
padding: 10px !important;
|
||||
background: #fff;
|
||||
margin-top: 10px !important;
|
||||
display: flex;
|
||||
flex-direction: row-reverse;
|
||||
justify-content: left;
|
||||
border-bottom: none;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-basic-text-name {
|
||||
font-size: 20px;
|
||||
padding-bottom: 1px;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-basic-text-other {
|
||||
font-size: 14px;
|
||||
padding: 3px 0;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-basic-avatar {
|
||||
border-radius: 10px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-more {
|
||||
background: #fff;
|
||||
margin-top: 10px !important;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-more-item {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
overflow: hidden;
|
||||
padding: 10px !important;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-more-item-label {
|
||||
color: #000;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-more-item-content {
|
||||
overflow: hidden;
|
||||
color: #979797;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-more-item-content-text {
|
||||
overflow: hidden;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-more-item-content-text-data {
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-more-item:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-button {
|
||||
margin-top: 10px !important;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 0;
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-button-item {
|
||||
width: 100%;
|
||||
margin: 0;
|
||||
border: none;
|
||||
padding: 16px !important;
|
||||
font-size: 16px;
|
||||
border-bottom: 1px solid #eee;
|
||||
height: fit-content;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-button-item::after {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-button-item-textarea {
|
||||
background-color: #f8f8f8;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-button-item:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-button .tui-contact-info-button-item-cancel {
|
||||
background-color: #fff;
|
||||
color: #006eff;
|
||||
}
|
||||
|
||||
.tui-contact-info-h5-button .tui-contact-info-button-item-submit {
|
||||
background-color: #fff;
|
||||
color: #FE3C3C;
|
||||
}
|
@ -119,12 +119,13 @@
|
||||
|
||||
.tui-contact-info-button-item-cancel {
|
||||
background-color: #fff;
|
||||
color: #e54545;
|
||||
color: #006eff;
|
||||
}
|
||||
|
||||
.tui-contact-info-button-item-submit {
|
||||
background-color: #fff;
|
||||
color: #006eff;
|
||||
|
||||
color: #FE3C3C;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -34,7 +34,7 @@ import { onHide } from '@dcloudio/uni-app';
|
||||
import './entry.ts';
|
||||
// #endif
|
||||
|
||||
const emits = defineEmits(['handleSwitchConversation']);
|
||||
const emits = defineEmits(['handleSwitchConversation','state']);
|
||||
|
||||
const totalUnreadCount = ref(0);
|
||||
const headerRef = ref<typeof ConversationHeader>();
|
||||
@ -56,6 +56,7 @@ TUIStore.watch(StoreName.CUSTOM, {
|
||||
});
|
||||
|
||||
const handleSwitchConversation = (conversationID: string) => {
|
||||
emits('state',false);
|
||||
TUIGlobal?.navigateTo({
|
||||
url: '/TUIKit/components/TUIChat/index',
|
||||
});
|
||||
|
@ -17,9 +17,9 @@ const groupIntroConfig = [
|
||||
// },
|
||||
{
|
||||
icon: 'https://web.sdk.qcloud.com/im/assets/images/Work.svg',
|
||||
label: '好友工作群(Work)',
|
||||
label: '好友群',
|
||||
type: TUIChatEngine.TYPES.GRP_WORK,
|
||||
detail: '类似普通微信群,创建后仅支持已在群内的好友邀请加群,且无需被邀请方同意或群主审批。详见',
|
||||
detail: '类似普通微信群,创建后仅支持已在群内的好友邀请加群,且无需被邀请方同意或群主审批',
|
||||
src: '产品文档',
|
||||
},
|
||||
// {
|
||||
|
@ -30,6 +30,7 @@
|
||||
<li class="group-list-item">
|
||||
<label class="group-list-item-label">{{ TUITranslateService.t('TUIGroup.群头像') }}</label>
|
||||
<Avatar :url="groupInfo.profile.avatar" />
|
||||
<!-- {{ }} -->
|
||||
</li>
|
||||
<ul>
|
||||
<li
|
||||
@ -76,12 +77,12 @@
|
||||
>
|
||||
<label class="introduction-name">{{ groupTypeDetail.label }}:</label>
|
||||
<span class="introduction-detail">{{ groupTypeDetail.detail }}</span>
|
||||
<a
|
||||
<!-- <a
|
||||
:href="documentLink.product.url"
|
||||
target="view_window"
|
||||
>
|
||||
{{ TUITranslateService.t(`TUIGroup.${groupTypeDetail.src}`) }}
|
||||
</a>
|
||||
</a> -->
|
||||
</article>
|
||||
</li>
|
||||
</ul>
|
||||
@ -205,10 +206,8 @@ const createInfo = computed(() => {
|
||||
? [groupNameInput]
|
||||
: [groupNameInput, groupIDInput];
|
||||
});
|
||||
|
||||
const submitDisabledStatus = computed(() => {
|
||||
return groupInfo.profile.name === '' && !groupInfo.isEdit;
|
||||
|
||||
});
|
||||
|
||||
const selected = (type: any) => {
|
||||
|
102
TUIKit/components/TUIGroup/create-group/style/color.css
Normal file
@ -0,0 +1,102 @@
|
||||
.group {
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
.group-list-item {
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
.group-list-item label {
|
||||
font-family: PingFangSC-Regular;
|
||||
font-weight: 400;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.group-list input {
|
||||
border: 1px solid rgba(131, 137, 153, 0.4);
|
||||
font-weight: 400;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.group-list-edit {
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
.group-profile-footer {
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
.group-h5 {
|
||||
background: #F7F8FA;
|
||||
}
|
||||
|
||||
.group-h5-list-item-introduction {
|
||||
font-family: PingFangSC-Regular;
|
||||
font-weight: 400;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
.group-h5-list-item-introduction a {
|
||||
color: #006EFF;
|
||||
}
|
||||
|
||||
.select {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.select a {
|
||||
color: #006EFF;
|
||||
}
|
||||
|
||||
.select-item {
|
||||
border: 1px solid rgba(131, 137, 153, 0.4);
|
||||
}
|
||||
|
||||
.select-item-header .left {
|
||||
font-weight: 500;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.select-item-detail {
|
||||
color: #4F4F4F;
|
||||
}
|
||||
|
||||
.select .selected {
|
||||
border: 1px solid #006EFF;
|
||||
}
|
||||
|
||||
header {
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
header h1 {
|
||||
font-family: PingFangSC-Medium;
|
||||
font-weight: 500;
|
||||
color: #000;
|
||||
letter-spacing: 0;
|
||||
}
|
||||
|
||||
.btn-default {
|
||||
background: #FFF;
|
||||
border: 1px solid #DDD;
|
||||
font-family: PingFangSC-Medium;
|
||||
font-weight: 500;
|
||||
color: #828282;
|
||||
}
|
||||
|
||||
.btn-submit {
|
||||
width: 100%;
|
||||
background: #3370FF;
|
||||
border: 0 solid #2F80ED;
|
||||
font-family: PingFangSC-Regular;
|
||||
font-weight: 400;
|
||||
color: #FFF;
|
||||
letter-spacing: 0;
|
||||
background-color: #fe3c3c;
|
||||
}
|
||||
|
||||
.btn-submit:disabled {
|
||||
background: #e8e8e9;
|
||||
border: 1px solid #DDD;
|
||||
color: #FFF;
|
||||
}
|
@ -89,12 +89,14 @@ header {
|
||||
}
|
||||
|
||||
.btn-submit {
|
||||
width: 100%;
|
||||
background: #3370FF;
|
||||
border: 0 solid #2F80ED;
|
||||
font-family: PingFangSC-Regular;
|
||||
font-weight: 400;
|
||||
color: #FFF;
|
||||
letter-spacing: 0;
|
||||
background-color: #fe3c3c;
|
||||
|
||||
&:disabled {
|
||||
background: #e8e8e9;
|
||||
|
104
TUIKit/components/TUIGroup/create-group/style/web.css
Normal file
@ -0,0 +1,104 @@
|
||||
.group {
|
||||
padding: 30px;
|
||||
box-sizing: border-box;
|
||||
width: 750px;
|
||||
max-height: calc(100vh - 100px);
|
||||
overflow-y: auto;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
.group .group-box .group-box-header {
|
||||
display: flex;
|
||||
flex-direction: row-reverse;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.group .group-box .group-box-header .group-box-header-title {
|
||||
font-size: 18px;
|
||||
line-height: 30px;
|
||||
}
|
||||
|
||||
.group-list-item {
|
||||
display: flex;
|
||||
padding: 10px 0;
|
||||
}
|
||||
|
||||
.group-list-item-label {
|
||||
width: 84px;
|
||||
}
|
||||
|
||||
.group-list input {
|
||||
flex: 1;
|
||||
box-sizing: border-box;
|
||||
padding: 6px 10px;
|
||||
border-radius: 2px;
|
||||
font-size: 14px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.select {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.select-item {
|
||||
padding: 12px 20px !important;
|
||||
border-radius: 2px;
|
||||
margin-bottom: 20px !important;
|
||||
}
|
||||
|
||||
.select-item-header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.select-item-header .left {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.select-item-header .left .icon {
|
||||
margin-right: 12px;
|
||||
}
|
||||
|
||||
.select-item-header .icon-selected {
|
||||
position: relative;
|
||||
left: 12px;
|
||||
top: -4px;
|
||||
}
|
||||
|
||||
.select-item-type {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.select-item-detail {
|
||||
padding-top: 6px;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.select-item .link {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.group-profile-footer {
|
||||
padding-top: 10px;
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
.btn-default {
|
||||
width: 82px;
|
||||
height: 32px;
|
||||
border-radius: 4px;
|
||||
font-size: 14px;
|
||||
background-color: #fe3c3c;
|
||||
}
|
||||
|
||||
.btn-submit {
|
||||
width: 100%;
|
||||
background-color: #fe3c3c;
|
||||
height: 32px;
|
||||
border-radius: 4px;
|
||||
margin-left: 10px;
|
||||
font-size: 14px;
|
||||
}
|
@ -95,10 +95,12 @@
|
||||
height: 32px;
|
||||
border-radius: 4px;
|
||||
font-size: 14px;
|
||||
background-color: #fe3c3c;
|
||||
}
|
||||
|
||||
.btn-submit {
|
||||
width: 82px;
|
||||
width: 100%;
|
||||
background-color: #fe3c3c;
|
||||
height: 32px;
|
||||
border-radius: 4px;
|
||||
margin-left: 10px;
|
||||
|
@ -197,11 +197,13 @@ const close = (tabName: string) => {
|
||||
border: 0 solid #2f80ed;
|
||||
padding: 4px 28px;
|
||||
font-weight: 400;
|
||||
font-size: 12px;
|
||||
font-size: 14px;
|
||||
color: #fff;
|
||||
line-height: 24px;
|
||||
border-radius: 4px;
|
||||
|
||||
display: flex ;
|
||||
align-items: center;
|
||||
background-color: #fe3c3c;
|
||||
&-cancel {
|
||||
background: #fff;
|
||||
border: 1px solid #ddd;
|
||||
@ -237,7 +239,7 @@ const close = (tabName: string) => {
|
||||
font-family: PingFangSC-Regular;
|
||||
font-weight: 400;
|
||||
font-size: 18px;
|
||||
color: #3370ff;
|
||||
color: #fe3c3c;
|
||||
letter-spacing: 0;
|
||||
line-height: 27px;
|
||||
}
|
||||
|
@ -35,6 +35,7 @@
|
||||
<button
|
||||
class="btn btn-cancel"
|
||||
@click="close"
|
||||
style="color: #fff;display: flex;justify-content: center;align-items: center"
|
||||
>
|
||||
{{ TUITranslateService.t('component.取消') }}
|
||||
</button>
|
||||
|
46
TUIKit/components/common/Dialog/style/color.css
Normal file
@ -0,0 +1,46 @@
|
||||
.dialog {
|
||||
background: rgba(0, 0, 0, 0.6);
|
||||
}
|
||||
|
||||
.dialog-main {
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
.dialog-main-header {
|
||||
font-weight: 500;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.dialog-main-title {
|
||||
font-family: PingFangSC-Medium;
|
||||
font-weight: 500;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.dialog-main-back {
|
||||
background: none;
|
||||
}
|
||||
|
||||
.dialog-main-content {
|
||||
font-weight: 400;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.btn {
|
||||
font-weight: 400;
|
||||
color: #FFF;
|
||||
letter-spacing: 0;
|
||||
background-color: #fe3c3c;
|
||||
}
|
||||
|
||||
.btn-cancel {
|
||||
border: 1px solid #ddd;
|
||||
color: #666;
|
||||
background-color: #fe3c3c;
|
||||
}
|
||||
|
||||
.btn-default {
|
||||
background: #006EFF;
|
||||
border: 1px solid #006EFF;
|
||||
background-color: #fe3c3c;
|
||||
}
|
@ -30,14 +30,16 @@
|
||||
font-weight: 400;
|
||||
color: #FFF;
|
||||
letter-spacing: 0;
|
||||
|
||||
background-color: #fe3c3c;
|
||||
&-cancel {
|
||||
border: 1px solid #ddd;
|
||||
color: #666;
|
||||
background-color: #fe3c3c;
|
||||
}
|
||||
|
||||
&-default {
|
||||
background: #006EFF;
|
||||
border: 1px solid #006EFF;
|
||||
background-color: #fe3c3c;
|
||||
}
|
||||
}
|
||||
|
59
TUIKit/components/common/Dialog/style/h5.css
Normal file
@ -0,0 +1,59 @@
|
||||
.dialog-h5 {
|
||||
height: 95%;
|
||||
top: 30px;
|
||||
align-items: inherit;
|
||||
}
|
||||
|
||||
.dialog-h5 .dialog-main {
|
||||
border-radius: 0;
|
||||
padding: 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
width: 100%;
|
||||
min-height: 80px;
|
||||
min-width: 120px;
|
||||
}
|
||||
|
||||
.dialog-h5 .dialog-main-content {
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
min-height: 0;
|
||||
overflow: hidden;
|
||||
text-align: center;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.dialog-h5 .dialog-main-content-uniapp {
|
||||
padding: 40px 0;
|
||||
}
|
||||
|
||||
.dialog-h5 .dialog-main-footer {
|
||||
border-top: 1px solid #DDD;
|
||||
}
|
||||
|
||||
.dialog-h5 .dialog-main-footer .btn {
|
||||
flex: 1;
|
||||
margin: 0;
|
||||
background: none;
|
||||
border-right: 1px solid #DDD;
|
||||
background-color: #fe3c3c;
|
||||
}
|
||||
|
||||
.dialog-h5 .dialog-main-footer .btn-default {
|
||||
color: #fff;
|
||||
border: none;
|
||||
background-color: #fe3c3c;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.center {
|
||||
align-items: center;
|
||||
padding: 20px;
|
||||
box-sizing: border-box;
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
.dialog-h5 {
|
||||
height: 100%;
|
||||
top: 0;
|
||||
height: 95%;
|
||||
top: 30px;
|
||||
align-items: inherit;
|
||||
|
||||
.dialog {
|
||||
@ -38,10 +38,14 @@
|
||||
margin: 0;
|
||||
background: none;
|
||||
border-right: 1px solid #DDD;
|
||||
|
||||
background-color: #fe3c3c;
|
||||
&-default {
|
||||
color: #FF584C;
|
||||
color: #fff;
|
||||
border: none;
|
||||
background-color: #fe3c3c;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
63
TUIKit/components/common/Dialog/style/web.css
Normal file
@ -0,0 +1,63 @@
|
||||
.dialog {
|
||||
position: fixed;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
z-index: 6;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.dialog-main {
|
||||
min-width: 368px;
|
||||
border-radius: 10px;
|
||||
padding: 20px 30px;
|
||||
}
|
||||
|
||||
.dialog-main-header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
font-size: 16px;
|
||||
line-height: 30px;
|
||||
}
|
||||
|
||||
.dialog-main-title {
|
||||
font-size: 16px;
|
||||
line-height: 30px;
|
||||
}
|
||||
|
||||
.dialog-main-content {
|
||||
font-size: 14px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.dialog-main-footer {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
.btn {
|
||||
padding: 8px 20px;
|
||||
margin: 0 6px;
|
||||
border-radius: 4px;
|
||||
border: none;
|
||||
font-size: 14px;
|
||||
text-align: center;
|
||||
line-height: 20px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.btn:disabled {
|
||||
opacity: 0.3;
|
||||
}
|
||||
|
||||
.btn:last-child {
|
||||
margin-right: 0;
|
||||
}
|
@ -50,7 +50,8 @@
|
||||
font-size: 14px;
|
||||
text-align: center;
|
||||
line-height: 20px;
|
||||
|
||||
display: flex;
|
||||
align-items: center;
|
||||
&:disabled {
|
||||
opacity: 0.3;
|
||||
}
|
||||
|
@ -3,20 +3,9 @@
|
||||
class="transfer"
|
||||
:class="[!isPC ? 'transfer-h5' : '', isWeChat ? 'transfer-h5-wechat' : '']"
|
||||
>
|
||||
<header
|
||||
v-if="!isPC"
|
||||
class="transfer-header transfer-h5-header"
|
||||
>
|
||||
<div
|
||||
v-if="!props.isHiddenBackIcon"
|
||||
@click="cancel"
|
||||
>
|
||||
<Icon
|
||||
class="icon"
|
||||
:file="backIcon"
|
||||
:width="'18px'"
|
||||
:height="'18px'"
|
||||
/>
|
||||
<header v-if="!isPC" class="transfer-header transfer-h5-header">
|
||||
<div v-if="!props.isHiddenBackIcon" @click="cancel">
|
||||
<Icon class="icon" :file="backIcon" :width="'18px'" :height="'18px'" />
|
||||
</div>
|
||||
<span class="title">{{ transferTitle }}</span>
|
||||
<span class="space" />
|
||||
@ -33,7 +22,7 @@
|
||||
enterkeyhint="search"
|
||||
:class="[isUniFrameWork ? 'left-uniapp-input' : '']"
|
||||
@keyup.enter="handleInput"
|
||||
>
|
||||
/>
|
||||
<!-- not PC triggers blur -->
|
||||
<input
|
||||
v-if="!isPC && isTransferSearch"
|
||||
@ -44,7 +33,7 @@
|
||||
:class="[isUniFrameWork ? 'left-uniapp-input' : '']"
|
||||
@blur="handleInput"
|
||||
@confirm="handleInput"
|
||||
>
|
||||
/>
|
||||
</header>
|
||||
<main class="transfer-left-main">
|
||||
<ul class="transfer-list">
|
||||
@ -59,10 +48,7 @@
|
||||
:width="'18px'"
|
||||
:height="'18px'"
|
||||
/>
|
||||
<i
|
||||
v-else
|
||||
class="icon-unselected"
|
||||
/>
|
||||
<i v-else class="icon-unselected" />
|
||||
<span class="select-all">{{
|
||||
TUITranslateService.t("component.全选")
|
||||
}}</span>
|
||||
@ -89,18 +75,17 @@
|
||||
class="avatar"
|
||||
:src="
|
||||
item.avatar ||
|
||||
'https://web.sdk.qcloud.com/component/TUIKit/assets/avatar_21.png'
|
||||
'https://web.sdk.qcloud.com/component/TUIKit/assets/avatar_21.png'
|
||||
"
|
||||
onerror="this.onerror=null;this.src='https://web.sdk.qcloud.com/component/TUIKit/assets/avatar_21.png'"
|
||||
>
|
||||
/>
|
||||
<span class="name">{{ item.nick || item.userID }}</span>
|
||||
<span v-if="item.isDisabled">({{ TUITranslateService.t("component.已在群中") }})</span>
|
||||
<span v-if="item.isDisabled"
|
||||
>({{ TUITranslateService.t("component.已在群中") }})</span
|
||||
>
|
||||
</template>
|
||||
<template v-else>
|
||||
<slot
|
||||
name="left"
|
||||
:data="item"
|
||||
/>
|
||||
<slot name="left" :data="item" />
|
||||
</template>
|
||||
</li>
|
||||
<li
|
||||
@ -114,16 +99,10 @@
|
||||
</main>
|
||||
</div>
|
||||
<div class="right">
|
||||
<header
|
||||
v-if="isPC"
|
||||
class="transfer-header"
|
||||
>
|
||||
<header v-if="isPC" class="transfer-header">
|
||||
{{ transferTitle }}
|
||||
</header>
|
||||
<ul
|
||||
v-if="resultShow"
|
||||
class="transfer-list"
|
||||
>
|
||||
<ul v-if="resultShow" class="transfer-list">
|
||||
<p
|
||||
v-if="transferSelectedList.length > 0 && isPC"
|
||||
class="transfer-text"
|
||||
@ -143,31 +122,20 @@
|
||||
class="avatar"
|
||||
:src="
|
||||
item.avatar ||
|
||||
'https://web.sdk.qcloud.com/component/TUIKit/assets/avatar_21.png'
|
||||
'https://web.sdk.qcloud.com/component/TUIKit/assets/avatar_21.png'
|
||||
"
|
||||
onerror="this.onerror=null;this.src='https://web.sdk.qcloud.com/component/TUIKit/assets/avatar_21.png'"
|
||||
>
|
||||
<span
|
||||
v-if="isPC"
|
||||
class="name"
|
||||
>{{ item.nick || item.userID }}</span>
|
||||
/>
|
||||
<span v-if="isPC" class="name">{{
|
||||
item.nick || item.userID
|
||||
}}</span>
|
||||
</template>
|
||||
<template v-else>
|
||||
<slot
|
||||
name="right"
|
||||
:data="item"
|
||||
/>
|
||||
<slot name="right" :data="item" />
|
||||
</template>
|
||||
</aside>
|
||||
<span
|
||||
v-if="isPC"
|
||||
@click="selected(item)"
|
||||
>
|
||||
<Icon
|
||||
:file="cancelIcon"
|
||||
:width="'18px'"
|
||||
:height="'18px'"
|
||||
/>
|
||||
<span v-if="isPC" @click="selected(item)">
|
||||
<Icon :file="cancelIcon" :width="'18px'" :height="'18px'" />
|
||||
</span>
|
||||
</li>
|
||||
</ul>
|
||||
@ -175,6 +143,7 @@
|
||||
<button
|
||||
class="btn btn-cancel"
|
||||
@click="cancel"
|
||||
style="display: flex; justify-content: center; align-items: center"
|
||||
>
|
||||
{{ TUITranslateService.t("component.取消") }}
|
||||
</button>
|
||||
@ -182,6 +151,13 @@
|
||||
v-if="transferSelectedList.length > 0"
|
||||
class="btn"
|
||||
@click="submit"
|
||||
style="
|
||||
background-color: #fe3c3c;
|
||||
color: #fff;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
"
|
||||
>
|
||||
{{ TUITranslateService.t("component.完成") }}
|
||||
</button>
|
||||
@ -189,6 +165,13 @@
|
||||
v-else
|
||||
class="btn btn-no"
|
||||
@click="submit"
|
||||
style="
|
||||
background-color: #fe3c3c;
|
||||
color: #fff;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
"
|
||||
>
|
||||
{{ TUITranslateService.t("component.完成") }}
|
||||
</button>
|
||||
@ -199,14 +182,14 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, watchEffect, computed } from '../../../adapter-vue';
|
||||
import { TUITranslateService } from '@tencentcloud/chat-uikit-engine';
|
||||
import { ITransferListItem } from '../../../interface';
|
||||
import Icon from '../Icon.vue';
|
||||
import selectedIcon from '../../../assets/icon/selected.svg';
|
||||
import backIcon from '../../../assets/icon/back.svg';
|
||||
import cancelIcon from '../../../assets/icon/cancel.svg';
|
||||
import { isPC, isUniFrameWork, isWeChat } from '../../../utils/env';
|
||||
import { ref, watchEffect, computed } from "../../../adapter-vue";
|
||||
import { TUITranslateService } from "@tencentcloud/chat-uikit-engine";
|
||||
import { ITransferListItem } from "../../../interface";
|
||||
import Icon from "../Icon.vue";
|
||||
import selectedIcon from "../../../assets/icon/selected.svg";
|
||||
import backIcon from "../../../assets/icon/back.svg";
|
||||
import cancelIcon from "../../../assets/icon/cancel.svg";
|
||||
import { isPC, isUniFrameWork, isWeChat } from "../../../utils/env";
|
||||
|
||||
const props = defineProps({
|
||||
list: {
|
||||
@ -231,11 +214,11 @@ const props = defineProps({
|
||||
},
|
||||
title: {
|
||||
type: String,
|
||||
default: '',
|
||||
default: "",
|
||||
},
|
||||
type: {
|
||||
type: String,
|
||||
default: '',
|
||||
default: "",
|
||||
},
|
||||
resultShow: {
|
||||
type: Boolean,
|
||||
@ -256,14 +239,14 @@ const transferTotal = ref<number>(0);
|
||||
const transferSelectedList = ref<ITransferListItem[]>([]);
|
||||
const isTransferSearch = ref(true);
|
||||
const isTransferCustomItem = ref(false);
|
||||
const transferTitle = ref('');
|
||||
const searchValue = ref('');
|
||||
const transferTitle = ref("");
|
||||
const searchValue = ref("");
|
||||
|
||||
watchEffect(() => {
|
||||
if (props.isCustomItem) {
|
||||
for (let index = 0; index < props.list.length; index++) {
|
||||
if (
|
||||
(props.list[index] as any).conversationID.indexOf('@TIM#SYSTEM') > -1
|
||||
(props.list[index] as any).conversationID.indexOf("@TIM#SYSTEM") > -1
|
||||
) {
|
||||
// eslint-disable-next-line vue/no-mutating-props
|
||||
props.list.splice(index, 1);
|
||||
@ -274,21 +257,25 @@ watchEffect(() => {
|
||||
transferList.value = props.list as ITransferListItem[];
|
||||
}
|
||||
transferTotal.value = props.total ? props.total : props.list.length;
|
||||
transferSelectedList.value = (props.selectedList && props.selectedList.length > 0 ? props.selectedList : transferSelectedList.value) as any;
|
||||
transferSelectedList.value = (
|
||||
props.selectedList && props.selectedList.length > 0
|
||||
? props.selectedList
|
||||
: transferSelectedList.value
|
||||
) as any;
|
||||
isTransferSearch.value = props.isSearch;
|
||||
isTransferCustomItem.value = props.isCustomItem;
|
||||
transferTitle.value = props.title;
|
||||
});
|
||||
|
||||
const emit = defineEmits(['search', 'submit', 'cancel', 'getMore']);
|
||||
const emit = defineEmits(["search", "submit", "cancel", "getMore"]);
|
||||
|
||||
const optional = computed(() =>
|
||||
transferList.value.filter((item: any) => !item.isDisabled),
|
||||
transferList.value.filter((item: any) => !item.isDisabled)
|
||||
);
|
||||
|
||||
const handleInput = (e: any) => {
|
||||
searchValue.value = e.target.value || e.detail.value;
|
||||
emit('search', searchValue.value);
|
||||
emit("search", searchValue.value);
|
||||
};
|
||||
const selected = (item: any) => {
|
||||
if (item.isDisabled) {
|
||||
@ -315,17 +302,17 @@ const selectedAll = () => {
|
||||
};
|
||||
|
||||
const submit = () => {
|
||||
emit('submit', transferSelectedList.value);
|
||||
searchValue.value = '';
|
||||
emit("submit", transferSelectedList.value);
|
||||
searchValue.value = "";
|
||||
};
|
||||
|
||||
const cancel = () => {
|
||||
emit('cancel');
|
||||
searchValue.value = '';
|
||||
emit("cancel");
|
||||
searchValue.value = "";
|
||||
};
|
||||
|
||||
const getMore = () => {
|
||||
emit('getMore');
|
||||
emit("getMore");
|
||||
};
|
||||
</script>
|
||||
|
||||
|
91
TUIKit/components/common/Transfer/style/h5.css
Normal file
@ -0,0 +1,91 @@
|
||||
.transfer-h5 {
|
||||
width: 100%;
|
||||
height: 92%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.transfer-h5-wechat {
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
}
|
||||
|
||||
.transfer-h5-header {
|
||||
position: relative;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
font-size: 18px;
|
||||
padding: 16px 18px;
|
||||
}
|
||||
|
||||
.transfer-h5-header .space, .transfer-h5-header .icon {
|
||||
width: 18px;
|
||||
height: 18px;
|
||||
}
|
||||
|
||||
.transfer-h5 .main {
|
||||
flex: 1;
|
||||
flex-direction: column;
|
||||
width: auto;
|
||||
height: auto;
|
||||
border-radius: 0;
|
||||
border: none;
|
||||
box-shadow: none;
|
||||
max-height: calc(100% - 50px);
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .avatar {
|
||||
border-radius: 5px;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .left {
|
||||
padding: 0;
|
||||
flex: 1;
|
||||
border: none;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .left .transfer-header {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
padding: 0 18px;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .left .transfer-header input {
|
||||
border-radius: 5px;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .left-uniapp-input {
|
||||
height: 36px;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .right {
|
||||
flex: 0;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
box-shadow: inset 0 1px 0 0 #EEE;
|
||||
padding: 8px 18px;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .right .transfer-list {
|
||||
flex-direction: row;
|
||||
width: 0;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .right .transfer-list-item-content {
|
||||
flex: none;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .right .transfer-right-footer {
|
||||
padding: 6px 0;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.transfer-h5 .main .right .transfer-right-footer .btn {
|
||||
font-size: 14px;
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
.transfer-h5 {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
height: 92%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
@ -86,6 +86,7 @@
|
||||
|
||||
.btn {
|
||||
font-size: 14px;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -23,7 +23,7 @@ export function getArticleCategory(category_type) {
|
||||
*/
|
||||
export function getArticleDetail(type) {
|
||||
return http.request({
|
||||
url: `/other/article/get/${type}`,
|
||||
url: `/other/article/type/${type}`,
|
||||
method: Method.GET,
|
||||
});
|
||||
}
|
||||
|
26
api/point.js
@ -23,6 +23,32 @@ export function mymon() {
|
||||
needToken: true,
|
||||
});
|
||||
}
|
||||
/**
|
||||
* 达人下的用户
|
||||
* @param params
|
||||
*/
|
||||
export function bindUsers() {
|
||||
return http.request({
|
||||
url: '/share/code/expert/bind/users',
|
||||
method: Method.GET,
|
||||
needToken: true,
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 分销的消费记录
|
||||
* @param params
|
||||
*/
|
||||
export function getcompleted(data) {
|
||||
return http.request({
|
||||
url: '/share/code/completed-orders',
|
||||
method: Method.GET,
|
||||
needToken: true,
|
||||
params:data
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 绑定推荐码
|
||||
* @param params
|
||||
|
@ -65,7 +65,7 @@ export default {
|
||||
{
|
||||
color: "#04BE02",
|
||||
title: "消息",
|
||||
icon: "weixin-circle-fill",
|
||||
icon: "man-add-fill",
|
||||
type: 2,
|
||||
},
|
||||
],
|
||||
@ -73,7 +73,7 @@ export default {
|
||||
},
|
||||
// 图片缩略图、 商品名称 、 type(goods,shop,pintuan) 拼团商品分享以及店铺分享
|
||||
|
||||
props: ["thumbnail", "goodsName", "type", "goodsId", "link","price"],
|
||||
props: ["thumbnail", "goodsName", "type", "goodsId", "link", "price"],
|
||||
methods: {
|
||||
close() {
|
||||
this.$emit("close");
|
||||
@ -154,37 +154,34 @@ export default {
|
||||
});
|
||||
}
|
||||
if (val.type == 2) {
|
||||
// 优化复制逻辑,确保内容存在
|
||||
// props: ["thumbnail", "goodsName", "type", "goodsId", "link","price"],
|
||||
// console.log(this.link,'===')
|
||||
// const mofn=JSON.stringify('名字:'+this.goodsName+',价格:'+this.price+','+this.link)
|
||||
|
||||
const mofn=this.goodsName+','+this.price+','+this.thumbnail.split('?')[0].split('com')[1]+','+this.link.split('?')[1]
|
||||
// const mofn={nage:this.goodsName,price:this.price,img:this.thumbnail.split('?')[0],link:this.link}
|
||||
console.log('===+++',mofn.split(',')[1])
|
||||
console.log('===+++',this.thumbnail)
|
||||
console.log('===+++',mofn.split(',')[3])
|
||||
// uni.setClipboardData({
|
||||
// data: mofn,
|
||||
// success: () => {
|
||||
// uni.showToast({
|
||||
// title: "复制成功",
|
||||
// icon: "none",
|
||||
// });
|
||||
// uni.switchTab({
|
||||
// url: "/pages/tabbar/im/index",
|
||||
// fail: (err) => {
|
||||
// console.error("跳转失败--:", err); // 查看具体错误
|
||||
// },
|
||||
// });
|
||||
|
||||
// },
|
||||
// fail: () => {
|
||||
// uni.showToast({
|
||||
// title: "不支持",
|
||||
// });
|
||||
// },
|
||||
// });
|
||||
const mofn =
|
||||
this.goodsName +
|
||||
"," +
|
||||
this.price +
|
||||
"," +
|
||||
this.thumbnail.split("?")[0].split("com")[1] +
|
||||
"," +
|
||||
this.link.split("?")[1];
|
||||
uni.setClipboardData({
|
||||
data: mofn,
|
||||
success: () => {
|
||||
uni.showToast({
|
||||
title: "复制成功",
|
||||
icon: "none",
|
||||
});
|
||||
uni.switchTab({
|
||||
url: "/pages/tabbar/im/index",
|
||||
fail: (err) => {
|
||||
console.error("跳转失败--:", err); // 查看具体错误
|
||||
},
|
||||
});
|
||||
},
|
||||
fail: () => {
|
||||
uni.showToast({
|
||||
title: "不支持",
|
||||
});
|
||||
},
|
||||
});
|
||||
}
|
||||
},
|
||||
// #endif
|
||||
|
@ -322,7 +322,7 @@ export default {
|
||||
return `${m}:${s < 10 ? '0' : ''}${s}`;
|
||||
},
|
||||
onTimeUpdate(e) {
|
||||
console.log(e.detail.currentTime);
|
||||
// console.log(e.detail.currentTime);
|
||||
if (e.detail.currentTime > 0.2) {
|
||||
this.doplay(e.detail.currentTime);
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
const name = "lilishop"; //全局商城name
|
||||
const name = "无终街"; //全局商城name
|
||||
const schemeName = 'lilishop' //唤醒app需要的schemeName
|
||||
export default {
|
||||
name: name,
|
||||
|
12
pages.json
@ -573,6 +573,18 @@
|
||||
"navigationBarTitleText": "我的分销"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "mydistribution/my/myindex",
|
||||
"style": {
|
||||
"navigationBarTitleText": "用户"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "mydistribution/my/consumption",
|
||||
"style": {
|
||||
"navigationBarTitleText": "消费记录"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "makeMoney/index",
|
||||
"style": {
|
||||
|
@ -2,9 +2,9 @@
|
||||
<view class="add-address">
|
||||
<div class="uForm">
|
||||
<u-form :border-bottom="false" :model="form" ref="uForm" :error-type="['toast']" :rule="rules">
|
||||
<view class="selectAddress" @click="clickUniMap">
|
||||
<!-- <view class="selectAddress" @click="clickUniMap">
|
||||
选择收货地址
|
||||
</view>
|
||||
</view> -->
|
||||
<u-form-item class="border" label="收货人" label-width="130" prop="name">
|
||||
<u-input v-model="form.name" clearable placeholder="请输入收货人姓名" />
|
||||
</u-form-item>
|
||||
|
@ -319,15 +319,21 @@ export default {
|
||||
border-color: #fe3c3c !important;
|
||||
background-color: #fe3c3c !important;
|
||||
}
|
||||
.u-radio__icon-wrap--checked{
|
||||
border-color: #fe3c3c !important;
|
||||
background-color: #fe3c3c !important;
|
||||
}
|
||||
}
|
||||
.bunem {
|
||||
width: 309px;
|
||||
width: 309px;
|
||||
margin-top: 20px;
|
||||
height: 41px;
|
||||
font-size: 15px;
|
||||
line-height: 41px;
|
||||
text-align: center;
|
||||
color: #ffffff;
|
||||
height: 32px;
|
||||
display: flex;
|
||||
align-items: #ffffff;
|
||||
margin-bottom: 35px;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
}
|
||||
</style>
|
||||
|
@ -1,7 +1,14 @@
|
||||
<template>
|
||||
<div class="wrapper">
|
||||
<div class="imgage" v-if="type=='about'">
|
||||
<div>便捷生活畅玩无终街</div>
|
||||
<!-- <div class="title">{{ loginTitleWay[current].title }}</div>
|
||||
<div :class="current == 1 ? 'desc-light' : 'desc'">
|
||||
{{ loginTitleWay[current].desc
|
||||
}}<span v-if="current == 1">{{ mobile | secrecyMobile }}</span>
|
||||
</div> -->
|
||||
</div>
|
||||
<u-parse v-html="res.content"></u-parse>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
@ -10,6 +17,7 @@ export default {
|
||||
data() {
|
||||
return {
|
||||
res: "",
|
||||
type:"",
|
||||
way: {
|
||||
user: {
|
||||
title: "用户协议",
|
||||
@ -35,6 +43,7 @@ export default {
|
||||
uni.setNavigationBarTitle({
|
||||
title: this.way[option.type].title,
|
||||
});
|
||||
this.type = option.type;
|
||||
this.init(option);
|
||||
},
|
||||
|
||||
@ -53,4 +62,19 @@ export default {
|
||||
.wrapper {
|
||||
padding: 16rpx;
|
||||
}
|
||||
.imgage {
|
||||
width: 100%;
|
||||
height: 37.5vh;
|
||||
background: url("@/static/logn.png");
|
||||
background-size: 100% 100%;
|
||||
& > div {
|
||||
width: 100%;
|
||||
height: 80%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: end;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
}
|
||||
}
|
||||
</style>
|
@ -6,7 +6,7 @@
|
||||
v-model="inviteCode"
|
||||
type="text"
|
||||
aria-placeholder="
|
||||
请输入推荐码"
|
||||
请输入推荐码/手机号"
|
||||
/>
|
||||
</div>
|
||||
<div class="si_bottom">
|
||||
|
@ -80,10 +80,9 @@ export default {
|
||||
return {
|
||||
show: false,
|
||||
menuItems: [
|
||||
{name:"我的用户",url:''},
|
||||
{name:"消费记录",url:''},
|
||||
{name:"我的用户",url:'/pages/mine/mydistribution/my/myindex'},
|
||||
{name:"消费记录",url:'/pages/mine/mydistribution/my/consumption'},
|
||||
{name:"收益明细",url:''},
|
||||
{name:"提现记录",url:''},
|
||||
{name:"我的邀请码",url:'/pages/mine/invite'},
|
||||
]
|
||||
};
|
||||
|
107
pages/mine/mydistribution/my/consumption.vue
Normal file
@ -0,0 +1,107 @@
|
||||
<template>
|
||||
<div class="distribution-container">
|
||||
<div class="distribution-header">
|
||||
<view :style="{ textAlign: 'center' }">分销收益</view>
|
||||
<view class="hcolng" :style="{ textAlign: 'center' }">
|
||||
<view :style="{ fontSize: '30px' }">¥</view>
|
||||
<view :style="{ fontSize: '30px' }">{{ totle }}</view>
|
||||
<view :style="{ fontSize: '30px' }">积分</view>
|
||||
</view>
|
||||
</div>
|
||||
<div class="distribution-center">
|
||||
<div>
|
||||
<div>头像</div>
|
||||
<div>消费金额</div>
|
||||
<div>日期</div>
|
||||
</div>
|
||||
<div
|
||||
v-for="(item, index) in getlist"
|
||||
:key="item.id"
|
||||
:style="{ background: index % 2 == 0 ? '#fff' : '' }"
|
||||
>
|
||||
<div>
|
||||
<img :src="item.face" alt="" width="60" style="border-radius: 50%" />
|
||||
</div>
|
||||
<div>{{ item.nickName }}</div>
|
||||
<div>{{ timefun(item.lastLoginDate) }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { bindUsers, getcompleted } from "@/api/point.js";
|
||||
export default {
|
||||
name: "MyDistribution",
|
||||
data() {
|
||||
return {
|
||||
show: false,
|
||||
totle: 0,
|
||||
getlist: [],
|
||||
size:1,
|
||||
page:10,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
this.getl();
|
||||
},
|
||||
methods: {
|
||||
timefun(e) {
|
||||
return e.split(" ")[0];
|
||||
},
|
||||
touni(e) {
|
||||
uni.navigateTo({ url: e });
|
||||
},
|
||||
goToDepositPage() {
|
||||
uni.navigateTo({ url: "/pages/mine/deposit/operation" });
|
||||
},
|
||||
getl() {
|
||||
getcompleted({size:this.size,page:this.page}).then((res) => {
|
||||
this.getlist = res.data.result;
|
||||
this.totle = res.data.result.length;
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.distribution-container {
|
||||
font-family: "PingFang SC", "Helvetica Neue", Arial, sans-serif;
|
||||
width: 100%;
|
||||
color: #333;
|
||||
|
||||
.distribution-header {
|
||||
background-color: #ff7d00;
|
||||
color: white;
|
||||
padding: 25px 20px;
|
||||
.hcolng {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 50px;
|
||||
& > view {
|
||||
font-weight: 700;
|
||||
display: flex;
|
||||
font-size: 14px;
|
||||
margin: 0 5px;
|
||||
align-items: end;
|
||||
}
|
||||
}
|
||||
}
|
||||
.distribution-center {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
& > div {
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
padding: 10px 0px 10px 0px;
|
||||
& > div {
|
||||
width: 30%;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
// justify-content: space-evenly;
|
||||
}
|
||||
}
|
||||
</style>
|
107
pages/mine/mydistribution/my/myindex.vue
Normal file
@ -0,0 +1,107 @@
|
||||
<template>
|
||||
<div class="distribution-container">
|
||||
<!-- Header section -->
|
||||
<div class="distribution-header">
|
||||
<view class="hcolng">
|
||||
<view>共</view>
|
||||
<view :style="{ fontSize: '30px' }">{{ totle }}</view>
|
||||
<view>人</view>
|
||||
</view>
|
||||
</div>
|
||||
<div class="distribution-center">
|
||||
<div>
|
||||
<div>用户头像</div>
|
||||
<div>昵称</div>
|
||||
<div>绑定日期</div>
|
||||
</div>
|
||||
<div
|
||||
v-for="(item, index) in getlist"
|
||||
:key="item.id"
|
||||
:style="{ background: index % 2 == 0 ? '#fff' : '' }"
|
||||
>
|
||||
<div>
|
||||
<img :src="item.face" alt="" width="60" style="border-radius: 50%" />
|
||||
</div>
|
||||
<div>{{ item.nickName }}</div>
|
||||
<div>{{ timefun(item.lastLoginDate) }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { bindUsers } from "@/api/point.js";
|
||||
export default {
|
||||
name: "MyDistribution",
|
||||
data() {
|
||||
return {
|
||||
show: false,
|
||||
totle: 0,
|
||||
getlist: [],
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
this.getl();
|
||||
},
|
||||
methods: {
|
||||
timefun(e) {
|
||||
return e.split(" ")[0];
|
||||
},
|
||||
touni(e) {
|
||||
uni.navigateTo({ url: e });
|
||||
},
|
||||
goToDepositPage() {
|
||||
uni.navigateTo({ url: "/pages/mine/deposit/operation" });
|
||||
},
|
||||
getl() {
|
||||
bindUsers({}).then((res) => {
|
||||
this.getlist = res.data.result;
|
||||
this.totle = res.data.result.length;
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.distribution-container {
|
||||
font-family: "PingFang SC", "Helvetica Neue", Arial, sans-serif;
|
||||
width: 100%;
|
||||
color: #333;
|
||||
|
||||
.distribution-header {
|
||||
background-color: #ff7d00;
|
||||
color: white;
|
||||
padding: 25px 20px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
.hcolng {
|
||||
display: flex;
|
||||
padding: 10px 20px;
|
||||
margin-top: 50px;
|
||||
& > view {
|
||||
font-weight: 700;
|
||||
display: flex;
|
||||
font-size: 14px;
|
||||
margin: 0 5px;
|
||||
align-items: end;
|
||||
}
|
||||
}
|
||||
}
|
||||
.distribution-center {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
& > div {
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
padding: 10px 0px 10px 0px;
|
||||
& > div {
|
||||
width: 30%;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
// justify-content: space-evenly;
|
||||
}
|
||||
}
|
||||
</style>
|
@ -33,6 +33,7 @@
|
||||
max-count="1"
|
||||
:action="action"
|
||||
@on-uploaded="onUploadedtwo"
|
||||
@on-remove="onRemove"
|
||||
style="margin-left: 30px"
|
||||
></u-upload>
|
||||
<div class="describe">请压缩图片在2M以内,格式为gif,jpg,png</div>
|
||||
@ -207,6 +208,9 @@ export default {
|
||||
this.form.storeLogo.push(item.response.result);
|
||||
});
|
||||
},
|
||||
onRemove(lists) {
|
||||
this.form.storeLogo = [];
|
||||
},
|
||||
// 下一步
|
||||
next() {
|
||||
this.$refs.thirdForm.validate((valid) => {
|
||||
@ -220,11 +224,11 @@ export default {
|
||||
applyThird(params)
|
||||
.then((res) => {
|
||||
this.loading = false;
|
||||
uni.showToast({
|
||||
title: "请正确输入",
|
||||
icon: "none",
|
||||
duration: 1500,
|
||||
});
|
||||
// uni.showToast({
|
||||
// title: "请正确输入",
|
||||
// icon: "none",
|
||||
// duration: 1500,
|
||||
// });
|
||||
setTimeout(() => {
|
||||
uni.switchTab({
|
||||
url: "/pages/tabbar/user/my",
|
||||
@ -307,12 +311,15 @@ h4 {
|
||||
}
|
||||
.bunem {
|
||||
width: 309px;
|
||||
margin-top: 50px;
|
||||
height: 41px;
|
||||
font-size: 15px;
|
||||
line-height: 41px;
|
||||
text-align: center;
|
||||
color: #ffffff;
|
||||
margin-top: 20px;
|
||||
height: 32px;
|
||||
display: flex;
|
||||
align-items: #ffffff;
|
||||
margin-bottom: 35px;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
}
|
||||
::v-deep {
|
||||
.u-checkbox__icon-wrap--checked {
|
||||
|
@ -5,7 +5,7 @@
|
||||
<u-form-item prop="companyName" label="公司名称">
|
||||
<u-input v-model="form.companyName" placeholder="请填写公司信息" />
|
||||
</u-form-item>
|
||||
<u-form-item prop="companyAddressIdPath" label="公司所在地">
|
||||
<u-form-item label="公司所在地">
|
||||
<u-input
|
||||
v-model="path"
|
||||
type="select"
|
||||
@ -68,6 +68,8 @@
|
||||
max-count="1"
|
||||
style="margin-left: 70px"
|
||||
@on-uploaded="onUploadedone"
|
||||
|
||||
@on-remove="onRemoveone"
|
||||
></u-upload>
|
||||
</u-form-item>
|
||||
<h4>法人信息</h4>
|
||||
@ -87,6 +89,7 @@
|
||||
max-count="2"
|
||||
:action="action"
|
||||
@on-uploaded="onUploadedtwo"
|
||||
@on-remove="onRemove"
|
||||
style="margin-left: 70px"
|
||||
></u-upload>
|
||||
<div class="describe">
|
||||
@ -140,11 +143,10 @@ export default {
|
||||
form: {
|
||||
legalPhoto: [],
|
||||
licencePhoto: [],
|
||||
|
||||
companyAddressIdPath: [],
|
||||
legalId: "",
|
||||
legalName: "",
|
||||
companyName: "",
|
||||
// companyAddressIdPath: "",
|
||||
companyAddress: "",
|
||||
employeeNum: "",
|
||||
registeredCapital: "",
|
||||
@ -159,13 +161,6 @@ export default {
|
||||
trigger: ["blur", "change"],
|
||||
},
|
||||
],
|
||||
companyAddressIdPath: [
|
||||
{
|
||||
required: true,
|
||||
message: "请选择公司所在地",
|
||||
trigger: ["change"],
|
||||
},
|
||||
],
|
||||
companyAddress: [
|
||||
{
|
||||
required: true,
|
||||
@ -313,12 +308,17 @@ export default {
|
||||
// 将需要绑定的地址设置为空,并赋值
|
||||
this.form.consigneeAddressIdPath = [];
|
||||
this.form.consigneeAddressPath = [];
|
||||
this.form.companyAddressIdPath = [];
|
||||
let name = "";
|
||||
|
||||
e.forEach((item, index) => {
|
||||
if (item.id) {
|
||||
// 遍历数据
|
||||
this.form.consigneeAddressIdPath.push(item.id);
|
||||
this.form.companyAddressIdPath.push(item.id);
|
||||
console.log(item.id);
|
||||
console.log(this.form.companyAddressIdPath);
|
||||
|
||||
this.form.consigneeAddressPath.push(item.localName);
|
||||
name += item.localName;
|
||||
this.form.companyAddressPath = name;
|
||||
@ -349,12 +349,22 @@ export default {
|
||||
this.form.licencePhoto = item.response.result;
|
||||
});
|
||||
},
|
||||
|
||||
onRemoveone(index, lists) {
|
||||
this.form.licencePhoto=[]
|
||||
},
|
||||
// 法人证件电子版
|
||||
onUploadedtwo(lists) {
|
||||
lists.forEach((item) => {
|
||||
this.form.legalPhoto.push(item.response.result);
|
||||
const fn = this.form.legalPhoto.indexOf(item.response.result);
|
||||
if (fn == -1) {
|
||||
this.form.legalPhoto.push(item.response.result);
|
||||
}
|
||||
});
|
||||
},
|
||||
onRemove(index, lists) {
|
||||
this.form.legalPhoto.splice(index, 1);
|
||||
},
|
||||
|
||||
// 下一步
|
||||
next() {
|
||||
@ -363,11 +373,14 @@ export default {
|
||||
let params = JSON.parse(JSON.stringify(this.form));
|
||||
params.legalPhoto = this.form.legalPhoto.toString();
|
||||
params.licencePhoto = this.form.licencePhoto.toString();
|
||||
params.companyAddressIdPath = this.form.companyAddressIdPath.toString();
|
||||
if (
|
||||
this.form.legalPhoto != "" &&
|
||||
this.form.legalId != "" &&
|
||||
this.form.legalName != ""
|
||||
) {
|
||||
console.log(params,'========');
|
||||
|
||||
applyFirst(params)
|
||||
.then((res) => {
|
||||
if (res.data.success) {
|
||||
@ -417,12 +430,14 @@ export default {
|
||||
.bunem {
|
||||
width: 309px;
|
||||
margin-top: 20px;
|
||||
height: 41px;
|
||||
font-size: 15px;
|
||||
line-height: 41px;
|
||||
text-align: center;
|
||||
color: #ffffff;
|
||||
height: 32px;
|
||||
display: flex;
|
||||
align-items: #ffffff;
|
||||
margin-bottom: 35px;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
}
|
||||
.u-input {
|
||||
margin-left: 30px; // 可根据实际情况调整这个值
|
||||
|
@ -175,12 +175,15 @@ h4 {
|
||||
// }
|
||||
.bunem{
|
||||
width: 309px;
|
||||
margin-top: 50px;
|
||||
height: 41px;
|
||||
font-size: 15px;
|
||||
line-height: 41px;
|
||||
text-align: center;
|
||||
color: #ffffff;
|
||||
margin-top: 20px;
|
||||
height: 32px;
|
||||
display: flex;
|
||||
align-items: #ffffff;
|
||||
margin-bottom: 35px;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
}
|
||||
.u-input {
|
||||
margin-left: 30px; // 可根据实际情况调整这个值
|
||||
|
@ -1,8 +1,14 @@
|
||||
|
||||
<template>
|
||||
<view class="edition-intro">
|
||||
<image :src="config.logo" class="logo" />
|
||||
<h1> {{config.name}}</h1>
|
||||
<div class="imgage">
|
||||
<div>便捷生活畅玩无终街</div>
|
||||
<!-- <div class="title">{{ loginTitleWay[current].title }}</div>
|
||||
<div :class="current == 1 ? 'desc-light' : 'desc'">
|
||||
{{ loginTitleWay[current].desc
|
||||
}}<span v-if="current == 1">{{ mobile | secrecyMobile }}</span>
|
||||
</div> -->
|
||||
</div>
|
||||
<view class='version'>
|
||||
<!-- #ifdef APP-PLUS -->
|
||||
Version {{localVersion.version}}
|
||||
@ -19,11 +25,11 @@
|
||||
<u-cell-item title="证照信息" @click="navigateTo('/pages/mine/help/tips?type=message')"></u-cell-item>
|
||||
<u-cell-item title="服务协议" @click="navigateTo('/pages/mine/help/tips?type=user')"></u-cell-item>
|
||||
<u-cell-item title="隐私协议" @click="navigateTo('/pages/mine/help/tips?type=privacy')"></u-cell-item>
|
||||
<u-cell-item title="关于我们" :border-bottom="false" @click="navigateTo('/pages/mine/help/tips?type=about')"></u-cell-item>
|
||||
<u-cell-item title="公司介绍" :border-bottom="false" @click="navigateTo('/pages/mine/help/tips?type=about')"></u-cell-item>
|
||||
|
||||
</u-cell-group>
|
||||
|
||||
<view class="intro">
|
||||
<!-- <view class="intro">
|
||||
<view>{{config.customerServiceMobile ? `客服热线:${config.customerServiceMobile}` : ``}}</view>
|
||||
<view style="margin:20rpx 0 0 0;">{{config.customerServiceEmail ? `客服邮箱:${config.customerServiceEmail}` : ``}}</view>
|
||||
|
||||
@ -31,7 +37,7 @@
|
||||
<view style="margin:20rpx 0; color:#003a8c;" @click="navigateTo('/pages/mine/help/tips?type=user')">《{{config.name}}用户协议》</view>
|
||||
<view>CopyRight @{{config.name}} </view>
|
||||
</view>
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
</template>
|
||||
|
||||
@ -136,7 +142,7 @@ page {
|
||||
background: #fff;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
// justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
> h1 {
|
||||
@ -154,7 +160,22 @@ page {
|
||||
letter-spacing: 2rpx;
|
||||
}
|
||||
.logo {
|
||||
width: 200rpx;
|
||||
height: 200rpx;
|
||||
width: 100%;
|
||||
// height: 200rpx;
|
||||
}
|
||||
.imgage {
|
||||
width: 100%;
|
||||
height: 37.5vh;
|
||||
background: url("@/static/logn.png");
|
||||
background-size: 100% 100%;
|
||||
& > div {
|
||||
width: 100%;
|
||||
height: 80%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: end;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
@ -39,7 +39,15 @@
|
||||
placeholder="请选择城市"
|
||||
right-icon="arrow-right"
|
||||
>
|
||||
<div style="width: 100%" @click="clickRegion">
|
||||
<div
|
||||
style="
|
||||
width: 32vh;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
"
|
||||
@click="clickRegion"
|
||||
>
|
||||
{{ form.___path || "请选择城市" }}
|
||||
</div>
|
||||
</u-form-item>
|
||||
@ -87,7 +95,7 @@ export default {
|
||||
form: {
|
||||
nickName: storage.getUserInfo().nickName || "",
|
||||
birthday: storage.getUserInfo().birthday || "",
|
||||
face: storage.getUserInfo().face || "/static/missing-face.png", //默认头像
|
||||
face: storage.getUserInfo().face || "/static/imlogo.png", //默认头像
|
||||
regionId: [], //地址Id
|
||||
region: storage.getUserInfo().region || [], //地址
|
||||
sex: storage.getUserInfo().sex, //性别
|
||||
@ -317,4 +325,7 @@ export default {
|
||||
background-color: #fe3c3c !important;
|
||||
}
|
||||
}
|
||||
|
||||
.u-form-item div {
|
||||
}
|
||||
</style>
|
||||
|
@ -20,7 +20,7 @@
|
||||
<u-cell-item title="意见反馈" @click="navigateTo('/pages/mine/set/feedBack')"></u-cell-item>
|
||||
<!-- #ifndef H5 -->
|
||||
<!-- #endif -->
|
||||
<u-cell-item :title="`关于${config.name}`" @click="navigateTo('/pages/mine/set/editionIntro')"></u-cell-item>
|
||||
<u-cell-item :title="`关于我们`" @click="navigateTo('/pages/mine/set/editionIntro')"></u-cell-item>
|
||||
</u-cell-group>
|
||||
<view class="submit" @click="showModalDialog">{{userInfo.id ?'退出登录':'返回登录'}}</view>
|
||||
<u-modal show-cancel-button v-model="quitShow" @confirm="confirm" :confirm-color="lightColor" :async-close="true"
|
||||
|
@ -349,7 +349,7 @@ export default {
|
||||
// 接收分类的数据
|
||||
|
||||
this.routerVal = val;
|
||||
|
||||
console.log(this.routerVal);
|
||||
// 有值
|
||||
if (this.routerVal.category) {
|
||||
this.params.categoryId = this.routerVal.category;
|
||||
@ -705,6 +705,8 @@ export default {
|
||||
if (type == "refresh") {
|
||||
this.goodsList = [];
|
||||
}
|
||||
console.log(this.params,'==');
|
||||
|
||||
//没有更多直接返回 #TODO
|
||||
let goodsList = await getGoodsList(this.params);
|
||||
|
||||
|
@ -113,7 +113,7 @@
|
||||
borderRadius="10rpx"
|
||||
width="200rpx"
|
||||
height="200rpx"
|
||||
:src="val.goodsSku.thumbnail"
|
||||
:src="imgfun(val.goodsSku.thumbnail)"
|
||||
alt
|
||||
/>
|
||||
</div>
|
||||
@ -256,7 +256,6 @@
|
||||
</u-row>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 配送地区没有提示 -->
|
||||
<div class="notSupportFreight" v-if="notSupportFreight.length != 0">
|
||||
<u-notice-bar
|
||||
@ -648,6 +647,8 @@ export default {
|
||||
// 获取会员默认地址
|
||||
this.getUserAddress();
|
||||
} else {
|
||||
// console.log(res.data.result,"=====");
|
||||
|
||||
this.address = res.data.result.memberAddress;
|
||||
res.data.result.memberAddress.consigneeAddressPath = res.data.result.memberAddress.consigneeAddressPath.split(
|
||||
","
|
||||
|
@ -75,7 +75,7 @@
|
||||
</div>
|
||||
|
||||
<!-- 循环出当前可使用的第三方登录模式 -->
|
||||
<div class="flex login-list">
|
||||
<!-- <div class="flex login-list">
|
||||
<div
|
||||
v-if="item.code"
|
||||
:style="{ background: item.color }"
|
||||
@ -100,7 +100,7 @@
|
||||
height="80"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
<myVerification
|
||||
v-if="codeFlag"
|
||||
@send="verification"
|
||||
|
@ -243,9 +243,9 @@
|
||||
<u-icon name="more-dot-fill"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="card-flex" @click="shutMask(3)" v-if="ste==1">
|
||||
<view class="card-flex" @click="shutMask(3)" v-if="ste == 1">
|
||||
<view class="card-title"> 送至</view>
|
||||
<view class="card-content" >
|
||||
<view class="card-content">
|
||||
<span v-if="delivery">{{
|
||||
delivery.consigneeAddressPath | clearStrComma
|
||||
}}</span>
|
||||
@ -256,9 +256,9 @@
|
||||
<u-icon name="more-dot-fill"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="card-flex" v-else>
|
||||
<view class="card-title"> 店铺位置</view>
|
||||
<view class="card-content" >
|
||||
<view class="card-flex" v-else @click="copyAddren">
|
||||
<view class="card-title"> 位置</view>
|
||||
<view class="card-content">
|
||||
{{ addren }}
|
||||
</view>
|
||||
|
||||
@ -316,7 +316,7 @@
|
||||
<view class="detail-btn" v-if="!isGroup">
|
||||
<view
|
||||
class="to-store-car to-store-btn"
|
||||
v-if="goodsDetail.goodsType != 'VIRTUAL_GOODS' && ste==1 "
|
||||
v-if="goodsDetail.goodsType != 'VIRTUAL_GOODS' && ste == 1"
|
||||
@click="shutMask(4)"
|
||||
>
|
||||
加入购物车</view
|
||||
@ -452,11 +452,11 @@ export default {
|
||||
GoodsSwiper,
|
||||
popupGoods,
|
||||
popupAddress,
|
||||
TUIChatKit
|
||||
TUIChatKit,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
addren:"",
|
||||
addren: "",
|
||||
setup,
|
||||
promotionShow: false, //弹窗开关
|
||||
promotionFlag: true, //活动开关
|
||||
@ -578,7 +578,7 @@ export default {
|
||||
|
||||
routerVal: "",
|
||||
IMLink: "", // IM地址
|
||||
ste:1
|
||||
ste: 1,
|
||||
};
|
||||
},
|
||||
|
||||
@ -604,7 +604,7 @@ export default {
|
||||
},
|
||||
},
|
||||
mounted() {
|
||||
this.ste=uni.getStorageSync('ste')
|
||||
this.ste = uni.getStorageSync("ste");
|
||||
const { windowHeight } = uni.getSystemInfoSync();
|
||||
let bottomHeight = 0;
|
||||
let topHeight = 0;
|
||||
@ -721,7 +721,7 @@ export default {
|
||||
}
|
||||
/**商品信息以及规格信息存储 */
|
||||
this.goodsDetail = response.data.result.data;
|
||||
this.addren= response.data.result.storeAddressPath;
|
||||
this.addren = response.data.result.storeAddressPath;
|
||||
|
||||
this.goodsSpec = response.data.result.specs;
|
||||
this.PromotionList = response.data.result.promotionMap;
|
||||
@ -773,7 +773,7 @@ export default {
|
||||
// storage.getUserInfo
|
||||
getUserimInfo()
|
||||
.then(({ data }) => {
|
||||
if (data.success ) {
|
||||
if (data.success) {
|
||||
const par = data.result;
|
||||
TUILogin.login({
|
||||
SDKAppID: par.sdkAppId,
|
||||
@ -918,7 +918,15 @@ export default {
|
||||
getStoreBaseInfoFun(id) {
|
||||
API_store.getStoreBaseInfo(id).then((res) => {
|
||||
if (res.data.success) {
|
||||
this.storeDetail = res.data.result;
|
||||
if (res.data.result != "null") {
|
||||
this.storeDetail = res.data.result;
|
||||
} else {
|
||||
uni.reLaunch({ url: "/" });
|
||||
uni.showToast({
|
||||
title: "店铺已关闭!",
|
||||
icon: "none",
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
@ -975,7 +983,6 @@ export default {
|
||||
keyword: this.goodsDetail.name,
|
||||
}).then((res) => {
|
||||
this.likeGoodsList = res.data.result.content;
|
||||
|
||||
});
|
||||
},
|
||||
|
||||
@ -1155,6 +1162,17 @@ export default {
|
||||
async shareChange() {
|
||||
this.shareFlage = true;
|
||||
},
|
||||
copyAddren() {
|
||||
uni.setClipboardData({
|
||||
data: this.addren,
|
||||
success: () => {
|
||||
uni.showToast({
|
||||
title: "复制成功",
|
||||
icon: "none",
|
||||
});
|
||||
},
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
@ -162,8 +162,6 @@ import config from "@/config/config";
|
||||
import storage from "@/utils/storage";
|
||||
import { getGoodsList } from "@/api/goods.js";
|
||||
import { getAllCoupons } from "@/api/promotions.js";
|
||||
import setup from "./product/popup/popup";
|
||||
TUIChatKit.init();
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@ -350,9 +348,17 @@ export default {
|
||||
*/
|
||||
async getStoreData() {
|
||||
let res = await getStoreBaseInfo(this.storeId);
|
||||
res.data.success
|
||||
? (this.storeInfo = res.data.result)
|
||||
: uni.reLaunch({ url: "/" });
|
||||
if(res.data.success){
|
||||
if(res.data.result!='null'){
|
||||
this.storeInfo = res.data.result;
|
||||
}else{
|
||||
uni.reLaunch({ url: "/" })
|
||||
uni.showToast({
|
||||
title: "店铺已关闭!",
|
||||
icon: "none",
|
||||
});
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
/** 加载商品 */
|
||||
|
@ -904,7 +904,15 @@ export default {
|
||||
getStoreBaseInfoFun(id) {
|
||||
API_store.getStoreBaseInfo(id).then((res) => {
|
||||
if (res.data.success) {
|
||||
this.storeDetail = res.data.result;
|
||||
if (res.data.result != "null") {
|
||||
this.storeDetail = res.data.result;
|
||||
} else {
|
||||
uni.reLaunch({ url: "/" });
|
||||
uni.showToast({
|
||||
title: "店铺已关闭!",
|
||||
icon: "none",
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
|
@ -19,7 +19,7 @@
|
||||
<view class="index-items">
|
||||
<view class="index-item" v-for="(item, key) in nav.goods" :key="key" @click="toGoods(item)">
|
||||
<view class="index-item-img">
|
||||
<u-image :src="item.thumbnail" mode="aspectFill">
|
||||
<u-image :src="imgfun(item.thumbnail)" mode="aspectFill">
|
||||
<u-loading slot="loading"></u-loading>
|
||||
</u-image>
|
||||
<view class="index-item-title">{{ item.goodsName }}</view>
|
||||
|
@ -5,7 +5,7 @@
|
||||
<u-image shape="circle" :lazy-load="true" width="100" height="100"
|
||||
:src="userInfo.face || '/static/missing-face.png'"></u-image>
|
||||
<div class="whether-point">
|
||||
<div>你的可用积分:<span class="point">{{userInfo.point || 0}}</span></div>
|
||||
<div>积分:<span class="point">{{userInfo.point || 0}}</span></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -34,9 +34,9 @@ export default {
|
||||
<style lang="scss" scoped>
|
||||
.user-point {
|
||||
padding: 0 20rpx;
|
||||
height: 300rpx;
|
||||
height: 200px;
|
||||
background: url("/static/point-bg.png") no-repeat;
|
||||
background-size: 100%;
|
||||
background-size: 100% 100%;
|
||||
}
|
||||
.point {
|
||||
font-size: 40rpx;
|
||||
|
@ -202,7 +202,7 @@ export default {
|
||||
.sale-head {
|
||||
image {
|
||||
width: 100%;
|
||||
height: 280rpx;
|
||||
height: 200px;
|
||||
}
|
||||
}
|
||||
|
||||
|
Before Width: | Height: | Size: 31 KiB After Width: | Height: | Size: 366 KiB |
@ -66,9 +66,13 @@ export default {
|
||||
tpl,
|
||||
},
|
||||
onReachBottom() {
|
||||
console.log("触底了");
|
||||
this.$refs.childComp.loadMon();
|
||||
},
|
||||
onPullDownRefresh() {
|
||||
setTimeout(() => {
|
||||
uni.stopPullDownRefresh();
|
||||
}, 1000);
|
||||
},
|
||||
methods: {
|
||||
change(index) {
|
||||
this.current = index;
|
||||
@ -92,7 +96,7 @@ export default {
|
||||
}
|
||||
::v-deep {
|
||||
.u-tabs {
|
||||
padding: 25px 20px 0px 20px;
|
||||
padding: 30px 20px 0px 20px;
|
||||
}
|
||||
.u-tab-item {
|
||||
color: $main-color !important;
|
||||
|
@ -1,5 +1,5 @@
|
||||
/** 配置楼层模块的跳转 */
|
||||
export function modelNavigateTo(item) {
|
||||
export function modelNavigateTo(item,ste='') {
|
||||
let val = item.url;
|
||||
|
||||
switch (val.___type) {
|
||||
@ -11,7 +11,7 @@ export function modelNavigateTo(item) {
|
||||
case "category":
|
||||
if (val.id) {
|
||||
uni.navigateTo({
|
||||
url: `/pages/navigation/search/searchPage?category=${val.id}`,
|
||||
url: `/pages/navigation/search/searchPage?category=${val.id}&ste=${ste}`,
|
||||
});
|
||||
} else {
|
||||
uni.navigateTo({
|
||||
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="layout">
|
||||
<div class="menu-list">
|
||||
<div class="menu-item" @click="modelNavigateTo(item)" v-for="(item, index) in res.list" :key="index">
|
||||
<div class="menu-item" @click="modelNavigateTo(item,val)" v-for="(item, index) in res.list" :key="index">
|
||||
<div>
|
||||
<u-image
|
||||
width="88rpx"
|
||||
@ -21,12 +21,16 @@
|
||||
import {modelNavigateTo} from './tpl'
|
||||
export default {
|
||||
title:"五列菜单",
|
||||
props: ["res"],
|
||||
props: ["res","val"],
|
||||
data () {
|
||||
return {
|
||||
modelNavigateTo,
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted () {
|
||||
console.log(this.val,'=========')
|
||||
// this.$u.toast('Hello uView!');
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
|
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div class="layout">
|
||||
<div class="addres" @click="showPicker" style="white-space: nowrap; overflow: hidden; text-overflow: ellipsis;">
|
||||
<div class="addres" @click="showPicker">
|
||||
{{ cityOrCounty == "" ? "请选择" : cityOrCounty }}
|
||||
</div>
|
||||
<div class="search" @click="handleSearch">{{ res.list[0].title }}</div>
|
||||
@ -240,10 +240,13 @@ export default {
|
||||
}
|
||||
.addres {
|
||||
// width: 15%;
|
||||
width: 60px;
|
||||
height: 32px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
padding: 0px 10px 0px 10px;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
line-height: 32px;
|
||||
}
|
||||
.layout {
|
||||
// background: #fff;
|
||||
|
@ -7,11 +7,22 @@
|
||||
@click="handleClick(item)"
|
||||
>
|
||||
<div class="pl_img">
|
||||
<img :src="imgfun(item.thumbnail)" alt="" width="100" />
|
||||
<img :src="imgfun(item.thumbnail)" alt="" width="100" height="100"/>
|
||||
</div>
|
||||
<div class="right">
|
||||
<div>{{ item.goodsName }}</div>
|
||||
<div>价格:¥{{ item.price }}</div>
|
||||
<div style="font-size:18px">{{ item.goodsName }}
|
||||
</div>
|
||||
<div>收藏:{{ item.commentNum }}
|
||||
</div>
|
||||
<div class="proice">价格:¥{{ item.price }}</div>
|
||||
|
||||
<div class="flex store-distance">
|
||||
<div>
|
||||
<template v-for="i in 5">
|
||||
<u-icon :name="i <= item.descriptionScore ? 'star-fill' : 'star'" class="proice" size="30"></u-icon>
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
<div>地址:{{ item.storeAddressPath }}</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -123,8 +134,8 @@ export default {
|
||||
border: 1px solid #eee;
|
||||
display: flex;
|
||||
.pl_img{
|
||||
// width: 100px;
|
||||
// height: 100px;
|
||||
// width: 100px;
|
||||
// height: 100px;
|
||||
padding: 10px;
|
||||
// &>img{
|
||||
// width: 100%;
|
||||
@ -134,6 +145,11 @@ export default {
|
||||
.right{
|
||||
// flex: 1;
|
||||
padding: 10px;
|
||||
font-size: 12px;
|
||||
|
||||
}
|
||||
}
|
||||
.proice{
|
||||
color: $light-color;
|
||||
}
|
||||
</style>
|
||||
|
@ -41,7 +41,7 @@
|
||||
<flexFour v-if="item.type == 'flexFour'" :res="item.options" />
|
||||
<flexTwo v-if="item.type == 'flexTwo'" :res="item.options" />
|
||||
<textPicture v-if="item.type == 'textPicture'" :res="item.options" />
|
||||
<menuLayout v-if="item.type == 'menu'" :res="item.options" />
|
||||
<menuLayout v-if="item.type == 'menu'" :val="ste" :res="item.options" />
|
||||
<flexOne v-if="item.type == 'flexOne'" :res="item.options" />
|
||||
<activity v-if="item.type == 'activity'" :res="item.options" />
|
||||
<Talent v-if="item.type == 'talent'" :res="item.options" :model="item" />
|
||||
@ -93,7 +93,7 @@ export default {
|
||||
config,
|
||||
pageData: "", //楼层页面数据
|
||||
isIos: "",
|
||||
isload:false
|
||||
isload: false,
|
||||
};
|
||||
},
|
||||
components: {
|
||||
@ -148,7 +148,7 @@ export default {
|
||||
|
||||
methods: {
|
||||
loadMon() {
|
||||
this.isload=!this.isload
|
||||
this.isload = !this.isload;
|
||||
// this.$refs.loadMonfn.loadMon();
|
||||
},
|
||||
/**
|
||||
@ -160,12 +160,14 @@ export default {
|
||||
if (this.ste == 1) {
|
||||
getFloorData().then((res) => {
|
||||
if (res.data.success) {
|
||||
console.log("商城数据已加载完成");
|
||||
this.pageData = JSON.parse(res.data.result.pageData);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
getFloorgetBendi().then((res) => {
|
||||
if (res.data.success) {
|
||||
console.log("本地生活数据已加载完成");
|
||||
this.pageData = JSON.parse(res.data.result.pageData);
|
||||
}
|
||||
});
|
||||
@ -186,7 +188,6 @@ export default {
|
||||
let path = encodeURIComponent(res.result);
|
||||
// WX_CODE 为小程序码
|
||||
if (res.scanType == "WX_CODE") {
|
||||
console.log(res);
|
||||
uni.navigateTo({
|
||||
url: `/${res.path}`,
|
||||
});
|
||||
|
@ -1,47 +1,43 @@
|
||||
<template>
|
||||
<div style="height: 100%">
|
||||
<div class="jolkp">
|
||||
<div
|
||||
class="fan"
|
||||
:style="{ marginRight: statue == 0 ? '50%' : '50%' }"
|
||||
>
|
||||
<div
|
||||
@click="hui(0)"
|
||||
:style="{ marginTop: '35px', color: '#fff' }"
|
||||
v-if="statue == 1 || 6"
|
||||
>
|
||||
<
|
||||
</div>
|
||||
</div>
|
||||
<!-- <TUIContact v-else-if="statue==1" :stu="2" /> -->
|
||||
<div
|
||||
@click="hui(6)"
|
||||
class="jolkp_z"
|
||||
v-if="statue == 0 || 6"
|
||||
:style="{ marginTop: '40px' }"
|
||||
>
|
||||
<div class="tiole">{{ tole }}</div>
|
||||
</div>
|
||||
<div style="height: 100%" @click="handleTouchStart">
|
||||
<div class="jolkp">
|
||||
<div
|
||||
class="fan"
|
||||
:style="{ marginRight: statue == 0 ? '47.5%' : '47.5%' }"
|
||||
>
|
||||
<div
|
||||
@click="hui(0)"
|
||||
:style="{ marginTop: '45px' }"
|
||||
v-if="statue !=0"
|
||||
>
|
||||
<u-icon name="arrow-left"></u-icon>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <TUIContact v-else-if="statue==1" :stu="2" /> -->
|
||||
<div
|
||||
@click="hui(6)"
|
||||
class="jolkp_z"
|
||||
v-if="statue == 0 || 6"
|
||||
:style="{ marginTop: '45px' }"
|
||||
>
|
||||
<div class="tiole">{{ tole }}</div>
|
||||
</div>
|
||||
|
||||
<div
|
||||
@click="hui(1)"
|
||||
class="jolkp_h"
|
||||
v-if="statue == 0 || 6"
|
||||
:style="{ marginTop: '35px' }"
|
||||
></div>
|
||||
<div
|
||||
@click="fnkiopl"
|
||||
class="jolkp_l"
|
||||
:style="{ marginTop: '35px' }"
|
||||
:style="{ marginTop: '45px' }"
|
||||
></div>
|
||||
<view class="jolkp_l" :style="{ marginTop: '45px' }"></view>
|
||||
<!-- 弹出框 -->
|
||||
<div v-if="isPopupVisible" class="popup" ref="popup">
|
||||
<view v-if="isPopupVisible" class="popup" ref="popup">
|
||||
<ul>
|
||||
<li @click="handleAddFriend">添加好友/群聊</li>
|
||||
<li @click="handleMenu()">发起群聊</li>
|
||||
<li @click="handleScan">扫一扫</li>
|
||||
</ul>
|
||||
</div>
|
||||
</view>
|
||||
</div>
|
||||
<!-- 搜索添加 -->
|
||||
<TUIContactsea v-if="statue == 2" @switchConversation="hui" />
|
||||
@ -56,6 +52,7 @@
|
||||
<!-- 群类型 -->
|
||||
<CreateGroup v-else-if="statue == 10" @con="confn" />
|
||||
<SelectFriendqlioa v-else-if="statue == 4" @concen="concen" />
|
||||
<ContactInfo v-else-if="statue == 7" @concen="concen" />
|
||||
<!-- 站内信数据 -->
|
||||
<!-- <div > -->
|
||||
<scroll-view
|
||||
@ -86,13 +83,10 @@
|
||||
</div>
|
||||
</scroll-view>
|
||||
|
||||
<!-- </div> -->
|
||||
<!-- 会话 -->
|
||||
<TUIConversation
|
||||
style="height: 100%"
|
||||
v-else
|
||||
/>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
<!-- 会话 -->
|
||||
<TUIConversation style="height: 100%" v-else @state="state" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
@ -105,13 +99,14 @@ import ContactSearch from "@/TUIKit/components/TUIContact/contact-search/index.v
|
||||
import CreateGroup from "@/TUIKit/components/TUIGroup/create-group/index.vue";
|
||||
import { TUIChatKit } from "@/TUIKit";
|
||||
import SelectFriend from "@/TUIKit/components/TUIContact/select-friend/index.vue";
|
||||
import ContactInfo from "@/TUIKit/components/TUIContact/contact-info/index.vue";
|
||||
import SelectFriendqlioa from "@/TUIKit/components/TUIGroup/index.vue";
|
||||
|
||||
import TUICore, { ExtensionInfo, TUIConstants } from "@tencentcloud/tui-core";
|
||||
import storage from "@/utils/storage.js";
|
||||
// push
|
||||
import { TUIConversationService } from '@tencentcloud/chat-uikit-engine';
|
||||
import * as Push from '@/uni_modules/TencentCloud-Push';
|
||||
import { TUIConversationService } from "@tencentcloud/chat-uikit-engine";
|
||||
import * as Push from "@/uni_modules/TencentCloud-Push";
|
||||
|
||||
import {
|
||||
getUserimInfo,
|
||||
@ -120,6 +115,16 @@ import {
|
||||
getMemberdelete,
|
||||
geterweijki,
|
||||
} from "@/api/members";
|
||||
import {
|
||||
TUITranslateService,
|
||||
TUIStore,
|
||||
StoreName,
|
||||
IGroupModel,
|
||||
TUIFriendService,
|
||||
Friend,
|
||||
FriendApplication,
|
||||
TUIUserService,
|
||||
} from "@tencentcloud/chat-uikit-engine";
|
||||
TUIChatKit.init();
|
||||
let vueVersion = 2;
|
||||
// vueVersion = 3;
|
||||
@ -135,10 +140,11 @@ export default {
|
||||
SelectFriendqlioa,
|
||||
TUIChatKit,
|
||||
CreateGroup,
|
||||
ContactInfo,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
statue: 0, // 0对话记录 1联系人 2添加好友/群聊 3建群 4群名称 6站内信
|
||||
statue: 0, // 0对话记录 1联系人 2添加好友/群聊 3建群 4群名称 6站内信 10群类型 7扫码后用户详情
|
||||
isPopupVisible: false, // 控制弹出框的显示与隐藏
|
||||
isq: false,
|
||||
popupRef: null, // 新增,用于保存弹窗的引用
|
||||
@ -167,52 +173,56 @@ export default {
|
||||
userSig: par.userSig,
|
||||
useUploadPlugin: true, // If you need to send rich media messages, please set to true.
|
||||
framework: `vue${vueVersion}`, // framework used vue2 / vue3
|
||||
}).then(()=>{
|
||||
Push.setRegistrationID(par.userID, () => {
|
||||
console.log('设置id设置id设置id设置id设置id设置id设置id设置id设置id设置id', par.userID);
|
||||
}).then(() => {
|
||||
Push.setRegistrationID(par.userID, () => {
|
||||
console.log(
|
||||
"设置id设置id设置id设置id设置id设置id设置id设置id设置id设置id",
|
||||
par.userID
|
||||
);
|
||||
|
||||
Push.registerPush(
|
||||
par.sdkAppId,
|
||||
'vkFpe55aYqfV7Sk5uGaoxhEstJ3tcI9dquk7JwG1GloDSLD2HeMWeQweWWXgNlhC',
|
||||
(data) => {
|
||||
console.log('registerPush ok', data);
|
||||
Push.getRegistrationID((registrationID) => {
|
||||
console.log('getRegistrationID ok', registrationID);
|
||||
});
|
||||
},
|
||||
(errCode, errMsg) => {
|
||||
console.error('registerPush failed', errCode, errMsg);
|
||||
}
|
||||
);
|
||||
});
|
||||
// 监听通知栏点击事件,获取推送扩展信息
|
||||
Push.addPushListener(Push.EVENT.NOTIFICATION_CLICKED, (res) => {
|
||||
console.log('notification clicked', res);
|
||||
// 解析扩展信息,跳转到相应的会话(代码仅供参考,发布前需要完善)
|
||||
try {
|
||||
const data = JSON.parse(res.data);
|
||||
const conv_type = data?.entity?.chatType === 1 ? 'C2C' : 'GROUP';
|
||||
// 根据推送信息拼的 conversationID
|
||||
const conversationID = `${conv_type}${data.entity.sender}`;
|
||||
// 切换会话
|
||||
TUIConversationService.switchConversation(conversationID);
|
||||
const chatPath = '/TUIKit/components/TUIChat/index';
|
||||
uni.navigateTo({ url: chatPath });
|
||||
} catch (error) {
|
||||
console.log('error', error);
|
||||
}
|
||||
});
|
||||
// 监听在线推送
|
||||
Push.addPushListener(Push.EVENT.MESSAGE_RECEIVED, (res) => {
|
||||
// res 为消息内容
|
||||
console.log('message received', res);
|
||||
});
|
||||
// 监听在线推送被撤回
|
||||
Push.addPushListener(Push.EVENT.MESSAGE_REVOKED, (res) => {
|
||||
// res 为被撤回的消息 ID
|
||||
console.log('message revoked', res);
|
||||
});
|
||||
})
|
||||
Push.registerPush(
|
||||
par.sdkAppId,
|
||||
"vkFpe55aYqfV7Sk5uGaoxhEstJ3tcI9dquk7JwG1GloDSLD2HeMWeQweWWXgNlhC",
|
||||
(data) => {
|
||||
console.log("registerPush ok", data);
|
||||
Push.getRegistrationID((registrationID) => {
|
||||
console.log("getRegistrationID ok", registrationID);
|
||||
});
|
||||
},
|
||||
(errCode, errMsg) => {
|
||||
console.error("registerPush failed", errCode, errMsg);
|
||||
}
|
||||
);
|
||||
});
|
||||
// 监听通知栏点击事件,获取推送扩展信息
|
||||
Push.addPushListener(Push.EVENT.NOTIFICATION_CLICKED, (res) => {
|
||||
console.log("notification clicked", res);
|
||||
// 解析扩展信息,跳转到相应的会话(代码仅供参考,发布前需要完善)
|
||||
try {
|
||||
const data = JSON.parse(res.data);
|
||||
const conv_type =
|
||||
data?.entity?.chatType === 1 ? "C2C" : "GROUP";
|
||||
// 根据推送信息拼的 conversationID
|
||||
const conversationID = `${conv_type}${data.entity.sender}`;
|
||||
// 切换会话
|
||||
TUIConversationService.switchConversation(conversationID);
|
||||
const chatPath = "/TUIKit/components/TUIChat/index";
|
||||
uni.navigateTo({ url: chatPath });
|
||||
} catch (error) {
|
||||
console.log("error", error);
|
||||
}
|
||||
});
|
||||
// 监听在线推送
|
||||
Push.addPushListener(Push.EVENT.MESSAGE_RECEIVED, (res) => {
|
||||
// res 为消息内容
|
||||
console.log("message received", res);
|
||||
});
|
||||
// 监听在线推送被撤回
|
||||
Push.addPushListener(Push.EVENT.MESSAGE_REVOKED, (res) => {
|
||||
// res 为被撤回的消息 ID
|
||||
console.log("message revoked", res);
|
||||
});
|
||||
});
|
||||
} else {
|
||||
// 接口返回非 200 状态码,跳转登录页面
|
||||
uni.navigateTo({
|
||||
@ -227,23 +237,62 @@ export default {
|
||||
});
|
||||
});
|
||||
},
|
||||
|
||||
mounted() {
|
||||
this.getMembermethod();
|
||||
this.setTime();
|
||||
// 监听全局点击事件
|
||||
document.addEventListener("click", (event) =>
|
||||
this.handleGlobalClick(event)
|
||||
);
|
||||
// 监听滚动事件
|
||||
|
||||
// 监听自定义全局点击事件
|
||||
uni.$on("globalClick", (event) => {
|
||||
// console.log(event, "====+++");
|
||||
this.handleGlobalClick(event);
|
||||
});
|
||||
|
||||
// // 在页面根元素上监听触摸开始事件并触发自定义全局点击事件
|
||||
// uni.onTouchStart((event) => {
|
||||
// uni.$emit("globalClick", event);
|
||||
// });
|
||||
},
|
||||
beforeDestroy() {
|
||||
// 移除全局点击事件
|
||||
document.removeEventListener("click", this.handleGlobalClick);
|
||||
// 移除全局点击事件监听
|
||||
uni.$off("globalClick");
|
||||
// 清除定时器
|
||||
clearTimeout(this.cleartime);
|
||||
// 移除滚动事件监听
|
||||
},
|
||||
methods: {
|
||||
state(item) {
|
||||
this.isPopupVisible = item;
|
||||
},
|
||||
handleTouchStart(event) {
|
||||
uni.$emit("globalClick", event);
|
||||
},
|
||||
handleGlobalClick(event) {
|
||||
const query = uni.createSelectorQuery().in(this);
|
||||
query
|
||||
.select(".jolkp_l")
|
||||
// 获取节点的布局位置和尺寸信息
|
||||
.boundingClientRect((rect) => {
|
||||
if (rect) {
|
||||
const clickX = event.clientX || event.touches[0].clientX;
|
||||
const clickY = event.clientY || event.touches[0].clientY;
|
||||
|
||||
if (clickX >= rect.left && clickX <= rect.width+rect.left
|
||||
&& clickY >= rect.top && clickY <= rect.top + rect.height*2) {
|
||||
// this.statue = 0; // 点击在节点范围内,执行相应操作
|
||||
console.log("点击是在节点范围");
|
||||
this.isPopupVisible = !this.isPopupVisible; // 隐藏弹出框
|
||||
}else{
|
||||
// this.statue = 0; // 点击在节点范围内,执行相应操作
|
||||
console.log("否");
|
||||
this.isPopupVisible = false; // 隐藏弹出框
|
||||
}
|
||||
}
|
||||
})
|
||||
// 执行查询操作
|
||||
.exec(() => {
|
||||
// this.isPopupVisible = true; // 隐藏弹出框
|
||||
});
|
||||
},
|
||||
lowerBottom() {
|
||||
if (this.total >= this.meList.length) {
|
||||
this.pageSize += 10;
|
||||
@ -258,7 +307,7 @@ export default {
|
||||
}, 10000);
|
||||
},
|
||||
torut(item) {
|
||||
// 将 item 对象转换为 JSON 字符串,以便在 URL 中传递
|
||||
this.isPopupVisible = false;
|
||||
const itemJson = encodeURIComponent(JSON.stringify(item));
|
||||
// 使用 uni.navigateTo 方法跳转到详情页,并传递信息
|
||||
uni.navigateTo({
|
||||
@ -283,11 +332,6 @@ export default {
|
||||
this.isPopupVisible = !this.isPopupVisible;
|
||||
this.popupRef = this.$refs.popup;
|
||||
},
|
||||
handleGlobalClick(event) {
|
||||
if (this.isPopupVisible && event.target._prevClass != "jolkp_l") {
|
||||
this.isPopupVisible = false;
|
||||
}
|
||||
},
|
||||
|
||||
getMembermethod() {
|
||||
const param = {
|
||||
@ -331,18 +375,13 @@ export default {
|
||||
this.isPopupVisible = false;
|
||||
uni.scanCode({
|
||||
success: (res) => {
|
||||
console.log("扫码结果:---", res);
|
||||
geterweijki(res.result).then((resfn) => {
|
||||
console.log(resfn, "====");
|
||||
this.getUserimInfo();
|
||||
this.statue = 0;
|
||||
});
|
||||
this.statue = 0;
|
||||
// 可以在这里添加处理扫码结果的逻辑
|
||||
},
|
||||
fail: (err) => {
|
||||
console.error("扫码失败:", err);
|
||||
this.statue = 0;
|
||||
console.log("扫码结果:---", res.result);
|
||||
const params = {
|
||||
userID: res.result, //userID
|
||||
};
|
||||
console.log("params", params);
|
||||
TUIStore.update(StoreName.CUSTOM, "currentContactInfo", params);
|
||||
this.statue = 7;
|
||||
},
|
||||
});
|
||||
},
|
||||
@ -373,152 +412,152 @@ uni-page-body,
|
||||
html,
|
||||
body,
|
||||
page {
|
||||
width: 100% !important;
|
||||
height: 100% !important;
|
||||
overflow: hidden;
|
||||
width: 100% !important;
|
||||
height: 100% !important;
|
||||
overflow: hidden;
|
||||
}
|
||||
.jolkp {
|
||||
height: 66px;
|
||||
display: flex;
|
||||
font-size: 15px;
|
||||
justify-content: end;
|
||||
/* 设置背景图 */
|
||||
background-image: url('@/static/im/Rectangle.png');
|
||||
/* 让背景图覆盖整个元素 */
|
||||
background-size: cover;
|
||||
/* 背景图不重复 */
|
||||
background-repeat: no-repeat;
|
||||
height: 75px;
|
||||
display: flex;
|
||||
font-size: 15px;
|
||||
justify-content: end;
|
||||
/* background: green; */
|
||||
/* 设置背景图 */
|
||||
/* background-image: url('@/static/im/Rectangle.png'); */
|
||||
/* 让背景图覆盖整个元素 */
|
||||
background-size: cover;
|
||||
/* 背景图不重复 */
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
|
||||
.jolkp_l {
|
||||
width: 2rem;
|
||||
height: 2rem;
|
||||
background-image: url('@/static/im/Frame.png');
|
||||
/* 让背景图覆盖整个元素 */
|
||||
background-size: cover;
|
||||
/* 背景图不重复 */
|
||||
background-repeat: no-repeat;
|
||||
margin-top: 35px;
|
||||
margin-right: 10px;
|
||||
width: 1.8rem;
|
||||
height: 1.8rem;
|
||||
background-image: url("@/static/im/Frame.png");
|
||||
/* 让背景图覆盖整个元素 */
|
||||
background-size: cover;
|
||||
/* 背景图不重复 */
|
||||
background-repeat: no-repeat;
|
||||
margin-top: 35px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
.jolkp_h {
|
||||
width: 2rem;
|
||||
height: 2rem;
|
||||
background-image: url('@/static/im/user.png');
|
||||
/* 让背景图覆盖整个元素 */
|
||||
background-size: cover;
|
||||
/* 背景图不重复 */
|
||||
background-repeat: no-repeat;
|
||||
margin-top: 35px;
|
||||
margin-right: 20px;
|
||||
width: 1.8rem;
|
||||
height: 1.8rem;
|
||||
background-image: url("@/static/im/user.png");
|
||||
/* 让背景图覆盖整个元素 */
|
||||
background-size: cover;
|
||||
/* 背景图不重复 */
|
||||
background-repeat: no-repeat;
|
||||
margin-top: 35px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.jolkp_z {
|
||||
width: 2rem;
|
||||
height: 1.5rem;
|
||||
background-image: url('@/static/im/znx.png');
|
||||
/* 让背景图覆盖整个元素 */
|
||||
background-size: cover;
|
||||
/* 背景图不重复 */
|
||||
background-size: 100% 100%;
|
||||
width: 1.8rem;
|
||||
height: 1.8rem;
|
||||
background-image: url("@/static/im/znx.png");
|
||||
/* 让背景图覆盖整个元素 */
|
||||
background-size: cover;
|
||||
/* 背景图不重复 */
|
||||
background-size: 100% 100%;
|
||||
|
||||
margin-top: 35px;
|
||||
margin-right: 20px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.tiole {
|
||||
margin-top: -10px;
|
||||
margin-left: 105%;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
margin-top: -10px;
|
||||
margin-left: 105%;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
}
|
||||
.popup {
|
||||
position: absolute;
|
||||
top: 65px;
|
||||
/* 调整弹出框的位置 */
|
||||
right: 5px;
|
||||
background-color: #fff;
|
||||
border: 1px solid #ccc;
|
||||
border-radius: 4px;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
||||
z-index: 3;
|
||||
position: absolute;
|
||||
top: 75px;
|
||||
/* 调整弹出框的位置 */
|
||||
right: 5px;
|
||||
background-color: #fff;
|
||||
border: 1px solid #ccc;
|
||||
border-radius: 4px;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
||||
z-index: 3;
|
||||
}
|
||||
|
||||
.popup ul {
|
||||
list-style-type: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
list-style-type: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.popup li {
|
||||
padding: 10px 20px;
|
||||
cursor: pointer;
|
||||
padding: 10px 20px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.popup li:hover {
|
||||
background-color: #f0f0f0;
|
||||
background-color: #f0f0f0;
|
||||
}
|
||||
|
||||
.fan {
|
||||
width: 10%;
|
||||
height: '100%';
|
||||
font-size: 18px;
|
||||
display: flex;
|
||||
width: 10%;
|
||||
height: "100%";
|
||||
font-size: 18px;
|
||||
display: flex;
|
||||
|
||||
padding: 5px;
|
||||
padding: 5px;
|
||||
}
|
||||
@media screen and (device-width: 393px) and (device-height: 851px) and (-webkit-device-pixel-ratio: 3) {
|
||||
.fan {
|
||||
margin-right: 56% !important;
|
||||
width: 10%;
|
||||
height: '100%';
|
||||
font-size: 18px;
|
||||
display: flex;
|
||||
margin-top: 85%;
|
||||
padding: 5px;
|
||||
}
|
||||
.fan {
|
||||
margin-right: 56% !important;
|
||||
width: 10%;
|
||||
height: "100%";
|
||||
font-size: 18px;
|
||||
display: flex;
|
||||
margin-top: 80%;
|
||||
/* padding: 5px; */
|
||||
}
|
||||
}
|
||||
.three {
|
||||
width: 100%;
|
||||
height: 10%;
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
align-items: center;
|
||||
background: rgb(255, 255, 255);
|
||||
width: 100%;
|
||||
height: 10%;
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
align-items: center;
|
||||
background: rgb(255, 255, 255);
|
||||
}
|
||||
.con {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
.three_div1 {
|
||||
height: 3rem;
|
||||
width: 40%;
|
||||
background-image: url('@/static/im/kf.png');
|
||||
background-size: 100% 100%;
|
||||
background-repeat: no-repeat;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: end;
|
||||
height: 3rem;
|
||||
width: 40%;
|
||||
background-image: url("@/static/im/kf.png");
|
||||
background-size: 100% 100%;
|
||||
background-repeat: no-repeat;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: end;
|
||||
}
|
||||
|
||||
.three_div2 {
|
||||
width: 40%;
|
||||
height: 3rem;
|
||||
background-image: url('@/static/im/hy.png');
|
||||
background-size: 100% 100%;
|
||||
background-repeat: no-repeat;
|
||||
width: 40%;
|
||||
width: 40%;
|
||||
height: 3rem;
|
||||
background-image: url("@/static/im/hy.png");
|
||||
background-size: 100% 100%;
|
||||
background-repeat: no-repeat;
|
||||
width: 40%;
|
||||
}
|
||||
|
||||
.three_div3 {
|
||||
height: 3rem;
|
||||
background-image: url('@/static/im/da.png');
|
||||
background-size: 100% 100%;
|
||||
background-repeat: no-repeat;
|
||||
width: 40%;
|
||||
height: 3rem;
|
||||
background-image: url("@/static/im/da.png");
|
||||
background-size: 100% 100%;
|
||||
background-repeat: no-repeat;
|
||||
width: 40%;
|
||||
}
|
||||
.tui-conversation-item {
|
||||
/* height: 10%; */
|
||||
@ -534,39 +573,38 @@ page {
|
||||
position: relative;
|
||||
}
|
||||
.content {
|
||||
display: flex;
|
||||
flex: 1;
|
||||
padding-left: 8px;
|
||||
justify-content: end;
|
||||
box-sizing: border-box;
|
||||
overflow: hidden;
|
||||
display: flex;
|
||||
flex: 1;
|
||||
padding-left: 8px;
|
||||
justify-content: end;
|
||||
box-sizing: border-box;
|
||||
overflow: hidden;
|
||||
}
|
||||
.left {
|
||||
position: relative;
|
||||
width: 36px;
|
||||
height: 36px;
|
||||
position: relative;
|
||||
width: 36px;
|
||||
height: 36px;
|
||||
}
|
||||
|
||||
.znx {
|
||||
max-height: 100vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
overflow-y: auto;
|
||||
max-height: 100vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.delete-button {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
width: 100px;
|
||||
background-color: red;
|
||||
color: white;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
cursor: pointer;
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
width: 100px;
|
||||
background-color: red;
|
||||
color: white;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
@ -10,15 +10,20 @@
|
||||
</view>
|
||||
<view class="head-2" v-if="userInfo.id">
|
||||
<view class="user-name">{{ userInfo.nickName }}</view>
|
||||
<view class="user-logn" v-if="ismongt.expert">
|
||||
<view class="mong"></view>
|
||||
<view>达人</view>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="head-2" v-else>
|
||||
<view class="user-name">登录/注册</view>
|
||||
</view>
|
||||
<u-icon
|
||||
<!-- <u-icon
|
||||
style="display: flex; align-items: flex-start"
|
||||
name="arrow-right"
|
||||
></u-icon>
|
||||
></u-icon> -->
|
||||
</view>
|
||||
<!-- 积分,优惠券,关注, -->
|
||||
<div class="pointBox box">
|
||||
@ -101,13 +106,15 @@
|
||||
</div>
|
||||
<!-- 常用工具 -->
|
||||
|
||||
<tool :userInfo="userInfo" v-if="userInfo.id != undefined" ref="tool"/>
|
||||
<tool :userInfo="userInfo" v-if="userInfo.id != undefined" ref="tool" />
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
import tool from "@/pages/tabbar/user/utils/tool.vue";
|
||||
import { getCouponsNum, getFootprintNum } from "@/api/members.js";
|
||||
import { getUserWallet } from "@/api/members";
|
||||
import Views from "../home/views.vue";
|
||||
import { getUserInfo } from "@/api/members";
|
||||
export default {
|
||||
components: {
|
||||
tool,
|
||||
@ -121,10 +128,14 @@ export default {
|
||||
couponNum: "",
|
||||
footNum: "",
|
||||
walletNum: "",
|
||||
ismongt: {},
|
||||
};
|
||||
},
|
||||
onLoad() {},
|
||||
onShow() {
|
||||
// if(this.ismongt.expert=='undefined'){
|
||||
this.getUser()
|
||||
// }
|
||||
this.userInfo = this.$options.filters.isLogin();
|
||||
if (this.$options.filters.isLogin("auth")) {
|
||||
this.getUserOrderNum();
|
||||
@ -134,9 +145,9 @@ export default {
|
||||
},
|
||||
onPullDownRefresh() {
|
||||
this.getUserOrderNum();
|
||||
this.getUser()
|
||||
this.userInfo = this.$options.filters.isLogin();
|
||||
this.$refs.tool.getUser();
|
||||
|
||||
},
|
||||
// #ifndef MP
|
||||
onNavigationBarButtonTap(e) {
|
||||
@ -149,6 +160,12 @@ export default {
|
||||
|
||||
mounted() {},
|
||||
methods: {
|
||||
getUser() {
|
||||
this.ismongt = {}
|
||||
getUserInfo().then((user) => {
|
||||
this.ismongt = user.data.result;
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 统一跳转接口,拦截未登录路由
|
||||
* navigator标签现在默认没有转场动画,所以用view
|
||||
@ -236,7 +253,7 @@ body {
|
||||
.head-2 {
|
||||
flex: 1;
|
||||
margin-left: 30rpx;
|
||||
margin-top: 100rpx;
|
||||
margin-top: 80rpx;
|
||||
line-height: 1;
|
||||
}
|
||||
/deep/ .u-icon,
|
||||
@ -298,7 +315,19 @@ body {
|
||||
.user-name {
|
||||
font-size: 34rpx;
|
||||
}
|
||||
.user-logn {
|
||||
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin: 15px 15px 0px 0px;
|
||||
font-size: 15px;
|
||||
.mong{
|
||||
width: 1rem;
|
||||
height:1rem;
|
||||
background: url("@/static/mon.png") no-repeat;
|
||||
background-size: 100% 100%;
|
||||
}
|
||||
}
|
||||
.bag {
|
||||
width: 56rpx;
|
||||
height: 56rpx;
|
||||
|
Before Width: | Height: | Size: 642 B After Width: | Height: | Size: 5.5 KiB |
Before Width: | Height: | Size: 761 B After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 404 B After Width: | Height: | Size: 4.1 KiB |
BIN
static/mon.png
Normal file
After Width: | Height: | Size: 2.0 KiB |
Before Width: | Height: | Size: 7.9 KiB After Width: | Height: | Size: 177 KiB |
153
utils/request.js
@ -17,41 +17,30 @@ function cleanStorage() {
|
||||
uni.hideLoading();
|
||||
}
|
||||
|
||||
storage.setHasLogin(false);
|
||||
storage.setAccessToken("");
|
||||
storage.setRefreshToken("");
|
||||
console.log("清空token");
|
||||
storage.setUuid("");
|
||||
storage.setUserInfo({});
|
||||
// 清理vlog信息
|
||||
storage.setVlogToken("")
|
||||
storage.setVlogUserInfo(null)
|
||||
// 清除初始化数据内容
|
||||
storage.setRefreshVlogIndex('0') //不需要刷新
|
||||
|
||||
|
||||
// 防抖处理跳转
|
||||
// #ifdef MP-WEIXIN
|
||||
|
||||
uni.navigateTo({
|
||||
url: "/pages/passport/wechatMPLogin",
|
||||
});
|
||||
|
||||
// #endif
|
||||
|
||||
// #ifndef MP-WEIXIN
|
||||
|
||||
storage.setHasLogin(false);
|
||||
storage.setAccessToken("");
|
||||
storage.setRefreshToken("");
|
||||
storage.setUuid("");
|
||||
storage.setUserInfo({});
|
||||
// 清理vlog信息
|
||||
storage.setVlogToken("");
|
||||
storage.setVlogUserInfo(null);
|
||||
// 清除初始化数据内容
|
||||
storage.setRefreshVlogIndex("0"); //不需要刷新
|
||||
// 获取当前页面栈
|
||||
const pages = getCurrentPages();
|
||||
const currentPage = pages[pages.length - 1];
|
||||
const currentRoute = currentPage.route;
|
||||
console.log(currentRoute,'===');
|
||||
|
||||
setTimeout(() => {
|
||||
uni.navigateTo({
|
||||
url: "/pages/passport/login",
|
||||
});
|
||||
}, 5000);
|
||||
|
||||
// 防抖处理跳转
|
||||
// #ifdef MP-WEIXIN
|
||||
if (currentRoute !== 'pages/passport/wechatMPLogin') {
|
||||
uni.navigateTo({ url: "/pages/passport/wechatMPLogin" });
|
||||
}
|
||||
// #endif
|
||||
// #ifndef MP-WEIXIN
|
||||
if (currentRoute !== 'pages/passport/login') {
|
||||
uni.navigateTo({ url: "/pages/passport/login" });
|
||||
}
|
||||
// #endif
|
||||
}
|
||||
|
||||
@ -95,29 +84,25 @@ http.interceptors.request.use(
|
||||
..._params,
|
||||
};
|
||||
|
||||
config.params = params;
|
||||
config.header.accessToken = accessToken;
|
||||
|
||||
}
|
||||
// 配置vlog所需参数
|
||||
let vlogToken = storage.getVlogToken();
|
||||
let vlogId = storage.getVlogUserInfo();
|
||||
// console.log(vlogId)
|
||||
// console.log(vlogToken)
|
||||
if (vlogToken) {
|
||||
config.header.headerUserToken = vlogToken;
|
||||
config.header.headerUserId = vlogId.id;
|
||||
}
|
||||
config.header = {
|
||||
...config.header,
|
||||
uuid: storage.getUuid() || uuid.v1(),
|
||||
};
|
||||
// console.log(config)
|
||||
return config;
|
||||
},
|
||||
(config) => {
|
||||
return Promise.reject(config);
|
||||
}
|
||||
config.params = params;
|
||||
config.header.accessToken = accessToken;
|
||||
}
|
||||
// 配置vlog所需参数
|
||||
let vlogToken = storage.getVlogToken();
|
||||
let vlogId = storage.getVlogUserInfo();
|
||||
if (vlogToken) {
|
||||
config.header.headerUserToken = vlogToken;
|
||||
config.header.headerUserId = vlogId.id;
|
||||
}
|
||||
config.header = {
|
||||
...config.header,
|
||||
uuid: storage.getUuid() || uuid.v1(),
|
||||
};
|
||||
return config;
|
||||
},
|
||||
(config) => {
|
||||
return Promise.reject(config);
|
||||
}
|
||||
);
|
||||
|
||||
// 是否正在刷新的标记
|
||||
@ -126,15 +111,15 @@ let isRefreshing = false;
|
||||
let requests = [];
|
||||
// 必须使用异步函数,注意
|
||||
http.interceptors.response.use(
|
||||
async (response) => {
|
||||
// console.log(isRefreshing)
|
||||
// console.log(response)
|
||||
/* 请求之后拦截器。可以使用async await 做异步操作 */
|
||||
// token存在并且token过期
|
||||
if (isRefreshing && response.statusCode === 403) {
|
||||
cleanStorage();
|
||||
isRefreshing = false;
|
||||
}
|
||||
async (response) => {
|
||||
// console.log(isRefreshing)
|
||||
// console.log(response)
|
||||
/* 请求之后拦截器。可以使用async await 做异步操作 */
|
||||
// token存在并且token过期
|
||||
if (isRefreshing && response.statusCode === 403) {
|
||||
cleanStorage();
|
||||
isRefreshing = false;
|
||||
}
|
||||
|
||||
let token = storage.getAccessToken();
|
||||
if (
|
||||
@ -181,26 +166,26 @@ http.interceptors.response.use(
|
||||
) {
|
||||
cleanStorage();
|
||||
|
||||
// 如果当前状态码为正常但是success为不正常时
|
||||
} else if (
|
||||
(response.statusCode == 200 && !response.data.success) ||
|
||||
response.statusCode == 400
|
||||
) {
|
||||
if (response.data.message) {
|
||||
uni.showToast({
|
||||
title: response.data.message,
|
||||
icon: "none",
|
||||
duration: 1500,
|
||||
});
|
||||
}
|
||||
} else if (response.data.code == 502) {
|
||||
cleanStorage();
|
||||
}
|
||||
return response;
|
||||
},
|
||||
(error) => {
|
||||
return error;
|
||||
}
|
||||
// 如果当前状态码为正常但是success为不正常时
|
||||
} else if (
|
||||
(response.statusCode == 200 && !response.data.success) ||
|
||||
response.statusCode == 400
|
||||
) {
|
||||
if (response.data.message) {
|
||||
uni.showToast({
|
||||
title: response.data.message,
|
||||
icon: "none",
|
||||
duration: 1500,
|
||||
});
|
||||
}
|
||||
} else if (response.data.code == 502) {
|
||||
cleanStorage();
|
||||
}
|
||||
return response;
|
||||
},
|
||||
(error) => {
|
||||
return error;
|
||||
}
|
||||
);
|
||||
|
||||
export { http };
|
||||
|