<%@ Page Language="c#" AutoEventWireup="True" CodeBehind="PostStudent.aspx.cs" Inherits="SWTraining.Affairs.PostStudent"
    Title="教务管理-编辑学员基本信息" %>

<%@ Import Namespace="SWTraining" %>
<%@ Register Src="../UserCol/Dictionary.ascx" TagName="Dictionary" TagPrefix="uc1" %>
<!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">
    <link id="linkStyle" runat="server" href="../Themes/Orange/css.css" rel="stylesheet"
        type="text/css" />
    <style type="text/css">
        #PhotoScale
        {
            filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod=scale);
        }
    </style>
</head>

<script type="text/javascript">
    function ShowImage() {
        var img = document.getElementById("imgPhoto");
        var file = document.getElementById("fileImage");
        var cimgurl = document.getElementById("imgUrl");
        var scale = document.getElementById("imgScale");
        if (file.value != "") {
            scale.style.display = "none";
            img.style.display = "inline";
            img.height = 16;
            img.src = file.value;
            img.height = "150";
            cimgurl.value = file.value;
        }
    }

    function DeleteImage() {
        if (editmode && photo) {
            lbnDelete.style.visibility = "visible";
        }
    }
</script>

<body>
    <iframe id="PickPanel" width="0" height="0"></iframe>
    <form id="Form1" runat="server">
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <div id="sw_content">
        <div class="divpanel">
            <table class="table" cellspacing="0">
                <tr>
                    <th colspan="3">
                        学员报名
                    </th>
                </tr>
                <tr>
                    <td width="13%">
                        学号：
                    </td>
                    <td colspan="2" width="823">
                        <asp:TextBox ID="tbxStudentID" runat="server" Enabled="False"></asp:TextBox>
                        <span style="color: Red">*</span>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        姓名：
                    </td>
                    <td width="823" colspan="2">
                        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                            <ContentTemplate>
                                <asp:TextBox ID="tbxStudentName" runat="server" OnTextChanged="tbxStudentName_TextChanged"
                                    AutoPostBack="True"></asp:TextBox>
                                <span style="color: Red">*</span>
                                <asp:RequiredFieldValidator ID="_tbxStudentName" runat="server" ControlToValidate="tbxStudentName"
                                    ErrorMessage="姓名不能为空！"></asp:RequiredFieldValidator>
                            </ContentTemplate>
                        </asp:UpdatePanel>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        拼音缩写：
                    </td>
                    <td style="height: 11px" width="67%">
                        <asp:UpdatePanel ID="UpdatePanel2" runat="server">
                            <ContentTemplate>
                                <asp:TextBox ID="tbxPYSimple" runat="server"></asp:TextBox>
                            </ContentTemplate>
                        </asp:UpdatePanel>
                    </td>
                    <td rowspan="9" style="text-align: center">
                        <asp:Image ID="imgPhoto" runat="server" ImageUrl='<%#accTheme("pic.gif") %>' onclick="DeleteImage()">
                        </asp:Image><div id="imgScale">
                        </div>
                        <div style="width: 100%; text-align: center">
                            <asp:LinkButton ID="lbnDelete" runat="server" OnClick="lbnDelete_Click" Style="visibility: hidden"
                                CausesValidation="false">清除</asp:LinkButton></div>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        别名：
                    </td>
                    <td style="height: 11px" width="67%">
                        <asp:TextBox ID="tbxByname" runat="server"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        称呼：
                    </td>
                    <td style="height: 11px" width="67%">
                        <asp:TextBox ID="tbxAppellation" runat="server"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        性别：
                    </td>
                    <td style="height: 11px" width="67%">
                        <asp:RadioButtonList ID="rblSex" runat="server" RepeatDirection="Horizontal">
                            <asp:ListItem Value="0" Text="女"></asp:ListItem>
                            <asp:ListItem Value="1" Text="男"></asp:ListItem>
                        </asp:RadioButtonList>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        类型：
                    </td>
                    <td width="67%">
                        <asp:RadioButtonList ID="rblStudentType" runat="server" RepeatDirection="Horizontal"
                            AutoPostBack="True" OnSelectedIndexChanged="rblStudentType_SelectedIndexChanged">
                            <asp:ListItem Value="0" Text="学生"></asp:ListItem>
                            <asp:ListItem Value="1" Text="上班族"></asp:ListItem>
                        </asp:RadioButtonList>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        出生：
                    </td>
                    <td style="height: 15px" width="67%">
                        <asp:TextBox ID="tbxBirthday" runat="server"></asp:TextBox>

                        <script type="text/javascript">                            Calendar("tbxBirthday");</script>

                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        校区：
                    </td>
                    <td width="67%">
                        <asp:DropDownList ID="ddlSchool" runat="server" DataTextField="SchoolName" DataValueField="SchoolID">
                        </asp:DropDownList>
                        <span style="color: Red">*</span>
                        <asp:CompareValidator ID="_ddlSchool" runat="server" ControlToValidate="ddlSchool"
                            ErrorMessage="请选择校区！" Operator="NotEqual" ValueToCompare="0"></asp:CompareValidator>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        选择相片：
                    </td>
                    <td width="67%">
                        <div style="float: left">
                            <input id="fileImage" type="file" accept="Image/*" runat="server" onblur="ShowImage()" /></div>
                        <div style="float: left; margin-left: 5px" class="tool_camera" onclick="Avicap();">
                        </div>
                        <div style="clear: both; height: 0px; line-height: 0px; font-size: 0px">
                        </div>
                        <asp:HiddenField ID="imgByteString" runat="server" />
                        <asp:HiddenField ID="imgUrl" runat="server" />
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        密码：
                    </td>
                    <td>
                        <asp:TextBox ID="tbxPassword" runat="server" Width="141px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        拥有积分：
                    </td>
                    <td colspan="2">
                        <asp:TextBox ID="tbxPoints" runat="server" Width="58px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        报名时间：
                    </td>
                    <td colspan="2">
                        <asp:TextBox ID="tbxDateAndTime" runat="server" Width="141px"></asp:TextBox>
                        <span style="color: Red">*</span>
                        <asp:RequiredFieldValidator ID="_tbxDateAndTime" runat="server" ErrorMessage="报名日期不能为空！"
                            ControlToValidate="tbxDateAndTime"></asp:RequiredFieldValidator>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        电话：
                    </td>
                    <td width="823" colspan="2">
                        <asp:TextBox ID="tbxTel" runat="server" Width="141px"></asp:TextBox>
                        <span style="color: Red">*</span>
                    </td>
                </tr>
                <tr>
                    <td width="13%" style="height: 27px">
                        手机：
                    </td>
                    <td width="823" colspan="2" style="height: 27px">
                        <asp:TextBox ID="tbxMobileTel" runat="server" Width="141px"></asp:TextBox>
                        <span style="color: Red">*</span> (接收短信默认号码)
                    </td>
                </tr>
                <tr>
                    <td width="13%" style="height: 26px">
                        QQ：
                    </td>
                    <td width="823" colspan="2" style="height: 26px">
                        <asp:TextBox ID="tbxQQ" runat="server" Width="141px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%" style="height: 26px">
                        电子邮箱：
                    </td>
                    <td width="823" colspan="2" style="height: 26px">
                        <asp:TextBox ID="tbxEmail" runat="server" Width="141px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        地址：
                    </td>
                    <td colspan="2" width="823">
                        <asp:TextBox ID="tbxHomeAddress" runat="server" Width="285px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        邮编：
                    </td>
                    <td colspan="2" width="823">
                        <asp:TextBox ID="tbxPostCode" runat="server"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        原学校：
                    </td>
                    <td colspan="2" width="823">
                        <asp:TextBox ID="tbxSchool" runat="server" Width="185px"></asp:TextBox>
                        年级：<asp:TextBox ID="tbxGrade" runat="server" Width="84px"></asp:TextBox>
                        班级：<asp:TextBox ID="tbxClass" runat="server" Width="79px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        工作单位：
                    </td>
                    <td colspan="2" width="823">
                        <asp:TextBox ID="tbxCompany" runat="server" Width="269px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        工作职务：
                    </td>
                    <td colspan="2" width="823">
                        <asp:TextBox ID="tbxHeadship" runat="server" Width="122px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        学历：
                    </td>
                    <td colspan="2" width="823">
                        <asp:TextBox ID="tbxDiploma" runat="server"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        身份证：
                    </td>
                    <td colspan="2" width="823">
                        <asp:TextBox ID="tbxIDcard" runat="server" Width="269px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        ＩＤ卡号：
                    </td>
                    <td colspan="2" width="823">
                        <asp:TextBox ID="tbxSignInID" runat="server" Width="177px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        VIP到期时间：
                    </td>
                    <td width="823" colspan="2">
                        <asp:TextBox ID="tbxVIPLastDate" runat="server" Width="121px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        接收考勤短信：
                    </td>
                    <td width="823" colspan="2">
                        <asp:CheckBox ID="cbxSignInSMS" runat="server" Checked="True" />
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        父亲信息：
                    </td>
                    <td width="823" colspan="2">
                        姓名：<asp:TextBox ID="tbxFatherName" runat="server" Width="93px"></asp:TextBox>
                        手机：<asp:TextBox ID="tbxFatherMobileTel" runat="server" Width="107px"></asp:TextBox>
                        单位：<asp:TextBox ID="tbxFatherUnit" runat="server" Width="140px"></asp:TextBox>
                        职务：<asp:TextBox ID="tbxFatherHeadship" runat="server" Width="140px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        母亲信息：
                    </td>
                    <td width="823" colspan="2">
                        姓名：<asp:TextBox ID="tbxMotherName" runat="server" Width="93px"></asp:TextBox>
                        手机：<asp:TextBox ID="tbxMotherMobileTel" runat="server" Width="107px"></asp:TextBox>
                        单位：<asp:TextBox ID="tbxMotherUnit" runat="server" Width="140px"></asp:TextBox>
                        职务：<asp:TextBox ID="tbxMotherHeadship" runat="server" Width="140px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        学习顾问：
                    </td>
                    <td width="823" colspan="2">
                        <asp:DropDownList ID="ddlConsultant" runat="server" DataTextField="TrueName" DataValueField="UserID">
                        </asp:DropDownList>
                        <span style="color: Red">*</span>
                        <asp:CompareValidator ID="_ddlConsultant" runat="server" ControlToValidate="ddlConsultant"
                            ErrorMessage="请选择学习顾问！" Operator="NotEqual" ValueToCompare="0"></asp:CompareValidator>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        获知广告方式：
                    </td>
                    <td width="823" colspan="2">
                        <asp:DropDownList ID="ddlMedia" runat="server" DataTextField="MediaName" DataValueField="MediaID">
                        </asp:DropDownList>
                        <span style="color: Red">*</span>
                        <asp:CompareValidator ID="_ddlMedia" runat="server" ControlToValidate="ddlMedia"
                            ErrorMessage="请选择获知广告方式！" Operator="NotEqual" ValueToCompare="0"></asp:CompareValidator>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                        备注：
                    </td>
                    <td width="823" colspan="2">
                        <asp:TextBox ID="tbxRemark" runat="server" Width="459px" TextMode="MultiLine" Height="114px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td width="13%" style="height: 8px">
                        指纹状态：
                    </td>
                    <td width="823" colspan="2" style="height: 8px">
                        <asp:DropDownList ID="ddlFingerState" runat="server">
                            <asp:ListItem Value="0">禁用</asp:ListItem>
                            <asp:ListItem Selected="True" Value="1">可用</asp:ListItem>
                        </asp:DropDownList>
                    </td>
                </tr>
                <tr>
                    <td width="13%" style="height: 8px">
                        指纹模板：
                    </td>
                    <td width="823" colspan="2" style="height: 8px">
                        <asp:TextBox ID="tbxFingerCode" runat="server" Height="63px" TextMode="MultiLine"
                            Width="321px"></asp:TextBox>
                        <asp:ImageButton ID="ibnFinger" Visible="false" runat="server" ImageUrl='<%# accTheme("tools/finger.gif") %>' />
                    </td>
                </tr>
                <tr>
                    <td width="13%" style="height: 8px">
                        录入员：
                    </td>
                    <td width="823" colspan="2" style="height: 8px">
                        <asp:DropDownList ID="ddlUser" runat="server" DataTextField="TrueName" DataValueField="UserID">
                        </asp:DropDownList>
                        <span style="color: Red">*</span>
                        <asp:CompareValidator ID="_ddlUser" runat="server" ControlToValidate="ddlUser" ErrorMessage="录入员不能为空！"
                            Operator="NotEqual" ValueToCompare="0"></asp:CompareValidator>
                    </td>
                </tr>
                <tr>
                    <td width="13%">
                    </td>
                    <td width="823" colspan="2">
                        <asp:Button ID="btnPost" runat="server" Text="提交" OnClick="btnPost_Click"></asp:Button>
                        <input causesvalidation="false" type="button" runat="server" onclick="back()" value="返回" />
                    </td>
                </tr>
            </table>
        </div>
    </div>
    <!------usercol ajax-------->
    <asp:UpdatePanel ID="up" runat="server">
        <ContentTemplate>
            <uc1:Dictionary ID="Dictionary1" runat="server" />
        </ContentTemplate>
    </asp:UpdatePanel>
    <!-------usercol ajax------->
    </form>
</body>
</html>
