#新增
1. 新增组拖工作档
2. 新增组拖工作档明细
| | |
| | | // generator.username="sa"; |
| | | // generator.password="Zoneyung@zy56$"; |
| | | |
| | | generator.table="man_device_site"; |
| | | generator.tableDesc="device sites"; |
| | | generator.table="man_wait_pakin_item"; |
| | | generator.tableDesc="组拖档明细"; |
| | | generator.packagePath="com.vincent.rsf.server.manager"; |
| | | |
| | | generator.build(); |
New file |
| | |
| | | package com.vincent.rsf.server.manager.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.vincent.rsf.framework.common.Cools; |
| | | import com.vincent.rsf.framework.common.R; |
| | | import com.vincent.rsf.server.common.utils.ExcelUtil; |
| | | import com.vincent.rsf.server.common.annotation.OperationLog; |
| | | import com.vincent.rsf.server.common.domain.BaseParam; |
| | | import com.vincent.rsf.server.common.domain.KeyValVo; |
| | | import com.vincent.rsf.server.common.domain.PageParam; |
| | | import com.vincent.rsf.server.manager.entity.WaitPakin; |
| | | import com.vincent.rsf.server.manager.service.WaitPakinService; |
| | | import com.vincent.rsf.server.system.controller.BaseController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.*; |
| | | |
| | | @RestController |
| | | public class WaitPakinController extends BaseController { |
| | | |
| | | @Autowired |
| | | private WaitPakinService waitPakinService; |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakin:list')") |
| | | @PostMapping("/waitPakin/page") |
| | | public R page(@RequestBody Map<String, Object> map) { |
| | | BaseParam baseParam = buildParam(map, BaseParam.class); |
| | | PageParam<WaitPakin, BaseParam> pageParam = new PageParam<>(baseParam, WaitPakin.class); |
| | | return R.ok().add(waitPakinService.page(pageParam, pageParam.buildWrapper(true))); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakin:list')") |
| | | @PostMapping("/waitPakin/list") |
| | | public R list(@RequestBody Map<String, Object> map) { |
| | | return R.ok().add(waitPakinService.list()); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakin:list')") |
| | | @PostMapping({"/waitPakin/many/{ids}", "/waitPakins/many/{ids}"}) |
| | | public R many(@PathVariable Long[] ids) { |
| | | return R.ok().add(waitPakinService.listByIds(Arrays.asList(ids))); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakin:list')") |
| | | @GetMapping("/waitPakin/{id}") |
| | | public R get(@PathVariable("id") Long id) { |
| | | return R.ok().add(waitPakinService.getById(id)); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakin:save')") |
| | | @OperationLog("Create 组拖档") |
| | | @PostMapping("/waitPakin/save") |
| | | public R save(@RequestBody WaitPakin waitPakin) { |
| | | waitPakin.setCreateBy(getLoginUserId()); |
| | | waitPakin.setCreateTime(new Date()); |
| | | waitPakin.setUpdateBy(getLoginUserId()); |
| | | waitPakin.setUpdateTime(new Date()); |
| | | if (!waitPakinService.save(waitPakin)) { |
| | | return R.error("Save Fail"); |
| | | } |
| | | return R.ok("Save Success").add(waitPakin); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakin:update')") |
| | | @OperationLog("Update 组拖档") |
| | | @PostMapping("/waitPakin/update") |
| | | public R update(@RequestBody WaitPakin waitPakin) { |
| | | waitPakin.setUpdateBy(getLoginUserId()); |
| | | waitPakin.setUpdateTime(new Date()); |
| | | if (!waitPakinService.updateById(waitPakin)) { |
| | | return R.error("Update Fail"); |
| | | } |
| | | return R.ok("Update Success").add(waitPakin); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakin:remove')") |
| | | @OperationLog("Delete 组拖档") |
| | | @PostMapping("/waitPakin/remove/{ids}") |
| | | public R remove(@PathVariable Long[] ids) { |
| | | if (!waitPakinService.removeByIds(Arrays.asList(ids))) { |
| | | return R.error("Delete Fail"); |
| | | } |
| | | return R.ok("Delete Success").add(ids); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakin:list')") |
| | | @PostMapping("/waitPakin/query") |
| | | public R query(@RequestParam(required = false) String condition) { |
| | | List<KeyValVo> vos = new ArrayList<>(); |
| | | LambdaQueryWrapper<WaitPakin> wrapper = new LambdaQueryWrapper<>(); |
| | | if (!Cools.isEmpty(condition)) { |
| | | wrapper.like(WaitPakin::getId, condition); |
| | | } |
| | | waitPakinService.page(new Page<>(1, 30), wrapper).getRecords().forEach( |
| | | item -> vos.add(new KeyValVo(item.getId(), item.getId())) |
| | | ); |
| | | return R.ok().add(vos); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakin:list')") |
| | | @PostMapping("/waitPakin/export") |
| | | public void export(@RequestBody Map<String, Object> map, HttpServletResponse response) throws Exception { |
| | | ExcelUtil.build(ExcelUtil.create(waitPakinService.list(), WaitPakin.class), response); |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.vincent.rsf.server.manager.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.vincent.rsf.framework.common.Cools; |
| | | import com.vincent.rsf.framework.common.R; |
| | | import com.vincent.rsf.server.common.utils.ExcelUtil; |
| | | import com.vincent.rsf.server.common.annotation.OperationLog; |
| | | import com.vincent.rsf.server.common.domain.BaseParam; |
| | | import com.vincent.rsf.server.common.domain.KeyValVo; |
| | | import com.vincent.rsf.server.common.domain.PageParam; |
| | | import com.vincent.rsf.server.manager.entity.WaitPakinItem; |
| | | import com.vincent.rsf.server.manager.service.WaitPakinItemService; |
| | | import com.vincent.rsf.server.system.controller.BaseController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.*; |
| | | |
| | | @RestController |
| | | public class WaitPakinItemController extends BaseController { |
| | | |
| | | @Autowired |
| | | private WaitPakinItemService waitPakinItemService; |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakinItem:list')") |
| | | @PostMapping("/waitPakinItem/page") |
| | | public R page(@RequestBody Map<String, Object> map) { |
| | | BaseParam baseParam = buildParam(map, BaseParam.class); |
| | | PageParam<WaitPakinItem, BaseParam> pageParam = new PageParam<>(baseParam, WaitPakinItem.class); |
| | | return R.ok().add(waitPakinItemService.page(pageParam, pageParam.buildWrapper(true))); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakinItem:list')") |
| | | @PostMapping("/waitPakinItem/list") |
| | | public R list(@RequestBody Map<String, Object> map) { |
| | | return R.ok().add(waitPakinItemService.list()); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakinItem:list')") |
| | | @PostMapping({"/waitPakinItem/many/{ids}", "/waitPakinItems/many/{ids}"}) |
| | | public R many(@PathVariable Long[] ids) { |
| | | return R.ok().add(waitPakinItemService.listByIds(Arrays.asList(ids))); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakinItem:list')") |
| | | @GetMapping("/waitPakinItem/{id}") |
| | | public R get(@PathVariable("id") Long id) { |
| | | return R.ok().add(waitPakinItemService.getById(id)); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakinItem:save')") |
| | | @OperationLog("Create 组拖档明细") |
| | | @PostMapping("/waitPakinItem/save") |
| | | public R save(@RequestBody WaitPakinItem waitPakinItem) { |
| | | waitPakinItem.setCreateBy(getLoginUserId()); |
| | | waitPakinItem.setCreateTime(new Date()); |
| | | waitPakinItem.setUpdateBy(getLoginUserId()); |
| | | waitPakinItem.setUpdateTime(new Date()); |
| | | if (!waitPakinItemService.save(waitPakinItem)) { |
| | | return R.error("Save Fail"); |
| | | } |
| | | return R.ok("Save Success").add(waitPakinItem); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakinItem:update')") |
| | | @OperationLog("Update 组拖档明细") |
| | | @PostMapping("/waitPakinItem/update") |
| | | public R update(@RequestBody WaitPakinItem waitPakinItem) { |
| | | waitPakinItem.setUpdateBy(getLoginUserId()); |
| | | waitPakinItem.setUpdateTime(new Date()); |
| | | if (!waitPakinItemService.updateById(waitPakinItem)) { |
| | | return R.error("Update Fail"); |
| | | } |
| | | return R.ok("Update Success").add(waitPakinItem); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakinItem:remove')") |
| | | @OperationLog("Delete 组拖档明细") |
| | | @PostMapping("/waitPakinItem/remove/{ids}") |
| | | public R remove(@PathVariable Long[] ids) { |
| | | if (!waitPakinItemService.removeByIds(Arrays.asList(ids))) { |
| | | return R.error("Delete Fail"); |
| | | } |
| | | return R.ok("Delete Success").add(ids); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakinItem:list')") |
| | | @PostMapping("/waitPakinItem/query") |
| | | public R query(@RequestParam(required = false) String condition) { |
| | | List<KeyValVo> vos = new ArrayList<>(); |
| | | LambdaQueryWrapper<WaitPakinItem> wrapper = new LambdaQueryWrapper<>(); |
| | | if (!Cools.isEmpty(condition)) { |
| | | wrapper.like(WaitPakinItem::getId, condition); |
| | | } |
| | | waitPakinItemService.page(new Page<>(1, 30), wrapper).getRecords().forEach( |
| | | item -> vos.add(new KeyValVo(item.getId(), item.getId())) |
| | | ); |
| | | return R.ok().add(vos); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:waitPakinItem:list')") |
| | | @PostMapping("/waitPakinItem/export") |
| | | public void export(@RequestBody Map<String, Object> map, HttpServletResponse response) throws Exception { |
| | | ExcelUtil.build(ExcelUtil.create(waitPakinItemService.list(), WaitPakinItem.class), response); |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.vincent.rsf.server.manager.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Date; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import com.vincent.rsf.framework.common.Cools; |
| | | import com.vincent.rsf.framework.common.SpringUtils; |
| | | import com.vincent.rsf.server.system.service.UserService; |
| | | import com.vincent.rsf.server.system.entity.User; |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @Data |
| | | @TableName("man_wait_pakin") |
| | | public class WaitPakin implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * ID |
| | | */ |
| | | @ApiModelProperty(value= "ID") |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 编码 |
| | | */ |
| | | @ApiModelProperty(value= "编码") |
| | | private String code; |
| | | |
| | | /** |
| | | * 订单ID |
| | | */ |
| | | @ApiModelProperty(value= "订单ID") |
| | | private Long ansId; |
| | | |
| | | /** |
| | | * 订单编码 |
| | | */ |
| | | @ApiModelProperty(value= "订单编码") |
| | | private String asnCode; |
| | | |
| | | /** |
| | | * 容器码 |
| | | */ |
| | | @ApiModelProperty(value= "容器码") |
| | | private String barcode; |
| | | |
| | | /** |
| | | * 组拖数量 |
| | | */ |
| | | @ApiModelProperty(value= "组拖数量") |
| | | private Double anfme; |
| | | |
| | | /** |
| | | * 组拖状态 0: 待入库 1: 入库中 |
| | | */ |
| | | @ApiModelProperty(value= "组拖状态 0: 待入库 1: 入库中 ") |
| | | private Short ioStatus; |
| | | |
| | | /** |
| | | * 状态 1: 正常 0: 冻结 |
| | | */ |
| | | @ApiModelProperty(value= "状态 1: 正常 0: 冻结 ") |
| | | private Integer status; |
| | | |
| | | /** |
| | | * 是否删除 1: 是 0: 否 |
| | | */ |
| | | @ApiModelProperty(value= "是否删除 1: 是 0: 否 ") |
| | | @TableLogic |
| | | private Integer deleted; |
| | | |
| | | /** |
| | | * 租户 |
| | | */ |
| | | @ApiModelProperty(value= "租户") |
| | | private Integer tenantId; |
| | | |
| | | /** |
| | | * 添加人员 |
| | | */ |
| | | @ApiModelProperty(value= "添加人员") |
| | | private Long createBy; |
| | | |
| | | /** |
| | | * 添加时间 |
| | | */ |
| | | @ApiModelProperty(value= "添加时间") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | |
| | | /** |
| | | * 修改人员 |
| | | */ |
| | | @ApiModelProperty(value= "修改人员") |
| | | private Long updateBy; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | @ApiModelProperty(value= "修改时间") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | |
| | | /** |
| | | * 备注 |
| | | */ |
| | | @ApiModelProperty(value= "备注") |
| | | private String memo; |
| | | |
| | | public WaitPakin() {} |
| | | |
| | | public WaitPakin(String code,Long ansId,String asnCode,String barcode,Double anfme,Short ioStatus,Integer status,Integer deleted,Integer tenantId,Long createBy,Date createTime,Long updateBy,Date updateTime,String memo) { |
| | | this.code = code; |
| | | this.ansId = ansId; |
| | | this.asnCode = asnCode; |
| | | this.barcode = barcode; |
| | | this.anfme = anfme; |
| | | this.ioStatus = ioStatus; |
| | | this.status = status; |
| | | this.deleted = deleted; |
| | | this.tenantId = tenantId; |
| | | this.createBy = createBy; |
| | | this.createTime = createTime; |
| | | this.updateBy = updateBy; |
| | | this.updateTime = updateTime; |
| | | this.memo = memo; |
| | | } |
| | | |
| | | // WaitPakin waitPakin = new WaitPakin( |
| | | // null, // 编码 |
| | | // null, // 订单ID |
| | | // null, // 订单编码 |
| | | // null, // 容器码 |
| | | // null, // 组拖数量 |
| | | // null, // 组拖状态 |
| | | // null, // 状态[非空] |
| | | // null, // 是否删除[非空] |
| | | // null, // 租户 |
| | | // null, // 添加人员 |
| | | // null, // 添加时间[非空] |
| | | // null, // 修改人员 |
| | | // null, // 修改时间[非空] |
| | | // null // 备注 |
| | | // ); |
| | | |
| | | public String getIoStatus$(){ |
| | | if (null == this.ioStatus){ return null; } |
| | | switch (this.ioStatus){ |
| | | case 0: |
| | | return "待入库"; |
| | | case 1: |
| | | return " 入库中"; |
| | | default: |
| | | return String.valueOf(this.ioStatus); |
| | | } |
| | | } |
| | | |
| | | public String getStatus$(){ |
| | | if (null == this.status){ return null; } |
| | | switch (this.status){ |
| | | case 1: |
| | | return "正常"; |
| | | case 0: |
| | | return "冻结"; |
| | | default: |
| | | return String.valueOf(this.status); |
| | | } |
| | | } |
| | | |
| | | public String getCreateBy$(){ |
| | | UserService service = SpringUtils.getBean(UserService.class); |
| | | User user = service.getById(this.createBy); |
| | | if (!Cools.isEmpty(user)){ |
| | | return String.valueOf(user.getNickname()); |
| | | } |
| | | return null; |
| | | } |
| | | |
| | | public String getCreateTime$(){ |
| | | if (Cools.isEmpty(this.createTime)){ |
| | | return ""; |
| | | } |
| | | return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.createTime); |
| | | } |
| | | |
| | | public String getUpdateBy$(){ |
| | | UserService service = SpringUtils.getBean(UserService.class); |
| | | User user = service.getById(this.updateBy); |
| | | if (!Cools.isEmpty(user)){ |
| | | return String.valueOf(user.getNickname()); |
| | | } |
| | | return null; |
| | | } |
| | | |
| | | public String getUpdateTime$(){ |
| | | if (Cools.isEmpty(this.updateTime)){ |
| | | return ""; |
| | | } |
| | | return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.updateTime); |
| | | } |
| | | |
| | | |
| | | |
| | | public Boolean getStatusBool(){ |
| | | if (null == this.status){ return null; } |
| | | switch (this.status){ |
| | | case 1: |
| | | return true; |
| | | case 0: |
| | | return false; |
| | | default: |
| | | return null; |
| | | } |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.vincent.rsf.server.manager.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Date; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Date; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import com.vincent.rsf.framework.common.Cools; |
| | | import com.vincent.rsf.framework.common.SpringUtils; |
| | | import com.vincent.rsf.server.system.service.UserService; |
| | | import com.vincent.rsf.server.system.entity.User; |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @Data |
| | | @TableName("man_wait_pakin_item") |
| | | public class WaitPakinItem implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * ID |
| | | */ |
| | | @ApiModelProperty(value= "ID") |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 主单ID |
| | | */ |
| | | @ApiModelProperty(value= "主单ID") |
| | | private Long pakinId; |
| | | |
| | | /** |
| | | * 物料名称 |
| | | */ |
| | | @ApiModelProperty(value= "物料名称") |
| | | private String maktx; |
| | | |
| | | /** |
| | | * 物料ID |
| | | */ |
| | | @ApiModelProperty(value= "物料ID") |
| | | private Long matnrId; |
| | | |
| | | /** |
| | | * 物料编码 |
| | | */ |
| | | @ApiModelProperty(value= "物料编码") |
| | | private String matnrCode; |
| | | |
| | | /** |
| | | * 数量 |
| | | */ |
| | | @ApiModelProperty(value= "数量") |
| | | private Double anfme; |
| | | |
| | | /** |
| | | * 执行中数量 |
| | | */ |
| | | @ApiModelProperty(value= "执行中数量") |
| | | private Double workQty; |
| | | |
| | | /** |
| | | * 单位 |
| | | */ |
| | | @ApiModelProperty(value= "单位") |
| | | private String unit; |
| | | |
| | | /** |
| | | * 扩展字段标识 |
| | | */ |
| | | @ApiModelProperty(value= "扩展字段标识") |
| | | private String fieldsIndex; |
| | | |
| | | /** |
| | | * 已完成数量 |
| | | */ |
| | | @ApiModelProperty(value= "已完成数量") |
| | | private Double qty; |
| | | |
| | | /** |
| | | * 批次号 |
| | | */ |
| | | @ApiModelProperty(value= "批次号") |
| | | private String batch; |
| | | |
| | | /** |
| | | * 状态 1: 正常 0: 冻结 |
| | | */ |
| | | @ApiModelProperty(value= "状态 1: 正常 0: 冻结 ") |
| | | private Integer status; |
| | | |
| | | /** |
| | | * 是否删除 1: 是 0: 否 |
| | | */ |
| | | @ApiModelProperty(value= "是否删除 1: 是 0: 否 ") |
| | | @TableLogic |
| | | private Integer deleted; |
| | | |
| | | /** |
| | | * 租户 |
| | | */ |
| | | @ApiModelProperty(value= "租户") |
| | | private Integer tenantId; |
| | | |
| | | /** |
| | | * 添加人员 |
| | | */ |
| | | @ApiModelProperty(value= "添加人员") |
| | | private Long createBy; |
| | | |
| | | /** |
| | | * 添加时间 |
| | | */ |
| | | @ApiModelProperty(value= "添加时间") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | |
| | | /** |
| | | * 修改人员 |
| | | */ |
| | | @ApiModelProperty(value= "修改人员") |
| | | private Long updateBy; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | @ApiModelProperty(value= "修改时间") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | |
| | | /** |
| | | * 备注 |
| | | */ |
| | | @ApiModelProperty(value= "备注") |
| | | private String memo; |
| | | |
| | | public WaitPakinItem() {} |
| | | |
| | | public WaitPakinItem(Long pakinId,String maktx,Long matnrId,String matnrCode,Double anfme,Double workQty,String unit,String fieldsIndex,Double qty,String batch,Integer status,Integer deleted,Integer tenantId,Long createBy,Date createTime,Long updateBy,Date updateTime,String memo) { |
| | | this.pakinId = pakinId; |
| | | this.maktx = maktx; |
| | | this.matnrId = matnrId; |
| | | this.matnrCode = matnrCode; |
| | | this.anfme = anfme; |
| | | this.workQty = workQty; |
| | | this.unit = unit; |
| | | this.fieldsIndex = fieldsIndex; |
| | | this.qty = qty; |
| | | this.batch = batch; |
| | | this.status = status; |
| | | this.deleted = deleted; |
| | | this.tenantId = tenantId; |
| | | this.createBy = createBy; |
| | | this.createTime = createTime; |
| | | this.updateBy = updateBy; |
| | | this.updateTime = updateTime; |
| | | this.memo = memo; |
| | | } |
| | | |
| | | // WaitPakinItem waitPakinItem = new WaitPakinItem( |
| | | // null, // 主单ID |
| | | // null, // 物料名称 |
| | | // null, // 物料ID |
| | | // null, // 物料编码 |
| | | // null, // 数量 |
| | | // null, // 执行中数量 |
| | | // null, // 单位 |
| | | // null, // 扩展字段标识 |
| | | // null, // 已完成数量 |
| | | // null, // 批次号 |
| | | // null, // 状态[非空] |
| | | // null, // 是否删除[非空] |
| | | // null, // 租户 |
| | | // null, // 添加人员 |
| | | // null, // 添加时间[非空] |
| | | // null, // 修改人员 |
| | | // null, // 修改时间[非空] |
| | | // null // 备注 |
| | | // ); |
| | | |
| | | public String getStatus$(){ |
| | | if (null == this.status){ return null; } |
| | | switch (this.status){ |
| | | case 1: |
| | | return "正常"; |
| | | case 0: |
| | | return "冻结"; |
| | | default: |
| | | return String.valueOf(this.status); |
| | | } |
| | | } |
| | | |
| | | public String getCreateBy$(){ |
| | | UserService service = SpringUtils.getBean(UserService.class); |
| | | User user = service.getById(this.createBy); |
| | | if (!Cools.isEmpty(user)){ |
| | | return String.valueOf(user.getNickname()); |
| | | } |
| | | return null; |
| | | } |
| | | |
| | | public String getCreateTime$(){ |
| | | if (Cools.isEmpty(this.createTime)){ |
| | | return ""; |
| | | } |
| | | return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.createTime); |
| | | } |
| | | |
| | | public String getUpdateBy$(){ |
| | | UserService service = SpringUtils.getBean(UserService.class); |
| | | User user = service.getById(this.updateBy); |
| | | if (!Cools.isEmpty(user)){ |
| | | return String.valueOf(user.getNickname()); |
| | | } |
| | | return null; |
| | | } |
| | | |
| | | public String getUpdateTime$(){ |
| | | if (Cools.isEmpty(this.updateTime)){ |
| | | return ""; |
| | | } |
| | | return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.updateTime); |
| | | } |
| | | |
| | | |
| | | |
| | | public Boolean getStatusBool(){ |
| | | if (null == this.status){ return null; } |
| | | switch (this.status){ |
| | | case 1: |
| | | return true; |
| | | case 0: |
| | | return false; |
| | | default: |
| | | return null; |
| | | } |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.vincent.rsf.server.manager.mapper; |
| | | |
| | | import com.vincent.rsf.server.manager.entity.WaitPakinItem; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface WaitPakinItemMapper extends BaseMapper<WaitPakinItem> { |
| | | |
| | | } |
New file |
| | |
| | | package com.vincent.rsf.server.manager.mapper; |
| | | |
| | | import com.vincent.rsf.server.manager.entity.WaitPakin; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface WaitPakinMapper extends BaseMapper<WaitPakin> { |
| | | |
| | | } |
New file |
| | |
| | | package com.vincent.rsf.server.manager.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.vincent.rsf.server.manager.entity.WaitPakinItem; |
| | | |
| | | public interface WaitPakinItemService extends IService<WaitPakinItem> { |
| | | |
| | | } |
New file |
| | |
| | | package com.vincent.rsf.server.manager.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.vincent.rsf.server.manager.entity.WaitPakin; |
| | | |
| | | public interface WaitPakinService extends IService<WaitPakin> { |
| | | |
| | | } |
New file |
| | |
| | | package com.vincent.rsf.server.manager.service.impl; |
| | | |
| | | import com.vincent.rsf.server.manager.mapper.WaitPakinItemMapper; |
| | | import com.vincent.rsf.server.manager.entity.WaitPakinItem; |
| | | import com.vincent.rsf.server.manager.service.WaitPakinItemService; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | @Service("waitPakinItemService") |
| | | public class WaitPakinItemServiceImpl extends ServiceImpl<WaitPakinItemMapper, WaitPakinItem> implements WaitPakinItemService { |
| | | |
| | | } |
New file |
| | |
| | | package com.vincent.rsf.server.manager.service.impl; |
| | | |
| | | import com.vincent.rsf.server.manager.mapper.WaitPakinMapper; |
| | | import com.vincent.rsf.server.manager.entity.WaitPakin; |
| | | import com.vincent.rsf.server.manager.service.WaitPakinService; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | @Service("waitPakinService") |
| | | public class WaitPakinServiceImpl extends ServiceImpl<WaitPakinMapper, WaitPakin> implements WaitPakinService { |
| | | |
| | | } |
New file |
| | |
| | | -- save waitPakinItem record |
| | | -- mysql |
| | | insert into `sys_menu` ( `name`, `parent_id`, `route`, `component`, `type`, `sort`, `tenant_id`, `status`) values ( 'menu.waitPakinItem', '0', '/manager/waitPakinItem', 'waitPakinItem', '0' , '0', '1' , '1'); |
| | | |
| | | insert into `sys_menu` ( `name`, `parent_id`, `type`, `authority`, `sort`, `tenant_id`, `status`) values ( 'Query 组拖档明细', '', '1', 'manager:waitPakinItem:list', '0', '1', '1'); |
| | | insert into `sys_menu` ( `name`, `parent_id`, `type`, `authority`, `sort`, `tenant_id`, `status`) values ( 'Create 组拖档明细', '', '1', 'manager:waitPakinItem:save', '1', '1', '1'); |
| | | insert into `sys_menu` ( `name`, `parent_id`, `type`, `authority`, `sort`, `tenant_id`, `status`) values ( 'Update 组拖档明细', '', '1', 'manager:waitPakinItem:update', '2', '1', '1'); |
| | | insert into `sys_menu` ( `name`, `parent_id`, `type`, `authority`, `sort`, `tenant_id`, `status`) values ( 'Delete 组拖档明细', '', '1', 'manager:waitPakinItem:remove', '3', '1', '1'); |
| | | |
| | | -- locale menu name |
| | | waitPakinItem: 'WaitPakinItem', |
| | | |
| | | -- locale field |
| | | waitPakinItem: { |
| | | pakinId: "pakinId", |
| | | maktx: "maktx", |
| | | matnrId: "matnrId", |
| | | matnrCode: "matnrCode", |
| | | anfme: "anfme", |
| | | workQty: "workQty", |
| | | unit: "unit", |
| | | fieldsIndex: "fieldsIndex", |
| | | qty: "qty", |
| | | batch: "batch", |
| | | }, |
| | | |
| | | -- ResourceContent |
| | | import waitPakinItem from './waitPakinItem'; |
| | | |
| | | case 'waitPakinItem': |
| | | return waitPakinItem; |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.vincent.rsf.server.manager.mapper.WaitPakinItemMapper"> |
| | | |
| | | </mapper> |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.vincent.rsf.server.manager.mapper.WaitPakinMapper"> |
| | | |
| | | </mapper> |