Compare commits
10
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b0efd05062 | ||
|
|
67f2a4f302 | ||
|
|
19a632402d | ||
|
|
62a07a3913 | ||
|
|
a79b35fbe8 | ||
|
|
0107eb05f7 | ||
|
|
f7cba07e1a | ||
|
|
c625871221 | ||
|
|
2c93c9fd0c | ||
|
|
93188a018e |
@@ -4,15 +4,16 @@
|
|||||||
|
|
||||||
本项目为springboot3的项目, 使用jdk21进行开发, 前端html模板为freemarker, 数据库orm为自研的jpaHelper.
|
本项目为springboot3的项目, 使用jdk21进行开发, 前端html模板为freemarker, 数据库orm为自研的jpaHelper.
|
||||||
|
|
||||||
jpaHelper的使用说明看这个页面: https://gitee.com/cym1102/jpaHelper 主要特点是不需要手动维护数据库结构, 添加model后自动生成表结构
|
jpaHelper的使用说明看这个页面: https://gitee.com/cym1102/jpaHelper 主要特点是不需要手动维护数据库结构, 添加model后自动生成表结构, 尽量不要写sql或xml文件, 使用ConditionAndWrapper ConditionOrWrapper进行sql构建和查询
|
||||||
|
|
||||||
网页框架用的jquery + layui官网说明: https://layui.dev/
|
网页框架用的jquery + layui官网说明: https://layui.dev/
|
||||||
|
|
||||||
### 文件说明
|
### java文件说明
|
||||||
|
|
||||||
com.cym.CdnWebUI.java : 主启动类
|
com.cym.CdnWebUI.java : 主启动类
|
||||||
|
|
||||||
com.cym.controller.page.LoginExampleController.java : 登录接口
|
com.cym.controller.page.LoginExampleController.java : 登录接口
|
||||||
|
|
||||||
com.cym.controller.page.ExampleController.java : 演示模块接口
|
com.cym.controller.page.ExampleController.java : 演示模块接口
|
||||||
|
|
||||||
com.cym.model.* : 数据库映射对象
|
com.cym.model.* : 数据库映射对象
|
||||||
@@ -22,3 +23,31 @@ com.cym.ext.* : 主要是一些类的扩展类, 方便返回更多数据给前
|
|||||||
com.cym.service.* : 数据访问层
|
com.cym.service.* : 数据访问层
|
||||||
|
|
||||||
com.cym.utils.* : 工具类
|
com.cym.utils.* : 工具类
|
||||||
|
|
||||||
|
### web文件说明
|
||||||
|
|
||||||
|
src/main/resources/templates/*.html : freemarker模板
|
||||||
|
|
||||||
|
src/main/resources/static/css : 公共css
|
||||||
|
|
||||||
|
src/main/resources/static/js : 公共js (一般和html文件一对一)
|
||||||
|
|
||||||
|
src/main/resources/static/lib : 其他js库
|
||||||
|
|
||||||
|
### 配置文件说明
|
||||||
|
|
||||||
|
src/main/resources/application.yml : 主配置文件
|
||||||
|
|
||||||
|
src/main/resources/application-dev.yml : 开发配置文件
|
||||||
|
|
||||||
|
### 测试说明
|
||||||
|
|
||||||
|
访问地址: http://127.0.0.1:8000/index
|
||||||
|
|
||||||
|
用户名:admin
|
||||||
|
|
||||||
|
密码:admin
|
||||||
|
|
||||||
|
### 开发说明
|
||||||
|
|
||||||
|
开始开发前需要进入lib目录, 执行install.bat, 将jpaHelper模块导入maven库, 否则编译不通过, 开发新模块时, 请尽量参照ExampleController这个模块进行开发, 新开发的模块可在menu.html里面添加菜单进行访问, 方便测试人员进行测试.
|
||||||
@@ -62,29 +62,6 @@
|
|||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.springframework.boot</groupId>
|
|
||||||
<artifactId>spring-boot-starter-quartz</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>io.github.binance</groupId>
|
|
||||||
<artifactId>binance-connector-java</artifactId>
|
|
||||||
<version>3.2.0</version>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.github.odiszapc</groupId>
|
|
||||||
<artifactId>nginxparser</artifactId>
|
|
||||||
<version>0.9.6</version>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.clickhouse</groupId>
|
|
||||||
<artifactId>clickhouse-jdbc</artifactId>
|
|
||||||
<version>0.6.2</version>
|
|
||||||
<classifier>all</classifier>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>cn.hutool</groupId>
|
<groupId>cn.hutool</groupId>
|
||||||
<artifactId>hutool-all</artifactId>
|
<artifactId>hutool-all</artifactId>
|
||||||
@@ -102,78 +79,25 @@
|
|||||||
<artifactId>expiringmap</artifactId>
|
<artifactId>expiringmap</artifactId>
|
||||||
<version>0.5.11</version>
|
<version>0.5.11</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
|
||||||
<groupId>com.sun.mail</groupId>
|
|
||||||
<artifactId>javax.mail</artifactId>
|
|
||||||
<version>1.6.2</version>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.huaweicloud.sdk</groupId>
|
|
||||||
<artifactId>huaweicloud-sdk-dns</artifactId>
|
|
||||||
<version>3.1.104</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.alipay.sdk</groupId>
|
|
||||||
<artifactId>alipay-sdk-java</artifactId>
|
|
||||||
<version>4.38.28.ALL</version>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.google.zxing</groupId>
|
|
||||||
<artifactId>core</artifactId>
|
|
||||||
<version>3.3.0</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.google.zxing</groupId>
|
|
||||||
<artifactId>javase</artifactId>
|
|
||||||
<version>3.3.0</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.apache.axis</groupId>
|
|
||||||
<artifactId>axis</artifactId>
|
|
||||||
<version>1.4</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.jsoup</groupId>
|
|
||||||
<artifactId>jsoup</artifactId>
|
|
||||||
<version>1.16.2</version>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.github.xiaoymin</groupId>
|
|
||||||
<artifactId>knife4j-openapi3-jakarta-spring-boot-starter</artifactId>
|
|
||||||
<version>4.5.0</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.projectlombok</groupId>
|
<groupId>org.projectlombok</groupId>
|
||||||
<artifactId>lombok</artifactId>
|
<artifactId>lombok</artifactId>
|
||||||
<optional>true</optional>
|
<optional>true</optional>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.google.guava</groupId>
|
|
||||||
<artifactId>guava</artifactId>
|
|
||||||
<version>21.0</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.apache.commons</groupId>
|
|
||||||
<artifactId>commons-lang3</artifactId>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
|
|
||||||
<!--curator-recipes -->
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.apache.curator</groupId>
|
|
||||||
<artifactId>curator-recipes</artifactId>
|
|
||||||
<version>5.6.0</version>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.upyun</groupId>
|
<groupId>org.springdoc</groupId>
|
||||||
<artifactId>java-sdk</artifactId>
|
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
|
||||||
<version>4.2.3</version>
|
<version>2.2.0</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<!--Knife4J:增强Swagger API文档-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.github.xiaoymin</groupId>
|
||||||
|
<artifactId>knife4j-openapi3-jakarta-spring-boot-starter</artifactId>
|
||||||
|
<version>4.4.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|||||||
@@ -29,8 +29,8 @@ public class ExampleController extends BaseController {
|
|||||||
ExampleService exampleService;
|
ExampleService exampleService;
|
||||||
|
|
||||||
@RequestMapping("")
|
@RequestMapping("")
|
||||||
public ModelAndView index(ModelAndView modelAndView, Page page) {
|
public ModelAndView index(ModelAndView modelAndView, Page page, String keyword) {
|
||||||
page = exampleService.search(page);
|
page = exampleService.search(page, keyword);
|
||||||
|
|
||||||
List<ExampleExt> exts = new ArrayList<ExampleExt>();
|
List<ExampleExt> exts = new ArrayList<ExampleExt>();
|
||||||
for (Example example : (List<Example>) page.getList()) {
|
for (Example example : (List<Example>) page.getList()) {
|
||||||
@@ -46,6 +46,7 @@ public class ExampleController extends BaseController {
|
|||||||
|
|
||||||
modelAndView.addObject("adminList", jpaHelper.findAll(Admin.class));
|
modelAndView.addObject("adminList", jpaHelper.findAll(Admin.class));
|
||||||
modelAndView.addObject("page", page);
|
modelAndView.addObject("page", page);
|
||||||
|
modelAndView.addObject("keyword", keyword);
|
||||||
modelAndView.setViewName("/example/index");
|
modelAndView.setViewName("/example/index");
|
||||||
return modelAndView;
|
return modelAndView;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,137 @@
|
|||||||
|
package com.cym.controller.page;
|
||||||
|
|
||||||
|
import cn.hutool.core.bean.BeanUtil;
|
||||||
|
import cn.hutool.core.lang.UUID;
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
import com.cym.bean.Page;
|
||||||
|
import com.cym.ext.AdminExt;
|
||||||
|
import com.cym.ext.ExampleExt;
|
||||||
|
import com.cym.model.Admin;
|
||||||
|
import com.cym.model.Example;
|
||||||
|
import com.cym.model.Goods;
|
||||||
|
import com.cym.service.AdminExampleService;
|
||||||
|
import com.cym.utils.BaseController;
|
||||||
|
import com.cym.utils.ConditionAndWrapper;
|
||||||
|
import com.cym.utils.JsonResult;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
|
import jakarta.transaction.Transactional;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@Tag(name = "测试", description = "测试相关接口")
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/test")
|
||||||
|
public class Test extends BaseController {
|
||||||
|
// @Autowired
|
||||||
|
// AdminExampleService adminExampleService;
|
||||||
|
// @GetMapping("/test")
|
||||||
|
// @Operation(summary = "测试")
|
||||||
|
// public String test(){
|
||||||
|
// log.error("==============error");
|
||||||
|
// List<User> all = jpaHelper.findAll(User.class);
|
||||||
|
// return "";
|
||||||
|
// }
|
||||||
|
|
||||||
|
@RequestMapping("")
|
||||||
|
public ModelAndView page(ModelAndView mv, Page page,String keyword){
|
||||||
|
ConditionAndWrapper wrapper = new ConditionAndWrapper();
|
||||||
|
if (StrUtil.isNotBlank(keyword))
|
||||||
|
wrapper.like(Goods::getName, keyword);
|
||||||
|
|
||||||
|
page = jpaHelper.findPageByQuery(wrapper, page, Goods.class);
|
||||||
|
|
||||||
|
|
||||||
|
mv.addObject("page", page);
|
||||||
|
mv.setViewName("/test/index");
|
||||||
|
return mv;
|
||||||
|
}
|
||||||
|
|
||||||
|
// @RequestMapping("/page")
|
||||||
|
// public ModelAndView page(Page page,String keyword){
|
||||||
|
// ModelAndView mv = new ModelAndView();
|
||||||
|
// ConditionAndWrapper wrapper = new ConditionAndWrapper();
|
||||||
|
// if (StrUtil.isNotBlank(keyword))
|
||||||
|
// wrapper.like(Goods::getName, keyword);
|
||||||
|
//
|
||||||
|
// Page<Goods> pageByQuery = jpaHelper.findPageByQuery(wrapper, page, Goods.class);
|
||||||
|
//
|
||||||
|
//
|
||||||
|
// mv.addObject("page", pageByQuery);
|
||||||
|
// mv.setViewName("/test/index");
|
||||||
|
// return mv;
|
||||||
|
// }
|
||||||
|
|
||||||
|
@RequestMapping("add")
|
||||||
|
@ResponseBody
|
||||||
|
public JsonResult add(Goods example) {
|
||||||
|
|
||||||
|
jpaHelper.insertOrUpdate(example);
|
||||||
|
|
||||||
|
return renderSuccess();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@RequestMapping("detail")
|
||||||
|
@ResponseBody
|
||||||
|
public JsonResult detail(String id) {
|
||||||
|
Goods example = jpaHelper.findById(id, Goods.class);
|
||||||
|
// ExampleExt exampleExt = new ExampleExt();
|
||||||
|
// BeanUtil.copyProperties(example, exampleExt);
|
||||||
|
//
|
||||||
|
// exampleExt.setAdmin(jpaHelper.findById(example.getAdminId(), Admin.class));
|
||||||
|
|
||||||
|
return renderSuccess(example);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Transactional
|
||||||
|
@RequestMapping("delete")
|
||||||
|
@ResponseBody
|
||||||
|
public JsonResult delete(String id) {
|
||||||
|
jpaHelper.deleteById(id, Goods.class);
|
||||||
|
|
||||||
|
return renderSuccess();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// @RequestMapping("index")
|
||||||
|
// public ModelAndView admin(ModelAndView modelAndView, HttpServletRequest request, String adminId) {
|
||||||
|
//
|
||||||
|
// modelAndView.setViewName("/loginExample/index");
|
||||||
|
// return modelAndView;
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// @RequestMapping("login")
|
||||||
|
// @ResponseBody
|
||||||
|
// public JsonResult submitLogin(String name, String pass, HttpServletRequest request) {
|
||||||
|
//
|
||||||
|
// getHttpSession().removeAttribute("adminLogin");
|
||||||
|
//
|
||||||
|
// // 用户名密码
|
||||||
|
// Admin admin = adminExampleService.login(name, pass);
|
||||||
|
// if (admin == null) {
|
||||||
|
// return renderError("用户名密码错误"); // 用户名密码错误
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// // 登录成功
|
||||||
|
// admin.setAutoKey(UUID.randomUUID().toString()); // 生成自动登录code
|
||||||
|
// jpaHelper.updateById(admin);
|
||||||
|
//
|
||||||
|
// // 读取菜单
|
||||||
|
// AdminExt adminExt = new AdminExt();
|
||||||
|
//
|
||||||
|
// getHttpSession().setAttribute("adminLogin", adminExt);
|
||||||
|
//
|
||||||
|
//
|
||||||
|
// return renderSuccess(admin);
|
||||||
|
// }
|
||||||
|
}
|
||||||
@@ -0,0 +1,77 @@
|
|||||||
|
package com.cym.model;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import jakarta.persistence.Entity;
|
||||||
|
import jakarta.persistence.Id;
|
||||||
|
|
||||||
|
@Entity
|
||||||
|
@Schema(description = "商品")
|
||||||
|
public class Goods {
|
||||||
|
|
||||||
|
@Id
|
||||||
|
@Schema(description = "商品ID")
|
||||||
|
public Integer id;
|
||||||
|
|
||||||
|
@Schema(description = "商品名称")
|
||||||
|
public String name;
|
||||||
|
|
||||||
|
@Schema(description = "商品描述")
|
||||||
|
public String description;
|
||||||
|
|
||||||
|
@Schema(description = "商品价格")
|
||||||
|
public Double price;
|
||||||
|
|
||||||
|
@Schema(description = "商品标题")
|
||||||
|
public String title;
|
||||||
|
|
||||||
|
@Schema(description = "商品图片")
|
||||||
|
public String image;
|
||||||
|
|
||||||
|
public Integer getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(Integer id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDescription() {
|
||||||
|
return description;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDescription(String description) {
|
||||||
|
this.description = description;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Double getPrice() {
|
||||||
|
return price;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPrice(Double price) {
|
||||||
|
this.price = price;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTitle() {
|
||||||
|
return title;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTitle(String title) {
|
||||||
|
this.title = title;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getImage() {
|
||||||
|
return image;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setImage(String image) {
|
||||||
|
this.image = image;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -9,7 +9,6 @@ import jakarta.persistence.Id;
|
|||||||
import com.cym.bean.CreateTime;
|
import com.cym.bean.CreateTime;
|
||||||
import com.cym.bean.InitValue;
|
import com.cym.bean.InitValue;
|
||||||
import io.swagger.v3.oas.annotations.media.Schema;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import io.swagger.v3.oas.annotations.media.SchemaProperty;
|
|
||||||
|
|
||||||
@Schema(description ="用户")
|
@Schema(description ="用户")
|
||||||
@Entity
|
@Entity
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ public class AdminExampleService {
|
|||||||
JpaHelper jpaHelper;
|
JpaHelper jpaHelper;
|
||||||
|
|
||||||
public Admin login(String name, String pass) {
|
public Admin login(String name, String pass) {
|
||||||
pass = SecureUtil.md5(pass);
|
// pass = SecureUtil.md5(pass);
|
||||||
return jpaHelper.findOneByQuery(new ConditionAndWrapper().eq(Admin::getName, name).eq(Admin::getPass, pass), Admin.class);
|
return jpaHelper.findOneByQuery(new ConditionAndWrapper().eq(Admin::getName, name).eq(Admin::getPass, pass), Admin.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,15 +5,23 @@ import org.springframework.stereotype.Service;
|
|||||||
|
|
||||||
import com.cym.bean.Page;
|
import com.cym.bean.Page;
|
||||||
import com.cym.model.Example;
|
import com.cym.model.Example;
|
||||||
|
import com.cym.utils.ConditionAndWrapper;
|
||||||
import com.cym.utils.JpaHelper;
|
import com.cym.utils.JpaHelper;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
|
||||||
@Service
|
@Service
|
||||||
public class ExampleService {
|
public class ExampleService {
|
||||||
@Autowired
|
@Autowired
|
||||||
JpaHelper jpaHelper;
|
JpaHelper jpaHelper;
|
||||||
|
|
||||||
public Page search(Page page) {
|
public Page search(Page page, String keyword) {
|
||||||
page = jpaHelper.findPageByQuery(page, Example.class);
|
ConditionAndWrapper conditionAndWrapper = new ConditionAndWrapper();
|
||||||
|
if (StrUtil.isNotEmpty(keyword)) {
|
||||||
|
conditionAndWrapper.like(Example::getName, keyword);
|
||||||
|
}
|
||||||
|
|
||||||
|
page = jpaHelper.findPageByQuery(conditionAndWrapper, page, Example.class);
|
||||||
|
|
||||||
return page;
|
return page;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ public class MenuUtils {
|
|||||||
menuCategory = new MenuCategory("IDC管理", "product");
|
menuCategory = new MenuCategory("IDC管理", "product");
|
||||||
menuCategory.getMenus().add(new Menu("adminPage/machineOrderAdmin?pageSize=20", "售出主机"));
|
menuCategory.getMenus().add(new Menu("adminPage/machineOrderAdmin?pageSize=20", "售出主机"));
|
||||||
menuCategory.getMenus().add(new Menu("adminPage/machine?pageSize=50", "服务器产品"));
|
menuCategory.getMenus().add(new Menu("adminPage/machine?pageSize=50", "服务器产品"));
|
||||||
menuCategory.getMenus().add(new Menu("adminPage/machineVps?pageSize=50", "云主机产品"));
|
menuCategory.getMenus().add(new Menu("adminPage/machineVps?pageSize=50", "云服务器产品"));
|
||||||
menuCategory.getMenus().add(new Menu("adminPage/machineRoom?pageSize=20", "机房管理"));
|
menuCategory.getMenus().add(new Menu("adminPage/machineRoom?pageSize=20", "机房管理"));
|
||||||
menuCategory.getMenus().add(new Menu("adminPage/machineProvider?pageSize=20", "供应商管理"));
|
menuCategory.getMenus().add(new Menu("adminPage/machineProvider?pageSize=20", "供应商管理"));
|
||||||
menuCategory.getMenus().add(new Menu("adminPage/icp?pageSize=20", "ICP白名单"));
|
menuCategory.getMenus().add(new Menu("adminPage/icp?pageSize=20", "ICP白名单"));
|
||||||
@@ -95,6 +95,12 @@ public class MenuUtils {
|
|||||||
menuCategory.getMenus().add(new Menu("adminPage/telegramSendLog?pageSize=20", "Telegram日志"));
|
menuCategory.getMenus().add(new Menu("adminPage/telegramSendLog?pageSize=20", "Telegram日志"));
|
||||||
menuCategoryList.add(menuCategory);
|
menuCategoryList.add(menuCategory);
|
||||||
|
|
||||||
|
menuCategory = new MenuCategory("测试管理", "other");
|
||||||
|
menuCategory.getMenus().add(new Menu("test?pageSize=20", "测试"));
|
||||||
|
// menuCategory.getMenus().add(new Menu("adminPage/emailTemplate?pageSize=20", "邮件模板"));
|
||||||
|
// menuCategory.getMenus().add(new Menu("adminPage/telegramSendLog?pageSize=20", "Telegram日志"));
|
||||||
|
menuCategoryList.add(menuCategory);
|
||||||
|
|
||||||
return menuCategoryList;
|
return menuCategoryList;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,13 @@
|
|||||||
|
#spring:
|
||||||
|
# datasource:
|
||||||
|
# printsql: true
|
||||||
|
# url: jdbc:mysql://222.186.15.41:3306/cdnWebUI
|
||||||
|
# username: cdnWebUI
|
||||||
|
# password: cdnWebUI
|
||||||
|
|
||||||
spring:
|
spring:
|
||||||
datasource:
|
datasource:
|
||||||
printsql: true
|
printsql: true
|
||||||
url: jdbc:mysql://127.0.0.1:3306/cdnWebUI
|
url: jdbc:mysql://localhost:3306/jpatest
|
||||||
username: root
|
username: root
|
||||||
password: root
|
password: 486934
|
||||||
|
|||||||
@@ -75,6 +75,8 @@ springdoc:
|
|||||||
packages-to-scan: com.cym.controller.webapi.admin
|
packages-to-scan: com.cym.controller.webapi.admin
|
||||||
- group: '用户端'
|
- group: '用户端'
|
||||||
packages-to-scan: com.cym.controller.webapi.user
|
packages-to-scan: com.cym.controller.webapi.user
|
||||||
|
- group: 'tt'
|
||||||
|
packages-to-scan: com.cym.controller.page
|
||||||
|
|
||||||
knife4j:
|
knife4j:
|
||||||
enable: true
|
enable: true
|
||||||
@@ -92,7 +94,7 @@ logging:
|
|||||||
com.binance.connector.client.utils.RequestHandler: OFF
|
com.binance.connector.client.utils.RequestHandler: OFF
|
||||||
|
|
||||||
ali:
|
ali:
|
||||||
host: https://my.freecdn.pw/
|
host: https://my.freecdn.vip/
|
||||||
appId: 2017021705714497
|
appId: 2017021705714497
|
||||||
privateKey: MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQCGfBMOwx2blHjBWbEgg/68GAfRFRGgoY8GAn1tOWWNfCYD7zCfBFIZDNc6ptOPEc2q2JH8YB5wgBDU4i/Usi7zkeYIcuhgTF8MK7+6GJkyvFuQk7SNcEhdy0xDD3QgygM752EDp57i3jISkYWEK2swbSjAjrj4FurLbXcCsKhiKVkGGslEPtBRetIMDk+ZnXfC5iMVa0OHIsVfw7xzLBKadA7+5ZPiQ+jpw9CNkXuQOD1cwh57u2Qm0e3q/QFCDnKCeiJ5TIspgbtweK4uxz5vBzvaFnYdup0reA9P2fBhEZkuQjAFAGGJuVl66OzBWEGmA0PvTx71Sl18PtLhF2KJAgMBAAECggEAOD6R9d2Sd2vr6OlrE+9ATUg7lK0cFzMaTughrtmPaFHg0Epr6kVzVHizVxtIZZCLlIVI4OUONfzJjU8fs/PlgQamzyfHmea25a8yW1FIWRi/rsKng3PPQDLzLSS8a64xFg+Z2l5zK+zDwlJMJc/G35T3szi9kTx8bCHW4TAi7BJEa/jNa2CIDKdT43gBmU5r9u8sQ0eLlNk72xvlSVFWIVRjffODhWOz5a2oK8IsJVV+fbBH2v+lY728l8fTT4V2MY2Inj2uzRfylq8aoWB7xjQkibBiLqIhjRODK2aVWiwCCnvq/zidqssOJ6CzcWpIxzDOrgIuj2bh44URs3afVQKBgQDSvBuK5v5Chdgf2S5nGo3tQBDXD+IX8o53HhFuDU2gbse8b95ZYWuFgXPGDx+NLrvlnJd+imaIk2lbUL5abxbJSEVXh+vSnh3U73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GXgrZ4PRJuo0GTOAZZ93ZpltwIDAQAB
|
||||||
|
|||||||
@@ -0,0 +1,113 @@
|
|||||||
|
// var menuUrl;
|
||||||
|
|
||||||
|
$(function() {
|
||||||
|
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function search() {
|
||||||
|
$("input[name='pageNum']").val(1);
|
||||||
|
$("#searchForm").submit();
|
||||||
|
}
|
||||||
|
|
||||||
|
function add() {
|
||||||
|
$("#id").val("");
|
||||||
|
$("#name").val("");
|
||||||
|
$("#title").val("");
|
||||||
|
$("#image").val("");
|
||||||
|
$("#price").val("");
|
||||||
|
$("#description").val("");
|
||||||
|
|
||||||
|
form.render();
|
||||||
|
showWindow("添加");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function showWindow(title) {
|
||||||
|
layer.open({
|
||||||
|
type: 1,
|
||||||
|
title: title,
|
||||||
|
area: ['400px', '400px'], // 宽高
|
||||||
|
content: $('#windowDiv')
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function addOver() {
|
||||||
|
// if ($("#name").val().trim() === '') {
|
||||||
|
// layer.msg("未填写名称");
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
type: 'POST',
|
||||||
|
url: ctx + 'test/add',
|
||||||
|
data: $('#addForm').serialize(),
|
||||||
|
dataType: 'json',
|
||||||
|
success: function(data) {
|
||||||
|
if (data.success) {
|
||||||
|
location.reload();
|
||||||
|
} else {
|
||||||
|
layer.msg(data.msg);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function() {
|
||||||
|
layer.alert("请求失败,请刷新重试");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function edit(id) {
|
||||||
|
$("#id").val(id);
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
type: 'GET',
|
||||||
|
url: ctx + 'test/detail',
|
||||||
|
dataType: 'json',
|
||||||
|
data: {
|
||||||
|
id: id
|
||||||
|
},
|
||||||
|
success: function(data) {
|
||||||
|
if (data.success) {
|
||||||
|
var example = data.obj;
|
||||||
|
$("#id").val(example.id);
|
||||||
|
$("#name").val(example.name);
|
||||||
|
$("#title").val(example.title);
|
||||||
|
$("#image").val(example.image);
|
||||||
|
$("#price").val(example.price);
|
||||||
|
$("#description").val(example.description);
|
||||||
|
|
||||||
|
form.render();
|
||||||
|
showWindow("编辑");
|
||||||
|
} else {
|
||||||
|
layer.msg(data.msg);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function() {
|
||||||
|
layer.alert("请求失败,请刷新重试");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function dele(id) {
|
||||||
|
if (confirm("确认删除?")) {
|
||||||
|
$.ajax({
|
||||||
|
type: 'POST',
|
||||||
|
url: ctx + 'test/delete',
|
||||||
|
data: {
|
||||||
|
id: id
|
||||||
|
},
|
||||||
|
dataType: 'json',
|
||||||
|
success: function(data) {
|
||||||
|
if (data.success) {
|
||||||
|
location.reload();
|
||||||
|
} else {
|
||||||
|
layer.msg(data.msg)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function() {
|
||||||
|
layer.alert("请求失败,请刷新重试");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -26,11 +26,24 @@
|
|||||||
<legend>演示模块</legend>
|
<legend>演示模块</legend>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
<form action="${ctx}/examplePage/example" id="searchForm" method="post">
|
<form action="${ctx}/adminPage/example" id="searchForm" method="post">
|
||||||
<div class="layui-form">
|
<div class="layui-form">
|
||||||
<div class="layui-inline">
|
<div class="layui-inline">
|
||||||
<button type="button" class="layui-btn layui-btn-normal layui-btn-sm" onclick="add()">添加模块</button>
|
<button type="button" class="layui-btn layui-btn-normal layui-btn-sm" onclick="add()">添加模块</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="layui-inline">
|
||||||
|
<label class="layui-form-label" style="width: 70px;">关键字</label>
|
||||||
|
<div class="layui-input-inline" style="width: 150px;">
|
||||||
|
<input type="text" name="keyword" value="${keyword}" class="layui-input">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="layui-inline">
|
||||||
|
<button type="button" class="layui-btn layui-btn-sm" onclick="search()">搜索</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<input type="hidden" name="pageNum" value="${page.pageNum}">
|
<input type="hidden" name="pageNum" value="${page.pageNum}">
|
||||||
<input type="hidden" name="pageSize" value="${page.pageSize}">
|
<input type="hidden" name="pageSize" value="${page.pageSize}">
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -12,6 +12,11 @@
|
|||||||
<a href="${ctx}/adminPage/example?pageSize=20">演示模块</a>
|
<a href="${ctx}/adminPage/example?pageSize=20">演示模块</a>
|
||||||
</dd>
|
</dd>
|
||||||
</dl>
|
</dl>
|
||||||
|
<dl class="layui-nav-child">
|
||||||
|
<dd>
|
||||||
|
<a href="${ctx}/test?pageSize=20">测试模块</a>
|
||||||
|
</dd>
|
||||||
|
</dl>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
<a href="${ctx}/web/machineBuy?pageSize=20">服务器购买</a>
|
<a href="${ctx}/web/machineBuy?pageSize=20">服务器购买</a>
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
<a href="${ctx}/web/machineVpsBuy?pageSize=20">云主机购买</a>
|
<a href="${ctx}/web/machineVpsBuy?pageSize=20">云服务器购买</a>
|
||||||
</p>
|
</p>
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,149 @@
|
|||||||
|
<!DOCTYPE HTML>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<#include "/common.html"/>
|
||||||
|
<style type="text/css">
|
||||||
|
.layui-form-label {
|
||||||
|
width: 140px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.layui-input-block {
|
||||||
|
margin-left: 170px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
</head>
|
||||||
|
<body class="layui-layout-body">
|
||||||
|
<div class="layui-layout layui-layout-admin">
|
||||||
|
|
||||||
|
<#include "/header.html"/>
|
||||||
|
<#include "/menu.html"/>
|
||||||
|
|
||||||
|
<div class="layui-body">
|
||||||
|
<!-- 内容主体区域 -->
|
||||||
|
<div style="padding: 15px">
|
||||||
|
<fieldset class="layui-elem-field layui-field-title">
|
||||||
|
<legend>测试</legend>
|
||||||
|
</fieldset>
|
||||||
|
|
||||||
|
<form action="${ctx}/test" id="searchForm" method="post">
|
||||||
|
<div class="layui-form">
|
||||||
|
<div class="layui-inline">
|
||||||
|
<button type="button" class="layui-btn layui-btn-normal layui-btn-sm" onclick="add()">添加</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="layui-inline">
|
||||||
|
<label class="layui-form-label" style="width: 70px;">关键字</label>
|
||||||
|
<div class="layui-input-inline" style="width: 150px;">
|
||||||
|
<input type="text" name="keyword" value="${keyword}" class="layui-input">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="layui-inline">
|
||||||
|
<button type="button" class="layui-btn layui-btn-sm" onclick="search()">搜索</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<input type="hidden" name="pageNum" value="${page.pageNum}">
|
||||||
|
<input type="hidden" name="pageSize" value="${page.pageSize}">
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
|
||||||
|
<table class="layui-table" lay-size="sm">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>图片</th>
|
||||||
|
<th>名称</th>
|
||||||
|
<th>标题</th>
|
||||||
|
<th>价格</th>
|
||||||
|
<th>操作</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<#list page.list as example>
|
||||||
|
<tr>
|
||||||
|
<td>${example.image}</td>
|
||||||
|
<td>
|
||||||
|
${example.name}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
${example.title}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
${example.price}
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td>
|
||||||
|
<div class="layui-inline">
|
||||||
|
<button class="layui-btn layui-btn-sm" onclick="edit('${example.id}')">编辑</button>
|
||||||
|
</div>
|
||||||
|
<div class="layui-inline">
|
||||||
|
<button class="layui-btn layui-btn-danger layui-btn-sm" onclick="dele('${example.id}')">删除</button>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</#list>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
<div id="pageInfo"></div>
|
||||||
|
|
||||||
|
<#include '/copyright.html'/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div style="height: 0px; width: 0px; overflow: hidden;">
|
||||||
|
<!-- 弹出框 -->
|
||||||
|
<div class="layui-form" id="windowDiv" style="padding: 15px; display: none">
|
||||||
|
<form id="addForm">
|
||||||
|
<input type="hidden" name="id" id="id">
|
||||||
|
|
||||||
|
<div class="layui-form-item">
|
||||||
|
<label class="layui-form-label">图片</label>
|
||||||
|
<div class="layui-input-inline">
|
||||||
|
<input type="text" name="image" id="image" class="layui-input" autocomplete="off">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="layui-form-item">
|
||||||
|
<label class="layui-form-label">名称</label>
|
||||||
|
<div class="layui-input-inline">
|
||||||
|
<input type="text" name="name" id="name" class="layui-input" autocomplete="off">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="layui-form-item">
|
||||||
|
<label class="layui-form-label">标题</label>
|
||||||
|
<div class="layui-input-inline">
|
||||||
|
<input type="text" name="title" id="title" class="layui-input" autocomplete="off">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="layui-form-item">
|
||||||
|
<label class="layui-form-label">价格</label>
|
||||||
|
<div class="layui-input-inline">
|
||||||
|
<input type="text" name="price" id="price" class="layui-input" autocomplete="off">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="layui-form-item">
|
||||||
|
<label class="layui-form-label">描述</label>
|
||||||
|
<div class="layui-input-inline">
|
||||||
|
<textarea name="description" id="description" class="layui-textarea" autocomplete="off"></textarea>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="layui-form-item center">
|
||||||
|
<button type="button" class="layui-btn layui-btn-normal layui-btn-sm" onclick="addOver()">提交</button>
|
||||||
|
<button type="button" class="layui-btn layui-btn-sm" onclick="layer.closeAll()">关闭</button>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<#include '/script.html'/>
|
||||||
|
<script src="${ctx}/js/test/index.js?v=${jsrandom}" type="text/javascript"></script>
|
||||||
|
</body>
|
||||||
|
|
||||||
|
</html>
|
||||||
@@ -7,17 +7,20 @@ import org.springframework.boot.test.context.SpringBootTest;
|
|||||||
import com.cym.CdnWebUI;
|
import com.cym.CdnWebUI;
|
||||||
import com.cym.utils.JpaHelper;
|
import com.cym.utils.JpaHelper;
|
||||||
|
|
||||||
|
import cn.hutool.crypto.SecureUtil;
|
||||||
|
|
||||||
@SpringBootTest(classes = CdnWebUI.class, webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
|
@SpringBootTest(classes = CdnWebUI.class, webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
|
||||||
public class MainTest {
|
public class MainTest {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
JpaHelper jpaHelper;
|
JpaHelper jpaHelper;
|
||||||
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void test() throws Exception {
|
public void test() throws Exception {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void main(String[] args) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user