Compare commits
	
		
			No commits in common. "ee76489951a1b01e3c469ae44a1680a715586689" and "6b4643e4c0bae60ed53b51ad6bed1a8475ec3a4c" have entirely different histories.
		
	
	
		
			ee76489951
			...
			6b4643e4c0
		
	
		
| @ -9,7 +9,7 @@ | ||||
|     </parent> | ||||
|     <modelVersion>4.0.0</modelVersion> | ||||
|     <packaging>jar</packaging> | ||||
|     <artifactId>nuxt-site</artifactId> | ||||
|     <artifactId>ruoyi-admin</artifactId> | ||||
| 
 | ||||
|     <description> | ||||
|         web服务入口 | ||||
|  | ||||
| @ -265,25 +265,4 @@ public class WebController extends BaseController { | ||||
|         WebDetailVO webDetailVO = new WebDetailVO(); | ||||
|         return R.ok(prodNewService.getProdNewInfo(id)); | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|      * 全站搜索 | ||||
|      * @author vinjor-M | ||||
|      * @date 10:04 2025/7/8 | ||||
|      * @return com.ruoyi.common.core.domain.AjaxResult | ||||
|      **/ | ||||
|     @ApiOperation("全站搜索") | ||||
|     @ApiImplicitParams(value = { | ||||
|             @ApiImplicitParam(name = "tenantId", value = "站点唯一码", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class), | ||||
|             @ApiImplicitParam(name = "pageNum", value = "页码(1开始)", required = true, dataType = "int", paramType = "query", dataTypeClass = Integer.class), | ||||
|             @ApiImplicitParam(name = "pageSize", value = "每页显示数量", required = true, dataType = "int", paramType = "query", dataTypeClass = Integer.class), | ||||
|             @ApiImplicitParam(name = "text", value = "搜索内容", required = true, dataType = "string", paramType = "query", dataTypeClass = String.class) | ||||
|     }) | ||||
|     @GetMapping("/searchText") | ||||
|     public R<IPage<BusiProdNew>> searchText(String tenantId,String text, | ||||
|                                      @RequestParam(name = "pageNum", defaultValue = "1") Integer pageNum, | ||||
|                                      @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize){ | ||||
|         Page<BusiProdNew> page = new Page<>(pageNum,pageSize); | ||||
|         return R.ok(prodNewService.searchTextAll(tenantId,text,page)); | ||||
|     } | ||||
| } | ||||
|  | ||||
| @ -63,15 +63,4 @@ public interface IBusiProdNewService extends IService<BusiProdNew> | ||||
|      * @return com.ruoyi.busi.vo.WebDetailVO | ||||
|     **/ | ||||
|     WebDetailVO getProdNewInfo(String id); | ||||
| 
 | ||||
|     /** | ||||
|      * 全站搜索产品和文章 | ||||
|      * @author vinjor-M | ||||
|      * @date 13:55 2025/7/9 | ||||
|      * @param tenantId 站点ID | ||||
|  * @param text 搜索内容 | ||||
|  * @param page 分页对象 | ||||
|      * @return com.baomidou.mybatisplus.core.metadata.IPage<com.ruoyi.busi.vo.ProdNewVO> | ||||
|     **/ | ||||
|     IPage<BusiProdNew> searchTextAll(String tenantId, String text,Page<BusiProdNew> page); | ||||
| } | ||||
|  | ||||
| @ -13,8 +13,10 @@ import org.springframework.beans.BeanUtils; | ||||
| import org.springframework.beans.factory.annotation.Autowired; | ||||
| import org.springframework.stereotype.Service; | ||||
| 
 | ||||
| import java.util.*; | ||||
| import java.util.stream.Collectors; | ||||
| import java.util.ArrayList; | ||||
| import java.util.HashMap; | ||||
| import java.util.List; | ||||
| import java.util.Map; | ||||
| 
 | ||||
