| 
			
	
	
	
						  
						
						
						
	
 
					注:这里的原型是展示效果,让大家有个感性的认识,编码不在这里进行,项目开发过程会在后面的章节从零开始。
					 
					
				<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<html>
<head>
	<script src="https://how2j.cn/study/js/jquery/2.0.0/jquery.min.js"></script>
	<link href="https://how2j.cn/study/css/bootstrap/3.3.6/bootstrap.min.css" rel="stylesheet">
	<script src="https://how2j.cn/study/js/bootstrap/3.3.6/bootstrap.min.js"></script>
	<link href="https://how2j.cn/tmall/css/back/style.css" rel="stylesheet">
	
<script>
function checkEmpty(id, name){
	var value = $("#"+id).val();
	if(value.length==0){
		alert(name+ "不能为空");
		$("#"+id)[0].focus();
		return false;
	}
	return true;
}
function checkNumber(id, name){
	var value = $("#"+id).val();
	if(value.length==0){
		alert(name+ "不能为空");
		$("#"+id)[0].focus();
		return false;
	}
	if(isNaN(value)){
		alert(name+ "必须是数字");
		$("#"+id)[0].focus();
		return false;
	}
	
	return true;
}
function checkInt(id, name){
	var value = $("#"+id).val();
	if(value.length==0){
		alert(name+ "不能为空");
		$("#"+id)[0].focus();
		return false;
	}
	if(parseInt(value)!=value){
		alert(name+ "必须是整数");
		$("#"+id)[0].focus();
		return false;
	}
	
	return true;
}
$(function(){
	$("a").click(function(){
		var deleteLink = $(this).attr("deleteLink");
		console.log(deleteLink);
		if("true"==deleteLink){
			var confirmDelete = confirm("确认要删除");
			if(confirmDelete)
				return true;
			return false;
			
		}
	});
})
</script>	
</head>
<body>
<div class="navitagorDiv">
	<nav class="navbar navbar-default navbar-fixed-top navbar-inverse">
		<img style="margin-left:10px;margin-right:0px" class="pull-left" src="https://how2j.cn/tmall/img/site/tmallbuy.png" height="45px">
		<a class="navbar-brand" href="#nowhere">天猫后台</a>
		
		<a class="navbar-brand" href="#nowhere">分类管理</a>
		<a class="navbar-brand" href="#nowhere">用户管理</a>
		<a class="navbar-brand" href="#nowhere">订单管理</a>
	</nav>
</div>
<script>
	$(function() {
		$("#addForm").submit(function() {
			if (!checkEmpty("name", "产品名称"))
				return false;
// 			if (!checkEmpty("subTitle", "小标题"))
// 				return false;
			if (!checkNumber("orignalPrice", "原价格"))
				return false;
			if (!checkNumber("promotePrice", "优惠价格"))
				return false;
			if (!checkInt("stock", "库存"))
				return false;
			return true;
		});
	});
