This commit is contained in:
@@ -27,8 +27,8 @@ const config = {
|
|||||||
// config.baseUrl = 'http://tc.cqsznc.com:7080/api';
|
// config.baseUrl = 'http://tc.cqsznc.com:7080/api';
|
||||||
|
|
||||||
//正式
|
//正式
|
||||||
// config.baseUrl = 'http://183.230.235.66:11010/api';
|
config.baseUrl = 'http://183.230.235.66:11010/api';
|
||||||
|
|
||||||
|
|
||||||
config.baseUrl = 'http://70b1d4b3.r28.cpolar.top';
|
// config.baseUrl = 'http://70b1d4b3.r28.cpolar.top';
|
||||||
export default config;
|
export default config;
|
||||||
|
@@ -39,9 +39,14 @@
|
|||||||
<!-- 滚动资讯条 -->
|
<!-- 滚动资讯条 -->
|
||||||
<view class="news-bar">
|
<view class="news-bar">
|
||||||
<text class="news-label">头条</text>
|
<text class="news-label">头条</text>
|
||||||
<scroll-view scroll-x class="news-scroll">
|
<view class="news-scroll-container">
|
||||||
<text v-for="(item, idx) in newsList" :key="idx" class="news-item">{{ item }}</text>
|
<scroll-view scroll-y class="news-scroll" :scroll-top="scrollTop" @scroll="onScroll">
|
||||||
</scroll-view>
|
<view class="news-list">
|
||||||
|
<!-- 重复列表以实现无缝循环 -->
|
||||||
|
<text v-for="(item, idx) in [...newsList, ...newsList]" :key="idx" class="news-item">{{ item }}</text>
|
||||||
|
</view>
|
||||||
|
</scroll-view>
|
||||||
|
</view>
|
||||||
<text class="news-arrow">›</text>
|
<text class="news-arrow">›</text>
|
||||||
</view>
|
</view>
|
||||||
<!-- 热门活动区 -->
|
<!-- 热门活动区 -->
|
||||||
@@ -82,72 +87,37 @@
|
|||||||
// }
|
// }
|
||||||
],
|
],
|
||||||
current: 0,
|
current: 0,
|
||||||
gridList: [
|
gridList: [
|
||||||
{
|
{
|
||||||
icon: '/static/aaaa_gd.png',
|
icon: '/static/aaaa_gd.png',
|
||||||
text: '工单',
|
text: '工单',
|
||||||
url:'/pages/sys/workbench/order/order'
|
url:'/pages/sys/workbench/order/order'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
icon: '/static/aaaa_yjcl.png',
|
icon: '/static/aaaa_yjcl.png',
|
||||||
text: '预警处理',
|
text: '预警处理',
|
||||||
url:'/pages/sys/workbench/earlyWarning/earlyWarning'
|
url:'/pages/sys/workbench/earlyWarning/earlyWarning'
|
||||||
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
icon: '/static/aaaa_jk.png',
|
icon: '/static/aaaa_jk.png',
|
||||||
text: '监控',
|
text: '监控',
|
||||||
url:'/pages/sys/workbench/monitor/monitors'
|
url:'/pages/sys/workbench/monitor/monitors'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
icon: '/static/aaaa_bsbx.png',
|
icon: '/static/aaaa_bsbx.png',
|
||||||
text: '报事报修',
|
text: '报事报修',
|
||||||
url:'/pages/sys/user/myRepair/myRepair'
|
url:'/pages/sys/user/myRepair/myRepair'
|
||||||
},
|
},
|
||||||
// {
|
|
||||||
// icon: '/static/aaa_bsbx.png',
|
|
||||||
// text: '报事报修',
|
|
||||||
// url:'/pages/sys/user/myRepair/myRepair'
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// icon: '/static/aaa_tcjf.png',
|
|
||||||
// text: '停车缴费',
|
|
||||||
// url:'/pages/sys/user/myPayment/myPayment'
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// icon: '/static/aaa_shfw.png',
|
|
||||||
// text: '生活服务'
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// icon: '/static/aaa_fwzx.png',
|
|
||||||
// text: '服务中心',
|
|
||||||
// url:'/pages/sys/user/serviceCenter/serviceCenter'
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// icon: '/static/aaa_hyyy.png',
|
|
||||||
// text: '会议预约',
|
|
||||||
// url:'/pages/sys/workbench/meet/meet'
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// icon: '/static/aaa_gdgl.png',
|
|
||||||
// text: '工单管理',
|
|
||||||
// url:'/pages/sys/workbench/order/order'
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// icon: '/static/aaa_fkgl.png',
|
|
||||||
// text: '访客管理',
|
|
||||||
// url:'/pages/sys/user/myVisitor/myVisitor'
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// icon: '/static/aaa_jqqd.png',
|
|
||||||
// text: '敬请期待'
|
|
||||||
// }
|
|
||||||
],
|
],
|
||||||
newsList: [
|
newsList: [
|
||||||
'数智南川|最新资讯1',
|
'数智南川|最新资讯1',
|
||||||
'数智南川|最新资讯2',
|
'数智南川|最新资讯2',
|
||||||
'数智南川|最新资讯3'
|
'数智南川|最新资讯3'
|
||||||
],
|
],
|
||||||
|
scrollTop: 0,
|
||||||
|
scrollInterval: null,
|
||||||
|
scrollHeight: 0,
|
||||||
hotList: [{
|
hotList: [{
|
||||||
img: '/static/aaa_hd1.png',
|
img: '/static/aaa_hd1.png',
|
||||||
title: '世界骑行日 低碳出行 让城市更美好',
|
title: '世界骑行日 低碳出行 让城市更美好',
|
||||||
@@ -194,6 +164,40 @@
|
|||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: url
|
url: url
|
||||||
});
|
});
|
||||||
|
},
|
||||||
|
// 资讯跑马灯控制
|
||||||
|
startScroll() {
|
||||||
|
// 清除之前的定时器
|
||||||
|
if (this.scrollInterval) {
|
||||||
|
clearInterval(this.scrollInterval);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 设置新的定时器
|
||||||
|
this.scrollHeight = this.newsList.length * 60;
|
||||||
|
this.scrollTop = 0;
|
||||||
|
|
||||||
|
this.scrollInterval = setInterval(() => {
|
||||||
|
this.scrollTop++;
|
||||||
|
// 当滚动到一半时重置位置,实现无缝循环
|
||||||
|
if (this.scrollTop >= this.scrollHeight) {
|
||||||
|
this.scrollTop = 0;
|
||||||
|
}
|
||||||
|
}, 50);
|
||||||
|
},
|
||||||
|
onScroll(e) {
|
||||||
|
// 滚动事件处理
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
// 页面加载完成后启动跑马灯
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.startScroll();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
beforeDestroy() {
|
||||||
|
// 页面销毁前清除定时器
|
||||||
|
if (this.scrollInterval) {
|
||||||
|
clearInterval(this.scrollInterval);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -363,6 +367,7 @@
|
|||||||
padding: 10rpx 0;
|
padding: 10rpx 0;
|
||||||
border-top: 1rpx solid #f5f5f5;
|
border-top: 1rpx solid #f5f5f5;
|
||||||
margin-top: 10rpx;
|
margin-top: 10rpx;
|
||||||
|
height: 60rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.news-label {
|
.news-label {
|
||||||
@@ -373,23 +378,37 @@
|
|||||||
border: 1rpx solid #FF6A00;
|
border: 1rpx solid #FF6A00;
|
||||||
border-radius: 4rpx;
|
border-radius: 4rpx;
|
||||||
padding: 2rpx 6rpx;
|
padding: 2rpx 6rpx;
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.news-scroll-container {
|
||||||
|
flex: 1;
|
||||||
|
height: 60rpx;
|
||||||
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.news-scroll {
|
.news-scroll {
|
||||||
flex: 1;
|
height: 60rpx;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.news-list {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
}
|
||||||
|
|
||||||
.news-item {
|
.news-item {
|
||||||
display: inline-block;
|
height: 60rpx;
|
||||||
margin-right: 30rpx;
|
line-height: 60rpx;
|
||||||
color: #666;
|
color: #666;
|
||||||
font-size: 24rpx;
|
font-size: 24rpx;
|
||||||
|
flex-shrink: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.news-arrow {
|
.news-arrow {
|
||||||
color: #999;
|
color: #999;
|
||||||
font-size: 32rpx;
|
font-size: 32rpx;
|
||||||
|
flex-shrink: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.hot-section {
|
.hot-section {
|
||||||
|
@@ -309,21 +309,21 @@
|
|||||||
border-radius: 12rpx;
|
border-radius: 12rpx;
|
||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
margin-bottom: 40rpx;
|
margin-bottom: 40rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.status2 {
|
.status2 {
|
||||||
width: 280rpx;
|
width: 280rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
border: 1px solid #BFBFBF;
|
border: 1px solid #BFBFBF;
|
||||||
margin-top: 30rpx;
|
margin-top: 30rpx;
|
||||||
color: #BFBFBF;
|
color: #BFBFBF;
|
||||||
padding: 12rpx 24rpx;
|
padding: 12rpx 24rpx;
|
||||||
border-radius: 12rpx;
|
border-radius: 12rpx;
|
||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
margin-bottom: 20rpx;
|
margin-bottom: 20rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-outline {
|
.btn-outline {
|
||||||
|
Reference in New Issue
Block a user