[免费]SpringBoot+Vue鲜花贩卖商城系统【论文+源码+SQL脚本】

[复制链接]
发表于 2025-6-21 23:52:42 | 显示全部楼层 |阅读模式
大家好,我是java1234_小锋老师,看到一个不错的SpringBoot+Vue鲜花贩卖商城系统【论文+源码+SQL脚本】,分享下哈。
项目视频演示
【免费】SpringBoot+Vue鲜花贩卖商城系统 Java结业设计_哔哩哔哩_bilibili


项目先容

随着互联网突飞猛进的发展及其对人们的生活产生至关重要的影响,线上购花,送货到家的购物方式受到了越来越多顾客的接受与喜爱。线上花卉小铺的设计与实现不仅可以带来更广泛的选择与实惠的价格,提供便利且优质的服务,而且可以更高效地宣传种植造就经验、花束的花语等花卉的相干知识,进步大家的文化素养,丰富精神世界。
本项目基于Web端,接纳了面向对象的头脑,使用的是springboot框架,选用了目前非常流行的Web应用程序开发语言Java,数据的存取接纳MYSQL进行技术支持,前端主要使用jQuery与maven。本设计主要实现了用户前台与管理员后端的相干功能,如用户注册登录、个人信息管理、购物车管理、个人订单管理、用户管理、花卉订单管理、花卉类目管理、活动公告发布等。
此次设计从系统需求分析、系统设计到系统编程和调试测试等过程,综合锻炼了自身对一个系统的设计与开发的能力。本文的工作为更为复杂的线上购花系统的建立打下了根本,完成了线上购花的根本流程,达到所需的功能性要求。

系统展示



部分代码

  1. package com.mall.sys.controller;
  2. import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
  3. import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
  4. import com.mall.common.result.R;
  5. import com.mall.sys.entity.MallGoodsType;
  6. import com.mall.sys.entity.queryVo.MallGoodsTypeQueryVo;
  7. import com.mall.sys.service.MallGoodsTypeService;
  8. import io.swagger.annotations.Api;
  9. import io.swagger.annotations.ApiOperation;
  10. import org.springframework.beans.factory.annotation.Autowired;
  11. import org.springframework.util.StringUtils;
  12. import org.springframework.web.bind.annotation.*;
  13. import org.springframework.web.bind.annotation.RestController;
  14. import java.util.HashMap;
  15. import java.util.List;
  16. import java.util.Map;
  17. import java.util.stream.Collectors;
  18. /**
  19. * 商品类型表 前端控制器
  20. */
  21. @RestController
  22. @RequestMapping("/sys/mallGoodsType")
  23. @Api(tags="商品类型表")
  24. public class MallGoodsTypeController {
  25.     @Autowired
  26.     MallGoodsTypeService iMallGoodsTypeService;
  27.         /**
  28.         * 查询商品类型表列表
  29.         */
  30.         @PostMapping("queryMallGoodsTypeList")
  31.         @ApiOperation("商品类型表列表")
  32.         public R queryMallGoodsTypeList(@RequestBody MallGoodsTypeQueryVo queryVo) {
  33.             QueryWrapper<MallGoodsType> queryWrapper=new QueryWrapper<>();
  34.             Page<MallGoodsType> page = iMallGoodsTypeService.page(queryVo.getPage(), queryWrapper);
  35.             return R.ok().data("dataList",page);
  36.         }
  37.         /**
  38.          * 保存或者更新商品类型表信息
  39.          */
  40.         @PostMapping("saveOrUpdateMallGoodsType")
  41.         @ApiOperation("保存或者更新商品类型表信息")
  42.         public R saveOrUpdateMallGoodsType(@RequestBody MallGoodsType entity) {
  43.             boolean b =true;
  44.             if(StringUtils.isEmpty(entity.getId())){
  45.                 b= iMallGoodsTypeService.save(entity);
  46.             }else{
  47.                 b=iMallGoodsTypeService.updateById(entity);
  48.             }
  49.             return R.th(b);
  50.         }
  51.         /**
  52.          * 根据id查询商品类型表信息
  53.          */
  54.         @GetMapping("getByIdMallGoodsType/{id}")
  55.         @ApiOperation("根据id查询商品类型表信息")
  56.         public R getByIdMallGoodsType(@PathVariable("id") String id) {
  57.              MallGoodsType dataMallGoodsType=  iMallGoodsTypeService.getById(id);
  58.              return R.ok().data("entity",dataMallGoodsType);
  59.         }
  60.         /**
  61.          * 根据id删除商品类型表信息
  62.          */
  63.         @DeleteMapping("removeByIdMallGoodsType/{id}")
  64.         @ApiOperation("根据id删除商品类型表信息")
  65.         public R removeByIdMallGoodsType(@PathVariable("id") String id) {
  66.             boolean effect= iMallGoodsTypeService.removeById(id);
  67.             return R.th(effect);
  68.         }
  69.         @GetMapping("mallGoodsTypeList")
  70.         public R mallGoodsTypeList(){
  71.             List<MallGoodsType> list = iMallGoodsTypeService.list();
  72.             List<Map<String, String>> collect = list.stream().map(res -> {
  73.                 Map<String, String> maps = new HashMap();
  74.                 maps.put("key", res.getTypeName());
  75.                 maps.put("value", String.valueOf(res.getId()));
  76.                 return maps;
  77.             }).collect(Collectors.toList());
  78.             return R.ok().data("dataList",collect);
  79.         }
  80. }
