<%@ Page Language="C#" AutoEventWireup="true" Inherits="System_InfoModel_ModelList, QianboCMS" EnableEventValidation="false" %>
<!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 href="../Css/layout.css" type="text/css" rel="stylesheet" />
    <script type="text/javascript" src="../../Js/jquery.js"></script>
    <script type="text/javascript" src="../../Js/lhgdialog/lhgdialog.min.js?self=true"></script>
    <script type="text/javascript" src="../../Js/Common.js"></script>
</head>

<body>
    <table cellspacing="1" cellpadding="0" class="wzdh" align="center">
        <tr>
            <td style="padding-left: 10px;">
                <img src="../Images/Skin/Default/you.gif" align="absmiddle" />
                您现在的位置：<a href="../SystemInfo.aspx">后台管理</a> &gt;&gt; 模型管理
			</td>
        </tr>
    </table>
    <table cellpadding="0" cellspacing="1" class="border" align="center">
        <tr>
            <td class="wzlist"><a href="SetInfoModel.aspx">添加模型</a> | <a href="ModelOut.aspx">导出内容模型</a> | <a href="ModelIn.aspx">导入内容模型</a></td>
        </tr>
    </table>
    <form id="ModelListForm" runat="server">
        <table align="center" class="border" cellspacing="1" cellpadding="0">
            <asp:Repeater ID="RepModel" runat="server" OnItemCommand="repModel_Delete">
                <HeaderTemplate>
                    <tr class="title">
                        <td width="60px">模型编号</td>
                        <td width="180px">模块名称</td>
                        <td width="180px">表名</td>
                        <td width="60px">类型</td>
                        <td width="90px">模型类型</td>
                        <td>描述</td>
                        <td width="240px">操作</td>
                    </tr>
                </HeaderTemplate>
                <ItemTemplate>
                    <script type="text/javascript">
                        var jq = jQuery.noConflict();
                        jQuery(function () {
                            jQuery('#CopyModel<%#Eval("ModelId") %>').click(function () {
								jQuery.dialog({
									id: 'txtCopyModel',
									lock: true,
									title: '选择模板',
									content: "url:CopyModelTable.aspx?ModelId=<%#Eval("ModelId") %>",
									width: 650,
									height: 110
								});
							});
						});
                    </script>
                    <tr class="tdbg" onmouseover="this.className='tdbgmouseover'" onmouseout="this.className='tdbg'">
                        <td><%#Eval("ModelId") %></td>
                        <td><%#Eval("ModelName") %></td>
                        <td><%#Eval("TableName") %></td>
                        <td><%#FormatIsSystem(Eval("IsSystem"))%></td>
                        <td><%#ModelSortStr(Eval("ModelSort", "{0}"))%></td>
                        <td align="left" style="padding-left: 5px;"><%#Eval("ModelDesc") %></td>
                        <td nowrap>
							<%# GetModelPreView(Eval("ModelId", "{0}"), Eval("ModelSort", "{0}"))%> | <a href='SetInfoModel.aspx?ModelId=<%#Eval("ModelId") %>'>修改</a>
                            <span runat="server" visible='<%#FormatHidden(Eval("IsSystem")) %>' nowrap> | <a id="CopyModel<%#Eval("ModelId") %>" class="mouseStyle">复制</a> | <a href='FieldList.aspx?ModelId=<%#Eval("ModelId")%>'>字段列表</a> | <asp:LinkButton ID="lnkDelete" runat="server" Text="删除" CommandName="delete" CommandArgument='<%#Eval("ModelId") %>' OnClientClick="return confirm('是否确定删除该自定义模型？')"></asp:LinkButton></a></span>
						</td>
                    </tr>
                </ItemTemplate>
            </asp:Repeater>
        </table>
    </form>
    <br />
</body>
</html>