<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="ReportKoho.aspx.vb" Inherits="eTella.Web.ReportKoho" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>【管理画面】</title>
    <link rel="stylesheet" href="../assets/css/admin.css" type="text/css" />
    <link rel="stylesheet" href="../assets/css/jquery-ui.css" type="text/css" />
    <script type="text/javascript" src="../assets/js/jquery-1.8.1.min.js"></script>
    <script type="text/javascript" src="../assets/js/jquery-ui.js"></script>
    <script type="text/javascript" src="../assets/js/jquery.blockUI.js"></script>
    <script type="text/javascript">

        //function block() {

        //    $.blockUI({ message: '<p><img src="../img/loader.gif" style="vertical-align:middle;" /> 集計中です...</p>' });
        //}

        //function pageLoad() {

        //    var mng = Sys.WebForms.PageRequestManager.getInstance();
        //    // 非同期ポストバックの完了時に呼び出されるイベントを定義
        //    mng.add_endRequest(
        //    function (sender, args) {
        //        $(function () {
        //            $.unblockUI();
        //        });
        //    });

        //}
                
        $(document).ready(function () {

            $("#progressbar-2").progressbar({
                value: 0,
                max: '<%= maxValue%>'
            });

            function ShowCurrentTime() {

                var progressbar = $("#progressbar-2");

                var val = progressbar.progressbar("value") || 0
                progressbar.progressbar("value", val + 1);
                console.log(val)
                if (val < '<%= maxValue%>') {
                    setInterval(function () {
                        ShowCurrentTime();
                    }, 1000);
                }
                                
            }

            $('#BtnDownload').click(function (e) {

                setTimeout(ShowCurrentTime(), 3000);

            });

                      
        });

        function InsertIFrameDownloadPage(sUrl) {
            document.getElementById('ifDownloadPage').contentWindow.location.href = sUrl;
        }
    </script>
<style>
         .ui-widget-header {
            background: #268187;
            border: 1px solid #DDDDDD;
            color: #333333;
            font-weight: bold;
         }
</style>
</head>
<body>
    <form id="form1" runat="server">
    <label class="caption">集計結果報告書（候補者別）</label><br />
    <br />
    
    <asp:CheckBox ID="ChkAll" runat="server"  Text="全投票所フォルダを集計対象とする" AutoPostBack="true" Visible="false"/><br />
        <asp:Label ID="Label1" runat="server" Text="投票所："></asp:Label>
        <asp:DropDownList ID="DropDownList1" runat="server" Font-Size="X-Large" Font-Bold="True"></asp:DropDownList>
        <br>
    <%--Hashimoto--%>
    <br />
        <div style="text-align:center; margin-bottom:10px;">
    <asp:RadioButton id="Chk_O1" runat="server" Text="得票順で出力する" groupname="order"/><br />
    <asp:RadioButton id="Chk_O2" runat="server" Text="届出順で出力する" groupname="order"/><br />
            </div>
    <%--<asp:CheckBox ID="Chk_Csv" runat="server" Text="CSV出力" />
    <asp:Button ID="BtnDownload" runat="server" Text="　集計　" /><br />--%>


<div style="text-align:center; margin-top:10px;margin-left:-150px">
    <asp:CheckBox ID="Chk_Csv" runat="server" Text="CSV出力" />
    <asp:Button ID="BtnDownload" runat="server" Text="　集計　" />
</div>

                                        <div id = "progressbar-2"></div>
        <label class="warning"><asp:Label ID="LblMessage" runat="server"></asp:Label></label><br />
  
    
        
        <a href="Menu.aspx" class="btn">もどる</a>

<!-- 隠しiframe -->
        <div>
<iframe id="ifDownloadPage" style="visibility:hidden"></iframe>
            </div>
    </form>
</body>
</html>
