13 files modified
18 files added
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.controller; |
| | | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | | import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
| | | import lombok.AllArgsConstructor; |
| | | import javax.validation.Valid; |
| | | |
| | | import org.springblade.core.secure.BladeUser; |
| | | import org.springblade.core.mp.support.Condition; |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tool.api.R; |
| | | import org.springblade.core.tool.utils.Func; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.modules.category.entity.CategoryEntity; |
| | | import org.springblade.modules.category.vo.CategoryVO; |
| | | import org.springblade.modules.category.wrapper.CategoryWrapper; |
| | | import org.springblade.modules.category.service.ICategoryService; |
| | | import org.springblade.core.boot.ctrl.BladeController; |
| | | |
| | | /** |
| | | * 天地图poi 分类表 控制器 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @RestController |
| | | @AllArgsConstructor |
| | | @RequestMapping("blade-category/category") |
| | | @Api(value = "天地图poi 分类表", tags = "天地图poi 分类表接口") |
| | | public class CategoryController{ |
| | | |
| | | private final ICategoryService categoryService; |
| | | |
| | | /** |
| | | * 天地图poi 分类表 详情 |
| | | */ |
| | | @GetMapping("/detail") |
| | | @ApiOperationSupport(order = 1) |
| | | @ApiOperation(value = "详情", notes = "传入category") |
| | | public R<CategoryVO> detail(CategoryEntity category) { |
| | | CategoryEntity detail = categoryService.getOne(Condition.getQueryWrapper(category)); |
| | | return R.data(CategoryWrapper.build().entityVO(detail)); |
| | | } |
| | | /** |
| | | * 天地图poi 分类表 分页 |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperationSupport(order = 2) |
| | | @ApiOperation(value = "分页", notes = "传入category") |
| | | public R<IPage<CategoryVO>> list(CategoryEntity category, Query query) { |
| | | IPage<CategoryEntity> pages = categoryService.page(Condition.getPage(query), Condition.getQueryWrapper(category)); |
| | | return R.data(CategoryWrapper.build().pageVO(pages)); |
| | | } |
| | | |
| | | /** |
| | | * 天地图poi 分类表 自定义分页 |
| | | */ |
| | | @GetMapping("/page") |
| | | @ApiOperationSupport(order = 3) |
| | | @ApiOperation(value = "分页", notes = "传入category") |
| | | public R<IPage<CategoryVO>> page(CategoryVO category, Query query) { |
| | | IPage<CategoryVO> pages = categoryService.selectCategoryPage(Condition.getPage(query), category); |
| | | return R.data(pages); |
| | | } |
| | | |
| | | /** |
| | | * 天地图poi 分类表 新增 |
| | | */ |
| | | @PostMapping("/save") |
| | | @ApiOperationSupport(order = 4) |
| | | @ApiOperation(value = "新增", notes = "传入category") |
| | | public R save(@Valid @RequestBody CategoryEntity category) { |
| | | return R.status(categoryService.save(category)); |
| | | } |
| | | |
| | | /** |
| | | * 天地图poi 分类表 修改 |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "修改", notes = "传入category") |
| | | public R update(@Valid @RequestBody CategoryEntity category) { |
| | | return R.status(categoryService.updateById(category)); |
| | | } |
| | | |
| | | /** |
| | | * 天地图poi 分类表 新增或修改 |
| | | */ |
| | | @PostMapping("/submit") |
| | | @ApiOperationSupport(order = 6) |
| | | @ApiOperation(value = "新增或修改", notes = "传入category") |
| | | public R submit(@Valid @RequestBody CategoryEntity category) { |
| | | return R.status(categoryService.saveOrUpdate(category)); |
| | | } |
| | | |
| | | /** |
| | | * 天地图poi 分类表 删除 |
| | | */ |
| | | @PostMapping("/remove") |
| | | @ApiOperationSupport(order = 7) |
| | | @ApiOperation(value = "逻辑删除", notes = "传入ids") |
| | | public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
| | | return R.status(categoryService.removeByIds(Func.toLongList(ids))); |
| | | } |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.controller; |
| | | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | | import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
| | | import lombok.AllArgsConstructor; |
| | | import javax.validation.Valid; |
| | | |
| | | import org.springblade.core.secure.BladeUser; |
| | | import org.springblade.core.mp.support.Condition; |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tool.api.R; |
| | | import org.springblade.core.tool.utils.Func; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.modules.category.entity.CategoryLabelEntity; |
| | | import org.springblade.modules.category.vo.CategoryLabelVO; |
| | | import org.springblade.modules.category.wrapper.CategoryLabelWrapper; |
| | | import org.springblade.modules.category.service.ICategoryLabelService; |
| | | import org.springblade.core.boot.ctrl.BladeController; |
| | | |
| | | /** |
| | | * 场所标签临时表 控制器 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @RestController |
| | | @AllArgsConstructor |
| | | @RequestMapping("blade-categoryLabel/categoryLabel") |
| | | @Api(value = "场所标签临时表", tags = "场所标签临时表接口") |
| | | public class CategoryLabelController{ |
| | | |
| | | private final ICategoryLabelService categoryLabelService; |
| | | |
| | | /** |
| | | * 场所标签临时表 详情 |
| | | */ |
| | | @GetMapping("/detail") |
| | | @ApiOperationSupport(order = 1) |
| | | @ApiOperation(value = "详情", notes = "传入categoryLabel") |
| | | public R<CategoryLabelVO> detail(CategoryLabelEntity categoryLabel) { |
| | | CategoryLabelEntity detail = categoryLabelService.getOne(Condition.getQueryWrapper(categoryLabel)); |
| | | return R.data(CategoryLabelWrapper.build().entityVO(detail)); |
| | | } |
| | | /** |
| | | * 场所标签临时表 分页 |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperationSupport(order = 2) |
| | | @ApiOperation(value = "分页", notes = "传入categoryLabel") |
| | | public R<IPage<CategoryLabelVO>> list(CategoryLabelEntity categoryLabel, Query query) { |
| | | IPage<CategoryLabelEntity> pages = categoryLabelService.page(Condition.getPage(query), Condition.getQueryWrapper(categoryLabel)); |
| | | return R.data(CategoryLabelWrapper.build().pageVO(pages)); |
| | | } |
| | | |
| | | /** |
| | | * 场所标签临时表 自定义分页 |
| | | */ |
| | | @GetMapping("/page") |
| | | @ApiOperationSupport(order = 3) |
| | | @ApiOperation(value = "分页", notes = "传入categoryLabel") |
| | | public R<IPage<CategoryLabelVO>> page(CategoryLabelVO categoryLabel, Query query) { |
| | | IPage<CategoryLabelVO> pages = categoryLabelService.selectCategoryLabelPage(Condition.getPage(query), categoryLabel); |
| | | return R.data(pages); |
| | | } |
| | | |
| | | /** |
| | | * 场所标签临时表 新增 |
| | | */ |
| | | @PostMapping("/save") |
| | | @ApiOperationSupport(order = 4) |
| | | @ApiOperation(value = "新增", notes = "传入categoryLabel") |
| | | public R save(@Valid @RequestBody CategoryLabelEntity categoryLabel) { |
| | | return R.status(categoryLabelService.save(categoryLabel)); |
| | | } |
| | | |
| | | /** |
| | | * 场所标签临时表 修改 |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "修改", notes = "传入categoryLabel") |
| | | public R update(@Valid @RequestBody CategoryLabelEntity categoryLabel) { |
| | | return R.status(categoryLabelService.updateById(categoryLabel)); |
| | | } |
| | | |
| | | /** |
| | | * 场所标签临时表 新增或修改 |
| | | */ |
| | | @PostMapping("/submit") |
| | | @ApiOperationSupport(order = 6) |
| | | @ApiOperation(value = "新增或修改", notes = "传入categoryLabel") |
| | | public R submit(@Valid @RequestBody CategoryLabelEntity categoryLabel) { |
| | | return R.status(categoryLabelService.saveOrUpdate(categoryLabel)); |
| | | } |
| | | |
| | | /** |
| | | * 场所标签临时表 删除 |
| | | */ |
| | | @PostMapping("/remove") |
| | | @ApiOperationSupport(order = 7) |
| | | @ApiOperation(value = "逻辑删除", notes = "传入ids") |
| | | public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
| | | return R.status(categoryLabelService.removeByIds(Func.toLongList(ids))); |
| | | } |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.dto; |
| | | |
| | | import org.springblade.modules.category.entity.CategoryEntity; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | /** |
| | | * 天地图poi 分类表 数据传输对象实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class CategoryDTO extends CategoryEntity { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.dto; |
| | | |
| | | import org.springblade.modules.category.entity.CategoryLabelEntity; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | /** |
| | | * 场所标签临时表 数据传输对象实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class CategoryLabelDTO extends CategoryLabelEntity { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.fasterxml.jackson.databind.annotation.JsonSerialize; |
| | | import com.fasterxml.jackson.databind.ser.std.ToStringSerializer; |
| | | import lombok.Data; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springblade.core.tenant.mp.TenantEntity; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * 天地图poi 分类表 实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @Data |
| | | @TableName("jczz_category") |
| | | @ApiModel(value = "Category对象", description = "天地图poi 分类表") |
| | | public class CategoryEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | | */ |
| | | @JsonSerialize(using = ToStringSerializer.class) |
| | | @ApiModelProperty("主键id") |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | /** |
| | | * 分类代码 |
| | | */ |
| | | @ApiModelProperty(value = "分类代码") |
| | | private String categoryNo; |
| | | /** |
| | | * 分类名称 |
| | | */ |
| | | @ApiModelProperty(value = "分类名称") |
| | | private String categoryName; |
| | | /** |
| | | * 父级编码 |
| | | */ |
| | | @ApiModelProperty(value = "父级编码") |
| | | private String parentNo; |
| | | /** |
| | | * 重要度 |
| | | */ |
| | | @ApiModelProperty(value = "重要度") |
| | | private String importance; |
| | | /** |
| | | * 备注 |
| | | */ |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | /** |
| | | * 层级 |
| | | */ |
| | | @ApiModelProperty(value = "层级") |
| | | private Integer level; |
| | | /** |
| | | * 提示词分类描述 |
| | | */ |
| | | @ApiModelProperty(value = "提示词分类描述") |
| | | private String description; |
| | | |
| | | /** |
| | | * 是否删除 |
| | | */ |
| | | @TableLogic |
| | | @ApiModelProperty("是否已删除 0:否 1:是") |
| | | private Integer isDeleted; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.fasterxml.jackson.databind.annotation.JsonSerialize; |
| | | import com.fasterxml.jackson.databind.ser.std.ToStringSerializer; |
| | | import lombok.Data; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springblade.core.tenant.mp.TenantEntity; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * 场所标签临时表 实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @Data |
| | | @TableName("jczz_category_label") |
| | | @ApiModel(value = "CategoryLabel对象", description = "场所标签临时表") |
| | | public class CategoryLabelEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | | */ |
| | | @JsonSerialize(using = ToStringSerializer.class) |
| | | @ApiModelProperty("主键id") |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | /** |
| | | * 分类代码 |
| | | */ |
| | | @ApiModelProperty(value = "分类代码") |
| | | private String categoryNo; |
| | | /** |
| | | * 分类名称 |
| | | */ |
| | | @ApiModelProperty(value = "分类名称") |
| | | private String categoryName; |
| | | /** |
| | | * 标签 |
| | | */ |
| | | @ApiModelProperty(value = "标签") |
| | | private String label; |
| | | /** |
| | | * 备注 |
| | | */ |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.mapper; |
| | | |
| | | import org.springblade.modules.category.entity.CategoryLabelEntity; |
| | | import org.springblade.modules.category.vo.CategoryLabelVO; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * 场所标签临时表 Mapper 接口 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | public interface CategoryLabelMapper extends BaseMapper<CategoryLabelEntity> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param categoryLabel |
| | | * @return |
| | | */ |
| | | List<CategoryLabelVO> selectCategoryLabelPage(IPage page, CategoryLabelVO categoryLabel); |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="org.springblade.modules.category.mapper.CategoryLabelMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="categoryLabelResultMap" type="org.springblade.modules.category.entity.CategoryLabelEntity"> |
| | | <result column="id" property="id"/> |
| | | <result column="category_no" property="categoryNo"/> |
| | | <result column="category_name" property="categoryName"/> |
| | | <result column="label" property="label"/> |
| | | <result column="remark" property="remark"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <select id="selectCategoryLabelPage" resultMap="categoryLabelResultMap"> |
| | | select * from jczz_category_label where is_deleted = 0 |
| | | </select> |
| | | |
| | | |
| | | </mapper> |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.mapper; |
| | | |
| | | import org.springblade.modules.category.entity.CategoryEntity; |
| | | import org.springblade.modules.category.vo.CategoryVO; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * 天地图poi 分类表 Mapper 接口 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | public interface CategoryMapper extends BaseMapper<CategoryEntity> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param category |
| | | * @return |
| | | */ |
| | | List<CategoryVO> selectCategoryPage(IPage page, CategoryVO category); |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="org.springblade.modules.category.mapper.CategoryMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="categoryResultMap" type="org.springblade.modules.category.entity.CategoryEntity"> |
| | | <result column="id" property="id"/> |
| | | <result column="category_no" property="categoryNo"/> |
| | | <result column="category_name" property="categoryName"/> |
| | | <result column="parent_no" property="parentNo"/> |
| | | <result column="importance" property="importance"/> |
| | | <result column="remark" property="remark"/> |
| | | <result column="level" property="level"/> |
| | | <result column="description" property="description"/> |
| | | <result column="is_deleted" property="isDeleted"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <select id="selectCategoryPage" resultMap="categoryResultMap"> |
| | | select * from jczz_category where is_deleted = 0 |
| | | </select> |
| | | |
| | | |
| | | </mapper> |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import org.springblade.modules.category.entity.CategoryLabelEntity; |
| | | import org.springblade.modules.category.vo.CategoryLabelVO; |
| | | import org.springblade.core.mp.base.BaseService; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 场所标签临时表 服务类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | public interface ICategoryLabelService extends IService<CategoryLabelEntity> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param categoryLabel |
| | | * @return |
| | | */ |
| | | IPage<CategoryLabelVO> selectCategoryLabelPage(IPage<CategoryLabelVO> page, CategoryLabelVO categoryLabel); |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import org.springblade.modules.category.entity.CategoryEntity; |
| | | import org.springblade.modules.category.vo.CategoryVO; |
| | | import org.springblade.core.mp.base.BaseService; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 天地图poi 分类表 服务类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | public interface ICategoryService extends IService<CategoryEntity> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param category |
| | | * @return |
| | | */ |
| | | IPage<CategoryVO> selectCategoryPage(IPage<CategoryVO> page, CategoryVO category); |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import org.springblade.modules.category.entity.CategoryLabelEntity; |
| | | import org.springblade.modules.category.vo.CategoryLabelVO; |
| | | import org.springblade.modules.category.mapper.CategoryLabelMapper; |
| | | import org.springblade.modules.category.service.ICategoryLabelService; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 场所标签临时表 服务实现类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @Service |
| | | public class CategoryLabelServiceImpl extends ServiceImpl<CategoryLabelMapper, CategoryLabelEntity> implements ICategoryLabelService { |
| | | |
| | | @Override |
| | | public IPage<CategoryLabelVO> selectCategoryLabelPage(IPage<CategoryLabelVO> page, CategoryLabelVO categoryLabel) { |
| | | return page.setRecords(baseMapper.selectCategoryLabelPage(page, categoryLabel)); |
| | | } |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import org.springblade.modules.category.entity.CategoryEntity; |
| | | import org.springblade.modules.category.vo.CategoryVO; |
| | | import org.springblade.modules.category.mapper.CategoryMapper; |
| | | import org.springblade.modules.category.service.ICategoryService; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 天地图poi 分类表 服务实现类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @Service |
| | | public class CategoryServiceImpl extends ServiceImpl<CategoryMapper, CategoryEntity> implements ICategoryService { |
| | | |
| | | @Override |
| | | public IPage<CategoryVO> selectCategoryPage(IPage<CategoryVO> page, CategoryVO category) { |
| | | return page.setRecords(baseMapper.selectCategoryPage(page, category)); |
| | | } |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.vo; |
| | | |
| | | import org.springblade.modules.category.entity.CategoryLabelEntity; |
| | | import org.springblade.core.tool.node.INode; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | /** |
| | | * 场所标签临时表 视图实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class CategoryLabelVO extends CategoryLabelEntity { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.vo; |
| | | |
| | | import org.springblade.modules.category.entity.CategoryEntity; |
| | | import org.springblade.core.tool.node.INode; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | /** |
| | | * 天地图poi 分类表 视图实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class CategoryVO extends CategoryEntity { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.wrapper; |
| | | |
| | | import org.springblade.core.mp.support.BaseEntityWrapper; |
| | | import org.springblade.core.tool.utils.BeanUtil; |
| | | import org.springblade.modules.category.entity.CategoryLabelEntity; |
| | | import org.springblade.modules.category.vo.CategoryLabelVO; |
| | | import java.util.Objects; |
| | | |
| | | /** |
| | | * 场所标签临时表 包装类,返回视图层所需的字段 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | public class CategoryLabelWrapper extends BaseEntityWrapper<CategoryLabelEntity, CategoryLabelVO> { |
| | | |
| | | public static CategoryLabelWrapper build() { |
| | | return new CategoryLabelWrapper(); |
| | | } |
| | | |
| | | @Override |
| | | public CategoryLabelVO entityVO(CategoryLabelEntity categoryLabel) { |
| | | CategoryLabelVO categoryLabelVO = Objects.requireNonNull(BeanUtil.copy(categoryLabel, CategoryLabelVO.class)); |
| | | |
| | | //User createUser = UserCache.getUser(categoryLabel.getCreateUser()); |
| | | //User updateUser = UserCache.getUser(categoryLabel.getUpdateUser()); |
| | | //categoryLabelVO.setCreateUserName(createUser.getName()); |
| | | //categoryLabelVO.setUpdateUserName(updateUser.getName()); |
| | | |
| | | return categoryLabelVO; |
| | | } |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.category.wrapper; |
| | | |
| | | import org.springblade.core.mp.support.BaseEntityWrapper; |
| | | import org.springblade.core.tool.utils.BeanUtil; |
| | | import org.springblade.modules.category.entity.CategoryEntity; |
| | | import org.springblade.modules.category.vo.CategoryVO; |
| | | import java.util.Objects; |
| | | |
| | | /** |
| | | * 天地图poi 分类表 包装类,返回视图层所需的字段 |
| | | * |
| | | * @author BladeX |
| | | * @since 2023-10-28 |
| | | */ |
| | | public class CategoryWrapper extends BaseEntityWrapper<CategoryEntity, CategoryVO> { |
| | | |
| | | public static CategoryWrapper build() { |
| | | return new CategoryWrapper(); |
| | | } |
| | | |
| | | @Override |
| | | public CategoryVO entityVO(CategoryEntity category) { |
| | | CategoryVO categoryVO = Objects.requireNonNull(BeanUtil.copy(category, CategoryVO.class)); |
| | | |
| | | //User createUser = UserCache.getUser(category.getCreateUser()); |
| | | //User updateUser = UserCache.getUser(category.getUpdateUser()); |
| | | //categoryVO.setCreateUserName(createUser.getName()); |
| | | //categoryVO.setUpdateUserName(updateUser.getName()); |
| | | |
| | | return categoryVO; |
| | | } |
| | | |
| | | |
| | | } |
| | |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springblade.core.tenant.mp.TenantEntity; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * 门牌地址表(总台账数据) 实体类 |
| | | * |
| | |
| | | @Data |
| | | @TableName("jczz_doorplate_address") |
| | | @ApiModel(value = "DoorplateAddress对象", description = "门牌地址表(总台账数据)") |
| | | public class DoorplateAddressEntity{ |
| | | public class DoorplateAddressEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 地址编码 |
| | |
| | | @TableName("jczz_grid") |
| | | @ApiModel(value = "Grid对象", description = "网格表") |
| | | public class GridEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | |
| | | @TableName("jczz_grid_range") |
| | | @ApiModel(value = "GridRange对象", description = "网格范围表") |
| | | public class GridRangeEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | |
| | | @TableName("jczz_house") |
| | | @ApiModel(value = "House对象", description = "房屋") |
| | | public class HouseEntity implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * 主键 |
| | | */ |
| | |
| | | @TableName("jczz_house_label") |
| | | @ApiModel(value = "HouseLabel对象", description = "房屋-标签") |
| | | public class HouseLabelEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | |
| | | @TableName("jczz_house_rental") |
| | | @ApiModel(value = "HouseRental对象", description = "出租屋") |
| | | public class HouseRentalEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | |
| | | @TableName("jczz_house_tenant") |
| | | @ApiModel(value = "HouseTenant对象", description = "租户管理") |
| | | public class HouseTenantEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * 主键 |
| | | */ |
| | |
| | | @TableName("jczz_household") |
| | | @ApiModel(value = "Household对象", description = "住户") |
| | | public class HouseholdEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | |
| | | @TableName("jczz_household_label") |
| | | @ApiModel(value = "HouseholdLabel对象", description = "住户-标签") |
| | | public class HouseholdLabelEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | |
| | | @TableName("jczz_label") |
| | | @ApiModel(value = "Label对象", description = "标签管理") |
| | | public class LabelEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | |
| | | @TableName("jczz_place") |
| | | @ApiModel(value = "Place对象", description = "场所表") |
| | | public class PlaceEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | |
| | | @TableName("jczz_place_ext") |
| | | @ApiModel(value = "PlaceExt对象", description = "场所详情表") |
| | | public class PlaceExtEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | |
| | | @TableName("jczz_place_practitioner") |
| | | @ApiModel(value = "PlacePractitioner对象", description = "场所从业人员") |
| | | public class PlacePractitionerEntity implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | /** |
| | | * 主键 |
| | | */ |