Commit b6e8dcfc87be8f76628635f59eb788b512b55f41
1 parent
a062e7cf
update...
Showing
3 changed files
with
18 additions
and
2 deletions
src/main/java/com/bsth/data/directive/DirectivesPstThread.java
| @@ -7,6 +7,8 @@ import com.bsth.entity.directive.Directive; | @@ -7,6 +7,8 @@ import com.bsth.entity.directive.Directive; | ||
| 7 | import com.bsth.entity.realcontrol.ScheduleRealInfo; | 7 | import com.bsth.entity.realcontrol.ScheduleRealInfo; |
| 8 | import com.bsth.repository.directive.D60Repository; | 8 | import com.bsth.repository.directive.D60Repository; |
| 9 | import com.bsth.repository.directive.D64Repository; | 9 | import com.bsth.repository.directive.D64Repository; |
| 10 | +import org.joda.time.format.DateTimeFormat; | ||
| 11 | +import org.joda.time.format.DateTimeFormatter; | ||
| 10 | import org.slf4j.Logger; | 12 | import org.slf4j.Logger; |
| 11 | import org.slf4j.LoggerFactory; | 13 | import org.slf4j.LoggerFactory; |
| 12 | import org.springframework.beans.factory.annotation.Autowired; | 14 | import org.springframework.beans.factory.annotation.Autowired; |
| @@ -32,6 +34,8 @@ public class DirectivesPstThread extends Thread { | @@ -32,6 +34,8 @@ public class DirectivesPstThread extends Thread { | ||
| 32 | @Autowired | 34 | @Autowired |
| 33 | DayOfSchedule dayOfSchedule; | 35 | DayOfSchedule dayOfSchedule; |
| 34 | 36 | ||
| 37 | + private static DateTimeFormatter fmtyyyyMMdd = DateTimeFormat.forPattern("yyyy-MM-dd"); | ||
| 38 | + | ||
| 35 | @Override | 39 | @Override |
| 36 | public void run() { | 40 | public void run() { |
| 37 | 41 | ||
| @@ -52,6 +56,8 @@ public class DirectivesPstThread extends Thread { | @@ -52,6 +56,8 @@ public class DirectivesPstThread extends Thread { | ||
| 52 | continue; | 56 | continue; |
| 53 | } | 57 | } |
| 54 | } | 58 | } |
| 59 | + //日期 | ||
| 60 | + d60.setRq(fmtyyyyMMdd.print(d60.getTimestamp())); | ||
| 55 | d60Repository.save(d60); | 61 | d60Repository.save(d60); |
| 56 | } | 62 | } |
| 57 | 63 |
src/main/java/com/bsth/entity/directive/Directive.java
| @@ -28,6 +28,8 @@ public class Directive { | @@ -28,6 +28,8 @@ public class Directive { | ||
| 28 | * 时间戳 | 28 | * 时间戳 |
| 29 | */ | 29 | */ |
| 30 | protected Long timestamp; | 30 | protected Long timestamp; |
| 31 | + | ||
| 32 | + private String rq; | ||
| 31 | 33 | ||
| 32 | /** | 34 | /** |
| 33 | * 时间 HH:mm | 35 | * 时间 HH:mm |
| @@ -113,4 +115,12 @@ public class Directive { | @@ -113,4 +115,12 @@ public class Directive { | ||
| 113 | public void setSender(String sender) { | 115 | public void setSender(String sender) { |
| 114 | this.sender = sender; | 116 | this.sender = sender; |
| 115 | } | 117 | } |
| 118 | + | ||
| 119 | + public String getRq() { | ||
| 120 | + return rq; | ||
| 121 | + } | ||
| 122 | + | ||
| 123 | + public void setRq(String rq) { | ||
| 124 | + this.rq = rq; | ||
| 125 | + } | ||
| 116 | } | 126 | } |
src/main/resources/static/pages/summary/temp_sch_detail/list.html