基于javaweb+mysql的宠物商城(前台、后台)

基于javaweb+mysql的宠物商城(前台、后台)

运行环境

Java≥8、MySQL≥5.7、Tomcat≥8

开发工具

eclipse/idea/myeclipse/sts等均可配置运行

适用

课程设计,大作业,毕业设计,项目练习,学习演示等

功能说明

分为前端和后台管理模块

前端用户可以登录注册、查看宠物列表、分类、详情、购买等

后台管理可以管理分类、商品、订单、留言等

前台

后台

技术框架

JavaBean MVC JSP SSM(Spring SpringMVC MyBatis) MySQL jQuery Ajax JavaScript CSS


          <trim prefix="(" suffix=")" prefixOverrides="and" >
            <foreach collection="criteria.criteria" item="criterion" >
              <choose >
                <when test="criterion.noValue" >
                  and ${criterion.condition}
                </when>
                <when test="criterion.singleValue" >
                  and ${criterion.condition} #{criterion.value}
                </when>
                <when test="criterion.betweenValue" >
                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
                </when>
                <when test="criterion.listValue" >
                  and ${criterion.condition}
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }


        public Criteria andNameLessThanOrEqualTo(String value) {
            addCriterion("name <=", value, "name");
            return (Criteria) this;
        }

        public Criteria andNameLike(String value) {
            addCriterion("name like", value, "name");
            return (Criteria) this;
        }

        public Criteria andNameNotLike(String value) {
            addCriterion("name not like", value, "name");
            return (Criteria) this;
        }

        public Criteria andNameIn(List<String> values) {
            addCriterion("name in", values, "name");
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }
	
	location.href = url;
}

function submitCheck()
{
	var condition = $("#condition").val();
	
	if (condition == null || condition == "")
	{
		return false;
	}
}

function AutoScroll(obj) 
{
    $(obj).find("ul:first").animate({
        marginTop: "-25px"
    },
    500,
    function() {
        $(this).css({
            marginTop: "0px"
        }).find("li:first").appendTo(this);
    });
									<foreach collection="criterion.value" item="listItem"
										open="(" close=")" separator=",">
										#{listItem}
									</foreach>
								</when>
							</choose>
						</foreach>
					</trim>
				</if>
			</foreach>
		</where>
	</sql>
	<sql id="Base_Column_List">
		pid, pname, market_price, shop_price, image, pdesc, is_hot,
		pdate, csid
	</sql>
	<!-- 根据csid查找商品的个数 countProducyByCsid-->
            return (Criteria) this;
        }

        public Criteria andShopPriceIsNotNull() {
            addCriterion("shop_price is not null");
            return (Criteria) this;
        }

        public Criteria andShopPriceEqualTo(Double value) {
            addCriterion("shop_price =", value, "shopPrice");
            return (Criteria) this;
        }

        public Criteria andShopPriceNotEqualTo(Double value) {
            addCriterion("shop_price <>", value, "shopPrice");
            return (Criteria) this;
        }

        public Criteria andShopPriceGreaterThan(Double value) {
            addCriterion("shop_price >", value, "shopPrice");
            return (Criteria) this;
        }

			<if test="record.accepter != null">
				#{record.accepter,jdbcType=VARCHAR},
			</if>
		</set>
		<if test="_parameter != null">
			<include refid="Update_By_Example_Where_Clause" />
		</if>
	</update>
	<update id="updateByExample" parameterType="map">
		update orders
		set oid = #{record.oid,jdbcType=INTEGER},
		money =
		#{record.money,jdbcType=DOUBLE},
		state =
		#{record.state,jdbcType=INTEGER},
		receiveInfo =
		#{record.receiveinfo,jdbcType=VARCHAR},
		phoNum =
		#{record.phonum,jdbcType=VARCHAR},
		order_time =
		#{record.orderTime,jdbcType=TIMESTAMP},
		uid =
		#{record.uid,jdbcType=INTEGER},
			</if>
			<if test="record.isHot != null">
				is_hot = #{record.isHot,jdbcType=INTEGER},
			</if>
			<if test="record.pdate != null">
				pdate = #{record.pdate,jdbcType=TIMESTAMP},
			</if>
			<if test="record.csid != null">
				csid = #{record.csid,jdbcType=INTEGER},
			</if>
		</set>
		<if test="_parameter != null">
			<include refid="Update_By_Example_Where_Clause" />
		</if>
	</update>
	<update id="updateByExample" parameterType="map">
		update product
		set pid = #{record.pid,jdbcType=INTEGER},
		pname =
		#{record.pname,jdbcType=VARCHAR},
		market_price =
		#{record.marketPrice,jdbcType=DOUBLE},
		shop_price =
		#{record.shopPrice,jdbcType=DOUBLE},
		image =
                                                                            &yen;
                                                                        </span>
                                                                        <span>
                                                                            ${p.shopPrice}
                                                                        </span>
                                                                    </span>
                                                                </p>
                                                            </li>
                                                        </c:forEach>
                                                    </c:otherwise>
                                                </c:choose>
                                             </ul>
                                        </div> 
                    
                </div>
            </div>
        </div>
     </div>
		<jsp:include page="bottomCommon.jsp"></jsp:include>
	</body>
