<%@ page language="C#" autoeventwireup="true" inherits="admin_model_Import, DianCMS" enableviewstatemac="false" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Import Namespace="D.Common" %>
<!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 id="CssName" rel="stylesheet" type="text/css" runat="server" />

    <script src="../../js/Common.js" type="text/javascript"></script>

    <script src="../../js/lhgdialog/lhgcore.lhgdialog.min.js?self=true&skin=<%=Function.GetCssNameColor()%>" type="text/javascript"></script>

    <script type="text/javascript">
        function SelType() {
            var TypeCount = document.getElementsByName("Type");
            var s;
            if (navigator.appName == "Microsoft Internet Explorer") {
                s = TypeCount[1].checked;
            }
            else {
                s = TypeCount[0].checked;
            }
            if (s) {
                DianCMS_$("InfoModel").style.display = "none";
            }
            else {
                DianCMS_$("InfoModel").style.display = "";
            }

        }
        function PinYin() {
            var chs = DianCMS_$("txtModelName").value;
            D.BLL.B_CHS2PinYin.GetPinYin(chs, CallBack);
        }

        function CallBack(res) {
            DianCMS_$("txtModelEnName").value = res.value;
        }
    </script>

</head>
<body>
    <form id="form1" runat="server">
    <table class="dh" cellpadding="0" cellspacing="0" border="0" align="center">
        <tr>
            <td>
                <asp:Image ID="P_Go" runat="server" ImageAlign="AbsMiddle" />
                您现在的位置：<a href="../info.aspx">后台管理</a> >> <a href="InfoModelList.aspx">模型列表</a>
                >> 导入内容模型
            </td>
        </tr>
    </table>
    <table class="border" cellspacing="1" cellpadding="0" border="0" align="center">
        <tr>
            <td class="bqleft">
                选择导入模板：
            </td>
            <td class="bqright">
                <asp:TextBox ID="txtTemplate" runat="server" Columns="50" CssClass="in1" style="float:left"></asp:TextBox>
                <input id="Button1" type="button" value="选择模板" class="btn" onclick="WinOpenLhgDialog('选择模板','../template/SelectTemplate.aspx?ControlId=txtTemplate',650,450,'')" style="float:left" /><font
                    color="#ff0066">*</font>
            </td>
        </tr>
        <tr>
            <td class="bqleft">
                导入方式：
            </td>
            <td class="bqright">
                <asp:RadioButtonList ID="Type" runat="server" RepeatDirection="Horizontal" onclick="SelType()">
                    <asp:ListItem Value="0" Selected="True">模板默认</asp:ListItem>
                    <asp:ListItem Value="1">自定义</asp:ListItem>
                </asp:RadioButtonList>
            </td>
        </tr>
        <tbody id="InfoModel" style="display: none">
            <tr>
                <td class="bqleft">
                    模型名称：
                </td>
                <td class="bqright">
                    <asp:TextBox ID="txtModelName" MaxLength="50" Columns="30" runat="server" CssClass="in1" style="float:left"></asp:TextBox><input
                        id="btnPinYin" type="button" value="自动设置英文名（拼音）" onclick="PinYin()" class="btn" style="float:left"
                        runat="server" /><font color="#ff0066">*</font>
                </td>
            </tr>
            <tr>
                <td class="bqleft">
                    英文名称（拼音）：
                </td>
                <td class="bqright">
                    <asp:TextBox ID="txtModelEnName" Columns="50" runat="server" CssClass="in1"></asp:TextBox><font
                        color="#ff0066">*</font>
                </td>
            </tr>
            <tr>
                <td class="bqleft">
                    表名：
                </td>
                <td class="bqright">
                    <asp:TextBox ID="txtTabelName_1" runat="server" Columns="8" CssClass="in1" Enabled="False">D_U_</asp:TextBox><asp:TextBox
                        ID="txtTableName" runat="server" MaxLength="20" Columns="15" CssClass="in1"></asp:TextBox><font
                            color="#ff0066">*</font>
                </td>
            </tr>
        </tbody>
        <tr>
            <td class="bqleft">
                导入分类：
            </td>
            <td class="bqright">
                <asp:CheckBoxList ID="CheckClass" runat="server" RepeatDirection="Horizontal">
                    <asp:ListItem Value="1">导入栏目分类</asp:ListItem>
                    <asp:ListItem Value="2">导入数据字典</asp:ListItem>
                </asp:CheckBoxList>
            </td>
        </tr>
        <tr>
            <td class="bqleft">
            </td>
            <td class="bqright" height="50">
                <asp:Button ID="Button2" runat="server" Text=" 提交 " CssClass="btn radius30 pad_0_30" OnClick="Button2_Click" />
            </td>
        </tr>
    </table>
    </form>
</body>
</html>
