This commit is contained in:
Vinjor 2025-04-08 11:07:05 +08:00
parent bcb8a68013
commit 93f7410a12
5 changed files with 54 additions and 9 deletions

View File

@ -1,6 +1,6 @@
// 应用全局配置 // 应用全局配置
module.exports = { module.exports = {
baseUrl: 'http://192.168.1.4:8080', baseUrl: 'http://192.168.1.17:8080',
// baseUrl: 'http://localhost:8080', // baseUrl: 'http://localhost:8080',
// 应用信息 // 应用信息
appInfo: { appInfo: {

View File

@ -25,6 +25,13 @@
import subscribe from '@/pages/components/subscribe.vue' import subscribe from '@/pages/components/subscribe.vue'
import mineIndex from '@/pages/mine/mine-index.vue' import mineIndex from '@/pages/mine/mine-index.vue'
import myNotice from '@/pages/components/my-notice.vue' import myNotice from '@/pages/components/my-notice.vue'
import {
getSiteConfig
} from '@/api/system/config.js'
import constant from '@/utils/constant'
import {
setStrData
} from '@/utils/auth.js'
export default { export default {
components: { components: {
tabBarVue, tabBarVue,
@ -52,6 +59,7 @@
}, },
onLoad: function() { onLoad: function() {
this.nowUserType = getUserType() this.nowUserType = getUserType()
this.selectSiteConfig("platform_tel")
}, },
methods: { methods: {
updateParams(newVal) { updateParams(newVal) {
@ -88,6 +96,29 @@
this.queryParams.pageNo = 1 this.queryParams.pageNo = 1
this.total = 0 this.total = 0
}, },
/**
* 查询平台配置
*/
selectSiteConfig(code) {
getSiteConfig({
code: code
}).then(res => {
let jsonArray = JSON.parse(res.data)
jsonArray.map((item) => {
if (constant.customer_service == item.name) {
setStrData(constant.customer_service, item.value)
} else if (constant.wechat_img == item.name) {
setStrData(constant.wechat_img, item.value)
}
})
}).catch((e) => {
uni.showToast({
icon: 'error',
duration: 2000,
title: e
});
})
}
} }
} }
</script> </script>

View File

@ -134,17 +134,17 @@
<image src="@/static/mine/caise/shouce.png" mode="aspectFit"></image> <image src="@/static/mine/caise/shouce.png" mode="aspectFit"></image>
<view>新人手册</view> <view>新人手册</view>
</view> </view>
<view class="menu-item" @click="toggle('center')"> <view class="menu-item" @click="toggle('center',customer_service)">
<!-- <image src="@/static/mine/kefu.png" mode="aspectFit"></image> --> <!-- <image src="@/static/mine/kefu.png" mode="aspectFit"></image> -->
<image src="@/static/mine/caise/kefu.png" mode="aspectFit"></image> <image src="@/static/mine/caise/kefu.png" mode="aspectFit"></image>
<view>联系客服</view> <view>联系客服</view>
</view> </view>
<view class="menu-item" @click="toggle('center')"> <view class="menu-item" @click="toggle('center',wechat_img)">
<!-- <image src="@/static/mine/gognzhonghao.png" mode="aspectFit"></image> --> <!-- <image src="@/static/mine/gognzhonghao.png" mode="aspectFit"></image> -->
<image src="@/static/mine/caise/weixin.png" mode="aspectFit"></image> <image src="@/static/mine/caise/weixin.png" mode="aspectFit"></image>
<view>公众号</view> <view>公众号</view>
</view> </view>
<view class="menu-item" @click="toggle('center')"> <view class="menu-item" @click="toggle('center',customer_service)">
<!-- <image src="@/static/mine/jairushequ.png" mode="aspectFit"></image> --> <!-- <image src="@/static/mine/jairushequ.png" mode="aspectFit"></image> -->
<image src="@/static/mine/caise/shequ.png" mode="aspectFit"></image> <image src="@/static/mine/caise/shequ.png" mode="aspectFit"></image>
<view>加入社区</view> <view>加入社区</view>
@ -160,7 +160,7 @@
<!-- 普通弹窗 --> <!-- 普通弹窗 -->
<uni-popup ref="popup" background-color="#fff"> <uni-popup ref="popup" background-color="#fff">
<view class="popup-content" :class="{ 'popup-height': type === 'left' || type === 'right' }"> <view class="popup-content" :class="{ 'popup-height': type === 'left' || type === 'right' }">
<image src="@/static/mine/erweima.jpg" mode="aspectFit"></image> <image :src="imageUrl+popupImgUrl" mode="aspectFit"></image>
</view> </view>
</uni-popup> </uni-popup>
</view> </view>
@ -176,8 +176,10 @@
formatNumberWithUnits, formatNumberWithUnits,
calculateTimeDifference calculateTimeDifference
} from '@/utils/common.js' } from '@/utils/common.js'
import config from '@/config'
import { import {
getJSONData getJSONData,
getStrData
} from '@/utils/auth.js' } from '@/utils/auth.js'
import { import {
bloggerDetail bloggerDetail
@ -203,7 +205,14 @@
globalConfig: getApp().globalData.config, globalConfig: getApp().globalData.config,
// //
ifHasCard: false, ifHasCard: false,
userInfo: {} userInfo: {},
imageUrl: config.baseUrl,
//
wechat_img: constant.wechat_img,
//
customer_service: constant.customer_service,
//
popupImgUrl: "",
} }
}, },
mounted() {}, mounted() {},
@ -225,8 +234,9 @@
} }
}, },
methods: { methods: {
toggle(type) { toggle(type, key) {
this.type = type this.type = type
this.popupImgUrl = getStrData(key)
// open uni-popup type // open uni-popup type
this.$refs.popup.open(type) this.$refs.popup.open(type)
}, },

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

View File

@ -12,6 +12,10 @@ const constant = {
//博主 //博主
bz: '02', bz: '02',
//通告主 //通告主
tgz: '01' tgz: '01',
//微信公众号二维码
wechat_img: 'wechat_img',
//客服二维码
customer_service: 'customer_service',
} }
export default constant export default constant