Compare commits
30 Commits
ylc
...
959b1a0b77
| Author | SHA1 | Date | |
|---|---|---|---|
| 959b1a0b77 | |||
| ba88da6982 | |||
| 314380cd74 | |||
| 1b01150a7e | |||
| e9e0c47536 | |||
|
|
0750c9583e | ||
|
|
e9c8f7857b | ||
|
|
227a27295d | ||
|
|
2d1ef3d743 | ||
| 46b6e5e66e | |||
| bac1ec5b70 | |||
|
|
8a3a037bda | ||
|
|
e7a542d386 | ||
|
|
fde6a8b684 | ||
|
|
d26600892f | ||
|
|
1477d05a69 | ||
|
|
f498afd856 | ||
| 4cfd541f06 | |||
| 297d5f04ea | |||
| f44f701dad | |||
| c3460f6dc4 | |||
|
|
23b5ce90c9 | ||
|
|
2b34011129 | ||
| 3a77498965 | |||
| 3bd383a347 | |||
| 718ad8a8c2 | |||
|
|
13020d05c9 | ||
|
|
970359823b | ||
|
|
facfe5c7a2 | ||
|
|
d3500d195b |
24
pom.xml
24
pom.xml
@@ -15,6 +15,8 @@
|
||||
<module>ym-baisc</module>
|
||||
<module>ym-schedule-task</module>
|
||||
<module>ym-influx</module>
|
||||
<module>ym-quality-planning</module>
|
||||
<module>ym-process-inspection</module>
|
||||
</modules>
|
||||
<packaging>pom</packaging>
|
||||
|
||||
@@ -92,17 +94,17 @@
|
||||
</dependency>
|
||||
|
||||
<!-- influx start-->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-actuator-autoconfigure</artifactId>
|
||||
<optional>true</optional>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>com.fasterxml.jackson.core</groupId>
|
||||
<artifactId>jackson-databind</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<!-- <dependency>-->
|
||||
<!-- <groupId>org.springframework.boot</groupId>-->
|
||||
<!-- <artifactId>spring-boot-actuator-autoconfigure</artifactId>-->
|
||||
<!-- <optional>true</optional>-->
|
||||
<!-- <exclusions>-->
|
||||
<!-- <exclusion>-->
|
||||
<!-- <groupId>com.fasterxml.jackson.core</groupId>-->
|
||||
<!-- <artifactId>jackson-databind</artifactId>-->
|
||||
<!-- </exclusion>-->
|
||||
<!-- </exclusions>-->
|
||||
<!-- </dependency>-->
|
||||
|
||||
<!-- influx end-->
|
||||
|
||||
|
||||
18
ym-admin/src/main/java/com/cnbm/admin/basic/BaseParam.java
Normal file
18
ym-admin/src/main/java/com/cnbm/admin/basic/BaseParam.java
Normal file
@@ -0,0 +1,18 @@
|
||||
/*
|
||||
* Copyright (c) 2018.
|
||||
* http://www.ulabcare.com
|
||||
*/
|
||||
|
||||
package com.cnbm.admin.basic;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 接口请求参数基类
|
||||
*
|
||||
* @author jiff
|
||||
* @date 2018/11/1
|
||||
* @since 1.0
|
||||
*/
|
||||
public class BaseParam implements Serializable {
|
||||
}
|
||||
@@ -73,6 +73,8 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
|
||||
"/webjars/**",
|
||||
"/websocket/**",
|
||||
"/influx/**",
|
||||
"/basic/**",
|
||||
"/processInspection/**",
|
||||
"/captcha").anonymous()
|
||||
// .antMatchers("/testCors").hasAuthority("system:dept:list222")
|
||||
// 除上面外的所有请求全部需要鉴权认证
|
||||
|
||||
36
ym-admin/src/main/java/com/cnbm/admin/params/IdParam.java
Normal file
36
ym-admin/src/main/java/com/cnbm/admin/params/IdParam.java
Normal file
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
* Copyright (c) 2018.
|
||||
* http://www.ulabcare.com
|
||||
*/
|
||||
|
||||
package com.cnbm.admin.params;
|
||||
|
||||
|
||||
import com.cnbm.admin.basic.BaseParam;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.io.Serializable;
|
||||
|
||||
|
||||
/**
|
||||
* 主键请求参数对象
|
||||
*
|
||||
* @author jiff
|
||||
* @date 2018/11/9
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel("主键参数对象")
|
||||
public class IdParam implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@NotNull(message = "主键不能为空")
|
||||
@ApiModelProperty(value = "主键", required = true, example = "1", notes = "根据实际接口传递不同对象的主键")
|
||||
private Long id;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,130 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.admin.params.IdParam;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.FactoryDTO;
|
||||
import com.cnbm.basic.excel.FactoryExcel;
|
||||
import com.cnbm.basic.service.IFactoryService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 工厂 表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/factory")
|
||||
@Api(tags="工厂 表")
|
||||
public class FactoryController {
|
||||
@Autowired
|
||||
private IFactoryService factoryService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "name", value = "名称", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "code", value = "编码", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "type", value = "工厂类型", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:factory:page')")
|
||||
public Result<PageData<FactoryDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<FactoryDTO> page = factoryService.page(params);
|
||||
|
||||
return new Result<PageData<FactoryDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:factory:info')")
|
||||
public Result<FactoryDTO> get(@PathVariable("id") Long id){
|
||||
FactoryDTO data = factoryService.get(id);
|
||||
|
||||
return new Result<FactoryDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:factory:save')")
|
||||
public Result save(@RequestBody FactoryDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
factoryService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:factory:update')")
|
||||
public Result update(@RequestBody FactoryDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
factoryService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:factory:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
factoryService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:factory:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<FactoryDTO> list = factoryService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, FactoryExcel.class);
|
||||
}
|
||||
|
||||
@PostMapping("status")
|
||||
@ApiOperation("改变状态")
|
||||
//@LogOperation("改变状态")
|
||||
public Result changeStatus(@RequestBody IdParam id){
|
||||
factoryService.changeStatus(id.getId());
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,144 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.admin.params.IdParam;
|
||||
import com.cnbm.basic.vo.MachineVo;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.MachineDTO;
|
||||
import com.cnbm.basic.excel.MachineExcel;
|
||||
import com.cnbm.basic.service.IMachineService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 机台表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/machine")
|
||||
@Api(tags="机台表")
|
||||
public class MachineController {
|
||||
@Autowired
|
||||
private IMachineService machineService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:machine:page')")
|
||||
public Result<PageData<MachineDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<MachineDTO> page = machineService.page(params);
|
||||
|
||||
return new Result<PageData<MachineDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("page2")
|
||||
@ApiOperation("分页2")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:machine:page')")
|
||||
public Result<PageData<MachineVo>> page2(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<MachineVo> page = machineService.page1(params);
|
||||
|
||||
return new Result<PageData<MachineVo>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:machine:info')")
|
||||
public Result<MachineDTO> get(@PathVariable("id") Long id){
|
||||
MachineDTO data = machineService.get(id);
|
||||
|
||||
return new Result<MachineDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:machine:save')")
|
||||
public Result save(@RequestBody MachineDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
machineService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:machine:update')")
|
||||
public Result update(@RequestBody MachineDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
machineService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:machine:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
machineService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:machine:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<MachineDTO> list = machineService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, MachineExcel.class);
|
||||
}
|
||||
|
||||
@PostMapping("status")
|
||||
@ApiOperation("改变状态")
|
||||
//@LogOperation("改变状态")
|
||||
public Result changeStatus(@RequestBody IdParam id){
|
||||
machineService.changeStatus(id.getId());
|
||||
|
||||
return new Result().ok(true);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,128 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.admin.params.IdParam;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.MeasureToolDTO;
|
||||
import com.cnbm.basic.excel.MeasureToolExcel;
|
||||
import com.cnbm.basic.service.IMeasureToolService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 量具表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/measureTool")
|
||||
@Api(tags="量具表")
|
||||
public class MeasureToolController {
|
||||
@Autowired
|
||||
private IMeasureToolService measureToolService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "name", value = "名称", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "code", value = "编码", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:measureTool:page')")
|
||||
public Result<PageData<MeasureToolDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<MeasureToolDTO> page = measureToolService.page(params);
|
||||
|
||||
return new Result<PageData<MeasureToolDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:measureTool:info')")
|
||||
public Result<MeasureToolDTO> get(@PathVariable("id") Long id){
|
||||
MeasureToolDTO data = measureToolService.get(id);
|
||||
|
||||
return new Result<MeasureToolDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:measureTool:save')")
|
||||
public Result save(@RequestBody MeasureToolDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
measureToolService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:measureTool:update')")
|
||||
public Result update(@RequestBody MeasureToolDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
measureToolService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:measureTool:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
measureToolService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:measureTool:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<MeasureToolDTO> list = measureToolService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, MeasureToolExcel.class);
|
||||
}
|
||||
|
||||
@PostMapping("status")
|
||||
@ApiOperation("改变状态")
|
||||
//@LogOperation("改变状态")
|
||||
public Result changeStatus(@RequestBody IdParam id){
|
||||
measureToolService.changeStatus(id.getId());
|
||||
|
||||
return new Result();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,127 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.admin.params.IdParam;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.PlatformDTO;
|
||||
import com.cnbm.basic.excel.PlatformExcel;
|
||||
import com.cnbm.basic.service.IPlatformService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 站点表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/platform")
|
||||
@Api(tags="站点表")
|
||||
public class PlatformController {
|
||||
@Autowired
|
||||
private IPlatformService platformService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:platform:page')")
|
||||
public Result<PageData<PlatformDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<PlatformDTO> page = platformService.page(params);
|
||||
|
||||
return new Result<PageData<PlatformDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:platform:info')")
|
||||
public Result<PlatformDTO> get(@PathVariable("id") Long id){
|
||||
PlatformDTO data = platformService.get(id);
|
||||
|
||||
return new Result<PlatformDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:platform:save')")
|
||||
public Result save(@RequestBody PlatformDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
platformService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:platform:update')")
|
||||
public Result update(@RequestBody PlatformDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
platformService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:platform:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
platformService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:platform:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<PlatformDTO> list = platformService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, PlatformExcel.class);
|
||||
}
|
||||
|
||||
@PostMapping("status")
|
||||
@ApiOperation("改变状态")
|
||||
//@LogOperation("改变状态")
|
||||
public Result changeStatus(@RequestBody IdParam id){
|
||||
platformService.changeStatus(id.getId());
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,131 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.admin.params.IdParam;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.ProductDTO;
|
||||
import com.cnbm.basic.excel.ProductExcel;
|
||||
import com.cnbm.basic.service.IProductService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 产品 表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-11
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/product")
|
||||
@Api(tags="产品 表")
|
||||
public class ProductController {
|
||||
@Autowired
|
||||
private IProductService productService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "name", value = "名称", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "code", value = "编码", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class),
|
||||
@ApiImplicitParam(name = "product_type_id", value = "产品类型id", paramType = "query", dataTypeClass = Integer.class),
|
||||
@ApiImplicitParam(name = "inspection_stage", value = "检验阶段;1 进货检验、 2 过程检验、 3 成品检验、 4 出货检验", paramType = "query", dataTypeClass = String.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:product:page')")
|
||||
public Result<PageData<ProductDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<ProductDTO> page = productService.page(params);
|
||||
|
||||
return new Result<PageData<ProductDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:product:info')")
|
||||
public Result<ProductDTO> get(@PathVariable("id") Long id){
|
||||
ProductDTO data = productService.get(id);
|
||||
|
||||
return new Result<ProductDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:product:save')")
|
||||
public Result save(@RequestBody ProductDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
productService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:product:update')")
|
||||
public Result update(@RequestBody ProductDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
productService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:product:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
productService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:product:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<ProductDTO> list = productService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, ProductExcel.class);
|
||||
}
|
||||
|
||||
@PostMapping("status")
|
||||
@ApiOperation("改变状态")
|
||||
//@LogOperation("改变状态")
|
||||
public Result changeStatus(@RequestBody IdParam id){
|
||||
productService.changeStatus(id.getId());
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,117 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.ProductFactoryRelationDTO;
|
||||
import com.cnbm.basic.excel.ProductFactoryRelationExcel;
|
||||
import com.cnbm.basic.service.IProductFactoryRelationService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 产品-工厂 关系表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-27
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/productFactoryRelation")
|
||||
@Api(tags="产品-工厂 关系表")
|
||||
public class ProductFactoryRelationController {
|
||||
@Autowired
|
||||
private IProductFactoryRelationService productFactoryRelationService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "id", value = "id", paramType = "query", dataTypeClass = Long.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFactoryRelation:page')")
|
||||
public Result<PageData<ProductFactoryRelationDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<ProductFactoryRelationDTO> page = productFactoryRelationService.page(params);
|
||||
|
||||
return new Result<PageData<ProductFactoryRelationDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFactoryRelation:info')")
|
||||
public Result<ProductFactoryRelationDTO> get(@PathVariable("id") Long id){
|
||||
ProductFactoryRelationDTO data = productFactoryRelationService.get(id);
|
||||
|
||||
return new Result<ProductFactoryRelationDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFactoryRelation:save')")
|
||||
public Result save(@RequestBody ProductFactoryRelationDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
productFactoryRelationService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFactoryRelation:update')")
|
||||
public Result update(@RequestBody ProductFactoryRelationDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
productFactoryRelationService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFactoryRelation:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
productFactoryRelationService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFactoryRelation:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<ProductFactoryRelationDTO> list = productFactoryRelationService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, ProductFactoryRelationExcel.class);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,117 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.ProductFeaturesDTO;
|
||||
import com.cnbm.basic.excel.ProductFeaturesExcel;
|
||||
import com.cnbm.basic.service.IProductFeaturesService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 产品特性 表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/productFeatures")
|
||||
@Api(tags="产品特性 表")
|
||||
public class ProductFeaturesController {
|
||||
@Autowired
|
||||
private IProductFeaturesService productFeaturesService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "id", value = "id", paramType = "query", dataTypeClass = Long.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeatures:page')")
|
||||
public Result<PageData<ProductFeaturesDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<ProductFeaturesDTO> page = productFeaturesService.page(params);
|
||||
|
||||
return new Result<PageData<ProductFeaturesDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeatures:info')")
|
||||
public Result<ProductFeaturesDTO> get(@PathVariable("id") Long id){
|
||||
ProductFeaturesDTO data = productFeaturesService.get(id);
|
||||
|
||||
return new Result<ProductFeaturesDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeatures:save')")
|
||||
public Result save(@RequestBody ProductFeaturesDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
productFeaturesService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeatures:update')")
|
||||
public Result update(@RequestBody ProductFeaturesDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
productFeaturesService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeatures:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
productFeaturesService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeatures:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<ProductFeaturesDTO> list = productFeaturesService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, ProductFeaturesExcel.class);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,117 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.ProductFeaturesHisDTO;
|
||||
import com.cnbm.basic.excel.ProductFeaturesHisExcel;
|
||||
import com.cnbm.basic.service.IProductFeaturesHisService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 产品特性 历史表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/productFeaturesHis")
|
||||
@Api(tags="产品特性 历史表")
|
||||
public class ProductFeaturesHisController {
|
||||
@Autowired
|
||||
private IProductFeaturesHisService productFeaturesHisService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "id", value = "id", paramType = "query", dataTypeClass = Long.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeaturesHis:page')")
|
||||
public Result<PageData<ProductFeaturesHisDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<ProductFeaturesHisDTO> page = productFeaturesHisService.page(params);
|
||||
|
||||
return new Result<PageData<ProductFeaturesHisDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeaturesHis:info')")
|
||||
public Result<ProductFeaturesHisDTO> get(@PathVariable("id") Long id){
|
||||
ProductFeaturesHisDTO data = productFeaturesHisService.get(id);
|
||||
|
||||
return new Result<ProductFeaturesHisDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeaturesHis:save')")
|
||||
public Result save(@RequestBody ProductFeaturesHisDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
productFeaturesHisService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeaturesHis:update')")
|
||||
public Result update(@RequestBody ProductFeaturesHisDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
productFeaturesHisService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeaturesHis:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
productFeaturesHisService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productFeaturesHis:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<ProductFeaturesHisDTO> list = productFeaturesHisService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, ProductFeaturesHisExcel.class);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.admin.params.IdParam;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
@@ -34,19 +35,23 @@ import java.util.Map;
|
||||
* @since 2022-06-30
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/code/productType")
|
||||
@RequestMapping("/basic/productType")
|
||||
@Api(tags="产品类型 表")
|
||||
public class ProductTypeController {
|
||||
@Autowired
|
||||
private IProductTypeService productTypeService;
|
||||
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class)
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "name", value = "名称", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "code", value = "编码", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class)
|
||||
})
|
||||
// @PreAuthorize("@ex.hasAuthority('code:productType:page')")
|
||||
public Result<PageData<ProductTypeDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
@@ -66,7 +71,7 @@ public class ProductTypeController {
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
@LogOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
// @PreAuthorize("@ex.hasAuthority('code:productType:save')")
|
||||
public Result save(@RequestBody ProductTypeDTO dto){
|
||||
//效验数据
|
||||
@@ -79,7 +84,7 @@ public class ProductTypeController {
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
@LogOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
// @PreAuthorize("@ex.hasAuthority('code:productType:update')")
|
||||
public Result update(@RequestBody ProductTypeDTO dto){
|
||||
//效验数据
|
||||
@@ -92,7 +97,7 @@ public class ProductTypeController {
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
@LogOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
// @PreAuthorize("@ex.hasAuthority('code:productType:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
@@ -105,7 +110,7 @@ public class ProductTypeController {
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
@LogOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
// @PreAuthorize("@ex.hasAuthority('code:productType:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<ProductTypeDTO> list = productTypeService.list(params);
|
||||
@@ -113,4 +118,13 @@ public class ProductTypeController {
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, ProductTypeExcel.class);
|
||||
}
|
||||
|
||||
@PostMapping("status")
|
||||
@ApiOperation("改变状态")
|
||||
//@LogOperation("改变状态")
|
||||
public Result changeStatus(@RequestBody IdParam id){
|
||||
productTypeService.changeStatus(id.getId());
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,137 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.basic.dto.WorkingProcedureDTO;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.ProductWorkingprocedureRelationDTO;
|
||||
import com.cnbm.basic.excel.ProductWorkingprocedureRelationExcel;
|
||||
import com.cnbm.basic.service.IProductWorkingprocedureRelationService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 工序 表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/productWorkingprocedureRelation")
|
||||
@Api(tags="产品-工序 关系表")
|
||||
public class ProductWorkingprocedureRelationController {
|
||||
@Autowired
|
||||
private IProductWorkingprocedureRelationService productWorkingprocedureRelationService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "id", value = "id", paramType = "query", dataTypeClass = Long.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productWorkingprocedureRelation:page')")
|
||||
public Result<PageData<ProductWorkingprocedureRelationDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<ProductWorkingprocedureRelationDTO> page = productWorkingprocedureRelationService.page(params);
|
||||
|
||||
return new Result<PageData<ProductWorkingprocedureRelationDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productWorkingprocedureRelation:info')")
|
||||
public Result<ProductWorkingprocedureRelationDTO> get(@PathVariable("id") Long id){
|
||||
ProductWorkingprocedureRelationDTO data = productWorkingprocedureRelationService.get(id);
|
||||
|
||||
return new Result<ProductWorkingprocedureRelationDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping("save")
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productWorkingprocedureRelation:save')")
|
||||
public Result save(@RequestBody ProductWorkingprocedureRelationDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
productWorkingprocedureRelationService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productWorkingprocedureRelation:update')")
|
||||
public Result update(@RequestBody ProductWorkingprocedureRelationDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
productWorkingprocedureRelationService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productWorkingprocedureRelation:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
productWorkingprocedureRelationService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productWorkingprocedureRelation:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<ProductWorkingprocedureRelationDTO> list = productWorkingprocedureRelationService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, ProductWorkingprocedureRelationExcel.class);
|
||||
}
|
||||
|
||||
@GetMapping("{productId}")
|
||||
@ApiOperation("查询所有工序 依据产品id")
|
||||
//@LogOperation("查询所有工序 依据产品id")
|
||||
public Result<List<ProductWorkingprocedureRelationDTO>> getWorkingprocedureByProductId(@PathVariable("productId") Long productId){
|
||||
List<ProductWorkingprocedureRelationDTO> list = productWorkingprocedureRelationService.getWorkingprocedureByProductId(productId);
|
||||
return new Result<List<ProductWorkingprocedureRelationDTO>>().ok(list);
|
||||
}
|
||||
|
||||
@PostMapping("batchInsertWorkingprocedure")
|
||||
@ApiOperation("添加工序流程")
|
||||
//@LogOperation("添加工序流程")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:productWorkingprocedureRelation:batchInsertWorkingprocedure')")
|
||||
public Result batchInsertWorkingprocedure(@RequestBody ProductWorkingprocedureRelationDTO[] lists){
|
||||
|
||||
productWorkingprocedureRelationService.batchInsertWorkingprocedure(lists);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,117 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.ShiftDTO;
|
||||
import com.cnbm.basic.excel.ShiftExcel;
|
||||
import com.cnbm.basic.service.IShiftService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 班次 表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/shift")
|
||||
@Api(tags="班次 表")
|
||||
public class ShiftController {
|
||||
@Autowired
|
||||
private IShiftService shiftService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "id", value = "id", paramType = "query", dataTypeClass = Long.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:shift:page')")
|
||||
public Result<PageData<ShiftDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<ShiftDTO> page = shiftService.page(params);
|
||||
|
||||
return new Result<PageData<ShiftDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:shift:info')")
|
||||
public Result<ShiftDTO> get(@PathVariable("id") Long id){
|
||||
ShiftDTO data = shiftService.get(id);
|
||||
|
||||
return new Result<ShiftDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:shift:save')")
|
||||
public Result save(@RequestBody ShiftDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
shiftService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:shift:update')")
|
||||
public Result update(@RequestBody ShiftDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
shiftService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:shift:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
shiftService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:shift:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<ShiftDTO> list = shiftService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, ShiftExcel.class);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,117 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.TeamDTO;
|
||||
import com.cnbm.basic.excel.TeamExcel;
|
||||
import com.cnbm.basic.service.ITeamService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 班组 表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/team")
|
||||
@Api(tags="班组 表")
|
||||
public class TeamController {
|
||||
@Autowired
|
||||
private ITeamService teamService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "id", value = "id", paramType = "query", dataTypeClass = Long.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:team:page')")
|
||||
public Result<PageData<TeamDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<TeamDTO> page = teamService.page(params);
|
||||
|
||||
return new Result<PageData<TeamDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:team:info')")
|
||||
public Result<TeamDTO> get(@PathVariable("id") Long id){
|
||||
TeamDTO data = teamService.get(id);
|
||||
|
||||
return new Result<TeamDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:team:save')")
|
||||
public Result save(@RequestBody TeamDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
teamService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:team:update')")
|
||||
public Result update(@RequestBody TeamDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
teamService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:team:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
teamService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:team:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<TeamDTO> list = teamService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, TeamExcel.class);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.admin.params.IdParam;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
@@ -34,7 +35,7 @@ import java.util.Map;
|
||||
* @since 2022-06-30
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/code/unit")
|
||||
@RequestMapping("/basic/unit")
|
||||
@Api(tags="单位 表")
|
||||
public class UnitController {
|
||||
@Autowired
|
||||
@@ -46,9 +47,10 @@ public class UnitController {
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class)
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class)
|
||||
})
|
||||
@PreAuthorize("@ex.hasAuthority('code:unit:page')")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:unit:page')")
|
||||
public Result<PageData<UnitDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<UnitDTO> page = unitService.page(params);
|
||||
|
||||
@@ -57,7 +59,7 @@ public class UnitController {
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
@PreAuthorize("@ex.hasAuthority('code:unit:info')")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:unit:info')")
|
||||
public Result<UnitDTO> get(@PathVariable("id") Long id){
|
||||
UnitDTO data = unitService.get(id);
|
||||
|
||||
@@ -66,8 +68,8 @@ public class UnitController {
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
@LogOperation("保存")
|
||||
@PreAuthorize("@ex.hasAuthority('code:unit:save')")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:unit:save')")
|
||||
public Result save(@RequestBody UnitDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
@@ -79,8 +81,8 @@ public class UnitController {
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
@LogOperation("修改")
|
||||
@PreAuthorize("@ex.hasAuthority('code:unit:update')")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:unit:update')")
|
||||
public Result update(@RequestBody UnitDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
@@ -92,8 +94,8 @@ public class UnitController {
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
@LogOperation("删除")
|
||||
@PreAuthorize("@ex.hasAuthority('code:unit:delete')")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:unit:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
@@ -105,12 +107,21 @@ public class UnitController {
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
@LogOperation("导出")
|
||||
@PreAuthorize("@ex.hasAuthority('code:unit:export')")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:unit:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<UnitDTO> list = unitService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, UnitExcel.class);
|
||||
}
|
||||
|
||||
@PostMapping("status")
|
||||
@ApiOperation("改变状态")
|
||||
//@LogOperation("改变状态")
|
||||
public Result changeStatus(@RequestBody IdParam id){
|
||||
unitService.changeStatus(id.getId());
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,137 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.admin.params.IdParam;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.WorkingProcedureDTO;
|
||||
import com.cnbm.basic.excel.WorkingProcedureExcel;
|
||||
import com.cnbm.basic.service.IWorkingProcedureService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 工序 表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/workingProcedure")
|
||||
@Api(tags="工序 表")
|
||||
public class WorkingProcedureController {
|
||||
@Autowired
|
||||
private IWorkingProcedureService workingProcedureService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "name", value = "名称", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "code", value = "编码", paramType = "query", dataTypeClass = String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedure:page')")
|
||||
public Result<PageData<WorkingProcedureDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<WorkingProcedureDTO> page = workingProcedureService.page(params);
|
||||
|
||||
return new Result<PageData<WorkingProcedureDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedure:info')")
|
||||
public Result<WorkingProcedureDTO> get(@PathVariable("id") Long id){
|
||||
WorkingProcedureDTO data = workingProcedureService.get(id);
|
||||
|
||||
return new Result<WorkingProcedureDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedure:save')")
|
||||
public Result save(@RequestBody WorkingProcedureDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
workingProcedureService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedure:update')")
|
||||
public Result update(@RequestBody WorkingProcedureDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
workingProcedureService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedure:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
workingProcedureService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedure:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<WorkingProcedureDTO> list = workingProcedureService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, WorkingProcedureExcel.class);
|
||||
}
|
||||
|
||||
@PostMapping("status")
|
||||
@ApiOperation("改变状态")
|
||||
//@LogOperation("改变状态")
|
||||
public Result changeStatus(@RequestBody IdParam id){
|
||||
workingProcedureService.changeStatus(id.getId());
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("getWorkingprocedureByProductId")
|
||||
@ApiOperation("查询所有工序 依据产品id")
|
||||
//@LogOperation("查询所有工序 依据产品id")
|
||||
public Result<List<WorkingProcedureDTO>> getWorkingprocedureByProductId(@PathVariable("productId") Long productId){
|
||||
List<WorkingProcedureDTO> list = workingProcedureService.getWorkingProcedureByProductId(productId);
|
||||
return new Result<List<WorkingProcedureDTO>>().ok(list);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,127 @@
|
||||
package com.cnbm.basic.controller;
|
||||
|
||||
import com.cnbm.admin.annotation.LogOperation;
|
||||
import com.cnbm.admin.params.IdParam;
|
||||
import com.cnbm.common.constant.Constant;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.utils.ExcelUtils;
|
||||
import com.cnbm.common.utils.Result;
|
||||
import com.cnbm.common.validator.AssertUtils;
|
||||
import com.cnbm.common.validator.ValidatorUtils;
|
||||
import com.cnbm.common.validator.group.AddGroup;
|
||||
import com.cnbm.common.validator.group.DefaultGroup;
|
||||
import com.cnbm.common.validator.group.UpdateGroup;
|
||||
import com.cnbm.basic.dto.WorkingProcedureTypeDTO;
|
||||
import com.cnbm.basic.excel.WorkingProcedureTypeExcel;
|
||||
import com.cnbm.basic.service.IWorkingProcedureTypeService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import springfox.documentation.annotations.ApiIgnore;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
/**
|
||||
* 工序类型表 表 前端控制器
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/basic/workingProcedureType")
|
||||
@Api(tags="工序类型表 表")
|
||||
public class WorkingProcedureTypeController {
|
||||
@Autowired
|
||||
private IWorkingProcedureTypeService workingProcedureTypeService;
|
||||
|
||||
@GetMapping("page")
|
||||
@ApiOperation("分页")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = Constant.PAGE, value = "当前页码,从1开始", paramType = "query", required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.LIMIT, value = "每页显示记录数", paramType = "query",required = true, dataTypeClass=Integer.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER_FIELD, value = "排序字段", paramType = "query", dataTypeClass=String.class) ,
|
||||
@ApiImplicitParam(name = Constant.ORDER, value = "排序方式,可选值(asc、desc)", paramType = "query", dataTypeClass=String.class),
|
||||
@ApiImplicitParam(name = "status", value = "状态", paramType = "query", dataTypeClass = Integer.class)
|
||||
})
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedureType:page')")
|
||||
public Result<PageData<WorkingProcedureTypeDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params){
|
||||
PageData<WorkingProcedureTypeDTO> page = workingProcedureTypeService.page(params);
|
||||
|
||||
return new Result<PageData<WorkingProcedureTypeDTO>>().ok(page);
|
||||
}
|
||||
|
||||
@GetMapping("{id}")
|
||||
@ApiOperation("信息")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedureType:info')")
|
||||
public Result<WorkingProcedureTypeDTO> get(@PathVariable("id") Long id){
|
||||
WorkingProcedureTypeDTO data = workingProcedureTypeService.get(id);
|
||||
|
||||
return new Result<WorkingProcedureTypeDTO>().ok(data);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@ApiOperation("保存")
|
||||
//@LogOperation("保存")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedureType:save')")
|
||||
public Result save(@RequestBody WorkingProcedureTypeDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||
|
||||
workingProcedureTypeService.save(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@ApiOperation("修改")
|
||||
//@LogOperation("修改")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedureType:update')")
|
||||
public Result update(@RequestBody WorkingProcedureTypeDTO dto){
|
||||
//效验数据
|
||||
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class);
|
||||
|
||||
workingProcedureTypeService.update(dto);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@ApiOperation("删除")
|
||||
//@LogOperation("删除")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedureType:delete')")
|
||||
public Result delete(@RequestBody Long[] ids){
|
||||
//效验数据
|
||||
AssertUtils.isArrayEmpty(ids, "id");
|
||||
|
||||
workingProcedureTypeService.delete(ids);
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
@GetMapping("export")
|
||||
@ApiOperation("导出")
|
||||
//@LogOperation("导出")
|
||||
//@PreAuthorize("@ex.hasAuthority('code:workingProcedureType:export')")
|
||||
public void export(@ApiIgnore @RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception {
|
||||
List<WorkingProcedureTypeDTO> list = workingProcedureTypeService.list(params);
|
||||
|
||||
ExcelUtils.exportExcelToTarget(response, null, list, WorkingProcedureTypeExcel.class);
|
||||
}
|
||||
|
||||
@PostMapping("status")
|
||||
@ApiOperation("改变状态")
|
||||
//@LogOperation("改变状态")
|
||||
public Result changeStatus(@RequestBody IdParam id){
|
||||
workingProcedureTypeService.changeStatus(id.getId());
|
||||
|
||||
return new Result();
|
||||
}
|
||||
|
||||
}
|
||||
72
ym-baisc/src/main/java/com/cnbm/basic/dto/FactoryDTO.java
Normal file
72
ym-baisc/src/main/java/com/cnbm/basic/dto/FactoryDTO.java
Normal file
@@ -0,0 +1,72 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
/**
|
||||
* 工厂 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "工厂 表DTO对象")
|
||||
public class FactoryDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "工厂 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "工厂 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "工厂 描述")
|
||||
private String descs;
|
||||
|
||||
@ApiModelProperty(value = "工厂 联系地址")
|
||||
private String address;
|
||||
|
||||
@ApiModelProperty(value = "工厂类型,1-内部工厂;2-供应商")
|
||||
private String type;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
69
ym-baisc/src/main/java/com/cnbm/basic/dto/MachineDTO.java
Normal file
69
ym-baisc/src/main/java/com/cnbm/basic/dto/MachineDTO.java
Normal file
@@ -0,0 +1,69 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
/**
|
||||
* 机台表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "机台表DTO对象")
|
||||
public class MachineDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "机台名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "机台编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "机台id,关联platform id")
|
||||
private Long platformId;
|
||||
|
||||
@ApiModelProperty(value = "机台名称,关联platform id")
|
||||
private String platformName;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,66 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
/**
|
||||
* 量具表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "量具表DTO对象")
|
||||
public class MeasureToolDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "量具 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "量具 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "量具类型;计量型=1 计数型=2")
|
||||
private String type;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
66
ym-baisc/src/main/java/com/cnbm/basic/dto/PlatformDTO.java
Normal file
66
ym-baisc/src/main/java/com/cnbm/basic/dto/PlatformDTO.java
Normal file
@@ -0,0 +1,66 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
/**
|
||||
* 站点表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "站点表DTO对象")
|
||||
public class PlatformDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "站台名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "站台编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "站台分组")
|
||||
private String platformGroup;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
85
ym-baisc/src/main/java/com/cnbm/basic/dto/ProductDTO.java
Normal file
85
ym-baisc/src/main/java/com/cnbm/basic/dto/ProductDTO.java
Normal file
@@ -0,0 +1,85 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
/**
|
||||
* 产品 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-11
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "产品 表DTO对象")
|
||||
public class ProductDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "产品 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "产品 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "产品 规格")
|
||||
private String specifications;
|
||||
|
||||
@ApiModelProperty(value = "产品 图纸")
|
||||
private String drawing;
|
||||
|
||||
@ApiModelProperty(value = "描述")
|
||||
private String descs;
|
||||
|
||||
@ApiModelProperty(value = "产品类型id,关联product_type表")
|
||||
private Long productTypeId;
|
||||
|
||||
@ApiModelProperty(value = "产品类型 名,product_type表")
|
||||
private String productType;
|
||||
|
||||
@ApiModelProperty(value = "单位 id,关联unit表")
|
||||
private Long unitId;
|
||||
|
||||
@ApiModelProperty(value = "检验阶段;1 进货检验、 2 过程检验、 3 成品检验、 4 出货检验;; 如果有多个用逗号隔开,比如 1,4 就代表选中了进货检验和出货检验")
|
||||
private String inspectionStage;
|
||||
|
||||
@ApiModelProperty(value = "检验标准")
|
||||
private String inspectionStandard;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,63 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
/**
|
||||
* 产品-工厂 关系表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-27
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "产品-工厂 关系表DTO对象")
|
||||
public class ProductFactoryRelationDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "产品id,关联product表")
|
||||
private Long productId;
|
||||
|
||||
@ApiModelProperty(value = "工厂id,关联 factory 表")
|
||||
private Long factoryId;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,110 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 产品特性 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "产品特性 表DTO对象")
|
||||
public class ProductFeaturesDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "产品id,关联product表")
|
||||
private Long productId;
|
||||
|
||||
@ApiModelProperty(value = "量具id,关联measure_tool表")
|
||||
private Long measureToolId;
|
||||
|
||||
@ApiModelProperty(value = "单位 id,关联unit表")
|
||||
private Long unitId;
|
||||
|
||||
@ApiModelProperty(value = "产品特性 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "产品特性 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "产品特性类型:1 计量型;2 计数型")
|
||||
private Integer type;
|
||||
|
||||
@ApiModelProperty(value = "缺陷等级:1 致命缺陷;2 严重缺陷;3.轻微缺陷")
|
||||
private Integer defectLevel;
|
||||
|
||||
@ApiModelProperty(value = "产品特性 规格")
|
||||
private String specifications;
|
||||
|
||||
@ApiModelProperty(value = "检验参数 规格下线")
|
||||
private Float lsl;
|
||||
|
||||
@ApiModelProperty(value = "检验参数 规格中心线")
|
||||
private Float sl;
|
||||
|
||||
@ApiModelProperty(value = "检验参数 规格上线")
|
||||
private Float usl;
|
||||
|
||||
@ApiModelProperty(value = "工序id,关联 working_procedure 表id")
|
||||
private Long workingProcedureId;
|
||||
|
||||
@ApiModelProperty(value = "分析图形,关联control_graph表id")
|
||||
private Long controlGraphId;
|
||||
|
||||
@ApiModelProperty(value = "是否需要spc分析,1 yes;0 no")
|
||||
private Integer isSpc;
|
||||
|
||||
@ApiModelProperty(value = "样本大小,一般2-25之间。 会依据这个size 把所有待分析的数据 组成一个一个样本")
|
||||
private Integer sampleSize;
|
||||
|
||||
@ApiModelProperty(value = "采样频率,只用于展示")
|
||||
private String samplingFrequency;
|
||||
|
||||
@ApiModelProperty(value = "小数位数(限制 检验参数小数点后面位数),这个先放着后续再说。")
|
||||
private Integer decimalPlaces;
|
||||
|
||||
@ApiModelProperty(value = "目标cpk")
|
||||
private Float targetCpk;
|
||||
|
||||
@ApiModelProperty(value = "目标cpk")
|
||||
private Float targetPpk;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,113 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 产品特性 历史表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "产品特性 历史表DTO对象")
|
||||
public class ProductFeaturesHisDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "产品特性id,关联product_features表")
|
||||
private Long productFeaturesId;
|
||||
|
||||
@ApiModelProperty(value = "产品id,关联product表")
|
||||
private Long productId;
|
||||
|
||||
@ApiModelProperty(value = "产品特性 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "产品特性 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "产品特性类型:1 计量型;2 计数型")
|
||||
private Integer type;
|
||||
|
||||
@ApiModelProperty(value = "缺陷等级:1 致命缺陷;2 严重缺陷;3.轻微缺陷")
|
||||
private Integer defectLevel;
|
||||
|
||||
@ApiModelProperty(value = "量具id,关联measure_tool表")
|
||||
private Long measureToolId;
|
||||
|
||||
@ApiModelProperty(value = "单位 id,关联unit表")
|
||||
private Long unitId;
|
||||
|
||||
@ApiModelProperty(value = "产品特性 规格")
|
||||
private String specifications;
|
||||
|
||||
@ApiModelProperty(value = "检验参数 规格下线")
|
||||
private Float lsl;
|
||||
|
||||
@ApiModelProperty(value = "检验参数 规格中心线")
|
||||
private Float sl;
|
||||
|
||||
@ApiModelProperty(value = "检验参数 规格上线")
|
||||
private Float usl;
|
||||
|
||||
@ApiModelProperty(value = "工序id,关联 working_procedure 表id")
|
||||
private Long workingProcedureId;
|
||||
|
||||
@ApiModelProperty(value = "是否需要spc分析,1 yes;0 no")
|
||||
private Integer isSpc;
|
||||
|
||||
@ApiModelProperty(value = "分析图形,关联control_graph表id")
|
||||
private Long controlGraphId;
|
||||
|
||||
@ApiModelProperty(value = "样本大小,一般2-25之间。 会依据这个size 把所有待分析的数据 组成一个一个样本")
|
||||
private Integer sampleSize;
|
||||
|
||||
@ApiModelProperty(value = "采样频率,只用于展示")
|
||||
private String samplingFrequency;
|
||||
|
||||
@ApiModelProperty(value = "小数位数(限制 检验参数小数点后面位数),这个先放着后续再说。")
|
||||
private Integer decimalPlaces;
|
||||
|
||||
@ApiModelProperty(value = "目标cpk")
|
||||
private Float targetCpk;
|
||||
|
||||
@ApiModelProperty(value = "目标cpk")
|
||||
private Float targetPpk;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -5,7 +5,6 @@ import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
@@ -20,10 +19,8 @@ import java.time.LocalDateTime;
|
||||
public class ProductTypeDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private BigDecimal id;
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "产品类型 名")
|
||||
private String name;
|
||||
@@ -35,16 +32,16 @@ public class ProductTypeDTO implements Serializable {
|
||||
private String desc;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private BigDecimal status;
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private BigDecimal valid;
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private BigDecimal creatorId;
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
@@ -53,7 +50,7 @@ public class ProductTypeDTO implements Serializable {
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private BigDecimal updaterId;
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
@@ -62,6 +59,6 @@ public class ProductTypeDTO implements Serializable {
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private BigDecimal version;
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,69 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
/**
|
||||
* 工序 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "工序 表DTO对象")
|
||||
public class ProductWorkingprocedureRelationDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "产品id,关联product表")
|
||||
private Long productId;
|
||||
|
||||
@ApiModelProperty(value = "工序id,关联 working_procedure 表")
|
||||
private Long workingProcedureId;
|
||||
|
||||
@ApiModelProperty(value = "工序名称,关联 working_procedure 表")
|
||||
private String workingProcedureName;
|
||||
|
||||
@ApiModelProperty(value = "顺序,工序是有先后顺序的。")
|
||||
private Integer order;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
65
ym-baisc/src/main/java/com/cnbm/basic/dto/ShiftDTO.java
Normal file
65
ym-baisc/src/main/java/com/cnbm/basic/dto/ShiftDTO.java
Normal file
@@ -0,0 +1,65 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 班次 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "班次 表DTO对象")
|
||||
public class ShiftDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "班次 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "班次 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "班次 描述")
|
||||
private String descs;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
65
ym-baisc/src/main/java/com/cnbm/basic/dto/TeamDTO.java
Normal file
65
ym-baisc/src/main/java/com/cnbm/basic/dto/TeamDTO.java
Normal file
@@ -0,0 +1,65 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 班组 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "班组 表DTO对象")
|
||||
public class TeamDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "班组 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "班组 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "班组 描述")
|
||||
private String descs;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -5,7 +5,6 @@ import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
|
||||
@@ -23,7 +22,7 @@ public class UnitDTO implements Serializable {
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private BigDecimal id;
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "单位 名")
|
||||
private String name;
|
||||
@@ -32,19 +31,19 @@ public class UnitDTO implements Serializable {
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "单位类型,1 可计数,2 不可计数")
|
||||
private BigDecimal type;
|
||||
private Integer type;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private BigDecimal status;
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private BigDecimal valid;
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private BigDecimal creatorId;
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
@@ -53,7 +52,7 @@ public class UnitDTO implements Serializable {
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private BigDecimal updaterId;
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
@@ -62,6 +61,6 @@ public class UnitDTO implements Serializable {
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private BigDecimal version;
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,74 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 工序 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "工序 表DTO对象")
|
||||
public class WorkingProcedureDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "工序 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "工序 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "工序类型 id,关联working_procedure_type表")
|
||||
private Long workingProcedureTypeId;
|
||||
|
||||
@ApiModelProperty(value = "工序类型 名,关联working_procedure_type表")
|
||||
private String workingProcedureTypeName;
|
||||
|
||||
@ApiModelProperty(value = "机台(也就是设备),这个工序对应的设备,可能有一个或者多个,如果多个用逗号隔开,\"id1,id2,......\"")
|
||||
private String machineId;
|
||||
|
||||
@ApiModelProperty(value = "机台id对应名称")
|
||||
private String machineName;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,62 @@
|
||||
package com.cnbm.basic.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 工序类型表 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "工序类型表 表DTO对象")
|
||||
public class WorkingProcedureTypeDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "工序类型 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "工序类型 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty(value = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty(value = "更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty(value = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
72
ym-baisc/src/main/java/com/cnbm/basic/entity/Factory.java
Normal file
72
ym-baisc/src/main/java/com/cnbm/basic/entity/Factory.java
Normal file
@@ -0,0 +1,72 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 工厂 表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "Factory对象", description = "工厂 表")
|
||||
public class Factory implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("工厂 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("工厂 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("工厂 描述")
|
||||
private String descs;
|
||||
|
||||
@ApiModelProperty("工厂 联系地址")
|
||||
private String address;
|
||||
|
||||
@ApiModelProperty("工厂类型,1-内部工厂;2-供应商")
|
||||
private String type;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
66
ym-baisc/src/main/java/com/cnbm/basic/entity/Machine.java
Normal file
66
ym-baisc/src/main/java/com/cnbm/basic/entity/Machine.java
Normal file
@@ -0,0 +1,66 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 机台表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "Machine对象", description = "机台表")
|
||||
public class Machine implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("机台名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("机台编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("机台id,关联platform id")
|
||||
private Long platformId;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 量具表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@TableName("measure_tool")
|
||||
@ApiModel(value = "MeasureTool对象", description = "量具表")
|
||||
public class MeasureTool implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("量具 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("量具 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("量具类型;计量型=1 计数型=2")
|
||||
private String type;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
66
ym-baisc/src/main/java/com/cnbm/basic/entity/Platform.java
Normal file
66
ym-baisc/src/main/java/com/cnbm/basic/entity/Platform.java
Normal file
@@ -0,0 +1,66 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 站点表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "Platform对象", description = "站点表")
|
||||
public class Platform implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("站台名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("站台编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("站台分组")
|
||||
private String platformGroup;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
84
ym-baisc/src/main/java/com/cnbm/basic/entity/Product.java
Normal file
84
ym-baisc/src/main/java/com/cnbm/basic/entity/Product.java
Normal file
@@ -0,0 +1,84 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 产品 表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-11
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "Product对象", description = "产品 表")
|
||||
public class Product implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("产品 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("产品 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("产品 规格")
|
||||
private String specifications;
|
||||
|
||||
@ApiModelProperty("产品 图纸")
|
||||
private String drawing;
|
||||
|
||||
@ApiModelProperty("描述")
|
||||
private String descs;
|
||||
|
||||
@ApiModelProperty("产品类型id,关联product_type表")
|
||||
private Long productTypeId;
|
||||
|
||||
@ApiModelProperty("单位 id,关联unit表")
|
||||
private Long unitId;
|
||||
|
||||
@ApiModelProperty("检验阶段;1 进货检验、 2 过程检验、 3 成品检验、 4 出货检验;; 如果有多个用逗号隔开,比如 1,4 就代表选中了进货检验和出货检验")
|
||||
private String inspectionStage;
|
||||
|
||||
@ApiModelProperty("检验标准")
|
||||
private String inspectionStandard;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,65 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 产品-工厂 关系表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-27
|
||||
*/
|
||||
@Data
|
||||
@TableName("product_factory_relation")
|
||||
@ApiModel(value = "ProductFactoryRelation对象", description = "产品-工厂 关系表")
|
||||
public class ProductFactoryRelation implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("产品id,关联product表")
|
||||
private Long productId;
|
||||
|
||||
@ApiModelProperty("工厂id,关联 factory 表")
|
||||
private Long factoryId;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,113 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 产品特性 表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@TableName("product_features")
|
||||
@ApiModel(value = "ProductFeatures对象", description = "产品特性 表")
|
||||
public class ProductFeatures implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("产品id,关联product表")
|
||||
private Long productId;
|
||||
|
||||
@ApiModelProperty("量具id,关联measure_tool表")
|
||||
private Long measureToolId;
|
||||
|
||||
@ApiModelProperty("单位 id,关联unit表")
|
||||
private Long unitId;
|
||||
|
||||
@ApiModelProperty("产品特性 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("产品特性 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("产品特性类型:1 计量型;2 计数型")
|
||||
private Integer type;
|
||||
|
||||
@ApiModelProperty("缺陷等级:1 致命缺陷;2 严重缺陷;3.轻微缺陷")
|
||||
private Integer defectLevel;
|
||||
|
||||
@ApiModelProperty("产品特性 规格")
|
||||
private String specifications;
|
||||
|
||||
@ApiModelProperty("检验参数 规格下线")
|
||||
private Float lsl;
|
||||
|
||||
@ApiModelProperty("检验参数 规格中心线")
|
||||
private Float sl;
|
||||
|
||||
@ApiModelProperty("检验参数 规格上线")
|
||||
private Float usl;
|
||||
|
||||
@ApiModelProperty("工序id,关联 working_procedure 表id")
|
||||
private Long workingProcedureId;
|
||||
|
||||
@ApiModelProperty("分析图形,关联control_graph表id")
|
||||
private Long controlGraphId;
|
||||
|
||||
@ApiModelProperty("是否需要spc分析,1 yes;0 no")
|
||||
private Integer isSpc;
|
||||
|
||||
@ApiModelProperty("样本大小,一般2-25之间。 会依据这个size 把所有待分析的数据 组成一个一个样本")
|
||||
private Integer sampleSize;
|
||||
|
||||
@ApiModelProperty("采样频率,只用于展示")
|
||||
private String samplingFrequency;
|
||||
|
||||
@ApiModelProperty("小数位数(限制 检验参数小数点后面位数),这个先放着后续再说。")
|
||||
private Integer decimalPlaces;
|
||||
|
||||
@ApiModelProperty("目标cpk")
|
||||
private Float targetCpk;
|
||||
|
||||
@ApiModelProperty("目标cpk")
|
||||
private Float targetPpk;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,116 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 产品特性 历史表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@TableName("product_features_his")
|
||||
@ApiModel(value = "ProductFeaturesHis对象", description = "产品特性 历史表")
|
||||
public class ProductFeaturesHis implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("产品特性id,关联product_features表")
|
||||
private Long productFeaturesId;
|
||||
|
||||
@ApiModelProperty("产品id,关联product表")
|
||||
private Long productId;
|
||||
|
||||
@ApiModelProperty("产品特性 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("产品特性 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("产品特性类型:1 计量型;2 计数型")
|
||||
private Integer type;
|
||||
|
||||
@ApiModelProperty("缺陷等级:1 致命缺陷;2 严重缺陷;3.轻微缺陷")
|
||||
private Integer defectLevel;
|
||||
|
||||
@ApiModelProperty("量具id,关联measure_tool表")
|
||||
private Long measureToolId;
|
||||
|
||||
@ApiModelProperty("单位 id,关联unit表")
|
||||
private Long unitId;
|
||||
|
||||
@ApiModelProperty("产品特性 规格")
|
||||
private String specifications;
|
||||
|
||||
@ApiModelProperty("检验参数 规格下线")
|
||||
private Float lsl;
|
||||
|
||||
@ApiModelProperty("检验参数 规格中心线")
|
||||
private Float sl;
|
||||
|
||||
@ApiModelProperty("检验参数 规格上线")
|
||||
private Float usl;
|
||||
|
||||
@ApiModelProperty("工序id,关联 working_procedure 表id")
|
||||
private Long workingProcedureId;
|
||||
|
||||
@ApiModelProperty("是否需要spc分析,1 yes;0 no")
|
||||
private Integer isSpc;
|
||||
|
||||
@ApiModelProperty("分析图形,关联control_graph表id")
|
||||
private Long controlGraphId;
|
||||
|
||||
@ApiModelProperty("样本大小,一般2-25之间。 会依据这个size 把所有待分析的数据 组成一个一个样本")
|
||||
private Integer sampleSize;
|
||||
|
||||
@ApiModelProperty("采样频率,只用于展示")
|
||||
private String samplingFrequency;
|
||||
|
||||
@ApiModelProperty("小数位数(限制 检验参数小数点后面位数),这个先放着后续再说。")
|
||||
private Integer decimalPlaces;
|
||||
|
||||
@ApiModelProperty("目标cpk")
|
||||
private Float targetCpk;
|
||||
|
||||
@ApiModelProperty("目标cpk")
|
||||
private Float targetPpk;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
@@ -6,7 +6,6 @@ import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
@@ -25,7 +24,7 @@ public class ProductType implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private BigDecimal id;
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("产品类型 名")
|
||||
private String name;
|
||||
@@ -37,16 +36,16 @@ public class ProductType implements Serializable {
|
||||
private String descs;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private BigDecimal status;
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private BigDecimal valid;
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private BigDecimal creatorId;
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
@@ -55,7 +54,7 @@ public class ProductType implements Serializable {
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private BigDecimal updaterId;
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
@@ -64,7 +63,7 @@ public class ProductType implements Serializable {
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private BigDecimal version;
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,69 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import io.swagger.models.auth.In;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 工序 表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@TableName("product_workingprocedure_relation")
|
||||
@ApiModel(value = "ProductWorkingprocedureRelation对象", description = "工序 表")
|
||||
public class ProductWorkingprocedureRelation implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("产品id,关联product表")
|
||||
private Long productId;
|
||||
|
||||
@ApiModelProperty("工序id,关联 working_procedure 表")
|
||||
private Long workingProcedureId;
|
||||
|
||||
@ApiModelProperty("顺序,工序是有先后顺序的。")
|
||||
private Integer order;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
66
ym-baisc/src/main/java/com/cnbm/basic/entity/Shift.java
Normal file
66
ym-baisc/src/main/java/com/cnbm/basic/entity/Shift.java
Normal file
@@ -0,0 +1,66 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 班次 表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "Shift对象", description = "班次 表")
|
||||
public class Shift implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("班次 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("班次 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("班次 描述")
|
||||
private String descs;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
66
ym-baisc/src/main/java/com/cnbm/basic/entity/Team.java
Normal file
66
ym-baisc/src/main/java/com/cnbm/basic/entity/Team.java
Normal file
@@ -0,0 +1,66 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 班组 表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "Team对象", description = "班组 表")
|
||||
public class Team implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("班组 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("班组 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("班组 描述")
|
||||
private String descs;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
@@ -5,7 +5,6 @@ import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
@@ -23,7 +22,7 @@ public class Unit implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private BigDecimal id;
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("单位 名")
|
||||
private String name;
|
||||
@@ -32,19 +31,19 @@ public class Unit implements Serializable {
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("单位类型,1 可计数,2 不可计数")
|
||||
private BigDecimal type;
|
||||
private Integer type;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private BigDecimal status;
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private BigDecimal valid;
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private BigDecimal creatorId;
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
@@ -53,7 +52,7 @@ public class Unit implements Serializable {
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private BigDecimal updaterId;
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
@@ -62,7 +61,7 @@ public class Unit implements Serializable {
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private BigDecimal version;
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,71 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 工序 表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@TableName("working_procedure")
|
||||
@ApiModel(value = "WorkingProcedure对象", description = "工序 表")
|
||||
public class WorkingProcedure implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("工序 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("工序 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("工序类型 id,关联working_procedure_type表")
|
||||
private Long workingProcedureTypeId;
|
||||
|
||||
@ApiModelProperty("机台(也就是设备),这个工序对应的设备,可能有一个或者多个,如果多个用逗号隔开,\"id1,id2,......\"")
|
||||
private String machineId;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,65 @@
|
||||
package com.cnbm.basic.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 工序类型表 表
|
||||
* </p>
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
@TableName("working_procedure_type")
|
||||
@ApiModel(value = "WorkingProcedureType对象", description = "工序类型表 表")
|
||||
public class WorkingProcedureType implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("ID")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("工序类型 名")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty("工序类型 编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("1 可用,0 不可用")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
|
||||
@ApiModelProperty("创建人")
|
||||
private Long creatorId;
|
||||
|
||||
@ApiModelProperty("创建人姓名")
|
||||
private String creatorName;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty("更新人")
|
||||
private Long updaterId;
|
||||
|
||||
@ApiModelProperty("更新人姓名")
|
||||
private String updaterName;
|
||||
|
||||
@ApiModelProperty("更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
@ApiModelProperty("版本号")
|
||||
private Integer version;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,51 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 工厂 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
public class FactoryExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "工厂 名")
|
||||
private String name;
|
||||
@Excel(name = "工厂 编码")
|
||||
private String code;
|
||||
@Excel(name = "工厂 描述")
|
||||
private String descs;
|
||||
@Excel(name = "工厂 联系地址")
|
||||
private String address;
|
||||
@Excel(name = "工厂类型,1-内部工厂;2-供应商")
|
||||
private String type;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 机台表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
public class MachineExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "机台名")
|
||||
private String name;
|
||||
@Excel(name = "机台编码")
|
||||
private String code;
|
||||
@Excel(name = "机台id,关联platform id")
|
||||
private Long platformId;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 量具表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
public class MeasureToolExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "量具 名")
|
||||
private String name;
|
||||
@Excel(name = "量具 编码")
|
||||
private String code;
|
||||
@Excel(name = "量具类型;计量型=1 计数型=2")
|
||||
private String type;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 站点表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
public class PlatformExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "站台名")
|
||||
private String name;
|
||||
@Excel(name = "站台编码")
|
||||
private String code;
|
||||
@Excel(name = "站台分组")
|
||||
private String platformGroup;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,57 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 产品 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-11
|
||||
*/
|
||||
@Data
|
||||
public class ProductExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "产品 名")
|
||||
private String name;
|
||||
@Excel(name = "产品 编码")
|
||||
private String code;
|
||||
@Excel(name = "产品 规格")
|
||||
private String specifications;
|
||||
@Excel(name = "产品 图纸")
|
||||
private String drawing;
|
||||
@Excel(name = "描述")
|
||||
private String descs;
|
||||
@Excel(name = "产品类型id,关联product_type表")
|
||||
private Long productTypeId;
|
||||
@Excel(name = "单位 id,关联unit表")
|
||||
private Long unitId;
|
||||
@Excel(name = "检验阶段;1 进货检验、 2 过程检验、 3 成品检验、 4 出货检验;; 如果有多个用逗号隔开,比如 1,4 就代表选中了进货检验和出货检验")
|
||||
private String inspectionStage;
|
||||
@Excel(name = "检验标准")
|
||||
private String inspectionStandard;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 产品-工厂 关系表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-27
|
||||
*/
|
||||
@Data
|
||||
public class ProductFactoryRelationExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "产品id,关联product表")
|
||||
private Long productId;
|
||||
@Excel(name = "工厂id,关联 factory 表")
|
||||
private Long factoryId;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,75 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 产品特性 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
public class ProductFeaturesExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "产品id,关联product表")
|
||||
private Long productId;
|
||||
@Excel(name = "量具id,关联measure_tool表")
|
||||
private Long measureToolId;
|
||||
@Excel(name = "单位 id,关联unit表")
|
||||
private Long unitId;
|
||||
@Excel(name = "产品特性 名")
|
||||
private String name;
|
||||
@Excel(name = "产品特性 编码")
|
||||
private String code;
|
||||
@Excel(name = "产品特性类型:1 计量型;2 计数型")
|
||||
private Integer type;
|
||||
@Excel(name = "缺陷等级:1 致命缺陷;2 严重缺陷;3.轻微缺陷")
|
||||
private Integer defectLevel;
|
||||
@Excel(name = "产品特性 规格")
|
||||
private String specifications;
|
||||
@Excel(name = "检验参数 规格下线")
|
||||
private Float lsl;
|
||||
@Excel(name = "检验参数 规格中心线")
|
||||
private Float sl;
|
||||
@Excel(name = "检验参数 规格上线")
|
||||
private Float usl;
|
||||
@Excel(name = "工序id,关联 working_procedure 表id")
|
||||
private Long workingProcedureId;
|
||||
@Excel(name = "分析图形,关联control_graph表id")
|
||||
private Long controlGraphId;
|
||||
@Excel(name = "是否需要spc分析,1 yes;0 no")
|
||||
private Integer isSpc;
|
||||
@Excel(name = "样本大小,一般2-25之间。 会依据这个size 把所有待分析的数据 组成一个一个样本")
|
||||
private Integer sampleSize;
|
||||
@Excel(name = "采样频率,只用于展示")
|
||||
private String samplingFrequency;
|
||||
@Excel(name = "小数位数(限制 检验参数小数点后面位数),这个先放着后续再说。")
|
||||
private Integer decimalPlaces;
|
||||
@Excel(name = "目标cpk")
|
||||
private Float targetCpk;
|
||||
@Excel(name = "目标cpk")
|
||||
private Float targetPpk;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,77 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 产品特性 历史表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
public class ProductFeaturesHisExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "产品特性id,关联product_features表")
|
||||
private Long productFeaturesId;
|
||||
@Excel(name = "产品id,关联product表")
|
||||
private Long productId;
|
||||
@Excel(name = "产品特性 名")
|
||||
private String name;
|
||||
@Excel(name = "产品特性 编码")
|
||||
private String code;
|
||||
@Excel(name = "产品特性类型:1 计量型;2 计数型")
|
||||
private Integer type;
|
||||
@Excel(name = "缺陷等级:1 致命缺陷;2 严重缺陷;3.轻微缺陷")
|
||||
private Integer defectLevel;
|
||||
@Excel(name = "量具id,关联measure_tool表")
|
||||
private Long measureToolId;
|
||||
@Excel(name = "单位 id,关联unit表")
|
||||
private Long unitId;
|
||||
@Excel(name = "产品特性 规格")
|
||||
private String specifications;
|
||||
@Excel(name = "检验参数 规格下线")
|
||||
private Float lsl;
|
||||
@Excel(name = "检验参数 规格中心线")
|
||||
private Float sl;
|
||||
@Excel(name = "检验参数 规格上线")
|
||||
private Float usl;
|
||||
@Excel(name = "工序id,关联 working_procedure 表id")
|
||||
private Long workingProcedureId;
|
||||
@Excel(name = "是否需要spc分析,1 yes;0 no")
|
||||
private Integer isSpc;
|
||||
@Excel(name = "分析图形,关联control_graph表id")
|
||||
private Long controlGraphId;
|
||||
@Excel(name = "样本大小,一般2-25之间。 会依据这个size 把所有待分析的数据 组成一个一个样本")
|
||||
private Integer sampleSize;
|
||||
@Excel(name = "采样频率,只用于展示")
|
||||
private String samplingFrequency;
|
||||
@Excel(name = "小数位数(限制 检验参数小数点后面位数),这个先放着后续再说。")
|
||||
private Integer decimalPlaces;
|
||||
@Excel(name = "目标cpk")
|
||||
private Float targetCpk;
|
||||
@Excel(name = "目标cpk")
|
||||
private Float targetPpk;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -3,7 +3,6 @@ package com.cnbm.basic.excel;
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
@@ -15,7 +14,7 @@ import java.time.LocalDateTime;
|
||||
@Data
|
||||
public class ProductTypeExcel {
|
||||
@Excel(name = "ID")
|
||||
private BigDecimal id;
|
||||
private Long id;
|
||||
@Excel(name = "产品类型 名")
|
||||
private String name;
|
||||
@Excel(name = "产品类型 编码")
|
||||
@@ -23,24 +22,24 @@ public class ProductTypeExcel {
|
||||
@Excel(name = "描述")
|
||||
private String desc;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private BigDecimal status;
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private BigDecimal valid;
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private BigDecimal creatorId;
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private BigDecimal updaterId;
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private BigDecimal version;
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 工序 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
public class ProductWorkingprocedureRelationExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "产品id,关联product表")
|
||||
private Long productId;
|
||||
@Excel(name = "工序id,关联 working_procedure 表")
|
||||
private Long workingProcedureId;
|
||||
@Excel(name = "顺序,工序是有先后顺序的。")
|
||||
private Integer order;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
45
ym-baisc/src/main/java/com/cnbm/basic/excel/ShiftExcel.java
Normal file
45
ym-baisc/src/main/java/com/cnbm/basic/excel/ShiftExcel.java
Normal file
@@ -0,0 +1,45 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 班次 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
public class ShiftExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "班次 名")
|
||||
private String name;
|
||||
@Excel(name = "班次 编码")
|
||||
private String code;
|
||||
@Excel(name = "班次 描述")
|
||||
private String descs;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
45
ym-baisc/src/main/java/com/cnbm/basic/excel/TeamExcel.java
Normal file
45
ym-baisc/src/main/java/com/cnbm/basic/excel/TeamExcel.java
Normal file
@@ -0,0 +1,45 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 班组 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Data
|
||||
public class TeamExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "班组 名")
|
||||
private String name;
|
||||
@Excel(name = "班组 编码")
|
||||
private String code;
|
||||
@Excel(name = "班组 描述")
|
||||
private String descs;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -3,7 +3,6 @@ package com.cnbm.basic.excel;
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
@@ -15,32 +14,32 @@ import java.time.LocalDateTime;
|
||||
@Data
|
||||
public class UnitExcel {
|
||||
@Excel(name = "ID")
|
||||
private BigDecimal id;
|
||||
private Long id;
|
||||
@Excel(name = "单位 名")
|
||||
private String name;
|
||||
@Excel(name = "单位 编码")
|
||||
private String code;
|
||||
@Excel(name = "单位类型,1 可计数,2 不可计数")
|
||||
private BigDecimal type;
|
||||
private Integer type;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private BigDecimal status;
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private BigDecimal valid;
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private BigDecimal creatorId;
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private BigDecimal updaterId;
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private BigDecimal version;
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 工序 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
public class WorkingProcedureExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "工序 名")
|
||||
private String name;
|
||||
@Excel(name = "工序 编码")
|
||||
private String code;
|
||||
@Excel(name = "工序类型 id,关联working_procedure_type表")
|
||||
private Long workingProcedureTypeId;
|
||||
@Excel(name = "机台(也就是设备),这个工序对应的设备,可能有一个或者多个,如果多个用逗号隔开,\"id1,id2,......\"")
|
||||
private String machineId;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
package com.cnbm.basic.excel;
|
||||
|
||||
import cn.afterturn.easypoi.excel.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 工序类型表 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Data
|
||||
public class WorkingProcedureTypeExcel {
|
||||
@Excel(name = "ID")
|
||||
private Long id;
|
||||
@Excel(name = "工序类型 名")
|
||||
private String name;
|
||||
@Excel(name = "工序类型 编码")
|
||||
private String code;
|
||||
@Excel(name = "1 可用,0 不可用")
|
||||
private Integer status;
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
@Excel(name = "删除标志,是否有效:1 可用 0不可用")
|
||||
private Integer valid;
|
||||
@Excel(name = "创建人")
|
||||
private Long creatorId;
|
||||
@Excel(name = "创建人姓名")
|
||||
private String creatorName;
|
||||
@Excel(name = "创建时间")
|
||||
private LocalDateTime createTime;
|
||||
@Excel(name = "更新人")
|
||||
private Long updaterId;
|
||||
@Excel(name = "更新人姓名")
|
||||
private String updaterName;
|
||||
@Excel(name = "更新时间")
|
||||
private LocalDateTime updateTime;
|
||||
@Excel(name = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.Factory;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 工厂 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Mapper
|
||||
public interface FactoryMapper extends BaseDao<Factory> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.cnbm.basic.dto.MachineDTO;
|
||||
import com.cnbm.basic.vo.MachineVo;
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.Machine;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 机台表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Mapper
|
||||
public interface MachineMapper extends BaseDao<Machine> {
|
||||
PageData<MachineVo> page(Page<?> page, @Param("param") Map<String, Object> params);
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.MeasureTool;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 量具表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Mapper
|
||||
public interface MeasureToolMapper extends BaseDao<MeasureTool> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.Platform;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 站点表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Mapper
|
||||
public interface PlatformMapper extends BaseDao<Platform> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.ProductFactoryRelation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 产品-工厂 关系表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-27
|
||||
*/
|
||||
@Mapper
|
||||
public interface ProductFactoryRelationMapper extends BaseDao<ProductFactoryRelation> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.ProductFeaturesHis;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 产品特性 历史表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Mapper
|
||||
public interface ProductFeaturesHisMapper extends BaseDao<ProductFeaturesHis> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.ProductFeatures;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 产品特性 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Mapper
|
||||
public interface ProductFeaturesMapper extends BaseDao<ProductFeatures> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.cnbm.basic.dto.ProductDTO;
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.Product;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 产品 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-11
|
||||
*/
|
||||
@Mapper
|
||||
public interface ProductMapper extends BaseDao<Product> {
|
||||
// IPage<ProductDTO> page(Map<String, Object> params);
|
||||
}
|
||||
@@ -17,5 +17,5 @@ import java.util.Map;
|
||||
*/
|
||||
@Mapper
|
||||
public interface ProductTypeMapper extends BaseDao<ProductType> {
|
||||
IPage<ProductTypeDTO> page(IPage<ProductType> objectPage, @Param("param") Map<String, Object> params);
|
||||
//IPage<ProductTypeDTO> page(IPage<ProductType> objectPage, @Param("param") Map<String, Object> params);
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.ProductWorkingprocedureRelation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 工序 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Mapper
|
||||
public interface ProductWorkingprocedureRelationMapper extends BaseDao<ProductWorkingprocedureRelation> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.Shift;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 班次 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Mapper
|
||||
public interface ShiftMapper extends BaseDao<Shift> {
|
||||
|
||||
}
|
||||
16
ym-baisc/src/main/java/com/cnbm/basic/mapper/TeamMapper.java
Normal file
16
ym-baisc/src/main/java/com/cnbm/basic/mapper/TeamMapper.java
Normal file
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.Team;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 班组 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Mapper
|
||||
public interface TeamMapper extends BaseDao<Team> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.cnbm.basic.dto.WorkingProcedureDTO;
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.WorkingProcedure;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 工序 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Mapper
|
||||
public interface WorkingProcedureMapper extends BaseDao<WorkingProcedure> {
|
||||
IPage<WorkingProcedureDTO> page(Map<String, Object> params);
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.cnbm.basic.mapper;
|
||||
|
||||
import com.cnbm.common.dao.BaseDao;
|
||||
import com.cnbm.basic.entity.WorkingProcedureType;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 工序类型表 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Mapper
|
||||
public interface WorkingProcedureTypeMapper extends BaseDao<WorkingProcedureType> {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.FactoryDTO;
|
||||
import com.cnbm.basic.entity.Factory;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 工厂 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
public interface IFactoryService extends CrudService<Factory, FactoryDTO> {
|
||||
PageData<FactoryDTO> page (Map<String, Object> params);
|
||||
|
||||
FactoryDTO get(Long id);
|
||||
|
||||
void save(FactoryDTO dto);
|
||||
|
||||
void update(FactoryDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
|
||||
boolean changeStatus(Long id);
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.basic.vo.MachineVo;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.MachineDTO;
|
||||
import com.cnbm.basic.entity.Machine;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 机台表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
public interface IMachineService extends CrudService<Machine, MachineDTO> {
|
||||
PageData<MachineDTO> page (Map<String, Object> params);
|
||||
|
||||
PageData<MachineVo> page1 (Map<String, Object> params);
|
||||
|
||||
MachineDTO get(Long id);
|
||||
|
||||
void save(MachineDTO dto);
|
||||
|
||||
void update(MachineDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
|
||||
boolean changeStatus(Long id);
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.MeasureToolDTO;
|
||||
import com.cnbm.basic.entity.MeasureTool;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 量具表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
public interface IMeasureToolService extends CrudService<MeasureTool, MeasureToolDTO> {
|
||||
PageData<MeasureToolDTO> page (Map<String, Object> params);
|
||||
|
||||
MeasureToolDTO get(Long id);
|
||||
|
||||
void save(MeasureToolDTO dto);
|
||||
|
||||
void update(MeasureToolDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
|
||||
boolean changeStatus(Long id);
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.PlatformDTO;
|
||||
import com.cnbm.basic.entity.Platform;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 站点表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
public interface IPlatformService extends CrudService<Platform, PlatformDTO> {
|
||||
PageData<PlatformDTO> page (Map<String, Object> params);
|
||||
|
||||
PlatformDTO get(Long id);
|
||||
|
||||
void save(PlatformDTO dto);
|
||||
|
||||
void update(PlatformDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
|
||||
boolean changeStatus(Long id);
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.ProductFactoryRelationDTO;
|
||||
import com.cnbm.basic.entity.ProductFactoryRelation;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 产品-工厂 关系表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-27
|
||||
*/
|
||||
public interface IProductFactoryRelationService extends CrudService<ProductFactoryRelation, ProductFactoryRelationDTO> {
|
||||
|
||||
PageData<ProductFactoryRelationDTO> page (Map<String, Object> params);
|
||||
|
||||
ProductFactoryRelationDTO get(Long id);
|
||||
|
||||
void save(ProductFactoryRelationDTO dto);
|
||||
|
||||
void update(ProductFactoryRelationDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.ProductFeaturesHisDTO;
|
||||
import com.cnbm.basic.entity.ProductFeaturesHis;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 产品特性 历史表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
public interface IProductFeaturesHisService extends CrudService<ProductFeaturesHis, ProductFeaturesHisDTO> {
|
||||
PageData<ProductFeaturesHisDTO> page (Map<String, Object> params);
|
||||
|
||||
ProductFeaturesHisDTO get(Long id);
|
||||
|
||||
void save(ProductFeaturesHisDTO dto);
|
||||
|
||||
void update(ProductFeaturesHisDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.ProductFeaturesDTO;
|
||||
import com.cnbm.basic.entity.ProductFeatures;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 产品特性 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
public interface IProductFeaturesService extends CrudService<ProductFeatures, ProductFeaturesDTO> {
|
||||
PageData<ProductFeaturesDTO> page (Map<String, Object> params);
|
||||
|
||||
ProductFeaturesDTO get(Long id);
|
||||
|
||||
void save(ProductFeaturesDTO dto);
|
||||
|
||||
void update(ProductFeaturesDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.ProductDTO;
|
||||
import com.cnbm.basic.entity.Product;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 产品 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-11
|
||||
*/
|
||||
public interface IProductService extends CrudService<Product, ProductDTO> {
|
||||
PageData<ProductDTO> page (Map<String, Object> params);
|
||||
|
||||
ProductDTO get(Long id);
|
||||
|
||||
void save(ProductDTO dto);
|
||||
|
||||
void update(ProductDTO dto);
|
||||
|
||||
boolean changeStatus(Long id);
|
||||
|
||||
}
|
||||
@@ -15,4 +15,14 @@ import java.util.Map;
|
||||
*/
|
||||
public interface IProductTypeService extends CrudService<ProductType, ProductTypeDTO> {
|
||||
PageData<ProductTypeDTO> page (Map<String, Object> params);
|
||||
|
||||
ProductTypeDTO get(Long id);
|
||||
|
||||
void save(ProductTypeDTO dto);
|
||||
|
||||
void update(ProductTypeDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
|
||||
boolean changeStatus(Long id);
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.basic.dto.WorkingProcedureDTO;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.ProductWorkingprocedureRelationDTO;
|
||||
import com.cnbm.basic.entity.ProductWorkingprocedureRelation;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 工序 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
public interface IProductWorkingprocedureRelationService extends CrudService<ProductWorkingprocedureRelation, ProductWorkingprocedureRelationDTO> {
|
||||
PageData<ProductWorkingprocedureRelationDTO> page (Map<String, Object> params);
|
||||
|
||||
ProductWorkingprocedureRelationDTO get(Long id);
|
||||
|
||||
void save(ProductWorkingprocedureRelationDTO dto);
|
||||
|
||||
void update(ProductWorkingprocedureRelationDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
|
||||
List<ProductWorkingprocedureRelationDTO> getWorkingprocedureByProductId(Long productId);
|
||||
|
||||
void batchInsertWorkingprocedure(ProductWorkingprocedureRelationDTO[] lists);
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.ShiftDTO;
|
||||
import com.cnbm.basic.entity.Shift;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 班次 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
public interface IShiftService extends CrudService<Shift, ShiftDTO> {
|
||||
PageData<ShiftDTO> page (Map<String, Object> params);
|
||||
|
||||
ShiftDTO get(Long id);
|
||||
|
||||
void save(ShiftDTO dto);
|
||||
|
||||
void update(ShiftDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.TeamDTO;
|
||||
import com.cnbm.basic.entity.Team;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 班组 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
public interface ITeamService extends CrudService<Team, TeamDTO> {
|
||||
PageData<TeamDTO> page (Map<String, Object> params);
|
||||
|
||||
TeamDTO get(Long id);
|
||||
|
||||
void save(TeamDTO dto);
|
||||
|
||||
void update(TeamDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
}
|
||||
@@ -1,9 +1,12 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.UnitDTO;
|
||||
import com.cnbm.basic.entity.Unit;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 单位 表
|
||||
*
|
||||
@@ -11,5 +14,13 @@ import com.cnbm.basic.entity.Unit;
|
||||
* @since 2022-06-30
|
||||
*/
|
||||
public interface IUnitService extends CrudService<Unit, UnitDTO> {
|
||||
PageData<UnitDTO> page (Map<String, Object> params);
|
||||
|
||||
UnitDTO get(Long id);
|
||||
|
||||
void save(UnitDTO dto);
|
||||
|
||||
void update(UnitDTO dto);
|
||||
|
||||
boolean changeStatus(Long id);
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.WorkingProcedureDTO;
|
||||
import com.cnbm.basic.entity.WorkingProcedure;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 工序 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
public interface IWorkingProcedureService extends CrudService<WorkingProcedure, WorkingProcedureDTO> {
|
||||
PageData<WorkingProcedureDTO> page (Map<String, Object> params);
|
||||
|
||||
WorkingProcedureDTO get(Long id);
|
||||
|
||||
void save(WorkingProcedureDTO dto);
|
||||
|
||||
void update(WorkingProcedureDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
|
||||
boolean changeStatus(Long id);
|
||||
|
||||
List<WorkingProcedureDTO> getWorkingProcedureByProductId(Long productId);
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.cnbm.basic.service;
|
||||
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.CrudService;
|
||||
import com.cnbm.basic.dto.WorkingProcedureTypeDTO;
|
||||
import com.cnbm.basic.entity.WorkingProcedureType;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 工序类型表 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
public interface IWorkingProcedureTypeService extends CrudService<WorkingProcedureType, WorkingProcedureTypeDTO> {
|
||||
PageData<WorkingProcedureTypeDTO> page (Map<String, Object> params);
|
||||
|
||||
WorkingProcedureTypeDTO get(Long id);
|
||||
|
||||
void save(WorkingProcedureTypeDTO dto);
|
||||
|
||||
void update(WorkingProcedureTypeDTO dto);
|
||||
|
||||
void delete(Long[] ids);
|
||||
|
||||
boolean changeStatus(Long id);
|
||||
}
|
||||
@@ -0,0 +1,93 @@
|
||||
package com.cnbm.basic.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
|
||||
import com.cnbm.basic.dto.ProductTypeDTO;
|
||||
import com.cnbm.basic.entity.ProductType;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.impl.CrudServiceImpl;
|
||||
import com.cnbm.basic.dto.FactoryDTO;
|
||||
import com.cnbm.basic.mapper.FactoryMapper;
|
||||
import com.cnbm.basic.entity.Factory;
|
||||
import com.cnbm.basic.service.IFactoryService;
|
||||
import com.cnbm.common.utils.ConvertUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 工厂 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Service
|
||||
public class FactoryServiceImpl extends CrudServiceImpl<FactoryMapper, Factory, FactoryDTO> implements IFactoryService {
|
||||
|
||||
@Override
|
||||
public QueryWrapper<Factory> getWrapper(Map<String, Object> params){
|
||||
String name = (String)params.get("name");
|
||||
String code = (String)params.get("code");
|
||||
String type = (String)params.get("type");
|
||||
|
||||
QueryWrapper<Factory> wrapper = new QueryWrapper<>();
|
||||
wrapper.like(StringUtils.isNotBlank(name), "name", name);
|
||||
wrapper.like(StringUtils.isNotBlank(code), "code", code);
|
||||
wrapper.like(StringUtils.isNotBlank(type), "type", type);
|
||||
wrapper.eq(ObjectUtils.isNotNull(params.get("status")), "status", params.get("status"));
|
||||
|
||||
return wrapper;
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageData<FactoryDTO> page (Map<String, Object> params){
|
||||
IPage<Factory> page = baseDao.selectPage(
|
||||
getPage(params, "id", true),
|
||||
getWrapper(params)
|
||||
);
|
||||
return getPageData(page, FactoryDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public FactoryDTO get(Long id) {
|
||||
Factory entity = baseDao.selectById(id);
|
||||
return ConvertUtils.sourceToTarget(entity, FactoryDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void save(FactoryDTO dto) {
|
||||
Factory entity = ConvertUtils.sourceToTarget(dto, Factory.class);
|
||||
insert(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void update(FactoryDTO dto) {
|
||||
Factory entity = ConvertUtils.sourceToTarget(dto, Factory.class);
|
||||
updateById(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void delete(Long[] ids) {
|
||||
//删除
|
||||
deleteBatchIds(Arrays.asList(ids));
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public boolean changeStatus(Long id) {
|
||||
//改变状态 开启1 关闭0
|
||||
Factory entity = baseDao.selectById(id);
|
||||
Integer status = 1 - entity.getStatus();
|
||||
entity.setStatus(status);
|
||||
return updateById(entity);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,121 @@
|
||||
package com.cnbm.basic.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.cnbm.basic.entity.Platform;
|
||||
import com.cnbm.basic.vo.MachineVo;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.impl.CrudServiceImpl;
|
||||
import com.cnbm.basic.dto.MachineDTO;
|
||||
import com.cnbm.basic.mapper.MachineMapper;
|
||||
import com.cnbm.basic.entity.Machine;
|
||||
import com.cnbm.basic.service.IMachineService;
|
||||
import com.cnbm.common.utils.ConvertUtils;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 机台表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Service
|
||||
public class MachineServiceImpl extends CrudServiceImpl<MachineMapper, Machine, MachineDTO> implements IMachineService {
|
||||
|
||||
@Autowired
|
||||
private MachineMapper mapper;
|
||||
|
||||
@Override
|
||||
public QueryWrapper<Machine> getWrapper(Map<String, Object> params){
|
||||
|
||||
QueryWrapper<Machine> wrapper = new QueryWrapper<>();
|
||||
wrapper.eq(ObjectUtils.isNotNull(params.get("status")), "status", params.get("status"));
|
||||
|
||||
return wrapper;
|
||||
}
|
||||
|
||||
@Autowired
|
||||
private PlatformServiceImpl platformService;
|
||||
|
||||
@Override
|
||||
public PageData<MachineDTO> page (Map<String, Object> params) {
|
||||
IPage<Machine> page = baseDao.selectPage(
|
||||
getPage(params, "id", true),
|
||||
getWrapper(params)
|
||||
);
|
||||
PageData<MachineDTO> machineDTOPageData = getPageData(page, MachineDTO.class);
|
||||
|
||||
if (!machineDTOPageData.getList().isEmpty()) {
|
||||
|
||||
for (MachineDTO machineDTO : machineDTOPageData.getList()) {
|
||||
Platform platform = platformService.selectById(machineDTO.getPlatformId());
|
||||
String platformName = null;
|
||||
if (platformName != null) {
|
||||
platformName = platform.getName();
|
||||
|
||||
}
|
||||
machineDTO.setPlatformName(platformName);
|
||||
}
|
||||
}
|
||||
return machineDTOPageData;
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageData<MachineVo> page1 (Map<String, Object> params){
|
||||
// IPage<Machine> page = baseDao.selectPage(
|
||||
// getPage(params, "id", true),
|
||||
// getWrapper(params)
|
||||
// );
|
||||
return mapper.page(new Page<>(Integer.parseInt(params.get("page").toString()), Integer.parseInt(params.get("limit").toString())),
|
||||
params);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public MachineDTO get(Long id) {
|
||||
Machine entity = baseDao.selectById(id);
|
||||
return ConvertUtils.sourceToTarget(entity, MachineDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void save(MachineDTO dto) {
|
||||
Machine entity = ConvertUtils.sourceToTarget(dto, Machine.class);
|
||||
insert(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void update(MachineDTO dto) {
|
||||
Machine entity = ConvertUtils.sourceToTarget(dto, Machine.class);
|
||||
updateById(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void delete(Long[] ids) {
|
||||
//删除
|
||||
deleteBatchIds(Arrays.asList(ids));
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public boolean changeStatus(Long id) {
|
||||
//改变状态 开启1 关闭0
|
||||
Machine entity = baseDao.selectById(id);
|
||||
Integer status = 1 - entity.getStatus();
|
||||
entity.setStatus(status);
|
||||
return updateById(entity);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,81 @@
|
||||
package com.cnbm.basic.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.impl.CrudServiceImpl;
|
||||
import com.cnbm.basic.dto.MeasureToolDTO;
|
||||
import com.cnbm.basic.mapper.MeasureToolMapper;
|
||||
import com.cnbm.basic.entity.MeasureTool;
|
||||
import com.cnbm.basic.service.IMeasureToolService;
|
||||
import com.cnbm.common.utils.ConvertUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 量具表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Service
|
||||
public class MeasureToolServiceImpl extends CrudServiceImpl<MeasureToolMapper, MeasureTool, MeasureToolDTO> implements IMeasureToolService {
|
||||
|
||||
@Override
|
||||
public QueryWrapper<MeasureTool> getWrapper(Map<String, Object> params){
|
||||
String name = (String)params.get("name");
|
||||
String code = (String)params.get("code");
|
||||
|
||||
QueryWrapper<MeasureTool> wrapper = new QueryWrapper<>();
|
||||
wrapper.like(StringUtils.isNotBlank(name), "name", name);
|
||||
wrapper.like(StringUtils.isNotBlank(code), "code", code);
|
||||
wrapper.eq(ObjectUtils.isNotNull(params.get("status")), "status", params.get("status"));
|
||||
|
||||
return wrapper;
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageData<MeasureToolDTO> page (Map<String, Object> params){
|
||||
IPage<MeasureTool> page = baseDao.selectPage(
|
||||
getPage(params, "id", true),
|
||||
getWrapper(params)
|
||||
);
|
||||
return getPageData(page, MeasureToolDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public MeasureToolDTO get(Long id) {
|
||||
MeasureTool entity = baseDao.selectById(id);
|
||||
return ConvertUtils.sourceToTarget(entity, MeasureToolDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void save(MeasureToolDTO dto) {
|
||||
MeasureTool entity = ConvertUtils.sourceToTarget(dto, MeasureTool.class);
|
||||
insert(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void update(MeasureToolDTO dto) {
|
||||
MeasureTool entity = ConvertUtils.sourceToTarget(dto, MeasureTool.class);
|
||||
updateById(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public boolean changeStatus(Long id) {
|
||||
//改变状态 开启1 关闭0
|
||||
MeasureTool entity = baseDao.selectById(id);
|
||||
Integer status = 1 - entity.getStatus();
|
||||
entity.setStatus(status);
|
||||
return updateById(entity);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,86 @@
|
||||
package com.cnbm.basic.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.impl.CrudServiceImpl;
|
||||
import com.cnbm.basic.dto.PlatformDTO;
|
||||
import com.cnbm.basic.mapper.PlatformMapper;
|
||||
import com.cnbm.basic.entity.Platform;
|
||||
import com.cnbm.basic.service.IPlatformService;
|
||||
import com.cnbm.common.utils.ConvertUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 站点表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-13
|
||||
*/
|
||||
@Service
|
||||
public class PlatformServiceImpl extends CrudServiceImpl<PlatformMapper, Platform, PlatformDTO> implements IPlatformService {
|
||||
|
||||
@Override
|
||||
public QueryWrapper<Platform> getWrapper(Map<String, Object> params){
|
||||
|
||||
QueryWrapper<Platform> wrapper = new QueryWrapper<>();
|
||||
wrapper.eq(ObjectUtils.isNotNull(params.get("status")), "status", params.get("status"));
|
||||
|
||||
return wrapper;
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageData<PlatformDTO> page (Map<String, Object> params){
|
||||
IPage<Platform> page = baseDao.selectPage(
|
||||
getPage(params, "id", true),
|
||||
getWrapper(params)
|
||||
);
|
||||
return getPageData(page, PlatformDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PlatformDTO get(Long id) {
|
||||
Platform entity = baseDao.selectById(id);
|
||||
return ConvertUtils.sourceToTarget(entity, PlatformDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void save(PlatformDTO dto) {
|
||||
Platform entity = ConvertUtils.sourceToTarget(dto, Platform.class);
|
||||
insert(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void update(PlatformDTO dto) {
|
||||
Platform entity = ConvertUtils.sourceToTarget(dto, Platform.class);
|
||||
updateById(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void delete(Long[] ids) {
|
||||
//删除
|
||||
deleteBatchIds(Arrays.asList(ids));
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public boolean changeStatus(Long id) {
|
||||
//改变状态 开启1 关闭0
|
||||
Platform entity = baseDao.selectById(id);
|
||||
Integer status = 1 - entity.getStatus();
|
||||
entity.setStatus(status);
|
||||
return updateById(entity);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,74 @@
|
||||
package com.cnbm.basic.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.impl.CrudServiceImpl;
|
||||
import com.cnbm.basic.dto.ProductFactoryRelationDTO;
|
||||
import com.cnbm.basic.mapper.ProductFactoryRelationMapper;
|
||||
import com.cnbm.basic.entity.ProductFactoryRelation;
|
||||
import com.cnbm.basic.service.IProductFactoryRelationService;
|
||||
import com.cnbm.common.utils.ConvertUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 产品-工厂 关系表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-27
|
||||
*/
|
||||
@Service
|
||||
public class ProductFactoryRelationServiceImpl extends CrudServiceImpl<ProductFactoryRelationMapper, ProductFactoryRelation, ProductFactoryRelationDTO> implements IProductFactoryRelationService {
|
||||
|
||||
@Override
|
||||
public QueryWrapper<ProductFactoryRelation> getWrapper(Map<String, Object> params){
|
||||
String id = (String)params.get("id");
|
||||
|
||||
QueryWrapper<ProductFactoryRelation> wrapper = new QueryWrapper<>();
|
||||
wrapper.eq(StringUtils.isNotBlank(id), "id", id);
|
||||
|
||||
return wrapper;
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageData<ProductFactoryRelationDTO> page (Map<String, Object> params){
|
||||
IPage<ProductFactoryRelation> page = baseDao.selectPage(
|
||||
getPage(params, "id", true),
|
||||
getWrapper(params)
|
||||
);
|
||||
return getPageData(page, ProductFactoryRelationDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ProductFactoryRelationDTO get(Long id) {
|
||||
ProductFactoryRelation entity = baseDao.selectById(id);
|
||||
return ConvertUtils.sourceToTarget(entity, ProductFactoryRelationDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void save(ProductFactoryRelationDTO dto) {
|
||||
ProductFactoryRelation entity = ConvertUtils.sourceToTarget(dto, ProductFactoryRelation.class);
|
||||
insert(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void update(ProductFactoryRelationDTO dto) {
|
||||
ProductFactoryRelation entity = ConvertUtils.sourceToTarget(dto, ProductFactoryRelation.class);
|
||||
updateById(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void delete(Long[] ids) {
|
||||
//删除
|
||||
deleteBatchIds(Arrays.asList(ids));
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,67 @@
|
||||
package com.cnbm.basic.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.impl.CrudServiceImpl;
|
||||
import com.cnbm.basic.dto.ProductFeaturesHisDTO;
|
||||
import com.cnbm.basic.mapper.ProductFeaturesHisMapper;
|
||||
import com.cnbm.basic.entity.ProductFeaturesHis;
|
||||
import com.cnbm.basic.service.IProductFeaturesHisService;
|
||||
import com.cnbm.common.utils.ConvertUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 产品特性 历史表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Service
|
||||
public class ProductFeaturesHisServiceImpl extends CrudServiceImpl<ProductFeaturesHisMapper, ProductFeaturesHis, ProductFeaturesHisDTO> implements IProductFeaturesHisService {
|
||||
|
||||
@Override
|
||||
public QueryWrapper<ProductFeaturesHis> getWrapper(Map<String, Object> params){
|
||||
String id = (String)params.get("id");
|
||||
|
||||
QueryWrapper<ProductFeaturesHis> wrapper = new QueryWrapper<>();
|
||||
wrapper.eq(StringUtils.isNotBlank(id), "id", id);
|
||||
|
||||
return wrapper;
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageData<ProductFeaturesHisDTO> page (Map<String, Object> params){
|
||||
IPage<ProductFeaturesHis> page = baseDao.selectPage(
|
||||
getPage(params, "id", true),
|
||||
getWrapper(params)
|
||||
);
|
||||
return getPageData(page, ProductFeaturesHisDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ProductFeaturesHisDTO get(Long id) {
|
||||
ProductFeaturesHis entity = baseDao.selectById(id);
|
||||
return ConvertUtils.sourceToTarget(entity, ProductFeaturesHisDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void save(ProductFeaturesHisDTO dto) {
|
||||
ProductFeaturesHis entity = ConvertUtils.sourceToTarget(dto, ProductFeaturesHis.class);
|
||||
insert(entity);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void update(ProductFeaturesHisDTO dto) {
|
||||
ProductFeaturesHis entity = ConvertUtils.sourceToTarget(dto, ProductFeaturesHis.class);
|
||||
updateById(entity);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,80 @@
|
||||
package com.cnbm.basic.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.cnbm.basic.dto.ProductFeaturesHisDTO;
|
||||
import com.cnbm.basic.entity.ProductFeaturesHis;
|
||||
import com.cnbm.common.page.PageData;
|
||||
import com.cnbm.common.service.impl.CrudServiceImpl;
|
||||
import com.cnbm.basic.dto.ProductFeaturesDTO;
|
||||
import com.cnbm.basic.mapper.ProductFeaturesMapper;
|
||||
import com.cnbm.basic.entity.ProductFeatures;
|
||||
import com.cnbm.basic.service.IProductFeaturesService;
|
||||
import com.cnbm.common.utils.ConvertUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 产品特性 表
|
||||
*
|
||||
* @author why
|
||||
* @since 2022-07-15
|
||||
*/
|
||||
@Service
|
||||
public class ProductFeaturesServiceImpl extends CrudServiceImpl<ProductFeaturesMapper, ProductFeatures, ProductFeaturesDTO> implements IProductFeaturesService {
|
||||
|
||||
@Override
|
||||
public QueryWrapper<ProductFeatures> getWrapper(Map<String, Object> params){
|
||||
String id = (String)params.get("id");
|
||||
|
||||
QueryWrapper<ProductFeatures> wrapper = new QueryWrapper<>();
|
||||
wrapper.eq(StringUtils.isNotBlank(id), "id", id);
|
||||
|
||||
return wrapper;
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageData<ProductFeaturesDTO> page (Map<String, Object> params){
|
||||
IPage<ProductFeatures> page = baseDao.selectPage(
|
||||
getPage(params, "id", true),
|
||||
getWrapper(params)
|
||||
);
|
||||
return getPageData(page, ProductFeaturesDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ProductFeaturesDTO get(Long id) {
|
||||
ProductFeatures entity = baseDao.selectById(id);
|
||||
return ConvertUtils.sourceToTarget(entity, ProductFeaturesDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void save(ProductFeaturesDTO dto) {
|
||||
ProductFeatures entity = ConvertUtils.sourceToTarget(dto, ProductFeatures.class);
|
||||
insert(entity);
|
||||
}
|
||||
|
||||
@Autowired
|
||||
private ProductFeaturesHisServiceImpl productFeaturesHisServiceImpl;
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void update(ProductFeaturesDTO dto) {
|
||||
//当产品特性出现update的时候,就会把旧数据 全量备份到这张表
|
||||
ProductFeatures oentity = baseDao.selectById(dto.getId());
|
||||
ProductFeaturesHisDTO history = ConvertUtils.sourceToTarget(oentity, ProductFeaturesHisDTO.class);
|
||||
history.setProductFeaturesId(oentity.getId());
|
||||
history.setId(null);
|
||||
productFeaturesHisServiceImpl.save(history);
|
||||
//更新
|
||||
ProductFeatures entity = ConvertUtils.sourceToTarget(dto, ProductFeatures.class);
|
||||
updateById(entity);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user