<!--#include file="../../Inc/Cls_Main.Asp"-->
<!--#include file="../inc/Cls_Admin.Asp"-->
<!--#include file="../inc/Cls_MapPath.Asp"-->
<!--#include file="../inc/Cls_Type.Asp"-->
<!--#include file="../Admin_Check.Asp"-->
<%
Dim CmsAdmin, IncTemp, ToUrl
ToUrl = CmsFun.LoadToUrl()
'=========================================================== 加载日期组件
IncTemp = CmsMain.LoadDateScript(SiteWebFilePath)
'=============================================================================
Set CmsAdmin = New Cls_Admin
CmsAdmin.SetAdminTitle = CmsSiteName
CmsAdmin.SetIncHtmlFile = IncTemp
CmsAdmin.SetBodyCssName = "mainbody"
CmsAdmin.SetAdminPath = CmsAdminMapPath
CmsAdmin.LoadHead()
'=============================================================================
Dim ChannelId, ChannelName, BriefName, TabName, ChannelPath, ModelId
ChannelId = Easp.Get("ChannelId:n:0")
If ChannelId = 0 Then
    CmsAdmin.JscriptMsg "频道参数错误！", "back", "Error", "null"
End If
' 读取频道信息
Dim ArrayChannel
ArrayChannel = GetCaCheChannelInfo("Channel", ChannelId, ChannelField)
If Easp.IsN(ArrayChannel) Then
    CmsAdmin.JscriptMsg "不存在的频道！", "back", "Error", "null"
Else
    ChannelName = ArrayChannel(0)
    BriefName = ArrayChannel(1)
    TabName = ArrayChannel(2)
    ModelId = ArrayChannel(3)
    ChannelPath = ArrayChannel(4)
End If
'=============================================================================
Dim Action
'=============================================================================
Action = Easp.Get("action")
Select Case Action
    Case "pageload"
        Call PageLoad()
    Case "px"
        Call Px()
    Case "delall"
        Call DelAll()
    Case Else
        Call PageLoad()
End Select
CmsAdmin.LoadFooter()
Set CmsAdmin = Nothing

Sub PageLoad()
    ChkSysAdminLevel "sys_channel", "show"
    ' 读取分类
    Dim objType, SelectList
    Set objType = New Cls_Type
    SelectList = objType.ShowSelectList("选择分类", ChannelId, 0, 0)
    Set objType = Nothing
