添加接口
This commit is contained in:
parent
9e24244e1b
commit
1f36e254ad
|
|
@ -24,7 +24,6 @@ public class InvoicingApi {
|
||||||
private IInvoicingApi invoicingApi;
|
private IInvoicingApi invoicingApi;
|
||||||
|
|
||||||
@ApiOperation(value = "查询物料信息-分页列表查询", notes = "查询物料信息-分页列表查询")
|
@ApiOperation(value = "查询物料信息-分页列表查询", notes = "查询物料信息-分页列表查询")
|
||||||
@AutoLog(value = "查询物料信息-分页列表查询")
|
|
||||||
@GetMapping(value = "/queryInvoicingList")
|
@GetMapping(value = "/queryInvoicingList")
|
||||||
public Result<IPage<MaterialInfoEntity>> queryInvoicingList(MaterialInfoEntity materialInfoEntityDto,
|
public Result<IPage<MaterialInfoEntity>> queryInvoicingList(MaterialInfoEntity materialInfoEntityDto,
|
||||||
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
|
@ -36,7 +35,6 @@ public class InvoicingApi {
|
||||||
|
|
||||||
|
|
||||||
@ApiOperation(value = "查询购物车信息-分页列表查询", notes = "查询购物车信息-分页列表查询")
|
@ApiOperation(value = "查询购物车信息-分页列表查询", notes = "查询购物车信息-分页列表查询")
|
||||||
@AutoLog(value = "查询购物车信息-分页列表查询")
|
|
||||||
@GetMapping(value = "/queryShoppingCartList")
|
@GetMapping(value = "/queryShoppingCartList")
|
||||||
public Result<IPage<QgdInfoEntity>> queryShoppingCartList(QgdInfoEntity qgdInfoEntityDto,
|
public Result<IPage<QgdInfoEntity>> queryShoppingCartList(QgdInfoEntity qgdInfoEntityDto,
|
||||||
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
|
@ -89,7 +87,6 @@ public class InvoicingApi {
|
||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation(value = "查询采购单列表信息", notes = "查询采购单列表信息")
|
@ApiOperation(value = "查询采购单列表信息", notes = "查询采购单列表信息")
|
||||||
@AutoLog(value = "查询采购单列表信息")
|
|
||||||
@GetMapping(value = "/queryCgdList")
|
@GetMapping(value = "/queryCgdList")
|
||||||
public Result<IPage<CgdMainEntity>> queryCgdList(CgdMainEntity cgdMainEntityDto,
|
public Result<IPage<CgdMainEntity>> queryCgdList(CgdMainEntity cgdMainEntityDto,
|
||||||
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
|
@ -99,8 +96,15 @@ public class InvoicingApi {
|
||||||
return Result.OK(pageList);
|
return Result.OK(pageList);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ApiOperation(value="获取采购单数量", notes="获取采购单数量")
|
||||||
|
@GetMapping(value = "/getCgdListNum")
|
||||||
|
public Result<Map<String,Object>> getCgdListNum(CgdMainEntity cgdMainEntityDto) {
|
||||||
|
Map<String,Object> pageList = invoicingApi.getCgdListNum(cgdMainEntityDto);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
@ApiOperation(value = "查询采购单详细信息", notes = "查询采购单详细信息")
|
@ApiOperation(value = "查询采购单详细信息", notes = "查询采购单详细信息")
|
||||||
@AutoLog(value = "查询采购单详细信息")
|
|
||||||
@GetMapping(value = "/queryCgdInfoList")
|
@GetMapping(value = "/queryCgdInfoList")
|
||||||
public Result<IPage<CgdInfoEntity>> queryCgdInfoList(CgdInfoEntity cgdInfoEntityDto,
|
public Result<IPage<CgdInfoEntity>> queryCgdInfoList(CgdInfoEntity cgdInfoEntityDto,
|
||||||
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
|
@ -165,7 +169,6 @@ public class InvoicingApi {
|
||||||
|
|
||||||
|
|
||||||
@ApiOperation(value = "通过nuId获取单元信息", notes = "通过nuId获取单元信息")
|
@ApiOperation(value = "通过nuId获取单元信息", notes = "通过nuId获取单元信息")
|
||||||
@AutoLog(value = "通过nuId获取单元信息")
|
|
||||||
@GetMapping(value = "/queryNuInfoByNuId")
|
@GetMapping(value = "/queryNuInfoByNuId")
|
||||||
public Result<NuBaseInfoEntity> queryNuInfoByNuId(NuBaseInfoEntity nuBaseInfoEntityDto,
|
public Result<NuBaseInfoEntity> queryNuInfoByNuId(NuBaseInfoEntity nuBaseInfoEntityDto,
|
||||||
HttpServletRequest req) {
|
HttpServletRequest req) {
|
||||||
|
|
@ -175,7 +178,6 @@ public class InvoicingApi {
|
||||||
|
|
||||||
|
|
||||||
@ApiOperation(value = "通过物料id获取物料信息", notes = "通过物料id获取物料信息")
|
@ApiOperation(value = "通过物料id获取物料信息", notes = "通过物料id获取物料信息")
|
||||||
@AutoLog(value = "通过物料id获取物料信息")
|
|
||||||
@GetMapping(value = "/queryWlInfoByWlId")
|
@GetMapping(value = "/queryWlInfoByWlId")
|
||||||
public Result<MaterialInfoEntity> queryWlInfoByWlId(MaterialInfoEntity materialInfoEntity) {
|
public Result<MaterialInfoEntity> queryWlInfoByWlId(MaterialInfoEntity materialInfoEntity) {
|
||||||
MaterialInfoEntity info = invoicingApi.queryWlInfoByWlId(materialInfoEntity);
|
MaterialInfoEntity info = invoicingApi.queryWlInfoByWlId(materialInfoEntity);
|
||||||
|
|
@ -252,7 +254,6 @@ public class InvoicingApi {
|
||||||
|
|
||||||
|
|
||||||
@ApiOperation(value = "查询全部供应商信息", notes = "查询全部供应商信息")
|
@ApiOperation(value = "查询全部供应商信息", notes = "查询全部供应商信息")
|
||||||
@AutoLog(value = "查询全部供应商信息")
|
|
||||||
@GetMapping(value = "/getGysList")
|
@GetMapping(value = "/getGysList")
|
||||||
public Result<List<Map<String,Object>>> getGysList(MaterialInfoEntity materialInfoEntityDto,
|
public Result<List<Map<String,Object>>> getGysList(MaterialInfoEntity materialInfoEntityDto,
|
||||||
HttpServletRequest req) {
|
HttpServletRequest req) {
|
||||||
|
|
@ -260,4 +261,22 @@ public class InvoicingApi {
|
||||||
return Result.OK(pageList);
|
return Result.OK(pageList);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ApiOperation(value="获取采购人集合", notes="获取采购人集合")
|
||||||
|
@GetMapping(value = "/getCgrList")
|
||||||
|
public Result<List<Map<String,Object>>> getCgrList(CgdMainEntity cgdMainEntityDto) {
|
||||||
|
List<Map<String,Object>> pageList = invoicingApi.getCgrList(cgdMainEntityDto);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "查询拣货照片集合", notes = "查询拣货照片集合")
|
||||||
|
@GetMapping(value = "/queryJhzpList")
|
||||||
|
public Result<IPage<WarehouseMaterialCrkInfoEntity>> queryCgdInfoList(WarehouseMaterialCrkInfoEntity warehouseMaterialCrkInfoEntityDto,
|
||||||
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
IPage<WarehouseMaterialCrkInfoEntity> pageList = invoicingApi.queryJhzpList(pageNo, pageSize, warehouseMaterialCrkInfoEntityDto,req);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -15,6 +15,7 @@ import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
import org.springframework.format.annotation.DateTimeFormat;
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
|
import java.math.BigDecimal;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -71,13 +72,15 @@ public class CgdInfoEntity implements Serializable {
|
||||||
/**库房*/
|
/**库房*/
|
||||||
private String nuId;
|
private String nuId;
|
||||||
/**入库数量*/
|
/**入库数量*/
|
||||||
private String rksl;
|
private Integer rksl;
|
||||||
/**未入库数量*/
|
/**未入库数量*/
|
||||||
private String wrksl;
|
private Integer wrksl;
|
||||||
|
/**销账数量*/
|
||||||
|
private Integer xzsl;
|
||||||
/**采购单价*/
|
/**采购单价*/
|
||||||
private String procurementPrice;
|
private BigDecimal procurementPrice;
|
||||||
/**到货单间*/
|
/**到货单间*/
|
||||||
private String arrivalPrice;
|
private BigDecimal arrivalPrice;
|
||||||
/**物料类别*/
|
/**物料类别*/
|
||||||
|
|
||||||
@Dict(dictTable = "nu_config_material_category", dicText = "category_name", dicCode = "id")
|
@Dict(dictTable = "nu_config_material_category", dicText = "category_name", dicCode = "id")
|
||||||
|
|
@ -90,8 +93,24 @@ public class CgdInfoEntity implements Serializable {
|
||||||
private String medicationId;
|
private String medicationId;
|
||||||
/**物料图片*/
|
/**物料图片*/
|
||||||
private String materialImg;
|
private String materialImg;
|
||||||
|
/**单据状态 0待入库 1挂账中 2已入库 3已销账*/
|
||||||
|
@Dict(dicCode = "cgd_wl_status")
|
||||||
|
private String status;
|
||||||
private String tagType;
|
private String tagType;
|
||||||
private String tagName;
|
private String tagName;
|
||||||
private String wlParamInfo;
|
private String wlParamInfo;
|
||||||
private String kcsl;
|
private String kcsl;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// 格式化getter方法
|
||||||
|
public String getProcurementPrice() {
|
||||||
|
return procurementPrice != null ?
|
||||||
|
procurementPrice.setScale(2, BigDecimal.ROUND_HALF_UP).toString() : null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getArrivalPrice() {
|
||||||
|
return arrivalPrice != null ?
|
||||||
|
arrivalPrice.setScale(2, BigDecimal.ROUND_HALF_UP).toString() : null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -83,4 +83,7 @@ public class CgdMainEntity implements Serializable {
|
||||||
|
|
||||||
private List<CgdInfoEntity> cgdInfoList;
|
private List<CgdInfoEntity> cgdInfoList;
|
||||||
private String suppliers;
|
private String suppliers;
|
||||||
|
private String startTime;
|
||||||
|
private String endTime;
|
||||||
|
private String cgBy;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -63,6 +63,10 @@ public class MaterialCategoryEntity implements Serializable {
|
||||||
private String nuId;
|
private String nuId;
|
||||||
private String cgdId;
|
private String cgdId;
|
||||||
private String suppliers;
|
private String suppliers;
|
||||||
|
private String startTime;
|
||||||
|
private String endTime;
|
||||||
|
private String cgBy;
|
||||||
|
private String status;
|
||||||
|
|
||||||
private java.lang.String appIconPath;
|
private java.lang.String appIconPath;
|
||||||
private java.lang.String appCheckIconPath;
|
private java.lang.String appCheckIconPath;
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,67 @@
|
||||||
|
package com.nu.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 库房物料出入库信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-10-14
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class WarehouseMaterialCrkInfoEntity implements Serializable {
|
||||||
|
/**id*/
|
||||||
|
private String id;
|
||||||
|
/**createBy*/
|
||||||
|
private String createBy;
|
||||||
|
/**createTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
private Date createTime;
|
||||||
|
/**updateBy*/
|
||||||
|
private String updateBy;
|
||||||
|
/**updateTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
private Date updateTime;
|
||||||
|
/**采购单*/
|
||||||
|
@Dict(dictTable = "nu_invoicing_cgd_main", dicText = "cgd_no", dicCode = "id")
|
||||||
|
private String cgdId;
|
||||||
|
/**库房*/
|
||||||
|
@Dict(dictTable = "nu_base_info", dicText = "nu_name", dicCode = "nu_id")
|
||||||
|
private String nuId;
|
||||||
|
/**物料*/
|
||||||
|
@Dict(dictTable = "nu_config_material_info", dicText = "material_name", dicCode = "id")
|
||||||
|
private String wlId;
|
||||||
|
/**出入库数量*/
|
||||||
|
private Integer crkNum;
|
||||||
|
/**出入库类型 1入库*/
|
||||||
|
@Dict(dicCode = "crk_type")
|
||||||
|
private String crkType;
|
||||||
|
/**备注*/
|
||||||
|
private String dqkcl;
|
||||||
|
/**操作前库存量*/
|
||||||
|
private String czqkcl;
|
||||||
|
/**备注*/
|
||||||
|
private String content;
|
||||||
|
private String jhPic;
|
||||||
|
private BigDecimal oldPrice;
|
||||||
|
private BigDecimal newPrice;
|
||||||
|
private String crkStatus;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -58,4 +58,10 @@ public interface IInvoicingApi {
|
||||||
String eddShoppingCartList(QgdInfoEntity qgdInfoEntity);
|
String eddShoppingCartList(QgdInfoEntity qgdInfoEntity);
|
||||||
|
|
||||||
List<Map<String, Object>> getGysList(MaterialInfoEntity materialInfoEntityDto, HttpServletRequest req);
|
List<Map<String, Object>> getGysList(MaterialInfoEntity materialInfoEntityDto, HttpServletRequest req);
|
||||||
|
|
||||||
|
Map<String, Object> getCgdListNum(CgdMainEntity cgdMainEntityDto);
|
||||||
|
|
||||||
|
List<Map<String,Object>> getCgrList(CgdMainEntity cgdMainEntityDto);
|
||||||
|
|
||||||
|
IPage<WarehouseMaterialCrkInfoEntity> queryJhzpList(Integer pageNo, Integer pageSize, WarehouseMaterialCrkInfoEntity warehouseMaterialCrkInfoEntityDto, HttpServletRequest req);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -110,25 +110,32 @@ public class NuInvoicingCgdInfo implements Serializable {
|
||||||
/**入库数量*/
|
/**入库数量*/
|
||||||
@Excel(name = "入库数量", width = 15)
|
@Excel(name = "入库数量", width = 15)
|
||||||
@ApiModelProperty(value = "入库数量")
|
@ApiModelProperty(value = "入库数量")
|
||||||
private String rksl;
|
private Integer rksl;
|
||||||
/**未入库数量*/
|
/**未入库数量*/
|
||||||
@Excel(name = "未入库数量", width = 15)
|
@Excel(name = "未入库数量", width = 15)
|
||||||
@ApiModelProperty(value = "未入库数量")
|
@ApiModelProperty(value = "未入库数量")
|
||||||
private String wrksl;
|
private Integer wrksl;
|
||||||
|
/**销账数量*/
|
||||||
|
@Excel(name = "销账数量", width = 15)
|
||||||
|
@ApiModelProperty(value = "销账数量")
|
||||||
|
private Integer xzsl;
|
||||||
/**采购单价*/
|
/**采购单价*/
|
||||||
@Excel(name = "采购单价", width = 15)
|
@Excel(name = "采购单价", width = 15)
|
||||||
@ApiModelProperty(value = "采购单价")
|
@ApiModelProperty(value = "采购单价")
|
||||||
private String procurementPrice;
|
private BigDecimal procurementPrice;
|
||||||
/**到货单间*/
|
/**到货单价*/
|
||||||
@Excel(name = "到货单间", width = 15)
|
@Excel(name = "到货单价", width = 15)
|
||||||
@ApiModelProperty(value = "到货单间")
|
@ApiModelProperty(value = "到货单价")
|
||||||
private String arrivalPrice;
|
private BigDecimal arrivalPrice;
|
||||||
/**物料类别*/
|
/**物料类别*/
|
||||||
private String categoryId;
|
private String categoryId;
|
||||||
/**物料类型*/
|
/**物料类型*/
|
||||||
private String typeId;
|
private String typeId;
|
||||||
/**用药类型*/
|
/**用药类型*/
|
||||||
private String medicationId;
|
private String medicationId;
|
||||||
|
/**单据状态 0待入库 1挂账中 2已入库 3已销账*/
|
||||||
|
@Dict(dicCode = "cgd_wl_status")
|
||||||
|
private String status;
|
||||||
|
|
||||||
|
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
|
|
@ -141,4 +148,16 @@ public class NuInvoicingCgdInfo implements Serializable {
|
||||||
private String materialImg;
|
private String materialImg;
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private BigDecimal totalPrice;
|
private BigDecimal totalPrice;
|
||||||
|
|
||||||
|
|
||||||
|
// 格式化getter方法
|
||||||
|
public String getProcurementPrice() {
|
||||||
|
return procurementPrice != null ?
|
||||||
|
procurementPrice.setScale(2, BigDecimal.ROUND_HALF_UP).toString() : null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getArrivalPrice() {
|
||||||
|
return arrivalPrice != null ?
|
||||||
|
arrivalPrice.setScale(2, BigDecimal.ROUND_HALF_UP).toString() : null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -127,7 +127,26 @@ public class NuInvoicingCgdMain implements Serializable {
|
||||||
private String content;
|
private String content;
|
||||||
/**供应商名称*/
|
/**供应商名称*/
|
||||||
private String gysName;
|
private String gysName;
|
||||||
// 总价
|
|
||||||
|
/**拣货人*/
|
||||||
|
private String jhBy;
|
||||||
|
|
||||||
|
/**拣货时间*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
@ApiModelProperty(value = "审核时间")
|
||||||
|
private Date jhTime;
|
||||||
|
/**完结人*/
|
||||||
|
private String wjBy;
|
||||||
|
|
||||||
|
/**完结时间*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
@ApiModelProperty(value = "审核时间")
|
||||||
|
private Date wjTime;
|
||||||
|
|
||||||
|
|
||||||
|
// 总价
|
||||||
private BigDecimal totalPrice;
|
private BigDecimal totalPrice;
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private String qgdId;//临时变量,用于清空购物车id
|
private String qgdId;//临时变量,用于清空购物车id
|
||||||
|
|
|
||||||
|
|
@ -72,7 +72,7 @@ public class NuWarehouseMaterialCrkInfo implements Serializable {
|
||||||
/**出入库数量*/
|
/**出入库数量*/
|
||||||
@Excel(name = "出入库数量", width = 15)
|
@Excel(name = "出入库数量", width = 15)
|
||||||
@ApiModelProperty(value = "出入库数量")
|
@ApiModelProperty(value = "出入库数量")
|
||||||
private java.lang.String crkNum;
|
private Integer crkNum;
|
||||||
/**出入库类型 1入库*/
|
/**出入库类型 1入库*/
|
||||||
@Excel(name = "出入库类型 1入库", width = 15, dicCode = "crk_type")
|
@Excel(name = "出入库类型 1入库", width = 15, dicCode = "crk_type")
|
||||||
@Dict(dicCode = "crk_type")
|
@Dict(dicCode = "crk_type")
|
||||||
|
|
@ -90,4 +90,8 @@ public class NuWarehouseMaterialCrkInfo implements Serializable {
|
||||||
@Excel(name = "备注", width = 15)
|
@Excel(name = "备注", width = 15)
|
||||||
@ApiModelProperty(value = "备注")
|
@ApiModelProperty(value = "备注")
|
||||||
private java.lang.String content;
|
private java.lang.String content;
|
||||||
|
private String jhPic;
|
||||||
|
private BigDecimal oldPrice;
|
||||||
|
private BigDecimal newPrice;
|
||||||
|
private String crkStatus;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import java.util.List;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.nu.entity.CgdMainEntity;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import com.nu.modules.cgd.entity.NuInvoicingCgdMain;
|
import com.nu.modules.cgd.entity.NuInvoicingCgdMain;
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
|
@ -16,4 +17,5 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
*/
|
*/
|
||||||
public interface NuInvoicingCgdMainMapper extends BaseMapper<NuInvoicingCgdMain> {
|
public interface NuInvoicingCgdMainMapper extends BaseMapper<NuInvoicingCgdMain> {
|
||||||
|
|
||||||
|
List<NuInvoicingCgdMain> getCgrList(@Param("params") CgdMainEntity cgdMainEntityDto);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,4 +2,7 @@
|
||||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
<mapper namespace="com.nu.modules.cgd.mapper.NuInvoicingCgdMainMapper">
|
<mapper namespace="com.nu.modules.cgd.mapper.NuInvoicingCgdMainMapper">
|
||||||
|
|
||||||
|
<select id="getCgrList" resultType="com.nu.modules.cgd.entity.NuInvoicingCgdMain">
|
||||||
|
select qg_by from nu_invoicing_cgd_main GROUP BY qg_by
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
@ -90,7 +90,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
for (NuInvoicingCgdInfo nuInvoicingCgdInfo : cgdInfoList) {
|
for (NuInvoicingCgdInfo nuInvoicingCgdInfo : cgdInfoList) {
|
||||||
cgdInfoMapper.updateById(nuInvoicingCgdInfo);
|
cgdInfoMapper.updateById(nuInvoicingCgdInfo);
|
||||||
//入库数量不为空,并且大于0
|
//入库数量不为空,并且大于0
|
||||||
if(StringUtils.isNotBlank(nuInvoicingCgdInfo.getRksl()) && Integer.parseInt(nuInvoicingCgdInfo.getRksl()) > 0){
|
if(StringUtils.isNotBlank(nuInvoicingCgdInfo.getRksl()+"") && nuInvoicingCgdInfo.getRksl() > 0){
|
||||||
String nuId = nuInvoicingCgdInfo.getNuId();
|
String nuId = nuInvoicingCgdInfo.getNuId();
|
||||||
String wlId = nuInvoicingCgdInfo.getWlId();
|
String wlId = nuInvoicingCgdInfo.getWlId();
|
||||||
QueryWrapper<BlWarehouseMaterialInfo> queryWrapper = new QueryWrapper<>();
|
QueryWrapper<BlWarehouseMaterialInfo> queryWrapper = new QueryWrapper<>();
|
||||||
|
|
@ -100,7 +100,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
if(warehouseMaterialInfo != null){
|
if(warehouseMaterialInfo != null){
|
||||||
String kcsl = warehouseMaterialInfo.getKcsl();
|
String kcsl = warehouseMaterialInfo.getKcsl();
|
||||||
if(StringUtils.isNotBlank(kcsl)){
|
if(StringUtils.isNotBlank(kcsl)){
|
||||||
warehouseMaterialInfo.setKcsl(String.valueOf(Integer.parseInt(kcsl) + Integer.parseInt(nuInvoicingCgdInfo.getRksl())));
|
warehouseMaterialInfo.setKcsl(String.valueOf(Integer.parseInt(kcsl) + nuInvoicingCgdInfo.getRksl()));
|
||||||
mterialInfoMapper.updateById(warehouseMaterialInfo);
|
mterialInfoMapper.updateById(warehouseMaterialInfo);
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -119,10 +119,10 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
}
|
}
|
||||||
|
|
||||||
//判断是否有未入库的数量
|
//判断是否有未入库的数量
|
||||||
String wrksl = nuInvoicingCgdInfo.getWrksl();
|
Integer wrksl = nuInvoicingCgdInfo.getWrksl();
|
||||||
if(StringUtils.isNotBlank(wrksl) && Integer.parseInt(wrksl) > 0){
|
if(StringUtils.isNotBlank(wrksl+"") && wrksl > 0){
|
||||||
nuInvoicingCgdInfo.setId(null);
|
nuInvoicingCgdInfo.setId(null);
|
||||||
nuInvoicingCgdInfo.setPurchaseQuantity(Integer.parseInt(wrksl));
|
nuInvoicingCgdInfo.setPurchaseQuantity(wrksl);
|
||||||
nuInvoicingCgdInfo.setRksl(null);
|
nuInvoicingCgdInfo.setRksl(null);
|
||||||
nuInvoicingCgdInfo.setWrksl(null);
|
nuInvoicingCgdInfo.setWrksl(null);
|
||||||
cgdGzdInfoList.add(nuInvoicingCgdInfo);
|
cgdGzdInfoList.add(nuInvoicingCgdInfo);
|
||||||
|
|
@ -334,6 +334,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
cgdInfo.setBrand(params.getBrand());
|
cgdInfo.setBrand(params.getBrand());
|
||||||
cgdInfo.setNuId(params.getNuId());
|
cgdInfo.setNuId(params.getNuId());
|
||||||
cgdInfo.setProcurementPrice(params.getReferenceUnitPrice());
|
cgdInfo.setProcurementPrice(params.getReferenceUnitPrice());
|
||||||
|
cgdInfo.setArrivalPrice(params.getReferenceUnitPrice());
|
||||||
cgdInfo.setKcsl(wlInfo.getKcsl());
|
cgdInfo.setKcsl(wlInfo.getKcsl());
|
||||||
cgdInfo.setTagType(wlInfo.getTagType());
|
cgdInfo.setTagType(wlInfo.getTagType());
|
||||||
cgdInfo.setTagName(wlInfo.getTagName());
|
cgdInfo.setTagName(wlInfo.getTagName());
|
||||||
|
|
@ -342,7 +343,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
cgdInfo.setTypeId(wlInfo.getTypeId());
|
cgdInfo.setTypeId(wlInfo.getTypeId());
|
||||||
cgdInfo.setMedicationId(wlInfo.getMedicationId());
|
cgdInfo.setMedicationId(wlInfo.getMedicationId());
|
||||||
BigDecimal sl = new BigDecimal(params.getPurchaseQuantity());
|
BigDecimal sl = new BigDecimal(params.getPurchaseQuantity());
|
||||||
BigDecimal dj = new BigDecimal(params.getReferenceUnitPrice());
|
BigDecimal dj = params.getReferenceUnitPrice();
|
||||||
BigDecimal wlzj = sl.multiply(dj);
|
BigDecimal wlzj = sl.multiply(dj);
|
||||||
cgdInfo.setTotalPrice(wlzj);
|
cgdInfo.setTotalPrice(wlzj);
|
||||||
totalPrice = totalPrice.add(wlzj);
|
totalPrice = totalPrice.add(wlzj);
|
||||||
|
|
@ -405,6 +406,10 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
QueryWrapper<NuInvoicingCgdMain> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingCgdMain, req.getParameterMap(), customeRuleMap);
|
QueryWrapper<NuInvoicingCgdMain> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingCgdMain, req.getParameterMap(), customeRuleMap);
|
||||||
queryWrapper.apply(StringUtils.isNotBlank(cgdMainEntityDto.getCgdParamInfo()),"(cgd_no like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_name like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or qg_by like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_lxr like '%"+cgdMainEntityDto.getCgdParamInfo()+"%')");
|
queryWrapper.apply(StringUtils.isNotBlank(cgdMainEntityDto.getCgdParamInfo()),"(cgd_no like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_name like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or qg_by like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_lxr like '%"+cgdMainEntityDto.getCgdParamInfo()+"%')");
|
||||||
queryWrapper.in(StringUtils.isNotBlank(cgdMainEntityDto.getSuppliers()),"gys_id",cgdMainEntityDto.getSuppliers());
|
queryWrapper.in(StringUtils.isNotBlank(cgdMainEntityDto.getSuppliers()),"gys_id",cgdMainEntityDto.getSuppliers());
|
||||||
|
queryWrapper.eq(StringUtils.isNotBlank(cgdMainEntityDto.getCgBy()),"qg_by",cgdMainEntityDto.getCgBy());
|
||||||
|
queryWrapper.gt(StringUtils.isNotBlank(cgdMainEntityDto.getStartTime()),"qg_date",cgdMainEntityDto.getStartTime());
|
||||||
|
queryWrapper.lt(StringUtils.isNotBlank(cgdMainEntityDto.getEndTime()),"qg_date",cgdMainEntityDto.getEndTime());
|
||||||
|
queryWrapper.eq(StringUtils.isNotBlank(cgdMainEntityDto.getStatus()),"status",cgdMainEntityDto.getStatus());
|
||||||
Page<NuInvoicingCgdMain> page = new Page<>(pageNo, pageSize);
|
Page<NuInvoicingCgdMain> page = new Page<>(pageNo, pageSize);
|
||||||
List<NuInvoicingCgdMain> list = cgdMainMapper.selectList(page,queryWrapper);
|
List<NuInvoicingCgdMain> list = cgdMainMapper.selectList(page,queryWrapper);
|
||||||
IPage<CgdMainEntity> entityPage = new Page<>(page.getCurrent(), page.getSize(), page.getTotal());
|
IPage<CgdMainEntity> entityPage = new Page<>(page.getCurrent(), page.getSize(), page.getTotal());
|
||||||
|
|
@ -502,7 +507,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
public void voidedCgdMain(CgdMainEntity cgdMainEntity) {
|
public void voidedCgdMain(CgdMainEntity cgdMainEntity) {
|
||||||
NuInvoicingCgdMain cgdMain = new NuInvoicingCgdMain();
|
NuInvoicingCgdMain cgdMain = new NuInvoicingCgdMain();
|
||||||
BeanUtils.copyProperties(cgdMainEntity,cgdMain);
|
BeanUtils.copyProperties(cgdMainEntity,cgdMain);
|
||||||
cgdMain.setStatus("3");
|
// cgdMain.setStatus("3");
|
||||||
cgdMain.setCgdType("9");
|
cgdMain.setCgdType("9");
|
||||||
baseMapper.updateById(cgdMain);
|
baseMapper.updateById(cgdMain);
|
||||||
|
|
||||||
|
|
@ -654,4 +659,52 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
}
|
}
|
||||||
return list;
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<String, Object> getCgdListNum(CgdMainEntity cgdMainEntityDto) {
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
QueryWrapper<NuInvoicingCgdMain> queryWrapper = new QueryWrapper<>() ;
|
||||||
|
queryWrapper.apply(StringUtils.isNotBlank(cgdMainEntityDto.getCgdParamInfo()),"(cgd_no like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_name like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or qg_by like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_lxr like '%"+cgdMainEntityDto.getCgdParamInfo()+"%')");
|
||||||
|
queryWrapper.in(StringUtils.isNotBlank(cgdMainEntityDto.getSuppliers()),"gys_id",cgdMainEntityDto.getSuppliers());
|
||||||
|
queryWrapper.eq(StringUtils.isNotBlank(cgdMainEntityDto.getCgBy()),"gg_by",cgdMainEntityDto.getCgBy());
|
||||||
|
queryWrapper.ge(StringUtils.isNotBlank(cgdMainEntityDto.getStartTime()),"qg_date",cgdMainEntityDto.getStartTime());
|
||||||
|
if(StringUtils.isNotBlank(cgdMainEntityDto.getEndTime())){
|
||||||
|
cgdMainEntityDto.setEndTime(cgdMainEntityDto.getEndTime()+" 23:59:59");
|
||||||
|
queryWrapper.le("qg_date",cgdMainEntityDto.getEndTime());
|
||||||
|
}
|
||||||
|
queryWrapper.eq(StringUtils.isNotBlank(cgdMainEntityDto.getStatus()),"status",cgdMainEntityDto.getStatus());
|
||||||
|
List<NuInvoicingCgdMain> list = cgdMainMapper.selectList(queryWrapper);
|
||||||
|
map.put("success",true);
|
||||||
|
map.put("message","采购单数量");
|
||||||
|
map.put("totalSize",list.size());
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Map<String,Object>> getCgrList(CgdMainEntity cgdMainEntityDto) {
|
||||||
|
List<NuInvoicingCgdMain> list = cgdMainMapper.getCgrList(cgdMainEntityDto);
|
||||||
|
List<Map<String,Object>> listMap = new ArrayList<>();
|
||||||
|
for(NuInvoicingCgdMain cgdMain : list){
|
||||||
|
Map<String,Object> map = new HashMap<>();
|
||||||
|
map.put("cgBy",cgdMain.getQgBy());
|
||||||
|
listMap.add(map);
|
||||||
|
}
|
||||||
|
return listMap;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<WarehouseMaterialCrkInfoEntity> queryJhzpList(Integer pageNo, Integer pageSize, WarehouseMaterialCrkInfoEntity warehouseMaterialCrkInfoEntityDto, HttpServletRequest req) {
|
||||||
|
NuWarehouseMaterialCrkInfo warehouseMaterialCrkInfo = new NuWarehouseMaterialCrkInfo();
|
||||||
|
BeanUtils.copyProperties(warehouseMaterialCrkInfoEntityDto,warehouseMaterialCrkInfo);
|
||||||
|
QueryWrapper<NuWarehouseMaterialCrkInfo> queryWrapper = QueryGenerator.initQueryWrapper(warehouseMaterialCrkInfo, req.getParameterMap());
|
||||||
|
Page<NuWarehouseMaterialCrkInfo> page = new Page<>(pageNo, pageSize);
|
||||||
|
queryWrapper.eq("cgd_id",warehouseMaterialCrkInfo.getCgdId());
|
||||||
|
queryWrapper.isNotNull("jh_pic");
|
||||||
|
queryWrapper.eq("crk_status","1");
|
||||||
|
List<NuWarehouseMaterialCrkInfo> list = crkInfoMapper.selectList(page,queryWrapper);
|
||||||
|
IPage<WarehouseMaterialCrkInfoEntity> entityPage = new Page<>(page.getCurrent(), page.getSize(), page.getTotal());
|
||||||
|
entityPage.setRecords(BeanUtil.copyToList(list, WarehouseMaterialCrkInfoEntity.class));
|
||||||
|
return entityPage;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
package com.nu.modules.qgd.entity;
|
package com.nu.modules.qgd.entity;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.annotation.IdType;
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
import com.baomidou.mybatisplus.annotation.TableField;
|
import com.baomidou.mybatisplus.annotation.TableField;
|
||||||
|
|
@ -104,7 +105,7 @@ public class QgdInfo implements Serializable {
|
||||||
private java.lang.String nuId;
|
private java.lang.String nuId;
|
||||||
|
|
||||||
/**参考单价*/
|
/**参考单价*/
|
||||||
private java.lang.String referenceUnitPrice;
|
private BigDecimal referenceUnitPrice;
|
||||||
|
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private String kcsl;
|
private String kcsl;
|
||||||
|
|
|
||||||
|
|
@ -69,11 +69,11 @@ public class QgdInfoServiceImpl extends ServiceImpl<QgdInfoMapper, QgdInfo> impl
|
||||||
info.setWlUpperLimit(ConfigMaterialInfo.getUpperLimit());
|
info.setWlUpperLimit(ConfigMaterialInfo.getUpperLimit());
|
||||||
info.setWlLowerLimit(ConfigMaterialInfo.getLowerLimit());
|
info.setWlLowerLimit(ConfigMaterialInfo.getLowerLimit());
|
||||||
if(StringUtils.equals("1",ConfigMaterialInfo.getMultiUnitType())){
|
if(StringUtils.equals("1",ConfigMaterialInfo.getMultiUnitType())){
|
||||||
info.setReferenceUnitPrice(ConfigMaterialInfo.getOneUnitPrice()+"");
|
info.setReferenceUnitPrice(ConfigMaterialInfo.getOneUnitPrice());
|
||||||
}else if(StringUtils.equals("2",ConfigMaterialInfo.getMultiUnitType())){
|
}else if(StringUtils.equals("2",ConfigMaterialInfo.getMultiUnitType())){
|
||||||
info.setReferenceUnitPrice(ConfigMaterialInfo.getTwoUnitPrice()+"");
|
info.setReferenceUnitPrice(ConfigMaterialInfo.getTwoUnitPrice());
|
||||||
} else if(StringUtils.equals("3",ConfigMaterialInfo.getMultiUnitType())){
|
} else if(StringUtils.equals("3",ConfigMaterialInfo.getMultiUnitType())){
|
||||||
info.setReferenceUnitPrice(ConfigMaterialInfo.getReferenceUnitPrice()+"");
|
info.setReferenceUnitPrice(ConfigMaterialInfo.getReferenceUnitPrice());
|
||||||
}
|
}
|
||||||
baseMapper.insert(info);
|
baseMapper.insert(info);
|
||||||
}
|
}
|
||||||
|
|
@ -169,7 +169,7 @@ public class QgdInfoServiceImpl extends ServiceImpl<QgdInfoMapper, QgdInfo> impl
|
||||||
cgdInfo.setTypeId(wlInfo.getTypeId());
|
cgdInfo.setTypeId(wlInfo.getTypeId());
|
||||||
cgdInfo.setMedicationId(wlInfo.getMedicationId());
|
cgdInfo.setMedicationId(wlInfo.getMedicationId());
|
||||||
BigDecimal sl = new BigDecimal(params.getPurchaseQuantity());
|
BigDecimal sl = new BigDecimal(params.getPurchaseQuantity());
|
||||||
BigDecimal dj = new BigDecimal(params.getReferenceUnitPrice());
|
BigDecimal dj = params.getReferenceUnitPrice();
|
||||||
BigDecimal wlzj = sl.multiply(dj);
|
BigDecimal wlzj = sl.multiply(dj);
|
||||||
cgdInfo.setTotalPrice(wlzj);
|
cgdInfo.setTotalPrice(wlzj);
|
||||||
totalPrice = totalPrice.add(wlzj);
|
totalPrice = totalPrice.add(wlzj);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue