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

<%@ Register Src="../UserControls/SatisfactionDegree.ascx" TagName="SatisfactionDegree"
    TagPrefix="uc3" %>
<!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">
    <title></title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<%--   <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 type="text/javascript" src="../js/jquery.js"></script>
    <script type="text/javascript" src="../js/iframe_noscroll.js"></script>
    
        <script type="text/javascript" src="../js/vtip/vtip.js"></script>

    <link rel="stylesheet" type="text/css" href="../js/vtip/css/vtip.css" />
    
    <style type="text/css">
        .style1
        {
            width: 16px;
        }
    </style>
    <script src="../js/artDialog3/artDialog.min.js"></script>
      <script>          (function($) { var d = $.dialog.defaults; d.skin = ['chrome']; })(art);</script>
  <%--  <script type="text/javascript" src="../js/artDialog.js"></script>
  <link id="artDialogSkin" href="../js/skin/default.css" rel="stylesheet" type="text/css" />--%>
    <base target="_self"></base>

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

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

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

    <link type="text/css" rel="Stylesheet" href="../css/validwin.css" />

    <script type="text/javascript">

        //2010-12-28 杨丹 全屏时收起top和left 新加方法，无刷新
        function ScreenControl() {
            var course_intro = document.getElementById("course_intro");
            var imgScreenControl = document.getElementById("fullScreen_toggleBtn");
            var trSatisfactionDegree = document.getElementById("trSatisfactionDegree");
            if (course_intro.style.display == 'none') {

                var left = parent.document.getElementsByTagName("frameset")[1];
                left.cols = "186,7,*";
                var top = parent.document.getElementsByTagName("frameset")[0];
                top.rows = "94,*";
                $("#fullScreen_toggleBtn").val("全屏");
                course_intro.style.display = '';
                trSatisfactionDegree.style.display = '';

                document.getElementById("btnReturn").style.display = '';
                $("#LearnPanel").css("height", '530px');
                //                course_intro.style.display = '';
                //                parent.myFrame.cols = "186,7,*";
                //                parent.rowFrame.rows = "94,*";
                //                //imgScreenControl.src = "../Images/all_scn.gif";
                //                imgScreenControl.value = "全屏";
                //                trSatisfactionDegree.style.display = '';
            }
            else {
                var left = parent.document.getElementsByTagName("frameset")[1];
                left.cols = "0,7,*";
                var top = parent.document.getElementsByTagName("frameset")[0];
                top.rows = "0,*";
                $("#fullScreen_toggleBtn").val("标准");
                trSatisfactionDegree.style.display = 'none';

                course_intro.style.display = 'none';
                document.getElementById("btnReturn").style.display = 'none';

                $("#LearnPanel").css("height", document.body.offsetHeight);
                //                parent.myFrame.cols = "0,7,*";
                //                parent.rowFrame.rows = "0,*";
                //                //imgScreenControl.src = "../Images/exit_scn.gif";
                //                
                //                imgScreenControl.value = "标准";
                //                trSatisfactionDegree.style.display = 'none';
            }

        }



        //        function fullScreeen() {
        //            var course_intro = document.getElementById("course_intro");
        //            course_intro.style.display = 'none';
        //            //course_intro.style.width = '0px';
        //            //2010-12-28 杨丹 全屏时收起top和left
        //            parent.myFrame.cols = "0,7,*";

        //        }
        //        function restoreScreen() {
        //            var course_intro = document.getElementById("course_intro");
        //            course_intro.style.display = '';
        //            //course_intro.style.width = '200px';
        //            parent.myFrame.cols = "186,7,*";
        //        }

        var timerID;
        function LearningTimeStatistics() {

            var pars = $("#hideMessage").attr("value"); //document.getElementById("lblMessage").innerText;
            //alert(pars);
            var IntervalTime = document.getElementById("hideIntervalTime").value; //学习时间记录间隔，300000为5分钟
            timerID = window.setInterval('sendAJAX("LearningTimeStatistics.aspx", ' + '"' + pars + '"' + ', "get", ' + onComplete + ', true, false)', IntervalTime);
            setTimeout('showwin()', 1205000);
        }
        function onComplete(result) {
            //alert(result);
        }

        //        function showQuestionWindow() {
        //            var s = "QuestionAdd.aspx?userid=" + document.form1.txtUserID.value + "&username=" + document.form1.txtUserName.value;
        //            var sURL = encodeURI(s);
        //            var sFeatures = 'dialogHeight:300px; dialogWidth:450px; scroll:no; status:no; help:no; resizable:yes; center:yes';
        //            var result = window.showModalDialog(sURL, "", sFeatures);
        //        }

        //        function showNoteWindow() {
        //            var sURL = "NoteAdd.aspx?userid=" + document.form1.txtUserID.value + "&courseid=" + document.form1.txtCourseID.value;
        //            var sFeatures = 'dialogHeight:260px; dialogWidth:450px; scroll:no; status:no; help:no; resizable:yes; center:yes';
        //            var result = window.showModalDialog(sURL, "", sFeatures);
        //        }
    </script>

    <script type="text/javascript">
     
        function showNote() {
            var sURL = "NoteAdd.aspx?userid=" + document.form1.txtUserID.value + "&courseid=" + document.form1.txtCourseID.value;
            //art.dialog({ id: 'myDialogNote', title: '记录学习笔记', iframe: sURL, width: '450', height: '260', lock: false });
            //art.dialog.open(sURL, { id: 'myDialogQuestion', title: '记录学习笔记', width: '450px', height: '260px', lock: true });
            var sFeatures = 'dialogHeight:300px; dialogWidth:450px; scroll:no; status:no; help:no; resizable:yes; center:yes';
            var result = window.showModalDialog(sURL, "", sFeatures);
            return false;
        };
        function showQuestion() {
            var s = "QuestionAdd.aspx?userid=" + document.form1.txtUserID.value + "&username=" + document.form1.txtUserName.value;
            var sURL = encodeURI(s);
            //art.dialog({ id: 'myDialogQuestion', title: '提问', iframe: sURL, width: '450', height: '260', lock: false });
            //art.dialog.open(sURL, { id: 'myDialogQuestion', title: '提问', width: '450px', height: '260px', lock: true });
            var sFeatures = 'dialogHeight:260px; dialogWidth:450px; scroll:no; status:no; help:no; resizable:yes; center:yes';
            var result = window.showModalDialog(sURL, "", sFeatures);
            return false;
        };

        //Scorm课件的目录窗口
        function showSCORMIndex(vcontent) {
            art.dialog({ id: 'myDialogQuestion', title: '提问', content: vcontent, width: '450', height: '260', lock: false }).close(function() {

            }); ;
        }
        
    </script>

