修复已知问题
This commit is contained in:
@@ -0,0 +1,131 @@
|
|||||||
|
package com.gxwebsoft.common.system.controller;
|
||||||
|
|
||||||
|
import com.gxwebsoft.common.core.annotation.OperationLog;
|
||||||
|
import com.gxwebsoft.common.core.web.ApiResult;
|
||||||
|
import com.gxwebsoft.common.core.web.BaseController;
|
||||||
|
import com.gxwebsoft.common.core.web.BatchParam;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyComment;
|
||||||
|
import com.gxwebsoft.common.system.entity.User;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyCommentParam;
|
||||||
|
import com.gxwebsoft.common.system.service.CompanyCommentService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用评论控制器
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Api(tags = "应用评论管理")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/system/company-comment")
|
||||||
|
public class CompanyCommentController extends BaseController {
|
||||||
|
@Resource
|
||||||
|
private CompanyCommentService companyCommentService;
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("分页查询应用评论")
|
||||||
|
@GetMapping("/page")
|
||||||
|
public ApiResult<PageResult<CompanyComment>> page(CompanyCommentParam param) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyCommentService.pageRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("查询全部应用评论")
|
||||||
|
@GetMapping()
|
||||||
|
public ApiResult<List<CompanyComment>> list(CompanyCommentParam param) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyCommentService.listRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("根据id查询应用评论")
|
||||||
|
@GetMapping("/{id}")
|
||||||
|
public ApiResult<CompanyComment> get(@PathVariable("id") Integer id) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyCommentService.getByIdRel(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:save')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("添加应用评论")
|
||||||
|
@PostMapping()
|
||||||
|
public ApiResult<?> save(@RequestBody CompanyComment companyComment) {
|
||||||
|
// 记录当前登录用户id
|
||||||
|
User loginUser = getLoginUser();
|
||||||
|
if (loginUser != null) {
|
||||||
|
companyComment.setUserId(loginUser.getUserId());
|
||||||
|
}
|
||||||
|
if (companyCommentService.save(companyComment)) {
|
||||||
|
return success("添加成功");
|
||||||
|
}
|
||||||
|
return fail("添加失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:update')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("修改应用评论")
|
||||||
|
@PutMapping()
|
||||||
|
public ApiResult<?> update(@RequestBody CompanyComment companyComment) {
|
||||||
|
if (companyCommentService.updateById(companyComment)) {
|
||||||
|
return success("修改成功");
|
||||||
|
}
|
||||||
|
return fail("修改失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:remove')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("删除应用评论")
|
||||||
|
@DeleteMapping("/{id}")
|
||||||
|
public ApiResult<?> remove(@PathVariable("id") Integer id) {
|
||||||
|
if (companyCommentService.removeById(id)) {
|
||||||
|
return success("删除成功");
|
||||||
|
}
|
||||||
|
return fail("删除失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:save')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量添加应用评论")
|
||||||
|
@PostMapping("/batch")
|
||||||
|
public ApiResult<?> saveBatch(@RequestBody List<CompanyComment> list) {
|
||||||
|
if (companyCommentService.saveBatch(list)) {
|
||||||
|
return success("添加成功");
|
||||||
|
}
|
||||||
|
return fail("添加失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:update')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量修改应用评论")
|
||||||
|
@PutMapping("/batch")
|
||||||
|
public ApiResult<?> removeBatch(@RequestBody BatchParam<CompanyComment> batchParam) {
|
||||||
|
if (batchParam.update(companyCommentService, "id")) {
|
||||||
|
return success("修改成功");
|
||||||
|
}
|
||||||
|
return fail("修改失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:remove')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量删除应用评论")
|
||||||
|
@DeleteMapping("/batch")
|
||||||
|
public ApiResult<?> removeBatch(@RequestBody List<Integer> ids) {
|
||||||
|
if (companyCommentService.removeByIds(ids)) {
|
||||||
|
return success("删除成功");
|
||||||
|
}
|
||||||
|
return fail("删除失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,125 @@
|
|||||||
|
package com.gxwebsoft.common.system.controller;
|
||||||
|
|
||||||
|
import com.gxwebsoft.common.core.annotation.OperationLog;
|
||||||
|
import com.gxwebsoft.common.core.web.ApiResult;
|
||||||
|
import com.gxwebsoft.common.core.web.BaseController;
|
||||||
|
import com.gxwebsoft.common.core.web.BatchParam;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyContent;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyContentParam;
|
||||||
|
import com.gxwebsoft.common.system.service.CompanyContentService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用详情控制器
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-16 13:41:21
|
||||||
|
*/
|
||||||
|
@Api(tags = "应用详情管理")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/system/company-content")
|
||||||
|
public class CompanyContentController extends BaseController {
|
||||||
|
@Resource
|
||||||
|
private CompanyContentService companyContentService;
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("分页查询应用详情")
|
||||||
|
@GetMapping("/page")
|
||||||
|
public ApiResult<PageResult<CompanyContent>> page(CompanyContentParam param) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyContentService.pageRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("查询全部应用详情")
|
||||||
|
@GetMapping()
|
||||||
|
public ApiResult<List<CompanyContent>> list(CompanyContentParam param) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyContentService.listRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("根据id查询应用详情")
|
||||||
|
@GetMapping("/{id}")
|
||||||
|
public ApiResult<CompanyContent> get(@PathVariable("id") Integer id) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyContentService.getByIdRel(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:save')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("添加应用详情")
|
||||||
|
@PostMapping()
|
||||||
|
public ApiResult<?> save(@RequestBody CompanyContent companyContent) {
|
||||||
|
if (companyContentService.save(companyContent)) {
|
||||||
|
return success("添加成功");
|
||||||
|
}
|
||||||
|
return fail("添加失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:update')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("修改应用详情")
|
||||||
|
@PutMapping()
|
||||||
|
public ApiResult<?> update(@RequestBody CompanyContent companyContent) {
|
||||||
|
if (companyContentService.updateById(companyContent)) {
|
||||||
|
return success("修改成功");
|
||||||
|
}
|
||||||
|
return fail("修改失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:remove')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("删除应用详情")
|
||||||
|
@DeleteMapping("/{id}")
|
||||||
|
public ApiResult<?> remove(@PathVariable("id") Integer id) {
|
||||||
|
if (companyContentService.removeById(id)) {
|
||||||
|
return success("删除成功");
|
||||||
|
}
|
||||||
|
return fail("删除失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:save')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量添加应用详情")
|
||||||
|
@PostMapping("/batch")
|
||||||
|
public ApiResult<?> saveBatch(@RequestBody List<CompanyContent> list) {
|
||||||
|
if (companyContentService.saveBatch(list)) {
|
||||||
|
return success("添加成功");
|
||||||
|
}
|
||||||
|
return fail("添加失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:update')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量修改应用详情")
|
||||||
|
@PutMapping("/batch")
|
||||||
|
public ApiResult<?> removeBatch(@RequestBody BatchParam<CompanyContent> batchParam) {
|
||||||
|
if (batchParam.update(companyContentService, "id")) {
|
||||||
|
return success("修改成功");
|
||||||
|
}
|
||||||
|
return fail("修改失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:remove')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量删除应用详情")
|
||||||
|
@DeleteMapping("/batch")
|
||||||
|
public ApiResult<?> removeBatch(@RequestBody List<Integer> ids) {
|
||||||
|
if (companyContentService.removeByIds(ids)) {
|
||||||
|
return success("删除成功");
|
||||||
|
}
|
||||||
|
return fail("删除失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,5 +1,7 @@
|
|||||||
package com.gxwebsoft.common.system.controller;
|
package com.gxwebsoft.common.system.controller;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.DesensitizedUtil;
|
||||||
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
import com.gxwebsoft.common.core.annotation.OperationLog;
|
import com.gxwebsoft.common.core.annotation.OperationLog;
|
||||||
@@ -11,10 +13,7 @@ import com.gxwebsoft.common.system.entity.*;
|
|||||||
import com.gxwebsoft.common.system.mapper.CompanyMapper;
|
import com.gxwebsoft.common.system.mapper.CompanyMapper;
|
||||||
import com.gxwebsoft.common.system.mapper.TenantMapper;
|
import com.gxwebsoft.common.system.mapper.TenantMapper;
|
||||||
import com.gxwebsoft.common.system.param.CompanyParam;
|
import com.gxwebsoft.common.system.param.CompanyParam;
|
||||||
import com.gxwebsoft.common.system.service.CompanyService;
|
import com.gxwebsoft.common.system.service.*;
|
||||||
import com.gxwebsoft.common.system.service.DomainService;
|
|
||||||
import com.gxwebsoft.common.system.service.TenantService;
|
|
||||||
import com.gxwebsoft.common.system.service.UserCollectionService;
|
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
@@ -41,6 +40,12 @@ public class CompanyController extends BaseController {
|
|||||||
@Resource
|
@Resource
|
||||||
private CompanyService companyService;
|
private CompanyService companyService;
|
||||||
@Resource
|
@Resource
|
||||||
|
private CompanyContentService companyContentService;
|
||||||
|
@Resource
|
||||||
|
private CompanyUrlService companyUrlService;
|
||||||
|
@Resource
|
||||||
|
private CompanyParameterService companyParameterService;
|
||||||
|
@Resource
|
||||||
private TenantService tenantService;
|
private TenantService tenantService;
|
||||||
@Resource
|
@Resource
|
||||||
private CompanyMapper companyMapper;
|
private CompanyMapper companyMapper;
|
||||||
@@ -57,7 +62,11 @@ public class CompanyController extends BaseController {
|
|||||||
@ApiOperation("分页查询企业信息不限租户")
|
@ApiOperation("分页查询企业信息不限租户")
|
||||||
@GetMapping("/pageAll")
|
@GetMapping("/pageAll")
|
||||||
public ApiResult<PageResult<Company>> pageAll(CompanyParam param) {
|
public ApiResult<PageResult<Company>> pageAll(CompanyParam param) {
|
||||||
|
final PageResult<Company> result = companyService.pageRelAll(param);
|
||||||
|
result.getList().forEach(d -> {
|
||||||
|
d.setPhone(DesensitizedUtil.mobilePhone(d.getPhone()));
|
||||||
|
d.setCompanyCode(DesensitizedUtil.idCardNum(d.getCompanyCode(),1,2));
|
||||||
|
});
|
||||||
final User loginUser = getLoginUser();
|
final User loginUser = getLoginUser();
|
||||||
if(loginUser != null){
|
if(loginUser != null){
|
||||||
// 我的收藏
|
// 我的收藏
|
||||||
@@ -71,8 +80,6 @@ public class CompanyController extends BaseController {
|
|||||||
param.setCompanyIds(collect);
|
param.setCompanyIds(collect);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
final PageResult<Company> result = companyService.pageRelAll(param);
|
|
||||||
// System.out.println("collect = " + collect);
|
|
||||||
result.getList().forEach(d -> {
|
result.getList().forEach(d -> {
|
||||||
d.setCollection(collect.contains(d.getCompanyId()));
|
d.setCollection(collect.contains(d.getCompanyId()));
|
||||||
});
|
});
|
||||||
@@ -80,11 +87,10 @@ public class CompanyController extends BaseController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 使用关联查询
|
// 使用关联查询
|
||||||
return success(companyService.pageRelAll(param));
|
return success(result);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PreAuthorize("hasAuthority('sys:company:list')")
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
@OperationLog
|
|
||||||
@ApiOperation("分页查询企业信息")
|
@ApiOperation("分页查询企业信息")
|
||||||
@GetMapping("/page")
|
@GetMapping("/page")
|
||||||
public ApiResult<PageResult<Company>> page(CompanyParam param) {
|
public ApiResult<PageResult<Company>> page(CompanyParam param) {
|
||||||
@@ -101,13 +107,24 @@ public class CompanyController extends BaseController {
|
|||||||
return success(companyService.listRel(param));
|
return success(companyService.listRel(param));
|
||||||
}
|
}
|
||||||
|
|
||||||
@PreAuthorize("hasAuthority('sys:company:list')")
|
|
||||||
@OperationLog
|
|
||||||
@ApiOperation("根据id查询企业信息")
|
@ApiOperation("根据id查询企业信息")
|
||||||
@GetMapping("/{id}")
|
@GetMapping("/{id}")
|
||||||
public ApiResult<Company> get(@PathVariable("id") Integer id) {
|
public ApiResult<Company> get(@PathVariable("id") Integer id) {
|
||||||
// 使用关联查询
|
// 使用关联查询
|
||||||
return success(companyService.getByIdRel(id));
|
final Company company = companyService.getByIdRel(id);
|
||||||
|
if (ObjectUtil.isNotEmpty(company)) {
|
||||||
|
// 应用详情
|
||||||
|
final CompanyContent content = companyContentService.getOne(new LambdaQueryWrapper<CompanyContent>().eq(CompanyContent::getCompanyId, company.getCompanyId()).last("limit 1"));
|
||||||
|
if (ObjectUtil.isNotEmpty(content)) {
|
||||||
|
company.setContent(content.getContent());
|
||||||
|
}
|
||||||
|
// 应用链接
|
||||||
|
company.setLinks(companyUrlService.list(new LambdaQueryWrapper<CompanyUrl>().eq(CompanyUrl::getCompanyId, company.getCompanyId())));
|
||||||
|
// 应用参数
|
||||||
|
company.setParameters(companyParameterService.list(new LambdaQueryWrapper<CompanyParameter>().eq(CompanyParameter::getCompanyId, company.getCompanyId())));
|
||||||
|
|
||||||
|
}
|
||||||
|
return success(company);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Transactional(rollbackFor = {Exception.class}, isolation = Isolation.SERIALIZABLE)
|
@Transactional(rollbackFor = {Exception.class}, isolation = Isolation.SERIALIZABLE)
|
||||||
@@ -137,54 +154,56 @@ public class CompanyController extends BaseController {
|
|||||||
return fail("添加失败");
|
return fail("添加失败");
|
||||||
}
|
}
|
||||||
|
|
||||||
@PreAuthorize("hasAuthority('sys:company:update')")
|
@PreAuthorize("hasAuthority('sys:company:update')")
|
||||||
@OperationLog
|
@OperationLog
|
||||||
@ApiOperation("修改企业信息")
|
@ApiOperation("修改企业信息")
|
||||||
@PutMapping()
|
@PutMapping()
|
||||||
public ApiResult<?> update(@RequestBody Company company) {
|
public ApiResult<?> update(@RequestBody Company company) {
|
||||||
// 授权新的免费域名
|
// 授权新的免费域名
|
||||||
if (StrUtil.isNotBlank(company.getFreeDomain())) {
|
if (StrUtil.isNotBlank(company.getFreeDomain())) {
|
||||||
// 待授权的二级域名
|
// 待授权的二级域名
|
||||||
String domain = company.getFreeDomain().concat(".websoft.top");
|
String domain = company.getFreeDomain().concat(".websoft.top");
|
||||||
// 删除旧授权域名
|
// 删除旧授权域名
|
||||||
final Domain one = domainService.getOne(new LambdaQueryWrapper<Domain>().eq(Domain::getType, 2).eq(Domain::getCompanyId, company.getCompanyId()).eq(Domain::getDeleted,0).last("limit 1"));
|
final Domain one = domainService.getOne(new LambdaQueryWrapper<Domain>().eq(Domain::getType, 2).eq(Domain::getCompanyId, company.getCompanyId()).eq(Domain::getDeleted,0).last("limit 1"));
|
||||||
if(one != null){
|
if(one != null){
|
||||||
redisUtil.delete("Domain:".concat(one.getDomain()));
|
redisUtil.delete("Domain:".concat(one.getDomain()));
|
||||||
domainService.removeById(one);
|
domainService.removeById(one);
|
||||||
}
|
|
||||||
// 保存记录
|
|
||||||
final Domain sysDomain = new Domain();
|
|
||||||
sysDomain.setDomain(domain);
|
|
||||||
sysDomain.setType(2);
|
|
||||||
sysDomain.setSortNumber(100);
|
|
||||||
sysDomain.setCompanyId(company.getCompanyId());
|
|
||||||
sysDomain.setTenantId(company.getTenantId());
|
|
||||||
domainService.save(sysDomain);
|
|
||||||
company.setDomain(domain);
|
|
||||||
// 写入缓存
|
|
||||||
redisUtil.set("Domain:".concat(domain), company.getTenantId());
|
|
||||||
}
|
}
|
||||||
// 同步更新租户表
|
// 保存记录
|
||||||
if(StrUtil.isNotBlank(company.getShortName())){
|
final Domain sysDomain = new Domain();
|
||||||
final Tenant tenant = new Tenant();
|
sysDomain.setDomain(domain);
|
||||||
tenant.setTenantId(company.getTenantId());
|
sysDomain.setType(2);
|
||||||
tenant.setTenantName(company.getShortName());
|
sysDomain.setSortNumber(100);
|
||||||
tenantService.updateById(tenant);
|
sysDomain.setCompanyId(company.getCompanyId());
|
||||||
}
|
sysDomain.setTenantId(company.getTenantId());
|
||||||
if (companyService.updateById(company)) {
|
domainService.save(sysDomain);
|
||||||
// 清除缓存
|
company.setDomain(domain);
|
||||||
redisUtil.delete("TenantInfo:".concat(company.getTenantId().toString()));
|
// 写入缓存
|
||||||
return success("修改成功");
|
redisUtil.set("Domain:".concat(domain), company.getTenantId());
|
||||||
}
|
|
||||||
return fail("修改失败");
|
|
||||||
}
|
}
|
||||||
|
// 同步更新租户表
|
||||||
|
if(StrUtil.isNotBlank(company.getShortName())){
|
||||||
|
final Tenant tenant = new Tenant();
|
||||||
|
tenant.setTenantId(company.getTenantId());
|
||||||
|
tenant.setTenantName(company.getShortName());
|
||||||
|
tenantService.updateById(tenant);
|
||||||
|
}
|
||||||
|
if (companyService.updateById(company)) {
|
||||||
|
// 清除缓存
|
||||||
|
redisUtil.delete("TenantInfo:".concat(company.getTenantId().toString()));
|
||||||
|
return success("修改成功");
|
||||||
|
}
|
||||||
|
return fail("修改失败");
|
||||||
|
}
|
||||||
|
|
||||||
@PreAuthorize("hasAuthority('sys:company:remove')")
|
@PreAuthorize("hasAuthority('sys:company:remove')")
|
||||||
@OperationLog
|
@OperationLog
|
||||||
@ApiOperation("删除企业信息")
|
@ApiOperation("删除企业信息")
|
||||||
@DeleteMapping("/{id}")
|
@DeleteMapping("/{id}")
|
||||||
public ApiResult<?> remove(@PathVariable("id") Integer id) {
|
public ApiResult<?> remove(@PathVariable("id") Integer id) {
|
||||||
if (companyService.removeById(id)) {
|
final Company company = companyService.getById(id);
|
||||||
|
tenantService.removeById(company.getTenantId());
|
||||||
|
if (companyService.removeById(id)) {
|
||||||
return success("删除成功");
|
return success("删除成功");
|
||||||
}
|
}
|
||||||
return fail("删除失败");
|
return fail("删除失败");
|
||||||
|
|||||||
@@ -0,0 +1,125 @@
|
|||||||
|
package com.gxwebsoft.common.system.controller;
|
||||||
|
|
||||||
|
import com.gxwebsoft.common.core.annotation.OperationLog;
|
||||||
|
import com.gxwebsoft.common.core.web.ApiResult;
|
||||||
|
import com.gxwebsoft.common.core.web.BaseController;
|
||||||
|
import com.gxwebsoft.common.core.web.BatchParam;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyParameter;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyParameterParam;
|
||||||
|
import com.gxwebsoft.common.system.service.CompanyParameterService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用参数控制器
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Api(tags = "应用参数管理")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/system/company-parameter")
|
||||||
|
public class CompanyParameterController extends BaseController {
|
||||||
|
@Resource
|
||||||
|
private CompanyParameterService companyParameterService;
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("分页查询应用参数")
|
||||||
|
@GetMapping("/page")
|
||||||
|
public ApiResult<PageResult<CompanyParameter>> page(CompanyParameterParam param) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyParameterService.pageRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("查询全部应用参数")
|
||||||
|
@GetMapping()
|
||||||
|
public ApiResult<List<CompanyParameter>> list(CompanyParameterParam param) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyParameterService.listRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("根据id查询应用参数")
|
||||||
|
@GetMapping("/{id}")
|
||||||
|
public ApiResult<CompanyParameter> get(@PathVariable("id") Integer id) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyParameterService.getByIdRel(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:save')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("添加应用参数")
|
||||||
|
@PostMapping()
|
||||||
|
public ApiResult<?> save(@RequestBody CompanyParameter companyParameter) {
|
||||||
|
if (companyParameterService.save(companyParameter)) {
|
||||||
|
return success("添加成功");
|
||||||
|
}
|
||||||
|
return fail("添加失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:update')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("修改应用参数")
|
||||||
|
@PutMapping()
|
||||||
|
public ApiResult<?> update(@RequestBody CompanyParameter companyParameter) {
|
||||||
|
if (companyParameterService.updateById(companyParameter)) {
|
||||||
|
return success("修改成功");
|
||||||
|
}
|
||||||
|
return fail("修改失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:remove')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("删除应用参数")
|
||||||
|
@DeleteMapping("/{id}")
|
||||||
|
public ApiResult<?> remove(@PathVariable("id") Integer id) {
|
||||||
|
if (companyParameterService.removeById(id)) {
|
||||||
|
return success("删除成功");
|
||||||
|
}
|
||||||
|
return fail("删除失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:save')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量添加应用参数")
|
||||||
|
@PostMapping("/batch")
|
||||||
|
public ApiResult<?> saveBatch(@RequestBody List<CompanyParameter> list) {
|
||||||
|
if (companyParameterService.saveBatch(list)) {
|
||||||
|
return success("添加成功");
|
||||||
|
}
|
||||||
|
return fail("添加失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:update')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量修改应用参数")
|
||||||
|
@PutMapping("/batch")
|
||||||
|
public ApiResult<?> removeBatch(@RequestBody BatchParam<CompanyParameter> batchParam) {
|
||||||
|
if (batchParam.update(companyParameterService, "id")) {
|
||||||
|
return success("修改成功");
|
||||||
|
}
|
||||||
|
return fail("修改失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:remove')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量删除应用参数")
|
||||||
|
@DeleteMapping("/batch")
|
||||||
|
public ApiResult<?> removeBatch(@RequestBody List<Integer> ids) {
|
||||||
|
if (companyParameterService.removeByIds(ids)) {
|
||||||
|
return success("删除成功");
|
||||||
|
}
|
||||||
|
return fail("删除失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,125 @@
|
|||||||
|
package com.gxwebsoft.common.system.controller;
|
||||||
|
|
||||||
|
import com.gxwebsoft.common.core.annotation.OperationLog;
|
||||||
|
import com.gxwebsoft.common.core.web.ApiResult;
|
||||||
|
import com.gxwebsoft.common.core.web.BaseController;
|
||||||
|
import com.gxwebsoft.common.core.web.BatchParam;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyUrl;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyUrlParam;
|
||||||
|
import com.gxwebsoft.common.system.service.CompanyUrlService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用域名控制器
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Api(tags = "应用域名管理")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/system/company-url")
|
||||||
|
public class CompanyUrlController extends BaseController {
|
||||||
|
@Resource
|
||||||
|
private CompanyUrlService companyUrlService;
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("分页查询应用域名")
|
||||||
|
@GetMapping("/page")
|
||||||
|
public ApiResult<PageResult<CompanyUrl>> page(CompanyUrlParam param) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyUrlService.pageRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("查询全部应用域名")
|
||||||
|
@GetMapping()
|
||||||
|
public ApiResult<List<CompanyUrl>> list(CompanyUrlParam param) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyUrlService.listRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:list')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("根据id查询应用域名")
|
||||||
|
@GetMapping("/{id}")
|
||||||
|
public ApiResult<CompanyUrl> get(@PathVariable("id") Integer id) {
|
||||||
|
// 使用关联查询
|
||||||
|
return success(companyUrlService.getByIdRel(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:save')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("添加应用域名")
|
||||||
|
@PostMapping()
|
||||||
|
public ApiResult<?> save(@RequestBody CompanyUrl companyUrl) {
|
||||||
|
if (companyUrlService.save(companyUrl)) {
|
||||||
|
return success("添加成功");
|
||||||
|
}
|
||||||
|
return fail("添加失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:update')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("修改应用域名")
|
||||||
|
@PutMapping()
|
||||||
|
public ApiResult<?> update(@RequestBody CompanyUrl companyUrl) {
|
||||||
|
if (companyUrlService.updateById(companyUrl)) {
|
||||||
|
return success("修改成功");
|
||||||
|
}
|
||||||
|
return fail("修改失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:remove')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("删除应用域名")
|
||||||
|
@DeleteMapping("/{id}")
|
||||||
|
public ApiResult<?> remove(@PathVariable("id") Integer id) {
|
||||||
|
if (companyUrlService.removeById(id)) {
|
||||||
|
return success("删除成功");
|
||||||
|
}
|
||||||
|
return fail("删除失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:save')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量添加应用域名")
|
||||||
|
@PostMapping("/batch")
|
||||||
|
public ApiResult<?> saveBatch(@RequestBody List<CompanyUrl> list) {
|
||||||
|
if (companyUrlService.saveBatch(list)) {
|
||||||
|
return success("添加成功");
|
||||||
|
}
|
||||||
|
return fail("添加失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:update')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量修改应用域名")
|
||||||
|
@PutMapping("/batch")
|
||||||
|
public ApiResult<?> removeBatch(@RequestBody BatchParam<CompanyUrl> batchParam) {
|
||||||
|
if (batchParam.update(companyUrlService, "id")) {
|
||||||
|
return success("修改成功");
|
||||||
|
}
|
||||||
|
return fail("修改失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("hasAuthority('sys:company:remove')")
|
||||||
|
@OperationLog
|
||||||
|
@ApiOperation("批量删除应用域名")
|
||||||
|
@DeleteMapping("/batch")
|
||||||
|
public ApiResult<?> removeBatch(@RequestBody List<Integer> ids) {
|
||||||
|
if (companyUrlService.removeByIds(ids)) {
|
||||||
|
return success("删除成功");
|
||||||
|
}
|
||||||
|
return fail("删除失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -4,12 +4,13 @@ import cn.hutool.core.util.DesensitizedUtil;
|
|||||||
import com.baomidou.mybatisplus.annotation.*;
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.annotations.ApiModel;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import io.swagger.models.auth.In;
|
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
import lombok.EqualsAndHashCode;
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
|
import java.math.BigDecimal;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 企业信息
|
* 企业信息
|
||||||
@@ -28,6 +29,9 @@ public class Company implements Serializable {
|
|||||||
@TableId(value = "company_id", type = IdType.AUTO)
|
@TableId(value = "company_id", type = IdType.AUTO)
|
||||||
private Integer companyId;
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "应用类型")
|
||||||
|
private Integer type;
|
||||||
|
|
||||||
@ApiModelProperty(value = "企业简称")
|
@ApiModelProperty(value = "企业简称")
|
||||||
private String shortName;
|
private String shortName;
|
||||||
|
|
||||||
@@ -40,18 +44,44 @@ public class Company implements Serializable {
|
|||||||
@ApiModelProperty(value = "企业类型")
|
@ApiModelProperty(value = "企业类型")
|
||||||
private String companyType;
|
private String companyType;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "是否官方")
|
||||||
|
private Boolean official;
|
||||||
|
|
||||||
@ApiModelProperty(value = "企业类型 多选")
|
@ApiModelProperty(value = "企业类型 多选")
|
||||||
private String companyTypeMultiple;
|
private String companyTypeMultiple;
|
||||||
|
|
||||||
@ApiModelProperty(value = "应用标识")
|
@ApiModelProperty(value = "应用标识")
|
||||||
private String companyLogo;
|
private String companyLogo;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "封面图")
|
||||||
|
private String image;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "应用详情")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String content;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "栏目分类")
|
||||||
|
private Integer categoryId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "栏目名称")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String categoryName;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "应用截图")
|
||||||
|
private String files;
|
||||||
|
|
||||||
@ApiModelProperty(value = "顶级域名")
|
@ApiModelProperty(value = "顶级域名")
|
||||||
private String domain;
|
private String domain;
|
||||||
|
|
||||||
@ApiModelProperty(value = "免费域名")
|
@ApiModelProperty(value = "免费域名")
|
||||||
private String freeDomain;
|
private String freeDomain;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "销售价格")
|
||||||
|
private BigDecimal price;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "计费方式")
|
||||||
|
private Integer chargingMethod;
|
||||||
|
|
||||||
@ApiModelProperty(value = "联系电话")
|
@ApiModelProperty(value = "联系电话")
|
||||||
private String phone;
|
private String phone;
|
||||||
|
|
||||||
@@ -83,6 +113,9 @@ public class Company implements Serializable {
|
|||||||
@ApiModelProperty(value = "版本号")
|
@ApiModelProperty(value = "版本号")
|
||||||
private String versionCode;
|
private String versionCode;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "评分")
|
||||||
|
private BigDecimal rate;
|
||||||
|
|
||||||
@ApiModelProperty(value = "企业成员(当前)")
|
@ApiModelProperty(value = "企业成员(当前)")
|
||||||
private Integer users;
|
private Integer users;
|
||||||
|
|
||||||
@@ -188,9 +221,15 @@ public class Company implements Serializable {
|
|||||||
@ApiModelProperty(value = "排序")
|
@ApiModelProperty(value = "排序")
|
||||||
private Integer sortNumber;
|
private Integer sortNumber;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "插件ID(菜单根节点)")
|
||||||
|
private Integer menuId;
|
||||||
|
|
||||||
@ApiModelProperty(value = "当前使用的租户模板")
|
@ApiModelProperty(value = "当前使用的租户模板")
|
||||||
private Integer planId;
|
private Integer planId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "是否开启网站")
|
||||||
|
private Boolean websiteStatus;
|
||||||
|
|
||||||
@ApiModelProperty(value = "用户ID")
|
@ApiModelProperty(value = "用户ID")
|
||||||
private Integer userId;
|
private Integer userId;
|
||||||
|
|
||||||
@@ -234,10 +273,6 @@ public class Company implements Serializable {
|
|||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private String nickname;
|
private String nickname;
|
||||||
|
|
||||||
@ApiModelProperty(value = "是否已安装")
|
|
||||||
@TableField(exist = false)
|
|
||||||
private Boolean installed;
|
|
||||||
|
|
||||||
@ApiModelProperty(value = "配置信息")
|
@ApiModelProperty(value = "配置信息")
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private Object config;
|
private Object config;
|
||||||
@@ -254,6 +289,26 @@ public class Company implements Serializable {
|
|||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private String mobile;
|
private String mobile;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "是否已购买")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private Boolean isBuy;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "用户是否已安装了该插件")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private Boolean installed;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "产品参数")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private List<CompanyParameter> parameters;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "产品按钮及链接")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private List<CompanyUrl> links;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "购买数量")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private Integer num;
|
||||||
|
|
||||||
public String getMobile() {
|
public String getMobile() {
|
||||||
return DesensitizedUtil.mobilePhone(this.phone);
|
return DesensitizedUtil.mobilePhone(this.phone);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,59 @@
|
|||||||
|
package com.gxwebsoft.common.system.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用评论
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value = "CompanyComment对象", description = "应用评论")
|
||||||
|
@TableName("sys_company_comment")
|
||||||
|
public class CompanyComment implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "ID")
|
||||||
|
@TableId(value = "id", type = IdType.AUTO)
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "父级ID")
|
||||||
|
private Integer parentId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "用户ID")
|
||||||
|
private Integer userId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "企业ID")
|
||||||
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "评分")
|
||||||
|
private BigDecimal rate;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "排序(数字越小越靠前)")
|
||||||
|
private Integer sortNumber;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "评论内容")
|
||||||
|
private String comments;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "状态")
|
||||||
|
private Integer status;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "租户id")
|
||||||
|
private Integer tenantId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "创建时间")
|
||||||
|
private Date createTime;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.gxwebsoft.common.system.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用详情
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-16 13:41:21
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value = "CompanyContent对象", description = "应用详情")
|
||||||
|
@TableName("sys_company_content")
|
||||||
|
public class CompanyContent implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
@TableId(value = "id", type = IdType.AUTO)
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "企业ID")
|
||||||
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "详细内容")
|
||||||
|
private String content;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "租户id")
|
||||||
|
private Integer tenantId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "创建时间")
|
||||||
|
private Date createTime;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,55 @@
|
|||||||
|
package com.gxwebsoft.common.system.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用参数
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value = "CompanyParameter对象", description = "应用参数")
|
||||||
|
@TableName("sys_company_parameter")
|
||||||
|
public class CompanyParameter implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "自增ID")
|
||||||
|
@TableId(value = "id", type = IdType.AUTO)
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "参数名称")
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "参数内容")
|
||||||
|
private String value;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "企业ID")
|
||||||
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "备注")
|
||||||
|
private String comments;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "排序(数字越小越靠前)")
|
||||||
|
private Integer sortNumber;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "状态, 0正常, 1待确认")
|
||||||
|
private Integer status;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "创建时间")
|
||||||
|
private Date createTime;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "租户id")
|
||||||
|
private Integer tenantId;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,64 @@
|
|||||||
|
package com.gxwebsoft.common.system.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用域名
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value = "CompanyUrl对象", description = "应用域名")
|
||||||
|
@TableName("sys_company_url")
|
||||||
|
public class CompanyUrl implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "自增ID")
|
||||||
|
@TableId(value = "id", type = IdType.AUTO)
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "域名类型")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "企业ID")
|
||||||
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "域名")
|
||||||
|
private String domain;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "账号")
|
||||||
|
private String account;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "密码")
|
||||||
|
private String password;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "二维码")
|
||||||
|
private String qrcode;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "备注")
|
||||||
|
private String comments;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "排序(数字越小越靠前)")
|
||||||
|
private Integer sortNumber;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "状态, 0正常, 1待确认")
|
||||||
|
private Integer status;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "创建时间")
|
||||||
|
private Date createTime;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "租户id")
|
||||||
|
private Integer tenantId;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
package com.gxwebsoft.common.system.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyComment;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyCommentParam;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用评论Mapper
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
public interface CompanyCommentMapper extends BaseMapper<CompanyComment> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*
|
||||||
|
* @param page 分页对象
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<CompanyComment>
|
||||||
|
*/
|
||||||
|
List<CompanyComment> selectPageRel(@Param("page") IPage<CompanyComment> page,
|
||||||
|
@Param("param") CompanyCommentParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询全部
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<User>
|
||||||
|
*/
|
||||||
|
List<CompanyComment> selectListRel(@Param("param") CompanyCommentParam param);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
package com.gxwebsoft.common.system.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyContent;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyContentParam;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用详情Mapper
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-16 13:41:21
|
||||||
|
*/
|
||||||
|
public interface CompanyContentMapper extends BaseMapper<CompanyContent> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*
|
||||||
|
* @param page 分页对象
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<CompanyContent>
|
||||||
|
*/
|
||||||
|
List<CompanyContent> selectPageRel(@Param("page") IPage<CompanyContent> page,
|
||||||
|
@Param("param") CompanyContentParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询全部
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<User>
|
||||||
|
*/
|
||||||
|
List<CompanyContent> selectListRel(@Param("param") CompanyContentParam param);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -3,10 +3,8 @@ package com.gxwebsoft.common.system.mapper;
|
|||||||
import com.baomidou.mybatisplus.annotation.InterceptorIgnore;
|
import com.baomidou.mybatisplus.annotation.InterceptorIgnore;
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.gxwebsoft.common.core.web.ExistenceParam;
|
|
||||||
import com.gxwebsoft.common.core.web.PageParam;
|
import com.gxwebsoft.common.core.web.PageParam;
|
||||||
import com.gxwebsoft.common.system.entity.Company;
|
import com.gxwebsoft.common.system.entity.Company;
|
||||||
import com.gxwebsoft.common.system.entity.User;
|
|
||||||
import com.gxwebsoft.common.system.param.CompanyParam;
|
import com.gxwebsoft.common.system.param.CompanyParam;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,37 @@
|
|||||||
|
package com.gxwebsoft.common.system.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyParameter;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyParameterParam;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用参数Mapper
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
public interface CompanyParameterMapper extends BaseMapper<CompanyParameter> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*
|
||||||
|
* @param page 分页对象
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<CompanyParameter>
|
||||||
|
*/
|
||||||
|
List<CompanyParameter> selectPageRel(@Param("page") IPage<CompanyParameter> page,
|
||||||
|
@Param("param") CompanyParameterParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询全部
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<User>
|
||||||
|
*/
|
||||||
|
List<CompanyParameter> selectListRel(@Param("param") CompanyParameterParam param);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
package com.gxwebsoft.common.system.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyUrl;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyUrlParam;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用域名Mapper
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
public interface CompanyUrlMapper extends BaseMapper<CompanyUrl> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*
|
||||||
|
* @param page 分页对象
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<CompanyUrl>
|
||||||
|
*/
|
||||||
|
List<CompanyUrl> selectPageRel(@Param("page") IPage<CompanyUrl> page,
|
||||||
|
@Param("param") CompanyUrlParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询全部
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<User>
|
||||||
|
*/
|
||||||
|
List<CompanyUrl> selectListRel(@Param("param") CompanyUrlParam param);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,53 @@
|
|||||||
|
<?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="com.gxwebsoft.common.system.mapper.CompanyCommentMapper">
|
||||||
|
|
||||||
|
<!-- 关联查询sql -->
|
||||||
|
<sql id="selectSql">
|
||||||
|
SELECT a.*
|
||||||
|
FROM sys_company_comment a
|
||||||
|
<where>
|
||||||
|
<if test="param.id != null">
|
||||||
|
AND a.id = #{param.id}
|
||||||
|
</if>
|
||||||
|
<if test="param.parentId != null">
|
||||||
|
AND a.parent_id = #{param.parentId}
|
||||||
|
</if>
|
||||||
|
<if test="param.userId != null">
|
||||||
|
AND a.user_id = #{param.userId}
|
||||||
|
</if>
|
||||||
|
<if test="param.companyId != null">
|
||||||
|
AND a.company_id = #{param.companyId}
|
||||||
|
</if>
|
||||||
|
<if test="param.rate != null">
|
||||||
|
AND a.rate = #{param.rate}
|
||||||
|
</if>
|
||||||
|
<if test="param.sortNumber != null">
|
||||||
|
AND a.sort_number = #{param.sortNumber}
|
||||||
|
</if>
|
||||||
|
<if test="param.comments != null">
|
||||||
|
AND a.comments LIKE CONCAT('%', #{param.comments}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.status != null">
|
||||||
|
AND a.status = #{param.status}
|
||||||
|
</if>
|
||||||
|
<if test="param.createTimeStart != null">
|
||||||
|
AND a.create_time >= #{param.createTimeStart}
|
||||||
|
</if>
|
||||||
|
<if test="param.createTimeEnd != null">
|
||||||
|
AND a.create_time <= #{param.createTimeEnd}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 分页查询 -->
|
||||||
|
<select id="selectPageRel" resultType="com.gxwebsoft.common.system.entity.CompanyComment">
|
||||||
|
<include refid="selectSql"></include>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 查询全部 -->
|
||||||
|
<select id="selectListRel" resultType="com.gxwebsoft.common.system.entity.CompanyComment">
|
||||||
|
<include refid="selectSql"></include>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
<?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="com.gxwebsoft.common.system.mapper.CompanyContentMapper">
|
||||||
|
|
||||||
|
<!-- 关联查询sql -->
|
||||||
|
<sql id="selectSql">
|
||||||
|
SELECT a.*
|
||||||
|
FROM sys_company_content a
|
||||||
|
<where>
|
||||||
|
<if test="param.id != null">
|
||||||
|
AND a.id = #{param.id}
|
||||||
|
</if>
|
||||||
|
<if test="param.companyId != null">
|
||||||
|
AND a.company_id = #{param.companyId}
|
||||||
|
</if>
|
||||||
|
<if test="param.content != null">
|
||||||
|
AND a.content LIKE CONCAT('%', #{param.content}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.createTimeStart != null">
|
||||||
|
AND a.create_time >= #{param.createTimeStart}
|
||||||
|
</if>
|
||||||
|
<if test="param.createTimeEnd != null">
|
||||||
|
AND a.create_time <= #{param.createTimeEnd}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 分页查询 -->
|
||||||
|
<select id="selectPageRel" resultType="com.gxwebsoft.common.system.entity.CompanyContent">
|
||||||
|
<include refid="selectSql"></include>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 查询全部 -->
|
||||||
|
<select id="selectListRel" resultType="com.gxwebsoft.common.system.entity.CompanyContent">
|
||||||
|
<include refid="selectSql"></include>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
@@ -4,13 +4,23 @@
|
|||||||
|
|
||||||
<!-- 关联查询sql -->
|
<!-- 关联查询sql -->
|
||||||
<sql id="selectSql">
|
<sql id="selectSql">
|
||||||
SELECT a.*,b.tenant_id,b.tenant_name,b.tenant_code
|
SELECT a.*,b.tenant_id,b.tenant_name,b.tenant_code,c.title as categoryName
|
||||||
FROM sys_company a
|
FROM sys_company a
|
||||||
LEFT JOIN sys_tenant b ON a.tenant_id = b.tenant_id
|
LEFT JOIN sys_tenant b ON a.tenant_id = b.tenant_id
|
||||||
|
LEFT JOIN cms_navigation c ON a.category_id = c.navigation_id
|
||||||
<where>
|
<where>
|
||||||
<if test="param.companyId != null">
|
<if test="param.companyId != null">
|
||||||
AND a.company_id = #{param.companyId}
|
AND a.company_id = #{param.companyId}
|
||||||
</if>
|
</if>
|
||||||
|
<if test="param.type != null">
|
||||||
|
AND a.type = #{param.type}
|
||||||
|
</if>
|
||||||
|
<if test="param.official != null">
|
||||||
|
AND a.official = #{param.official}
|
||||||
|
</if>
|
||||||
|
<if test="param.categoryId != null">
|
||||||
|
AND a.category_id = #{param.categoryId}
|
||||||
|
</if>
|
||||||
<if test="param.shortName != null">
|
<if test="param.shortName != null">
|
||||||
AND a.short_name LIKE CONCAT('%', #{param.shortName}, '%')
|
AND a.short_name LIKE CONCAT('%', #{param.shortName}, '%')
|
||||||
</if>
|
</if>
|
||||||
@@ -105,7 +115,7 @@
|
|||||||
AND a.authoritative = #{param.authoritative}
|
AND a.authoritative = #{param.authoritative}
|
||||||
</if>
|
</if>
|
||||||
<if test="param.recommend != null">
|
<if test="param.recommend != null">
|
||||||
AND a.recommend = #{param.recommend}
|
AND a.recommend = 1
|
||||||
</if>
|
</if>
|
||||||
<if test="param.appName != null">
|
<if test="param.appName != null">
|
||||||
AND a.short_name = #{param.appName}
|
AND a.short_name = #{param.appName}
|
||||||
|
|||||||
@@ -0,0 +1,50 @@
|
|||||||
|
<?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="com.gxwebsoft.common.system.mapper.CompanyParameterMapper">
|
||||||
|
|
||||||
|
<!-- 关联查询sql -->
|
||||||
|
<sql id="selectSql">
|
||||||
|
SELECT a.*
|
||||||
|
FROM sys_company_parameter a
|
||||||
|
<where>
|
||||||
|
<if test="param.id != null">
|
||||||
|
AND a.id = #{param.id}
|
||||||
|
</if>
|
||||||
|
<if test="param.name != null">
|
||||||
|
AND a.name LIKE CONCAT('%', #{param.name}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.value != null">
|
||||||
|
AND a.value LIKE CONCAT('%', #{param.value}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.companyId != null">
|
||||||
|
AND a.company_id = #{param.companyId}
|
||||||
|
</if>
|
||||||
|
<if test="param.comments != null">
|
||||||
|
AND a.comments LIKE CONCAT('%', #{param.comments}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.sortNumber != null">
|
||||||
|
AND a.sort_number = #{param.sortNumber}
|
||||||
|
</if>
|
||||||
|
<if test="param.status != null">
|
||||||
|
AND a.status = #{param.status}
|
||||||
|
</if>
|
||||||
|
<if test="param.createTimeStart != null">
|
||||||
|
AND a.create_time >= #{param.createTimeStart}
|
||||||
|
</if>
|
||||||
|
<if test="param.createTimeEnd != null">
|
||||||
|
AND a.create_time <= #{param.createTimeEnd}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 分页查询 -->
|
||||||
|
<select id="selectPageRel" resultType="com.gxwebsoft.common.system.entity.CompanyParameter">
|
||||||
|
<include refid="selectSql"></include>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 查询全部 -->
|
||||||
|
<select id="selectListRel" resultType="com.gxwebsoft.common.system.entity.CompanyParameter">
|
||||||
|
<include refid="selectSql"></include>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,59 @@
|
|||||||
|
<?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="com.gxwebsoft.common.system.mapper.CompanyUrlMapper">
|
||||||
|
|
||||||
|
<!-- 关联查询sql -->
|
||||||
|
<sql id="selectSql">
|
||||||
|
SELECT a.*
|
||||||
|
FROM sys_company_url a
|
||||||
|
<where>
|
||||||
|
<if test="param.id != null">
|
||||||
|
AND a.id = #{param.id}
|
||||||
|
</if>
|
||||||
|
<if test="param.type != null">
|
||||||
|
AND a.type LIKE CONCAT('%', #{param.type}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.companyId != null">
|
||||||
|
AND a.company_id = #{param.companyId}
|
||||||
|
</if>
|
||||||
|
<if test="param.domain != null">
|
||||||
|
AND a.domain LIKE CONCAT('%', #{param.domain}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.account != null">
|
||||||
|
AND a.account LIKE CONCAT('%', #{param.account}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.password != null">
|
||||||
|
AND a.password LIKE CONCAT('%', #{param.password}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.qrcode != null">
|
||||||
|
AND a.qrcode LIKE CONCAT('%', #{param.qrcode}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.comments != null">
|
||||||
|
AND a.comments LIKE CONCAT('%', #{param.comments}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="param.sortNumber != null">
|
||||||
|
AND a.sort_number = #{param.sortNumber}
|
||||||
|
</if>
|
||||||
|
<if test="param.status != null">
|
||||||
|
AND a.status = #{param.status}
|
||||||
|
</if>
|
||||||
|
<if test="param.createTimeStart != null">
|
||||||
|
AND a.create_time >= #{param.createTimeStart}
|
||||||
|
</if>
|
||||||
|
<if test="param.createTimeEnd != null">
|
||||||
|
AND a.create_time <= #{param.createTimeEnd}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<!-- 分页查询 -->
|
||||||
|
<select id="selectPageRel" resultType="com.gxwebsoft.common.system.entity.CompanyUrl">
|
||||||
|
<include refid="selectSql"></include>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 查询全部 -->
|
||||||
|
<select id="selectListRel" resultType="com.gxwebsoft.common.system.entity.CompanyUrl">
|
||||||
|
<include refid="selectSql"></include>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,58 @@
|
|||||||
|
package com.gxwebsoft.common.system.param;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||||
|
import com.gxwebsoft.common.core.annotation.QueryField;
|
||||||
|
import com.gxwebsoft.common.core.annotation.QueryType;
|
||||||
|
import com.gxwebsoft.common.core.web.BaseParam;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用评论查询参数
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||||
|
@ApiModel(value = "CompanyCommentParam对象", description = "应用评论查询参数")
|
||||||
|
public class CompanyCommentParam extends BaseParam {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "ID")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "父级ID")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer parentId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "用户ID")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer userId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "企业ID")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "评分")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private BigDecimal rate;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "排序(数字越小越靠前)")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer sortNumber;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "评论内容")
|
||||||
|
private String comments;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "状态")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer status;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
package com.gxwebsoft.common.system.param;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||||
|
import com.gxwebsoft.common.core.annotation.QueryField;
|
||||||
|
import com.gxwebsoft.common.core.annotation.QueryType;
|
||||||
|
import com.gxwebsoft.common.core.web.BaseParam;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用详情查询参数
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-16 13:41:21
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||||
|
@ApiModel(value = "CompanyContentParam对象", description = "应用详情查询参数")
|
||||||
|
public class CompanyContentParam extends BaseParam {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "企业ID")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "详细内容")
|
||||||
|
private String content;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -29,6 +29,12 @@ public class CompanyParam extends BaseParam {
|
|||||||
@QueryField(type = QueryType.EQ)
|
@QueryField(type = QueryType.EQ)
|
||||||
private Integer companyId;
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "应用类型")
|
||||||
|
private Integer type;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "是否官方")
|
||||||
|
private Boolean official;
|
||||||
|
|
||||||
@ApiModelProperty(value = "企业简称")
|
@ApiModelProperty(value = "企业简称")
|
||||||
private String shortName;
|
private String shortName;
|
||||||
|
|
||||||
@@ -48,6 +54,10 @@ public class CompanyParam extends BaseParam {
|
|||||||
@ApiModelProperty(value = "应用标识")
|
@ApiModelProperty(value = "应用标识")
|
||||||
private String companyLogo;
|
private String companyLogo;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "栏目分类")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer categoryId;
|
||||||
|
|
||||||
@ApiModelProperty(value = "企业域名")
|
@ApiModelProperty(value = "企业域名")
|
||||||
private String domain;
|
private String domain;
|
||||||
|
|
||||||
@@ -117,6 +127,7 @@ public class CompanyParam extends BaseParam {
|
|||||||
private Integer authentication;
|
private Integer authentication;
|
||||||
|
|
||||||
@ApiModelProperty(value = "是否推荐")
|
@ApiModelProperty(value = "是否推荐")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
private Boolean recommend;
|
private Boolean recommend;
|
||||||
|
|
||||||
@ApiModelProperty(value = "应用类型 app应用 plug插件")
|
@ApiModelProperty(value = "应用类型 app应用 plug插件")
|
||||||
|
|||||||
@@ -0,0 +1,50 @@
|
|||||||
|
package com.gxwebsoft.common.system.param;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||||
|
import com.gxwebsoft.common.core.annotation.QueryField;
|
||||||
|
import com.gxwebsoft.common.core.annotation.QueryType;
|
||||||
|
import com.gxwebsoft.common.core.web.BaseParam;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用参数查询参数
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||||
|
@ApiModel(value = "CompanyParameterParam对象", description = "应用参数查询参数")
|
||||||
|
public class CompanyParameterParam extends BaseParam {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "自增ID")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "参数名称")
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "参数内容")
|
||||||
|
private String value;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "企业ID")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "备注")
|
||||||
|
private String comments;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "排序(数字越小越靠前)")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer sortNumber;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "状态, 0正常, 1待确认")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer status;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,59 @@
|
|||||||
|
package com.gxwebsoft.common.system.param;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||||
|
import com.gxwebsoft.common.core.annotation.QueryField;
|
||||||
|
import com.gxwebsoft.common.core.annotation.QueryType;
|
||||||
|
import com.gxwebsoft.common.core.web.BaseParam;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用域名查询参数
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||||
|
@ApiModel(value = "CompanyUrlParam对象", description = "应用域名查询参数")
|
||||||
|
public class CompanyUrlParam extends BaseParam {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "自增ID")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "域名类型")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "企业ID")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer companyId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "域名")
|
||||||
|
private String domain;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "账号")
|
||||||
|
private String account;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "密码")
|
||||||
|
private String password;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "二维码")
|
||||||
|
private String qrcode;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "备注")
|
||||||
|
private String comments;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "排序(数字越小越靠前)")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer sortNumber;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "状态, 0正常, 1待确认")
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
private Integer status;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.gxwebsoft.common.system.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyComment;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyCommentParam;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用评论Service
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
public interface CompanyCommentService extends IService<CompanyComment> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页关联查询
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return PageResult<CompanyComment>
|
||||||
|
*/
|
||||||
|
PageResult<CompanyComment> pageRel(CompanyCommentParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 关联查询全部
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<CompanyComment>
|
||||||
|
*/
|
||||||
|
List<CompanyComment> listRel(CompanyCommentParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据id查询
|
||||||
|
*
|
||||||
|
* @param id ID
|
||||||
|
* @return CompanyComment
|
||||||
|
*/
|
||||||
|
CompanyComment getByIdRel(Integer id);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.gxwebsoft.common.system.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyContent;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyContentParam;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用详情Service
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-16 13:41:21
|
||||||
|
*/
|
||||||
|
public interface CompanyContentService extends IService<CompanyContent> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页关联查询
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return PageResult<CompanyContent>
|
||||||
|
*/
|
||||||
|
PageResult<CompanyContent> pageRel(CompanyContentParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 关联查询全部
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<CompanyContent>
|
||||||
|
*/
|
||||||
|
List<CompanyContent> listRel(CompanyContentParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据id查询
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return CompanyContent
|
||||||
|
*/
|
||||||
|
CompanyContent getByIdRel(Integer id);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.gxwebsoft.common.system.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyParameter;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyParameterParam;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用参数Service
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
public interface CompanyParameterService extends IService<CompanyParameter> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页关联查询
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return PageResult<CompanyParameter>
|
||||||
|
*/
|
||||||
|
PageResult<CompanyParameter> pageRel(CompanyParameterParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 关联查询全部
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<CompanyParameter>
|
||||||
|
*/
|
||||||
|
List<CompanyParameter> listRel(CompanyParameterParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据id查询
|
||||||
|
*
|
||||||
|
* @param id 自增ID
|
||||||
|
* @return CompanyParameter
|
||||||
|
*/
|
||||||
|
CompanyParameter getByIdRel(Integer id);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
package com.gxwebsoft.common.system.service;
|
package com.gxwebsoft.common.system.service;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
import com.gxwebsoft.common.core.web.ExistenceParam;
|
|
||||||
import com.gxwebsoft.common.core.web.PageResult;
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
import com.gxwebsoft.common.system.entity.Company;
|
import com.gxwebsoft.common.system.entity.Company;
|
||||||
import com.gxwebsoft.common.system.param.CompanyParam;
|
import com.gxwebsoft.common.system.param.CompanyParam;
|
||||||
|
|||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.gxwebsoft.common.system.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyUrl;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyUrlParam;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用域名Service
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
public interface CompanyUrlService extends IService<CompanyUrl> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页关联查询
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return PageResult<CompanyUrl>
|
||||||
|
*/
|
||||||
|
PageResult<CompanyUrl> pageRel(CompanyUrlParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 关联查询全部
|
||||||
|
*
|
||||||
|
* @param param 查询参数
|
||||||
|
* @return List<CompanyUrl>
|
||||||
|
*/
|
||||||
|
List<CompanyUrl> listRel(CompanyUrlParam param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据id查询
|
||||||
|
*
|
||||||
|
* @param id 自增ID
|
||||||
|
* @return CompanyUrl
|
||||||
|
*/
|
||||||
|
CompanyUrl getByIdRel(Integer id);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,47 @@
|
|||||||
|
package com.gxwebsoft.common.system.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.gxwebsoft.common.core.web.PageParam;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyComment;
|
||||||
|
import com.gxwebsoft.common.system.mapper.CompanyCommentMapper;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyCommentParam;
|
||||||
|
import com.gxwebsoft.common.system.service.CompanyCommentService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用评论Service实现
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class CompanyCommentServiceImpl extends ServiceImpl<CompanyCommentMapper, CompanyComment> implements CompanyCommentService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<CompanyComment> pageRel(CompanyCommentParam param) {
|
||||||
|
PageParam<CompanyComment, CompanyCommentParam> page = new PageParam<>(param);
|
||||||
|
page.setDefaultOrder("create_time desc");
|
||||||
|
List<CompanyComment> list = baseMapper.selectPageRel(page, param);
|
||||||
|
return new PageResult<>(list, page.getTotal());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<CompanyComment> listRel(CompanyCommentParam param) {
|
||||||
|
List<CompanyComment> list = baseMapper.selectListRel(param);
|
||||||
|
// 排序
|
||||||
|
PageParam<CompanyComment, CompanyCommentParam> page = new PageParam<>();
|
||||||
|
page.setDefaultOrder("create_time desc");
|
||||||
|
return page.sortRecords(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public CompanyComment getByIdRel(Integer id) {
|
||||||
|
CompanyCommentParam param = new CompanyCommentParam();
|
||||||
|
param.setId(id);
|
||||||
|
return param.getOne(baseMapper.selectListRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,47 @@
|
|||||||
|
package com.gxwebsoft.common.system.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.gxwebsoft.common.core.web.PageParam;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyContent;
|
||||||
|
import com.gxwebsoft.common.system.mapper.CompanyContentMapper;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyContentParam;
|
||||||
|
import com.gxwebsoft.common.system.service.CompanyContentService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用详情Service实现
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-16 13:41:21
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class CompanyContentServiceImpl extends ServiceImpl<CompanyContentMapper, CompanyContent> implements CompanyContentService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<CompanyContent> pageRel(CompanyContentParam param) {
|
||||||
|
PageParam<CompanyContent, CompanyContentParam> page = new PageParam<>(param);
|
||||||
|
page.setDefaultOrder("create_time desc");
|
||||||
|
List<CompanyContent> list = baseMapper.selectPageRel(page, param);
|
||||||
|
return new PageResult<>(list, page.getTotal());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<CompanyContent> listRel(CompanyContentParam param) {
|
||||||
|
List<CompanyContent> list = baseMapper.selectListRel(param);
|
||||||
|
// 排序
|
||||||
|
PageParam<CompanyContent, CompanyContentParam> page = new PageParam<>();
|
||||||
|
page.setDefaultOrder("create_time desc");
|
||||||
|
return page.sortRecords(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public CompanyContent getByIdRel(Integer id) {
|
||||||
|
CompanyContentParam param = new CompanyContentParam();
|
||||||
|
param.setId(id);
|
||||||
|
return param.getOne(baseMapper.selectListRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,47 @@
|
|||||||
|
package com.gxwebsoft.common.system.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.gxwebsoft.common.core.web.PageParam;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyParameter;
|
||||||
|
import com.gxwebsoft.common.system.mapper.CompanyParameterMapper;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyParameterParam;
|
||||||
|
import com.gxwebsoft.common.system.service.CompanyParameterService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用参数Service实现
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class CompanyParameterServiceImpl extends ServiceImpl<CompanyParameterMapper, CompanyParameter> implements CompanyParameterService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<CompanyParameter> pageRel(CompanyParameterParam param) {
|
||||||
|
PageParam<CompanyParameter, CompanyParameterParam> page = new PageParam<>(param);
|
||||||
|
page.setDefaultOrder("create_time desc");
|
||||||
|
List<CompanyParameter> list = baseMapper.selectPageRel(page, param);
|
||||||
|
return new PageResult<>(list, page.getTotal());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<CompanyParameter> listRel(CompanyParameterParam param) {
|
||||||
|
List<CompanyParameter> list = baseMapper.selectListRel(param);
|
||||||
|
// 排序
|
||||||
|
PageParam<CompanyParameter, CompanyParameterParam> page = new PageParam<>();
|
||||||
|
page.setDefaultOrder("create_time desc");
|
||||||
|
return page.sortRecords(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public CompanyParameter getByIdRel(Integer id) {
|
||||||
|
CompanyParameterParam param = new CompanyParameterParam();
|
||||||
|
param.setId(id);
|
||||||
|
return param.getOne(baseMapper.selectListRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
package com.gxwebsoft.common.system.service.impl;
|
package com.gxwebsoft.common.system.service.impl;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
import com.gxwebsoft.common.core.web.ExistenceParam;
|
|
||||||
import com.gxwebsoft.common.core.web.PageParam;
|
import com.gxwebsoft.common.core.web.PageParam;
|
||||||
import com.gxwebsoft.common.core.web.PageResult;
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
import com.gxwebsoft.common.system.entity.Company;
|
import com.gxwebsoft.common.system.entity.Company;
|
||||||
@@ -24,7 +23,7 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyMapper, Company> impl
|
|||||||
@Override
|
@Override
|
||||||
public PageResult<Company> pageRel(CompanyParam param) {
|
public PageResult<Company> pageRel(CompanyParam param) {
|
||||||
PageParam<Company, CompanyParam> page = new PageParam<>(param);
|
PageParam<Company, CompanyParam> page = new PageParam<>(param);
|
||||||
page.setDefaultOrder("create_time desc");
|
page.setDefaultOrder("sort_number desc,create_time desc");
|
||||||
List<Company> list = baseMapper.selectPageRel(page, param);
|
List<Company> list = baseMapper.selectPageRel(page, param);
|
||||||
return new PageResult<>(list, page.getTotal());
|
return new PageResult<>(list, page.getTotal());
|
||||||
}
|
}
|
||||||
@@ -56,7 +55,7 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyMapper, Company> impl
|
|||||||
@Override
|
@Override
|
||||||
public PageResult<Company> pageRelAll(CompanyParam param) {
|
public PageResult<Company> pageRelAll(CompanyParam param) {
|
||||||
PageParam<Company, CompanyParam> page = new PageParam<>(param);
|
PageParam<Company, CompanyParam> page = new PageParam<>(param);
|
||||||
page.setDefaultOrder("create_time desc");
|
page.setDefaultOrder("sort_number desc,create_time desc");
|
||||||
List<Company> list = baseMapper.selectPageRelAll(page, param);
|
List<Company> list = baseMapper.selectPageRelAll(page, param);
|
||||||
return new PageResult<>(list, page.getTotal());
|
return new PageResult<>(list, page.getTotal());
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,47 @@
|
|||||||
|
package com.gxwebsoft.common.system.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.gxwebsoft.common.core.web.PageParam;
|
||||||
|
import com.gxwebsoft.common.core.web.PageResult;
|
||||||
|
import com.gxwebsoft.common.system.entity.CompanyUrl;
|
||||||
|
import com.gxwebsoft.common.system.mapper.CompanyUrlMapper;
|
||||||
|
import com.gxwebsoft.common.system.param.CompanyUrlParam;
|
||||||
|
import com.gxwebsoft.common.system.service.CompanyUrlService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 应用域名Service实现
|
||||||
|
*
|
||||||
|
* @author 科技小王子
|
||||||
|
* @since 2024-10-17 15:30:24
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class CompanyUrlServiceImpl extends ServiceImpl<CompanyUrlMapper, CompanyUrl> implements CompanyUrlService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<CompanyUrl> pageRel(CompanyUrlParam param) {
|
||||||
|
PageParam<CompanyUrl, CompanyUrlParam> page = new PageParam<>(param);
|
||||||
|
page.setDefaultOrder("create_time desc");
|
||||||
|
List<CompanyUrl> list = baseMapper.selectPageRel(page, param);
|
||||||
|
return new PageResult<>(list, page.getTotal());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<CompanyUrl> listRel(CompanyUrlParam param) {
|
||||||
|
List<CompanyUrl> list = baseMapper.selectListRel(param);
|
||||||
|
// 排序
|
||||||
|
PageParam<CompanyUrl, CompanyUrlParam> page = new PageParam<>();
|
||||||
|
page.setDefaultOrder("create_time desc");
|
||||||
|
return page.sortRecords(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public CompanyUrl getByIdRel(Integer id) {
|
||||||
|
CompanyUrlParam param = new CompanyUrlParam();
|
||||||
|
param.setId(id);
|
||||||
|
return param.getOne(baseMapper.selectListRel(param));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
# 端口
|
# 端口
|
||||||
server:
|
server:
|
||||||
port: 30000
|
port: 9001
|
||||||
# socketIo
|
# socketIo
|
||||||
socketio:
|
socketio:
|
||||||
port: 30091
|
port: 30091
|
||||||
|
|||||||
Reference in New Issue
Block a user