<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="YC_Template_List.aspx.cs"
    Inherits="YCHR.Web.admin.template.YC_Template_List" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
<link rel="stylesheet" type="text/css" href="../images/style.css" />
<script type="text/javascript" src="../js/jquery.js"></script>
<script type="text/javascript">
        this.imagePreview = function () {
            xOffset = 10;
            yOffset = 30;
            $("a.preview").hover(function (e) {
                this.t = this.title;
                this.title = "";
                var c = (this.t != "") ? "<br/>" + this.t : "";
                $("body").append("<p id='preview'><img src='" + this.href + "' alt='Image preview' />" + c + "</p>");
                $("#preview")
			.css("top", (e.pageY - xOffset) + "px")
			.css("left", (e.pageX + yOffset) + "px")
			.fadeIn("fast");
            },
	function () {
	    this.title = this.t;
	    $("#preview").remove();
	});
            $("a.preview").mousemove(function (e) {
                $("#preview")
			.css("top", (e.pageY - 500) + "px")
			.css("left", (e.pageX + 500) + "px");
            });
        };
        // starting the script on page load
        $(document).ready(function () {
            imagePreview();
        });
    </script>
</head>
<body style="padding: 10px;">
<form id="form1" runat="server">
  <div class="navigation"> <span class="add"></span><b>您当前的位置：首页 &gt; 系统模板管理 </b> </div>
  <div class="spClear"> </div>
  <table width="100%" cellspacing="1" cellpadding="2" border="0" align="center" class="border">
    <tbody>
      <tr class="tdbg">
        <td width="8%" height="30"><strong>管理选项：</strong></td>
        <td width="92%" class="dh"><a href="YC_Template_List.aspx">管理首页</a>| <a href="javascript:location.reload()">刷新页面</a></td>
      </tr>
    </tbody>
  </table>
  <div class="spClear"> </div>
  <table width="100%" border="0" cellspacing="0" cellpadding="0" class="msgtable">
    <tr>
      <th width="10%" align="center"> 选择 </th>
      <th width="25%" align="center"> 模板名称 </th>
      <th width="10%" align="center"> 作者 </th>
      <th width="19%" align="center"> 创建日期 </th>
      <th width="16%" align="center"> 适用程序版本号 </th>
      <th width="10%" align="center"> 是否入库 </th>
      <th width="10%" align="center"> 状态 </th>
    </tr>
    <asp:Repeater ID="rpttemplate" runat="server" 
            onitemcommand="rpttemplate_ItemCommand">
      <ItemTemplate>
        <tr>
          <td align="center"><asp:CheckBox ID="cb_id" CssClass="checkall" runat="server" />
            &nbsp;
            <asp:HiddenField ID="txtskinname" runat="server" Value='<%#Eval("skinname") %>' /></td>
          <td align="center"><%#Eval("skinname")%> <a class="preview" href="<%#Eval("img")%>" title=""> <img class="preview" alt="查看预览图" src="../images/eye.gif"> </a> &nbsp;&nbsp;&nbsp;&nbsp;</td>
          <td align="center"><%#Eval("author")%></td>
          <td align="center"><%#Eval("createdate")%></td>
          <td align="center"><%#Eval("foraspxjobver")%></td>
          <td align="center"><%#getisrk(Eval("skinname"))%></td>
          <td align="center"><asp:ImageButton ID="ibtnsy" CommandName="ibtnsy" runat="server" ImageUrl='<%# Eval("skinname").ToString().ToLower() == config.templatetheme  ? "../Images/state2.gif" : "../Images/state1.gif"%>' ToolTip='<%#Eval("skinname").ToString().ToLower() == config.templatetheme  ? "正在使用中" : "未启用"%>' /></td>
        </tr>
      </ItemTemplate>
    </asp:Repeater>
  </table>
  &nbsp;&nbsp;<br />
  <asp:Button ID="btnsc" runat="server" CssClass="submit" onclick="btnsc_Click" 
        Text="生成模板" />
  &nbsp;
  <asp:Button ID="btnrk" runat="server" CssClass="submit" onclick="btnrk_Click" 
        Text="模板入库" />
  &nbsp;
</form>
</body>
</html>
