提交 437efd99 编写于 作者: RunAtWorld's avatar RunAtWorld

在线商城

上级 c2ea84cc
HELP.md
target/
!.mvn/wrapper/maven-wrapper.jar
!**/src/main/**
!**/src/test/**
### STS ###
.apt_generated
.classpath
.factorypath
.project
.settings
.springBeans
.sts4-cache
### IntelliJ IDEA ###
.idea
*.iws
*.iml
*.ipr
### NetBeans ###
/nbproject/private/
/nbbuild/
/dist/
/nbdist/
/.nb-gradle/
build/
### VS Code ###
.vscode/
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.2.7.RELEASE</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<groupId>com.southwind</groupId>
<artifactId>staticdemo</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>mmall</name>
<description>Demo project for Spring Boot</description>
<properties>
<java.version>1.8</java.version>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-thymeleaf</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
<exclusions>
<exclusion>
<groupId>org.junit.vintage</groupId>
<artifactId>junit-vintage-engine</artifactId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
</project>
package com.southwind.staticdemo;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class StaticdemoApplication {
public static void main(String[] args) {
SpringApplication.run(StaticdemoApplication.class, args);
}
}
package com.southwind.staticdemo.controller;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import javax.servlet.http.HttpSession;
@Controller
public class RedirectController {
@GetMapping("/{url}")
public String redirect(@PathVariable("url") String url){
return url;
}
@GetMapping("/session")
public String session(HttpSession session){
session.setAttribute("name","张三");
return "common";
}
}
spring:
thymeleaf:
prefix: classpath:/static/
suffix: .html
\ No newline at end of file
<html xmlns:th="http://www.thymeleaf.org">
<!-- js+css -->
<div th:fragment="source">
<script type="text/javascript" src="/js/jquery-1.8.3.min.js"></script>
<link type="text/css" rel="stylesheet" href="/css/style.css"/>
</div>
<!-- 头文件 -->
<div th:fragment="header">
<!-- top -->
<div class="soubg">
<div class="sou">
<span class="s_city_b">
<span class="fl">送货至:</span>
<span class="s_city">
<span id="s_city_title">四川</span>
<div class="s_city_bg">
<div class="s_city_t"></div>
<div class="s_city_c">
<h2>请选择所在的收货地区</h2>
<table border="0" class="c_tab" style="width:235px; margin-top:10px;" cellspacing="0" cellpadding="0">
<tr>
<th>A</th>
<td class="c_h"><span>安徽</span><span>澳门</span></td>
</tr>
<tr>
<th>B</th>
<td class="c_h"><span>北京</span></td>
</tr>
<tr>
<th>C</th>
<td class="c_h"><span>重庆</span></td>
</tr>
<tr>
<th>F</th>
<td class="c_h"><span>福建</span></td>
</tr>
<tr>
<th>G</th>
<td class="c_h"><span>广东</span><span>广西</span><span>贵州</span><span>甘肃</span></td>
</tr>
<tr>
<th>H</th>
<td class="c_h"><span>河北</span><span>河南</span><span>黑龙江</span><span>海南</span><span>湖北</span><span>湖南</span></td>
</tr>
<tr>
<th>J</th>
<td class="c_h"><span>江苏</span><span>吉林</span><span>江西</span></td>
</tr>
<tr>
<th>L</th>
<td class="c_h"><span>辽宁</span></td>
</tr>
<tr>
<th>N</th>
<td class="c_h"><span>内蒙古</span><span>宁夏</span></td>
</tr>
<tr>
<th>Q</th>
<td class="c_h"><span>青海</span></td>
</tr>
<tr>
<th>S</th>
<td class="c_h"><span>上海</span><span>山东</span><span>山西</span><span class="c_check">四川</span><span>陕西</span></td>
</tr>
<tr>
<th>T</th>
<td class="c_h"><span>台湾</span><span>天津</span></td>
</tr>
<tr>
<th>X</th>
<td class="c_h"><span>西藏</span><span>香港</span><span>新疆</span></td>
</tr>
<tr>
<th>Y</th>
<td class="c_h"><span>云南</span></td>
</tr>
<tr>
<th>Z</th>
<td class="c_h"><span>浙江</span></td>
</tr>
</table>
</div>
</div>
</span>
</span>
<span class="fr">
<span class="fl">你好,请<a href="/login.html" style="color:#ff4e00;">登录</a>&nbsp;<a href="/register.jsp" style="color:#ff4e00;">免费注册</a>&nbsp;&nbsp;</span>
<span class="fl"><a href="/userInfo.html" >欢迎回来,张三</a>&nbsp;|&nbsp;<a href="/orderList.html">我的订单</a>&nbsp;</span>
<span class="fl">|&nbsp;<a>注销</a></span>
</span>
</div>
</div>
<div id="fade1" class="black_overlay"></div>
<div id="MyDiv1" class="white_content">
<div class="white_d">
<div class="notice_t">
<span class="fr" style="margin-top:10px; cursor:pointer;" onclick="CloseDiv_1('MyDiv1','fade1')"><img src="/images/close.gif" /></span>
</div>
<div class="notice_c">
<table border="0" align="center" cellspacing="0" cellpadding="0">
<tr valign="top">
<td width="40"><img src="/images/suc.png"></td>
<td>
<span style="color:#3e3e3e; font-size:18px; font-weight:bold;" id="showMessage">操作成功</span><br />
</td>
</tr>
</table>
</div>
</div>
</div>
<!-- top -->
<!-- search -->
<div class="top">
<div class="logo">
<a href="/main.html"><img src="/images/logo.png" style="width: 230px;border:0px solid red;"></a>
</div>
<div class="search">
<form action="/productList.html" method="post">
<input type="text" name="keyWord" class="s_ipt">
<input type="submit" value="搜索" class="s_btn">
</form>
</div>
<div class="i_car">
<a href="/orderList.html">
<div class="car_t">
购物车 [
<span>3</span>
]
</div>
</a>
<div class="car_bg">
<div class="un_login">我的购物车</div>
<ul class="cars">
<li>
<div class="img"><a href="/productDetail.html"><img src="/images/mat_1.jpg" width="58" height="58" /></a></div>
<div class="name"><a href="/productDetail.html">相机</a></div>
<div class="price"><font color="#ff4e00">¥300</font> X <span class="quantity">2</span> = <span class="cost">600</span></div>
</li>
<li>
<div class="img"><a href="/productDetail.html"><img src="/images/mat_1.jpg" width="58" height="58" /></a></div>
<div class="name"><a href="/productDetail.html">相机</a></div>
<div class="price"><font color="#ff4e00">¥300</font> X <span class="quantity">2</span> = <span class="cost">600</span></div>
</li>
<li>
<div class="img"><a href="/productDetail.html"><img src="/images/mat_1.jpg" width="58" height="58" /></a></div>
<div class="name"><a href="/productDetail.html">相机</a></div>
<div class="price"><font color="#ff4e00">¥300</font> X <span class="quantity">2</span> = <span class="cost">600</span></div>
</li>
</ul>
<div class="price_sum">共计&nbsp;<font color="#ff4e00"></font><span id="totalCost"></span></div>
<div class="price_a"><a href="/settlement1.html">去结算</a></div>
</div>
</div>
</div>
<!-- search -->
<script type="text/javascript">
$(function(){
//购物车总价
var array = $(".cost");
var totalCost = 0;
for(var i = 0;i < array.length;i++){
var val = parseInt($(".cost").eq(i).html());
totalCost += val;
}
$("#totalCost").html(""+totalCost);
});
</script>
</div>
<!-- 商品类目 -->
<div th:fragment="category">
<div class="menu_bg">
<div class="menu">
<div class="nav">
<div class="nav_t">全部商品分类</div>
<div class="leftNav">
<ul>
<li>
<div class="fj">
<span class="n_img"></span> <span class="fl" >一级分类1</span>
</div>
<div class="zj">
<div class="zj_l">
<div class="zj_l_c">
<h2>
<a href="/productList.html">二级分类1</a>
</h2>
<a href="/productList.html">三级分类1</a>
<a href="/productList.html">三级分类1</a>
<a href="/productList.html">三级分类1</a>
</div>
<div class="zj_l_c">
<h2>
<a href="/productList.html">二级分类2</a>
</h2>
<a href="/productList.html">三级分类2</a>
<a href="/productList.html">三级分类2</a>
<a href="/productList.html">三级分类2</a>
</div>
</div>
</div>
</li>
<li>
<div class="fj">
<span class="n_img"></span> <span class="fl" >一级分类1</span>
</div>
<div class="zj">
<div class="zj_l">
<div class="zj_l_c">
<h2>
<a href="/productList.html">二级分类1</a>
</h2>
<a href="/productList.html">三级分类1</a>
<a href="/productList.html">三级分类1</a>
<a href="/productList.html">三级分类1</a>
</div>
<div class="zj_l_c">
<h2>
<a href="/productList.html">二级分类2</a>
</h2>
<a href="/productList.html">三级分类2</a>
<a href="/productList.html">三级分类2</a>
<a href="/productList.html">三级分类2</a>
</div>
</div>
</div>
</li>
</ul>
</div>
</div>
<ul class="menu_r">
<li><a href="/main.html">首页</a></li>
<li>
<a href="/productList.html">一级分类</a>
</li>
</ul>
</div>
</div>
<script type="text/javascript">
$(function(){
//商品类目
$(".leftNav ul li").hover(
function(){
$(this).find(".fj").addClass("nuw");
$(this).find(".zj").show();
}
,
function(){
$(this).find(".fj").removeClass("nuw");
$(this).find(".zj").hide();
}
)
});
</script>
</div>
<!-- 底部 -->
<div th:fragment="footer">
<div class="b_btm_bg b_btm_c" id="footer">
<div class="b_btm">
<table border="0" style="width:210px; height:62px; float:left; margin-left:75px; margin-top:30px;" cellspacing="0" cellpadding="0">
<tr>
<td width="72"><img src="/images/b1.png" width="62" height="62" /></td>
<td><h2>正品保障</h2>正品行货 放心购买</td>
</tr>
</table>
<table border="0" style="width:210px; height:62px; float:left; margin-left:75px; margin-top:30px;" cellspacing="0" cellpadding="0">
<tr>
<td width="72"><img src="/images/b2.png" width="62" height="62" /></td>
<td><h2>满38包邮</h2>满38包邮 免运费</td>
</tr>
</table>
<table border="0" style="width:210px; height:62px; float:left; margin-left:75px; margin-top:30px;" cellspacing="0" cellpadding="0">
<tr>
<td width="72"><img src="/images/b3.png" width="62" height="62" /></td>
<td><h2>天天低价</h2>天天低价 畅选无忧</td>
</tr>
</table>
<table border="0" style="width:210px; height:62px; float:left; margin-left:75px; margin-top:30px;" cellspacing="0" cellpadding="0">
<tr>
<td width="72"><img src="/images/b4.png" width="62" height="62" /></td>
<td><h2>准时送达</h2>收货时间由你做主</td>
</tr>
</table>
</div>
</div>
<div class="b_nav">
<dl>
<dt><a href="#">新手上路</a></dt>
<dd><a href="#">售后流程</a></dd>
<dd><a href="#">购物流程</a></dd>
<dd><a href="#">订购方式</a></dd>
<dd><a href="#">隐私声明</a></dd>
<dd><a href="#">推荐分享说明</a></dd>
</dl>
<dl>
<dt><a href="#">配送与支付</a></dt>
<dd><a href="#">货到付款区域</a></dd>
<dd><a href="#">配送支付查询</a></dd>
<dd><a href="#">支付方式说明</a></dd>
</dl>
<dl>
<dt><a href="#">会员中心</a></dt>
<dd><a href="#">资金管理</a></dd>
<dd><a href="#">我的收藏</a></dd>
<dd><a href="#">我的订单</a></dd>
</dl>
<dl>
<dt><a href="#">服务保证</a></dt>
<dd><a href="#">退换货原则</a></dd>
<dd><a href="#">售后服务保证</a></dd>
<dd><a href="#">产品质量保证</a></dd>
</dl>
<dl>
<dt><a href="#">联系我们</a></dt>
<dd><a href="#">网站故障报告</a></dd>
<dd><a href="#">购物咨询</a></dd>
<dd><a href="#">投诉与建议</a></dd>
</dl>
<div class="b_tel_bg">
<a href="#" class="b_sh1">新浪微博</a>
<a href="#" class="b_sh2">腾讯微博</a>
<p>
服务热线:<br />
<span>400-123-4567</span>
</p>
</div>
<div class="b_er">
<div class="b_er_c"><img src="/images/er.gif" width="118" height="118" /></div>
<img src="/images/ss.png" />
</div>
</div>
</div>
<div th:fragment="permit">
<div class="btmbg">
<div class="btm">
备案/许可证编号:蜀ICP备12009302号-1-www.dingguagua.com Copyright © 2015-2018 尤洪商城网 All Rights Reserved. 复制必究 , Technical Support: Dgg Group <br />
<img src="/images/b_1.gif" width="98" height="33" /><img src="/images/b_2.gif" width="98" height="33" /><img src="/images/b_3.gif" width="98" height="33" /><img src="/images/b_4.gif" width="98" height="33" /><img src="/images/b_5.gif" width="98" height="33" /><img src="/images/b_6.gif" width="98" height="33" />
</div>
</div>
</div>
\ No newline at end of file
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册