<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="task_config.aspx.vb" Inherits="gogo_mechanism.task_config" %>
<%@ Import namespace="gogo_mechanism"%>
<html>
	<head id="head1"  runat="server">
    <title><%=pagename %></title>
    <meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="stylesheet" type="text/css" href="lib/bootstrap/css/bootstrap.css">
    <link rel="stylesheet" type="text/css" href="stylesheets/theme.css">
    <link rel="stylesheet" href="lib/font-awesome/css/font-awesome.css">
    <link href="site_css2.css" type="text/css" rel="stylesheet">
    <script src="lib/jquery-1.7.2.min.js" type="text/javascript"></script>
    <script src="lib/bootstrap/js/bootstrap.js" type="text/javascript"></script>
    <script type="text/javascript" src="js/myjs.js" language="javascript"></script>
    <!-- Le HTML5 shim, for IE6-8 support of HTML5 elements -->
    <!--[if lt IE 9]>
      <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
    <!-- Le fav and touch icons -->
</head>
  <body class=""> 
  	<form id="Form1" runat="server">
     <!--<![endif]-->
    <div class="content">
        
        <div class="header">
<div class="stats">
    <p class="stat">数量 <span class="number"><asp:label id="Label1" runat="server"></asp:label></span></p>
</div>
            <h1 class="page-title"><%=pagename %></h1>
        </div>
        
                <ul class="breadcrumb">
            <li><a href="info.aspx">系统首页</a> <span class="divider">/</span></li>
            <li class="active"><%=pagename %></li>
        </ul>

        <div class="container-fluid">
            <div class="row-fluid">
                    

    <div class="search-toolbar"><i class="icon-search"></i>
    单位<asp:TextBox ID="dpmid" runat="server" onclick="showDIV(this,dwtree);" 
            ReadOnly="True" Height="30px" Width="170px"></asp:TextBox>
    启用<asp:DropDownList ID="kg" runat="server" AutoPostBack="True">
            <asp:ListItem Selected="True" Value="0">所有</asp:ListItem>
            <asp:ListItem Value="true">启用</asp:ListItem>
            <asp:ListItem Value="false">停用</asp:ListItem>
        </asp:DropDownList>
    周期<asp:DropDownList ID="zq" runat="server" AutoPostBack="True">
            <asp:ListItem Value="all">所有</asp:ListItem>
            <asp:ListItem Value="间隔">间隔</asp:ListItem>
            <asp:ListItem Value="定日">定日</asp:ListItem>
            <asp:ListItem Value="每天">每天</asp:ListItem>
            <asp:ListItem Value="每周">每周</asp:ListItem>
            <asp:ListItem Value="每月">每月</asp:ListItem>
        </asp:DropDownList>
        深度<asp:DropDownList ID="Depth" runat="server" AutoPostBack="True">
            <asp:ListItem Value="all">所有</asp:ListItem>
            <asp:ListItem>0</asp:ListItem>
            <asp:ListItem>1</asp:ListItem>
            <asp:ListItem>2</asp:ListItem>
            <asp:ListItem>3</asp:ListItem>
            <asp:ListItem>4</asp:ListItem>
            <asp:ListItem>5</asp:ListItem>
            <asp:ListItem>6</asp:ListItem>
            <asp:ListItem>7</asp:ListItem>
            <asp:ListItem>8</asp:ListItem>
            <asp:ListItem>9</asp:ListItem>
            <asp:ListItem>10</asp:ListItem>
        </asp:DropDownList>
        记录模式<asp:DropDownList ID="recordhtml" runat="server" AutoPostBack="True">
            <asp:ListItem Value="all">所有</asp:ListItem>
            <asp:ListItem Value="2">预警时记录</asp:ListItem>
            <asp:ListItem Value="1">始终记录</asp:ListItem>
            <asp:ListItem Value="0">从不记录</asp:ListItem>
        </asp:DropDownList>
  关键词模式<asp:DropDownList ID="ksmode" runat="server" AutoPostBack="True">
            <asp:ListItem Value="all">所有</asp:ListItem>
            <asp:ListItem Value="0">仅使用部门策略</asp:ListItem>
            <asp:ListItem Value="1">使用部门和下属部门策略</asp:ListItem>
        </asp:DropDownList>
        状态<asp:DropDownList ID="zt" runat="server" AutoPostBack="True">
            <asp:ListItem Value="all">所有</asp:ListItem>
            <asp:ListItem Value="0">任务停止</asp:ListItem>
            <asp:ListItem Value="1">正在运行</asp:ListItem>
        </asp:DropDownList>
         搜索<asp:DropDownList ID="how" runat="server">
            <asp:ListItem Value="id">编号</asp:ListItem>
            <asp:ListItem Selected="True" Value="mc">名称</asp:ListItem>
            <asp:ListItem Value="urls">开始地址</asp:ListItem>
            <asp:ListItem Value="host">域名限制</asp:ListItem>
            <asp:ListItem Value="ip1">起始限制IP</asp:ListItem>
            <asp:ListItem Value="ip2">截止限制IP</asp:ListItem>
        </asp:DropDownList>
        关键词<asp:TextBox ID="key" runat="server" Height="30px" Width="100px"></asp:TextBox>
         </div>
         <div class="btn-toolbar">
    <asp:Button ID="Button6" runat="server" Text="新增任务" class="btn btn-primary"/>
    <asp:Button ID="Button1" runat="server" CausesValidation="False" Text="当页全选" class="btn"/>
    <asp:Button ID="Button2" runat="server" CausesValidation="False" Text="取消选择" class="btn"/>
    <asp:Button ID="Button3" runat="server" CausesValidation="False" Text="删除选中"  class="btn btn-danger"/>
     <asp:Button ID="Button4" runat="server" Text="执行搜索" class="btn"/>
    <asp:Button ID="Button5" runat="server" Text="退出搜索" class="btn"/>
    </div>

 <div class="btn-group"></div>
