<%@ page language="C#" autoeventwireup="true" stylesheettheme="Themes" theme="Themes" inherits="Course_ApprovalCourse, App_Web_vzflj4p3" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="cc1" %>
<!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 id="Head1" runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <title></title>
     <script type="text/javascript" src="../Js/jquery.js"></script>
 <%--   <link rel="stylesheet" href="../css/form-field-tooltip.css" media="screen" type="text/css">

    <script type="text/javascript" src="../js/rounded-corners.js"></script>

    <script type="text/javascript" src="../js/form-field-tooltip.js"></script>--%>
    
     <script src="../js/artDialog3/artDialog.min.js"></script>
      <script>          (function($) { var d = $.dialog.defaults; d.skin = ['chrome']; })(art);</script>

    <style type="text/css">
        #divNum
        {
            position: absolute;
            width: 70%;
            height: 30%;
            z-index: 2;
            left: 20%;
            top: 10%;
        }
        #LayerAll
        {
            position: absolute;
            filter: alpha(opacity = 50);
            width: 100%;
            height: 100%;
            background-color: #CCCCCC;
            border: 0px;
            left: 1px;
            top: 1px;
            z-index: 1;
            display: none;
        }
        #right
        {
            position: absolute;
            width: 80%;
            height: 30%;
            z-index: 2;
            left: 10%;
            top: 16%;
        }
        .t1
        {
            border-bottom: #99cc66 1px solid;
            position: relative;
            line-height: 23px;
            padding-left: 5px;
            margin-bottom: 10px;
            height: 23px;
            color: #5b9400;
            font-size: 14px;
            font-weight: bold;
        }
        .t2
        {
            border-bottom: #99cc66 1px solid;
            position: relative;
            line-height: 23px;
            padding-left: 5px;
            margin-bottom: 10px;
            height: 23px;
            color: #5b9400;
            font-size: 14px;
            font-weight: bold;
        }
        .t1 .m
        {
            position: absolute;
            padding-right: 15px;
            background: url(http://img.baidu.com/hi/img/index/arrow.gif) no-repeat right -5px;
            font-size: 14px;
            top: 2px;
            right: 0px;
        }
        .t1 .m2
        {
            position: absolute;
            padding-right: 15px;
            background: url(http://img.baidu.com/hi/img/index/arrow.gif) no-repeat right -5px;
            font-size: 14px;
            top: 2px;
            right: 0px;
        }
        .t1 .m2
        {
            line-height: 18px;
            font-size: 12px;
            font-weight: normal;
        }
        .t2
        {
            padding-bottom: 0px;
            line-height: 18px;
            border-right-width: 0px;
            padding-left: 0px;
            padding-right: 0px;
            margin-bottom: 2px;
            border-top-width: 0px;
            border-bottom-width: 0px;
            color: #5b9400;
            border-left-width: 0px;
            padding-top: 0px;
        }
        .t3
        {
            z-index: 6553;
            position: relative;
            line-height: 30px;
            padding-left: 55px;
            background: url(http://img.baidu.com/hi/img/index/iconhi.gif) no-repeat;
            height: 35px;
            font-size: 14px;
            font-weight: bold;
        }
        .rcb
        {
            height: 5px;
            clear: both;
        }
        .rct .l
        {
            background-image: url(../images/rc.gif);
            position: relative;
            width: 5px;
            height: 5px;
            font-size: 1px;
            overflow: hidden;
        }
        .rct .r
        {
            background-image: url(../images/rc.gif);
            position: relative;
            width: 5px;
            height: 5px;
            font-size: 1px;
            overflow: hidden;
        }
        .rcb .l
        {
            background-image: url(../images/rc.gif);
            position: relative;
            width: 5px;
            height: 5px;
            font-size: 1px;
            overflow: hidden;
        }
        .rcb .r
        {
            background-image: url(../images/rc.gif);
            position: relative;
            width: 5px;
            height: 5px;
            font-size: 1px;
            overflow: hidden;
        }
        .rct .l
        {
            float: left;
            left: -1px;
        }
        .rcb .l
        {
            float: left;
            left: -1px;
        }
        .rct .r
        {
            float: right;
            right: -1px;
        }
        .rcb .r
        {
            float: right;
            right: -1px;
        }
        .rct .l
        {
            top: -1px;
        }
        .rct .r
        {
            top: -1px;
        }
        .rcb .l
        {
            top: 1px;
        }
        .rcb .r
        {
            top: 1px;
        }
        .b2
        {
            border-bottom: #ccc 1px solid;
            border-left: #ccc 1px solid;
            margin-bottom: 10px;
            background: #fff;
            border-top: #ccc 1px solid;
            border-right: #ccc 1px solid;
        }
        .b2 .cnt
        {
            padding-bottom: 10px;
            padding-left: 10px;
            padding-right: 10px;
            padding-top: 10px;
        }
        .tl1
        {
            background-position: left top;
        }
        .tr1
        {
            background-position: right top;
        }
        .bl1
        {
            background-position: left bottom;
        }
        .br1
        {
            background-position: right bottom;
        }
        .lginfo
        {
            line-height: 22px;
            clear: both;
        }
        .fan
        {
            margin-top: 10px;
        }
        .fan TD
        {
            padding-bottom: 2px;
            padding-left: 8px;
            padding-right: 8px;
            color: #666;
            padding-top: 2px;
        }
        .f14
        {
            line-height: 24px;
            font-size: 14px;
        }
    </style>

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

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

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



    <script type="text/javascript">
    //artDialog js的完美弹出层
    function showEdit(strId) {
        var sURL = "lkCourseInfo.aspx?id=" + strId;
        // art.dialog({ id: 'myDialogNote', title: '申请原因', iframe: sURL, width: '550', height: '300', lock: true });
        art.dialog.open(sURL, { id: 'myDialogNote', title: '申请原因', width: '550px', height: '300px', lock: true, closeFn: function() {
            document.getElementById("btnArtRefresh").click();
        } 
        });
        return false;
    };
  
    </script>

</head>

<script language="javascript">
    function CheckAll() {
        var cked = false;
        cked = document.getElementById("chkSelAll").checked;
        for (var i = 0; i < document.getElementsByTagName("*").length; i++) {
            var e = document.getElementsByTagName("*")[i];
            try {
                if (e.name.substring(e.name.length - 6, e.name.length) == "chkSel") {
                    e.checked = cked;
                }
            }
            catch (exception) {
            }
        }
    }
</script>

<body>
<div id="loading">
        <div style="position: absolute; top: 0px; left: 0px; width: 100%; height: 100%; background-color: #ffffff;
            z-index: 10; filter: alpha(opacity=90); opacity: 0.9;">
        </div>
        <div id="msg_area" style="z-index: 200; left: 289px; position: absolute; top: 202px;">
            <div id="msgPanel" style="z-index: 200;" height="24px" width="100px" bordercolor="#eeeeee"
                borderstyle="Solid" borderwidth="1px">
                <asp:Image ID="img" runat="server" ImageUrl="~/images/loading.gif" />
                <font style="font-size: 9pt;color:Gray;">loading...读取中......</font>
            </div>
        </div>
    </div>
    <form id="form1" runat="server">
    <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
    </asp:ToolkitScriptManager>
    &nbsp;<asp:AutoCompleteExtender ID="AutoCompleteExtender1" runat="server" TargetControlID="txtName"
        CompletionSetCount="12" CompletionInterval="1" EnableCaching="true" MinimumPrefixLength="1"
        ServicePath="../services/AutoComplete.asmx" ServiceMethod="GetCourseNameList">
    </asp:AutoCompleteExtender>
    <div id="divNum" algin="center" style="display: none" runat="server">
        <div id="Div1" class="b2">
            <div class="rct">
                <div class="l tl1">
                </div>
                <div class="r tr1">
                </div>
            </div>
            <div class="cnt f14">
                <div style="color: #666" align="center">
                    <table border="0" cellpadding="5" cellspacing="0" width="100%" style="background-color: #deeffa;">
                        <%--#e7ddf9--%>
                        <tr class="td_3">
                            <td height="25" align="right" class="style1">
                                <p align="center">
                                    请填写原因</p>
                            </td>
                        </tr>
                        <tr class="td_3">
                            <td height="25" align="center" class="style1">
                                <asp:TextBox ID="txtCause" runat="server" Height="92px" TextMode="MultiLine" Width="240px"
                                    MaxLength="100"></asp:TextBox>
                            </td>
                        </tr>
                        <tr class="td_3">
                            <td height="25" align="center" class="style1">
                                <asp:Button ID="btnEnter" runat="server" Text="确定" OnClick="btnEnter_Click" />
                                &nbsp;&nbsp;
                                <asp:Button ID="btnCancel" runat="server" Text="取消" OnClick="btnCancel_Click" />
                            </td>
                        </tr>
                    </table>
                </div>
            </div>
            <div class="rcb">
                <div class="l bl1">
                </div>
                <div class="r br1">
                </div>
            </div>
        </div>
        <!--CMSLOADOK--->
    </div>
    <div id="LayerAll" runat="server">
    </div>
    <table cellpadding="0" cellspacing="0" class="table_box">
        <tr>
            <td class="right_bg">
                <span class="right_title">
                    <img src="../Images/homen.gif" class="img_style" />
                    您的当前位置：学习管理 > 学习需求管理 &gt; 审批课程申请</span>
            </td>
        </tr>
        <tr>
            <td class="r_top_box">
                <table cellspacing="0" cellpadding="5" class="r_top_title_box">
                    <tr>
                        <td align="left" width="150px">
                            审批状态：
                            <asp:DropDownList ID="ddlState" runat="server" AutoPostBack="True" OnSelectedIndexChanged="ddlState_SelectedIndexChanged">
                                <asp:ListItem Value="-1">全部</asp:ListItem>
                                <asp:ListItem Value="1">通过</asp:ListItem>
                                <asp:ListItem Value="0">未审核</asp:ListItem>
                                <asp:ListItem Value="2">未通过</asp:ListItem>
                            </asp:DropDownList>
                        </td>
                        <td align="left">
                            课程名称：<asp:TextBox ID="txtName" runat="server" MaxLength="20"></asp:TextBox>
                            <asp:Button ID="btnSearch" runat="server" Text="查 询" OnClick="btnSearch_Click" />
                        &nbsp;&nbsp;&nbsp;
                            <asp:Button ID="btnArtRefresh" runat="server" Text="查 询" 
                                OnClick="btnArtRefresh_Click" />
                        </td>
                        <td align="right">
                            <asp:Button ID="btnBatch" runat="server" Text="批量通过" OnClick="btnBatch_Click" />
                            &nbsp;<asp:Button ID="btnBatchNo" runat="server" Text="批量拒绝" onclick="btnBatchNo_Click" 
                                 />
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        <tr>
            <td class="grid_box">
                <table cellpadding="0" cellspacing="0" width="100%">
                    <tr>
                        <td>
                            <asp:GridView ID="gvApplyCourse" runat="server" AllowPaging="True" AutoGenerateColumns="False"
                                DataKeyNames="ID" OnRowCommand="gvApplyCourse_RowCommand" OnRowDataBound="gvApplyCourse_RowDataBound">
                                <PagerSettings Visible="False" />
                                <Columns>
                                    <asp:TemplateField>
                                        <HeaderTemplate>
                                            全选<input id="chkSelAll" name="chkSelAll" onclick="javascript:CheckAll();" type="checkbox">
                                        </HeaderTemplate>
                                        <HeaderStyle Width="50px" />
                                        <ItemTemplate>
                                            <asp:CheckBox ID="chkSel" runat="server" />
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                    <asp:TemplateField HeaderText="申请人">
                                        <ItemTemplate>
                                            <asp:Label ID="lblUser" runat="server" Text='<%# Bind("ApplierID") %>'></asp:Label>
                
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                    <asp:BoundField DataField="Name" HeaderText="申请的课程" />
                                    <asp:BoundField DataField="ApplyCourseAetiology" HeaderText="申请课程原因" />
                                    <asp:BoundField DataField="ApplyTime" DataFormatString="{0:d}" HeaderText="申请时间" />
                                    <asp:BoundField DataField="AuditID" HeaderText="是否审核通过" />
                                    <asp:TemplateField HeaderText="操作">
                                        <ItemTemplate>
                                            <%--                     <a href="javascript:window.showModalDialog('lkCourseInfo.aspx?id=<%#Eval("ID")%>','','dialogHeight:260px; dialogWidth:650px; scroll:no; status:no; help:no; resizable:yes; center:yes');">查看</a>--%>
                                            <a onclick="javascript:showEdit(<%#Eval("ID")%>);" class="linkBtn">审核</a>
                                            <asp:LinkButton ID="lbtnYes" CommandName="yes" runat="server" Visible="false">通过</asp:LinkButton>
                                            <asp:LinkButton ID="lbtnNo" CommandName="no" runat="server" Visible="false">不通过</asp:LinkButton>
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                </Columns>
                            </asp:GridView>
                        </td>
                    </tr>
                    <tr>
                        <td class="page_bg_left">
                            <cc1:AspNetPager ID="myAspNetPager" runat="server" AlwaysShow="True" CssClass="cut_pager"
                                PageSize="10" FirstPageText="首页&nbsp;&nbsp;" HorizontalAlign="Right" InputBoxStyle="width:20px;"
                                LastPageText="尾页" NextPageText="&nbsp;&nbsp;下一页&nbsp;&nbsp;" NumericButtonTextFormatString="  {0}"
                                OnPageChanging="AspNetPager1_PageChanging" PrevPageText="上一页" ShowCustomInfoSection="Left"
                                CustomInfoTextAlign="Left" ShowInputBox="Always">
                            </cc1:AspNetPager>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
    </table>
    </form>

    <script type="text/javascript">
//	
//　　         var tooltipObj = new DHTMLgoodies_formTooltip();
//         tooltipObj.setTooltipWidth('135');
//         tooltipObj.setTooltipPosition('right');
//         tooltipObj.setPageBgColor('#EEE');
//         tooltipObj.setTooltipBgColor('#FFF');
//         tooltipObj.setArrowVisibility(false);
//         tooltipObj.setCloseMessage('');
//         tooltipObj.initFormFieldTooltip();

    </script>
<script type="text/javascript">
     $("#loading").fadeOut()
</script>
</body>
</html>
