当前位置: 首页 > news >正文

音乐系统java在线音乐网站基于springboot+vue的音乐系统带万字文档

文章目录

  • 音乐系统
    • 一、项目演示
    • 二、项目介绍
    • 三、万字项目文档
    • 四、部分功能截图
    • 五、部分代码展示
    • 六、底部获取项目源码和万字论文参考(9.9¥带走)

音乐系统

一、项目演示

在线音乐系统

二、项目介绍

基于springboot+vue的前后端分离在线音乐系统

登录角色 : 用户、管理员

用户:歌单分类分页界面,歌手分类分页界面,我的音乐查看收藏歌曲,搜索音乐,可根据歌手、歌曲、歌单名进行搜索;头像修改、用户信息修改,歌曲播放,进度条拉伸,歌词加载,歌曲收藏,歌曲下载,登录、注册等

管理员:系统首页展示统计数据,用户管理,歌手管理,歌曲管理(修改音源,歌词,后台评论),上传音乐

项目技术
语言:java
前端技术:Vue、 ELementUI、echarts
后端技术:SpringBoot、Mybatis-Plus
数据库:MySQL

三、万字项目文档

在这里插入图片描述

在这里插入图片描述

四、部分功能截图

在这里插入图片描述

在这里插入图片描述

在这里插入图片描述

在这里插入图片描述

在这里插入图片描述

在这里插入图片描述

在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

五、部分代码展示