%>
<div class="navigation"><a href="Admin.Index.Asp" class="back">生成静态</a> 控制面板 &gt; 生成静态 &gt; <%=ChannelName%></div>
<div id="contentTab">
  <div class="content-tab">
    <ul class="tab_nav">
      <li><a onclick="tabs(this);" class="selected" href="javascript:void(0);">生成移动端<%=ChannelName%></a></li>
    </ul>
  </div>
  <div class="tab_con" style="display: block;">
    <table class="form_table">
      <col width="200px">
        </col>
      
      <tbody>
      <form action="Admin.Mt.Html.Asp" method="get" id="fm1" target="_blankframe">
        <input type="hidden" name="action" value="infoall" />
        <input type="hidden" name="ChannelId" value="<%=ChannelId%>" />
        <tr>
          <th>一键生成<%=ChannelName%>：</th>
          <td><input type="button" class="btnSearch" value="开始生成" onclick="ExeConfirmSub('fm1','Admin.Mt.Html.Asp','一键生成整个频道很耗资源,您确定要生成吗？');" /></td>
        </tr>
      </form>
      <tr>
        <th></th>
        <td><iframe style="display:;width:100%;height:150px;" frameborder="0" src="blank.html" name="_blankframe" id="createiframe" allowTransparency="true"></iframe></td>
      </tr>
      <form action="Admin.Mt.Html.Asp" method="get" id="fmindex" target="_blankframe">
        <input type="hidden" name="action" value="infoindex" />
        <input type="hidden" name="ChannelId" value="<%=ChannelId%>" />
        <tr>
          <th>生成<%=ChannelName%>首页：</th>
          <td><input type="button" class="btnSearch" onclick="OkSubmit('fmindex');" value="开始生成" /></td>
        </tr>
      </form>
      <form action="Admin.Mt.Html.Asp" method="get" id="fminfo_list" target="_blankframe">
        <input type="hidden" name="action" value="infolist" />
        <input type="hidden" name="ChannelId" value="<%=ChannelId%>" />
        <tr>
          <th>生成分类：</th>
          <td><%=SelectList%>
            <input type="button" class="btnSearch" onclick="OkSubmit('fminfo_list');" value="开始生成" /></td>
        </tr>
      </form>
      <form action="Admin.Mt.Html.Asp" method="get" id="fminfo" target="_blankframe">
        <input type="hidden" name="action" value="info" />
        <input type="hidden" name="ChannelId" value="<%=ChannelId%>" />
        <tr>
          <th>一键生成全部内容：</th>
          <td><input type="button" class="btnSearch" onclick="OkSubmit('fminfo');" value="开始生成" /></td>
        </tr>
      </form>
      <form action="Admin.Mt.Html.Asp" method="get" id="fminfo_New" target="_blankframe">
        <input type="hidden" name="action" value="info" />
        <input type="hidden" name="ChannelId" value="<%=ChannelId%>" />
        <tr>
          <th>生成最新多少条内容：</th>
          <td><input name="NewNum" type="text" id="NewNum" class="txtInput w50" onfocus="ChkNumEric(this)" autocomplete="off" maxlength="5" value="100" />
            <label> </label>
            <input type="button" class="btnSearch" onclick="OkSubmit('fminfo_New');" value="开始生成" /></td>
        </tr>
      </form>
      <form action="Admin.Mt.Html.Asp" method="get" id="fminfo_Type" target="_blankframe">
        <input type="hidden" name="action" value="info" />
        <input type="hidden" name="ChannelId" value="<%=ChannelId%>" />
        <tr>
          <th>按分类生成内容：</th>
          <td><%=SelectList%>
            <input type="button" class="btnSearch" onclick="OkSubmit('fminfo_Type');" value="开始生成" /></td>
        </tr>
      </form>
      <form action="Admin.Mt.Html.Asp" method="get" id="fminfo_Time" target="_blankframe">
        <input type="hidden" name="action" value="info" />
        <input type="hidden" name="ChannelId" value="<%=ChannelId%>" />
        <tr>
          <th>按日期生成：</th>
          <td><input name="StartTime" type="text" id="StartTime" class="txtInput w100" autocomplete="off" maxlength="150" value="<%=Easp.DateTime(DateAdd("m",-1,date()),"yyyy-mm-dd")%>" onclick="WdatePicker();" />
            <input name="EndTime" type="text" id="EndTime" class="txtInput w100" autocomplete="off" maxlength="150" value="<%=Easp.DateTime(date(),"yyyy-mm-dd")%>" onclick="WdatePicker();" />
            <label> </label>
            <input type="button" class="btnSearch" onclick="OkSubmit('fminfo_Time');" value="开始生成" /></td>
        </tr>
      </form>
      <form action="Admin.Mt.Html.Asp" method="get" id="fminfo_id" target="_blankframe">
        <input type="hidden" name="action" value="info" />
        <input type="hidden" name="ChannelId" value="<%=ChannelId%>" />
        <tr>
          <th>按指定ID生成：</th>
          <td><input name="id" type="text" id="id" class="txtInput w350" autocomplete="off" maxlength="150" />
            <input type="button" class="btnSearch" onclick="OkSubmit('fminfo_id');" value="开始生成" />
            <label>(多个以逗号隔开,如：1,2,3)</label></td>
        </tr>
      </form>
        </tbody>
      
    </table>
  </div>
</div>
<%
End Sub
%>
