1.0.1 add客户信息
parent
a50cdefaf1
commit
44a3fc98f5
@ -0,0 +1,128 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<parent>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-modules</artifactId>
|
||||
<version>${revision}</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>ruoyi-oa</artifactId>
|
||||
|
||||
<description>
|
||||
ruoyi-oa办公模块
|
||||
</description>
|
||||
|
||||
<dependencies>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-nacos</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- RuoYi Common Log -->
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-log</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-service-impl</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-doc</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-web</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-mybatis</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-dubbo</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-seata</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-idempotent</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-tenant</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-security</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-translation</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-sensitive</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-encrypt</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- RuoYi Api System -->
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-api-system</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-api-resource</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- RuoYi Api System -->
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-api-workflow</artifactId>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<finalName>${project.artifactId}</finalName>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
<version>${spring-boot.version}</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<goals>
|
||||
<goal>repackage</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
||||
@ -0,0 +1,22 @@
|
||||
package org.dromara.oa;
|
||||
|
||||
import org.apache.dubbo.config.spring.context.annotation.EnableDubbo;
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
import org.springframework.boot.context.metrics.buffering.BufferingApplicationStartup;
|
||||
|
||||
/**
|
||||
* OA模块
|
||||
*
|
||||
* @author Yinq
|
||||
*/
|
||||
@EnableDubbo
|
||||
@SpringBootApplication
|
||||
public class RuoYiOaApplication {
|
||||
public static void main(String[] args) {
|
||||
SpringApplication application = new SpringApplication(RuoYiOaApplication.class);
|
||||
application.setApplicationStartup(new BufferingApplicationStartup(2048));
|
||||
application.run(args);
|
||||
System.out.println("(♥◠‿◠)ノ゙ OA模块启动成功 ლ(´ڡ`ლ)゙ ");
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,116 @@
|
||||
package org.dromara.oa.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.oa.domain.vo.BaseCustomerVo;
|
||||
import org.dromara.oa.domain.bo.BaseCustomerBo;
|
||||
import org.dromara.oa.service.IBaseCustomerService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 客户信息
|
||||
* 前端访问路由地址为:/oa/baseCustomer
|
||||
*
|
||||
* @author Yinq
|
||||
* @date 2025-09-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/baseCustomer")
|
||||
public class BaseCustomerController extends BaseController {
|
||||
|
||||
private final IBaseCustomerService baseCustomerService;
|
||||
|
||||
/**
|
||||
* 查询客户信息列表
|
||||
*/
|
||||
@SaCheckPermission("oa:baseCustomer:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BaseCustomerVo> list(BaseCustomerBo bo, PageQuery pageQuery) {
|
||||
return baseCustomerService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出客户信息列表
|
||||
*/
|
||||
@SaCheckPermission("oa:baseCustomer:export")
|
||||
@Log(title = "客户信息", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BaseCustomerBo bo, HttpServletResponse response) {
|
||||
List<BaseCustomerVo> list = baseCustomerService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "客户信息", BaseCustomerVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取客户信息详细信息
|
||||
*
|
||||
* @param customerId 主键
|
||||
*/
|
||||
@SaCheckPermission("oa:baseCustomer:query")
|
||||
@GetMapping("/{customerId}")
|
||||
public R<BaseCustomerVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("customerId") Long customerId) {
|
||||
return R.ok(baseCustomerService.queryById(customerId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增客户信息
|
||||
*/
|
||||
@SaCheckPermission("oa:baseCustomer:add")
|
||||
@Log(title = "客户信息", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BaseCustomerBo bo) {
|
||||
return toAjax(baseCustomerService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改客户信息
|
||||
*/
|
||||
@SaCheckPermission("oa:baseCustomer:edit")
|
||||
@Log(title = "客户信息", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BaseCustomerBo bo) {
|
||||
return toAjax(baseCustomerService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除客户信息
|
||||
*
|
||||
* @param customerIds 主键串
|
||||
*/
|
||||
@SaCheckPermission("oa:baseCustomer:remove")
|
||||
@Log(title = "客户信息", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{customerIds}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("customerIds") Long[] customerIds) {
|
||||
return toAjax(baseCustomerService.deleteWithValidByIds(List.of(customerIds), true));
|
||||
}
|
||||
|
||||
/**
|
||||
* 下拉框查询客户信息列表
|
||||
*/
|
||||
@GetMapping("/getBaseCustomerList")
|
||||
public R<List<BaseCustomerVo>> getBaseCustomerList(BaseCustomerBo bo) {
|
||||
List<BaseCustomerVo> list = baseCustomerService.queryList(bo);
|
||||
return R.ok(list);
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,37 @@
|
||||
package org.dromara.oa.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.dromara.oa.domain.BaseCustomer;
|
||||
import org.dromara.oa.domain.vo.BaseCustomerVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 客户信息Mapper接口
|
||||
*
|
||||
* @author Yinq
|
||||
* @date 2025-09-15
|
||||
*/
|
||||
public interface BaseCustomerMapper extends BaseMapperPlus<BaseCustomer, BaseCustomerVo> {
|
||||
|
||||
/**
|
||||
* 查询客户信息列表
|
||||
*
|
||||
* @param page 分页
|
||||
* @param queryWrapper 条件
|
||||
* @return 客户信息集合
|
||||
*/
|
||||
public Page<BaseCustomerVo> selectCustomBaseCustomerVoList(@Param("page") Page<BaseCustomerVo> page, @Param(Constants.WRAPPER) MPJLambdaWrapper<BaseCustomer> queryWrapper);
|
||||
|
||||
/**
|
||||
* 查询客户信息列表
|
||||
*
|
||||
* @param queryWrapper 条件
|
||||
* @return 客户信息集合
|
||||
*/
|
||||
public List<BaseCustomerVo> selectCustomBaseCustomerVoList(@Param(Constants.WRAPPER) MPJLambdaWrapper<BaseCustomer> queryWrapper);
|
||||
|
||||
}
|
||||
@ -0,0 +1,69 @@
|
||||
package org.dromara.oa.service;
|
||||
|
||||
import org.dromara.oa.domain.BaseCustomer;
|
||||
import org.dromara.oa.domain.vo.BaseCustomerVo;
|
||||
import org.dromara.oa.domain.bo.BaseCustomerBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 客户信息Service接口
|
||||
*
|
||||
* @author Yinq
|
||||
* @date 2025-09-12
|
||||
*/
|
||||
public interface IBaseCustomerService {
|
||||
|
||||
/**
|
||||
* 查询客户信息
|
||||
*
|
||||
* @param customerId 主键
|
||||
* @return 客户信息
|
||||
*/
|
||||
BaseCustomerVo queryById(Long customerId);
|
||||
|
||||
/**
|
||||
* 分页查询客户信息列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 客户信息分页列表
|
||||
*/
|
||||
TableDataInfo<BaseCustomerVo> queryPageList(BaseCustomerBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的客户信息列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 客户信息列表
|
||||
*/
|
||||
List<BaseCustomerVo> queryList(BaseCustomerBo bo);
|
||||
|
||||
/**
|
||||
* 新增客户信息
|
||||
*
|
||||
* @param bo 客户信息
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(BaseCustomerBo bo);
|
||||
|
||||
/**
|
||||
* 修改客户信息
|
||||
*
|
||||
* @param bo 客户信息
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(BaseCustomerBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除客户信息信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
||||
@ -0,0 +1,147 @@
|
||||
package org.dromara.oa.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.github.yulichang.toolkit.JoinWrappers;
|
||||
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.oa.domain.bo.BaseCustomerBo;
|
||||
import org.dromara.oa.domain.vo.BaseCustomerVo;
|
||||
import org.dromara.oa.domain.BaseCustomer;
|
||||
import org.dromara.oa.mapper.BaseCustomerMapper;
|
||||
import org.dromara.oa.service.IBaseCustomerService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 客户信息Service业务层处理
|
||||
*
|
||||
* @author Yinq
|
||||
* @date 2025-09-15
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class BaseCustomerServiceImpl implements IBaseCustomerService {
|
||||
|
||||
private final BaseCustomerMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询客户信息
|
||||
*
|
||||
* @param customerId 主键
|
||||
* @return 客户信息
|
||||
*/
|
||||
@Override
|
||||
public BaseCustomerVo queryById(Long customerId) {
|
||||
return baseMapper.selectVoById(customerId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询客户信息列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 客户信息分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<BaseCustomerVo> queryPageList(BaseCustomerBo bo, PageQuery pageQuery) {
|
||||
MPJLambdaWrapper<BaseCustomer> lqw = buildQueryWrapper(bo);
|
||||
Page<BaseCustomerVo> result = baseMapper.selectCustomBaseCustomerVoList(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的客户信息列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 客户信息列表
|
||||
*/
|
||||
@Override
|
||||
public List<BaseCustomerVo> queryList(BaseCustomerBo bo) {
|
||||
MPJLambdaWrapper<BaseCustomer> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectCustomBaseCustomerVoList(lqw);
|
||||
}
|
||||
|
||||
private MPJLambdaWrapper<BaseCustomer> buildQueryWrapper(BaseCustomerBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
MPJLambdaWrapper<BaseCustomer> lqw = JoinWrappers.lambda(BaseCustomer.class)
|
||||
.selectAll(BaseCustomer.class)
|
||||
.like(StringUtils.isNotBlank(bo.getCustomerName()), BaseCustomer::getCustomerName, bo.getCustomerName())
|
||||
.like(StringUtils.isNotBlank(bo.getMnemonicName()), BaseCustomer::getMnemonicName, bo.getMnemonicName())
|
||||
.eq(bo.getIndustryId() != null, BaseCustomer::getIndustryId, bo.getIndustryId())
|
||||
.eq(bo.getCustomerType() != null, BaseCustomer::getCustomerType, bo.getCustomerType())
|
||||
.eq(bo.getCustomerStatus() != null, BaseCustomer::getCustomerStatus, bo.getCustomerStatus())
|
||||
.eq(bo.getCustomerLevel() != null, BaseCustomer::getCustomerLevel, bo.getCustomerLevel())
|
||||
.eq(bo.getCustomerSource() != null, BaseCustomer::getCustomerSource, bo.getCustomerSource())
|
||||
.eq(bo.getOwnerId() != null, BaseCustomer::getOwnerId, bo.getOwnerId())
|
||||
.eq(StringUtils.isNotBlank(bo.getDetailedAddress()), BaseCustomer::getDetailedAddress, bo.getDetailedAddress())
|
||||
.eq(bo.getCustomerScale() != null, BaseCustomer::getCustomerScale, bo.getCustomerScale())
|
||||
.eq(bo.getParentCustomerId() != null, BaseCustomer::getParentCustomerId, bo.getParentCustomerId())
|
||||
.eq(StringUtils.isNotBlank(bo.getLegalRepresentative()), BaseCustomer::getLegalRepresentative, bo.getLegalRepresentative())
|
||||
.eq(StringUtils.isNotBlank(bo.getBusinessLicenseNumber()), BaseCustomer::getBusinessLicenseNumber, bo.getBusinessLicenseNumber())
|
||||
.eq(StringUtils.isNotBlank(bo.getBankAccountOpening()), BaseCustomer::getBankAccountOpening, bo.getBankAccountOpening())
|
||||
.eq(StringUtils.isNotBlank(bo.getTaxNumber()), BaseCustomer::getTaxNumber, bo.getTaxNumber())
|
||||
.eq(StringUtils.isNotBlank(bo.getActiveFlag()), BaseCustomer::getActiveFlag, bo.getActiveFlag())
|
||||
.orderByAsc(BaseCustomer::getCustomerId);
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增客户信息
|
||||
*
|
||||
* @param bo 客户信息
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(BaseCustomerBo bo) {
|
||||
BaseCustomer add = MapstructUtils.convert(bo, BaseCustomer.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setCustomerId(add.getCustomerId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改客户信息
|
||||
*
|
||||
* @param bo 客户信息
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(BaseCustomerBo bo) {
|
||||
BaseCustomer update = MapstructUtils.convert(bo, BaseCustomer.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(BaseCustomer entity) {
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除客户信息信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if (isValid) {
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,34 @@
|
||||
# Tomcat
|
||||
server:
|
||||
port: 9301
|
||||
|
||||
# Spring
|
||||
spring:
|
||||
application:
|
||||
# 应用名称
|
||||
name: ruoyi-oa
|
||||
profiles:
|
||||
# 环境配置
|
||||
active: @profiles.active@
|
||||
|
||||
--- # nacos 配置
|
||||
spring:
|
||||
cloud:
|
||||
nacos:
|
||||
# nacos 服务地址
|
||||
server-addr: @nacos.server@
|
||||
username: @nacos.username@
|
||||
password: @nacos.password@
|
||||
discovery:
|
||||
# 注册组
|
||||
group: @nacos.discovery.group@
|
||||
namespace: ${spring.profiles.active}
|
||||
config:
|
||||
# 配置组
|
||||
group: @nacos.config.group@
|
||||
namespace: ${spring.profiles.active}
|
||||
config:
|
||||
import:
|
||||
- optional:nacos:application-common.yml
|
||||
- optional:nacos:datasource.yml
|
||||
- optional:nacos:${spring.application.name}.yml
|
||||
@ -0,0 +1,9 @@
|
||||
Spring Boot Version: ${spring-boot.version}
|
||||
Spring Application Name: ${spring.application.name}
|
||||
_ _ __ __ ___ _
|
||||
| | | | \ \ / / / _ \ / \
|
||||
| |_| | \ \ /\ / / _____ | | | | / _ \
|
||||
| _ | \ V V / |_____| | |_| | / ___ \
|
||||
|_| |_| \_/\_/ \___/ /_/ \_\
|
||||
|
||||
|
||||
@ -0,0 +1,28 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configuration scan="true" scanPeriod="60 seconds" debug="false">
|
||||
<!-- 日志存放路径 -->
|
||||
<property name="log.path" value="logs/${project.artifactId}" />
|
||||
<!-- 日志输出格式 -->
|
||||
<property name="console.log.pattern"
|
||||
value="%cyan(%d{yyyy-MM-dd HH:mm:ss}) %green([%thread]) %highlight(%-5level) %boldMagenta(%logger{36}%n) - %msg%n"/>
|
||||
|
||||
<!-- 控制台输出 -->
|
||||
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
|
||||
<encoder>
|
||||
<pattern>${console.log.pattern}</pattern>
|
||||
<charset>utf-8</charset>
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<include resource="logback-common.xml" />
|
||||
|
||||
<include resource="logback-logstash.xml" />
|
||||
|
||||
<!-- 开启 skywalking 日志收集 -->
|
||||
<include resource="logback-skylog.xml" />
|
||||
|
||||
<!--系统操作日志-->
|
||||
<root level="info">
|
||||
<appender-ref ref="console" />
|
||||
</root>
|
||||
</configuration>
|
||||
@ -0,0 +1,39 @@
|
||||
<?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.dromara.oa.mapper.BaseCustomerMapper">
|
||||
<resultMap type="org.dromara.oa.domain.vo.BaseCustomerVo" id="BaseCustomerResult">
|
||||
</resultMap>
|
||||
|
||||
<select id="selectCustomBaseCustomerVoList" resultMap="BaseCustomerResult">
|
||||
select customer_id,
|
||||
tenant_id,
|
||||
customer_name,
|
||||
mnemonic_name,
|
||||
industry_id,
|
||||
customer_type,
|
||||
customer_status,
|
||||
customer_level,
|
||||
customer_source,
|
||||
owner_id,
|
||||
detailed_address,
|
||||
customer_scale,
|
||||
parent_customer_id,
|
||||
legal_representative,
|
||||
business_license_number,
|
||||
bank_account_opening,
|
||||
tax_number,
|
||||
remark,
|
||||
active_flag,
|
||||
del_flag,
|
||||
create_dept,
|
||||
create_by,
|
||||
create_time,
|
||||
update_by,
|
||||
update_time
|
||||
from base_customer t
|
||||
${ew.getCustomSqlSegment}
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
Loading…
Reference in New Issue