</head>
<body>
    <form id="form1" runat="server">
    <asp:HiddenField ID="hideIntervalTime" Value="300000" runat="server" />
<%--<embed src="http://localhost:808/upload/courseadjunct/K00012920110111163209915.wmv" type="video/x-ms-wmv" width="320" height="270" autoStart="1" showControls="1" showstatusbar="1" />--%>
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <div id="win1" style="z-index: 999999; border: none;" align="center">
        <div id="title">
            <span>学习确认</span></div>
        <div id="con" style="border: solid 1px #cccccc;">
            <table width="99%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                    <td align="right">
                        <img src="../Images/light.gif" />
                    </td>
                    <td align="left">
                        <font color="red">您已经学习了20分钟，<br />
                            请确认继续学习！</font>
                    </td>
                </tr>
                <tr>
                    <td height="20" colspan="2">
                    </td>
                </tr>
                <tr>
                    <td align="center" colspan="2">
                        <div id="close" style="width: 100px;">
                            <input type="button" value="确定" style="width: 99px;" class="BigButton" onclick="LearningTimeStatistics();" /></div>
                    </td>
                </tr>
            </table>
        </div>
    </div>
    <table cellpadding="0" cellspacing="0" class="table_box">
        <tr>
            <td colspan="3">
                <table border="0" cellspacing="0" cellpadding="0" class="right_bg" style="background-repeat: no-repeat;height:24px">
                    <tr>
                        <td>
                            <span class="right_title">
                                <img src="../Images/homen.gif" class="img_style" />
                                您的当前位置：学习课程</span>
                        </td>
                        <td align="right" valign="top" width="50%" height="30px">
                            <table cellpadding="0" cellspacing="0" width="60%">
                                <tr>
                                    <td>
                                        <asp:TextBox ID="txtUserID" runat="server" Style="display: none"></asp:TextBox>
                                    </td>
                                    <td>
                                        <asp:TextBox ID="txtUserName" runat="server" Style="display: none"></asp:TextBox>
                                    </td>
                                    <td>
                                        <asp:TextBox ID="txtCourseID" runat="server" Style="display: none"></asp:TextBox>
                                    </td>
                                    <td>
                                      <input id="fullScreen_toggleBtn" type="button" class="conn_btn" value="全屏" style="border: none;
                                            cursor: pointer" title="全屏" onclick="javascript:ScreenControl();" />
                                    <%--    <img alt="" id="fullScreen_toggleBtn" onclick="javascript:ScreenControl();" style="cursor: hand"
                                            src="../Images/all_scn.gif" />--%></td>
                                    <%--<asp:Button ID="btnNoteAdd" runat="server" Text="添加笔记" OnClick="btnNoteAdd_Click" />--%>
                                    <td>
                                        <input id="btnNote" runat="server"  type="button" class="conn_btn" value="添加笔记" style="border: none;
                                            cursor: pointer" title="添加笔记" onclick="showNote()" />
                                    </td>
                                    <td>
                                        <input id="btnQ" runat="server" type="button" class="conn_btn" value="添加问题" style="border: none;
                                            cursor: pointer" title="添加问题" onclick="showQuestion()" />
                                    </td>
                                    <%--<asp:Button ID="btnReturn" runat="server" Text="返回" OnClick="btnReturn_Click" />--%>
                                    <td>
                                        <asp:Button ID="btnReturn" runat="server" Text="返回" OnClick="btnReturn_Click" />
                                      <%--  <asp:ImageButton ID="btnReturn" runat="server" ImageUrl="~/Images/back.gif" AlternateText="返回"
                                            OnClick="btnReturn_Click" />--%>
                                    </td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                </table>
                </td>
        </tr>
        <tr>
            <td>
                <table width="100%" border="0" cellpadding="0" cellspacing="0">
                    <tr class="videobk">
                        <td align="left">
                            <%--<asp:UpdatePanel ID="UpdatePanelGvUser" runat="server" UpdateMode="Conditional">
                                        <ContentTemplate>--%>
                            <iframe id="LearnPanel" width="100%" runat="server" height="510" frameborder="0"
                                src="../images/tip.gif" style="border-width: 1px"></iframe>
                            <asp:Label ID="lblMessage" runat="server" Style="display: none"></asp:Label>
                            <asp:HiddenField ID="hideMessage" runat="server" />
                            <%--</ContentTemplate>
                                        <Triggers>
                                            <asp:AsyncPostBackTrigger ControlID="gvCourseAdjunct" />
                                        </Triggers>
                                    </asp:UpdatePanel>--%>
                        </td>
                    </tr>
                    <tr id="trSatisfactionDegree">
                        <td align="left">
                            <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional">
                                <ContentTemplate>
                                    <uc3:SatisfactionDegree ID="SatisfactionDegree" runat="server" />
                                </ContentTemplate>
                                <Triggers>
                                    <asp:AsyncPostBackTrigger ControlID="SatisfactionDegree" />
                                </Triggers>
                            </asp:UpdatePanel>
                        </td>
                    </tr>
                </table>
            </td>
            <td>
                <td id="course_intro" valign="top" align="left" height="560px" width="200px" runat="server">
                    <table width="100%" border="0" cellspacing="0" cellpadding="0" class="course">
                        <tr>
                            <td align="center">
                                <table width="98%" border="0" cellspacing="1" cellpadding="3" class="table_notitle">
                                    <tr>
                                        <td align="left" height="20px" class="td01" colspan="2">
                                             <a class="vtip" title='<img height=160 width=120  src=../Upload/CourseImage/<%=photopath %> /><font size="9pt"><%# Eval("Descrip") %></font>'><asp:Label ID="lblName" style="cursor:hand" runat="server" Font-Bold="True" ForeColor="#000000"></asp:Label></a>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="left" height="20px" class="td01">
                                            课程类别：
                                        </td>
                                        <td align="left">
                                            <asp:Label ID="lblTypeID" runat="server"></asp:Label>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="left" height="20px" class="td01">
                                            学习时间：
                                        </td>
                                        <td align="left">
                                            <asp:Label ID="lblLearnTime" runat="server"></asp:Label>
                                        </td>
                                    </tr>
                                </table>
                                <table width="97%" border="0" cellspacing="0" cellpadding="3">
                                    <tr>
                                        <td>
                                             <asp:GridView ID="gvCourseAdjunct" runat="server" AutoGenerateColumns="False" DataKeyNames="ID"
                                                OnRowCommand="gvCourseAdjunct_RowCommand" ShowHeader="False" OnRowDataBound="gvCourseAdjunct_RowDataBound">
                                                <Columns>
                                                    <asp:TemplateField HeaderText="附件">
                                                        <ItemTemplate>
                                                            <table style="width: 100%; border: none;" border="0" cellpadding="0" cellspacing="0">
                                                                <tr>
                                                                    <td align="left" style="border: none;" >
                                                                        <img src="../images/icons/<%# Eval("FileType") %>.gif" width="16" height="16" />
                                                                        </td>
                                                                    <td align="left" style="border: none;">
                                                                        <asp:LinkButton ID="lbtnFileName" runat="server" Text='<%# Common.CutString(Eval("FileName").ToString(),25) %>' CommandName="read"
                                                                            Font-Overline="false" ForeColor="Black" ToolTip="点击学习"></asp:LinkButton>
                                                                               <asp:Label ID="lblFolder" runat="server" Text='<%# Eval("Filepath") %>' 
                                                                            Visible="false"></asp:Label>
                                                                               <asp:Button ID="btnRead" CommandName="read" runat="server" ToolTip="点击学习" Text="学习"
                                                                CssClass="BigButton" Visible="false"  />
                                                                        <asp:Label ID="lblFileType" runat="server" Text='<%# Eval("FileType") %>' 
                                                                            Visible="false"></asp:Label>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td align="left" colspan="2" style="border: none;">
                                                                                 <asp:Panel ID="PanelSCOIndex" runat="server">
                                            <div class=admin_box>
                                              <ur>
                                                <asp:Repeater ID="rptSCO"  runat="server" onitemcommand="rptSCO_ItemCommand" 
                                                      onitemdatabound="rptSCO_ItemDataBound">
                                                <ItemTemplate>
                                                    <li><img id="imgPic" runat="server" src="../Images/134.gif" width="16" height="16" class="img_style" />
                                                            <asp:LinkButton ID="lbtnStudy" CommandArgument='<%# Eval("url") %>' CommandName="study" runat="server"><%# Eval("title") %></asp:LinkButton>
                                                            </li >
                                                            <asp:Label runat="server" Id="lblId" Text='<%# Eval("id") %>'  Visible="false"></asp:Label>
                                                             <asp:Label runat="server" Id="lblSCOEntryPoint" Text='<%# Eval("SCOEntryPoint") %>'  Visible="false"></asp:Label>
                                                </ItemTemplate>
                                                
                                                </asp:Repeater>
                                                </ur>
                                                </div>
                                            </asp:Panel>
                                                                       </td>
                                                                </tr>
                                                            </table>
                                                        </ItemTemplate>
                                                    </asp:TemplateField>
                                             
                                                </Columns>
                                                <EmptyDataRowStyle BorderStyle="None" BorderWidth="0px" />
                                            </asp:GridView>
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                    </table>
                </td>
            </td>
        </tr>
    </table>
    </form>
   
</body>
</html>