package com.rabbiter.music.controller;import com.alibaba.fastjson.JSONObject;
import com.rabbiter.music.pojo.Collect;
import com.rabbiter.music.service.CollectService;
import com.rabbiter.music.utils.Consts;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
import javax.servlet.http.HttpServletRequest;/*** 收藏控制类*/
@RestController
@RequestMapping("/collect")
@Api(tags = "收藏")
public class CollectController {@Autowiredprivate CollectService CollectService;/*** 添加收藏*/@ApiOperation(value = "添加收藏、取消收藏")@RequestMapping(value = "/add",method = RequestMethod.POST)public Object addCollect(HttpServletRequest request){JSONObject jsonObject = new JSONObject();String userId = request.getParameter("userId");           //用户idString type = request.getParameter("type");               //收藏类型(0歌曲1歌单)String songId = request.getParameter("songId");           //歌曲idif(songId==null||songId.equals("")){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"收藏歌曲为空");return jsonObject;}if(CollectService.existSongId(Integer.parseInt(userId),Integer.parseInt(songId))){CollectService.deleteByUserIdSongId(Integer.parseInt(userId),Integer.parseInt(songId));jsonObject.put(Consts.CODE,2);jsonObject.put(Consts.MSG,"取消收藏成功");return jsonObject;}//保存到收藏的对象中Collect Collect = new Collect();Collect.setUserId(Integer.parseInt(userId));Collect.setType(new Byte(type));Collect.setSongId(Integer.parseInt(songId));boolean flag = CollectService.insert(Collect);if(flag){   //保存成功jsonObject.put(Consts.CODE,1);jsonObject.put(Consts.MSG,"收藏成功");return jsonObject;}jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"收藏失败");return jsonObject;}/*** 删除收藏*/@ApiOperation(value = "取消收藏")@RequestMapping(value = "/delete",method = RequestMethod.GET)public Object deleteCollect(HttpServletRequest request){String userId = request.getParameter("userId");           //用户idString songId = request.getParameter("songId");           //歌曲idboolean flag = CollectService.deleteByUserIdSongId(Integer.parseInt(userId),Integer.parseInt(songId));return flag;}/*** 查询所有收藏*/@ApiOperation(value = "查看所有收藏")@RequestMapping(value = "/allCollect",method = RequestMethod.GET)public Object allCollect(HttpServletRequest request){return CollectService.allCollect();}/*** 查询某个用户的收藏列表*/@ApiOperation(value = "用户的收藏列表")@RequestMapping(value = "/collectOfUserId",method = RequestMethod.GET)public Object collectOfUserId(HttpServletRequest request){String userId = request.getParameter("userId");          //用户idreturn CollectService.collectOfUserId(Integer.parseInt(userId));}}
package com.rabbiter.music.controller;import com.alibaba.fastjson.JSONObject;
import com.rabbiter.music.pojo.Consumer;
import com.rabbiter.music.service.ConsumerService;
import com.rabbiter.music.utils.Consts;
import com.rabbiter.music.utils.PathUtils;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletRequest;
import java.io.File;
import java.io.IOException;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;/*** 前端用户控制类*/
@RestController
@RequestMapping("/consumer")
@Api(tags = "用户")
public class ConsumerController {@Autowiredprivate ConsumerService consumerService;/*** 添加前端用户*/@ApiOperation(value = "注册、添加前端用户")@RequestMapping(value = "/add",method = RequestMethod.POST)public Object addConsumer(HttpServletRequest request){JSONObject jsonObject = new JSONObject();String username = request.getParameter("username").trim();     //账号String password = request.getParameter("password").trim();     //密码String sex = request.getParameter("sex").trim();               //性别String phoneNum = request.getParameter("phoneNum").trim();     //手机号String email = request.getParameter("email").trim();           //电子邮箱String birth = request.getParameter("birth").trim();           //生日String introduction = request.getParameter("introduction").trim();//签名String location = request.getParameter("location").trim();      //地区String avator = request.getParameter("avator").trim();          //头像地址if(username==null||username.equals("")){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"用户名不能为空");return jsonObject;}Consumer consumer1 = consumerService.getByUsername(username);if(consumer1!=null){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"用户名已存在");return jsonObject;}if(password==null||password.equals("")){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"密码不能为空");return jsonObject;}//把生日转换成Date格式DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");Date birthDate = new Date();try {birthDate = dateFormat.parse(birth);} catch (ParseException e) {e.printStackTrace();}//保存到前端用户的对象中Consumer consumer = new Consumer();consumer.setUsername(username);consumer.setPassword(password);consumer.setSex(new Byte(sex));consumer.setPhoneNum(phoneNum);consumer.setEmail(email);consumer.setBirth(birthDate);consumer.setIntroduction(introduction);consumer.setLocation(location);consumer.setAvator(avator);boolean flag = consumerService.insert(consumer);if(flag){   //保存成功jsonObject.put(Consts.CODE,1);jsonObject.put(Consts.MSG,"添加成功");return jsonObject;}jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"添加失败");return jsonObject;}/*** 修改前端用户*/@ApiOperation(value = "修改前端用户")@RequestMapping(value = "/update",method = RequestMethod.POST)public Object updateConsumer(HttpServletRequest request){JSONObject jsonObject = new JSONObject();String id = request.getParameter("id").trim();          //主键String username = request.getParameter("username").trim();     //账号String password = request.getParameter("password").trim();     //密码String sex = request.getParameter("sex").trim();               //性别String phoneNum = request.getParameter("phoneNum").trim();     //手机号String email = request.getParameter("email").trim();           //电子邮箱String birth = request.getParameter("birth").trim();           //生日String introduction = request.getParameter("introduction").trim();//签名String location = request.getParameter("location").trim();      //地区if(username==null||username.equals("")){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"用户名不能为空");return jsonObject;}if(password==null||password.equals("")){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"密码不能为空");return jsonObject;}//把生日转换成Date格式DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");Date birthDate = new Date();try {birthDate = dateFormat.parse(birth);} catch (ParseException e) {e.printStackTrace();}//保存到前端用户的对象中Consumer consumer = new Consumer();consumer.setId(Integer.parseInt(id));consumer.setUsername(username);consumer.setPassword(password);consumer.setSex(new Byte(sex));consumer.setPhoneNum(phoneNum);consumer.setEmail(email);consumer.setBirth(birthDate);consumer.setIntroduction(introduction);consumer.setLocation(location);boolean flag = consumerService.update(consumer);if(flag){   //保存成功jsonObject.put(Consts.CODE,1);jsonObject.put(Consts.MSG,"修改成功");return jsonObject;}jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"修改失败");return jsonObject;}/*** 删除前端用户*/@ApiOperation(value = "删除前端用户")@RequestMapping(value = "/delete",method = RequestMethod.GET)public Object deleteConsumer(HttpServletRequest request){String id = request.getParameter("id").trim();          //主键boolean flag = consumerService.delete(Integer.parseInt(id));return flag;}/*** 根据主键查询整个对象*/@ApiOperation(value = "根据主键查询整个对象")@RequestMapping(value = "/selectByPrimaryKey",method = RequestMethod.GET)public Object selectByPrimaryKey(HttpServletRequest request){String id = request.getParameter("id").trim();          //主键return consumerService.selectByPrimaryKey(Integer.parseInt(id));}/*** 查询所有前端用户*/@ApiOperation(value = "查询所有前端用户")@RequestMapping(value = "/allConsumer",method = RequestMethod.GET)public Object allConsumer(HttpServletRequest request){return consumerService.allConsumer();}/*** 更新前端用户图片*/@ApiOperation(value = "更新前端用户图片")@RequestMapping(value = "/updateConsumerPic",method = RequestMethod.POST)public Object updateConsumerPic(@RequestParam("file") MultipartFile avatorFile, @RequestParam("id")int id){JSONObject jsonObject = new JSONObject();if(avatorFile.isEmpty()){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"文件上传失败");return jsonObject;}//文件名=当前时间到毫秒+原来的文件名String fileName = System.currentTimeMillis()+avatorFile.getOriginalFilename();//文件路径String filePath = PathUtils.getClassLoadRootPath() +"/userImages/";//如果文件路径不存在,新增该路径File file1 = new File(filePath);if(!file1.exists()){file1.mkdir();}//实际的文件地址File dest = new File(filePath + fileName);//存储到数据库里的相对文件地址String storeAvatorPath = "/userImages/"+fileName;try {avatorFile.transferTo(dest);Consumer consumer = new Consumer();consumer.setId(id);consumer.setAvator(storeAvatorPath);boolean flag = consumerService.update(consumer);if(flag){jsonObject.put(Consts.CODE,1);jsonObject.put(Consts.MSG,"上传成功");jsonObject.put("avator",storeAvatorPath);return jsonObject;}jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"上传失败");return jsonObject;} catch (IOException e) {jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"上传失败"+e.getMessage());}finally {return jsonObject;}}/*** 前端用户登录*/@ApiOperation(value = "前端用户登录")@RequestMapping(value = "/login",method = RequestMethod.POST)public Object login(HttpServletRequest request){JSONObject jsonObject = new JSONObject();String username = request.getParameter("username").trim();     //账号String password = request.getParameter("password").trim();     //密码if(username==null||username.equals("")){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"用户名不能为空");return jsonObject;}if(password==null||password.equals("")){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"密码不能为空");return jsonObject;}//保存到前端用户的对象中Consumer consumer = new Consumer();consumer.setUsername(username);consumer.setPassword(password);boolean flag = consumerService.verifyPassword(username,password);if(flag){   //验证成功jsonObject.put(Consts.CODE,1);jsonObject.put(Consts.MSG,"登录成功");jsonObject.put("userMsg",consumerService.getByUsername(username));return jsonObject;}jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"用户名或密码错误");return jsonObject;}
}
package com.rabbiter.music.controller;import com.alibaba.fastjson.JSONObject;
import com.rabbiter.music.pojo.Song;
import com.rabbiter.music.service.SongService;
import com.rabbiter.music.utils.Consts;
import com.rabbiter.music.utils.PathUtils;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletRequest;
import java.io.File;
import java.io.IOException;/*** 歌曲管理controller*/
@RestController
@RequestMapping("/song")
@Api(tags = "歌曲管理")
public class SongController {@Autowiredprivate SongService songService;/*** 添加歌曲*/@ApiOperation(value = "添加歌曲")@RequestMapping(value = "/add",method = RequestMethod.POST)public Object addSong(HttpServletRequest request, @RequestParam("file")MultipartFile mpFile){JSONObject jsonObject = new JSONObject();//获取前端传来的参数String singerId = request.getParameter("singerId").trim();  //所属歌手idString name = request.getParameter("name").trim();          //歌名String introduction = request.getParameter("introduction").trim();          //简介String pic = "/img/songPic/tubiao.jpg";                     //默认图片String lyric = request.getParameter("lyric").trim();     //歌词//上传歌曲文件if(mpFile.isEmpty()){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"歌曲上传失败");return jsonObject;}//文件名=当前时间到毫秒+原来的文件名String fileName = System.currentTimeMillis()+mpFile.getOriginalFilename();//文件路径String filePath = PathUtils.getClassLoadRootPath() + "/song/";//如果文件路径不存在,新增该路径File file1 = new File(filePath);if(!file1.exists()){file1.mkdir();}//实际的文件地址File dest = new File(filePath + fileName);//存储到数据库里的相对文件地址String storeUrlPath = "/song/"+fileName;try {mpFile.transferTo(dest);Song song = new Song();song.setSingerId(Integer.parseInt(singerId));song.setName(name);song.setIntroduction(introduction);song.setPic(pic);song.setLyric(lyric);song.setUrl(storeUrlPath);boolean flag = songService.insert(song);if(flag){jsonObject.put(Consts.CODE,1);jsonObject.put(Consts.MSG,"保存成功");jsonObject.put("avator",storeUrlPath);return jsonObject;}jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"保存失败");return jsonObject;} catch (IOException e) {jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"保存失败"+e.getMessage());}finally {return jsonObject;}}/*** 根据歌手id查询歌曲*/@ApiOperation(value = "根据歌手id查询歌曲")@RequestMapping(value = "/singer/detail",method = RequestMethod.GET)public Object songOfSingerId(HttpServletRequest request){String singerId = request.getParameter("singerId");return songService.songOfSingerId(Integer.parseInt(singerId));}/*** 修改歌曲*/@ApiOperation(value = "修改歌曲")@RequestMapping(value = "/update",method = RequestMethod.POST)public Object updateSong(HttpServletRequest request){JSONObject jsonObject = new JSONObject();String id = request.getParameter("id").trim();          //主键String name = request.getParameter("name").trim();      //歌名String introduction = request.getParameter("introduction").trim();//专辑String lyric = request.getParameter("lyric").trim();    //歌词//保存到歌手的对象中Song song = new Song();song.setId(Integer.parseInt(id));song.setName(name);song.setIntroduction(introduction);song.setLyric(lyric);boolean flag = songService.update(song);if(flag){   //保存成功jsonObject.put(Consts.CODE,1);jsonObject.put(Consts.MSG,"修改成功");return jsonObject;}jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"修改失败");return jsonObject;}/*** 删除歌曲*/@ApiOperation(value = "删除歌曲")@RequestMapping(value = "/delete",method = RequestMethod.GET)public Object deleteSinger(HttpServletRequest request){//-TODO 先查询到数据库中对应的文件地址,删除掉它再进行下面的代码String id = request.getParameter("id").trim();          //主键boolean flag = songService.delete(Integer.parseInt(id));return flag;}/*** 更新歌曲图片*/@ApiOperation(value = "更新歌曲图片")@RequestMapping(value = "/updateSongPic",method = RequestMethod.POST)public Object updateSongPic(@RequestParam("file") MultipartFile avatorFile, @RequestParam("id")int id){JSONObject jsonObject = new JSONObject();if(avatorFile.isEmpty()){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"文件上传失败");return jsonObject;}//文件名=当前时间到毫秒+原来的文件名String fileName = System.currentTimeMillis()+avatorFile.getOriginalFilename();//文件路径String filePath = PathUtils.getClassLoadRootPath() + "/img/songPic/";//如果文件路径不存在,新增该路径File file1 = new File(filePath);if(!file1.exists()){file1.mkdir();}//实际的文件地址File dest = new File(filePath + fileName);//存储到数据库里的相对文件地址String storeAvatorPath = "/img/songPic/"+fileName;try {avatorFile.transferTo(dest);Song song = new Song();song.setId(id);song.setPic(storeAvatorPath);boolean flag = songService.update(song);if(flag){jsonObject.put(Consts.CODE,1);jsonObject.put(Consts.MSG,"上传成功");jsonObject.put("pic",storeAvatorPath);return jsonObject;}jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"上传失败");return jsonObject;} catch (IOException e) {jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"上传失败"+e.getMessage());}finally {return jsonObject;}}/*** 更新歌曲*/@ApiOperation(value = "更新歌曲")@RequestMapping(value = "/updateSongUrl",method = RequestMethod.POST)public Object updateSongUrl(@RequestParam("file") MultipartFile avatorFile, @RequestParam("id")int id){JSONObject jsonObject = new JSONObject();if(avatorFile.isEmpty()){jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"文件上传失败");return jsonObject;}//文件名=当前时间到毫秒+原来的文件名String fileName = System.currentTimeMillis()+avatorFile.getOriginalFilename();//文件路径String filePath = PathUtils.getClassLoadRootPath() + "/song/";//如果文件路径不存在,新增该路径File file1 = new File(filePath);if(!file1.exists()){file1.mkdir();}//实际的文件地址File dest = new File(filePath + fileName);//存储到数据库里的相对文件地址String storeAvatorPath = "/song/"+fileName;try {avatorFile.transferTo(dest);Song song = new Song();song.setId(id);song.setUrl(storeAvatorPath);boolean flag = songService.update(song);if(flag){jsonObject.put(Consts.CODE,1);jsonObject.put(Consts.MSG,"上传成功");jsonObject.put("avator",storeAvatorPath);return jsonObject;}jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"上传失败");return jsonObject;} catch (IOException e) {jsonObject.put(Consts.CODE,0);jsonObject.put(Consts.MSG,"上传失败"+e.getMessage());}finally {return jsonObject;}}/*** 根据歌曲id查询歌曲对象*/@ApiOperation(value = "根据歌曲id查询歌曲对象")@RequestMapping(value = "/detail",method = RequestMethod.GET)public Object detail(HttpServletRequest request){String songId = request.getParameter("songId");return songService.selectByPrimaryKey(Integer.parseInt(songId));}/*** 根据歌手名字精确查询歌曲*/@ApiOperation(value = "根据歌手名字精确查询歌曲")@RequestMapping(value = "/songOfSongName",method = RequestMethod.GET)public Object songOfSongName(HttpServletRequest request){String songName = request.getParameter("songName");return songService.songOfName(songName);}/*** 根据歌手名字模糊查询歌曲*/@ApiOperation(value = "根据歌手名字模糊查询歌曲")@RequestMapping(value = "/likeSongOfName",method = RequestMethod.GET)public Object likeSongOfName(HttpServletRequest request){String songName = request.getParameter("songName");return songService.likeSongOfName(songName);}/*** 查询所有歌曲*/@ApiOperation(value = "查询所有歌曲")@RequestMapping(value = "/allSong",method = RequestMethod.GET)public Object allSong(HttpServletRequest request){return songService.allSong();}}

六、底部获取项目源码和万字论文参考(9.9¥带走)

有问题,或者需要协助调试运行项目的也可以

相关文章:

音乐系统java在线音乐网站基于springboot+vue的音乐系统带万字文档

文章目录 音乐系统一、项目演示二、项目介绍三、万字项目文档四、部分功能截图五、部分代码展示六、底部获取项目源码和万字论文参考(9.9¥带走) 音乐系统 一、项目演示 在线音乐系统 二、项目介绍 基于springbootvue的前后端分离在线音乐系…...

Python—面向对象小解(1)

一、面向对象 面向对象编程(Object-Oriented Programming,简称 OOP)是一种程序设计范式,它通过使用“对象”和“类”来组织代码。Python 是一种面向对象的编程语言,支持 OOP 的核心概念。 面向过程&#xff1a…...

2024最新TikTok抖音国际版,tiktok正版免拔卡安装来了!

保姆级教程!2024最新TikTok抖音国际版,无限制!tiktok正版免拔卡安装方法来了! TikTok这款APP为何让全球都为之疯狂?因为它更懂人性,懂的人都懂! 我是你的老朋友阿星,今天阿星要给大…...

【Python-OS】os.path.splitext()

作用:将文件路径分割成文件名和扩展名两部分。 slide_id, _ os.path.splitext(slide) print("slide:") print(slide) print("slide_id:") print(slide_id)注: slide是文件名,可以自行赋值...

安卓开发--安卓使用Echatrs绘制折线图

安卓开发--安卓使用Echatrs绘制折线图 前期资料安卓使用Echarts绘制折线图1.1 下载 Echarts 安卓资源1.2 新建assets文件1.3 新建布局文件1.4 在布局文件中布局WebView1.5 在活动文件中调用 最终效果 前期资料 Echarts 官网样式预览: https://echarts.apache.org/examples/zh/…...

每日5题Day9 - LeetCode 41 - 45

每一步向前都是向自己的梦想更近一步,坚持不懈,勇往直前! 第一题:41. 缺失的第一个正数 - 力扣(LeetCode) 今天这道题没有ac,写不动了,下次再通过吧,先给个半成品下次回…...

进程间通信的方式中,socket和消息队列的区别

进程间通信的方式中,socket和消息队列的区别 进程间通信方式中,socket和消息队列的主要区别在于通信的方式和跨机通信的能力。 socket是通过网络传输的方式来实现进程间通信,并且可以跨主机;而消息队列是通过内核提供的缓冲区进…...

10. C++异步IO处理库和使用libevent实现高性能服务器

C比较有名的异步IO处理库 libevent 这个主要使用的是epoll。libevthplibuvlibev 我们主要介绍libevent。 libevent重要函数 event_base_new 这个可以对应于epoll_create也就是创建一个实例。还可以初始化libevent所有管理相关的代码。比如说所能用到的队列,栈&a…...

React里面useMemo和useCallBack的区别

useMemo 和 useCallback 接收的参数都是一样,第一个参数为回调,第二个参数为要依赖的数据。 相同部分:都是依赖数据发生变化,才会去更新缓存数据 不同部分: useMemo缓存的是二次计算的数据,主要用于缓存…...

css 渐变色边框

效果图&#xff1a; 代码&#xff1a; <style>:root{--br-radius: 12px;}.list{position: relative;}.list_tle{margin-top: 15px;margin-bottom: 5px;}.item{position: relative;display: inline-flex;} .br1 {padding: 10px 16px;clip-path: inset(0 round 6px);borde…...

prompt提示词:如何让AI帮你提一个好问题

我们看完一篇文章的时候&#xff0c;有时候发给AI后&#xff0c;不知道如何问AI&#xff0c;不知道问哪些问题&#xff0c;你使用这个提示词&#xff0c;就可以让AI帮你想一个好问题&#xff0c;然后你用AI想好的问题再去问AI 能提出一个好的问题是非常难的 提示词 结合文章…...

若依ruoyi-vue element-ui 横向滚动条 动态横向滚动条

动态横向滚动条 因为每次横向滑动都要到底部&#xff0c;引入插件 https://github.com/mizuka-wu/el-table-horizontal-scroll //动态横向滚动条移入样式 .el-table-horizontal-scrollbar :hover{//高度 变大10%transform: scaleY(1.5) translateY(-10%);//百分之八十亮度&a…...

CET-4 听力高频词

1. 生活故事 architect /ˈɑːkɪtekt/ n. 建筑师anxiety /ŋˈzaɪəti/ n. 焦虑attack /əˈtk/ v./n. 批评&#xff1b;攻击assume /əˈsjuːm/ v. 假定auditorium /ˌɔːdɪˈtɔːriəm/ n. 观众席&#xff1b;礼堂bonus /ˈbəʊnəs/ n. 奖金campaigner /kmˈpeɪnə…...

ARM鲲鹏920-oe2309-caffe

参考链接:Caffe | Installation 安装依赖包 dnf install dnf update dnf install leveldb-devel snappy-devel opencv.aarch64 boost-devel hdf5-devel gflags-devel glog-devel lmdb-devel openblas.aarch64 dnf install git wget tar gcc-g unzip automake libtool autoco…...

这款网站测试工具,炫酷且强大!【送源码】

随着互联网的普及和发展&#xff0c;Web 应用程序的数量也越来越多&#xff0c;各种网络问题也是层出不穷&#xff0c;因而监测这些 Web 应用程序的性能和可用性变得非常重要。 今天的文章&#xff0c;了不起和大家分享一款十分好用的的网站分析项目 - Web-Check。 项目简介 …...

成功案例(IF=7.4)| 代谢组+16s联合分析助力房颤代谢重构的潜在机制研究

研究背景 心房颤动&#xff08;AF&#xff09;是临床上最常见的持续性心律失常&#xff0c;具有显著的发病率和死亡率。高龄是房颤发病率、患病率和进展最显著的危险因素。与年龄在50-59岁之间的参与者相比&#xff0c;80-89岁之间的参与者患房颤的风险增加了9.33倍。目前尚不…...

【LeetCode:496. 下一个更大元素 I + 单调栈】

&#x1f680; 算法题 &#x1f680; &#x1f332; 算法刷题专栏 | 面试必备算法 | 面试高频算法 &#x1f340; &#x1f332; 越难的东西,越要努力坚持&#xff0c;因为它具有很高的价值&#xff0c;算法就是这样✨ &#x1f332; 作者简介&#xff1a;硕风和炜&#xff0c;…...

软考案例题总结

数据库故障与恢复 E-R图 关系规范化 SQL 涉及的知识点一般包括&#xff1a;表的创建、视图和索引创建的关键字、表的查询、聚集函数、子查询、分组查询、集合操作、外连接存储过程、游标、触发器以及表的更新、插入和删除...

第二证券炒股知识:股票破发后怎么办?

当一只新股的价格跌破其发行价时&#xff0c;往往会受到商场出资者的关注。关于股票破发后怎么办&#xff0c;第二证券下面就为我们具体介绍一下。 股票破发是指股票的商场价格低于其发行价格或最近一次增发价格&#xff0c;股票破发往往是由于多种要素共同作用的结果&#xf…...

Angular中,@HostListener装饰器

HostListener(input, [$event]) onInput(event: KeyboardEvent) {// 将输入值转换为大写const currentValue this.el.nativeElement.value;const upperCaseValue currentValue.toUpperCase();// 更新输入框的值if (currentValue ! upperCaseValue) {this.el.nativeElement.va…...

OpenLayers 可视化之热力图

注&#xff1a;当前使用的是 ol 5.3.0 版本&#xff0c;天地图使用的key请到天地图官网申请&#xff0c;并替换为自己的key 热力图&#xff08;Heatmap&#xff09;又叫热点图&#xff0c;是一种通过特殊高亮显示事物密度分布、变化趋势的数据可视化技术。采用颜色的深浅来显示…...

以下是对华为 HarmonyOS NETX 5属性动画(ArkTS)文档的结构化整理,通过层级标题、表格和代码块提升可读性:

一、属性动画概述NETX 作用&#xff1a;实现组件通用属性的渐变过渡效果&#xff0c;提升用户体验。支持属性&#xff1a;width、height、backgroundColor、opacity、scale、rotate、translate等。注意事项&#xff1a; 布局类属性&#xff08;如宽高&#xff09;变化时&#…...

1.3 VSCode安装与环境配置

进入网址Visual Studio Code - Code Editing. Redefined下载.deb文件&#xff0c;然后打开终端&#xff0c;进入下载文件夹&#xff0c;键入命令 sudo dpkg -i code_1.100.3-1748872405_amd64.deb 在终端键入命令code即启动vscode 需要安装插件列表 1.Chinese简化 2.ros …...

oracle与MySQL数据库之间数据同步的技术要点

Oracle与MySQL数据库之间的数据同步是一个涉及多个技术要点的复杂任务。由于Oracle和MySQL的架构差异&#xff0c;它们的数据同步要求既要保持数据的准确性和一致性&#xff0c;又要处理好性能问题。以下是一些主要的技术要点&#xff1a; 数据结构差异 数据类型差异&#xff…...

【SQL学习笔记1】增删改查+多表连接全解析(内附SQL免费在线练习工具)

可以使用Sqliteviz这个网站免费编写sql语句&#xff0c;它能够让用户直接在浏览器内练习SQL的语法&#xff0c;不需要安装任何软件。 链接如下&#xff1a; sqliteviz 注意&#xff1a; 在转写SQL语法时&#xff0c;关键字之间有一个特定的顺序&#xff0c;这个顺序会影响到…...

Ascend NPU上适配Step-Audio模型

1 概述 1.1 简述 Step-Audio 是业界首个集语音理解与生成控制一体化的产品级开源实时语音对话系统&#xff0c;支持多语言对话&#xff08;如 中文&#xff0c;英文&#xff0c;日语&#xff09;&#xff0c;语音情感&#xff08;如 开心&#xff0c;悲伤&#xff09;&#x…...

今日学习:Spring线程池|并发修改异常|链路丢失|登录续期|VIP过期策略|数值类缓存

文章目录 优雅版线程池ThreadPoolTaskExecutor和ThreadPoolTaskExecutor的装饰器并发修改异常并发修改异常简介实现机制设计原因及意义 使用线程池造成的链路丢失问题线程池导致的链路丢失问题发生原因 常见解决方法更好的解决方法设计精妙之处 登录续期登录续期常见实现方式特…...

C# 求圆面积的程序(Program to find area of a circle)

给定半径r&#xff0c;求圆的面积。圆的面积应精确到小数点后5位。 例子&#xff1a; 输入&#xff1a;r 5 输出&#xff1a;78.53982 解释&#xff1a;由于面积 PI * r * r 3.14159265358979323846 * 5 * 5 78.53982&#xff0c;因为我们只保留小数点后 5 位数字。 输…...

Android第十三次面试总结(四大 组件基础)

Activity生命周期和四大启动模式详解 一、Activity 生命周期 Activity 的生命周期由一系列回调方法组成&#xff0c;用于管理其创建、可见性、焦点和销毁过程。以下是核心方法及其调用时机&#xff1a; ​onCreate()​​ ​调用时机​&#xff1a;Activity 首次创建时调用。​…...

纯 Java 项目(非 SpringBoot)集成 Mybatis-Plus 和 Mybatis-Plus-Join

纯 Java 项目&#xff08;非 SpringBoot&#xff09;集成 Mybatis-Plus 和 Mybatis-Plus-Join 1、依赖1.1、依赖版本1.2、pom.xml 2、代码2.1、SqlSession 构造器2.2、MybatisPlus代码生成器2.3、获取 config.yml 配置2.3.1、config.yml2.3.2、项目配置类 2.4、ftl 模板2.4.1、…...