| /** | ||||
|  * 网站栏目Service业务层处理 | ||||
| @ -50,10 +52,7 @@ public class BusiCategoryServiceImpl extends ServiceImpl<BusiCategoryMapper, Bus | ||||
|         } | ||||
|         lambdaQueryWrapper.orderByAsc(BusiCategory::getSort); | ||||
|         List<BusiCategory> list = list(lambdaQueryWrapper); | ||||
|         List<BusiCategoryVO> rtnList = buildCategoryTree(list); | ||||
|         return rtnList.stream().sorted(Comparator.comparing(BusiCategoryVO::getSort, | ||||
|                 Comparator.nullsLast(Comparator.reverseOrder()))) | ||||
|                 .collect(Collectors.toList()); | ||||
|         return buildCategoryTree(list); | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|  | ||||
| @ -180,27 +180,4 @@ public class BusiProdNewServiceImpl extends ServiceImpl<BusiProdNewMapper,BusiPr | ||||
|         webDetailVO.setNext(busiProdNewMapper.selectPreOrNext(prodNew.getDataType(),prodNew.getSort(),"next",prodNew.getTenantId(),prodNew.getCatgId())); | ||||
|         return webDetailVO; | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|      * 全站搜索产品和文章 | ||||
|      * | ||||
|      * @param tenantId 站点ID | ||||
|      * @param text     搜索内容 | ||||
|      * @param page     分页对象 | ||||
|      * @return com.baomidou.mybatisplus.core.metadata.IPage<com.ruoyi.busi.vo.ProdNewVO> | ||||
|      * @author vinjor-M | ||||
|      * @date 13:55 2025/7/9 | ||||
|      **/ | ||||
|     @Override | ||||
|     public IPage<BusiProdNew> searchTextAll(String tenantId, String text, Page<BusiProdNew> page) { | ||||
|         LambdaQueryWrapper<BusiProdNew> queryWrapper = new LambdaQueryWrapper<BusiProdNew>() | ||||
|                 .eq(BusiProdNew::getTenantId,tenantId) | ||||
|                 .eq(BusiProdNew::getIfPublic,true) | ||||
|                 .and(wq->wq | ||||
|                         .like(BusiProdNew::getTitle,text) | ||||
|                         .or().like(BusiProdNew::getDescription,text) | ||||
|                         .or().like(BusiProdNew::getContent,text)) | ||||
|                 .orderByDesc(BusiProdNew::getSort); | ||||
|         return this.page(page,queryWrapper); | ||||
|     } | ||||
| } | ||||
|  | ||||
| @ -27,6 +27,7 @@ import io.swagger.annotations.ApiOperation; | ||||
|  *  | ||||
|  * @author ruoyi | ||||
|  */ | ||||
| @Api("用户信息管理") | ||||
| @RestController | ||||
| @RequestMapping("/test/user") | ||||
| public class TestController extends BaseController | ||||
| @ -37,6 +38,7 @@ public class TestController extends BaseController | ||||
|         users.put(2, new UserEntity(2, "ry", "admin123", "15666666666")); | ||||
|     } | ||||
| 
 | ||||
|     @ApiOperation("获取用户列表") | ||||
|     @GetMapping("/list") | ||||
|     public R<List<UserEntity>> userList() | ||||
|     { | ||||
| @ -44,6 +46,8 @@ public class TestController extends BaseController | ||||
|         return R.ok(userList); | ||||
|     } | ||||
| 
 | ||||
