基本增删改查
parent
87837b20ec
commit
b01ac1370a
|
|
@ -4,3 +4,4 @@
|
||||||
/**/target
|
/**/target
|
||||||
/**/.DS_Store
|
/**/.DS_Store
|
||||||
/**/.njzscloud-dispose
|
/**/.njzscloud-dispose
|
||||||
|
/接口文档
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,57 @@
|
||||||
|
package com.njzscloud.dispose.common.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通用基础字段
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
public class BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 主键
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建人 Id;sys_user.id
|
||||||
|
*/
|
||||||
|
@TableField(fill = FieldFill.INSERT)
|
||||||
|
private Long creatorId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改人 Id; sys_user.id
|
||||||
|
*/
|
||||||
|
@TableField(fill = FieldFill.INSERT_UPDATE)
|
||||||
|
private Long modifierId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建时间
|
||||||
|
*/
|
||||||
|
@TableField(fill = FieldFill.INSERT)
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改时间
|
||||||
|
*/
|
||||||
|
@TableField(fill = FieldFill.INSERT_UPDATE)
|
||||||
|
private LocalDateTime modifyTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否删除; 0-->未删除、1-->已删除
|
||||||
|
*/
|
||||||
|
@TableLogic
|
||||||
|
private Boolean deleted;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.cst.driver.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.driver.pojo.entity.DriverEntity;
|
||||||
|
import com.njzscloud.dispose.cst.driver.service.DriverService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 司机
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/driver")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class DriverController {
|
||||||
|
|
||||||
|
private final DriverService driverService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody DriverEntity driverEntity) {
|
||||||
|
driverService.add(driverEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody DriverEntity driverEntity) {
|
||||||
|
driverService.modify(driverEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
driverService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<DriverEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(driverService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<DriverEntity>> paging(PageParam pageParam, DriverEntity driverEntity) {
|
||||||
|
return R.success(driverService.paging(pageParam, driverEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
package com.njzscloud.dispose.cst.driver.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.cst.driver.pojo.entity.DriverEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 司机
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface DriverMapper extends BaseMapper<DriverEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,73 @@
|
||||||
|
package com.njzscloud.dispose.cst.driver.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 司机
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("cst_driver")
|
||||||
|
public class DriverEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 归属用户 Id;sys_user.id
|
||||||
|
*/
|
||||||
|
private Long userId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 归属客户 Id;cst_customer.id
|
||||||
|
*/
|
||||||
|
private Long customerId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 归属公司 Id;cst_org.id
|
||||||
|
*/
|
||||||
|
private Long orgId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 驾驶证编号
|
||||||
|
*/
|
||||||
|
private String drivingLicenceNo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 司机姓名
|
||||||
|
*/
|
||||||
|
private String driverName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 手机号
|
||||||
|
*/
|
||||||
|
private String phone;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 驾驶证图片
|
||||||
|
*/
|
||||||
|
private String drivingLicence;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 驾驶证有效期开始
|
||||||
|
*/
|
||||||
|
private LocalDateTime licenceStartTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 驾驶证有效期结束
|
||||||
|
*/
|
||||||
|
private LocalDateTime licenceEndTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 忙碌中
|
||||||
|
*/
|
||||||
|
private Boolean busy;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,26 @@
|
||||||
|
package com.njzscloud.dispose.cst.driver.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.driver.pojo.entity.DriverEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 司机
|
||||||
|
*/
|
||||||
|
public interface DriverService extends IService<DriverEntity> {
|
||||||
|
|
||||||
|
void add(DriverEntity driverEntity);
|
||||||
|
|
||||||
|
void modify(DriverEntity driverEntity);
|
||||||
|
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
DriverEntity detail(Long id);
|
||||||
|
|
||||||
|
PageResult<DriverEntity> paging(PageParam pageParam, DriverEntity driverEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
package com.njzscloud.dispose.cst.driver.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.driver.mapper.DriverMapper;
|
||||||
|
import com.njzscloud.dispose.cst.driver.pojo.entity.DriverEntity;
|
||||||
|
import com.njzscloud.dispose.cst.driver.service.DriverService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 司机
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class DriverServiceImpl extends ServiceImpl<DriverMapper, DriverEntity> implements DriverService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void add(DriverEntity driverEntity) {
|
||||||
|
this.save(driverEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void modify(DriverEntity driverEntity) {
|
||||||
|
this.updateById(driverEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public DriverEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<DriverEntity> paging(PageParam pageParam, DriverEntity driverEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<DriverEntity>query(driverEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.cst.project.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.project.pojo.entity.ProjectEntity;
|
||||||
|
import com.njzscloud.dispose.cst.project.service.ProjectService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 项目信息
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/project")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class ProjectController {
|
||||||
|
|
||||||
|
private final ProjectService projectService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody ProjectEntity projectEntity) {
|
||||||
|
projectService.add(projectEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody ProjectEntity projectEntity) {
|
||||||
|
projectService.modify(projectEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
projectService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<ProjectEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(projectService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<ProjectEntity>> paging(PageParam pageParam, ProjectEntity projectEntity) {
|
||||||
|
return R.success(projectService.paging(pageParam, projectEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
package com.njzscloud.dispose.cst.project.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.cst.project.pojo.entity.ProjectEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 项目信息
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface ProjectMapper extends BaseMapper<ProjectEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,118 @@
|
||||||
|
package com.njzscloud.dispose.cst.project.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 项目信息
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("cst_project")
|
||||||
|
public class ProjectEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 项目名称
|
||||||
|
*/
|
||||||
|
private String projectName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 合同图片
|
||||||
|
*/
|
||||||
|
private String contractPicture;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 运输方客户 Id
|
||||||
|
*/
|
||||||
|
private Long transCustomerId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 运输方组织 Id
|
||||||
|
*/
|
||||||
|
private Long transOrgId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产废方/购买方客户 Id
|
||||||
|
*/
|
||||||
|
private Long fringeCustomerId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产废方/购买方组织 Id
|
||||||
|
*/
|
||||||
|
private Long fringeOrgId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 省;代码
|
||||||
|
*/
|
||||||
|
private String province;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 市;代码
|
||||||
|
*/
|
||||||
|
private String city;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 区县;代码
|
||||||
|
*/
|
||||||
|
private String area;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 乡镇街道;代码
|
||||||
|
*/
|
||||||
|
private String town;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 省;名称
|
||||||
|
*/
|
||||||
|
private String provinceName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 市;名称
|
||||||
|
*/
|
||||||
|
private String cityName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 区县;名称
|
||||||
|
*/
|
||||||
|
private String areaName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 乡镇街道;名称
|
||||||
|
*/
|
||||||
|
private String townName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详细地址
|
||||||
|
*/
|
||||||
|
private String address;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 经度
|
||||||
|
*/
|
||||||
|
private Double lng;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 纬度
|
||||||
|
*/
|
||||||
|
private Double lat;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 合同有效期
|
||||||
|
*/
|
||||||
|
private LocalDate contractStartDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 合同有效期
|
||||||
|
*/
|
||||||
|
private LocalDate contractEndDate;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,26 @@
|
||||||
|
package com.njzscloud.dispose.cst.project.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.project.pojo.entity.ProjectEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 项目信息
|
||||||
|
*/
|
||||||
|
public interface ProjectService extends IService<ProjectEntity> {
|
||||||
|
|
||||||
|
void add(ProjectEntity projectEntity);
|
||||||
|
|
||||||
|
void modify(ProjectEntity projectEntity);
|
||||||
|
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
ProjectEntity detail(Long id);
|
||||||
|
|
||||||
|
PageResult<ProjectEntity> paging(PageParam pageParam, ProjectEntity projectEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
package com.njzscloud.dispose.cst.project.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.project.mapper.ProjectMapper;
|
||||||
|
import com.njzscloud.dispose.cst.project.pojo.entity.ProjectEntity;
|
||||||
|
import com.njzscloud.dispose.cst.project.service.ProjectService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 项目信息
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, ProjectEntity> implements ProjectService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void add(ProjectEntity projectEntity) {
|
||||||
|
this.save(projectEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void modify(ProjectEntity projectEntity) {
|
||||||
|
this.updateById(projectEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ProjectEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<ProjectEntity> paging(PageParam pageParam, ProjectEntity projectEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<ProjectEntity>query(projectEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.cst.station.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.station.pojo.entity.StationEntity;
|
||||||
|
import com.njzscloud.dispose.cst.station.service.StationService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 站点信息
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/station")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class StationController {
|
||||||
|
|
||||||
|
private final StationService stationService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody StationEntity stationEntity) {
|
||||||
|
stationService.add(stationEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody StationEntity stationEntity) {
|
||||||
|
stationService.modify(stationEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
stationService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<StationEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(stationService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<StationEntity>> paging(PageParam pageParam, StationEntity stationEntity) {
|
||||||
|
return R.success(stationService.paging(pageParam, stationEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
package com.njzscloud.dispose.cst.station.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.cst.station.pojo.entity.StationEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 站点信息
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface StationMapper extends BaseMapper<StationEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,85 @@
|
||||||
|
package com.njzscloud.dispose.cst.station.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 站点信息
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("cst_station")
|
||||||
|
public class StationEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 组织信息 Id
|
||||||
|
*/
|
||||||
|
private Long orgId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 站点名称
|
||||||
|
*/
|
||||||
|
private String stationName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 省;代码
|
||||||
|
*/
|
||||||
|
private String province;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 市;代码
|
||||||
|
*/
|
||||||
|
private String city;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 区县;代码
|
||||||
|
*/
|
||||||
|
private String area;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 乡镇街道;代码
|
||||||
|
*/
|
||||||
|
private String town;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 省;名称
|
||||||
|
*/
|
||||||
|
private String provinceName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 市;名称
|
||||||
|
*/
|
||||||
|
private String cityName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 区县;名称
|
||||||
|
*/
|
||||||
|
private String areaName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 乡镇街道;名称
|
||||||
|
*/
|
||||||
|
private String townName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详细地址
|
||||||
|
*/
|
||||||
|
private String address;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 经度
|
||||||
|
*/
|
||||||
|
private Double lng;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 纬度
|
||||||
|
*/
|
||||||
|
private Double lat;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,26 @@
|
||||||
|
package com.njzscloud.dispose.cst.station.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.station.pojo.entity.StationEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 站点信息
|
||||||
|
*/
|
||||||
|
public interface StationService extends IService<StationEntity> {
|
||||||
|
|
||||||
|
void add(StationEntity stationEntity);
|
||||||
|
|
||||||
|
void modify(StationEntity stationEntity);
|
||||||
|
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
StationEntity detail(Long id);
|
||||||
|
|
||||||
|
PageResult<StationEntity> paging(PageParam pageParam, StationEntity stationEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
package com.njzscloud.dispose.cst.station.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.station.mapper.StationMapper;
|
||||||
|
import com.njzscloud.dispose.cst.station.pojo.entity.StationEntity;
|
||||||
|
import com.njzscloud.dispose.cst.station.service.StationService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 站点信息
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class StationServiceImpl extends ServiceImpl<StationMapper, StationEntity> implements StationService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void add(StationEntity stationEntity) {
|
||||||
|
this.save(stationEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void modify(StationEntity stationEntity) {
|
||||||
|
this.updateById(stationEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public StationEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<StationEntity> paging(PageParam pageParam, StationEntity stationEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<StationEntity>query(stationEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.cst.truck.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.truck.pojo.entity.TruckEntity;
|
||||||
|
import com.njzscloud.dispose.cst.truck.service.TruckService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车辆信息
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/truck")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class TruckController {
|
||||||
|
|
||||||
|
private final TruckService truckService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody TruckEntity truckEntity) {
|
||||||
|
truckService.add(truckEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody TruckEntity truckEntity) {
|
||||||
|
truckService.modify(truckEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
truckService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<TruckEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(truckService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<TruckEntity>> paging(PageParam pageParam, TruckEntity truckEntity) {
|
||||||
|
return R.success(truckService.paging(pageParam, truckEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
package com.njzscloud.dispose.cst.truck.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.cst.truck.pojo.entity.TruckEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车辆信息
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface TruckMapper extends BaseMapper<TruckEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,98 @@
|
||||||
|
package com.njzscloud.dispose.cst.truck.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车辆信息
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("cst_truck")
|
||||||
|
public class TruckEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 归属客户 Id;cst_customer.id
|
||||||
|
*/
|
||||||
|
private Long customerId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 归属组织
|
||||||
|
*/
|
||||||
|
private Long orgId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车牌
|
||||||
|
*/
|
||||||
|
private String licensePlate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 行驶证图片
|
||||||
|
*/
|
||||||
|
private String truckLicense;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车架号
|
||||||
|
*/
|
||||||
|
private String vnCode;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 合格证图片
|
||||||
|
*/
|
||||||
|
private String qualification;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 最大载重;单位:千克
|
||||||
|
*/
|
||||||
|
private Integer carryingCapacity;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 皮重;单位:千克
|
||||||
|
*/
|
||||||
|
private Integer tareWeight;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 行驶证有效期
|
||||||
|
*/
|
||||||
|
private LocalDate licenseStartDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 行驶证有效期
|
||||||
|
*/
|
||||||
|
private LocalDate licenseEndDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 合格证有效期
|
||||||
|
*/
|
||||||
|
private LocalDate qualificationStartDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 合格证有效期
|
||||||
|
*/
|
||||||
|
private LocalDate qualificationEndDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车辆类型
|
||||||
|
*/
|
||||||
|
private String truckCategory;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车辆图片
|
||||||
|
*/
|
||||||
|
private String picture;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 忙碌中
|
||||||
|
*/
|
||||||
|
private Boolean busy;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,26 @@
|
||||||
|
package com.njzscloud.dispose.cst.truck.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.truck.pojo.entity.TruckEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车辆信息
|
||||||
|
*/
|
||||||
|
public interface TruckService extends IService<TruckEntity> {
|
||||||
|
|
||||||
|
void add(TruckEntity truckEntity);
|
||||||
|
|
||||||
|
void modify(TruckEntity truckEntity);
|
||||||
|
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
TruckEntity detail(Long id);
|
||||||
|
|
||||||
|
PageResult<TruckEntity> paging(PageParam pageParam, TruckEntity truckEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
package com.njzscloud.dispose.cst.truck.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.cst.truck.mapper.TruckMapper;
|
||||||
|
import com.njzscloud.dispose.cst.truck.pojo.entity.TruckEntity;
|
||||||
|
import com.njzscloud.dispose.cst.truck.service.TruckService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车辆信息
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class TruckServiceImpl extends ServiceImpl<TruckMapper, TruckEntity> implements TruckService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void add(TruckEntity truckEntity) {
|
||||||
|
this.save(truckEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void modify(TruckEntity truckEntity) {
|
||||||
|
this.updateById(truckEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public TruckEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<TruckEntity> paging(PageParam pageParam, TruckEntity truckEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<TruckEntity>query(truckEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.finance.bill.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.bill.pojo.entity.BillEntity;
|
||||||
|
import com.njzscloud.dispose.finance.bill.service.BillService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 对账单
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/bill")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class BillController {
|
||||||
|
|
||||||
|
private final BillService billService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody BillEntity billEntity) {
|
||||||
|
billService.add(billEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody BillEntity billEntity) {
|
||||||
|
billService.modify(billEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
billService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<BillEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(billService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<BillEntity>> paging(PageParam pageParam, BillEntity billEntity) {
|
||||||
|
return R.success(billService.paging(pageParam, billEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
package com.njzscloud.dispose.finance.bill.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.finance.bill.pojo.entity.BillEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 对账单
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface BillMapper extends BaseMapper<BillEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,89 @@
|
||||||
|
package com.njzscloud.dispose.finance.bill.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 对账单
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("fin_bill")
|
||||||
|
public class BillEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户 Id
|
||||||
|
*/
|
||||||
|
private Long userId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 客户 Id;cst_customer.id
|
||||||
|
*/
|
||||||
|
private Long customerId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 组织 Id
|
||||||
|
*/
|
||||||
|
private Long orgId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 账户类型;account_type,GeRen-->个人、QiYe-->企业
|
||||||
|
*/
|
||||||
|
private String accountType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 账期
|
||||||
|
*/
|
||||||
|
private LocalDate billPeriod;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 账单开始时间
|
||||||
|
*/
|
||||||
|
private LocalDate startTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 账单结束时间
|
||||||
|
*/
|
||||||
|
private LocalDate endTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 订单数
|
||||||
|
*/
|
||||||
|
private Integer orderCount;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 总车数
|
||||||
|
*/
|
||||||
|
private Integer carCount;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 总质量
|
||||||
|
*/
|
||||||
|
private Integer totalWeight;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 优惠金额
|
||||||
|
*/
|
||||||
|
private BigDecimal discountMoney;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 账单金额
|
||||||
|
*/
|
||||||
|
private BigDecimal totalMoney;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
private String memo;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,41 @@
|
||||||
|
package com.njzscloud.dispose.finance.bill.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.bill.pojo.entity.BillEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 对账单
|
||||||
|
*/
|
||||||
|
public interface BillService extends IService<BillEntity> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
void add(BillEntity billEntity);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
void modify(BillEntity billEntity);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
BillEntity detail(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
PageResult<BillEntity> paging(PageParam pageParam, BillEntity billEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,67 @@
|
||||||
|
package com.njzscloud.dispose.finance.bill.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.bill.mapper.BillMapper;
|
||||||
|
import com.njzscloud.dispose.finance.bill.pojo.entity.BillEntity;
|
||||||
|
import com.njzscloud.dispose.finance.bill.service.BillService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 对账单
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class BillServiceImpl extends ServiceImpl<BillMapper, BillEntity> implements BillService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void add(BillEntity billEntity) {
|
||||||
|
this.save(billEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void modify(BillEntity billEntity) {
|
||||||
|
this.updateById(billEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public BillEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public PageResult<BillEntity> paging(PageParam pageParam, BillEntity billEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<BillEntity>query(billEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.finance.expenseItem.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.expenseItem.pojo.entity.ExpenseItemEntity;
|
||||||
|
import com.njzscloud.dispose.finance.expenseItem.service.ExpenseItemService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 收费项目
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/expense_item")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class ExpenseItemController {
|
||||||
|
|
||||||
|
private final ExpenseItemService expenseItemService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody ExpenseItemEntity expenseItemEntity) {
|
||||||
|
expenseItemService.add(expenseItemEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody ExpenseItemEntity expenseItemEntity) {
|
||||||
|
expenseItemService.modify(expenseItemEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
expenseItemService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<ExpenseItemEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(expenseItemService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<ExpenseItemEntity>> paging(PageParam pageParam, ExpenseItemEntity expenseItemEntity) {
|
||||||
|
return R.success(expenseItemService.paging(pageParam, expenseItemEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
package com.njzscloud.dispose.finance.expenseItem.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.finance.expenseItem.pojo.entity.ExpenseItemEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 收费项目
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface ExpenseItemMapper extends BaseMapper<ExpenseItemEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,106 @@
|
||||||
|
package com.njzscloud.dispose.finance.expenseItem.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 收费项目
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("fin_expense_item")
|
||||||
|
public class ExpenseItemEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Id
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 收费项目类型,QiTa-->其他、ChanPin-->产品、YunFei-->运费
|
||||||
|
*/
|
||||||
|
private String expenseItemCategory;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 付费项名称
|
||||||
|
*/
|
||||||
|
private String expenseItemName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 计费策略;字典代码:expense_strategy
|
||||||
|
*/
|
||||||
|
private String expenseStrategy;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 计量单位;字典代码:unit
|
||||||
|
*/
|
||||||
|
private String unit;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 税率
|
||||||
|
*/
|
||||||
|
private BigDecimal taxRate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 付费方;字典代码:payer
|
||||||
|
*/
|
||||||
|
private String payer;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 单价;单位:元,弹性模式-->每档价格
|
||||||
|
*/
|
||||||
|
private BigDecimal unitPrice;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 起步价;单位:元,<= 起步量 固定费用
|
||||||
|
*/
|
||||||
|
private BigDecimal initialPrice;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 起步量
|
||||||
|
*/
|
||||||
|
private Integer initialQuantity;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 每档的量
|
||||||
|
*/
|
||||||
|
private Integer everyQuantity;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 适用用户;结构类型:{strategy: None | All | Specify,ids:long[]}
|
||||||
|
*/
|
||||||
|
private String userScope;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 适用站点;结构类型:{strategy: None | All | Specify,ids:long[]}
|
||||||
|
*/
|
||||||
|
private String stationScope;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 适用产品;结构类型:{strategy: None | All | Specify,ids:long[]}
|
||||||
|
*/
|
||||||
|
private String goodsScope;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否可用;0-->否、1-->是
|
||||||
|
*/
|
||||||
|
private Boolean canuse;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
private String memo;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,40 @@
|
||||||
|
package com.njzscloud.dispose.finance.expenseItem.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.expenseItem.pojo.entity.ExpenseItemEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 收费项目
|
||||||
|
*/
|
||||||
|
public interface ExpenseItemService extends IService<ExpenseItemEntity> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
void add(ExpenseItemEntity expenseItemEntity);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
void modify(ExpenseItemEntity expenseItemEntity);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
ExpenseItemEntity detail(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
PageResult<ExpenseItemEntity> paging(PageParam pageParam, ExpenseItemEntity expenseItemEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,67 @@
|
||||||
|
package com.njzscloud.dispose.finance.expenseItem.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.expenseItem.mapper.ExpenseItemMapper;
|
||||||
|
import com.njzscloud.dispose.finance.expenseItem.pojo.entity.ExpenseItemEntity;
|
||||||
|
import com.njzscloud.dispose.finance.expenseItem.service.ExpenseItemService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 收费项目
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class ExpenseItemServiceImpl extends ServiceImpl<ExpenseItemMapper, ExpenseItemEntity> implements ExpenseItemService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void add(ExpenseItemEntity expenseItemEntity) {
|
||||||
|
this.save(expenseItemEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void modify(ExpenseItemEntity expenseItemEntity) {
|
||||||
|
this.updateById(expenseItemEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public ExpenseItemEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public PageResult<ExpenseItemEntity> paging(PageParam pageParam, ExpenseItemEntity expenseItemEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<ExpenseItemEntity>query(expenseItemEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyAccount.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.moneyAccount.pojo.entity.MoneyAccountEntity;
|
||||||
|
import com.njzscloud.dispose.finance.moneyAccount.service.MoneyAccountService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金账户表
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/money_account")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class MoneyAccountController {
|
||||||
|
|
||||||
|
private final MoneyAccountService moneyAccountService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody MoneyAccountEntity moneyAccountEntity) {
|
||||||
|
moneyAccountService.add(moneyAccountEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody MoneyAccountEntity moneyAccountEntity) {
|
||||||
|
moneyAccountService.modify(moneyAccountEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
moneyAccountService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<MoneyAccountEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(moneyAccountService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<MoneyAccountEntity>> paging(PageParam pageParam, MoneyAccountEntity moneyAccountEntity) {
|
||||||
|
return R.success(moneyAccountService.paging(pageParam, moneyAccountEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyAccount.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.finance.moneyAccount.pojo.entity.MoneyAccountEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金账户表
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface MoneyAccountMapper extends BaseMapper<MoneyAccountEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,58 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyAccount.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金账户表
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("fin_money_account")
|
||||||
|
public class MoneyAccountEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 账户编号
|
||||||
|
*/
|
||||||
|
private String sn;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 账户类型;account_type,GeRen-->个人、QiYe-->企业
|
||||||
|
*/
|
||||||
|
private String accountType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户 Id
|
||||||
|
*/
|
||||||
|
private Long userId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 客户 Id
|
||||||
|
*/
|
||||||
|
private Long customerId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 组织 Id
|
||||||
|
*/
|
||||||
|
private Long orgId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 营收余额
|
||||||
|
*/
|
||||||
|
private BigDecimal revenue;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 充值余额
|
||||||
|
*/
|
||||||
|
private BigDecimal recharge;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,40 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyAccount.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.moneyAccount.pojo.entity.MoneyAccountEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金账户表
|
||||||
|
*/
|
||||||
|
public interface MoneyAccountService extends IService<MoneyAccountEntity> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
void add(MoneyAccountEntity moneyAccountEntity);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
void modify(MoneyAccountEntity moneyAccountEntity);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
MoneyAccountEntity detail(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
PageResult<MoneyAccountEntity> paging(PageParam pageParam, MoneyAccountEntity moneyAccountEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,67 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyAccount.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.moneyAccount.mapper.MoneyAccountMapper;
|
||||||
|
import com.njzscloud.dispose.finance.moneyAccount.pojo.entity.MoneyAccountEntity;
|
||||||
|
import com.njzscloud.dispose.finance.moneyAccount.service.MoneyAccountService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金账户表
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class MoneyAccountServiceImpl extends ServiceImpl<MoneyAccountMapper, MoneyAccountEntity> implements MoneyAccountService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void add(MoneyAccountEntity moneyAccountEntity) {
|
||||||
|
this.save(moneyAccountEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void modify(MoneyAccountEntity moneyAccountEntity) {
|
||||||
|
this.updateById(moneyAccountEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public MoneyAccountEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public PageResult<MoneyAccountEntity> paging(PageParam pageParam, MoneyAccountEntity moneyAccountEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<MoneyAccountEntity>query(moneyAccountEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyFlow.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.moneyFlow.pojo.entity.MoneyFlowEntity;
|
||||||
|
import com.njzscloud.dispose.finance.moneyFlow.service.MoneyFlowService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金流水
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/money_flow")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class MoneyFlowController {
|
||||||
|
|
||||||
|
private final MoneyFlowService moneyFlowService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody MoneyFlowEntity moneyFlowEntity) {
|
||||||
|
moneyFlowService.add(moneyFlowEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody MoneyFlowEntity moneyFlowEntity) {
|
||||||
|
moneyFlowService.modify(moneyFlowEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
moneyFlowService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<MoneyFlowEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(moneyFlowService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<MoneyFlowEntity>> paging(PageParam pageParam, MoneyFlowEntity moneyFlowEntity) {
|
||||||
|
return R.success(moneyFlowService.paging(pageParam, moneyFlowEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyFlow.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.finance.moneyFlow.pojo.entity.MoneyFlowEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金流水
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface MoneyFlowMapper extends BaseMapper<MoneyFlowEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,68 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyFlow.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金流水
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("fin_money_flow")
|
||||||
|
public class MoneyFlowEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 订单 Id
|
||||||
|
*/
|
||||||
|
private Long orderId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 订单编号
|
||||||
|
*/
|
||||||
|
private String orderSn;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 车次
|
||||||
|
*/
|
||||||
|
private Integer trainNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金账户 Id;fin_money_account.id
|
||||||
|
*/
|
||||||
|
private Long moneyAccountId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 变动前余额
|
||||||
|
*/
|
||||||
|
private BigDecimal boforeBalance;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 变动金额;有正负
|
||||||
|
*/
|
||||||
|
private BigDecimal delta;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 变动后余额
|
||||||
|
*/
|
||||||
|
private BigDecimal afterBalance;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 变动类型;字典代码:money_change_category
|
||||||
|
*/
|
||||||
|
private String moneyChangeCategory;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
private String memo;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,40 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyFlow.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.moneyFlow.pojo.entity.MoneyFlowEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金流水
|
||||||
|
*/
|
||||||
|
public interface MoneyFlowService extends IService<MoneyFlowEntity> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
void add(MoneyFlowEntity moneyFlowEntity);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
void modify(MoneyFlowEntity moneyFlowEntity);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
MoneyFlowEntity detail(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
PageResult<MoneyFlowEntity> paging(PageParam pageParam, MoneyFlowEntity moneyFlowEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,67 @@
|
||||||
|
package com.njzscloud.dispose.finance.moneyFlow.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.finance.moneyFlow.mapper.MoneyFlowMapper;
|
||||||
|
import com.njzscloud.dispose.finance.moneyFlow.pojo.entity.MoneyFlowEntity;
|
||||||
|
import com.njzscloud.dispose.finance.moneyFlow.service.MoneyFlowService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资金流水
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class MoneyFlowServiceImpl extends ServiceImpl<MoneyFlowMapper, MoneyFlowEntity> implements MoneyFlowService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void add(MoneyFlowEntity moneyFlowEntity) {
|
||||||
|
this.save(moneyFlowEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public void modify(MoneyFlowEntity moneyFlowEntity) {
|
||||||
|
this.updateById(moneyFlowEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public MoneyFlowEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public PageResult<MoneyFlowEntity> paging(PageParam pageParam, MoneyFlowEntity moneyFlowEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<MoneyFlowEntity>query(moneyFlowEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.goods.goods.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.goods.goods.pojo.entity.GoodsEntity;
|
||||||
|
import com.njzscloud.dispose.goods.goods.service.GoodsService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/goods")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class GoodsController {
|
||||||
|
|
||||||
|
private final GoodsService goodsService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody GoodsEntity goodsEntity) {
|
||||||
|
goodsService.add(goodsEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody GoodsEntity goodsEntity) {
|
||||||
|
goodsService.modify(goodsEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
goodsService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<GoodsEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(goodsService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<GoodsEntity>> paging(PageParam pageParam, GoodsEntity goodsEntity) {
|
||||||
|
return R.success(goodsService.paging(pageParam, goodsEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
package com.njzscloud.dispose.goods.goods.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.goods.goods.pojo.entity.GoodsEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface GoodsMapper extends BaseMapper<GoodsEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,81 @@
|
||||||
|
package com.njzscloud.dispose.goods.goods.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("gds_goods")
|
||||||
|
public class GoodsEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品类型 Id
|
||||||
|
*/
|
||||||
|
private Long goodsCategoryId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 商品编码
|
||||||
|
*/
|
||||||
|
private String sn;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品名称
|
||||||
|
*/
|
||||||
|
private String goodsName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 规格
|
||||||
|
*/
|
||||||
|
private String specParams;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 图片
|
||||||
|
*/
|
||||||
|
private String picture;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 计量单位;字典代码:unit
|
||||||
|
*/
|
||||||
|
private String unit;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否为成品;0-->否、1-->是
|
||||||
|
*/
|
||||||
|
private Boolean fg;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否为半成品;0-->否、1-->是
|
||||||
|
*/
|
||||||
|
private Boolean sfg;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否为原料;0-->否、1-->是
|
||||||
|
*/
|
||||||
|
private Boolean rg;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 排序
|
||||||
|
*/
|
||||||
|
private Integer sort;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否可用;0-->否、1-->是
|
||||||
|
*/
|
||||||
|
private Boolean canuse;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
private String memo;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,26 @@
|
||||||
|
package com.njzscloud.dispose.goods.goods.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.goods.goods.pojo.entity.GoodsEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品
|
||||||
|
*/
|
||||||
|
public interface GoodsService extends IService<GoodsEntity> {
|
||||||
|
|
||||||
|
void add(GoodsEntity goodsEntity);
|
||||||
|
|
||||||
|
void modify(GoodsEntity goodsEntity);
|
||||||
|
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
GoodsEntity detail(Long id);
|
||||||
|
|
||||||
|
PageResult<GoodsEntity> paging(PageParam pageParam, GoodsEntity goodsEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
package com.njzscloud.dispose.goods.goods.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.goods.goods.mapper.GoodsMapper;
|
||||||
|
import com.njzscloud.dispose.goods.goods.pojo.entity.GoodsEntity;
|
||||||
|
import com.njzscloud.dispose.goods.goods.service.GoodsService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class GoodsServiceImpl extends ServiceImpl<GoodsMapper, GoodsEntity> implements GoodsService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void add(GoodsEntity goodsEntity) {
|
||||||
|
this.save(goodsEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void modify(GoodsEntity goodsEntity) {
|
||||||
|
this.updateById(goodsEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public GoodsEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<GoodsEntity> paging(PageParam pageParam, GoodsEntity goodsEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<GoodsEntity>query(goodsEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.njzscloud.dispose.goods.goodscategory.controller;
|
||||||
|
|
||||||
|
import com.njzscloud.common.core.utils.R;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.goods.goodscategory.pojo.entity.GoodsCategoryEntity;
|
||||||
|
import com.njzscloud.dispose.goods.goodscategory.service.GoodsCategoryService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品分类
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/goods_category")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class GoodsCategoryController {
|
||||||
|
|
||||||
|
private final GoodsCategoryService goodsCategoryService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增
|
||||||
|
*/
|
||||||
|
@PostMapping("/add")
|
||||||
|
public R<?> add(@RequestBody GoodsCategoryEntity goodsCategoryEntity) {
|
||||||
|
goodsCategoryService.add(goodsCategoryEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改
|
||||||
|
*/
|
||||||
|
@PostMapping("/modify")
|
||||||
|
public R<?> modify(@RequestBody GoodsCategoryEntity goodsCategoryEntity) {
|
||||||
|
goodsCategoryService.modify(goodsCategoryEntity);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除
|
||||||
|
*/
|
||||||
|
@PostMapping("/del")
|
||||||
|
public R<?> del(@RequestBody List<Long> ids) {
|
||||||
|
goodsCategoryService.del(ids);
|
||||||
|
return R.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 详情
|
||||||
|
*/
|
||||||
|
@GetMapping("/detail")
|
||||||
|
public R<GoodsCategoryEntity> detail(@RequestParam Long id) {
|
||||||
|
return R.success(goodsCategoryService.detail(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询
|
||||||
|
*/
|
||||||
|
@GetMapping("/paging")
|
||||||
|
public R<PageResult<GoodsCategoryEntity>> paging(PageParam pageParam, GoodsCategoryEntity goodsCategoryEntity) {
|
||||||
|
return R.success(goodsCategoryService.paging(pageParam, goodsCategoryEntity));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
package com.njzscloud.dispose.goods.goodscategory.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njzscloud.dispose.goods.goodscategory.pojo.entity.GoodsCategoryEntity;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品分类
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface GoodsCategoryMapper extends BaseMapper<GoodsCategoryEntity> {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,41 @@
|
||||||
|
package com.njzscloud.dispose.goods.goodscategory.pojo.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njzscloud.dispose.common.pojo.entity.BaseEntity;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品分类
|
||||||
|
*/
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@ToString
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("gds_goods_category")
|
||||||
|
public class GoodsCategoryEntity extends BaseEntity {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 业务类型;字典代码:biz_type
|
||||||
|
*/
|
||||||
|
private String bizType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分类名称
|
||||||
|
*/
|
||||||
|
private String categoryName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 图片
|
||||||
|
*/
|
||||||
|
private String picture;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 排序
|
||||||
|
*/
|
||||||
|
private Integer sort;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,26 @@
|
||||||
|
package com.njzscloud.dispose.goods.goodscategory.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.goods.goodscategory.pojo.entity.GoodsCategoryEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品分类
|
||||||
|
*/
|
||||||
|
public interface GoodsCategoryService extends IService<GoodsCategoryEntity> {
|
||||||
|
|
||||||
|
void add(GoodsCategoryEntity goodsCategoryEntity);
|
||||||
|
|
||||||
|
void modify(GoodsCategoryEntity goodsCategoryEntity);
|
||||||
|
|
||||||
|
void del(List<Long> ids);
|
||||||
|
|
||||||
|
GoodsCategoryEntity detail(Long id);
|
||||||
|
|
||||||
|
PageResult<GoodsCategoryEntity> paging(PageParam pageParam, GoodsCategoryEntity goodsCategoryEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
package com.njzscloud.dispose.goods.goodscategory.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njzscloud.common.mp.support.PageParam;
|
||||||
|
import com.njzscloud.common.mp.support.PageResult;
|
||||||
|
import com.njzscloud.dispose.goods.goodscategory.mapper.GoodsCategoryMapper;
|
||||||
|
import com.njzscloud.dispose.goods.goodscategory.pojo.entity.GoodsCategoryEntity;
|
||||||
|
import com.njzscloud.dispose.goods.goodscategory.service.GoodsCategoryService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 产品分类
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class GoodsCategoryServiceImpl extends ServiceImpl<GoodsCategoryMapper, GoodsCategoryEntity> implements GoodsCategoryService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void add(GoodsCategoryEntity goodsCategoryEntity) {
|
||||||
|
this.save(goodsCategoryEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void modify(GoodsCategoryEntity goodsCategoryEntity) {
|
||||||
|
this.updateById(goodsCategoryEntity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void del(List<Long> ids) {
|
||||||
|
this.removeBatchByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public GoodsCategoryEntity detail(Long id) {
|
||||||
|
return this.getById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<GoodsCategoryEntity> paging(PageParam pageParam, GoodsCategoryEntity goodsCategoryEntity) {
|
||||||
|
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<GoodsCategoryEntity>query(goodsCategoryEntity)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,102 @@
|
||||||
|
<?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.njzscloud.dispose.cst.driver.mapper.DriverMapper">
|
||||||
|
|
||||||
|
<resultMap id="DriverResultMap" type="com.njzscloud.dispose.cst.driver.pojo.entity.DriverEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="user_id" property="userId"/>
|
||||||
|
<result column="customer_id" property="customerId"/>
|
||||||
|
<result column="org_id" property="orgId"/>
|
||||||
|
<result column="driving_licence_no" property="drivingLicenceNo"/>
|
||||||
|
<result column="driver_name" property="driverName"/>
|
||||||
|
<result column="phone" property="phone"/>
|
||||||
|
<result column="driving_licence" property="drivingLicence"/>
|
||||||
|
<result column="licence_start_time" property="licenceStartTime"/>
|
||||||
|
<result column="licence_end_time" property="licenceEndTime"/>
|
||||||
|
<result column="busy" property="busy"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, user_id, customer_id, org_id, driving_licence_no, driver_name, phone,
|
||||||
|
driving_licence, licence_start_time, licence_end_time, busy,
|
||||||
|
creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="DriverResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_driver
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="DriverResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_driver
|
||||||
|
<where>
|
||||||
|
<if test="userId != null">AND user_id = #{userId}</if>
|
||||||
|
<if test="customerId != null">AND customer_id = #{customerId}</if>
|
||||||
|
<if test="orgId != null">AND org_id = #{orgId}</if>
|
||||||
|
<if test="driverName != null and driverName != ''">AND driver_name = #{driverName}</if>
|
||||||
|
<if test="phone != null and phone != ''">AND phone = #{phone}</if>
|
||||||
|
<if test="busy != null">AND busy = #{busy}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
<?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.njzscloud.dispose.cst.driver.mapper.DriverMapper">
|
||||||
|
|
||||||
|
<resultMap id="DriverResultMap" type="com.njzscloud.dispose.cst.driver.pojo.entity.DriverEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="user_id" property="userId"/>
|
||||||
|
<result column="customer_id" property="customerId"/>
|
||||||
|
<result column="org_id" property="orgId"/>
|
||||||
|
<result column="driving_licence_no" property="drivingLicenceNo"/>
|
||||||
|
<result column="driver_name" property="driverName"/>
|
||||||
|
<result column="phone" property="phone"/>
|
||||||
|
<result column="driving_licence" property="drivingLicence"/>
|
||||||
|
<result column="licence_start_time" property="licenceStartTime"/>
|
||||||
|
<result column="licence_end_time" property="licenceEndTime"/>
|
||||||
|
<result column="busy" property="busy"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, user_id, customer_id, org_id, driving_licence_no, driver_name, phone, driving_licence,
|
||||||
|
licence_start_time, licence_end_time, busy, creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="DriverResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_driver
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="DriverResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_driver
|
||||||
|
<where>
|
||||||
|
<if test="userId != null">AND user_id = #{userId}</if>
|
||||||
|
<if test="customerId != null">AND customer_id = #{customerId}</if>
|
||||||
|
<if test="orgId != null">AND org_id = #{orgId}</if>
|
||||||
|
<if test="driverName != null and driverName != ''">AND driver_name = #{driverName}</if>
|
||||||
|
<if test="phone != null and phone != ''">AND phone = #{phone}</if>
|
||||||
|
<if test="busy != null">AND busy = #{busy}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,124 @@
|
||||||
|
<?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.njzscloud.dispose.cst.project.mapper.ProjectMapper">
|
||||||
|
|
||||||
|
<resultMap id="ProjectResultMap" type="com.njzscloud.dispose.cst.project.pojo.entity.ProjectEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="project_name" property="projectName"/>
|
||||||
|
<result column="contract_picture" property="contractPicture"/>
|
||||||
|
<result column="trans_customer_id" property="transCustomerId"/>
|
||||||
|
<result column="trans_org_id" property="transOrgId"/>
|
||||||
|
<result column="fringe_customer_id" property="fringeCustomerId"/>
|
||||||
|
<result column="fringe_org_id" property="fringeOrgId"/>
|
||||||
|
<result column="province" property="province"/>
|
||||||
|
<result column="city" property="city"/>
|
||||||
|
<result column="area" property="area"/>
|
||||||
|
<result column="town" property="town"/>
|
||||||
|
<result column="province_name" property="provinceName"/>
|
||||||
|
<result column="city_name" property="cityName"/>
|
||||||
|
<result column="area_name" property="areaName"/>
|
||||||
|
<result column="town_name" property="townName"/>
|
||||||
|
<result column="address" property="address"/>
|
||||||
|
<result column="lng" property="lng"/>
|
||||||
|
<result column="lat" property="lat"/>
|
||||||
|
<result column="contract_start_date" property="contractStartDate"/>
|
||||||
|
<result column="contract_end_date" property="contractEndDate"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, project_name, contract_picture, trans_customer_id, trans_org_id,
|
||||||
|
fringe_customer_id, fringe_org_id, province, city, area, town,
|
||||||
|
province_name, city_name, area_name, town_name, address, lng, lat,
|
||||||
|
contract_start_date, contract_end_date, creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="ProjectResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_project
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="ProjectResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_project
|
||||||
|
<where>
|
||||||
|
<if test="projectName != null and projectName != ''">AND project_name = #{projectName}</if>
|
||||||
|
<if test="transCustomerId != null">AND trans_customer_id = #{transCustomerId}</if>
|
||||||
|
<if test="fringeCustomerId != null">AND fringe_customer_id = #{fringeCustomerId}</if>
|
||||||
|
<if test="province != null and province != ''">AND province = #{province}</if>
|
||||||
|
<if test="city != null and city != ''">AND city = #{city}</if>
|
||||||
|
<if test="area != null and area != ''">AND area = #{area}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
<?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.njzscloud.dispose.cst.project.mapper.ProjectMapper">
|
||||||
|
|
||||||
|
<resultMap id="ProjectResultMap" type="com.njzscloud.dispose.cst.project.pojo.entity.ProjectEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="project_name" property="projectName"/>
|
||||||
|
<result column="contract_picture" property="contractPicture"/>
|
||||||
|
<result column="trans_customer_id" property="transCustomerId"/>
|
||||||
|
<result column="trans_org_id" property="transOrgId"/>
|
||||||
|
<result column="fringe_customer_id" property="fringeCustomerId"/>
|
||||||
|
<result column="fringe_org_id" property="fringeOrgId"/>
|
||||||
|
<result column="province" property="province"/>
|
||||||
|
<result column="city" property="city"/>
|
||||||
|
<result column="area" property="area"/>
|
||||||
|
<result column="town" property="town"/>
|
||||||
|
<result column="province_name" property="provinceName"/>
|
||||||
|
<result column="city_name" property="cityName"/>
|
||||||
|
<result column="area_name" property="areaName"/>
|
||||||
|
<result column="town_name" property="townName"/>
|
||||||
|
<result column="address" property="address"/>
|
||||||
|
<result column="lng" property="lng"/>
|
||||||
|
<result column="lat" property="lat"/>
|
||||||
|
<result column="contract_start_date" property="contractStartDate"/>
|
||||||
|
<result column="contract_end_date" property="contractEndDate"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, project_name, contract_picture, trans_customer_id, trans_org_id, fringe_customer_id, fringe_org_id,
|
||||||
|
province, city, area, town, province_name, city_name, area_name, town_name, address, lng, lat,
|
||||||
|
contract_start_date, contract_end_date, creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="ProjectResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_project
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="ProjectResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_project
|
||||||
|
<where>
|
||||||
|
<if test="projectName != null and projectName != ''">AND project_name = #{projectName}</if>
|
||||||
|
<if test="transCustomerId != null">AND trans_customer_id = #{transCustomerId}</if>
|
||||||
|
<if test="transOrgId != null">AND trans_org_id = #{transOrgId}</if>
|
||||||
|
<if test="fringeCustomerId != null">AND fringe_customer_id = #{fringeCustomerId}</if>
|
||||||
|
<if test="fringeOrgId != null">AND fringe_org_id = #{fringeOrgId}</if>
|
||||||
|
<if test="province != null and province != ''">AND province = #{province}</if>
|
||||||
|
<if test="city != null and city != ''">AND city = #{city}</if>
|
||||||
|
<if test="area != null and area != ''">AND area = #{area}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,106 @@
|
||||||
|
<?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.njzscloud.dispose.cst.station.mapper.StationMapper">
|
||||||
|
|
||||||
|
<resultMap id="StationResultMap" type="com.njzscloud.dispose.cst.station.pojo.entity.StationEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="org_id" property="orgId"/>
|
||||||
|
<result column="station_name" property="stationName"/>
|
||||||
|
<result column="province" property="province"/>
|
||||||
|
<result column="city" property="city"/>
|
||||||
|
<result column="area" property="area"/>
|
||||||
|
<result column="town" property="town"/>
|
||||||
|
<result column="province_name" property="provinceName"/>
|
||||||
|
<result column="city_name" property="cityName"/>
|
||||||
|
<result column="area_name" property="areaName"/>
|
||||||
|
<result column="town_name" property="townName"/>
|
||||||
|
<result column="address" property="address"/>
|
||||||
|
<result column="lng" property="lng"/>
|
||||||
|
<result column="lat" property="lat"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, org_id, station_name, province, city, area, town,
|
||||||
|
province_name, city_name, area_name, town_name, address, lng, lat,
|
||||||
|
creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="StationResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_station
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="StationResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_station
|
||||||
|
<where>
|
||||||
|
<if test="orgId != null">AND org_id = #{orgId}</if>
|
||||||
|
<if test="stationName != null and stationName != ''">AND station_name = #{stationName}</if>
|
||||||
|
<if test="province != null and province != ''">AND province = #{province}</if>
|
||||||
|
<if test="city != null and city != ''">AND city = #{city}</if>
|
||||||
|
<if test="area != null and area != ''">AND area = #{area}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
<?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.njzscloud.dispose.cst.station.mapper.StationMapper">
|
||||||
|
|
||||||
|
<resultMap id="StationResultMap" type="com.njzscloud.dispose.cst.station.pojo.entity.StationEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="org_id" property="orgId"/>
|
||||||
|
<result column="station_name" property="stationName"/>
|
||||||
|
<result column="province" property="province"/>
|
||||||
|
<result column="city" property="city"/>
|
||||||
|
<result column="area" property="area"/>
|
||||||
|
<result column="town" property="town"/>
|
||||||
|
<result column="province_name" property="provinceName"/>
|
||||||
|
<result column="city_name" property="cityName"/>
|
||||||
|
<result column="area_name" property="areaName"/>
|
||||||
|
<result column="town_name" property="townName"/>
|
||||||
|
<result column="address" property="address"/>
|
||||||
|
<result column="lng" property="lng"/>
|
||||||
|
<result column="lat" property="lat"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, org_id, station_name, province, city, area, town, province_name, city_name, area_name, town_name,
|
||||||
|
address, lng, lat, creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="StationResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_station
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="StationResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_station
|
||||||
|
<where>
|
||||||
|
<if test="orgId != null">AND org_id = #{orgId}</if>
|
||||||
|
<if test="stationName != null and stationName != ''">AND station_name = #{stationName}</if>
|
||||||
|
<if test="province != null and province != ''">AND province = #{province}</if>
|
||||||
|
<if test="city != null and city != ''">AND city = #{city}</if>
|
||||||
|
<if test="area != null and area != ''">AND area = #{area}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,57 @@
|
||||||
|
<?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.njzscloud.dispose.cst.truck.mapper.TruckMapper">
|
||||||
|
|
||||||
|
<resultMap id="TruckResultMap" type="com.njzscloud.dispose.cst.truck.pojo.entity.TruckEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="customer_id" property="customerId"/>
|
||||||
|
<result column="org_id" property="orgId"/>
|
||||||
|
<result column="license_plate" property="licensePlate"/>
|
||||||
|
<result column="truck_license" property="truckLicense"/>
|
||||||
|
<result column="vn_code" property="vnCode"/>
|
||||||
|
<result column="qualification" property="qualification"/>
|
||||||
|
<result column="carrying_capacity" property="carryingCapacity"/>
|
||||||
|
<result column="tare_weight" property="tareWeight"/>
|
||||||
|
<result column="license_start_date" property="licenseStartDate"/>
|
||||||
|
<result column="license_end_date" property="licenseEndDate"/>
|
||||||
|
<result column="qualification_start_date" property="qualificationStartDate"/>
|
||||||
|
<result column="qualification_end_date" property="qualificationEndDate"/>
|
||||||
|
<result column="truck_category" property="truckCategory"/>
|
||||||
|
<result column="picture" property="picture"/>
|
||||||
|
<result column="busy" property="busy"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, customer_id, org_id, license_plate, truck_license, vn_code, qualification,
|
||||||
|
carrying_capacity, tare_weight, license_start_date, license_end_date,
|
||||||
|
qualification_start_date, qualification_end_date, truck_category, picture, busy,
|
||||||
|
creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="TruckResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_truck
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="TruckResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM cst_truck
|
||||||
|
<where>
|
||||||
|
<if test="customerId != null">AND customer_id = #{customerId}</if>
|
||||||
|
<if test="orgId != null">AND org_id = #{orgId}</if>
|
||||||
|
<if test="licensePlate != null and licensePlate != ''">AND license_plate = #{licensePlate}</if>
|
||||||
|
<if test="truckCategory != null and truckCategory != ''">AND truck_category = #{truckCategory}</if>
|
||||||
|
<if test="busy != null">AND busy = #{busy}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,54 @@
|
||||||
|
<?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.njzscloud.dispose.finance.bill.mapper.BillMapper">
|
||||||
|
|
||||||
|
<resultMap id="BillResultMap" type="com.njzscloud.dispose.finance.bill.pojo.entity.BillEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="user_id" property="userId"/>
|
||||||
|
<result column="customer_id" property="customerId"/>
|
||||||
|
<result column="org_id" property="orgId"/>
|
||||||
|
<result column="account_type" property="accountType"/>
|
||||||
|
<result column="bill_period" property="billPeriod"/>
|
||||||
|
<result column="start_time" property="startTime"/>
|
||||||
|
<result column="end_time" property="endTime"/>
|
||||||
|
<result column="order_count" property="orderCount"/>
|
||||||
|
<result column="car_count" property="carCount"/>
|
||||||
|
<result column="total_weight" property="totalWeight"/>
|
||||||
|
<result column="discount_money" property="discountMoney"/>
|
||||||
|
<result column="total_money" property="totalMoney"/>
|
||||||
|
<result column="memo" property="memo"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, user_id, customer_id, org_id, account_type, bill_period, start_time, end_time,
|
||||||
|
order_count, car_count, total_weight, discount_money, total_money, memo,
|
||||||
|
creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="BillResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM fin_bill
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="BillResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM fin_bill
|
||||||
|
<where>
|
||||||
|
<if test="userId != null">AND user_id = #{userId}</if>
|
||||||
|
<if test="customerId != null">AND customer_id = #{customerId}</if>
|
||||||
|
<if test="orgId != null">AND org_id = #{orgId}</if>
|
||||||
|
<if test="accountType != null and accountType != ''">AND account_type = #{accountType}</if>
|
||||||
|
<if test="billPeriod != null">AND bill_period = #{billPeriod}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,56 @@
|
||||||
|
<?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.njzscloud.dispose.finance.expenseItem.mapper.ExpenseItemMapper">
|
||||||
|
|
||||||
|
<resultMap id="ExpenseItemResultMap" type="com.njzscloud.dispose.finance.expenseItem.pojo.entity.ExpenseItemEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="expense_item_category" property="expenseItemCategory"/>
|
||||||
|
<result column="expense_item_name" property="expenseItemName"/>
|
||||||
|
<result column="expense_strategy" property="expenseStrategy"/>
|
||||||
|
<result column="unit" property="unit"/>
|
||||||
|
<result column="tax_rate" property="taxRate"/>
|
||||||
|
<result column="payer" property="payer"/>
|
||||||
|
<result column="unit_price" property="unitPrice"/>
|
||||||
|
<result column="initial_price" property="initialPrice"/>
|
||||||
|
<result column="initial_quantity" property="initialQuantity"/>
|
||||||
|
<result column="every_quantity" property="everyQuantity"/>
|
||||||
|
<result column="user_scope" property="userScope"/>
|
||||||
|
<result column="station_scope" property="stationScope"/>
|
||||||
|
<result column="goods_scope" property="goodsScope"/>
|
||||||
|
<result column="canuse" property="canuse"/>
|
||||||
|
<result column="memo" property="memo"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, expense_item_category, expense_item_name, expense_strategy, unit, tax_rate, payer,
|
||||||
|
unit_price, initial_price, initial_quantity, every_quantity, user_scope, station_scope,
|
||||||
|
goods_scope, canuse, memo, creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="ExpenseItemResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM fin_expense_item
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="ExpenseItemResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM fin_expense_item
|
||||||
|
<where>
|
||||||
|
<if test="expenseItemCategory != null and expenseItemCategory != ''">AND expense_item_category = #{expenseItemCategory}</if>
|
||||||
|
<if test="expenseItemName != null and expenseItemName != ''">AND expense_item_name = #{expenseItemName}</if>
|
||||||
|
<if test="expenseStrategy != null and expenseStrategy != ''">AND expense_strategy = #{expenseStrategy}</if>
|
||||||
|
<if test="payer != null and payer != ''">AND payer = #{payer}</if>
|
||||||
|
<if test="canuse != null">AND canuse = #{canuse}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,47 @@
|
||||||
|
<?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.njzscloud.dispose.finance.moneyAccount.mapper.MoneyAccountMapper">
|
||||||
|
|
||||||
|
<resultMap id="MoneyAccountResultMap" type="com.njzscloud.dispose.finance.moneyAccount.pojo.entity.MoneyAccountEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="sn" property="sn"/>
|
||||||
|
<result column="account_type" property="accountType"/>
|
||||||
|
<result column="user_id" property="userId"/>
|
||||||
|
<result column="customer_id" property="customerId"/>
|
||||||
|
<result column="org_id" property="orgId"/>
|
||||||
|
<result column="revenue" property="revenue"/>
|
||||||
|
<result column="recharge" property="recharge"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, sn, account_type, user_id, customer_id, org_id, revenue, recharge,
|
||||||
|
creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="MoneyAccountResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM fin_money_account
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="MoneyAccountResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM fin_money_account
|
||||||
|
<where>
|
||||||
|
<if test="sn != null and sn != ''">AND sn = #{sn}</if>
|
||||||
|
<if test="accountType != null and accountType != ''">AND account_type = #{accountType}</if>
|
||||||
|
<if test="userId != null">AND user_id = #{userId}</if>
|
||||||
|
<if test="customerId != null">AND customer_id = #{customerId}</if>
|
||||||
|
<if test="orgId != null">AND org_id = #{orgId}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,48 @@
|
||||||
|
<?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.njzscloud.dispose.finance.moneyFlow.mapper.MoneyFlowMapper">
|
||||||
|
|
||||||
|
<resultMap id="MoneyFlowResultMap" type="com.njzscloud.dispose.finance.moneyFlow.pojo.entity.MoneyFlowEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="order_id" property="orderId"/>
|
||||||
|
<result column="order_sn" property="orderSn"/>
|
||||||
|
<result column="train_num" property="trainNum"/>
|
||||||
|
<result column="money_account_id" property="moneyAccountId"/>
|
||||||
|
<result column="bofore_balance" property="boforeBalance"/>
|
||||||
|
<result column="delta" property="delta"/>
|
||||||
|
<result column="after_balance" property="afterBalance"/>
|
||||||
|
<result column="money_change_category" property="moneyChangeCategory"/>
|
||||||
|
<result column="memo" property="memo"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, order_id, order_sn, train_num, money_account_id, bofore_balance, delta, after_balance,
|
||||||
|
money_change_category, memo, creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="MoneyFlowResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM fin_money_flow
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="MoneyFlowResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM fin_money_flow
|
||||||
|
<where>
|
||||||
|
<if test="orderId != null">AND order_id = #{orderId}</if>
|
||||||
|
<if test="orderSn != null and orderSn != ''">AND order_sn = #{orderSn}</if>
|
||||||
|
<if test="moneyAccountId != null">AND money_account_id = #{moneyAccountId}</if>
|
||||||
|
<if test="moneyChangeCategory != null and moneyChangeCategory != ''">AND money_change_category = #{moneyChangeCategory}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,55 @@
|
||||||
|
<?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.njzscloud.dispose.goods.goods.mapper.GoodsMapper">
|
||||||
|
|
||||||
|
<resultMap id="GoodsResultMap" type="com.njzscloud.dispose.goods.goods.pojo.entity.GoodsEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="goods_category_id" property="goodsCategoryId"/>
|
||||||
|
<result column="sn" property="sn"/>
|
||||||
|
<result column="goods_name" property="goodsName"/>
|
||||||
|
<result column="spec_params" property="specParams"/>
|
||||||
|
<result column="picture" property="picture"/>
|
||||||
|
<result column="unit" property="unit"/>
|
||||||
|
<result column="fg" property="fg"/>
|
||||||
|
<result column="sfg" property="sfg"/>
|
||||||
|
<result column="rg" property="rg"/>
|
||||||
|
<result column="sort" property="sort"/>
|
||||||
|
<result column="canuse" property="canuse"/>
|
||||||
|
<result column="memo" property="memo"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, goods_category_id, sn, goods_name, spec_params, picture, unit,
|
||||||
|
fg, sfg, rg, sort, canuse, memo, creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="GoodsResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM gds_goods
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="GoodsResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM gds_goods
|
||||||
|
<where>
|
||||||
|
<if test="goodsCategoryId != null">AND goods_category_id = #{goodsCategoryId}</if>
|
||||||
|
<if test="sn != null and sn != ''">AND sn = #{sn}</if>
|
||||||
|
<if test="goodsName != null and goodsName != ''">AND goods_name = #{goodsName}</if>
|
||||||
|
<if test="unit != null and unit != ''">AND unit = #{unit}</if>
|
||||||
|
<if test="fg != null">AND fg = #{fg}</if>
|
||||||
|
<if test="sfg != null">AND sfg = #{sfg}</if>
|
||||||
|
<if test="rg != null">AND rg = #{rg}</if>
|
||||||
|
<if test="canuse != null">AND canuse = #{canuse}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY sort ASC, create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,40 @@
|
||||||
|
<?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.njzscloud.dispose.goods.goodscategory.mapper.GoodsCategoryMapper">
|
||||||
|
|
||||||
|
<resultMap id="GoodsCategoryResultMap" type="com.njzscloud.dispose.goods.goodscategory.pojo.entity.GoodsCategoryEntity">
|
||||||
|
<id column="id" property="id"/>
|
||||||
|
<result column="biz_type" property="bizType"/>
|
||||||
|
<result column="category_name" property="categoryName"/>
|
||||||
|
<result column="picture" property="picture"/>
|
||||||
|
<result column="sort" property="sort"/>
|
||||||
|
<result column="creator_id" property="creatorId"/>
|
||||||
|
<result column="modifier_id" property="modifierId"/>
|
||||||
|
<result column="create_time" property="createTime"/>
|
||||||
|
<result column="modify_time" property="modifyTime"/>
|
||||||
|
<result column="deleted" property="deleted"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, biz_type, category_name, picture, sort, creator_id, modifier_id, create_time, modify_time, deleted
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectById" resultMap="GoodsCategoryResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM gds_goods_category
|
||||||
|
WHERE id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectList" resultMap="GoodsCategoryResultMap">
|
||||||
|
SELECT <include refid="Base_Column_List"/>
|
||||||
|
FROM gds_goods_category
|
||||||
|
<where>
|
||||||
|
<if test="bizType != null and bizType != ''">AND biz_type = #{bizType}</if>
|
||||||
|
<if test="categoryName != null and categoryName != ''">AND category_name = #{categoryName}</if>
|
||||||
|
<if test="deleted != null">AND deleted = #{deleted}</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY sort ASC, create_time DESC
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
||||||
|
|
||||||
Loading…
Reference in New Issue