优化加入一些工鞥呢

This commit is contained in:
wuxw 2022-11-15 14:15:20 +08:00
parent d82a6cd54f
commit f4bdb30cca
5 changed files with 98 additions and 25 deletions

View File

@ -43,5 +43,6 @@ export default{
appPayKey:appPayKey,
commonBaseUrl: commonBaseUrl,
QQMapKey: QQMapKey,
imgUrl:commonBaseUrl,
systemName:systemName
}

View File

@ -1,5 +1,6 @@
import Vue from 'vue'
import App from './App'
import conf from './conf/config.js';
import Java110Context from './lib/java110/Java110Context.js'
import context from './lib/java110/context.js'
import url from './constant/url.js'
@ -25,6 +26,7 @@ Vue.prototype.url = url;
Vue.prototype.factory = factory;
Vue.prototype.util = util;
Vue.prototype.date = date;
Vue.prototype.imgUrl = conf.imgUrl;
App.mpType = 'app'

View File

@ -542,6 +542,15 @@
}
}
,{
"path" : "pages/inspection/inspectionTodayReport",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
],
"globalStyle": {
"navigationBarTextStyle": "white",

View File

@ -1,8 +1,8 @@
<template>
<view class="content">
<view class="margin-bottom-xs">
<uni-notice-bar :showIcon="true" :scrollable="true" :single="true" :speed="30"
:text="welcomeTitle"></uni-notice-bar>
<uni-notice-bar :showIcon="true" :scrollable="true" :single="true" :speed="30" :text="welcomeTitle">
</uni-notice-bar>
</view>
<scroll-view class="scroll-restaurants-list" scroll-y="true" style="height:100%">
<swiper class="categoryList padding-top-xs bg-white" indicator-dots="true"
@ -35,13 +35,13 @@
<view class="cu-bar bg-white solid-bottom margin-top">
<view class="action">
<view class="bock-icon "></view>
<text class="margin-left-xs">小区文化</text>
<text class="margin-left-xs">小区活动</text>
</view>
<view class="action" @tap="_moreActivity()">
<text class="lg text-gray cuIcon-more"></text>
</view>
</view>
<view class="noticesList">
<view class="noticesList" v-if="activitys && activitys.length>0">
<block v-for="(item,index) in activitys" :key="index" wx:key="index">
<view class="noticesList-list" @tap="_toDetail(item)">
@ -61,6 +61,10 @@
</view>
</block>
</view>
<view class="active_empty" v-else>
<image :src="noImg" />
<text class="text">暂无活动哦~</text>
</view>
</scroll-view>
</view>
</template>
@ -83,9 +87,13 @@
import mapping from '../../constant/mapping.js'
import {isNull} from '../../lib/java110/utils/StringUtil.js'
import {
isNull
} from '../../lib/java110/utils/StringUtil.js'
import {getUserInfo} from '../../lib/java110/api/Java110SessionApi.js'
import {
getUserInfo
} from '../../lib/java110/api/Java110SessionApi.js'
import url from '../../constant/url.js';
import conf from '@/conf/config.js'
export default {
@ -95,9 +103,16 @@
currentCommunityId: '',
currentCommunityName: '',
categoryList: [],
swiperList: [],
swiperList: [{
url: this.imgUrl + '/h5/images/serve/banner1.jpg'
},
{
url: this.imgUrl + '/h5/images/serve/banner2.jpg'
}
],
noImg:this.imgUrl+'/h5/images/serve/empty.png',
activitys: [],
welcomeTitle:''
welcomeTitle: ''
}
},
components: {
@ -106,7 +121,7 @@
onLoad() {
this.welcomeTitle = conf.systemName + '欢迎您'
uni.setNavigationBarTitle({
title:conf.systemName
title: conf.systemName
})
this.java110Context.onLoad();
},
@ -144,7 +159,9 @@
.then(function(res) {
if (res.statusCode == 200) {
let _advertPhotos = res.data;
if (_advertPhotos && _advertPhotos.length > 0) {
_that.swiperList = _advertPhotos;
}
_that._loadActivitys();
return;
}
@ -234,20 +251,20 @@
_that._loadAd();
},
_advertJump: function(ad){
_advertJump: function(ad) {
console.log(ad);
if(ad.advertType == 3 || !ad.pageUrl){
if (ad.advertType == 3 || !ad.pageUrl) {
return;
}
if(ad.advertType == 2){
if (ad.advertType == 2) {
//
let url = encodeURIComponent(ad.pageUrl)
uni.navigateTo({
url:'/pages/hcWebView/hcWebView?url='+url
url: '/pages/hcWebView/hcWebView?url=' + url
})
return;
}
if(ad.advertType == 1){
if (ad.advertType == 1) {
//
uni.navigateTo({
url: ad.pageUrl
@ -259,9 +276,10 @@
}
</script>
<style>
<style lang="scss">
@import "./index.css";
.swiper-height-index {
height: 240upx;
min-height: 240upx;
@ -348,4 +366,25 @@
.tec-height {
height: 120upx;
}
.active_empty {
background: #fff;
display: flex;
align-items: center;
justify-content: center;
flex-direction: column;
padding: 100rpx 0;
border-radius: 10px;
image {
width: 50%;
height: 200upx;
}
.text {
font-size: 28rpx;
color: #333;
margin-top: 20rpx;
}
}
</style>

View File

@ -0,0 +1,22 @@
<template>
<view>
</view>
</template>
<script>
export default {
data() {
return {
}
},
methods: {
}
}
</script>
<style>
</style>