67 changed files with 1595 additions and 68 deletions
@ -0,0 +1,26 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventory; |
|||
|
|||
import com.baomidou.mybatisplus.annotation.TableName; |
|||
import com.yxt.common.core.domain.BaseEntity; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:26 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物库存信息", description = "包装物库存信息") |
|||
@TableName("packaging_inventory") |
|||
public class PackagingInventory extends BaseEntity { |
|||
//包装物名称
|
|||
private String name; |
|||
//包装物编码
|
|||
private String number; |
|||
//包装物库存
|
|||
private double inventory=0; |
|||
//包装物初始库存
|
|||
private double initialInventory=0; |
|||
//包装物类型
|
|||
private String typeSid; |
|||
} |
@ -0,0 +1,27 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventory; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物库存信息 视图数据详情", description = "包装物库存信息 视图数据详情") |
|||
public class PackagingInventoryDetailsVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//包装物名称
|
|||
private String name; |
|||
//包装物编码
|
|||
private String number; |
|||
//包装物库存
|
|||
private double inventory=0; |
|||
//包装物初始库存
|
|||
private double initialInventory=0; |
|||
//包装物类型
|
|||
private String typeSid; |
|||
} |
@ -0,0 +1,27 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventory; |
|||
|
|||
import com.yxt.common.core.dto.Dto; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物库存信息 数据传输对象", description = "包装物库存信息 数据传输对象") |
|||
public class PackagingInventoryDto implements Dto { |
|||
private String id; |
|||
private String sid; |
|||
//包装物名称
|
|||
private String name; |
|||
//包装物编码
|
|||
private String number; |
|||
//包装物库存
|
|||
private double inventory=0; |
|||
//包装物初始库存
|
|||
private double initialInventory=0; |
|||
//包装物类型
|
|||
private String typeSid; |
|||
|
|||
} |
@ -0,0 +1,28 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventory; |
|||
|
|||
import com.yxt.common.core.query.Query; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物库存信息 查询条件", description = "包装物库存信息 查询条件") |
|||
public class PackagingInventoryQuery implements Query { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//包装物名称
|
|||
private String name; |
|||
//包装物编码
|
|||
private String number; |
|||
//包装物库存
|
|||
private double inventory=0; |
|||
//包装物初始库存
|
|||
private double initialInventory=0; |
|||
//包装物类型
|
|||
private String typeSid; |
|||
|
|||
} |
@ -0,0 +1,27 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventory; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物库存信息 视图数据对象", description = "包装物库存信息 视图数据对象") |
|||
public class PackagingInventoryVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//包装物名称
|
|||
private String name; |
|||
//包装物编码
|
|||
private String number; |
|||
//包装物库存
|
|||
private double inventory=0; |
|||
//包装物初始库存
|
|||
private double initialInventory=0; |
|||
//包装物类型
|
|||
private String typeSid; |
|||
} |
@ -0,0 +1,24 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventoryrecord; |
|||
|
|||
import com.baomidou.mybatisplus.annotation.TableName; |
|||
import com.yxt.common.core.domain.BaseEntity; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:26 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物盘库记录信息", description = "包装物盘库记录信息") |
|||
@TableName("material_inventory_record") |
|||
public class PackagingInventoryRecord extends BaseEntity { |
|||
//盘库日期
|
|||
private String inventoryDate; |
|||
//盘库库存
|
|||
private double inventory; |
|||
//包装物类型
|
|||
private String typeSid; |
|||
//价值
|
|||
private double value; |
|||
} |
@ -0,0 +1,25 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventoryrecord; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物盘库记录信息 视图数据详情", description = "包装物盘库记录信息 视图数据详情") |
|||
public class PackagingInventoryRecordDetailsVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//盘库日期
|
|||
private String inventoryDate; |
|||
//盘库库存
|
|||
private double inventory; |
|||
//包装物类型
|
|||
private String typeSid; |
|||
//价值
|
|||
private double value; |
|||
} |
@ -0,0 +1,25 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventoryrecord; |
|||
|
|||
import com.yxt.common.core.dto.Dto; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物盘库记录信息 数据传输对象", description = "包装物盘库记录信息 数据传输对象") |
|||
public class PackagingInventoryRecordDto implements Dto { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//盘库日期
|
|||
private String inventoryDate; |
|||
//盘库库存
|
|||
private double inventory; |
|||
//包装物类型
|
|||
private String typeSid; |
|||
//价值
|
|||
private double value; |
|||
} |
@ -0,0 +1,28 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventoryrecord; |
|||
|
|||
import com.yxt.common.core.query.Query; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物盘库记录信息 查询条件", description = "包装物盘库记录信息 查询条件") |
|||
public class PackagingInventoryRecordQuery implements Query { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//盘库日期
|
|||
private String inventoryDate; |
|||
//盘库库存
|
|||
private double inventory; |
|||
//包装物类型
|
|||
private String typeSid; |
|||
//价值
|
|||
private double value; |
|||
private String date; |
|||
private String name; |
|||
|
|||
} |
@ -0,0 +1,30 @@ |
|||
package com.yxt.supervise.cyf.api.packaginginventoryrecord; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物盘库记录信息 视图数据对象", description = "包装物盘库记录信息 视图数据对象") |
|||
public class PackagingInventoryRecordVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//盘库日期
|
|||
private String inventoryDate; |
|||
//盘库库存
|
|||
private double inventory; |
|||
//包装物库存sid
|
|||
private String inventorySid; |
|||
//价值
|
|||
private double value; |
|||
//包装物名称
|
|||
private String name; |
|||
//包装物类名称
|
|||
private String typeName; |
|||
|
|||
} |
@ -0,0 +1,28 @@ |
|||
package com.yxt.supervise.cyf.api.packagingoutbound; |
|||
|
|||
import com.baomidou.mybatisplus.annotation.TableName; |
|||
import com.yxt.common.core.domain.BaseEntity; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:26 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物出库信息", description = "包装物出库信息") |
|||
@TableName("packaging_outbound") |
|||
public class PackagingOutbound extends BaseEntity { |
|||
//销售合同号
|
|||
private String salesContractNumber; |
|||
//合同签订日期
|
|||
private String contractSigningDate; |
|||
//出库日期
|
|||
private String deliveryDate; |
|||
//包装物库存sid
|
|||
private String inventorySid; |
|||
//净重
|
|||
private double weight; |
|||
//价值
|
|||
private double value; |
|||
} |
@ -0,0 +1,29 @@ |
|||
package com.yxt.supervise.cyf.api.packagingoutbound; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物出库信息 视图数据详情", description = "包装物出库信息 视图数据详情") |
|||
public class PackagingOutboundDetailsVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//销售合同号
|
|||
private String salesContractNumber; |
|||
//合同签订日期
|
|||
private String contractSigningDate; |
|||
//出库日期
|
|||
private String deliveryDate; |
|||
//包装物库存sid
|
|||
private String inventorySid; |
|||
//净重
|
|||
private double weight; |
|||
//价值
|
|||
private String value; |
|||
} |
@ -0,0 +1,29 @@ |
|||
package com.yxt.supervise.cyf.api.packagingoutbound; |
|||
|
|||
import com.yxt.common.core.dto.Dto; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物出库信息 数据传输对象", description = "包装物出库信息 数据传输对象") |
|||
public class PackagingOutboundDto implements Dto { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//销售合同号
|
|||
private String salesContractNumber; |
|||
//合同签订日期
|
|||
private String contractSigningDate; |
|||
//出库日期
|
|||
private String deliveryDate; |
|||
//包装物库存sid
|
|||
private String inventorySid; |
|||
//净重
|
|||
private double weight; |
|||
//价值
|
|||
private double value; |
|||
} |
@ -0,0 +1,31 @@ |
|||
package com.yxt.supervise.cyf.api.packagingoutbound; |
|||
|
|||
import com.yxt.common.core.query.Query; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物出库信息 查询条件", description = "包装物出库信息 查询条件") |
|||
public class PackagingOutboundQuery implements Query { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//销售合同号
|
|||
private String salesContractNumber; |
|||
//合同签订日期
|
|||
private String contractSigningDate; |
|||
//出库日期
|
|||
private String deliveryDate; |
|||
//包装物库存sid
|
|||
private String inventorySid; |
|||
//净重
|
|||
private double weight; |
|||
//价值
|
|||
private double value; |
|||
private String date; |
|||
private String contractNumber; |
|||
} |
@ -0,0 +1,34 @@ |
|||
package com.yxt.supervise.cyf.api.packagingoutbound; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "油罐信息 视图数据对象", description = "油罐信息 视图数据对象") |
|||
public class PackagingOutboundVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//销售合同号
|
|||
private String salesContractNumber; |
|||
//合同签订日期
|
|||
private String contractSigningDate; |
|||
//出库日期
|
|||
private String deliveryDate; |
|||
//包装物库存sid
|
|||
private String inventorySid; |
|||
private String typeName; |
|||
//净重
|
|||
private double weight; |
|||
private String name; |
|||
//价值
|
|||
private double value; |
|||
//包装物库存
|
|||
private double inventory; |
|||
|
|||
} |
@ -0,0 +1,33 @@ |
|||
package com.yxt.supervise.cyf.api.packagingstorage; |
|||
|
|||
import com.baomidou.mybatisplus.annotation.TableName; |
|||
import com.yxt.common.core.domain.BaseEntity; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:26 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物入库信息", description = "包装物入库信息") |
|||
@TableName("packaging_storage") |
|||
public class PackagingStorage extends BaseEntity { |
|||
//合同号
|
|||
private String contractNumber; |
|||
//供应商sid
|
|||
private String supplierSid; |
|||
//签订日期
|
|||
private String contractSigningDate; |
|||
//发货车牌号
|
|||
private String licensePlateNumber; |
|||
//
|
|||
private String inventorySid; |
|||
//净重
|
|||
private double weight; |
|||
//价值
|
|||
private double value; |
|||
//入库日期
|
|||
private String warehousingDate; |
|||
|
|||
} |
@ -0,0 +1,35 @@ |
|||
package com.yxt.supervise.cyf.api.packagingstorage; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物入库信息 视图数据详情", description = "包装物入库信息 视图数据详情") |
|||
public class PackagingStorageDetailsVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//合同号
|
|||
private String contractNumber; |
|||
//供应商sid
|
|||
private String supplierSid; |
|||
//签订日期
|
|||
private String contractSigningDate; |
|||
//发货车牌号
|
|||
private String licensePlateNumber; |
|||
//
|
|||
private String inventorySid; |
|||
//净重
|
|||
private double weight; |
|||
//价值
|
|||
private String value; |
|||
//入库日期
|
|||
private String warehousingDate; |
|||
//油罐库存
|
|||
private double inventory=0; |
|||
} |
@ -0,0 +1,37 @@ |
|||
package com.yxt.supervise.cyf.api.packagingstorage; |
|||
|
|||
import com.yxt.common.core.dto.Dto; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物入库信息 数据传输对象", description = "包装物入库信息 数据传输对象") |
|||
public class PackagingStorageDto implements Dto { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//合同号
|
|||
private String contractNumber; |
|||
//供应商sid
|
|||
private String supplierSid; |
|||
//签订日期
|
|||
private String contractSigningDate; |
|||
//发货车牌号
|
|||
private String licensePlateNumber; |
|||
//
|
|||
private String inventorySid; |
|||
//净重
|
|||
private double weight; |
|||
//价值
|
|||
private String value; |
|||
//入库日期
|
|||
private String warehousingDate; |
|||
//油罐库存
|
|||
private double inventory=0; |
|||
//1 原料 2 包装物
|
|||
private String type; |
|||
} |
@ -0,0 +1,37 @@ |
|||
package com.yxt.supervise.cyf.api.packagingstorage; |
|||
|
|||
import com.yxt.common.core.query.Query; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物入库信息 查询条件", description = "包装物入库信息 查询条件") |
|||
public class PackagingStorageQuery implements Query { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//合同号
|
|||
private String contractNumber; |
|||
//供应商sid
|
|||
private String supplierSid; |
|||
//签订日期
|
|||
private String contractSigningDate; |
|||
//发货车牌号
|
|||
private String licensePlateNumber; |
|||
//
|
|||
private String inventorySid; |
|||
//净重
|
|||
private double weight; |
|||
//价值
|
|||
private String value; |
|||
//入库日期
|
|||
private String warehousingDate; |
|||
//油罐库存
|
|||
private double inventory=0; |
|||
private String date; |
|||
|
|||
} |
@ -0,0 +1,39 @@ |
|||
package com.yxt.supervise.cyf.api.packagingstorage; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物入库信息 视图数据对象", description = "包装物入库信息 视图数据对象") |
|||
public class PackagingStorageVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//合同号
|
|||
private String contractNumber; |
|||
//供应商sid
|
|||
private String supplierSid; |
|||
//签订日期
|
|||
private String contractSigningDate; |
|||
//发货车牌号
|
|||
private String licensePlateNumber; |
|||
//包装物库存sid
|
|||
private String inventorySid; |
|||
//包装物类型名称
|
|||
private String typeName; |
|||
//净重
|
|||
private double weight; |
|||
//价值
|
|||
private String value; |
|||
//入库日期
|
|||
private String warehousingDate; |
|||
//油罐库存
|
|||
private double inventory=0; |
|||
//包装物名称
|
|||
private String name; |
|||
} |
@ -0,0 +1,23 @@ |
|||
package com.yxt.supervise.cyf.api.packagingtype; |
|||
|
|||
import com.baomidou.mybatisplus.annotation.TableName; |
|||
import com.yxt.common.core.domain.BaseEntity; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:26 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物类型信息", description = "包装物类型信息") |
|||
@TableName("packaging_type") |
|||
public class PackagingType extends BaseEntity { |
|||
//包装物编号
|
|||
private String number; |
|||
//包装物名称
|
|||
private String name; |
|||
//包装物code
|
|||
private String code; |
|||
|
|||
} |
@ -0,0 +1,23 @@ |
|||
package com.yxt.supervise.cyf.api.packagingtype; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物类型信息 视图数据详情", description = "包装物类型信息 视图数据详情") |
|||
public class PackagingTypeDetailsVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//包装物编号
|
|||
private String number; |
|||
//包装物名称
|
|||
private String name; |
|||
//包装物code
|
|||
private String code; |
|||
} |
@ -0,0 +1,23 @@ |
|||
package com.yxt.supervise.cyf.api.packagingtype; |
|||
|
|||
import com.yxt.common.core.dto.Dto; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:28 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物类型信息 数据传输对象", description = "包装物类型信息 数据传输对象") |
|||
public class PackagingTypeDto implements Dto { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//包装物编号
|
|||
private String number; |
|||
//包装物名称
|
|||
private String name; |
|||
//包装物code
|
|||
private String code; |
|||
} |
@ -0,0 +1,23 @@ |
|||
package com.yxt.supervise.cyf.api.packagingtype; |
|||
|
|||
import com.yxt.common.core.query.Query; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物类型信息 查询条件", description = "包装物类型信息 查询条件") |
|||
public class PackagingTypeQuery implements Query { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//包装物编号
|
|||
private String number; |
|||
//包装物名称
|
|||
private String name; |
|||
//包装物code
|
|||
private String code; |
|||
} |
@ -0,0 +1,23 @@ |
|||
package com.yxt.supervise.cyf.api.packagingtype; |
|||
|
|||
import com.yxt.common.core.vo.Vo; |
|||
import io.swagger.annotations.ApiModel; |
|||
import lombok.Data; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:29 |
|||
*/ |
|||
@Data |
|||
@ApiModel(value = "包装物类型信息 视图数据对象", description = "包装物类型信息 视图数据对象") |
|||
public class PackagingTypeVo implements Vo { |
|||
private String id; |
|||
private String sid; |
|||
|
|||
//包装物编号
|
|||
private String number; |
|||
//包装物名称
|
|||
private String name; |
|||
//包装物code
|
|||
private String code; |
|||
} |
@ -0,0 +1,32 @@ |
|||
package com.yxt.supervise.cyf.biz.packaginginventory; |
|||
|
|||
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
|||
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.baomidou.mybatisplus.core.toolkit.Constants; |
|||
import com.yxt.supervise.cyf.api.packaginginventory.PackagingInventory; |
|||
import com.yxt.supervise.cyf.api.packaginginventory.PackagingInventoryVo; |
|||
import org.apache.ibatis.annotations.Mapper; |
|||
import org.apache.ibatis.annotations.Param; |
|||
import org.apache.ibatis.annotations.Select; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Mapper |
|||
public interface PackagingInventoryMapper extends BaseMapper<PackagingInventory> { |
|||
IPage<PackagingInventoryVo> selectPageVo(IPage<PackagingInventory> page, @Param(Constants.WRAPPER) Wrapper<PackagingInventory> qw); |
|||
@Select(" SELECT" + |
|||
" *,t.name as typeName" + |
|||
" FROM" + |
|||
" packaging_inventory r" + |
|||
" left join packaging_type t on t.sid=r.typeSid ") |
|||
List<PackagingInventoryVo> inventoryList(); |
|||
@Select("select * from packaging_inventory where sid=#{sid}") |
|||
PackagingInventory getInventoryBySid(@Param("sid")String sid); |
|||
@Select("select * from packaging_inventory where typeSid=#{sid}") |
|||
List<PackagingInventory> getInventory(@Param("sid")String sid); |
|||
} |
@ -0,0 +1,17 @@ |
|||
<?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.yxt.supervise.cyf.biz.packaginginventory.PackagingInventoryMapper"> |
|||
<!-- <where> ${ew.sqlSegment} </where>--> |
|||
<!-- ${ew.customSqlSegment} --> |
|||
<select id="selectPageVo" resultType="com.yxt.supervise.cyf.api.packaginginventory.PackagingInventoryVo"> |
|||
SELECT |
|||
*,t.name as typeName |
|||
FROM |
|||
packaging_inventory r |
|||
left join packaging_type t on t.sid=r.typeSid |
|||
<where> |
|||
${ew.sqlSegment} |
|||
</where> |
|||
</select> |
|||
|
|||
</mapper> |
@ -0,0 +1,66 @@ |
|||
package com.yxt.supervise.cyf.biz.packaginginventory; |
|||
|
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.packaginginventory.PackagingInventoryDto; |
|||
import com.yxt.supervise.cyf.api.packaginginventory.PackagingInventoryQuery; |
|||
import com.yxt.supervise.cyf.api.packaginginventory.PackagingInventoryVo; |
|||
import io.swagger.annotations.Api; |
|||
import io.swagger.annotations.ApiOperation; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.web.bind.annotation.*; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:38 |
|||
*/ |
|||
@Api(tags = "包装物库存信息") |
|||
@RestController |
|||
@RequestMapping("cyf/packinventory") |
|||
public class PackagingInventoryRest { |
|||
@Autowired |
|||
PackagingInventoryService packagingPackagingInventoryService; |
|||
|
|||
@ApiOperation("根据条件分页查询数据的列表") |
|||
@PostMapping("/listPage") |
|||
public ResultBean<PagerVo<PackagingInventoryVo>> listPage(@RequestBody PagerQuery<PackagingInventoryQuery> pq) { |
|||
ResultBean rb = ResultBean.fireFail(); |
|||
PagerVo<PackagingInventoryVo> pv = packagingPackagingInventoryService.listPageVo(pq); |
|||
return rb.success().setData(pv); |
|||
} |
|||
@ApiOperation("根据条件分页查询数据的列表") |
|||
@PostMapping("/inventoryList") |
|||
public ResultBean<PagerVo<PackagingInventoryVo>> inventoryList() { |
|||
ResultBean rb = ResultBean.fireFail(); |
|||
List<PackagingInventoryVo> pv = packagingPackagingInventoryService.inventoryList(); |
|||
return rb.success().setData(pv); |
|||
} |
|||
@ApiOperation("新增") |
|||
@PostMapping("/save") |
|||
public ResultBean save (@RequestBody PackagingInventoryDto dto){ |
|||
return packagingPackagingInventoryService.save(dto); |
|||
} |
|||
@ApiOperation("修改") |
|||
@PostMapping("/update") |
|||
public ResultBean update (@RequestBody PackagingInventoryDto dto){ |
|||
return packagingPackagingInventoryService.update(dto); |
|||
} |
|||
@ApiOperation("根据sid查询") |
|||
@GetMapping("/getInventoryBySid/{sid}") |
|||
public ResultBean getInventoryBySid(@PathVariable String sid){ |
|||
return packagingPackagingInventoryService.getInventoryBySid(sid); |
|||
} |
|||
@ApiOperation("根据typeSid查询") |
|||
@GetMapping("/getInventory/{sid}") |
|||
public ResultBean getInventory(@PathVariable String typeSid){ |
|||
return packagingPackagingInventoryService.getInventory(typeSid); |
|||
} |
|||
@ApiOperation("删除") |
|||
@DeleteMapping("/delete/{sid}") |
|||
public ResultBean delete(@PathVariable String sid ){ |
|||
return packagingPackagingInventoryService.del(sid); |
|||
} |
|||
} |
@ -0,0 +1,75 @@ |
|||
package com.yxt.supervise.cyf.biz.packaginginventory; |
|||
|
|||
import cn.hutool.core.bean.BeanUtil; |
|||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.yxt.common.base.service.MybatisBaseService; |
|||
import com.yxt.common.base.utils.PagerUtil; |
|||
import com.yxt.common.base.utils.StringUtils; |
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.packaginginventory.PackagingInventory; |
|||
import com.yxt.supervise.cyf.api.packaginginventory.PackagingInventoryDto; |
|||
import com.yxt.supervise.cyf.api.packaginginventory.PackagingInventoryQuery; |
|||
import com.yxt.supervise.cyf.api.packaginginventory.PackagingInventoryVo; |
|||
import org.springframework.stereotype.Service; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Service |
|||
public class PackagingInventoryService extends MybatisBaseService<PackagingInventoryMapper, PackagingInventory> { |
|||
|
|||
|
|||
public PagerVo<PackagingInventoryVo> listPageVo(PagerQuery<PackagingInventoryQuery> pq) { |
|||
PackagingInventoryQuery query = pq.getParams(); |
|||
QueryWrapper<PackagingInventory> qw = new QueryWrapper<>(); |
|||
if(StringUtils.isNotBlank(query.getName())){ |
|||
qw.like("r.name",query.getName()); |
|||
} |
|||
IPage<PackagingInventory> page = PagerUtil.queryToPage(pq); |
|||
IPage<PackagingInventoryVo> pagging = baseMapper.selectPageVo(page, qw); |
|||
PagerVo<PackagingInventoryVo> p = PagerUtil.pageToVo(pagging, null); |
|||
return p; |
|||
} |
|||
public List<PackagingInventoryVo> inventoryList() { |
|||
|
|||
return baseMapper.inventoryList(); |
|||
} |
|||
public ResultBean save(PackagingInventoryDto dto){ |
|||
ResultBean rb=new ResultBean(); |
|||
PackagingInventory entity=new PackagingInventory(); |
|||
BeanUtil.copyProperties(dto, entity, "id", "sid"); |
|||
entity.setInventory(dto.getInitialInventory()); |
|||
baseMapper.insert(entity); |
|||
return rb.success().setMsg("新增成功"); |
|||
} |
|||
public ResultBean update (PackagingInventoryDto dto){ |
|||
ResultBean rb=new ResultBean(); |
|||
String dtoSid = dto.getSid(); |
|||
PackagingInventory entity=fetchBySid(dtoSid); |
|||
BeanUtil.copyProperties(dto, entity, "id", "sid"); |
|||
baseMapper.updateById(entity); |
|||
return rb.success().setMsg("修改成功"); |
|||
} |
|||
public ResultBean getInventoryBySid(String sid){ |
|||
ResultBean rb=new ResultBean(); |
|||
PackagingInventory RawPackagingInventory=baseMapper.getInventoryBySid(sid); |
|||
return rb.success().setData(RawPackagingInventory); |
|||
} |
|||
|
|||
public ResultBean getInventory(String sid){ |
|||
ResultBean rb=new ResultBean(); |
|||
List<PackagingInventory> RawPackagingInventory=baseMapper.getInventory(sid); |
|||
return rb.success().setData(RawPackagingInventory); |
|||
} |
|||
public ResultBean del(String sid){ |
|||
ResultBean rb=new ResultBean(); |
|||
baseMapper.delete(new QueryWrapper<PackagingInventory>().eq("sid",sid)); |
|||
return rb.success().setMsg("删除成功"); |
|||
} |
|||
} |
@ -0,0 +1,20 @@ |
|||
package com.yxt.supervise.cyf.biz.packaginginventoryrecord; |
|||
|
|||
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
|||
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.baomidou.mybatisplus.core.toolkit.Constants; |
|||
import com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecord; |
|||
import com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecordVo; |
|||
import org.apache.ibatis.annotations.Mapper; |
|||
import org.apache.ibatis.annotations.Param; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Mapper |
|||
public interface PackagingInventoryRecordMapper extends BaseMapper<PackagingInventoryRecord> { |
|||
IPage<PackagingInventoryRecordVo> selectPageVo(IPage<PackagingInventoryRecord> page, @Param(Constants.WRAPPER) Wrapper<PackagingInventoryRecord> qw); |
|||
|
|||
} |
@ -0,0 +1,18 @@ |
|||
<?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.yxt.supervise.cyf.biz.packaginginventoryrecord.PackagingInventoryRecordMapper"> |
|||
<!-- <where> ${ew.sqlSegment} </where>--> |
|||
<!-- ${ew.customSqlSegment} --> |
|||
<select id="selectPageVo" resultType="com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecordVo"> |
|||
SELECT |
|||
*,i.name as name,i.inventory as inventory,t.name as typeName; |
|||
FROM |
|||
packaging_inventory_record r |
|||
left join packaging_inventory i on r.inventorySid =i.sid |
|||
left join packaging_type t on t.sid=i.typeSid |
|||
<where> |
|||
${ew.sqlSegment} |
|||
</where> |
|||
</select> |
|||
|
|||
</mapper> |
@ -0,0 +1,42 @@ |
|||
package com.yxt.supervise.cyf.biz.packaginginventoryrecord; |
|||
|
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecordDto; |
|||
import com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecordQuery; |
|||
import com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecordVo; |
|||
import io.swagger.annotations.Api; |
|||
import io.swagger.annotations.ApiOperation; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.web.bind.annotation.PostMapping; |
|||
import org.springframework.web.bind.annotation.RequestBody; |
|||
import org.springframework.web.bind.annotation.RequestMapping; |
|||
import org.springframework.web.bind.annotation.RestController; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:38 |
|||
*/ |
|||
@Api(tags = "包装物盘库信息") |
|||
@RestController |
|||
@RequestMapping("cyf/packrecord") |
|||
public class PackagingInventoryRecordRest { |
|||
@Autowired |
|||
PackagingInventoryRecordService PackagingInventoryRecordService; |
|||
|
|||
@ApiOperation("根据条件分页查询数据的列表") |
|||
@PostMapping("/listPage") |
|||
public ResultBean<PagerVo<PackagingInventoryRecordVo>> listPage(@RequestBody PagerQuery<PackagingInventoryRecordQuery> pq) { |
|||
ResultBean rb = ResultBean.fireFail(); |
|||
PagerVo<PackagingInventoryRecordVo> pv = PackagingInventoryRecordService.listPageVo(pq); |
|||
return rb.success().setData(pv); |
|||
} |
|||
|
|||
@ApiOperation("新增") |
|||
@PostMapping("/save") |
|||
public ResultBean save (@RequestBody PackagingInventoryRecordDto dto){ |
|||
return PackagingInventoryRecordService.save(dto); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,49 @@ |
|||
package com.yxt.supervise.cyf.biz.packaginginventoryrecord; |
|||
|
|||
import cn.hutool.core.bean.BeanUtil; |
|||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.yxt.common.base.service.MybatisBaseService; |
|||
import com.yxt.common.base.utils.PagerUtil; |
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecord; |
|||
import com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecordDto; |
|||
import com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecordQuery; |
|||
import com.yxt.supervise.cyf.api.packaginginventoryrecord.PackagingInventoryRecordVo; |
|||
import org.apache.commons.lang3.StringUtils; |
|||
import org.springframework.stereotype.Service; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Service |
|||
public class PackagingInventoryRecordService extends MybatisBaseService<PackagingInventoryRecordMapper, PackagingInventoryRecord> { |
|||
|
|||
|
|||
public PagerVo<PackagingInventoryRecordVo> listPageVo(PagerQuery<PackagingInventoryRecordQuery> pq) { |
|||
PackagingInventoryRecordQuery query = pq.getParams(); |
|||
QueryWrapper<PackagingInventoryRecord> qw = new QueryWrapper<>(); |
|||
if (StringUtils.isNotBlank(query.getDate())) { |
|||
qw.eq("STR_TO_DATE(r.inventoryDate,'%Y-%m-%d')", query.getDate()); |
|||
} |
|||
if (StringUtils.isNotBlank(query.getName())) { |
|||
qw.like("i.name", query.getName()); |
|||
} |
|||
IPage<PackagingInventoryRecord> page = PagerUtil.queryToPage(pq); |
|||
IPage<PackagingInventoryRecordVo> pagging = baseMapper.selectPageVo(page, qw); |
|||
PagerVo<PackagingInventoryRecordVo> p = PagerUtil.pageToVo(pagging, null); |
|||
return p; |
|||
} |
|||
|
|||
public ResultBean save(PackagingInventoryRecordDto dto){ |
|||
ResultBean rb=new ResultBean(); |
|||
PackagingInventoryRecord entity=new PackagingInventoryRecord(); |
|||
BeanUtil.copyProperties(dto, entity, "id", "sid"); |
|||
baseMapper.insert(entity); |
|||
return rb.success().setMsg("新增成功"); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,31 @@ |
|||
package com.yxt.supervise.cyf.biz.packagingoutbound; |
|||
|
|||
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
|||
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.baomidou.mybatisplus.core.toolkit.Constants; |
|||
import com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutbound; |
|||
import com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutboundVo; |
|||
import org.apache.ibatis.annotations.Mapper; |
|||
import org.apache.ibatis.annotations.Param; |
|||
import org.apache.ibatis.annotations.Select; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Mapper |
|||
public interface PackagingOutboundMapper extends BaseMapper<PackagingOutbound> { |
|||
IPage<PackagingOutboundVo> selectPageVo(IPage<PackagingOutbound> page, @Param(Constants.WRAPPER) Wrapper<PackagingOutbound> qw); |
|||
@Select(" SELECT" + |
|||
" *,t.name as typeName,i.inventory as inventory" + |
|||
" FROM" + |
|||
" packaging_outbound o" + |
|||
" left join packaging_inventory i on i.sid=o.inventorySid" + |
|||
" left join packaging_type t on t.sid=i.typeSid") |
|||
List<PackagingOutboundVo> outboundList(); |
|||
@Select("select * from tank_information where sid=#{sid}") |
|||
PackagingOutbound getOutboundBySid(@Param("sid")String sid); |
|||
} |
@ -0,0 +1,18 @@ |
|||
<?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.yxt.supervise.cyf.biz.packagingoutbound.PackagingOutboundMapper"> |
|||
<!-- <where> ${ew.sqlSegment} </where>--> |
|||
<!-- ${ew.customSqlSegment} --> |
|||
<select id="selectPageVo" resultType="com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutboundVo"> |
|||
SELECT |
|||
*,t.name as typeName,i.inventory as inventory |
|||
FROM |
|||
packaging_outbound o |
|||
left join packaging_inventory i on i.sid=o.inventorySid |
|||
left join packaging_type t on t.sid=i.typeSid") |
|||
<where> |
|||
${ew.sqlSegment} |
|||
</where> |
|||
</select> |
|||
|
|||
</mapper> |
@ -0,0 +1,53 @@ |
|||
package com.yxt.supervise.cyf.biz.packagingoutbound; |
|||
|
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutboundDto; |
|||
import com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutboundQuery; |
|||
import com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutboundVo; |
|||
import io.swagger.annotations.Api; |
|||
import io.swagger.annotations.ApiOperation; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.web.bind.annotation.*; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:38 |
|||
*/ |
|||
@Api(tags = "包装物出库信息") |
|||
@RestController |
|||
@RequestMapping("cyf/packoutbound") |
|||
public class PackagingOutboundRest { |
|||
@Autowired |
|||
PackagingOutboundService PackagingOutboundService; |
|||
|
|||
@ApiOperation("根据条件分页查询数据的列表") |
|||
@PostMapping("/listPage") |
|||
public ResultBean<PagerVo<PackagingOutboundVo>> listPage(@RequestBody PagerQuery<PackagingOutboundQuery> pq) { |
|||
ResultBean rb = ResultBean.fireFail(); |
|||
PagerVo<PackagingOutboundVo> pv = PackagingOutboundService.listPageVo(pq); |
|||
return rb.success().setData(pv); |
|||
} |
|||
@ApiOperation("根据条件分页查询数据的列表") |
|||
@PostMapping("/outboundList") |
|||
public ResultBean<PagerVo<PackagingOutboundVo>> outboundList() { |
|||
ResultBean rb = ResultBean.fireFail(); |
|||
List<PackagingOutboundVo> pv = PackagingOutboundService.outboundList(); |
|||
return rb.success().setData(pv); |
|||
} |
|||
@ApiOperation("新增") |
|||
@PostMapping("/save") |
|||
public ResultBean save (@RequestBody PackagingOutboundDto dto){ |
|||
return PackagingOutboundService.save(dto); |
|||
} |
|||
|
|||
@ApiOperation("根据sid查询") |
|||
@GetMapping("/getOutboundBySid/{sid}") |
|||
public ResultBean getOutboundBySid(@PathVariable String sid){ |
|||
return PackagingOutboundService.getOutboundBySid(sid); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,72 @@ |
|||
package com.yxt.supervise.cyf.biz.packagingoutbound; |
|||
|
|||
import cn.hutool.core.bean.BeanUtil; |
|||
import cn.hutool.core.date.DateUtil; |
|||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.yxt.common.base.service.MybatisBaseService; |
|||
import com.yxt.common.base.utils.PagerUtil; |
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.materialinventory.MaterialInventory; |
|||
import com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutbound; |
|||
import com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutboundDto; |
|||
import com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutboundQuery; |
|||
import com.yxt.supervise.cyf.api.packagingoutbound.PackagingOutboundVo; |
|||
import com.yxt.supervise.cyf.biz.materialinventory.MaterialInventoryMapper; |
|||
import org.apache.commons.lang3.StringUtils; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Service; |
|||
|
|||
import java.util.Date; |
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Service |
|||
public class PackagingOutboundService extends MybatisBaseService<PackagingOutboundMapper, PackagingOutbound> { |
|||
|
|||
@Autowired |
|||
MaterialInventoryMapper rawMaterialInventoryMapper; |
|||
public PagerVo<PackagingOutboundVo> listPageVo(PagerQuery<PackagingOutboundQuery> pq) { |
|||
PackagingOutboundQuery query = pq.getParams(); |
|||
QueryWrapper<PackagingOutbound> qw = new QueryWrapper<>(); |
|||
if (StringUtils.isNotBlank(query.getDate())) { |
|||
qw.eq("STR_TO_DATE(o.deliverDate,'%Y-%m-%d')", query.getDate()); |
|||
} |
|||
if (StringUtils.isNotBlank(query.getContractNumber())) { |
|||
qw.like("o.salesContractNumber", query.getContractNumber()); |
|||
} |
|||
IPage<PackagingOutbound> page = PagerUtil.queryToPage(pq); |
|||
IPage<PackagingOutboundVo> pagging = baseMapper.selectPageVo(page, qw); |
|||
PagerVo<PackagingOutboundVo> p = PagerUtil.pageToVo(pagging, null); |
|||
return p; |
|||
} |
|||
public List<PackagingOutboundVo> outboundList() { |
|||
|
|||
return baseMapper.outboundList(); |
|||
} |
|||
public ResultBean save(PackagingOutboundDto dto){ |
|||
ResultBean rb=new ResultBean(); |
|||
PackagingOutbound entity=new PackagingOutbound(); |
|||
BeanUtil.copyProperties(dto, entity, "id", "sid"); |
|||
Date curDate = new Date(); |
|||
String dfmt = DateUtil.format(curDate, "yyyy-MM-dd"); |
|||
entity.setDeliveryDate(dfmt); |
|||
baseMapper.insert(entity); |
|||
MaterialInventory rawMaterialInventory=rawMaterialInventoryMapper.selectOne(new QueryWrapper<MaterialInventory>().eq("sid",dto.getInventorySid())); |
|||
rawMaterialInventory.setInventory(rawMaterialInventory.getInventory()-dto.getWeight()); |
|||
rawMaterialInventoryMapper.updateById(rawMaterialInventory); |
|||
return rb.success().setMsg("新增成功"); |
|||
} |
|||
|
|||
public ResultBean getOutboundBySid(String sid){ |
|||
ResultBean rb=new ResultBean(); |
|||
PackagingOutbound RawPackagingOutbound=baseMapper.getOutboundBySid(sid); |
|||
return rb.success().setData(RawPackagingOutbound); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,30 @@ |
|||
package com.yxt.supervise.cyf.biz.packagingstorage; |
|||
|
|||
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
|||
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.baomidou.mybatisplus.core.toolkit.Constants; |
|||
import com.yxt.supervise.cyf.api.packagingstorage.PackagingStorage; |
|||
import com.yxt.supervise.cyf.api.packagingstorage.PackagingStorageVo; |
|||
import org.apache.ibatis.annotations.Mapper; |
|||
import org.apache.ibatis.annotations.Param; |
|||
import org.apache.ibatis.annotations.Select; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Mapper |
|||
public interface PackagingStorageMapper extends BaseMapper<PackagingStorage> { |
|||
IPage<PackagingStorageVo> selectPageVo(IPage<PackagingStorage> page, @Param(Constants.WRAPPER) Wrapper<PackagingStorage> qw); |
|||
@Select(" *,t.name as typeName,i.inventory as inventory" + |
|||
" FROM" + |
|||
" packaging_storage s" + |
|||
" left join packaging_inventory i on i.sid=s.inventorySid" + |
|||
" left join packaging_type t on t.sid=i.typeSid") |
|||
List<PackagingStorageVo> StorageList(); |
|||
@Select("select * from packaging_storage where sid=#{sid}") |
|||
PackagingStorage getStorageBySid(@Param("sid")String sid); |
|||
} |
@ -0,0 +1,18 @@ |
|||
<?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.yxt.supervise.cyf.biz.packagingstorage.PackagingStorageMapper"> |
|||
<!-- <where> ${ew.sqlSegment} </where>--> |
|||
<!-- ${ew.customSqlSegment} --> |
|||
<select id="selectPageVo" resultType="com.yxt.supervise.cyf.api.packagingstorage.PackagingStorageVo"> |
|||
SELECT |
|||
*,t.name as typeName,i.inventory as inventory |
|||
FROM |
|||
packaging_storage s |
|||
left join packaging_inventory i on i.sid=s.inventorySid |
|||
left join packaging_type t on t.sid=i.typeSid |
|||
<where> |
|||
${ew.sqlSegment} |
|||
</where> |
|||
</select> |
|||
|
|||
</mapper> |
@ -0,0 +1,53 @@ |
|||
package com.yxt.supervise.cyf.biz.packagingstorage; |
|||
|
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.packagingstorage.PackagingStorageDto; |
|||
import com.yxt.supervise.cyf.api.packagingstorage.PackagingStorageQuery; |
|||
import com.yxt.supervise.cyf.api.packagingstorage.PackagingStorageVo; |
|||
import io.swagger.annotations.Api; |
|||
import io.swagger.annotations.ApiOperation; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.web.bind.annotation.*; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:38 |
|||
*/ |
|||
@Api(tags = "包装物入库消息") |
|||
@RestController |
|||
@RequestMapping("cyf/packstorage") |
|||
public class PackagingStorageRest { |
|||
@Autowired |
|||
PackagingStorageService PackagingStorageService; |
|||
|
|||
@ApiOperation("根据条件分页查询数据的列表") |
|||
@PostMapping("/listPage") |
|||
public ResultBean<PagerVo<PackagingStorageVo>> listPage(@RequestBody PagerQuery<PackagingStorageQuery> pq) { |
|||
ResultBean rb = ResultBean.fireFail(); |
|||
PagerVo<PackagingStorageVo> pv = PackagingStorageService.listPageVo(pq); |
|||
return rb.success().setData(pv); |
|||
} |
|||
@ApiOperation("根据条件分页查询数据的列表") |
|||
@PostMapping("/tankList") |
|||
public ResultBean<PagerVo<PackagingStorageVo>> listPage() { |
|||
ResultBean rb = ResultBean.fireFail(); |
|||
List<PackagingStorageVo> pv = PackagingStorageService.StorageList(); |
|||
return rb.success().setData(pv); |
|||
} |
|||
@ApiOperation("新增") |
|||
@PostMapping("/save") |
|||
public ResultBean save (@RequestBody PackagingStorageDto dto){ |
|||
return PackagingStorageService.save(dto); |
|||
} |
|||
|
|||
@ApiOperation("根据sid查询") |
|||
@GetMapping("/getTankBySid/{sid}") |
|||
public ResultBean getTankBySid(@PathVariable String sid){ |
|||
return PackagingStorageService.getTankBySid(sid); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,71 @@ |
|||
package com.yxt.supervise.cyf.biz.packagingstorage; |
|||
|
|||
import cn.hutool.core.bean.BeanUtil; |
|||
import cn.hutool.core.date.DateUtil; |
|||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.yxt.common.base.service.MybatisBaseService; |
|||
import com.yxt.common.base.utils.PagerUtil; |
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.materialinventory.MaterialInventory; |
|||
import com.yxt.supervise.cyf.api.packagingstorage.PackagingStorage; |
|||
import com.yxt.supervise.cyf.api.packagingstorage.PackagingStorageDto; |
|||
import com.yxt.supervise.cyf.api.packagingstorage.PackagingStorageQuery; |
|||
import com.yxt.supervise.cyf.api.packagingstorage.PackagingStorageVo; |
|||
import com.yxt.supervise.cyf.biz.materialinventory.MaterialInventoryMapper; |
|||
import org.apache.commons.lang3.StringUtils; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Service; |
|||
|
|||
import java.util.Date; |
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Service |
|||
public class PackagingStorageService extends MybatisBaseService<PackagingStorageMapper, PackagingStorage> { |
|||
|
|||
@Autowired |
|||
MaterialInventoryMapper rawMaterialInventoryMapper; |
|||
public PagerVo<PackagingStorageVo> listPageVo(PagerQuery<PackagingStorageQuery> pq) { |
|||
PackagingStorageQuery query = pq.getParams(); |
|||
QueryWrapper<PackagingStorage> qw = new QueryWrapper<>(); |
|||
if (StringUtils.isNotBlank(query.getDate())) { |
|||
qw.eq("STR_TO_DATE(s.warehousingDate,'%Y-%m-%d')", query.getDate()); |
|||
} |
|||
if (StringUtils.isNotBlank(query.getContractNumber())) { |
|||
qw.like("s.salesContractNumber", query.getContractNumber()); |
|||
} |
|||
IPage<PackagingStorage> page = PagerUtil.queryToPage(pq); |
|||
IPage<PackagingStorageVo> pagging = baseMapper.selectPageVo(page, qw); |
|||
PagerVo<PackagingStorageVo> p = PagerUtil.pageToVo(pagging, null); |
|||
return p; |
|||
} |
|||
public List<PackagingStorageVo> StorageList() { |
|||
return baseMapper.StorageList(); |
|||
} |
|||
public ResultBean save(PackagingStorageDto dto){ |
|||
ResultBean rb=new ResultBean(); |
|||
PackagingStorage entity=new PackagingStorage(); |
|||
BeanUtil.copyProperties(dto, entity, "id", "sid"); |
|||
Date curDate = new Date(); |
|||
String dfmt = DateUtil.format(curDate, "yyyy-MM-dd"); |
|||
entity.setWarehousingDate(dfmt); |
|||
baseMapper.insert(entity); |
|||
MaterialInventory rawMaterialInventory=rawMaterialInventoryMapper.selectOne(new QueryWrapper<MaterialInventory>().eq("sid",dto.getInventorySid())); |
|||
rawMaterialInventory.setInventory(rawMaterialInventory.getInventory()+dto.getWeight()); |
|||
rawMaterialInventoryMapper.updateById(rawMaterialInventory); |
|||
return rb.success().setMsg("新增成功"); |
|||
} |
|||
|
|||
public ResultBean getTankBySid(String sid){ |
|||
ResultBean rb=new ResultBean(); |
|||
PackagingStorage RawPackagingStorage=baseMapper.getStorageBySid(sid); |
|||
return rb.success().setData(RawPackagingStorage); |
|||
} |
|||
|
|||
} |
@ -0,0 +1,26 @@ |
|||
package com.yxt.supervise.cyf.biz.packagingtype; |
|||
|
|||
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
|||
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.baomidou.mybatisplus.core.toolkit.Constants; |
|||
import com.yxt.supervise.cyf.api.packagingtype.PackagingType; |
|||
import com.yxt.supervise.cyf.api.packagingtype.PackagingTypeVo; |
|||
import org.apache.ibatis.annotations.Mapper; |
|||
import org.apache.ibatis.annotations.Param; |
|||
import org.apache.ibatis.annotations.Select; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Mapper |
|||
public interface PackagingTypeMapper extends BaseMapper<PackagingType> { |
|||
IPage<PackagingTypeVo> selectPageVo(IPage<PackagingType> page, @Param(Constants.WRAPPER) Wrapper<PackagingType> qw); |
|||
@Select("select * from packaging_type") |
|||
List<PackagingTypeVo> typeList(); |
|||
@Select("select * from packaging_type where sid=#{sid}") |
|||
PackagingType getTypeBySid(@Param("sid")String sid); |
|||
} |
@ -0,0 +1,16 @@ |
|||
<?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.yxt.supervise.cyf.biz.packagingtype.PackagingTypeMapper"> |
|||
<!-- <where> ${ew.sqlSegment} </where>--> |
|||
<!-- ${ew.customSqlSegment} --> |
|||
<select id="selectPageVo" resultType="com.yxt.supervise.cyf.api.packagingtype.PackagingTypeVo"> |
|||
SELECT |
|||
* |
|||
FROM |
|||
packaging_type |
|||
<where> |
|||
${ew.sqlSegment} |
|||
</where> |
|||
</select> |
|||
|
|||
</mapper> |
@ -0,0 +1,61 @@ |
|||
package com.yxt.supervise.cyf.biz.packagingtype; |
|||
|
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.packagingtype.PackagingTypeDto; |
|||
import com.yxt.supervise.cyf.api.packagingtype.PackagingTypeQuery; |
|||
import com.yxt.supervise.cyf.api.packagingtype.PackagingTypeVo; |
|||
import io.swagger.annotations.Api; |
|||
import io.swagger.annotations.ApiOperation; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.web.bind.annotation.*; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:38 |
|||
*/ |
|||
@Api(tags = "包装物类型信息") |
|||
@RestController |
|||
@RequestMapping("cyf/packtype") |
|||
public class PackagingTypeRest { |
|||
@Autowired |
|||
PackagingTypeService PackagingTypeService; |
|||
|
|||
@ApiOperation("根据条件分页查询数据的列表") |
|||
@PostMapping("/listPage") |
|||
public ResultBean<PagerVo<PackagingTypeVo>> listPage(@RequestBody PagerQuery<PackagingTypeQuery> pq) { |
|||
ResultBean rb = ResultBean.fireFail(); |
|||
PagerVo<PackagingTypeVo> pv = PackagingTypeService.listPageVo(pq); |
|||
return rb.success().setData(pv); |
|||
} |
|||
@ApiOperation("根据物料类型查询数据的列表") |
|||
@PostMapping("/typeList") |
|||
public ResultBean<PagerVo<PackagingTypeVo>> typeList() { |
|||
ResultBean rb = ResultBean.fireFail(); |
|||
List<PackagingTypeVo> pv = PackagingTypeService.typeList(); |
|||
return rb.success().setData(pv); |
|||
} |
|||
@ApiOperation("新增") |
|||
@PostMapping("/save") |
|||
public ResultBean save (@RequestBody PackagingTypeDto dto){ |
|||
return PackagingTypeService.save(dto); |
|||
} |
|||
@ApiOperation("修改") |
|||
@PostMapping("/update") |
|||
public ResultBean update (@RequestBody PackagingTypeDto dto){ |
|||
return PackagingTypeService.update(dto); |
|||
} |
|||
@ApiOperation("根据sid查询") |
|||
@GetMapping("/getTypeBySid/{sid}") |
|||
public ResultBean getTypeBySid(@PathVariable String sid){ |
|||
return PackagingTypeService.getTypeBySid(sid); |
|||
} |
|||
@ApiOperation("删除") |
|||
@DeleteMapping("/delete/{sid}") |
|||
public ResultBean delete(@PathVariable String sid ){ |
|||
return PackagingTypeService.del(sid); |
|||
} |
|||
} |
@ -0,0 +1,68 @@ |
|||
package com.yxt.supervise.cyf.biz.packagingtype; |
|||
|
|||
import cn.hutool.core.bean.BeanUtil; |
|||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.yxt.common.base.service.MybatisBaseService; |
|||
import com.yxt.common.base.utils.PagerUtil; |
|||
import com.yxt.common.base.utils.StringUtils; |
|||
import com.yxt.common.core.query.PagerQuery; |
|||
import com.yxt.common.core.result.ResultBean; |
|||
import com.yxt.common.core.vo.PagerVo; |
|||
import com.yxt.supervise.cyf.api.packagingtype.PackagingType; |
|||
import com.yxt.supervise.cyf.api.packagingtype.PackagingTypeDto; |
|||
import com.yxt.supervise.cyf.api.packagingtype.PackagingTypeQuery; |
|||
import com.yxt.supervise.cyf.api.packagingtype.PackagingTypeVo; |
|||
import org.springframework.stereotype.Service; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/5/4 14:37 |
|||
*/ |
|||
@Service |
|||
public class PackagingTypeService extends MybatisBaseService<PackagingTypeMapper, PackagingType> { |
|||
|
|||
|
|||
public PagerVo<PackagingTypeVo> listPageVo(PagerQuery<PackagingTypeQuery> pq) { |
|||
PackagingTypeQuery query = pq.getParams(); |
|||
QueryWrapper<PackagingType> qw = new QueryWrapper<>(); |
|||
if(StringUtils.isNotBlank(query.getName())){ |
|||
qw.like("name",query.getName()); |
|||
} |
|||
|
|||
IPage<PackagingType> page = PagerUtil.queryToPage(pq); |
|||
IPage<PackagingTypeVo> pagging = baseMapper.selectPageVo(page, qw); |
|||
PagerVo<PackagingTypeVo> p = PagerUtil.pageToVo(pagging, null); |
|||
return p; |
|||
} |
|||
public List<PackagingTypeVo> typeList() { |
|||
return baseMapper.typeList(); |
|||
} |
|||
public ResultBean save(PackagingTypeDto dto){ |
|||
ResultBean rb=new ResultBean(); |
|||
PackagingType entity=new PackagingType(); |
|||
BeanUtil.copyProperties(dto, entity, "id", "sid"); |
|||
baseMapper.insert(entity); |
|||
return rb.success().setMsg("新增成功"); |
|||
} |
|||
public ResultBean update (PackagingTypeDto dto){ |
|||
ResultBean rb=new ResultBean(); |
|||
String dtoSid = dto.getSid(); |
|||
PackagingType entity=fetchBySid(dtoSid); |
|||
BeanUtil.copyProperties(dto, entity, "id", "sid"); |
|||
baseMapper.updateById(entity); |
|||
return rb.success().setMsg("修改成功"); |
|||
} |
|||
public ResultBean getTypeBySid(String sid){ |
|||
ResultBean rb=new ResultBean(); |
|||
PackagingType RawPackagingType=baseMapper.getTypeBySid(sid); |
|||
return rb.success().setData(RawPackagingType); |
|||
} |
|||
public ResultBean del(String sid){ |
|||
ResultBean rb=new ResultBean(); |
|||
baseMapper.delete(new QueryWrapper<PackagingType>().eq("sid",sid)); |
|||
return rb.success().setMsg("删除成功"); |
|||
} |
|||
} |
Loading…
Reference in new issue