This commit is contained in:
陈浩 2025-03-28 16:05:11 +08:00
parent 57daf0f0f8
commit cefc3d67dc
19 changed files with 373 additions and 256 deletions

4
.gitignore vendored
View File

@ -1,7 +1,7 @@
# OSX
#
.DS_Store
/TUIKit/
/node_modules/
#Intellij idea
.idea/
/idea/

View File

@ -259,12 +259,13 @@ body {
transition-duration: 300ms;
}
// uni-page-body,
// html,
// body,
// page {
// width: 100% !important;
// height: 100% !important;
// width: 100% ;
// height: 100% ;
// overflow: hidden;
// }
</style>

View File

@ -16,7 +16,8 @@ img {
pointer-events:none;
}
body {
body{
height: 100% important;
color:#000;
background:#FFF;
}

View File

@ -1,6 +1,6 @@
<template>
<div class="chat">
<div :class="['tui-chat', !isPC && 'tui-chat-h5']">
<div class="chat" :style="{height:fn+'px'}">
<div :style="{height:'100%'}" :class="['tui-chat', !isPC && 'tui-chat-h5']">
<div
v-if="!currentConversationID"
:class="['tui-chat-default', !isPC && 'tui-chat-h5-default']"
@ -129,7 +129,7 @@ onUnload(() => {
// @End uniapp use Chat only
const emits = defineEmits(['closeChat']);
const fn = uni.getSystemInfoSync().windowHeight
const groupID = ref(undefined);
const isGroup = ref(false);
const isNotInGroup = ref(false);
@ -141,6 +141,8 @@ const messageInputRef = ref();
const messageListRef = ref<InstanceType<typeof MessageList>>();
const headerExtensionList = ref<ExtensionInfo[]>([]);
const featureConfig = TUIChatConfig.getFeatureConfig();
const ht = uni.getSystemInfoSync().windowHeight
onMounted(() => {
TUIStore.watch(StoreName.CONV, {
@ -302,4 +304,11 @@ function onCurrentConversationUpdate(conversation: IConversationModel) {
}
</script>
<style scoped lang="scss" src="./style/index.scss"></style>
<style scoped lang="scss" src="./style/index.scss">
.chat{
width: 100% !important;
height: 100vh !important;
overflow: hidden;
}
</style>

View File

@ -157,9 +157,11 @@ const onAt = (show: boolean) => {
};
const onFocus = () => {
if (isH5) {
// if (isH5) {
emits('changeToolbarDisplayType', 'none');
}
// }
//
// emits('changeToolbarDisplayType', 'none');
};
const insertEmoji = (emoji: any) => {

View File

@ -189,7 +189,7 @@ const onInput = (e: any) => {
const text = e?.detail?.value;
isEditorContentEmpty();
if (props.isGroup && (text.endsWith('@') || text.endsWith('@\n'))) {
TUIGlobal?.hideKeyboard();
// TUIGlobal?.hideKeyboard();
emits('onAt', true);
}
};

View File

@ -1,5 +1,6 @@
<template>
<div
:style="{height: '100%'}"
v-if="typeof contactInfoData === 'object' && Object.keys(contactInfoData).length"
:class="['tui-contact-info', !isPC && 'tui-contact-info-h5']"
>

View File

@ -4,13 +4,14 @@
v-else-if="isShowContactList"
:class="['tui-contact', !isPC && 'tui-contact-h5']"
>
<div :class="['tui-contact-left', !isPC && 'tui-contact-h5-left']">
<div :class="['tui-contact-left', !isPC && 'tui-contact-h5-left']" :style="{height:ht+'px'}">
<!-- <ContactSearch /> -->
<ContactList :class="['tui-contact-left-list', !isPC && 'tui-contact-h5-left-list']" />
</div>
<div
v-if="isShowContactInfo"
:class="['tui-contact-right', !isPC && 'tui-contact-h5-right']"
:style="{height:ht+'px'}"
>
<ContactInfo @switchConversation="switchConversation" />
</div>
@ -21,7 +22,7 @@ import { TUIStore, StoreName } from '@tencentcloud/chat-uikit-engine';
import { TUIGlobal } from '@tencentcloud/universal-api';
import { ref, watchEffect,defineProps } from '../../adapter-vue';
import { isPC, isUniFrameWork } from '../../utils/env';
const ht = uni.getSystemInfoSync().windowHeight
import SelectFriend from './select-friend/index.vue';
import ContactSearch from './contact-search/index.vue';
import ContactList from './contact-list/index.vue';

View File

@ -4,13 +4,14 @@
v-else-if="isShowContactList"
:class="['tui-contact', !isPC && 'tui-contact-h5']"
>
<div :class="['tui-contact-left', !isPC && 'tui-contact-h5-left']">
<div :class="['tui-contact-left', !isPC && 'tui-contact-h5-left']" :style="{height:ht+'px'}" >
<ContactSearch />
<ContactList :class="['tui-contact-left-list', !isPC && 'tui-contact-h5-left-list']" />
</div>
<div
v-if="isShowContactInfo"
:class="['tui-contact-right', !isPC && 'tui-contact-h5-right']"
:style="{height:ht+'px'}"
>
<ContactInfo @switchConversation="switchConversation" />
</div>
@ -28,7 +29,7 @@
import ContactInfo from './contact-info/index.vue';
const emits = defineEmits(['switchConversation']);
const ht = uni.getSystemInfoSync().windowHeight
const props = defineProps({
// web/h5 single page application display format, uniapp please ignore
displayType: {

View File

@ -61,7 +61,17 @@ export function getFloorData() {
method: "get",
});
}
/**
* 获取本地生活楼层数据
* @param client_type
* @param page_type
*/
export function getFloorgetBendi() {
return http.request({
url: `/other/pageData/getBendi?clientType=H5`,
method: "get",
});
}
/**
* 获取获取首页分类数据
*/

View File

@ -284,9 +284,11 @@ export default {
});
return;
}
const storedSte = uni.getStorageSync('ste');
let data = {
skuId: this.goodsDetail.id,
num: this.num,
ste:storedSte
};
if (val == "cart") {

View File

@ -1,7 +1,7 @@
{
"name" : "wzj4",
"appid" : "__UNI__6DB512D",
"description" : "",
"appid" : "__UNI__1F0975C",
"description" : "admin",
"versionName" : "4.0.0",
"versionCode" : 4000049,
"transformPx" : false,

View File

@ -103,67 +103,67 @@
"navigationBarBackgroundColor" : "#181b27",
"enablePullDownRefresh" : false
}
}
// {
// "path" : "pages/me/vlogerInfo",
// "style" : {
// "app-plus" : {
// "titleNView" : false //
// }
// }
// }
// {
// "path" : "pages/me/me",
// "style" : {
// "app-plus" : {
// "titleNView" : false //
// }
// }
// }
// {
// "path" : "pages/me/myBackImg",
// "style" : {
// "app-plus" : {
// "titleNView" : false //
// }
// }
// },
// {
// "path" : "pages/me/myFace",
// "style" : {
// "app-plus" : {
// "titleNView" : false //
// }
// }
// },
// {
// "path" : "pages/me/myInfo",
// "style" : {
// "navigationBarTitleText" : "修改个人资料",
// "navigationBarBackgroundColor" : "#181b27"
// }
// },
// {
// "path" : "pages/me/modifyNickname",
// "style" : {
// "navigationBarTitleText" : "修改昵称",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27",
// "app-plus" : {
// "titleNView" : {
// "buttons" : [
// {
// "text" : "保存",
// "color" : "#ef274d",
// "width" : "60px",
// "fontSize" : "15px",
// "fontWeight" : "bold"
// }
// ]
// }
// }
// }
// },
},
{
"path" : "pages/me/vlogerInfo",
"style" : {
"app-plus" : {
"titleNView" : false //
}
}
},
{
"path" : "pages/me/me",
"style" : {
"app-plus" : {
"titleNView" : false //
}
}
},
{
"path" : "pages/me/myBackImg",
"style" : {
"app-plus" : {
"titleNView" : false //
}
}
},
{
"path" : "pages/me/myFace",
"style" : {
"app-plus" : {
"titleNView" : false //
}
}
},
{
"path" : "pages/me/myInfo",
"style" : {
"navigationBarTitleText" : "修改个人资料",
"navigationBarBackgroundColor" : "#181b27"
}
},
{
"path" : "pages/me/modifyNickname",
"style" : {
"navigationBarTitleText" : "修改昵称",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27",
"app-plus" : {
"titleNView" : {
"buttons" : [
{
"text" : "保存",
"color" : "#ef274d",
"width" : "60px",
"fontSize" : "15px",
"fontWeight" : "bold"
}
]
}
}
}
},
// {
// "path" : "pages/me/modifyPass",
// "style" : {
@ -185,127 +185,127 @@
// }
// }
// },
// {
// "path" : "pages/me/modifyTioktokNum",
// "style" : {
// "navigationBarTitleText" : "修改视频号",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27",
// "app-plus" : {
// "titleNView" : {
// "buttons" : [
// {
// "text" : "保存",
// "color" : "#ef274d",
// "width" : "60px",
// "fontSize" : "15px",
// "fontWeight" : "bold"
// }
// ]
// }
// }
// }
// },
// {
// "path" : "pages/me/modifyDesc",
// "style" : {
// "navigationBarTitleText" : "修改简介",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27",
// "app-plus" : {
// "titleNView" : {
// "buttons" : [
// {
// "text" : "保存",
// "color" : "#ef274d",
// "width" : "60px",
// "fontSize" : "15px",
// "fontWeight" : "bold"
// }
// ]
// }
// }
// }
// },
// {
// "path" : "pages/me/modifySex",
// "style" : {
// "navigationBarTitleText" : "修改性别",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27",
// "app-plus" : {
// "titleNView" : {
// "buttons" : [
// {
// "text" : "保存",
// "color" : "#ef274d",
// "width" : "60px",
// "fontSize" : "15px",
// "fontWeight" : "bold"
// }
// ]
// }
// }
// }
// },
// {
// "path" : "pages/me/modifyBirthday",
// "style" : {
// "navigationBarTitleText" : "修改生日",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27",
// "app-plus" : {
// "titleNView" : {
// "buttons" : [
// {
// "text" : "保存",
// "color" : "#ef274d",
// "width" : "60px",
// "fontSize" : "15px",
// "fontWeight" : "bold"
// }
// ]
// }
// }
// }
// },
// {
// "path" : "pages/me/modifyLocation",
// "style" : {
// "navigationBarTitleText" : "修改所在地",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27",
// "app-plus" : {
// "titleNView" : {
// "buttons" : [
// {
// "text" : "保存",
// "color" : "#ef274d",
// "width" : "60px",
// "fontSize" : "15px",
// "fontWeight" : "bold"
// }
// ]
// }
// }
// }
// },
// {
// "path" : "pages/me/chooseProvince",
// "style" : {
// "navigationBarTitleText" : "选择省份",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27"
// }
// },
// {
// "path" : "pages/me/chooseCity",
// "style" : {
// "navigationBarTitleText" : "选择城市",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27"
// }
// },
{
"path" : "pages/me/modifyTioktokNum",
"style" : {
"navigationBarTitleText" : "修改视频号",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27",
"app-plus" : {
"titleNView" : {
"buttons" : [
{
"text" : "保存",
"color" : "#ef274d",
"width" : "60px",
"fontSize" : "15px",
"fontWeight" : "bold"
}
]
}
}
}
},
{
"path" : "pages/me/modifyDesc",
"style" : {
"navigationBarTitleText" : "修改简介",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27",
"app-plus" : {
"titleNView" : {
"buttons" : [
{
"text" : "保存",
"color" : "#ef274d",
"width" : "60px",
"fontSize" : "15px",
"fontWeight" : "bold"
}
]
}
}
}
},
{
"path" : "pages/me/modifySex",
"style" : {
"navigationBarTitleText" : "修改性别",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27",
"app-plus" : {
"titleNView" : {
"buttons" : [
{
"text" : "保存",
"color" : "#ef274d",
"width" : "60px",
"fontSize" : "15px",
"fontWeight" : "bold"
}
]
}
}
}
},
{
"path" : "pages/me/modifyBirthday",
"style" : {
"navigationBarTitleText" : "修改生日",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27",
"app-plus" : {
"titleNView" : {
"buttons" : [
{
"text" : "保存",
"color" : "#ef274d",
"width" : "60px",
"fontSize" : "15px",
"fontWeight" : "bold"
}
]
}
}
}
},
{
"path" : "pages/me/modifyLocation",
"style" : {
"navigationBarTitleText" : "修改所在地",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27",
"app-plus" : {
"titleNView" : {
"buttons" : [
{
"text" : "保存",
"color" : "#ef274d",
"width" : "60px",
"fontSize" : "15px",
"fontWeight" : "bold"
}
]
}
}
}
},
{
"path" : "pages/me/chooseProvince",
"style" : {
"navigationBarTitleText" : "选择省份",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27"
}
},
{
"path" : "pages/me/chooseCity",
"style" : {
"navigationBarTitleText" : "选择城市",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27"
}
},
// {
// "path" : "pages/me/settings",
// "style" : {
@ -314,30 +314,30 @@
// "navigationBarBackgroundColor" : "#181b27"
// }
// },
// {
// "path" : "pages/me/myFans",
// "style" : {
// "navigationBarTitleText" : "粉丝",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27"
// }
// },
// {
// "path" : "pages/me/myFollows",
// "style" : {
// "navigationBarTitleText" : "关注",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27"
// }
// },
// {
// "path" : "pages/me/chooseDistrict",
// "style" : {
// "navigationBarTitleText" : "选择地区",
// "navigationBarTextStyle" : "white",
// "navigationBarBackgroundColor" : "#181b27"
// }
// }
{
"path" : "pages/me/myFans",
"style" : {
"navigationBarTitleText" : "粉丝",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27"
}
},
{
"path" : "pages/me/myFollows",
"style" : {
"navigationBarTitleText" : "关注",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27"
}
},
{
"path" : "pages/me/chooseDistrict",
"style" : {
"navigationBarTitleText" : "选择地区",
"navigationBarTextStyle" : "white",
"navigationBarBackgroundColor" : "#181b27"
}
}
],
"subPackages": [

View File

@ -541,13 +541,15 @@ export default {
// #ifdef APP-PLUS
client = "APP";
// #endif
const storedSte = uni.getStorageSync('ste');
let submit = {
client,
way: this.routerVal.way,
remark: this.remarkVal,
parentOrderSn: "",
ste:storedSte
};
console.log(submit,'===')
//
this.routerVal.parentOrder && this.routerVal.parentOrder.orderSn
? (submit.parentOrderSn = this.routerVal.parentOrder.orderSn)

View File

@ -788,7 +788,7 @@ export default {
id: this.productId,
};
storage.setCartBackbtn(obj);
uni.switchTab({
uni.navigateTo({
url: "/pages/tabbar/cart/cartList",
});
},

View File

@ -1,8 +1,22 @@
<template>
<div class="wrapper">
<!-- 楼层装修组件 -->
<!-- <div v-for="i in 200">{{i}}</div> -->
<tpl ref="tpl" />
<!-- 楼层装修组件 -->
<u-navbar class="navbar" :is-back="false" :is-fixed="false">
<div class="tab-container">
<div
v-for="(item, index) in list1"
:key="index"
:class="{ active: currentTabIndex === index }"
@click="click(item)"
>
{{ item.name }}
</div>
</div>
</u-navbar>
<!-- 商城 -->
<tpl ref="tpl" v-if="currentTabIndex == 1" :ste="1" />
<!-- 本地生活 -->
<tpl ref="tpl" v-if="currentTabIndex == 0" :ste="0" />
</div>
</template>
@ -15,14 +29,26 @@ export default {
background: {
backgroundColor: "#fff",
},
list1: [
{
name: "本地生活",
},
{
name: "商城",
},
],
currentTabIndex: 0,
};
},
components: {
tpl,
},
methods: {
click(item) {
this.currentTabIndex = this.list1.indexOf(item);
},
},
onPullDownRefresh() {
console.log("下拉刷新");
this.$refs.tpl.init();
uni.stopPullDownRefresh();
},
@ -30,7 +56,28 @@ export default {
</script>
<style lang="scss" scoped>
.wrapper{
.tab-container {
width: 100%;
display: flex;
justify-content: space-evenly;
// background-color: #f0f0f0;
// padding: 0 16rpx 0 0;
font-size: 18px;
}
.tab-container div {
cursor: pointer;
padding: 5px 10px;
}
.tab-container div.active {
border-bottom: 2px solid #F50505;
color:#F50505;
background-color: transparent;
}
.wrapper {
// background: red;
}
.navbar{
height: 100%;
}
</style>

View File

@ -233,9 +233,10 @@ export default {
background: #ededed;
}
.layout {
background: #fff;
// background: #fff;
display: flex;
justify-content: space-between;
background: transparent;
}
.addres {
// width: 15%;
@ -245,7 +246,8 @@ export default {
align-items: center;
}
.layout {
background: #fff;
// background: #fff;
background: transparent;
display: flex;
justify-content: space-between;
}

View File

@ -3,7 +3,7 @@
<!-- uni 中不能使用 vue component 所以用if判断每个组件 -->
<div v-for="(item,index) in pageData.list" :key="index">
<!-- 搜索栏如果在楼层装修顶部则会自动浮动否则不浮动 -->
<u-navbar class="navbar" v-if="item.type == 'search'" :is-back="false" :is-fixed="index ===1 ? false : true">
<div class="navbar" v-if="item.type == 'search'" :is-back="false" :is-fixed="false">
<search style="width:100%" :res="item.options" />
<!-- #ifndef H5 -->
<!-- 扫码功能 不兼容h5 详情文档: https://uniapp.dcloud.io/api/system/barcode?id=scancode -->
@ -11,7 +11,7 @@
<u-icon name="scan" @click="scan()" color="#666" size="50"></u-icon>
</div>
<!-- #endif -->
</u-navbar>
</div>
<carousel v-if="item.type == 'carousel'" :res="item.options" />
<titleLayout v-if="item.type == 'title'" :res="item.options" />
<leftOneRightTwo v-if="item.type == 'leftOneRightTwo'" :res="item.options" />
@ -62,7 +62,7 @@ import tpl_goods from "@/pages/tabbar/home/template/tpl_goods"; //商品分类
import Talent from "@/pages/tabbar/home/template/Talent"; //
import tpl_activity from "@/pages/tabbar/home/template/tpl_activity"; //
//
import { getFloorData } from "@/api/home"; //
import { getFloorData ,getFloorgetBendi} from "@/api/home"; //
import permision from "@/js_sdk/wa-permission/permission.js"; //
import config from "@/config/config";
// TODO
@ -101,7 +101,17 @@ export default {
// joinGroup: tpl_join_group,
// integral: tpl_integral,
},
props: {
ste: {
type: Number,
default: 0,
},
},
watch: {
ste(val) {
this.init();
},
},
mounted() {
this.init();
// #ifdef MP-WEIXIN
@ -109,19 +119,32 @@ export default {
uni.showShareMenu({ withShareTicket: true });
// #endif
},
// provide() {
// return {
// ste: this.ste,
// };
// },
methods: {
/**
* 实例化首页数据楼层
*/
init() {
uni.setStorageSync('ste', this.ste); // ste
this.pageData = "";
getFloorData().then((res) => {
if (this.ste == 1) {
getFloorData().then((res) => {
if (res.data.success) {
this.pageData = JSON.parse(res.data.result.pageData);
console.log(this.pageData.list);
}
});
}else{
getFloorgetBendi().then((res) => {
if (res.data.success) {
this.pageData = JSON.parse(res.data.result.pageData);
}
});
}
},
/**
@ -224,7 +247,17 @@ export default {
.wrapper{
height: 100%;
}
.navbar-right {
padding: 0 16rpx 0 0;
.navbar{
display: flex;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
background:white;
padding-right: 10px;
}
.navbar-right {
// padding: 0 16rpx 0 0;
}
</style>

View File

@ -35,11 +35,11 @@
<!-- 搜索添加 -->
<TUIContactsea v-if="statue == 2" />
<!-- 联系人 -->
<TUIContact v-else-if="statue == 1" />
<TUIContact v-else-if="statue == 1" style="height: 100%;" />
<SelectFriend v-else-if="statue == 3" @con="confn" />
<SelectFriendqlioa v-else-if="statue == 4" @concen="concen" />
<!-- 会话 -->
<TUIConversation v-else />
<TUIConversation style="height: 100%;" v-else />
</div>
</template>
@ -85,15 +85,11 @@ export default {
getUserimInfo()
.then(({ data }) => {
if (data.code == 200) {
console.log(data);
const par = data.result;
uni.$SDKAppID = par.sdkAppId; // Your SDKAppID
uni.$userID = par.userID; // Your userID
uni.$userSig = par.userSig;
TUILogin.login({
SDKAppID: uni.$SDKAppID,
userID: uni.$userID,
userSig: uni.$userSig,
SDKAppID: par.sdkAppId,
userID: par.userID,
userSig: par.userSig,
useUploadPlugin: true, // If you need to send rich media messages, please set to true.
framework: `vue${vueVersion}`, // framework used vue2 / vue3
});
@ -164,7 +160,15 @@ export default {
};
</script>
<style>
<style scoped>
uni-page-body,
html,
body,
page {
width: 100% !important;
height: 100% !important;
overflow: hidden;
}
.jolkp {
height: 66px;
display: flex;
@ -281,4 +285,5 @@ export default {
background-repeat: no-repeat;
width: 40%;
}
</style>