lsw 10 月之前
父节点
当前提交
495367f593
共有 5 个文件被更改,包括 27 次插入24 次删除
  1. 1 1
      app/App.vue
  2. 8 1
      app/pages/news/index.vue
  3. 8 1
      app/pages/notice/index.vue
  4. 1 1
      app/pages/other/setting.vue
  5. 9 20
      app/pages/serve/index.vue

+ 1 - 1
app/App.vue

@@ -30,7 +30,7 @@ button::after {
 /**挂载iconfont字体图标*/
 @font-face {
 	font-family: 'iconfont';
-	src: url('https://at.alicdn.com/t/c/font_4507607_4zezmbmoj2k.ttf?t=1718677535976') format('truetype');
+	src: url('https://at.alicdn.com/t/c/font_4507607_epz0a0riqye.ttf?t=1718962643320') format('truetype');
 	/* src: url('~@/static/font/iconfont.ttf') format('truetype'); */
 }
 .icon {

+ 8 - 1
app/pages/news/index.vue

@@ -5,7 +5,10 @@
 		</view>
 		<view class="list">
 			<view class="item" v-for="(item, index) in list" :key="index" @click="go('/pages/news/detail?id=' + item.id)">
-				<view class="title omit">{{ item.title }}</view>
+				<view class="title omit">
+					<text class="icon" v-if="item.top === 1">&#xe61f;</text>
+					<text>{{ item.title }}</text>
+				</view>
 				<view class="desc">
 					<text>{{ item.type }}</text>
 					<text>发布于 {{ item.createTime }}</text>
@@ -105,6 +108,10 @@ export default {
 		.title {
 			font-size: 15px;
 			font-weight: bold;
+			.icon {
+				color: orangered;
+				padding-right: 3px;
+			}
 		}
 		.desc {
 			font-size: 14px;

+ 8 - 1
app/pages/notice/index.vue

@@ -1,7 +1,10 @@
 <template>
 	<view class="list">
 		<view class="item" v-for="(item, index) in list" :key="index" @click="go('/pages/notice/detail?id=' + item.id)">
-			<view class="title omit">{{ item.title }}</view>
+			<view class="title omit">
+				<text class="icon" v-if="item.top === 1">&#xe61f;</text>
+				<text>{{ item.title }}</text>
+			</view>
 			<view class="desc">
 				<text>发布于 {{ item.createTime }}</text>
 			</view>
@@ -77,6 +80,10 @@ export default {
 		.title {
 			font-size: 15px;
 			font-weight: bold;
+			.icon {
+				color: orangered;
+				padding-right: 3px;
+			}
 		}
 		.desc {
 			font-size: 14px;

+ 1 - 1
app/pages/other/setting.vue

@@ -1,7 +1,7 @@
 <template>
 	<view class="main pt0">
 		<button class="btn" @click="exit()">退出登陆</button>
-		<button class="btn" @click="pay()">支付测试</button>
+		<!-- <button class="btn" @click="pay()">支付测试</button> -->
 	</view>
 </template>
 

+ 9 - 20
app/pages/serve/index.vue

@@ -4,6 +4,10 @@
 		<view class="banner">
 			<u-swiper circular :radius="5" :indicator="true" keyName="pic" :list="bannerList" :height="160" class="uni-swiper" @click="click"></u-swiper>
 		</view>
+		<!--通知公告-->
+		<view class="notice">
+			<u-notice-bar color="#545555" :text="noticeList" :step="true" direction="column" mode="link" bgColor="white" speed="300" url="/pages/notice/index"></u-notice-bar>
+		</view>
 		<!--菜单-->
 		<view class="menu">
 			<view class="cd">
@@ -87,24 +91,6 @@
 				</view>
 			</view>
 		</view>
-		<!--通知公告-->
-		<!--新闻-->
-		<view class="news">
-			<view class="gg">
-				<view class="title">通知公告</view>
-				<view class="bor"></view>
-				<view class="more" @click="go('/pages/notice/index')">
-					<text>更多</text>
-					<text class="icon">&#xe62b;</text>
-				</view>
-			</view>
-			<view class="bhe">
-				<view class="item" v-for="(item, index) in noticeList" :key="index" @click="go('/pages/notice/detail?id=' + item.id)">
-					<view class="title omit">{{ item.title }}</view>
-					<view class="date">{{ item.createTime.substring(5, 10) }}</view>
-				</view>
-			</view>
-		</view>
 		<!--新闻-->
 		<view class="news">
 			<view class="gg">
@@ -185,7 +171,9 @@ export default {
 			this.http.request({
 				url: '/app/home/notice/小程序通知',
 				success: (res) => {
-					this.noticeList = res.data.data;
+					res.data.data.forEach((item) => {
+						this.noticeList.push(item.title);
+					});
 				}
 			});
 			//资讯
@@ -208,8 +196,9 @@ export default {
 	margin-top: -10px;
 }
 .notice {
-	border-radius: 5px;
 	margin-top: 10px;
+	border-radius: 5px;overflow: hidden;
+	box-shadow: $box-shadow;
 }
 .news {
 	margin-top: 10px;