From c9f63b4db2945354707b308366ea0fec385e0a38 Mon Sep 17 00:00:00 2001 From: Zeno <1834398598@qq.com> Date: Sun, 24 Dec 2023 19:36:39 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 - lyw/AdminRepository.java | 11 --- .../CartController.java | 71 ------------------- .../GoodsController.java | 44 ------------ .../TypeController.java | 35 --------- 5 files changed, 163 deletions(-) delete mode 100644 README.md delete mode 100644 lyw/AdminRepository.java delete mode 100644 蒋婷湘用例2和3进出库/CartController.java delete mode 100644 蒋婷湘用例2和3进出库/GoodsController.java delete mode 100644 蒋婷湘用例2和3进出库/TypeController.java diff --git a/README.md b/README.md deleted file mode 100644 index 9dab989..0000000 --- a/README.md +++ /dev/null @@ -1,2 +0,0 @@ -# Flower - diff --git a/lyw/AdminRepository.java b/lyw/AdminRepository.java deleted file mode 100644 index c18c2b4..0000000 --- a/lyw/AdminRepository.java +++ /dev/null @@ -1,11 +0,0 @@ -package com.ch.ebusiness.repository.admin; - -import java.util.List; - -import org.springframework.stereotype.Repository; - -import com.ch.ebusiness.entity.AUser; -@Repository -public interface AdminRepository { - List login(AUser aUser); -} diff --git a/蒋婷湘用例2和3进出库/CartController.java b/蒋婷湘用例2和3进出库/CartController.java deleted file mode 100644 index a289415..0000000 --- a/蒋婷湘用例2和3进出库/CartController.java +++ /dev/null @@ -1,71 +0,0 @@ -package com.ch.ebusiness.controller.before; - -import javax.servlet.http.HttpSession; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Controller; -import org.springframework.ui.Model; -import org.springframework.web.bind.annotation.RequestBody; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.ResponseBody; - -import com.ch.ebusiness.entity.Goods; -import com.ch.ebusiness.entity.Order; -import com.ch.ebusiness.service.before.CartService; - -@Controller -@RequestMapping("/cart") -public class CartController extends BeforeBaseController{ - @Autowired - private CartService cartService; - @RequestMapping("/putCart") - public String putCart(Goods goods, Model model, HttpSession session) { - return cartService.putCart(goods, model, session); - } - @RequestMapping("/focus") - @ResponseBody - public String focus(@RequestBody Goods goods, Model model, HttpSession session) { - return cartService.focus(model, session, goods.getId()); - } - @RequestMapping("/selectCart") - public String selectCart(Model model, HttpSession session, String act) { - return cartService.selectCart(model, session, act); - } - @RequestMapping("/deleteCart") - public String deleteCart(HttpSession session, Integer gid) { - return cartService.deleteCart(session, gid); - } - @RequestMapping("/clearCart") - public String clearCart(HttpSession session) { - return cartService.clearCart(session); - } - @RequestMapping("/submitOrder") - public String submitOrder(Order order, Model model, HttpSession session) { - return cartService.submitOrder(order, model, session); - } - @RequestMapping("/pay") - @ResponseBody - public String pay(@RequestBody Order order) { - return cartService.pay(order); - } - @RequestMapping("/myFocus") - public String myFocus(Model model, HttpSession session) { - return cartService.myFocus(model, session); - } - @RequestMapping("/myOder") - public String myOder(Model model, HttpSession session) { - return cartService.myOder(model, session); - } - @RequestMapping("/orderDetail") - public String orderDetail(Model model, Integer id) { - return cartService.orderDetail(model, id); - } - @RequestMapping("/userInfo") - public String userInfo() { - return "user/userInfo"; - } - @RequestMapping("/updateUpwd") - public String updateUpwd(HttpSession session, String bpwd) { - return cartService.updateUpwd(session, bpwd); - } -} diff --git a/蒋婷湘用例2和3进出库/GoodsController.java b/蒋婷湘用例2和3进出库/GoodsController.java deleted file mode 100644 index 06b3bbd..0000000 --- a/蒋婷湘用例2和3进出库/GoodsController.java +++ /dev/null @@ -1,44 +0,0 @@ -package com.ch.ebusiness.controller.admin; - -import java.io.IOException; - -import javax.servlet.http.HttpServletRequest; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Controller; -import org.springframework.ui.Model; -import org.springframework.web.bind.annotation.ModelAttribute; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.ResponseBody; - -import com.ch.ebusiness.entity.Goods; -import com.ch.ebusiness.service.admin.GoodsService; -@Controller -@RequestMapping("/goods") -public class GoodsController extends AdminBaseController{ - @Autowired - private GoodsService goodsService; - @RequestMapping("/selectAllGoodsByPage") - public String selectAllGoodsByPage(Model model, int currentPage) { - return goodsService.selectAllGoodsByPage(model, currentPage); - } - @RequestMapping("/toAddGoods") - public String toAddGoods(@ModelAttribute("goods") Goods goods, Model model) { - goods.setIsAdvertisement(0); - goods.setIsRecommend(1); - return goodsService.toAddGoods(goods, model); - } - @RequestMapping("/addGoods") - public String addGoods(@ModelAttribute("goods") Goods goods, HttpServletRequest request, String act) throws IllegalStateException, IOException { - return goodsService.addGoods(goods, request, act); - } - @RequestMapping("/detail") - public String detail(Model model, Integer id, String act) { - return goodsService.detail(model, id, act); - } - @RequestMapping("/delete") - @ResponseBody - public String delete(Integer id) { - return goodsService.delete(id); - } -} diff --git a/蒋婷湘用例2和3进出库/TypeController.java b/蒋婷湘用例2和3进出库/TypeController.java deleted file mode 100644 index 9e3b5be..0000000 --- a/蒋婷湘用例2和3进出库/TypeController.java +++ /dev/null @@ -1,35 +0,0 @@ -package com.ch.ebusiness.controller.admin; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Controller; -import org.springframework.ui.Model; -import org.springframework.web.bind.annotation.ModelAttribute; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.ResponseBody; - -import com.ch.ebusiness.entity.GoodsType; -import com.ch.ebusiness.service.admin.TypeService; - -@Controller -@RequestMapping("/type") -public class TypeController extends AdminBaseController{ - @Autowired - private TypeService typeService; - @RequestMapping("/selectAllTypeByPage") - public String selectAllTypeByPage(Model model, int currentPage) { - return typeService.selectAllTypeByPage(model, currentPage); - } - @RequestMapping("/deleteType") - @ResponseBody//返回字符串数据而不是视图 - public String delete(int id) { - return typeService.delete(id); - } - @RequestMapping("/toAddType") - public String toAddType(@ModelAttribute("goodsType") GoodsType goodsType) { - return "admin/addType"; - } - @RequestMapping("/addType") - public String addType(@ModelAttribute("goodsType") GoodsType goodsType) { - return typeService.addType(goodsType); - } -}