|     @ApiOperation("获取用户详细") | ||||
|     @ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "int", paramType = "path", dataTypeClass = Integer.class) | ||||
|     @GetMapping("/{userId}") | ||||
|     public R<UserEntity> getUser(@PathVariable Integer userId) | ||||
|     { | ||||
| @ -57,6 +61,13 @@ public class TestController extends BaseController | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     @ApiOperation("新增用户") | ||||
|     @ApiImplicitParams({ | ||||
|         @ApiImplicitParam(name = "userId", value = "用户id", dataType = "Integer", dataTypeClass = Integer.class), | ||||
|         @ApiImplicitParam(name = "username", value = "用户名称", dataType = "String", dataTypeClass = String.class), | ||||
|         @ApiImplicitParam(name = "password", value = "用户密码", dataType = "String", dataTypeClass = String.class), | ||||
|         @ApiImplicitParam(name = "mobile", value = "用户手机", dataType = "String", dataTypeClass = String.class) | ||||
|     }) | ||||
|     @PostMapping("/save") | ||||
|     public R<String> save(UserEntity user) | ||||
|     { | ||||
| @ -68,6 +79,7 @@ public class TestController extends BaseController | ||||
|         return R.ok(); | ||||
|     } | ||||
| 
 | ||||
|     @ApiOperation("更新用户") | ||||
|     @PutMapping("/update") | ||||
|     public R<String> update(@RequestBody UserEntity user) | ||||
|     { | ||||
| @ -84,6 +96,8 @@ public class TestController extends BaseController | ||||
|         return R.ok(); | ||||
|     } | ||||
| 
 | ||||
|     @ApiOperation("删除用户信息") | ||||
|     @ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "int", paramType = "path", dataTypeClass = Integer.class) | ||||
|     @DeleteMapping("/{userId}") | ||||
|     public R<String> delete(@PathVariable Integer userId) | ||||
|     { | ||||
|  | ||||
| @ -133,7 +133,7 @@ swagger: | ||||
|   # 是否开启swagger | ||||
|   enabled: true | ||||
|   # 请求前缀 | ||||
|   pathMapping: | ||||
|   pathMapping: /dev-api | ||||
| 
 | ||||
| # 防止XSS攻击 | ||||
| xss: | ||||
|  | ||||
| @ -1,7 +1,7 @@ | ||||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <configuration> | ||||
|     <!-- 日志存放路径 --> | ||||
| 	<property name="log.path" value="/www/wwwlogs/java/springboot/nuxt-site-logs" /> | ||||
| 	<property name="log.path" value="/home/ruoyi/logs" /> | ||||
|     <!-- 日志输出格式 --> | ||||
| 	<property name="log.pattern" value="%d{HH:mm:ss.SSS} [%thread] %-5level %logger{20} - [%method,%line] - %msg%n" /> | ||||
| 
 | ||||
|  | ||||
| @ -1,11 +1,11 @@ | ||||
| # 页面标题 | ||||
| VUE_APP_TITLE = 成事达管理平台 | ||||
| VUE_APP_TITLE = 通告快接管理后台 | ||||
| 
 | ||||
| # 生产环境配置 | ||||
| ENV = 'production' | ||||
| 
 | ||||
| # 成事达管理平台/生产环境 | ||||
| VUE_APP_BASE_API = 'http://122.51.230.86:8099' | ||||
| # 通告快接管理后台/生产环境 | ||||
| VUE_APP_BASE_API = 'https://www.ddtg.site/noticeApi' | ||||
| 
 | ||||
| # websocket | ||||
| VUE_APP_WEBSOCKET = 'ws://122.51.230.86:8099/ws/asset/' | ||||
| VUE_APP_WEBSOCKET = 'ws://localhost:8099/ws/asset/' | ||||
|  | ||||
| @ -30,7 +30,7 @@ | ||||
|         </el-col> | ||||
|         <el-col :span="8"> | ||||
|           <el-form-item label="排序" prop="sort"> | ||||
|             <el-input v-model="form.sort" type="number" placeholder="请输入排序" /> | ||||
|             <el-input v-model="form.sort" placeholder="请输入排序" /> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|       </el-row> | ||||
| @ -56,12 +56,12 @@ | ||||
| 
 | ||||
|       <el-row v-if="form.catgType == 'cp'" :gutter="20"> | ||||
|         <el-col :span="12"> | ||||
|           <el-form-item label="产品上方内容" prop="prodUp"> | ||||
|           <el-form-item label="产品上方内容html" prop="prodUp"> | ||||
|             <editor v-model="form.prodUp" :min-height="160"/> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|         <el-col :span="12"> | ||||
|           <el-form-item label="产品下方内容" prop="prodDown"> | ||||
|           <el-form-item label="产品下方内容html" prop="prodDown"> | ||||
|             <editor v-model="form.prodDown" :min-height="160"/> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
| @ -70,7 +70,7 @@ | ||||
| 
 | ||||
|       <el-row v-if="form.catgType == 'dym' || form.catgType == 'xp'"> | ||||
|         <el-col> | ||||
|           <el-form-item label="内容" prop="content"> | ||||
|           <el-form-item label="内容html" prop="content"> | ||||
|           <editor v-model="form.content" :min-height="192"/> | ||||
|           </el-form-item> | ||||
|         </el-col> | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user