<%@ Page Title="" Language="C#" MasterPageFile="~/Dialog/DialogMaster.Master" AutoEventWireup="true"
    CodeBehind="ClueClassEdit.aspx.cs" Inherits="OAWeb.crm.clues.ClueClassEdit" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="form" style="width: 600px; padding: 10px;">
        <table cellpadding="0" cellspacing="0" border="0" class="table_form">
            <tr>
                <td class="right">
                    分类名称：
                </td>
                <td>
                    <asp:TextBox ID="txtFullName" runat="server" CssClass="text width180"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td class="right">
                    排序：</td>
                <td>
                    <asp:TextBox ID="txtSortCode" runat="server" CssClass="text width50"></asp:TextBox></td>
            </tr>
            <tr>
                <td>
                </td>
                <td>
                    <input id="btnSave" type="button" value=" 保 存 " class="btn_77px" />
                    <input id="btnClose" type="button" value=" 返 回 " onclick="art.dialog.close();return false;"
                        class="btn_77px" />
                </td>
            </tr>
        </table>
    </div>
    <script type="text/javascript">
        $(document).ready(function () {
            rulesValue = { '<%=txtFullName.UniqueID %>': { required: true} };
            messagesValue = { '<%=txtFullName.UniqueID %>': { required: "请输入分类名称"} }
            var form = jQuery.validator.ValidateForm($("#aspnetForm"), rulesValue, messagesValue);
            $("#btnSave").click(function () {
                if (form.form()) {
                    $("#aspnetForm").ajaxSubmit({
                        url: "/crm/clues/ClueClassEdit.aspx?op=Save&Id=<%=Id %>",
                        success: function (result) {
                            if (result == "ok") {
                                alert("保存成功");
                                CloseReload();
                            } else {
                                alert(result);
                            }
                        }
                    });
                }
                return false;
            })
        });
    </script>
</asp:Content>