<div class="well">
   <!--内容-->
     <asp:ScriptManager ID="ScriptManager1" runat="server" />
                   <asp:UpdatePanel ID="UpdatePanel3" runat="server"> 
<ContentTemplate> 
<asp:Timer ID="Timer1" runat="server" Interval="10000" OnTick="Timer1_Tick"> 
</asp:Timer> 
    <asp:GridView ID="GridView1" runat="server" AllowPaging="True"  AutoGenerateColumns="False" GridLines="None" PageSize="15" Width="100%" CssClass="table">
         <Columns>
            <asp:TemplateField HeaderText="选择">
                <ItemTemplate>
                    <asp:CheckBox ID="CheckBox1" runat="server" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField DataField="id" HeaderText="编号" ReadOnly="True" />
            <asp:TemplateField HeaderText="所属部门">
                <ItemTemplate>
                    <asp:Label ID="Label5" runat="server" 
                        Text='<%# getdepartmentname(DataBinder.Eval(Container, "DataItem.dpmid"))%>'></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:HyperLinkField DataNavigateUrlFields="id" 
                DataNavigateUrlFormatString="edit_task.aspx?id={0}" DataTextField="mc" 
                HeaderText="名称" />
            <asp:TemplateField HeaderText="周期模式">
                <ItemTemplate>
                                                <%# zqmode(DataBinder.Eval(Container, "DataItem.zq"), DataBinder.Eval(Container, "DataItem.fz"), DataBinder.Eval(Container, "DataItem.rq"), DataBinder.Eval(Container, "DataItem.xq"), DataBinder.Eval(Container, "DataItem.hs"), DataBinder.Eval(Container, "DataItem.h"), DataBinder.Eval(Container, "DataItem.m"))%>
                                            </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="启用">
                <ItemTemplate>
                                                <%# Boolean_to_str(DataBinder.Eval(Container, "DataItem.kg"), "启用", "")%>
                                            </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="运行状态">
                <ItemTemplate>
                                                <%# taskzt(DataBinder.Eval(Container, "DataItem.zt"))%>
                                            </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="最近执行时间">
                <ItemTemplate>
                                                <%# tasktime3(DataBinder.Eval(Container, "DataItem.time1"),DataBinder.Eval(Container, "DataItem.time2"),DataBinder.Eval(Container, "DataItem.sml"))%>
                                            </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="扫描均量">
                <ItemTemplate>
                                                <%# plsml(DataBinder.Eval(Container, "DataItem.id"), 3, 10)%>
                                            </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField DataField="zl" HeaderText="下一指令" />
            <asp:ButtonField CommandName="gorun" HeaderText="操作" Text="执行/停止" />
            <asp:CommandField HeaderText="编辑" SelectText="编辑" ShowSelectButton="True" />
        </Columns>
        <PagerStyle CssClass="pagerclass" />
        <EmptyDataTemplate>
            暂无监测任务！
        </EmptyDataTemplate>
        </asp:GridView>
    </ContentTemplate> 
</asp:UpdatePanel> 
</div>
                    
            </div>
        </div>
    </div>
                <!--隐藏开始-->
			<div class="menudiv" id="dwtree">
            <asp:TreeView ID="fidTreeView" runat="server" ImageSet="XPFileExplorer" 
        NodeIndent="15" ShowLines="True">
            <HoverNodeStyle Font-Underline="True" ForeColor="#6666AA" />
            <NodeStyle Font-Names="Tahoma" ForeColor="Black" 
                HorizontalPadding="2px" NodeSpacing="0px" VerticalPadding="2px" />
            <ParentNodeStyle Font-Bold="False" />
            <SelectedNodeStyle BackColor="#B5B5B5" Font-Underline="False" 
                HorizontalPadding="0px" VerticalPadding="0px" />
        </asp:TreeView>
            </div>
			<!--隐藏结束-->
    </form>
</body>
</html>
