Browse Source

首页侧边栏增加日期,阅读状态样式判断

hejq 8 years ago
parent
commit
fe10cbea26
1 changed files with 4 additions and 6 deletions
  1. 4 6
      src/main/webapp/resources/tpl/index/home/left.html

+ 4 - 6
src/main/webapp/resources/tpl/index/home/left.html

@@ -164,15 +164,13 @@
 <div class="feed-wrap">
 	<div class="pane notice" ng-controller="NoticeCtrl">
 		<div class="pane-header">
-			<img src="static/img/home/gonggao.png"> 公告<span class="pull-right f12">{{dateTime | date:
-				'MM-dd'}} {{["星期日", "星期一", "星期二", "星期三", "星期四", "星期五",
-				"星期六"][dateTime.getDay()]}}</span>
+			<img src="static/img/home/gonggao.png"> 公告<span class="pull-right f12">{{dateTime | date: 'MM-dd'}}
+                {{["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六"][dateTime.getDay()]}}</span><!--ng-class="{'day-read': !isCurrentTime(dateTime, notice.date)}"-->
 		</div>
 		<div class="pane-body">
 			<ul class="list-unstyled detail details">
-				<li ng-repeat="notice in notices">
-                    {{isCurrentTime(dateTime, notice.date)}}
-                    <!--<a ng-click="setReadStatus(notice.id)" href="public#/notice/{{notice.id}}" class="" ng-bind="::notice.title" target="_blank"></a>-->
+				<li ng-repeat="notice in notices" ng-class="isCurrentTime(dateTime, notice.date) && notice.readStatus == 1 ? day-read : nonday">
+                    <a ng-click="setReadStatus(notice.id)" href="public#/notice/{{notice.id}}" class="" ng-bind="::notice.title" target="_blank"></a><img src="static/img/home/new.png" ng-show="isCurrentTime(dateTime, notice.date)">
                 </li>
 			</ul>
 		</div>