</html>
<%@ page language="java" pageEncoding="UTF-8" %>

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
		toolbarModifier.init( onToolbarInit );
		toolbarModifier.onRefresh = onRefresh;

		CKEDITOR.document.getById( 'toolbarModifierWrapper' ).append( toolbarModifier.mainContainer );

		var toolbarTextModifier = new ToolbarConfigurator.ToolbarTextModifier( 'editor-advanced' );
		toolbarTextModifier.init( onToolbarInit );
		toolbarTextModifier.onRefresh = onRefresh;

		function onToolbarInit() {
			if ( ++done === 2 ) {
				onToolbarsDone();

				positionSticky.watch( CKEDITOR.document.findOne( '.toolbar' ), function() {
					return mode === 'advanced';
				} );
			}
		}

		function onToolbarsDone() {
			if ( mode === 'basic' ) {
				toggleModeBasic( false );
			} else {
			CKEDITOR.tools.enableHtml5Elements( document );
	</script>
	<link rel="stylesheet" href="lib/codemirror/codemirror.css">
	<link rel="stylesheet" href="lib/codemirror/show-hint.css">
	<link rel="stylesheet" href="lib/codemirror/neo.css">
	<link rel="stylesheet" href="css/fontello.css">
	<link rel="stylesheet" href="../css/samples.css">
</head>
<body id="toolbar">

<nav class="navigation-a">
	<div class="grid-container">
		<ul class="navigation-a-left grid-width-70">
			<li><a href="http://ckeditor.com">Project Homepage</a></li>
			<li><a href="http://dev.ckeditor.com/">I found a bug</a></li>
			<li><a href="http://github.com/ckeditor/ckeditor-dev" class="icon-pos-right icon-navigation-a-github">Fork CKEditor on GitHub</a></li>
		</ul>
		<ul class="navigation-a-right grid-width-30">
			<li><a href="http://ckeditor.com/blog-list">CKEditor Blog</a></li>
            addCriterion("password =", value, "password");
            return (Criteria) this;
        }

        public Criteria andPasswordNotEqualTo(String value) {
            addCriterion("password <>", value, "password");
            return (Criteria) this;
        }

        public Criteria andPasswordGreaterThan(String value) {
            addCriterion("password >", value, "password");
            return (Criteria) this;
        }

        public Criteria andPasswordGreaterThanOrEqualTo(String value) {
            addCriterion("password >=", value, "password");
            return (Criteria) this;
        }
						styles: true,
						classes: true
					}
				},
				disallowedContent: 'img a'
			} );

		</script>
	</div>

	<div id="footer">
		<hr>
		<p>
			CKEditor - The text editor for the Internet - <a class="samples" href="http://ckeditor.com/">http://ckeditor.com</a>
		</p>

请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述
请添加图片描述

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值