<%@ Page CodeFileBaseClass="AliCMS.Lib.SystemPageBase" %>
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<ali:Get ID="Config" Object="InstanceConfig" Operation="GetGlobalSettings()" Validate="True" />
<title>生成设置</title>
<link rel="stylesheet"  href="<%=CommonPath%>jquery/themes/lightness/all.css" >
<ali:Comment><link rel="stylesheet"  href="../../S01/CHS/css/common.css" ></ali:Comment>
<link rel="stylesheet" href="<%=CssPath%>common.css" >
<script >
var _page = 'generate_config_basic',
    _lang = '<%=ContentLang%>',
    _webPath = '<%=WebPath%>',
    _imagePath = '<%=ImagePath%>',
    _lang_working ='正在操作...',
    _lang_operation_fail = '操作失败！',
    _lang_operation_success = '操作成功！',
    _lang_generate_interval_incorrect = '生成间隔格式不正确！';
</script>
</head>
<body>
<div class="WhiteHeader">
	<div class="Left"><img src="<%=ImagePath%>close_frame.gif" ></div>
	<div class="Title">全局设置</div>
	<div class="Right"></div>
</div>
<div class="Block">
	<ul class="TabMenu">
		<li class="Left Selected"></li>
		<li class="Middle Selected">生成设置</li>
		<li class="Right Selected"></li>
		<li class="Left"></li>
		<li class="Middle"><a href="../../generate/auto/list.aspx">智能生成</a></li>
		<li class="Right"></li>
		<li class="Left"></li>
		<li class="Middle"><a href="../../generate/manual/list.aspx">手动生成</a></li>
		<li class="Right"></li>
	</ul>
	<ul class="Title">
		<li class="Left"></li>
		<li class="Middle"></li>
		<li class="Right"></li>
	</ul>
	<form>
		<table border="0" cellpadding="4" cellspacing="1">
			<tbody>
				<tr>
					<th width="140">智能生成（更新）：</th>
					<td>
						<%If Convert.ToBoolean(Config[DisableSmartUpdate])%>
							<input type="radio" name="SmartUpdate" id="SmartUpdateDisable" checked="checked" ><label for="SmartUpdateDisable">禁用</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateLow" ><label for="SmartUpdateLow">低效</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateHigh" ><label for="SmartUpdateHigh">高效</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateSpeedUp" ><label for="SmartUpdateSpeedUp">爱革加速器</label>
						<%ElseIf Convert.ToBoolean(Config[IIS404])%>
							<input type="radio" name="SmartUpdate" id="SmartUpdateDisable" ><label for="SmartUpdateDisable">禁用</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateLow" ><label for="SmartUpdateLow">低效</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateHigh" checked="checked" ><label for="SmartUpdateHigh">高效</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateSpeedUp" ><label for="SmartUpdateSpeedUp">爱革加速器</label>
						<%ElseIf !String.IsNullOrEmpty(Config[SpeedUpConnectionString])%>
							<input type="radio" name="SmartUpdate" id="SmartUpdateDisable" ><label for="SmartUpdateDisable">禁用</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateLow" ><label for="SmartUpdateLow">低效</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateHigh" ><label for="SmartUpdateHigh">高效</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateSpeedUp" checked="checked" ><label for="SmartUpdateSpeedUp">爱革加速器</label>
						<%Else%>
							<input type="radio" name="SmartUpdate" id="SmartUpdateDisable" ><label for="SmartUpdateDisable">禁用</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateLow" checked="checked" ><label for="SmartUpdateLow">低效</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateHigh" ><label for="SmartUpdateHigh">高效</label>
							<input type="radio" name="SmartUpdate" id="SmartUpdateSpeedUp" ><label for="SmartUpdateSpeedUp">爱革加速器</label>
						<%EndIf%>
					</td>
				</tr>
				<tr id="SpeedUpTR" style="display:none">
					<th>爱革加速器：</th>
					<td>
						数据库连接字符串：<input type="text" name="SpeedUpConnectionString" value="<%=Config[SpeedUpConnectionString]%>" size="80" maxlength="255" class="Text" />
						<br />{#WebPath#}表示网站根目录，{#DataPath#}表示数据目录。
					</td>
				</tr>
				<tr id="LowTR" style="display:none">
					<th>低效生成：</th>
					<td>这是默认方式，也是要求最低的方式。</td>
				</tr>
				<tr id="HighTR" style="display:none">
					<th>高效生成：</th>
					<td>
						<br />设置方法：1）启动IIS。2）打开你的网站属性。3）切换到“自定义错误”。4）列表中选择“404”，点击“编辑属性”。5）消息类型：URL；URL：/alicms.aspx
						<br />按照上述方法设置完之后，才可启用此设置。
					</td>
				</tr>
				<tr id="IntervalTR" style="display:none">
					<th>生成间隔：</th>
					<td>
						<input type="text" name="GenerateInterval" value="<%=Config[GenerateInterval]%>" size="10" class="Text" />秒
						<br />如果生成时，占用CPU太多，可以把此项设置大一些。
					</td>
				</tr>
			</tbody>
			<tfoot>
				<tr>
					<td colspan="2"><input type="submit" class="Button" value="保存" ></td>
				</tr>
			</tfoot>
		</table>
	</form>
	<div class="Footer"></div>
</div>
<script  src="<%=CommonPath%>jquery/core.js"></script>
<script  src="<%=CommonPath%>jquery/ui.js"></script>
<script  src="<%=CommonPath%>utility.js"></script>
<script  src="<%=JsPath%>global.js"></script>
<script  src="<%=ModuleJsPath%>module.js"></script>
</body>
</html>