</script>
<title>产品管理</title>
<div class="workingArea">
	<ol class="breadcrumb">
	  <li><a href="#nowhere">所有分类</a></li>
	  <li><a href="#nowhere">男士手拿包 </a></li>
	  <li class="active">产品管理</li>
	</ol>
	<div class="listDataTableDiv">
		<table
			class="table table-striped table-bordered table-hover  table-condensed">
			<thead>
				<tr class="success">
					<th>ID</th>
					<th>图片</th>
					<th>产品名称</th>
					<th>产品小标题</th>
					<th width="53px">原价格</th>
					<th width="80px">优惠价格</th>
					<th width="80px">库存数量</th>
					<th width="80px">图片管理</th>
					<th width="80px">设置属性</th>
					<th width="42px">编辑</th>
					<th width="42px">删除</th>
				</tr>
			</thead>
			<tbody>
				
					<tr>
						<td>677</td>
						<td>
						
							<img width="40px" src="https://how2j.cn/tmall/img/productSingle/7058.jpg">
						
						</td>
						<td>MAXFEEL休闲男士手包真皮手拿包大容量信封包手抓包夹包软韩版潮</td>
						<td>无理由退换货 赠退货运费险</td>
						<td>888.0</td>
						<td>799.2</td>
						<td>98</td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-picture"></span></a></td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-th-list"></span></a></td>
						
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-edit"></span></a></td>
						<td><a deleteLink="true"
							href="#nowhere"><span
								class=" 	glyphicon glyphicon-trash"></span></a></td>
					</tr>
				
					<tr>
						<td>676</td>
						<td>
						
							<img width="40px" src="https://how2j.cn/tmall/img/productSingle/7047.jpg">
						
						</td>
						<td>宾度 男士手包真皮大容量手拿包牛皮个性潮男包手抓包软皮信封包</td>
						<td>专注品质领卷 顺丰包邮 头层牛皮 大容量 软皮</td>
						<td>568.0</td>
						<td>511.2</td>
						<td>79</td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-picture"></span></a></td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-th-list"></span></a></td>
						
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-edit"></span></a></td>
						<td><a deleteLink="true"
							href="#nowhere"><span
								class=" 	glyphicon glyphicon-trash"></span></a></td>
					</tr>
				
					<tr>
						<td>675</td>
						<td>
						
							<img width="40px" src="https://how2j.cn/tmall/img/productSingle/7036.jpg">
						
						</td>
						<td>唯美诺新款男士手包男包真皮大容量小羊皮手拿包信封包软皮夹包潮</td>
						<td>优质羊皮 大容量 品牌做工 超软手感 终身包保修</td>
						<td>498.0</td>
						<td>448.2</td>
						<td>84</td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-picture"></span></a></td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-th-list"></span></a></td>
						
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-edit"></span></a></td>
						<td><a deleteLink="true"
							href="#nowhere"><span
								class=" 	glyphicon glyphicon-trash"></span></a></td>
					</tr>
				
					<tr>
						<td>674</td>
						<td>
						
							<img width="40px" src="https://how2j.cn/tmall/img/productSingle/7025.jpg">
						
						</td>
						<td>英伦邦纹男士手包牛皮大容量真皮手拿包手抓包双拉链商务正品软皮</td>
						<td>意大利牛皮 纹路自然漂亮 更耐用更尊贵 手感棒</td>
						<td>588.0</td>
						<td>411.6</td>
						<td>42</td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-picture"></span></a></td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-th-list"></span></a></td>
						
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-edit"></span></a></td>
						<td><a deleteLink="true"
							href="#nowhere"><span
								class=" 	glyphicon glyphicon-trash"></span></a></td>
					</tr>
				
					<tr>
						<td>673</td>
						<td>
						
							<img width="40px" src="https://how2j.cn/tmall/img/productSingle/7014.jpg">
						
						</td>
						<td>劳迪莱斯男士手包休闲手拿包牛皮大容量钱包男包软面小包包手抓包</td>
						<td>牛皮手包 耐磨耐用 多卡位设计</td>
						<td>185.0</td>
						<td>157.25</td>
						<td>24</td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-picture"></span></a></td>
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-th-list"></span></a></td>
						
						<td><a href="#nowhere"><span
								class="glyphicon glyphicon-edit"></span></a></td>
						<td><a deleteLink="true"
							href="#nowhere"><span
								class=" 	glyphicon glyphicon-trash"></span></a></td>
					</tr>
				
			</tbody>
		</table>
	</div>
	<div class="pageDiv">
		
<script>
$(function(){
	$("ul.pagination li.disabled a").click(function(){
		return false;
	});
});
</script>
<nav>
  <ul class="pagination">
    <li class="disabled">
      <a  href="#nowhere" aria-label="Previous" >
        <span aria-hidden="true">«</span>
      </a>
    </li>
    <li class="disabled">
      <a  href="#nowhere" aria-label="Previous" >
        <span aria-hidden="true">‹</span>
      </a>
    </li>    
		    <li class="disabled">
		    	<a  
		    	href="#nowhere"
		    	class="current"
		    	>1</a>
		    </li>
		
		    <li >
		    	<a  
		    	href="#nowhere"
		    	
		    	>2</a>
		    </li>
		
		    <li >
		    	<a  
		    	href="#nowhere"
		    	
		    	>3</a>
		    </li>
		
		    <li >
		    	<a  
		    	href="#nowhere"
		    	
		    	>4</a>
		    </li>
		
    <li >
      <a href="#nowhere" aria-label="Next">
        <span aria-hidden="true">›</span>
      </a>
    </li>
    <li >
      <a href="#nowhere" aria-label="Next">
        <span aria-hidden="true">»</span>
      </a>
    </li>
  </ul>
</nav>
	</div>
	<div class="panel panel-warning addDiv">
		<div class="panel-heading">新增产品</div>
		<div class="panel-body">
			<form method="post" id="addForm" >
				<table class="addTable">
					<tr>
						<td>产品名称</td>
						<td><input id="name" name="name" type="text" 
							class="form-control"></td>
					</tr>
					<tr>
						<td>产品小标题</td>
						<td><input id="subTitle" name="subTitle" type="text"
							class="form-control"></td>
					</tr>
					<tr>
						<td>原价格</td>
						<td><input id="orignalPrice" value="99.98" name="orignalPrice" type="text"
							class="form-control"></td>
					</tr>
					<tr>
						<td>优惠价格</td>
						<td><input id="promotePrice"  value="19.98" name="promotePrice" type="text"
							class="form-control"></td>
					</tr>
					<tr>
						<td>库存</td>
						<td><input id="stock"  value="99" name="stock" type="text"
							class="form-control"></td>
					</tr>
					<tr class="submitTR">
						<td colspan="2" align="center">
							<input type="hidden" name="cid" value="72">
							<button type="button" class="btn btn-success">提 交</button>
						</td>
					</tr>
				</table>
			</form>
		</div>
	</div>
</div>
<div class="footer">
</div>
</body>
</html>
 
								
										
									
								
							
 
				HOW2J公众号,关注后实时获知最新的教程和优惠活动,谢谢。
			 
			 
			
			
			
			
			
		
			
			提问之前请登陆
			
		 
		提问已经提交成功,正在审核。 请于 我的提问 处查看提问记录,谢谢	
	 
 |