diff --git a/muyu-auth/src/main/resources/bootstrap.yml b/muyu-auth/src/main/resources/bootstrap.yml index b309a3d..52e9fc9 100644 --- a/muyu-auth/src/main/resources/bootstrap.yml +++ b/muyu-auth/src/main/resources/bootstrap.yml @@ -1,7 +1,6 @@ # Tomcat server: - port: 9200 - + port: 9001 # Spring spring: application: @@ -14,10 +13,10 @@ spring: nacos: discovery: # 服务注册地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 config: # 配置中心地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 # 配置文件格式 file-extension: yml # 共享配置 diff --git a/muyu-gateway/src/main/resources/bootstrap.yml b/muyu-gateway/src/main/resources/bootstrap.yml index d7367b4..2b89b27 100644 --- a/muyu-gateway/src/main/resources/bootstrap.yml +++ b/muyu-gateway/src/main/resources/bootstrap.yml @@ -1,6 +1,6 @@ # Tomcat server: - port: 8080 + port: 18080 # Spring spring: @@ -14,10 +14,10 @@ spring: nacos: discovery: # 服务注册地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 config: # 配置中心地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 # 配置文件格式 file-extension: yml # 共享配置 @@ -28,12 +28,12 @@ spring: eager: true transport: # 控制台地址 - dashboard: 127.0.0.1:8718 + dashboard: 43.142.44.217:8718 # nacos配置持久化 datasource: ds1: nacos: - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 dataId: sentinel-muyu-gateway groupId: DEFAULT_GROUP data-type: json diff --git a/muyu-modules/muyu-file/src/main/resources/bootstrap.yml b/muyu-modules/muyu-file/src/main/resources/bootstrap.yml index 0cb85bd..c500ff5 100644 --- a/muyu-modules/muyu-file/src/main/resources/bootstrap.yml +++ b/muyu-modules/muyu-file/src/main/resources/bootstrap.yml @@ -1,6 +1,6 @@ # Tomcat server: - port: 9300 + port: 9006 # Spring spring: @@ -14,10 +14,10 @@ spring: nacos: discovery: # 服务注册地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 config: # 配置中心地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 # 配置文件格式 file-extension: yml # 共享配置 diff --git a/muyu-modules/muyu-gen/src/main/resources/bootstrap.yml b/muyu-modules/muyu-gen/src/main/resources/bootstrap.yml index b628931..0bd8dbe 100644 --- a/muyu-modules/muyu-gen/src/main/resources/bootstrap.yml +++ b/muyu-modules/muyu-gen/src/main/resources/bootstrap.yml @@ -1,6 +1,6 @@ # Tomcat server: - port: 9202 + port: 9005 # Spring spring: @@ -14,10 +14,10 @@ spring: nacos: discovery: # 服务注册地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 config: # 配置中心地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 # 配置文件格式 file-extension: yml # 共享配置 diff --git a/muyu-modules/muyu-job/src/main/resources/bootstrap.yml b/muyu-modules/muyu-job/src/main/resources/bootstrap.yml index 618f3e8..58f4e0e 100644 --- a/muyu-modules/muyu-job/src/main/resources/bootstrap.yml +++ b/muyu-modules/muyu-job/src/main/resources/bootstrap.yml @@ -1,6 +1,6 @@ # Tomcat server: - port: 9203 + port: 9004 # Spring spring: @@ -14,10 +14,10 @@ spring: nacos: discovery: # 服务注册地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 config: # 配置中心地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 # 配置文件格式 file-extension: yml # 共享配置 diff --git a/muyu-modules/muyu-system/src/main/java/com/muyu/system/controller/BookInfoController.java b/muyu-modules/muyu-system/src/main/java/com/muyu/system/controller/BookInfoController.java new file mode 100644 index 0000000..bb1ac3d --- /dev/null +++ b/muyu-modules/muyu-system/src/main/java/com/muyu/system/controller/BookInfoController.java @@ -0,0 +1,105 @@ +package com.muyu.system.controller; + +import java.util.List; +import java.io.IOException; +import javax.servlet.http.HttpServletResponse; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.muyu.common.log.annotation.Log; +import com.muyu.common.log.enums.BusinessType; +import com.muyu.common.security.annotation.RequiresPermissions; +import com.muyu.system.domain.BookInfo; +import com.muyu.system.service.IBookInfoService; +import com.muyu.common.core.web.controller.BaseController; +import com.muyu.common.core.domain.Result; +import com.muyu.common.core.utils.poi.ExcelUtil; +import com.muyu.common.core.web.page.TableDataInfo; + +/** + * 【请填写功能名称】Controller + * + * @author muyu + * @date 2024-02-23 + */ +@RestController +@RequestMapping("/info") +public class BookInfoController extends BaseController +{ + @Autowired + private IBookInfoService bookInfoService; + + /** + * 查询【请填写功能名称】列表 + */ + @RequiresPermissions("system:info:list") + @GetMapping("/list") + public Result> list(BookInfo bookInfo) + { + startPage(); + List list = bookInfoService.selectBookInfoList(bookInfo); + return getDataTable(list); + } + + /** + * 导出【请填写功能名称】列表 + */ + @RequiresPermissions("system:info:export") + @Log(title = "【请填写功能名称】", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, BookInfo bookInfo) + { + List list = bookInfoService.selectBookInfoList(bookInfo); + ExcelUtil util = new ExcelUtil(BookInfo.class); + util.exportExcel(response, list, "【请填写功能名称】数据"); + } + + /** + * 获取【请填写功能名称】详细信息 + */ + @RequiresPermissions("system:info:query") + @GetMapping(value = "/{bid}") + public Result getInfo(@PathVariable("bid") Long bid) + { + return success(bookInfoService.selectBookInfoByBid(bid)); + } + + /** + * 新增【请填写功能名称】 + */ + @RequiresPermissions("system:info:add") + @Log(title = "【请填写功能名称】", businessType = BusinessType.INSERT) + @PostMapping + public Result add(@RequestBody BookInfo bookInfo) + { + return toAjax(bookInfoService.insertBookInfo(bookInfo)); + } + + /** + * 修改【请填写功能名称】 + */ + @RequiresPermissions("system:info:edit") + @Log(title = "【请填写功能名称】", businessType = BusinessType.UPDATE) + @PutMapping + public Result edit(@RequestBody BookInfo bookInfo) + { + return toAjax(bookInfoService.updateBookInfo(bookInfo)); + } + + /** + * 删除【请填写功能名称】 + */ + @RequiresPermissions("system:info:remove") + @Log(title = "【请填写功能名称】", businessType = BusinessType.DELETE) + @DeleteMapping("/{bids}") + public Result remove(@PathVariable Long[] bids) + { + return toAjax(bookInfoService.deleteBookInfoByBids(bids)); + } +} diff --git a/muyu-modules/muyu-system/src/main/java/com/muyu/system/domain/BookInfo.java b/muyu-modules/muyu-system/src/main/java/com/muyu/system/domain/BookInfo.java new file mode 100644 index 0000000..eacf4bf --- /dev/null +++ b/muyu-modules/muyu-system/src/main/java/com/muyu/system/domain/BookInfo.java @@ -0,0 +1,129 @@ +package com.muyu.system.domain; + +import java.util.Date; +import com.fasterxml.jackson.annotation.JsonFormat; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.muyu.common.core.annotation.Excel; +import com.muyu.common.core.web.domain.BaseEntity; + +/** + * 【请填写功能名称】对象 book_info + * + * @author muyu + * @date 2024-02-23 + */ +public class BookInfo extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 书籍编号 */ + private Long bid; + + /** 书籍名称 */ + @Excel(name = "书籍名称") + private String title; + + /** 作者名称 */ + @Excel(name = "作者名称") + private String author; + + /** 书籍类型 */ + @Excel(name = "书籍类型") + private String type; + + /** 图片 */ + @Excel(name = "图片") + private String image; + + /** 书籍介绍 */ + @Excel(name = "书籍介绍") + private String description; + + /** 创建时间 */ + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd") + private Date shelfTime; + + public void setBid(Long bid) + { + this.bid = bid; + } + + public Long getBid() + { + return bid; + } + public void setTitle(String title) + { + this.title = title; + } + + public String getTitle() + { + return title; + } + public void setAuthor(String author) + { + this.author = author; + } + + public String getAuthor() + { + return author; + } + public void setType(String type) + { + this.type = type; + } + + public String getType() + { + return type; + } + public void setImage(String image) + { + this.image = image; + } + + public String getImage() + { + return image; + } + public void setDescription(String description) + { + this.description = description; + } + + public String getDescription() + { + return description; + } + public void setShelfTime(Date shelfTime) + { + this.shelfTime = shelfTime; + } + + public Date getShelfTime() + { + return shelfTime; + } + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("bid", getBid()) + .append("title", getTitle()) + .append("author", getAuthor()) + .append("type", getType()) + .append("image", getImage()) + .append("description", getDescription()) + .append("shelfTime", getShelfTime()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("remark", getRemark()) + .toString(); + } +} diff --git a/muyu-modules/muyu-system/src/main/java/com/muyu/system/mapper/BookInfoMapper.java b/muyu-modules/muyu-system/src/main/java/com/muyu/system/mapper/BookInfoMapper.java new file mode 100644 index 0000000..9be3883 --- /dev/null +++ b/muyu-modules/muyu-system/src/main/java/com/muyu/system/mapper/BookInfoMapper.java @@ -0,0 +1,62 @@ +package com.muyu.system.mapper; + +import java.util.List; +import com.muyu.system.domain.BookInfo; +import org.apache.ibatis.annotations.Mapper; + +/** + * 【请填写功能名称】Mapper接口 + * + * @author muyu + * @date 2024-02-23 + */ +public interface BookInfoMapper +{ + /** + * 查询【请填写功能名称】 + * + * @param bid 【请填写功能名称】主键 + * @return 【请填写功能名称】 + */ + public BookInfo selectBookInfoByBid(Long bid); + + /** + * 查询【请填写功能名称】列表 + * + * @param bookInfo 【请填写功能名称】 + * @return 【请填写功能名称】集合 + */ + public List selectBookInfoList(BookInfo bookInfo); + + /** + * 新增【请填写功能名称】 + * + * @param bookInfo 【请填写功能名称】 + * @return 结果 + */ + public int insertBookInfo(BookInfo bookInfo); + + /** + * 修改【请填写功能名称】 + * + * @param bookInfo 【请填写功能名称】 + * @return 结果 + */ + public int updateBookInfo(BookInfo bookInfo); + + /** + * 删除【请填写功能名称】 + * + * @param bid 【请填写功能名称】主键 + * @return 结果 + */ + public int deleteBookInfoByBid(Long bid); + + /** + * 批量删除【请填写功能名称】 + * + * @param bids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteBookInfoByBids(Long[] bids); +} diff --git a/muyu-modules/muyu-system/src/main/java/com/muyu/system/service/IBookInfoService.java b/muyu-modules/muyu-system/src/main/java/com/muyu/system/service/IBookInfoService.java new file mode 100644 index 0000000..35406b3 --- /dev/null +++ b/muyu-modules/muyu-system/src/main/java/com/muyu/system/service/IBookInfoService.java @@ -0,0 +1,61 @@ +package com.muyu.system.service; + +import java.util.List; +import com.muyu.system.domain.BookInfo; + +/** + * 【请填写功能名称】Service接口 + * + * @author muyu + * @date 2024-02-23 + */ +public interface IBookInfoService +{ + /** + * 查询【请填写功能名称】 + * + * @param bid 【请填写功能名称】主键 + * @return 【请填写功能名称】 + */ + public BookInfo selectBookInfoByBid(Long bid); + + /** + * 查询【请填写功能名称】列表 + * + * @param bookInfo 【请填写功能名称】 + * @return 【请填写功能名称】集合 + */ + public List selectBookInfoList(BookInfo bookInfo); + + /** + * 新增【请填写功能名称】 + * + * @param bookInfo 【请填写功能名称】 + * @return 结果 + */ + public int insertBookInfo(BookInfo bookInfo); + + /** + * 修改【请填写功能名称】 + * + * @param bookInfo 【请填写功能名称】 + * @return 结果 + */ + public int updateBookInfo(BookInfo bookInfo); + + /** + * 批量删除【请填写功能名称】 + * + * @param bids 需要删除的【请填写功能名称】主键集合 + * @return 结果 + */ + public int deleteBookInfoByBids(Long[] bids); + + /** + * 删除【请填写功能名称】信息 + * + * @param bid 【请填写功能名称】主键 + * @return 结果 + */ + public int deleteBookInfoByBid(Long bid); +} diff --git a/muyu-modules/muyu-system/src/main/java/com/muyu/system/service/impl/BookInfoServiceImpl.java b/muyu-modules/muyu-system/src/main/java/com/muyu/system/service/impl/BookInfoServiceImpl.java new file mode 100644 index 0000000..02dcfb0 --- /dev/null +++ b/muyu-modules/muyu-system/src/main/java/com/muyu/system/service/impl/BookInfoServiceImpl.java @@ -0,0 +1,96 @@ +package com.muyu.system.service.impl; + +import java.util.List; +import com.muyu.common.core.utils.DateUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.muyu.system.mapper.BookInfoMapper; +import com.muyu.system.domain.BookInfo; +import com.muyu.system.service.IBookInfoService; + +/** + * 【请填写功能名称】Service业务层处理 + * + * @author muyu + * @date 2024-02-23 + */ +@Service +public class BookInfoServiceImpl implements IBookInfoService +{ + @Autowired + private BookInfoMapper bookInfoMapper; + + /** + * 查询【请填写功能名称】 + * + * @param bid 【请填写功能名称】主键 + * @return 【请填写功能名称】 + */ + @Override + public BookInfo selectBookInfoByBid(Long bid) + { + return bookInfoMapper.selectBookInfoByBid(bid); + } + + /** + * 查询【请填写功能名称】列表 + * + * @param bookInfo 【请填写功能名称】 + * @return 【请填写功能名称】 + */ + @Override + public List selectBookInfoList(BookInfo bookInfo) + { + return bookInfoMapper.selectBookInfoList(bookInfo); + } + + /** + * 新增【请填写功能名称】 + * + * @param bookInfo 【请填写功能名称】 + * @return 结果 + */ + @Override + public int insertBookInfo(BookInfo bookInfo) + { + bookInfo.setCreateTime(DateUtils.getNowDate()); + return bookInfoMapper.insertBookInfo(bookInfo); + } + + /** + * 修改【请填写功能名称】 + * + * @param bookInfo 【请填写功能名称】 + * @return 结果 + */ + @Override + public int updateBookInfo(BookInfo bookInfo) + { + bookInfo.setUpdateTime(DateUtils.getNowDate()); + return bookInfoMapper.updateBookInfo(bookInfo); + } + + /** + * 批量删除【请填写功能名称】 + * + * @param bids 需要删除的【请填写功能名称】主键 + * @return 结果 + */ + @Override + public int deleteBookInfoByBids(Long[] bids) + { + return bookInfoMapper.deleteBookInfoByBids(bids); + } + + /** + * 删除【请填写功能名称】信息 + * + * @param bid 【请填写功能名称】主键 + * @return 结果 + */ + @Override + public int deleteBookInfoByBid(Long bid) + { + return bookInfoMapper.deleteBookInfoByBid(bid); + } +} diff --git a/muyu-modules/muyu-system/src/main/resources/bootstrap.yml b/muyu-modules/muyu-system/src/main/resources/bootstrap.yml index a66fd4c..ed48248 100644 --- a/muyu-modules/muyu-system/src/main/resources/bootstrap.yml +++ b/muyu-modules/muyu-system/src/main/resources/bootstrap.yml @@ -1,6 +1,6 @@ # Tomcat server: - port: 9201 + port: 9003 # Spring spring: @@ -14,10 +14,10 @@ spring: nacos: discovery: # 服务注册地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 config: # 配置中心地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 # 配置文件格式 file-extension: yml # 共享配置 diff --git a/muyu-modules/muyu-system/src/main/resources/mapper/system/BookInfoMapper.xml b/muyu-modules/muyu-system/src/main/resources/mapper/system/BookInfoMapper.xml new file mode 100644 index 0000000..660f16f --- /dev/null +++ b/muyu-modules/muyu-system/src/main/resources/mapper/system/BookInfoMapper.xml @@ -0,0 +1,101 @@ + + + + + + + + + + + + + + + + + + + + + select bid, title, author, type, image, description, shelf_time, create_by, create_time, update_by, update_time, remark from book_info + + + + + + + + insert into book_info + + title, + author, + type, + image, + description, + shelf_time, + create_by, + create_time, + update_by, + update_time, + remark, + + + #{title}, + #{author}, + #{type}, + #{image}, + #{description}, + #{shelfTime}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{remark}, + + + + + update book_info + + title = #{title}, + author = #{author}, + type = #{type}, + image = #{image}, + description = #{description}, + shelf_time = #{shelfTime}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + remark = #{remark}, + + where bid = #{bid} + + + + delete from book_info where bid = #{bid} + + + + delete from book_info where bid in + + #{bid} + + + \ No newline at end of file diff --git a/muyu-visual/muyu-monitor/src/main/resources/bootstrap.yml b/muyu-visual/muyu-monitor/src/main/resources/bootstrap.yml index 1276c8e..f2e1e24 100644 --- a/muyu-visual/muyu-monitor/src/main/resources/bootstrap.yml +++ b/muyu-visual/muyu-monitor/src/main/resources/bootstrap.yml @@ -1,6 +1,6 @@ # Tomcat server: - port: 9100 + port: 9002 # Spring spring: @@ -14,10 +14,10 @@ spring: nacos: discovery: # 服务注册地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 config: # 配置中心地址 - server-addr: 127.0.0.1:8848 + server-addr: 43.142.44.217:8848 # 配置文件格式 file-extension: yml # 共享配置