diff --git a/src/main/webapp/template/1/default/news-detail.htm b/src/main/webapp/template/1/default/news-detail.htm new file mode 100644 index 00000000..51e8c4aa --- /dev/null +++ b/src/main/webapp/template/1/default/news-detail.htm @@ -0,0 +1,608 @@ + + + + + + + + + {ms:global.name/} + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + <#include "header.htm"/> + + +
+
+ +当前位置: + + +首页 + +{ms:channel type="path"} + + +${field.typetitle} + +{/ms:channel} +
+
+
+ +${field.title} + +
+ +发布时间: + + +${field.date?string("yyyy-MM-dd")} + +
+
+ +浏览次数: + + +${field.hit} + +
+
+ +${field.content} + +
+
+
+ +上一篇: + + +${pre.title} + +
+
+ <#include "footer.htm"/> +
+ + + + + + \ No newline at end of file diff --git a/src/main/webapp/template/1/default/news-list.htm b/src/main/webapp/template/1/default/news-list.htm new file mode 100644 index 00000000..890c2e23 --- /dev/null +++ b/src/main/webapp/template/1/default/news-list.htm @@ -0,0 +1,857 @@ + + + + + + + + + {ms:global.name/} + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + <#include "header.htm"/> + +
+
+ +当前位置: + + +首页 + +{ms:channel type="path"} + + +${field.typetitle} + +{/ms:channel} +
+
+ +{ms:arclist size=15 ispaging=true} +
+ + +${field.title} + + +${field.date?string("yyyy-MM-dd")} + +
+{/ms:arclist} +<#assign pagerCount=3 /> +<#assign pageCount=page.total /> +<#assign currentPage=page.cur /> +<#assign halfPagerCount=(pagerCount-1)/2/> +<#assign showPrevMore=false /> +<#assign showNextMore=false /> +<#assign arr=[] /> +<#--判断是否有翻页--> +<#if pageCount gt pagerCount> +<#if currentPage gt pagerCount - halfPagerCount> +<#assign showPrevMore=true /> + +<#if currentPage lt pageCount - halfPagerCount> +<#assign showNextMore=true /> + + +<#--计算页码--> +<#if showPrevMore&&!showNextMore> +<#assign startPage=pageCount - (pagerCount - 2) /> +<#list startPage..pageCount-1 as x> +<#assign arr=arr+[x] /> + +<#elseif !showPrevMore && showNextMore> +<#list 2..pagerCount as x> +<#assign arr=arr+[x] /> + +<#elseif showPrevMore && showNextMore> +<#assign offset=(pagerCount / 2)?floor - 1 /> +<#list currentPage - offset..currentPage + offset as x> +<#assign arr=arr+[x] /> + +<#else> +<#list 2..pageCount as x> +<#if x lt pageCount> +<#assign arr=arr+[x] /> + + + +
+ + + +<#--第一页--> +<#if pageCount gt 0> + +<#if 1==currentPage> +1 +<#else> +1 + + + +<#--翻页的省略号--> +<#if showPrevMore> + +... + + +<#--中间的页码--> +<#list arr as x> + +<#if x==currentPage> +${x} +<#else> +${x} + + + +<#-- 最后一页--> +<#if pageCount gt 1> + +<#if pageCount==currentPage> +${pageCount} +<#else> +${pageCount} + + + + + + +<#--span> +前往 + +页 + +
+
+ +
+ +
+ + +回到顶部 + +
+
+ + <#include "footer.htm"/> +
+ + + + + + \ No newline at end of file