目录
1 概论 1
1.1电子商务交易发展 1
1.1.1电子商务交易 1
1.1.2发展前景: 1
2 系统可行性及需求分析 3
2.1 系统调研 3
2.2 系统可行性分析 3
2.2.1技术可行性分析 3
2.2.2 操作可行性分析 3
2.2.3 社会可行性分析 4
2.2.4可行性分析小结 4
2.3 系统需求分析 4
2.4 系统实施要求 5
3 主要功能设计及实现 6
3.1 主要功能设计与实现 6
3.1.1 用户操作 6
3.1.2购物车管理 13
3.1.3订单管理 18
3.1.4商品展示 21
3.2 数据库的设计与实现 25
3.2.1数据库设计概述 25
3.2.2 MySQL数据库自身特性及应用环境 25
3.2.3 系统的实体模型 27
3.2.4数据库表设计 28
4 系统测试与系统分析 29
4.1 系统各功能模块测试与分析 29
4.2 系统在不同操作系统的测试与分析 31
4.3 系统在不同内核浏览器的测试与分析 31
4.4 小结 31
5 结论 33
致谢 34
参考文献 35
附录:数据库设计详表 36
<%@page contentType="text/html" pageEncoding="UTF-8" import="java.util.*, edu.zzu.hellomall.entity.*, edu.zzu.hellomall.imp.*"%>
<%@page import="edu.zzu.hellomall.util.ChangeStr"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<%
Member sessionMember = (Member)session.getAttribute("member");
int cartSize = 0;
CartDaoImp cdi = new CartDaoImp();
List cartList = null;
if(sessionMember == null){
//用户未登录
HashMap sessionCart = (HashMap)session.getAttribute("cart");
if(sessionCart != null){
cartList = cdi.getCartFromHashMap(sessionCart);
}
}else{
//用户已登录
cartList = cdi.findByMember(sessionMember);
System.out.println(cartList);
}
if(cartList != null){
cartSize = cartList.size();
}
%>
<html>
<head>
<title>Hello Mall</title>
<link rel="shortcut icon" href="images/icon.ico">
<link rel="Bookmark" href="images/icon.ico">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link href="css/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="js/jquery.js"></script>
<script src="js/flashobj.js" type="text/javascript"></script>
</head>
<body>
<div class="main">
<div class="header">
<div class="block_header">
<div class="top_text">
<div class="UserCart" id="login" style="float:left">
<a href="cart/cart.jsp">购物车<span><%=cartSize%></span>种商品</a>
|
<a href="my/myfav.jsp">我的收藏</a>
</div>
<div class="UserPassport">
<ul>
<li><a href="my/myinfor.jsp">修改资料</a></li>
<li><a href="my/myorder.jsp">我的订单</a></li>
<li><a href="cart/cart.jsp">购物车</a></li>
<li><a href="my/my.jsp">我的账户</a></li>
<%if(sessionMember == null){ %>
<li>[<a href="passport/regist.jsp">免费注册</a>]</li>
<li>[<a href="passport/login.jsp">登录</a>]</li>
<%}else{ %>
<li>欢迎您,<b><%=sessionMember.getName() %></b>! [<a href="servlet/LogoutServlet">退出登录</a>]</li>
<%} %>
</ul>
</div>
</div>
<div class="clr"></div>
<div class="logo"><a href="index.jsp"><img src="images/logo.gif" width="244" height="141" border="0" alt="logo" /></a></div>
<div class="searchbar">
<form name="search" action="goods/list.jsp" method="post">
<div class="searchtxt">
<input name="kw" type="text" value=""/>
</div>
<input type="submit" class="searchbtn" value=""/>
</form>
</div>
<div class="clr"></div>
<div class="menu">
<ul>
<li><a href="index.jsp" class="active"><span>首页</span></a></li>
<li><a href="goods/list.jsp?type=1"><span>服饰</span></a></li>
<li><a href="goods/list.jsp?type=2"><span>数码</span></a></li>
<li><a href="goods/list.jsp?type=3"><span>居家</span></a></li>
<li><a href="goods/list.jsp?type=4"><span>美容</span></a></li>
<li><a href="goods/list.jsp?type=5"><span>图书</span></a></li>
<li><a href="goods/list.jsp?type=6"><span>户外</span></a></li>
</ul>
</div>
<div class="clr"></div>
</div>
</div>
<div class="body">
<div class="body_resize">
<div class="left_big">
<div id="flashFocus"></div>
<script type="">
var sohuFlash2 = new sohuFlash("flash/demo001.swf", "27", 522, 245, "7");
sohuFlash2.addParam("quality", "high");
sohuFlash2.addParam("wmode", "opaque");
sohuFlash2.addVariable("image","images/01.jpg|images/02.jpg|images/03.jpg|images/04.jpg|");
sohuFlash2.addVariable("url","#|#|#|#");
sohuFlash2.addVariable("info", "林俊杰第7张专辑《100天》邀您聆听|图片广告2|图片广告3|图片广告4|");
sohuFlash2.addVariable("stopTime","5000");
sohuFlash2.write("flashFocus");
</script>
<div class="left_side">
<div class="r1"></div>
<div class="r2"></div>
<div class="content">
<h2><a href="#">推荐商品</a></h2>
<%
ProductDaoImp dao=new ProductDaoImp();
GimageDaoImp gdi = new GimageDaoImp();
List listTuiJian = null;
listTuiJian = dao.getByBuyCount();
Iterator it1 = listTuiJian.iterator();
while(it1.hasNext()){
Product product = (Product)(it1.next());
String gurl = gdi.getGimageUrl(product.getProduct_id());
String gname = product.getName();
gname = ChangeStr.charNum(gname, 12);
%>
<div class="rcomGoods">
<div class="pic"> <a href="goods/item.jsp?gid=<%=product.getProduct_id() %>"><img src="<%=gurl %>" alt="<%=product.getName() %>"></a> </div>
<div class="text"> <a href="goods/item.jsp?gid=<%=product.getProduct_id() %>" title="<%=product.getName() %>"><%=gname %></a> </div>
</div>
<% }%>
<div class="clr"></div>
</div>
<div class="r2"></div>
<div class="r1"></div>
</div>
<div class="clr"></div>
<div class="type_list_title">
<div class="type_title_btn">商品分类</div>
<div class="clr"></div>
</div>
<div class="hr"></div>
<!--
<div class="t1">
<table width="710" cellpadding="0" cellspacing="0">
<tr>
<td class="n1">分类</td>
<td width="5px"></td>
<td valign="top">
<%for(int j=0; j<6; j++){ %>
<div class="t2">
<p><a href="goods/list.jsp?type=">子分类</a></p>
<span><a href="goods/list.jsp?type=3">下级分类</a></span>
<span><a href="goods/list.jsp?type=3">下级分类</a></span>
<span><a href="goods/list.jsp?type=3">下级分类</a></span>
</div>
<%} %>
</td>
</tr>
</table>
</div>
-->
<div class="t1"><table cellpadding="0" cellspacing="0" width="710"><tbody><tr><td class="n1">服饰</td><td width="5px"></td><td valign="top"><div class="t2"><p><a href="goods/list.jsp?type=8">流行女装、品牌女装</a></p><span><a href="goods/list.jsp?type=47">T恤</a></span><span><a href="goods/list.jsp?type=48">风衣</a></span><span><a href="goods/list.jsp?type=49">衬衫</a></span><span><a href="goods/list.jsp?type=50">小西装</a></span><span><a href="goods/list.jsp?type=51">毛衣</a></span><span><a href="goods/list.jsp?type=52">针织衫</a></span><span><a href="goods/list.jsp?type=53">牛仔裤</a></span><span><a href="goods/list.jsp?type=54">外套</a></span><span><a href="goods/list.jsp?type=55">半身裙</a></span><span><a href="goods/list.jsp?type=56">运动</a></span><span><a href="goods/list.jsp?type=57">欧美风</a></span><span><a href="goods/list.jsp?type=58">街头风</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=9">流行配饰、珠宝</a></p><span><a href="goods/list.jsp?type=59">翡翠</a></span><span><a href="goods/list.jsp?type=60">钻石</a></span><span><a href="goods/list.jsp?type=61">K金饰</a></span><span><a href="goods/list.jsp?type=62">925银</a></span><span><a href="goods/list.jsp?type=63">水晶对戒</a></span><span><a href="goods/list.jsp?type=64">珍珠</a></span><span><a href="goods/list.jsp?type=65">项链</a></span><span><a href="goods/list.jsp?type=66">帽子</a></span><span><a href="goods/list.jsp?type=67">围巾</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=10">各类箱包</a></p><span><a href="goods/list.jsp?type=68">流苏包</a></span><span><a href="goods/list.jsp?type=69">机车包</a></span><span><a href="goods/list.jsp?type=70">多功能包</a></span><span><a href="goods/list.jsp?type=71">钱包</a></span><span><a href="goods/list.jsp?type=72">手包</a></span><span><a href="goods/list.jsp?type=73">旅行包</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=11">女鞋、靴子</a></p><span><a href="goods/list.jsp?type=74">骑士靴</a></span><span><a href="goods/list.jsp?type=75">过膝靴</a></span><span><a href="goods/list.jsp?type=76">雪地靴</a></span><span><a href="goods/list.jsp?type=77">运动</a></span><span><a href="goods/list.jsp?type=78">高跟</a></span><span><a href="goods/list.jsp?type=79">短靴</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=12">内衣/睡衣</a></p><span><a href="goods/list.jsp?type=81">女士内衣</a></span><span><a href="goods/list.jsp?type=82">睡衣</a></span><span><a href="goods/list.jsp?type=83">家居服</a></span><span><a href="goods/list.jsp?type=84">保暖</a></span><span><a href="goods/list.jsp?type=85">男士内衣</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=13">品牌、时尚男装</a></p><span><a href="goods/list.jsp?type=86">毛衣外套</a></span><span><a href="goods/list.jsp?type=87">夹克</a></span><span><a href="goods/list.jsp?type=88">衬衫</a></span><span><a href="goods/list.jsp?type=89">正装西服</a></span></div><div class="clr"></div><div class="t2"><p><a href="goods/list.jsp?type=14">男鞋、男士配饰</a></p><span><a href="goods/list.jsp?type=90">皮鞋</a></span><span><a href="goods/list.jsp?type=91">电脑包</a></span><span><a href="goods/list.jsp?type=92">围巾</a></span><span><a href="goods/list.jsp?type=93">商务鞋</a></span><span><a href="goods/list.jsp?type=94">领带</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=15">品牌手表、情侣对表</a></p><span><a href="goods/list.jsp?type=95">卡西欧</a></span><span><a href="goods/list.jsp?type=96">西铁城</a></span><span><a href="goods/list.jsp?type=97">天梭</a></span><span><a href="goods/list.jsp?type=98">迪斯尼</a></span></div></td></tr></tbody></table></div><div class="t1"><table cellpadding="0" cellspacing="0" width="710"><tbody><tr><td class="n1">手机数码</td><td width="5px"></td><td valign="top"><div class="t2"><p><a href="goods/list.jsp?type=16">品牌手机</a></p><span><a href="goods/list.jsp?type=99">诺基亚</a></span><span><a href="goods/list.jsp?type=100">索爱</a></span><span><a href="goods/list.jsp?type=101">多普达</a></span><span><a href="goods/list.jsp?type=102">三星</a></span><span><a href="goods/list.jsp?type=103">摩托罗拉</a></span><span><a href="goods/list.jsp?type=104">LG</a></span><span><a href="goods/list.jsp?type=105">HTC</a></span><span><a href="goods/list.jsp?type=108">夏普</a></span><span><a href="goods/list.jsp?type=109">iphone</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=17">手机配件、数码配件</a></p><span><a href="goods/list.jsp?type=110">电池</a></span><span><a href="goods/list.jsp?type=111">蓝牙</a></span><span><a href="goods/list.jsp?type=112">散热</a></span><span><a href="goods/list.jsp?type=113">摄像头</a></span><span><a href="goods/list.jsp?type=114">数据线</a></span><span><a href="goods/list.jsp?type=115">读卡器</a></span><span><a href="goods/list.jsp?type=116">硅胶套</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=18">移动存储设备</a></p><span><a href="goods/list.jsp?type=117">金士顿</a></span><span><a href="goods/list.jsp?type=118">SANDISK</a></span><span><a href="goods/list.jsp?type=119">记忆棒</a></span><span><a href="goods/list.jsp?type=120">硬盘</a></span><span><a href="goods/list.jsp?type=241">闪存盘</a></span><span><a href="goods/list.jsp?type=242">存储卡</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=19">数码相机、摄像机</a></p><span><a href="goods/list.jsp?type=121">佳能Canon</a></span><span><a href="goods/list.jsp?type=122">索尼SONY</a></span><span><a href="goods/list.jsp?type=123">尼康</a></span><span><a href="goods/list.jsp?type=124">松下</a></span><span><a href="goods/list.jsp?type=125">奥林巴斯</a></span><span><a href="goods/list.jsp?type=126">三星</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=20">网络设备、无线上网</a></p><span><a href="goods/list.jsp?type=127">路由器</a></span><span><a href="goods/list.jsp?type=128">交换机</a></span><span><a href="goods/list.jsp?type=129">无线网卡</a></span><span><a href="goods/list.jsp?type=130">上网卡</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=21">笔记本</a></p><span><a href="goods/list.jsp?type=131">联想</a></span><span><a href="goods/list.jsp?type=132">华硕</a></span><span><a href="goods/list.jsp?type=133">索尼</a></span><span><a href="goods/list.jsp?type=134">戴尔</a></span><span><a href="goods/list.jsp?type=135">富士通</a></span><span><a href="goods/list.jsp?type=136">惠普</a></span><span><a href="goods/list.jsp?type=137">苹果</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=22">音响、耳机</a></p><span><a href="goods/list.jsp?type=138">ipod</a></span><span><a href="goods/list.jsp?type=139">索尼</a></span><span><a href="goods/list.jsp?type=140">魅族</a></span><span><a href="goods/list.jsp?type=141">纽曼</a></span><span><a href="goods/list.jsp?type=142">爱国者</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=23">MP3、MP4、ipod</a></p><span><a href="goods/list.jsp?type=143">PSP</a></span><span><a href="goods/list.jsp?type=144">XBOX</a></span><span><a href="goods/list.jsp?type=145">任天堂</a></span><span><a href="goods/list.jsp?type=146">NDSL</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=24">动感电玩、游戏</a></p><span><a href="goods/list.jsp?type=147">音箱</a></span><span><a href="goods/list.jsp?type=148">耳机</a></span><span><a href="goods/list.jsp?type=149">5.1声道</a></span></div></td></tr></tbody></table></div><div class="t1"><table cellpadding="0" cellspacing="0" width="710"><tbody><tr><td class="n1">居家</td><td width="5px"></td><td valign="top"><div class="t2"><p><a href="goods/list.jsp?type=25">日用品、餐饮</a></p><span><a href="goods/list.jsp?type=150">保暖器具</a></span><span><a href="goods/list.jsp?type=151">咖啡器具</a></span><span><a href="goods/list.jsp?type=152">酒具</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=26">家饰、家电</a></p><span><a href="goods/list.jsp?type=153">装饰画</a></span><span><a href="goods/list.jsp?type=154">钟表</a></span><span><a href="goods/list.jsp?type=155">沙发</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=27">五金、灯饰、安防</a></p><span><a href="goods/list.jsp?type=156">卫浴</a></span><span><a href="goods/list.jsp?type=157">茶几</a></span><span><a href="goods/list.jsp?type=158">灯具</a></span><span><a href="goods/list.jsp?type=159">家具</a></span><span><a href="goods/list.jsp?type=160">折叠椅</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=28">玩具、模型</a></p><span><a href="goods/list.jsp?type=161">Kitty</a></span><span><a href="goods/list.jsp?type=162">迪士尼</a></span><span><a href="goods/list.jsp?type=163">喜羊羊</a></span><span><a href="goods/list.jsp?type=164">遥控</a></span><span><a href="goods/list.jsp?type=165">动漫</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=29">床上用品</a></p><span><a href="goods/list.jsp?type=166">窗帘</a></span><span><a href="goods/list.jsp?type=167">电热毯</a></span><span><a href="goods/list.jsp?type=168">羽绒被</a></span><span><a href="goods/list.jsp?type=169">抱枕</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=30">妇女、儿童用品</a></p><span><a href="goods/list.jsp?type=170">婴儿车</a></span><span><a href="goods/list.jsp?type=171">奶瓶</a></span><span><a href="goods/list.jsp?type=172">营养品</a></span><span><a href="goods/list.jsp?type=173">童鞋</a></span><span><a href="goods/list.jsp?type=174">积木</a></span><span><a href="goods/list.jsp?type=175">宠物</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=31">宠物、居家植物</a></p><span><a href="goods/list.jsp?type=176">猫狗粮</a></span><span><a href="goods/list.jsp?type=177">花种</a></span><span><a href="goods/list.jsp?type=178">宠物服饰</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=32">办公用品、办公家具</a></p><span><a href="goods/list.jsp?type=179">纸张</a></span><span><a href="goods/list.jsp?type=180">计算器</a></span><span><a href="goods/list.jsp?type=181">文具</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=33">收藏品、古玩</a></p><span><a href="goods/list.jsp?type=182">钱币</a></span><span><a href="goods/list.jsp?type=183">文房四宝</a></span><span><a href="goods/list.jsp?type=184">邮票 </a></span></div></td></tr></tbody></table></div><div class="t1"><table cellpadding="0" cellspacing="0" width="710"><tbody><tr><td class="n1">美容健康</td><td width="5px"></td><td valign="top"><div class="t2"><p><a href="goods/list.jsp?type=34">护肤、美体、美妆</a></p><span><a href="goods/list.jsp?type=185">面膜</a></span><span><a href="goods/list.jsp?type=186">防晒霜</a></span><span><a href="goods/list.jsp?type=188">唇彩</a></span><span><a href="goods/list.jsp?type=189">指甲油</a></span><span><a href="goods/list.jsp?type=190">眼线</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=35">香水、熏香</a></p><span><a href="goods/list.jsp?type=192">精油</a></span><span><a href="goods/list.jsp?type=193">兰蔻</a></span><span><a href="goods/list.jsp?type=194">Boss</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=36">个人护理、保健</a></p><span><a href="goods/list.jsp?type=187">美容工具</a></span><span><a href="goods/list.jsp?type=191">美发工具</a></span><span><a href="goods/list.jsp?type=195">电吹风</a></span><span><a href="goods/list.jsp?type=196">剃须刀</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=37">零食、茶叶、饮料</a></p><span><a href="goods/list.jsp?type=197">蜜饯</a></span><span><a href="goods/list.jsp?type=198">普洱</a></span><span><a href="goods/list.jsp?type=199">巧克力</a></span><span><a href="goods/list.jsp?type=200">咖啡</a></span><span><a href="goods/list.jsp?type=201">奶茶</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=38">保健品、营养品</a></p><span><a href="goods/list.jsp?type=202">安利</a></span><span><a href="goods/list.jsp?type=203">蜂蜜</a></span><span><a href="goods/list.jsp?type=204">钙片</a></span><span><a href="goods/list.jsp?type=205">胶原蛋白</a></span></div></td></tr></tbody></table></div><div class="t1"><table cellpadding="0" cellspacing="0" width="710"><tbody><tr><td class="n1">图书</td><td width="5px"></td><td valign="top"><div class="t2"><p><a href="goods/list.jsp?type=39">书籍、杂志类、教材</a></p><span><a href="goods/list.jsp?type=206">工具书</a></span><span><a href="goods/list.jsp?type=207">漫画</a></span><span><a href="goods/list.jsp?type=208">小说</a></span><span><a href="goods/list.jsp?type=209">健康</a></span><span><a href="goods/list.jsp?type=210">报纸</a></span><span><a href="goods/list.jsp?type=211">教材</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=40">音乐、影视类</a></p><span><a href="goods/list.jsp?type=212">音乐</a></span><span><a href="goods/list.jsp?type=213">电影</a></span><span><a href="goods/list.jsp?type=214">吉他</a></span><span><a href="goods/list.jsp?type=215">戏剧</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=41">电脑软件、网络图书</a></p><span><a href="goods/list.jsp?type=216">系统软件</a></span><span><a href="goods/list.jsp?type=217">图像软件</a></span><span><a href="goods/list.jsp?type=218">杀毒</a></span></div></td></tr></tbody></table></div><div class="t1"><table cellpadding="0" cellspacing="0" width="710"><tbody><tr><td class="n1">户外</td><td width="5px"></td><td valign="top"><div class="t2"><p><a href="goods/list.jsp?type=42">球类、瑜伽、跑步</a></p><span><a href="goods/list.jsp?type=219">运动鞋</a></span><span><a href="goods/list.jsp?type=220">卫衣</a></span><span><a href="goods/list.jsp?type=221">健身</a></span><span><a href="goods/list.jsp?type=222">极限运动</a></span><span><a href="goods/list.jsp?type=223">品牌运动</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=43">露营、登山、滑雪、军用品</a></p><span><a href="goods/list.jsp?type=224">登山包</a></span><span><a href="goods/list.jsp?type=225">登山鞋</a></span><span><a href="goods/list.jsp?type=226">ZIPPO</a></span><span><a href="goods/list.jsp?type=227">瑞士军刀</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=44">汽车、改装、电动车、自行车</a></p><span><a href="goods/list.jsp?type=228">GPS</a></span><span><a href="goods/list.jsp?type=229">车载视听</a></span><span><a href="goods/list.jsp?type=230">汽车电子</a></span><span><a href="goods/list.jsp?type=231">捷安特</a></span></div></td></tr></tbody></table></div><div class="t1"><table cellpadding="0" cellspacing="0" width="710"><tbody><tr><td class="n1">其它</td><td width="5px"></td><td valign="top"><div class="t2"><p><a href="goods/list.jsp?type=45">手机充值卡、游戏的点卡</a></p><span><a href="goods/list.jsp?type=232">移动充值卡</a></span><span><a href="goods/list.jsp?type=233">联通充值卡</a></span><span><a href="goods/list.jsp?type=234">电信</a></span><span><a href="goods/list.jsp?type=235">小灵通</a></span><span><a href="goods/list.jsp?type=236">魔兽点卡</a></span><span><a href="goods/list.jsp?type=237">DNF</a></span></div><div class="t2"><p><a href="goods/list.jsp?type=46">鲜花速递 旅游度假 网店装修</a></p><span><a href="goods/list.jsp?type=238">蛋糕</a></span><span><a href="goods/list.jsp?type=239">机票</a></span><span><a href="goods/list.jsp?type=240">店庆鲜花</a></span></div></td></tr></tbody></table></div>
</div>
<div class="right_small">
<div class="r1"></div>
<div class="r2"></div>
<div class="content">
<h2>最新上架</h2>
<%
ProductDaoImp pdi_zxsj = new ProductDaoImp();
GimageDaoImp gdi_zxsj = new GimageDaoImp();
List list_zxsj=pdi_zxsj.GetLatesProduct();
for(int i=0;i<list_zxsj.size();i++){
Product pro=(Product)list_zxsj.get(i);
String image = gdi_zxsj.getGimageUrl(pro.getProduct_id());
%>
<div class="cgoods">
<div class="cimg">
<a href="goods/item.jsp?gid=<%=pro.getProduct_id() %>"><img src="<%=image%>" alt="<%=pro.getName() %>"/></a>
</div>
<div class="cname">
<a href="goods/item.jsp?gid=<%=pro.getProduct_id() %>" title="<%=pro.getName() %>"><%=pro.getName() %></a>
</div>
<div class="cprice">¥<%=pro.getPrice() %></div>
</div>
<%
}
%>
<div class="clr"></div>
</div>
<div class="r2"></div>
<div class="r1"></div>
<div style="height:10px;"></div>
<div class="r1"></div>
<div class="r2"></div>
<div class="content">
<h2>人气排行</h2>
<div>
<%
ProductDaoImp pdi_rqph = new ProductDaoImp();
GimageDaoImp gdi_rqph = new GimageDaoImp();
List li = null;
li = pdi_rqph.getByViewCount();
Iterator it_rqph = li.iterator();
int j_rqph = 1;
while(it_rqph.hasNext()){
Product product = (Product)(it_rqph.next());
String gurl = gdi_rqph.getGimageUrl(product.getProduct_id());
String gname = product.getName();
gname = ChangeStr.charNum(gname, 28);
%>
<div class="ulist <%=(j_rqph==li.size())?("noborder"):("") %>">
<%if(j_rqph == 1){ %>
<div class="uorder o_active"><%=j_rqph %></div>
<%}else{ %>
<div class="uorder"><%=j_rqph %></div>
<%} %>
<div class="uimg" <%=(j_rqph==1)?("style=\"display:block;\""):("") %>>
<a href="goods/item.jsp?gid=<%=product.getProduct_id() %>"><img src="<%=gurl %>" width="60" height="60" alt="<%=product.getName() %>"></a>
</div>
<span><a href="goods/item.jsp?gid=<%=product.getProduct_id() %>" title="<%=product.getName() %>"><%=gname %></a></span>
<div class="clr"></div>
</div>
<%
j_rqph++;
} %>
</div>
</div>
<div class="r2"></div>
<div class="r1"></div>
<div style="height:10px;"></div>
</div>
</div>
</div>
<div class="clr"></div>
<div class="footer">
<div class="footer_resize">
<p class="leftt"><br />
<a href="index.jsp">首页</a> | <a href="cart/MyCart.jsp">我的购物车</a></p>
<p class="rightt"><br />
团队成员:<a href="mailto:zixcl@163.com">赵晓蕾</a> |
<a href="mailto:zhu-yanjun@hotmail.com">朱艳军</a> |
<a href="mailto:chenjiwei1029@126.com">陈记伟</a> |
<a href="mailto:ymm880215@gmail.com">尹蒙蒙</a> |
<a href="mailto:#">王鸿儒</a> |
<a href="mailto:yingwufenghua@163.com">李文峰</a>
</p>
</div>
</div>
<div id="msgbox" style="display:none;">
<div class="msgbox">
<div class="msgtext" id="msgtext"></div>
<div class="msgclose" onclick="hideMsgbox()">关闭</div>
</div>
</div>
</div>
<script type="text/javascript">
$(function(){
$(".t1").mouseover(function(){
$(this).parent().find('table').find("td:eq(0)").removeClass("n1_active");
$(this).find("td:eq(0)").addClass("n1_active");
});
$(".t1").mouseout(function(){
$(this).parent().find('table').find("td:eq(0)").removeClass("n1_active");
});
$(".ulist").mouseover(function(){
$(this).parent().find(".uimg").hide();
$(this).parent().find(".uorder").removeClass("o_active");
$(this).find(".uimg").show();
$(this).find(".uorder").addClass("o_active");
});
});
</script>
</body>
</html>