資源簡介
項目案例之網上書店全套源程序代碼,包括:數據庫,webContent,src````

代碼片段和文件信息
package?csai.bean;
import?java.util.*;
import?java.io.*;
public?class?buyCar?implements?Serializable
{??
??public?Hashtable?myGoods=new?Hashtable();
??public?void?addGoods(Long?Goods_idint?Goods_Count)
???{?//把商品加入購物車
????if(myGoods.containsKey(Goods_id))
????{//購物車中存在此商品則累加個數
??????int?Temp_Count=((Integer)myGoods.get(Goods_id)).intValue();
??????Temp_Count=Temp_Count+Goods_Count;
??????myGoods.put(Goods_idnew?Integer(Temp_Count));
????}else
????{//購物車中不存在此商品
??????myGoods.put(Goods_idnew?Integer(Goods_Count));
?????}
???}
???public?boolean?minusGoods(Long?Goods_idint?Goods_Count)
???{?//把商品從購物車中拿出
????if(myGoods.containsKey(Goods_id))
????{//購物車中存在此商品則減少個數
??????int?Temp_Count=((Integer)myGoods.get(Goods_id)).intValue();
??????Temp_Count=Temp_Count-Goods_Count;
??????if(Temp_Count<=0)??
????????deleteGoods(Goods_id);
??????else
????????myGoods.put(Goods_idnew?Integer(Temp_Count));
??????return?true;
????}?else
????{//購物車中不存在此商品
??????return?false;
?????}
???}
??public?Hashtable?listMyGoods()
???{//得到購物車中所有商品
?????return?myGoods;
???}?
??public?boolean?deleteGoods(Long?Goods_id)
???{//從購物車中刪除一件商品
?????if(myGoods.remove(Goods_id)==null)
???????return?false;
?????else
???????return?true;
???}??
??public?Hashtable?getMyGoods()?{
?? return?myGoods;
??}
??public?void?setMyGoods(Hashtable?myGoods)?{
????this.myGoods?=?myGoods;
??}
}
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
????......R??????1494??2007-08-06?16:42??項目案例之網上書店\src\csai\bean\buyCar.java
????......R??????1819??2007-08-06?16:42??項目案例之網上書店\src\csai\tag\acceptBookImgTag.java
????......R???????854??2007-08-06?16:42??項目案例之網上書店\src\csai\tag\addGoodsTag.java
????......R???????924??2007-08-06?16:42??項目案例之網上書店\src\csai\tag\csaiCertPicTag.java
????......R??????2522??2007-08-06?16:42??項目案例之網上書店\src\csai\tag\haveBookImgTag.java
????......R??????2203??2007-08-06?16:42??項目案例之網上書店\src\csai\tag\makeCertPic.java
????......R???????859??2007-08-06?16:42??項目案例之網上書店\src\csai\tag\minusGoosTag.java
????......R??????2518??2007-08-06?16:42??項目案例之網上書店\src\csai\tag\showBookImgTag.java
????......R???????132??2007-08-06?16:42??項目案例之網上書店\webContent\admin\adminmoduledown.jsp
????......R???????356??2007-08-06?16:42??項目案例之網上書店\webContent\admin\adminmoduleup.jsp
????......R???????755??2007-08-06?16:42??項目案例之網上書店\webContent\admin\banner.jsp
????......R???????312??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\acceptImg.jsp
????......R???????619??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\addbook.jsp
????......R??????4982??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\bookview.jsp
????......R???????635??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\deleteBook.jsp
????......R??????1508??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\insertBook.jsp
????......R??????4844??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\modibook.jsp
????......R???????185??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\showbookimg.jsp
????......R??????1159??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\updateBook.jsp
????......R??????1531??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\updateBookAction.jsp
????......R??????2190??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\uploadpic.jsp
????......R??????4640??2007-08-06?16:42??項目案例之網上書店\webContent\admin\book\uploadpicbook.jsp
????......R??????4189??2007-08-06?16:42??項目案例之網上書店\webContent\admin\booktype\booktypeview.jsp
????......R???????755??2007-08-06?16:42??項目案例之網上書店\webContent\admin\booktype\deleteBookType.jsp
????......R??????1610??2007-08-06?16:42??項目案例之網上書店\webContent\admin\booktype\updatebooktype.jsp
????......R???????813??2007-08-06?16:42??項目案例之網上書店\webContent\admin\booktype\updateTypeAction.jsp
????......R???????373??2007-08-06?16:42??項目案例之網上書店\webContent\admin\bottom.jsp
????......R???????305??2007-08-06?16:42??項目案例之網上書店\webContent\admin\common\failure.jsp
????......R??????1035??2007-08-06?16:42??項目案例之網上書店\webContent\admin\common\page.jsp
????......R???????951??2007-08-06?16:42??項目案例之網上書店\webContent\admin\common\page.txt
............此處省略121個文件信息
評論
共有 條評論