62,046
社区成员
发帖
与我相关
我的任务
分享
<script language="javascript" type="text/javascript">
var brandsBW = new Array();
var brandsCol = new Array();
</script>
<script type="text/javascript">
//<![CDATA[
brandsCol[0] = "system/images/dulux_color_brandslider_tcm60-2832.jpg";
brandsBW[0] = "system/images/dulux_grey_brandslider_tcm60-2833.jpg";
brandsCol[1] = "system/images/Glidden_95x40px-colour_tcm60-5007.jpg";
brandsBW[1] = "system/images/Glidden_95x40px-b&w_tcm60-5008.jpg";
brandsCol[2] = "system/images/levis_color_brandslider_tcm60-2840.jpg";
brandsBW[2] = "system/images/levis_grey_brandslider_tcm60-2841.jpg";
brandsCol[3] = "system/images/dissolvine_color_brandslider_tcm60-4212.jpg";
brandsBW[3] = "system/images/dissolvine_grey_brandslider_tcm60-4213.jpg";
brandsCol[4] = "system/images/eka_brandslider_color_tcm60-17949.jpg";
brandsBW[4] = "system/images/eka_brandslider_greyscale_tcm60-17950.jpg";
brandsCol[5] = "system/images/interpon_bs_color_tcm60-18555.jpg";
brandsBW[5] = "system/images/interpon_bs_grey_tcm60-18556.jpg";
brandsCol[6] = "system/images/international_color_brandslider_tcm60-6189.jpg";
brandsBW[6] = "system/images/international_grey_brandslider_tcm60-6190.jpg";
brandsCol[7] = "system/images/the_freshaire_choice_color_brandslider_tcm60-5009.jpg";
brandsBW[7] = "system/images/the_freshaire_choice_grey_brandslider_tcm60-5010.jpg";
brandsCol[8] = "system/images/raph_lauren_color_brandslider_tcm60-4573.jpg";
brandsBW[8] = "system/images/ralph_lauren_greyscale_brandslider_tcm60-4574.jpg";
brandsCol[9] = "system/images/Butanox_brandslider_color_tcm60-26194.jpg";
brandsBW[9] = "system/images/Butanox_brandslider_grey_tcm60-26195.jpg";
//]]>
</script>
<%@ Import Namespace="System.IO" %>
<table style="width: 98%; background-color: #e7e3e7;" cellspacing="1" cellpadding="4"
align="center" id="ajaxtable">
<tbody>
<tr align="center" class="head">
<td style="width: 5%;">
操作
</td>
<td width="50%">
文件名
</td>
<td style="width: 30%;">
生成日期
</td>
</tr>
<% foreach (FileInfo f in files) { %>
<tr align="center" class="dinfo" style="background-color: #D8D8D8;">
<td>
<a href="javascript:delF('<%=f.Name %>','delfile',<%=ModelID %>)">删除</a>
</td>
<td>
<a href="/<%=FilePath + "/" + ModelID + "/" + f.Name %>" target="_blank">
<%=f.Name %>
</a>
</td>
<td>
<%=f.LastWriteTime.ToString("yyyy-MM-dd HH:mm") %>
</td>
</tr>
<%} %>
</tbody>
</table>
protected List<FileInfo> files = new List<FileInfo>();
protected string FilePath = ConfigurationManager.AppSettings["FileDir"];
protected void Page_Load(object sender, EventArgs e) {
if (!Request.IsAuthenticated)
return;
string strTemplatePath = Server.MapPath(string.Format("/{0}", FilePath));
DirectoryInfo dir = new DirectoryInfo(strTemplatePath);
if (dir.Exists) {
files.AddRange(dir.GetFiles("*.xlsx").OrderByDescending(t => t.LastWriteTime));
}