<!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>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>在线商城后台管理</title>
<link rel="stylesheet" type="text/css" href="view/admin/style/basic.css" />
<link rel="stylesheet" type="text/css" href="view/admin/style/nav.css" />
<script type="text/javascript" src="view/admin/js/basic.js"></script>
<script type="text/javascript" src="view/admin/js/nav.js"></script>
{literal}
<script type="text/javascript">
	function addHomeNav() {
		var fm = document.update;
		
		if (fm.name.value == '') {
			alert('名称不能为空！');
			fm.name.focus();
			return false;
		}	
		if(fm.category.value==0){
			alert('请选择分类！');			
			return false;
		}
		return true;
	}
	</script>
{/literal}
</head>
<body>

<h2>系统 -- 修改首页数据</h2>

<form method="post" name="update" action="?a=homenav&m=update&id={$OneNav[0]->id}">
	<input type="hidden" name="flag" id="flag" />	
	<div class="add_update">		
		<table cellspacing="0">		
			<tr>
				<td class="text_right">名　　称：</td>
				<td class="text_left">
					<input type="text" name="name" value="{$OneNav[0]->name}" />
				</td>
			</tr>
			<tr>
				<td class="text_right">所属分类：</td>
				<td class="text_left">
					<select name="category" id="category" onchange="change_category_tao();">
							<option value="0">--请选择分类--</option>
							{html_options options=$category selected=$OneNav[0]->category}
					</select>
					<input type="hidden" name="tao_category"  id="tao_category" class="text" value="{$OneNav[0]->tao_category}" /> 
					<span>说明：分类名称用于调取api数据</span>					
				</td>
			</tr>			
			<tr>
				<td class="text_right">显示状态：</td>
				<td class="text_left">
					<select name="state" style="width:100px;">
						{$OneNav[0]->state}
					</select>
				</td>
			</tr>		
			<tr>
				<td class="text_right">排　　序：</td>
				<td class="text_left">
					<input type="text" name="sort"  id="sort" class="text"  value="{$OneNav[0]->sort}"/>
				</td>
			</tr>
			<tr>
				<td class="text_right">简　　介：</td>
				<td class="text_left">
					<textarea name="info">{$OneNav[0]->info}</textarea> <span class="middle">( * 200位以内 )</span>
				</td>
			</tr>
			<tr>
				<td></td>
				<td><input type="submit" name="send" onclick="return updateNav();" value="修改首页数据" class="submit" /></td>
			</tr>
		</table>
	</div>	
</form>

</body>
</html>