复制代码
  1. <!-- 首页组件-->
  2. <template>
  3.   <div class="home" id="home" name="home">
  4.     <!-- 秒杀测试 -->
  5.     <my-count-down/>
  6.     <!-- 放大镜效果 -->
  7.     <magnifying-glass/>
  8.     <!-- 轮播图 -->
  9.     <div class="block">
  10.       <el-carousel height="500px">
  11.         <el-carousel-item v-for="(item,index) in imgSUrl" :key="index">
  12.           <img style="width:100%;height:100%;" :src="item" >
  13.         </el-carousel-item>
  14.       </el-carousel>
  15.     </div>
  16.     <!-- 轮播图END -->
  17.     <div class="main-box">
  18.       <div class="main" v-for="(item,index) in applianceList" :key="item.id">
  19.         <div class="phone">
  20.           <div class="box-hd">
  21.             <div class="title">{{ item.typeName }}</div>
  22.           </div>
  23.           <div class="box-bd">
  24.             <div class="promo-list">
  25.               <router-link to v-if="phoneList[index]">
  26. <!--                <img :src="$target +phoneList[index].value"/>-->
  27. <!--                <img src="https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/ba7c4eccf6864b9101c28d2ca9cc71e2.jpg?w=1708&h=868"/>-->
  28.               </router-link>
  29.             </div>
  30.             <div class="list">
  31.               <MyList :list="item.goodsList" :isMore="true"></MyList>
  32.             </div>
  33.           </div>
  34.         </div>
  35.         <!-- 手机商品展示区域END -->
  36.       </div>
  37.     </div>
  38.   </div>
  39. </template>
  40. <script>
  41. import MagnifyingGlass from '../components/MagnifyingGlass.vue';
  42. import MyCountDown from '../components/MyCountDown.vue';
  43. export default {
  44.   components: {MyCountDown, MagnifyingGlass},
  45.   data() {
  46.     return {
  47.       carousel: "", // 轮播图数据
  48.       phoneList: "", // 手机商品列表
  49.       miTvList: "", // 小米电视商品列表
  50.       applianceList: [], // 家电商品列表
  51.       applianceHotList: "", //热门家电商品列表
  52.       accessoryList: "", //配件商品列表
  53.       accessoryHotList: "", //热门配件商品列表
  54.       protectingShellList: "", // 保护套商品列表
  55.       chargerList: "", //充电器商品列表
  56.       applianceActive: 1, // 家电当前选中的商品分类
  57.       accessoryActive: 1, // 配件当前选中的商品分类
  58.       imgSUrl:[
  59.         "https://img.tukuppt.com/bg_grid/00/15/30/f0b9cvnnPD.jpg!/fh/350",
  60.           "https://ts1.cn.mm.bing.net/th/id/R-C.79ed075aaedd7cda4ad08bdc364252cd?rik=NtuvWGnL%2bwiwzA&riu=http%3a%2f%2fwww.dmaku.com%2fdemo%2fmoban%2f2017052552491025%2fimages%2fsycase3.jpg&ehk=7P7XTGB%2b3D9S5IKXMYoPamwyTG6H1jPcHd%2fsTl7FTfg%3d&risl=&pid=ImgRaw&r=0",
  61.           "https://img.tukuppt.com/ad_preview/00/19/11/5c99f7c852662.jpg!/fw/980"
  62.       ]
  63.     };
  64.   },
  65.   watch: {
  66.     // 家电当前选中的商品分类,响应不同的商品数据
  67.     applianceActive: function (val) {
  68.       // 页面初始化的时候把applianceHotList(热门家电商品列表)直接赋值给applianceList(家电商品列表)
  69.       // 所以在切换商品列表时判断applianceHotList是否为空,为空则是第一次切换,把applianceList赋值给applianceHotList
  70.       if (this.applianceHotList == "") {
  71.         this.applianceHotList = this.applianceList;
  72.       }
  73.       if (val == 1) {
  74.         this.applianceList = this.applianceHotList;
  75.         return;
  76.       }
  77.       if (val == 2) {
  78.    
  79.         this.applianceList = this.miTvList;
  80.         return;
  81.       }
  82.     },
  83.     accessoryActive: function (val) {
  84.       if (this.accessoryHotList == "") {
  85.         this.accessoryHotList = this.accessoryList;
  86.       }
  87.       if (val == 1) {
  88.         
  89.         this.accessoryList = this.accessoryHotList;
  90.         return;
  91.       }
  92.       if (val == 2) {
  93.         this.accessoryList = this.protectingShellList;
  94.         return;
  95.       }
  96.       if (val == 3) {
  97.         this.accessoryList = this.chargerList;
  98.         return;
  99.       }
  100.     }
  101.   },
  102.   created() {
  103.     this.$axios
  104.         .get("/home/homeCarousel", {})
  105.         .then(res => {
  106.           this.carousel = res.data.data.dataList;
  107.         })
  108.         .catch(err => {
  109.           return Promise.reject(err);
  110.         });
  111.     this.getPromo()
  112.   },
  113.   methods: {
  114.     // 获取各类商品数据方法封装
  115.     getPromo() {
  116.       this.$axios
  117.           .get("/home/homeGoodsList",)
  118.           .then(res => {
  119.             console.log(res)
  120.             this.applianceList = res.data.data.dataList//商品类型
  121.             this.phoneList = res.data.data.dataMap
  122.           })
  123.           .catch(err => {
  124.             return Promise.reject(err);
  125.           });
  126.     }
  127.   }
  128. };
  129. </script>
  130. <style scoped>
  131. @import "../assets/css/index.css";
  132. </style>
复制代码
源码下载

链接:https://pan.baidu.com/s/1LSCTF9d0OZGz_rQefDuERA
提取码:1234


免责声明:如果侵犯了您的权益,请联系站长,我们会及时删除侵权内容,谢谢合作!更多信息从访问主页:qidao123.com:ToB企服之家,中国第一个企服评测及商务社交产业平台。
继续阅读请点击广告

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

×
回复

使用道具 举报

快速回复 返回顶部 返回列表