去除一些无用代码
parent
ea85e762ac
commit
b41f27040e
@ -1,35 +0,0 @@
|
|||||||
package com.glxp.api.controller.system;
|
|
||||||
|
|
||||||
import com.github.pagehelper.PageInfo;
|
|
||||||
import com.glxp.api.annotation.AuthRuleAnnotation;
|
|
||||||
import com.glxp.api.common.res.BaseResponse;
|
|
||||||
import com.glxp.api.common.util.ResultVOUtils;
|
|
||||||
import com.glxp.api.entity.system.SysRemindMsgEntity;
|
|
||||||
import com.glxp.api.entity.system.SysRemindSetEntity;
|
|
||||||
import com.glxp.api.req.system.FilterSysRemindMsgRequest;
|
|
||||||
import com.glxp.api.service.system.SysRemindMsgService;
|
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.List;
|
|
||||||
@ApiIgnore
|
|
||||||
@RestController
|
|
||||||
public class SysRemindMsgController {
|
|
||||||
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
SysRemindMsgService sysRemindMsgService;
|
|
||||||
|
|
||||||
|
|
||||||
@AuthRuleAnnotation("")
|
|
||||||
@GetMapping("/system/remind/msg/list")
|
|
||||||
public BaseResponse list(FilterSysRemindMsgRequest filterSysRemindMsgRequest) {
|
|
||||||
|
|
||||||
List<SysRemindMsgEntity> sysRemindMsgEntities = sysRemindMsgService.filterList(filterSysRemindMsgRequest);
|
|
||||||
PageInfo<SysRemindMsgEntity> pageInfo = new PageInfo<>(sysRemindMsgEntities);
|
|
||||||
return ResultVOUtils.page(pageInfo);
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,26 +0,0 @@
|
|||||||
package com.glxp.api.dao.basic;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
|
||||||
import com.glxp.api.dao.BaseMapperPlus;
|
|
||||||
import com.glxp.api.entity.basic.BasicBusTypeChangeEntity;
|
|
||||||
import com.glxp.api.req.basic.FilterBusTypeChangeRequest;
|
|
||||||
import com.glxp.api.res.basic.BasicBusTypeChangeResponse;
|
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 单据转换表查询接口
|
|
||||||
*/
|
|
||||||
@Mapper
|
|
||||||
public interface BasicBusTypeChangeDao extends BaseMapperPlus<BasicBusTypeChangeDao, BasicBusTypeChangeEntity, BasicBusTypeChangeEntity> {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 查询单据转换设置列表
|
|
||||||
*
|
|
||||||
* @param filterBusTypeChangeRequest
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
List<BasicBusTypeChangeResponse> filterList(FilterBusTypeChangeRequest filterBusTypeChangeRequest);
|
|
||||||
|
|
||||||
}
|
|
@ -1,47 +0,0 @@
|
|||||||
package com.glxp.api.dao.basic;
|
|
||||||
|
|
||||||
import com.glxp.api.dao.BaseMapperPlus;
|
|
||||||
import com.glxp.api.entity.basic.BasicBusTypePreEntity;
|
|
||||||
import com.glxp.api.req.basic.FilterBusTypeChangeRequest;
|
|
||||||
import com.glxp.api.req.basic.FilterBusTypePreRequest;
|
|
||||||
import com.glxp.api.res.basic.BasicBusTypePreResponse;
|
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 补单单据类型查询接口
|
|
||||||
*/
|
|
||||||
@Mapper
|
|
||||||
public interface BasicBusTypePreDao extends BaseMapperPlus<BasicBusTypePreDao, BasicBusTypePreEntity, BasicBusTypePreEntity> {
|
|
||||||
|
|
||||||
List<BasicBusTypePreEntity> filterList(FilterBusTypeChangeRequest busTypeChangeFilterRequest);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 根据单据类型删除
|
|
||||||
*
|
|
||||||
* @param action
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
boolean deleteByAction(@Param("action") String action);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 通过单据类型编码查询补单设置列表
|
|
||||||
*
|
|
||||||
* @param action
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
List<BasicBusTypePreEntity> findByAction(String action);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 查询单据流转列表数据
|
|
||||||
*
|
|
||||||
* @param filterBusTypePreRequest
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
List<BasicBusTypePreResponse> selectBusTypePreResList(FilterBusTypePreRequest filterBusTypePreRequest);
|
|
||||||
|
|
||||||
boolean insertOrUpdateEntity(BasicBusTypePreEntity record);
|
|
||||||
|
|
||||||
}
|
|
@ -1,31 +0,0 @@
|
|||||||
package com.glxp.api.dao.basic;
|
|
||||||
|
|
||||||
import com.glxp.api.dao.BaseMapperPlus;
|
|
||||||
import com.glxp.api.entity.basic.DlEntrustReceEntity;
|
|
||||||
import com.glxp.api.entity.basic.EntrustReceEntity;
|
|
||||||
import com.glxp.api.req.basic.BasicEntrustRecRequest;
|
|
||||||
import com.glxp.api.res.basic.EntrustReceResponse;
|
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Mapper
|
|
||||||
public interface EntrustReceDao extends BaseMapperPlus<EntrustReceDao, EntrustReceEntity, EntrustReceEntity> {
|
|
||||||
|
|
||||||
List<EntrustReceEntity> filterEntrustRec(BasicEntrustRecRequest basicEntrustRecRequest);
|
|
||||||
|
|
||||||
List<DlEntrustReceEntity> downloadEntrustRec(BasicEntrustRecRequest basicEntrustRecRequest);
|
|
||||||
|
|
||||||
List<EntrustReceResponse> filterJoinEntrustRec(BasicEntrustRecRequest basicEntrustRecRequest);
|
|
||||||
|
|
||||||
EntrustReceEntity findByUnique(@Param("action") String action, @Param("entrustUser") Long entrustUser);
|
|
||||||
|
|
||||||
boolean insertEntrustRec(EntrustReceEntity ioOrderStatusEntity);
|
|
||||||
|
|
||||||
boolean deleteById(String id);
|
|
||||||
|
|
||||||
boolean deleteAll();
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
@ -1,25 +0,0 @@
|
|||||||
package com.glxp.api.dao.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.purchase.PurApplyEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurApplyRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurApplyResponse;
|
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Mapper
|
|
||||||
public interface PurApplyDao {
|
|
||||||
|
|
||||||
List<PurApplyResponse> queryPageList(PurApplyRequest purApplyRequest);
|
|
||||||
|
|
||||||
Integer insert(PurApplyEntity purApplyRequest);
|
|
||||||
|
|
||||||
Boolean update(PurApplyEntity purApplyRequest);
|
|
||||||
|
|
||||||
Boolean deleteByIds(@Param("ids") List<Long> ids);
|
|
||||||
|
|
||||||
Boolean deleteById(@Param("id") long id);
|
|
||||||
|
|
||||||
}
|
|
@ -1,31 +0,0 @@
|
|||||||
package com.glxp.api.dao.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.purchase.PurApplyDetailEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurApplyDetailRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderDetailResponse;
|
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Mapper
|
|
||||||
public interface PurApplyDetailDao {
|
|
||||||
|
|
||||||
List<PurApplyDetailEntity> queryPageList(PurApplyDetailRequest purApplyRequest);
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> joinQueryList(PurApplyDetailRequest purApplyRequest);
|
|
||||||
|
|
||||||
Boolean insert(PurApplyDetailEntity purApplyDetailEntity);
|
|
||||||
|
|
||||||
Boolean update(PurApplyDetailEntity purApplyRequest);
|
|
||||||
|
|
||||||
Boolean deleteByIds(@Param("ids") List<Long> ids);
|
|
||||||
|
|
||||||
Boolean deleteByOrderId(@Param("orderIdFk") String orderIdFk);
|
|
||||||
|
|
||||||
boolean insertPurApplyDetailEntity(@Param("datas") List<PurApplyDetailEntity> purApplyDetailEntityList);
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> selectPurApplyDetailList(PurApplyDetailRequest purApplyDetailRequest);
|
|
||||||
|
|
||||||
}
|
|
@ -1,13 +0,0 @@
|
|||||||
package com.glxp.api.dao.purchase;
|
|
||||||
|
|
||||||
import com.glxp.api.dao.BaseMapperPlus;
|
|
||||||
import com.glxp.api.entity.purchase.PurOrderEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurOrderRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderResponse;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public interface PurOrderDao extends BaseMapperPlus<PurOrderDao, PurOrderEntity, PurOrderEntity> {
|
|
||||||
|
|
||||||
List<PurOrderResponse> queryPageList(PurOrderRequest purPlanRequest);
|
|
||||||
}
|
|
@ -1,29 +0,0 @@
|
|||||||
package com.glxp.api.dao.purchase;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
|
||||||
import com.glxp.api.entity.basic.BasicProductsEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurOrderDetailEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurOrderDetailRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderDetailResponse;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public interface PurOrderDetailDao extends BaseMapper<PurOrderDetailEntity> {
|
|
||||||
|
|
||||||
List<PurOrderDetailEntity> queryPageList(PurOrderDetailRequest purOrderDetailRequest);
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> joinQueryList(PurOrderDetailRequest purOrderDetailRequest);
|
|
||||||
|
|
||||||
Boolean update(PurOrderDetailEntity purOrderDetailEntity);
|
|
||||||
|
|
||||||
Boolean deleteByIds(@Param("ids") List<Long> ids);
|
|
||||||
|
|
||||||
Boolean deleteByOrderId(@Param("orderIdFk") String orderIdFk);
|
|
||||||
|
|
||||||
boolean insertPurOrderDetailEntity(@Param("datas") List<PurOrderDetailEntity> purOrderDetailEntityList);
|
|
||||||
|
|
||||||
BasicProductsEntity selectIoOrderDetailBiz(@Param("id") long id);
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> selectDetailList(PurOrderDetailRequest purOrderDetailRequest);
|
|
||||||
}
|
|
@ -1,25 +0,0 @@
|
|||||||
package com.glxp.api.dao.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurPlanRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurPlanResponse;
|
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Mapper
|
|
||||||
public interface PurPlanDao {
|
|
||||||
|
|
||||||
List<PurPlanResponse> queryPageList(PurPlanRequest purPlanRequest);
|
|
||||||
|
|
||||||
Boolean insert(PurPlanEntity purPlanRequest);
|
|
||||||
|
|
||||||
Boolean update(PurPlanEntity purPlanRequest);
|
|
||||||
|
|
||||||
Boolean deleteByIds(@Param("ids") List<Integer> ids);
|
|
||||||
|
|
||||||
Boolean deleteById(@Param("id") long id);
|
|
||||||
|
|
||||||
}
|
|
@ -1,32 +0,0 @@
|
|||||||
package com.glxp.api.dao.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.basic.BasicProductsEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanDetailEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurPlanDetailRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderDetailResponse;
|
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Mapper
|
|
||||||
public interface PurPlanDetailDao {
|
|
||||||
List<PurPlanDetailEntity> queryPageList(PurPlanDetailRequest purApplyRequest);
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> joinQueryList(PurPlanDetailRequest purPlanDetailRequest);
|
|
||||||
|
|
||||||
Boolean insert(PurPlanDetailEntity purPlanDetailRequest);
|
|
||||||
|
|
||||||
Boolean update(PurPlanDetailEntity purPlanDetailRequest);
|
|
||||||
|
|
||||||
Boolean deleteByIds(@Param("ids")List<Long> ids);
|
|
||||||
|
|
||||||
Boolean deleteByOrderId(@Param("orderIdFk") String orderIdFk);
|
|
||||||
|
|
||||||
boolean insertPurPlanDetailEntity(@Param("datas") List<PurPlanDetailEntity> purPlanDetailEntityList);
|
|
||||||
|
|
||||||
BasicProductsEntity selectIoOrderDetailBiz(@Param("id") long id);
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> seletDetaiList(PurPlanDetailRequest purPlanDetailRequest);
|
|
||||||
}
|
|
@ -1,16 +0,0 @@
|
|||||||
package com.glxp.api.dao.system;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
|
||||||
import com.glxp.api.entity.system.SysRemindMsgEntity;
|
|
||||||
import com.glxp.api.entity.system.SysRemindSetEntity;
|
|
||||||
import com.glxp.api.req.system.FilterSysRemindMsgRequest;
|
|
||||||
import com.glxp.api.req.system.FilterSysRemindSetRequest;
|
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Mapper
|
|
||||||
public interface SysRemindMsgMapper extends BaseMapper<SysRemindMsgEntity> {
|
|
||||||
|
|
||||||
List<SysRemindMsgEntity> filterList(FilterSysRemindMsgRequest filterSysRemindMsgRequest);
|
|
||||||
}
|
|
@ -1,64 +0,0 @@
|
|||||||
package com.glxp.api.entity.purchase;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.annotation.IdType;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableField;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableId;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableName;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
@TableName(value = "pur_apply_detail")
|
|
||||||
public class PurApplyDetailEntity {
|
|
||||||
@TableId(value = "id", type = IdType.INPUT)
|
|
||||||
private Integer id;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 订单外键
|
|
||||||
*/
|
|
||||||
@TableField(value = "orderIdFk")
|
|
||||||
private String orderIdFk;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品ID
|
|
||||||
*/
|
|
||||||
@TableField(value = "productId")
|
|
||||||
private Integer productId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品名称
|
|
||||||
*/
|
|
||||||
@TableField(value = "productName")
|
|
||||||
private String productName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 数量
|
|
||||||
*/
|
|
||||||
@TableField(value = "`count`")
|
|
||||||
private Integer count;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商ID
|
|
||||||
*/
|
|
||||||
@TableField(value = "supId")
|
|
||||||
private String supId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 注册证备案证号
|
|
||||||
*/
|
|
||||||
@TableField(value = "zczbhhzbapzbh")
|
|
||||||
private String zczbhhzbapzbh;
|
|
||||||
|
|
||||||
public static final String COL_ID = "id";
|
|
||||||
|
|
||||||
public static final String COL_ORDERIDFK = "orderIdFk";
|
|
||||||
|
|
||||||
public static final String COL_PRODUCTID = "productId";
|
|
||||||
|
|
||||||
public static final String COL_PRODUCTNAME = "productName";
|
|
||||||
|
|
||||||
public static final String COL_COUNT = "count";
|
|
||||||
|
|
||||||
public static final String COL_SUPID = "supId";
|
|
||||||
|
|
||||||
public static final String COL_ZCZBHHZBAPZBH = "zczbhhzbapzbh";
|
|
||||||
}
|
|
@ -1,64 +0,0 @@
|
|||||||
package com.glxp.api.entity.purchase;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.annotation.IdType;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableField;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableId;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableName;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
@TableName(value = "pur_order_detail")
|
|
||||||
public class PurOrderDetailEntity {
|
|
||||||
@TableId(value = "id", type = IdType.AUTO)
|
|
||||||
private Integer id;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 订单外键
|
|
||||||
*/
|
|
||||||
@TableField(value = "orderIdFk")
|
|
||||||
private String orderIdFk;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品ID
|
|
||||||
*/
|
|
||||||
@TableField(value = "productId")
|
|
||||||
private Integer productId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品名称
|
|
||||||
*/
|
|
||||||
@TableField(value = "productName")
|
|
||||||
private String productName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 数量
|
|
||||||
*/
|
|
||||||
@TableField(value = "`count`")
|
|
||||||
private Integer count;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商ID
|
|
||||||
*/
|
|
||||||
@TableField(value = "supId")
|
|
||||||
private String supId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 注册证备案证号
|
|
||||||
*/
|
|
||||||
@TableField(value = "zczbhhzbapzbh")
|
|
||||||
private String zczbhhzbapzbh;
|
|
||||||
|
|
||||||
public static final String COL_ID = "id";
|
|
||||||
|
|
||||||
public static final String COL_ORDERIDFK = "orderIdFk";
|
|
||||||
|
|
||||||
public static final String COL_PRODUCTID = "productId";
|
|
||||||
|
|
||||||
public static final String COL_PRODUCTNAME = "productName";
|
|
||||||
|
|
||||||
public static final String COL_COUNT = "count";
|
|
||||||
|
|
||||||
public static final String COL_SUPID = "supId";
|
|
||||||
|
|
||||||
public static final String COL_ZCZBHHZBAPZBH = "zczbhhzbapzbh";
|
|
||||||
}
|
|
@ -1,64 +0,0 @@
|
|||||||
package com.glxp.api.entity.purchase;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.annotation.IdType;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableField;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableId;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableName;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
@TableName(value = "pur_plan_detail")
|
|
||||||
public class PurPlanDetailEntity {
|
|
||||||
@TableId(value = "id", type = IdType.INPUT)
|
|
||||||
private Integer id;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 订单外键
|
|
||||||
*/
|
|
||||||
@TableField(value = "orderIdFk")
|
|
||||||
private String orderIdFk;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品ID
|
|
||||||
*/
|
|
||||||
@TableField(value = "productId")
|
|
||||||
private Integer productId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品名称
|
|
||||||
*/
|
|
||||||
@TableField(value = "productName")
|
|
||||||
private String productName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 数量
|
|
||||||
*/
|
|
||||||
@TableField(value = "`count`")
|
|
||||||
private Integer count;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商ID
|
|
||||||
*/
|
|
||||||
@TableField(value = "supId")
|
|
||||||
private String supId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 注册证备案证号
|
|
||||||
*/
|
|
||||||
@TableField(value = "zczbhhzbapzbh")
|
|
||||||
private String zczbhhzbapzbh;
|
|
||||||
|
|
||||||
public static final String COL_ID = "id";
|
|
||||||
|
|
||||||
public static final String COL_ORDERIDFK = "orderIdFk";
|
|
||||||
|
|
||||||
public static final String COL_PRODUCTID = "productId";
|
|
||||||
|
|
||||||
public static final String COL_PRODUCTNAME = "productName";
|
|
||||||
|
|
||||||
public static final String COL_COUNT = "count";
|
|
||||||
|
|
||||||
public static final String COL_SUPID = "supId";
|
|
||||||
|
|
||||||
public static final String COL_ZCZBHHZBAPZBH = "zczbhhzbapzbh";
|
|
||||||
}
|
|
@ -1,19 +0,0 @@
|
|||||||
package com.glxp.api.req.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.purchase.PurApplyDetailEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurApplyEntity;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
public class PostPurApplyRequest {
|
|
||||||
|
|
||||||
Integer type;
|
|
||||||
int editStatus;
|
|
||||||
PurApplyEntity purApplyEntity;
|
|
||||||
List<PurApplyDetailEntity> purApplyDetailEntities;
|
|
||||||
// List<StockOrderDetailEntity> subErpOrders;
|
|
||||||
|
|
||||||
}
|
|
@ -1,26 +0,0 @@
|
|||||||
package com.glxp.api.req.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.purchase.PurOrderDetailEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurOrderEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanDetailEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanEntity;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
public class PostPurOrderRequest {
|
|
||||||
|
|
||||||
int editStatus;
|
|
||||||
PurOrderEntity purOrderEntity;
|
|
||||||
List<PurOrderDetailEntity> purOrderDetailEntityList;
|
|
||||||
// List<StockOrderDetailEntity> subErpOrders;
|
|
||||||
Integer type;
|
|
||||||
boolean autoPurchase;
|
|
||||||
String targetSubInv;
|
|
||||||
String targetBillAction;
|
|
||||||
String targetDeptCode;
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
@ -1,24 +0,0 @@
|
|||||||
package com.glxp.api.req.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanDetailEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanEntity;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
public class PostPurPlanRequest {
|
|
||||||
|
|
||||||
int editStatus;
|
|
||||||
PurPlanEntity purPlanEntity;
|
|
||||||
List<PurPlanDetailEntity> purPlanDetailEntities;
|
|
||||||
// List<StockOrderDetailEntity> subErpOrders;
|
|
||||||
Integer type;
|
|
||||||
boolean autoPurchase;
|
|
||||||
String targetSubInv;
|
|
||||||
String targetBillAction;
|
|
||||||
String targetDeptCode;
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
@ -1,70 +0,0 @@
|
|||||||
package com.glxp.api.req.purchase;
|
|
||||||
|
|
||||||
import com.glxp.api.util.page.ListPageRequest;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @author anthony.ywj
|
|
||||||
* @date 2022-10-12
|
|
||||||
*/
|
|
||||||
@Data
|
|
||||||
public class PurApplyDetailRequest extends ListPageRequest {
|
|
||||||
|
|
||||||
|
|
||||||
private Long id;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 关联申购单主键
|
|
||||||
*/
|
|
||||||
private String orderIdFk;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 申购单号
|
|
||||||
*/
|
|
||||||
private String billNo;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 物资编号
|
|
||||||
*/
|
|
||||||
private Long productId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 物资名称
|
|
||||||
*/
|
|
||||||
private String productName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 申购数量
|
|
||||||
*/
|
|
||||||
private Long count;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商ID
|
|
||||||
*/
|
|
||||||
private String supId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 规格型号
|
|
||||||
*/
|
|
||||||
private String spec;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 注册证号
|
|
||||||
*/
|
|
||||||
private String zczbhhzbapzbh;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 生产企业
|
|
||||||
*/
|
|
||||||
private String manufactory;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 开始时间
|
|
||||||
*/
|
|
||||||
private String startDate;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 截止席间
|
|
||||||
*/
|
|
||||||
private String endDate;
|
|
||||||
}
|
|
@ -1,79 +0,0 @@
|
|||||||
package com.glxp.api.req.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.util.page.ListPageRequest;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
import javax.validation.constraints.NotBlank;
|
|
||||||
import javax.validation.constraints.NotNull;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
public class PurOrderDetailRequest extends ListPageRequest {
|
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@NotNull(message = "不能为空")
|
|
||||||
private Long id;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 订单外键
|
|
||||||
*/
|
|
||||||
@NotBlank(message = "订单外键不能为空")
|
|
||||||
private String orderIdFk;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品ID
|
|
||||||
*/
|
|
||||||
@NotNull(message = "产品ID不能为空")
|
|
||||||
private Long productId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品名称
|
|
||||||
*/
|
|
||||||
@NotBlank(message = "产品名称不能为空")
|
|
||||||
private String productName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 数量
|
|
||||||
*/
|
|
||||||
@NotNull(message = "数量不能为空")
|
|
||||||
private Long count;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商ID
|
|
||||||
*/
|
|
||||||
@NotBlank(message = "供应商ID不能为空")
|
|
||||||
private String supId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 采购计划单号
|
|
||||||
*/
|
|
||||||
private String billNo;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 规格型号
|
|
||||||
*/
|
|
||||||
private String spec;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 开始时间
|
|
||||||
*/
|
|
||||||
private String startDate;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 结束时间
|
|
||||||
*/
|
|
||||||
private String endDate;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 注册/凭证号
|
|
||||||
*/
|
|
||||||
private String zczbhhzbapzbh;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 生产企业
|
|
||||||
*/
|
|
||||||
private String manufactory;
|
|
||||||
|
|
||||||
}
|
|
@ -1,79 +0,0 @@
|
|||||||
package com.glxp.api.req.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.util.page.ListPageRequest;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
import javax.validation.constraints.NotBlank;
|
|
||||||
import javax.validation.constraints.NotNull;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
public class PurPlanDetailRequest extends ListPageRequest {
|
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@NotNull(message = "不能为空")
|
|
||||||
private Long id;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 订单外键
|
|
||||||
*/
|
|
||||||
@NotBlank(message = "订单外键不能为空")
|
|
||||||
private String orderIdFk;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品ID
|
|
||||||
*/
|
|
||||||
@NotNull(message = "产品ID不能为空")
|
|
||||||
private Long productId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 产品名称
|
|
||||||
*/
|
|
||||||
@NotBlank(message = "产品名称不能为空")
|
|
||||||
private String productName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 数量
|
|
||||||
*/
|
|
||||||
@NotNull(message = "数量不能为空")
|
|
||||||
private Long count;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商ID
|
|
||||||
*/
|
|
||||||
@NotBlank(message = "供应商ID不能为空")
|
|
||||||
private String supId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 采购计划单号
|
|
||||||
*/
|
|
||||||
private String billNo;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 规格型号
|
|
||||||
*/
|
|
||||||
private String spec;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 开始时间
|
|
||||||
*/
|
|
||||||
private String startDate;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 结束时间
|
|
||||||
*/
|
|
||||||
private String endDate;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 注册/凭证号
|
|
||||||
*/
|
|
||||||
private String zczbhhzbapzbh;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 生产企业
|
|
||||||
*/
|
|
||||||
private String manufactory;
|
|
||||||
|
|
||||||
}
|
|
@ -1,10 +0,0 @@
|
|||||||
package com.glxp.api.req.purchase;
|
|
||||||
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
public class purReceiveRequest {
|
|
||||||
|
|
||||||
private String id;
|
|
||||||
private String orderId;
|
|
||||||
}
|
|
@ -1,63 +0,0 @@
|
|||||||
package com.glxp.api.service.basic;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
|
||||||
import com.glxp.api.entity.basic.BasicBusTypeChangeEntity;
|
|
||||||
import com.glxp.api.req.basic.FilterBusTypeChangeRequest;
|
|
||||||
import com.glxp.api.res.basic.BasicBusTypeChangeResponse;
|
|
||||||
|
|
||||||
import java.util.Date;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 单据生成设置Service
|
|
||||||
*/
|
|
||||||
public interface IBasicBusTypeChangeService extends IService<BasicBusTypeChangeEntity> {
|
|
||||||
|
|
||||||
|
|
||||||
BasicBusTypeChangeEntity selectByOriginAction(String action);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 查询单据生成设置列表
|
|
||||||
*
|
|
||||||
* @param filterBusTypeChangeRequest
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
List<BasicBusTypeChangeResponse> filterList(FilterBusTypeChangeRequest filterBusTypeChangeRequest);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 新增单据生成设置
|
|
||||||
*
|
|
||||||
* @param basicBusTypeChangeEntity
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
int insert(BasicBusTypeChangeEntity basicBusTypeChangeEntity);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 更新单据生成设置
|
|
||||||
*
|
|
||||||
* @param basicBusTypeChangeEntity
|
|
||||||
*/
|
|
||||||
boolean updateBasicBusTypeChange(BasicBusTypeChangeEntity basicBusTypeChangeEntity);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 删除单据生成设置
|
|
||||||
*
|
|
||||||
* @param id
|
|
||||||
*/
|
|
||||||
boolean deleteById(String id);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 校验数据是否存在
|
|
||||||
*
|
|
||||||
* @param basicBusTypeChangeEntity
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
boolean verifyExists(BasicBusTypeChangeEntity basicBusTypeChangeEntity);
|
|
||||||
|
|
||||||
|
|
||||||
List<BasicBusTypeChangeEntity> findByLastTime(Date lastUpdateTime);
|
|
||||||
|
|
||||||
boolean insertVerifyExists(BasicBusTypeChangeEntity basicBusTypeChangeEntity);
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
@ -1,87 +0,0 @@
|
|||||||
package com.glxp.api.service.basic;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
|
||||||
import com.glxp.api.entity.basic.BasicBusTypePreEntity;
|
|
||||||
import com.glxp.api.req.basic.FilterBusTypeChangeRequest;
|
|
||||||
import com.glxp.api.req.basic.FilterBusTypePreRequest;
|
|
||||||
import com.glxp.api.res.basic.BasicBusTypePreResponse;
|
|
||||||
|
|
||||||
import java.util.Date;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 补单单据类型Service
|
|
||||||
*/
|
|
||||||
public interface IBasicBusTypePreService extends IService<BasicBusTypePreEntity> {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 查询补单单据类型数据列表
|
|
||||||
*
|
|
||||||
* @param busTypeChangeFilterRequest
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
List<BasicBusTypePreEntity> filterAll(FilterBusTypeChangeRequest busTypeChangeFilterRequest);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 根据ID删除补单单据类型
|
|
||||||
*
|
|
||||||
* @param id
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
boolean deleteById(String id);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 根据单据类型编码删除补单单据类型
|
|
||||||
*
|
|
||||||
* @param action
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
|
|
||||||
boolean deleteByAction(String action);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 更新补单单据类型
|
|
||||||
*
|
|
||||||
* @param basicBusTypePreEntity
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
|
|
||||||
boolean updateBusChangeType(BasicBusTypePreEntity basicBusTypePreEntity);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 新增补单单据类型
|
|
||||||
*
|
|
||||||
* @param basicBusTypePreEntity
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
boolean insertBusChangeType(BasicBusTypePreEntity basicBusTypePreEntity);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 通过单据类型编码查询补单设置
|
|
||||||
*
|
|
||||||
* @param action
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
List<BasicBusTypePreEntity> findByAction(String action);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 查询单据流转列表数据
|
|
||||||
*
|
|
||||||
* @param filterBusTypePreRequest
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
List<BasicBusTypePreResponse> filterBusTypePreResList(FilterBusTypePreRequest filterBusTypePreRequest);
|
|
||||||
|
|
||||||
|
|
||||||
BasicBusTypePreEntity findByOriginAction(String originAction);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 校验数据是否重复
|
|
||||||
*
|
|
||||||
* @param basicBusTypePreEntity
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
boolean verifyExists(BasicBusTypePreEntity basicBusTypePreEntity);
|
|
||||||
|
|
||||||
List<BasicBusTypePreEntity> findByLastTime(Date lastUpdateTime);
|
|
||||||
}
|
|
@ -1,99 +0,0 @@
|
|||||||
package com.glxp.api.service.basic.impl;
|
|
||||||
|
|
||||||
import cn.hutool.core.collection.CollUtil;
|
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
||||||
import com.github.pagehelper.PageHelper;
|
|
||||||
import com.glxp.api.dao.basic.BasicBusTypeChangeDao;
|
|
||||||
import com.glxp.api.entity.basic.BasicBusTypeChangeEntity;
|
|
||||||
import com.glxp.api.req.basic.FilterBusTypeChangeRequest;
|
|
||||||
import com.glxp.api.res.basic.BasicBusTypeChangeResponse;
|
|
||||||
import com.glxp.api.service.auth.CustomerService;
|
|
||||||
import com.glxp.api.service.basic.IBasicBusTypeChangeService;
|
|
||||||
import lombok.extern.slf4j.Slf4j;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.Date;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Slf4j
|
|
||||||
@Service
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
|
||||||
public class BasicBusTypeChangeServiceImpl extends ServiceImpl<BasicBusTypeChangeDao, BasicBusTypeChangeEntity> implements IBasicBusTypeChangeService {
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
private CustomerService customerService;
|
|
||||||
@Resource
|
|
||||||
private BasicBusTypeChangeDao basicBusTypeChangeDao;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public BasicBusTypeChangeEntity selectByOriginAction(String action) {
|
|
||||||
return basicBusTypeChangeDao.selectOne(new QueryWrapper<BasicBusTypeChangeEntity>().eq("originAction", action));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<BasicBusTypeChangeResponse> filterList(FilterBusTypeChangeRequest filterBusTypeChangeRequest) {
|
|
||||||
if (null == filterBusTypeChangeRequest) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (null != filterBusTypeChangeRequest.getPage() && null != filterBusTypeChangeRequest.getLimit()) {
|
|
||||||
PageHelper.offsetPage((filterBusTypeChangeRequest.getPage() - 1) * filterBusTypeChangeRequest.getLimit(), filterBusTypeChangeRequest.getLimit());
|
|
||||||
}
|
|
||||||
return basicBusTypeChangeDao.filterList(filterBusTypeChangeRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public int insert(BasicBusTypeChangeEntity basicBusTypeChangeEntity) {
|
|
||||||
setUpdateInfo(basicBusTypeChangeEntity);
|
|
||||||
return basicBusTypeChangeDao.insert(basicBusTypeChangeEntity);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean updateBasicBusTypeChange(BasicBusTypeChangeEntity basicBusTypeChangeEntity) {
|
|
||||||
setUpdateInfo(basicBusTypeChangeEntity);
|
|
||||||
return basicBusTypeChangeDao.updateById(basicBusTypeChangeEntity) != 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean deleteById(String id) {
|
|
||||||
return basicBusTypeChangeDao.deleteById(id) != 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean verifyExists(BasicBusTypeChangeEntity basicBusTypeChangeEntity) {
|
|
||||||
QueryWrapper<BasicBusTypeChangeEntity> wrapper = new QueryWrapper<>();
|
|
||||||
wrapper.eq("originAction", basicBusTypeChangeEntity.getOriginAction())
|
|
||||||
.eq("targetAction", basicBusTypeChangeEntity.getTargetAction())
|
|
||||||
.eq("originName", basicBusTypeChangeEntity.getOriginName()).ne("id", basicBusTypeChangeEntity.getId());
|
|
||||||
return basicBusTypeChangeDao.exists(wrapper);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean insertVerifyExists(BasicBusTypeChangeEntity basicBusTypeChangeEntity) {
|
|
||||||
QueryWrapper<BasicBusTypeChangeEntity> wrapper = new QueryWrapper<>();
|
|
||||||
wrapper.eq("originAction", basicBusTypeChangeEntity.getOriginAction())
|
|
||||||
.eq("targetAction", basicBusTypeChangeEntity.getTargetAction())
|
|
||||||
.eq("originName", basicBusTypeChangeEntity.getOriginName());
|
|
||||||
return basicBusTypeChangeDao.exists(wrapper);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<BasicBusTypeChangeEntity> findByLastTime(Date lastUpdateTime) {
|
|
||||||
return basicBusTypeChangeDao.selectList(new QueryWrapper<BasicBusTypeChangeEntity>().gt("updateTime", lastUpdateTime));
|
|
||||||
}
|
|
||||||
|
|
||||||
private void setUpdateInfo(BasicBusTypeChangeEntity basicBusTypeChangeEntity) {
|
|
||||||
Date now = new Date();
|
|
||||||
String userId = String.valueOf(customerService.getUserBean().getId());
|
|
||||||
basicBusTypeChangeEntity.setUpdateTime(now);
|
|
||||||
basicBusTypeChangeEntity.setUpdateUser(userId);
|
|
||||||
if (null == basicBusTypeChangeEntity.getId()) {
|
|
||||||
basicBusTypeChangeEntity.setCreateTime(now);
|
|
||||||
basicBusTypeChangeEntity.setCreateUser(userId);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,129 +0,0 @@
|
|||||||
package com.glxp.api.service.basic.impl;
|
|
||||||
|
|
||||||
import cn.hutool.core.collection.CollUtil;
|
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
||||||
import com.github.pagehelper.PageHelper;
|
|
||||||
import com.glxp.api.dao.basic.BasicBusTypePreDao;
|
|
||||||
import com.glxp.api.entity.basic.BasicBusTypePreEntity;
|
|
||||||
import com.glxp.api.req.basic.FilterBusTypeChangeRequest;
|
|
||||||
import com.glxp.api.req.basic.FilterBusTypePreRequest;
|
|
||||||
import com.glxp.api.res.basic.BasicBusTypePreResponse;
|
|
||||||
import com.glxp.api.service.auth.CustomerService;
|
|
||||||
import com.glxp.api.service.basic.IBasicBusTypePreService;
|
|
||||||
import lombok.extern.slf4j.Slf4j;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.Date;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Slf4j
|
|
||||||
@Service
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
|
||||||
public class BasicBusTypePreServiceImpl extends ServiceImpl<BasicBusTypePreDao, BasicBusTypePreEntity> implements IBasicBusTypePreService {
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
private BasicBusTypePreDao basicBusTypePreDao;
|
|
||||||
@Resource
|
|
||||||
private CustomerService customerService;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<BasicBusTypePreEntity> filterAll(FilterBusTypeChangeRequest busTypeChangeFilterRequest) {
|
|
||||||
if (null != busTypeChangeFilterRequest.getPage() && null != busTypeChangeFilterRequest.getLimit()) {
|
|
||||||
PageHelper.offsetPage((busTypeChangeFilterRequest.getPage() - 1) * busTypeChangeFilterRequest.getLimit(), busTypeChangeFilterRequest.getLimit());
|
|
||||||
}
|
|
||||||
return basicBusTypePreDao.filterList(busTypeChangeFilterRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean deleteById(String id) {
|
|
||||||
return basicBusTypePreDao.deleteById(id) != 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean deleteByAction(String action) {
|
|
||||||
return basicBusTypePreDao.deleteByAction(action);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean updateBusChangeType(BasicBusTypePreEntity basicBusTypePreEntity) {
|
|
||||||
setUpdateInfo(basicBusTypePreEntity);
|
|
||||||
return basicBusTypePreDao.updateById(basicBusTypePreEntity) != 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean insertBusChangeType(BasicBusTypePreEntity basicBusTypePreEntity) {
|
|
||||||
setUpdateInfo(basicBusTypePreEntity);
|
|
||||||
return basicBusTypePreDao.insert(basicBusTypePreEntity) != 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<BasicBusTypePreEntity> findByAction(String action) {
|
|
||||||
return basicBusTypePreDao.findByAction(action);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<BasicBusTypePreResponse> filterBusTypePreResList(FilterBusTypePreRequest filterBusTypePreRequest) {
|
|
||||||
if (null == filterBusTypePreRequest) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (null != filterBusTypePreRequest.getPage() && null != filterBusTypePreRequest.getLimit()) {
|
|
||||||
PageHelper.offsetPage((filterBusTypePreRequest.getPage() - 1) * filterBusTypePreRequest.getLimit(), filterBusTypePreRequest.getLimit());
|
|
||||||
}
|
|
||||||
return basicBusTypePreDao.selectBusTypePreResList(filterBusTypePreRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public BasicBusTypePreEntity findByOriginAction(String originAction) {
|
|
||||||
return basicBusTypePreDao.selectOne(new QueryWrapper<BasicBusTypePreEntity>().eq("originAction", originAction));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean verifyExists(BasicBusTypePreEntity basicBusTypePreEntity) {
|
|
||||||
QueryWrapper<BasicBusTypePreEntity> wrapper = new QueryWrapper<>();
|
|
||||||
wrapper.eq("action", basicBusTypePreEntity.getAction())
|
|
||||||
.eq("originAction", basicBusTypePreEntity.getOriginAction())
|
|
||||||
.eq("invCode", basicBusTypePreEntity.getInvCode())
|
|
||||||
.eq(null != basicBusTypePreEntity.getBeforeTime(), "beforeTime", basicBusTypePreEntity.getBeforeTime())
|
|
||||||
.eq(null != basicBusTypePreEntity.getDefaultInvCode(), "defaultInvCode", basicBusTypePreEntity.getDefaultInvCode())
|
|
||||||
.eq(null != basicBusTypePreEntity.getSupplementAll(), "supplementAll", basicBusTypePreEntity.getSupplementAll());
|
|
||||||
|
|
||||||
List<BasicBusTypePreEntity> list = basicBusTypePreDao.selectList(wrapper);
|
|
||||||
if (CollUtil.isNotEmpty(list)) {
|
|
||||||
if (null != basicBusTypePreEntity.getId()) {
|
|
||||||
for (BasicBusTypePreEntity busTypePreEntity : list) {
|
|
||||||
if (busTypePreEntity.getId() != basicBusTypePreEntity.getId()) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<BasicBusTypePreEntity> findByLastTime(Date lastUpdateTime) {
|
|
||||||
return basicBusTypePreDao.selectList(new QueryWrapper<BasicBusTypePreEntity>().gt("updateTime", lastUpdateTime));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 设置创建/更新信息
|
|
||||||
*
|
|
||||||
* @param basicBusTypePreEntity
|
|
||||||
*/
|
|
||||||
private void setUpdateInfo(BasicBusTypePreEntity basicBusTypePreEntity) {
|
|
||||||
Date now = new Date();
|
|
||||||
String userId = customerService.getUserIdStr();
|
|
||||||
if (null == basicBusTypePreEntity.getId()) {
|
|
||||||
basicBusTypePreEntity.setCreateUser(userId);
|
|
||||||
basicBusTypePreEntity.setCreateTime(now);
|
|
||||||
}
|
|
||||||
basicBusTypePreEntity.setUpdateUser(userId);
|
|
||||||
basicBusTypePreEntity.setUpdateTime(now);
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,38 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.purchase.PurApplyDetailEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurApplyDetailRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderDetailResponse;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public interface PurApplyDetailService {
|
|
||||||
|
|
||||||
List<PurApplyDetailEntity> queryPageList(PurApplyDetailRequest purApplyRequest);
|
|
||||||
|
|
||||||
List<PurApplyDetailEntity> findByOrderId(String orderId);
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> joinQueryList(PurApplyDetailRequest purApplyRequest);
|
|
||||||
|
|
||||||
|
|
||||||
Boolean insert(PurApplyDetailEntity purApplyRequest);
|
|
||||||
|
|
||||||
Boolean update(PurApplyDetailEntity purApplyRequest);
|
|
||||||
|
|
||||||
Boolean deleteByIds(List<Long> ids);
|
|
||||||
|
|
||||||
Boolean deleteByOrderId(String orderIdfK);
|
|
||||||
|
|
||||||
List<PurApplyDetailEntity> selectPurApplyDetailList(PurApplyDetailRequest purApplyRequest);
|
|
||||||
|
|
||||||
boolean insertPurApplyDetailEntity(List<PurApplyDetailEntity> purApplyDetailEntityList);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 查询申购单据明细列表
|
|
||||||
*
|
|
||||||
* @param purApplyDetailRequest
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
List<PurOrderDetailResponse> getDetailList(PurApplyDetailRequest purApplyDetailRequest);
|
|
||||||
}
|
|
@ -1,22 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.purchase.PurApplyEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurApplyRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurApplyResponse;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public interface PurApplyService {
|
|
||||||
|
|
||||||
List<PurApplyResponse> queryPageList(PurApplyRequest purApplyRequest);
|
|
||||||
|
|
||||||
Integer insert(PurApplyEntity purApplyEntity);
|
|
||||||
|
|
||||||
Boolean update(PurApplyEntity purApplyRequest);
|
|
||||||
|
|
||||||
Boolean deleteByIds(List<Long> ids);
|
|
||||||
|
|
||||||
Boolean deleteById(long id);
|
|
||||||
}
|
|
@ -1,35 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.basic.BasicProductsEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurOrderDetailEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurOrderDetailRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderDetailResponse;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public interface PurOrderDetailService {
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> joinQueryList(PurOrderDetailRequest purOrderDetailRequest);
|
|
||||||
|
|
||||||
|
|
||||||
List<PurOrderDetailEntity> findByOrderId(String orderId);
|
|
||||||
|
|
||||||
List<PurOrderDetailEntity> queryPageList(PurOrderDetailRequest purOrderDetailRequest);
|
|
||||||
|
|
||||||
List<PurOrderDetailEntity> getPurOrderDetailEntityList(PurOrderDetailRequest purOrderDetailRequest);
|
|
||||||
|
|
||||||
Boolean insert(PurOrderDetailEntity purOrderDetailEntity);
|
|
||||||
|
|
||||||
Boolean update(PurOrderDetailEntity purOrderDetailEntity);
|
|
||||||
|
|
||||||
Boolean deleteByIds(List<Long> ids);
|
|
||||||
|
|
||||||
Boolean deleteByOrderId(String orderIdfK);
|
|
||||||
|
|
||||||
boolean insertPurOrderDetailEntity(List<PurOrderDetailEntity> purOrderDetailEntityList);
|
|
||||||
|
|
||||||
BasicProductsEntity selectIoOrderDetailBiz(long id);
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> getDetailList(PurOrderDetailRequest purOrderDetailRequest);
|
|
||||||
}
|
|
@ -1,35 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.basic.BasicProductsEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanDetailEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurPlanDetailRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderDetailResponse;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public interface PurPlanDetailService {
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> joinQueryList(PurPlanDetailRequest purApplyRequest);
|
|
||||||
|
|
||||||
|
|
||||||
List<PurPlanDetailEntity> findByOrderId(String orderId);
|
|
||||||
|
|
||||||
List<PurPlanDetailEntity> queryPageList(PurPlanDetailRequest purPlanDetailRequest);
|
|
||||||
|
|
||||||
List<PurPlanDetailEntity> getPurPlanDetailEntityList(PurPlanDetailRequest purPlanDetailRequest);
|
|
||||||
|
|
||||||
Boolean insert(PurPlanDetailEntity purPlanDetailRequest);
|
|
||||||
|
|
||||||
Boolean update(PurPlanDetailEntity purPlanDetailRequest);
|
|
||||||
|
|
||||||
Boolean deleteByIds(List<Long> ids);
|
|
||||||
|
|
||||||
Boolean deleteByOrderId(String orderIdfK);
|
|
||||||
|
|
||||||
boolean insertPurPlanDetailEntity(List<PurPlanDetailEntity> purPlanDetailEntityList);
|
|
||||||
|
|
||||||
BasicProductsEntity selectIoOrderDetailBiz(long id);
|
|
||||||
|
|
||||||
List<PurOrderDetailResponse> getDetailList(PurPlanDetailRequest purPlanDetailRequest);
|
|
||||||
}
|
|
@ -1,25 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurPlanRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurPlanResponse;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public interface PurPlanService {
|
|
||||||
|
|
||||||
List<PurPlanResponse> queryPageList(PurPlanRequest purPlanRequest);
|
|
||||||
|
|
||||||
Boolean insert(PurPlanEntity purPlanRequest);
|
|
||||||
|
|
||||||
Boolean update(PurPlanEntity purPlanRequest);
|
|
||||||
|
|
||||||
Boolean deleteByIds(List<Integer> ids);
|
|
||||||
|
|
||||||
Boolean deleteById(long id);
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
@ -1,104 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase.impl;
|
|
||||||
|
|
||||||
import com.github.pagehelper.PageHelper;
|
|
||||||
|
|
||||||
import com.glxp.api.dao.purchase.PurApplyDetailDao;
|
|
||||||
import com.glxp.api.entity.purchase.PurApplyDetailEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurApplyDetailRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderDetailResponse;
|
|
||||||
import com.glxp.api.service.purchase.PurApplyDetailService;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Service
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
|
||||||
public class PurApplyDetailImplService implements PurApplyDetailService {
|
|
||||||
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
PurApplyDetailDao purApplyDetailDao;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurApplyDetailEntity> queryPageList(PurApplyDetailRequest purApplyRequest) {
|
|
||||||
if (purApplyRequest == null) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (purApplyRequest.getPage() != null) {
|
|
||||||
int offset = (purApplyRequest.getPage() - 1) * purApplyRequest.getLimit();
|
|
||||||
PageHelper.offsetPage(offset, purApplyRequest.getLimit());
|
|
||||||
}
|
|
||||||
List<PurApplyDetailEntity> data = purApplyDetailDao.queryPageList(purApplyRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurApplyDetailEntity> findByOrderId(String orderId) {
|
|
||||||
if (orderId == null) {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
PurApplyDetailRequest purApplyDetailRequest = new PurApplyDetailRequest();
|
|
||||||
purApplyDetailRequest.setOrderIdFk(orderId);
|
|
||||||
List<PurApplyDetailEntity> data = purApplyDetailDao.queryPageList(purApplyDetailRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurOrderDetailResponse> joinQueryList(PurApplyDetailRequest purApplyRequest) {
|
|
||||||
if (purApplyRequest == null) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (purApplyRequest.getPage() != null) {
|
|
||||||
int offset = (purApplyRequest.getPage() - 1) * purApplyRequest.getLimit();
|
|
||||||
PageHelper.offsetPage(offset, purApplyRequest.getLimit());
|
|
||||||
}
|
|
||||||
List<PurOrderDetailResponse> data = purApplyDetailDao.joinQueryList(purApplyRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean insert(PurApplyDetailEntity purApplyRequest) {
|
|
||||||
return purApplyDetailDao.insert(purApplyRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean update(PurApplyDetailEntity purApplyRequest) {
|
|
||||||
return purApplyDetailDao.update(purApplyRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteByIds(List<Long> ids) {
|
|
||||||
return purApplyDetailDao.deleteByIds(ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteByOrderId(String orderIdfK) {
|
|
||||||
return purApplyDetailDao.deleteByOrderId(orderIdfK);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurApplyDetailEntity> selectPurApplyDetailList(PurApplyDetailRequest purApplyRequest) {
|
|
||||||
return purApplyDetailDao.queryPageList(purApplyRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean insertPurApplyDetailEntity(List<PurApplyDetailEntity> purApplyDetailEntityList) {
|
|
||||||
return purApplyDetailDao.insertPurApplyDetailEntity(purApplyDetailEntityList);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurOrderDetailResponse> getDetailList(PurApplyDetailRequest purApplyDetailRequest) {
|
|
||||||
if (null == purApplyDetailRequest) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (null == purApplyDetailRequest.getPage() && null != purApplyDetailRequest.getLimit()) {
|
|
||||||
PageHelper.offsetPage((purApplyDetailRequest.getPage() - 1) * purApplyDetailRequest.getLimit(), purApplyDetailRequest.getLimit());
|
|
||||||
}
|
|
||||||
return purApplyDetailDao.selectPurApplyDetailList(purApplyDetailRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
@ -1,55 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase.impl;
|
|
||||||
|
|
||||||
import com.github.pagehelper.PageHelper;
|
|
||||||
import com.glxp.api.dao.purchase.PurApplyDao;
|
|
||||||
import com.glxp.api.entity.purchase.PurApplyEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurApplyRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurApplyResponse;
|
|
||||||
import com.glxp.api.service.purchase.PurApplyService;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Service
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
|
||||||
public class PurApplyServiceImpl implements PurApplyService {
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
PurApplyDao purApplyDao;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurApplyResponse> queryPageList(PurApplyRequest purApplyRequest) {
|
|
||||||
if (purApplyRequest == null) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (purApplyRequest.getPage() != null) {
|
|
||||||
int offset = (purApplyRequest.getPage() - 1) * purApplyRequest.getLimit();
|
|
||||||
PageHelper.offsetPage(offset, purApplyRequest.getLimit());
|
|
||||||
}
|
|
||||||
List<PurApplyResponse> data = purApplyDao.queryPageList(purApplyRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Integer insert(PurApplyEntity purApplyEntity) {
|
|
||||||
return purApplyDao.insert(purApplyEntity);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean update(PurApplyEntity purApplyRequest) {
|
|
||||||
return purApplyDao.update(purApplyRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteByIds(List<Long> ids) {
|
|
||||||
return purApplyDao.deleteByIds(ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteById(long id) {
|
|
||||||
return purApplyDao.deleteById(id);
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,104 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase.impl;
|
|
||||||
|
|
||||||
import com.github.pagehelper.PageHelper;
|
|
||||||
import com.glxp.api.dao.purchase.PurOrderDetailDao;
|
|
||||||
import com.glxp.api.entity.basic.BasicProductsEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurOrderDetailEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurOrderDetailRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderDetailResponse;
|
|
||||||
import com.glxp.api.service.purchase.PurOrderDetailService;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Service
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
|
||||||
public class PurOrderDetailServiceImpl implements PurOrderDetailService {
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
PurOrderDetailDao purOrderDetailDao;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurOrderDetailResponse> joinQueryList(PurOrderDetailRequest purOrderDetailRequest) {
|
|
||||||
if (purOrderDetailRequest == null) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (purOrderDetailRequest.getPage() != null) {
|
|
||||||
int offset = (purOrderDetailRequest.getPage() - 1) * purOrderDetailRequest.getLimit();
|
|
||||||
PageHelper.offsetPage(offset, purOrderDetailRequest.getLimit());
|
|
||||||
}
|
|
||||||
List<PurOrderDetailResponse> data = purOrderDetailDao.joinQueryList(purOrderDetailRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurOrderDetailEntity> findByOrderId(String orderId) {
|
|
||||||
PurOrderDetailRequest purOrderDetailRequest = new PurOrderDetailRequest();
|
|
||||||
purOrderDetailRequest.setOrderIdFk(orderId);
|
|
||||||
List<PurOrderDetailEntity> data = purOrderDetailDao.queryPageList(purOrderDetailRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurOrderDetailEntity> queryPageList(PurOrderDetailRequest purOrderDetailRequest) {
|
|
||||||
if (purOrderDetailRequest == null) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (purOrderDetailRequest.getPage() != null) {
|
|
||||||
int offset = (purOrderDetailRequest.getPage() - 1) * purOrderDetailRequest.getLimit();
|
|
||||||
PageHelper.offsetPage(offset, purOrderDetailRequest.getLimit());
|
|
||||||
}
|
|
||||||
List<PurOrderDetailEntity> data = purOrderDetailDao.queryPageList(purOrderDetailRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurOrderDetailEntity> getPurOrderDetailEntityList(PurOrderDetailRequest purOrderDetailRequest) {
|
|
||||||
return purOrderDetailDao.queryPageList(purOrderDetailRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean insert(PurOrderDetailEntity purOrderDetailEntity) {
|
|
||||||
return purOrderDetailDao.insert(purOrderDetailEntity)>0 ? true:false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean update(PurOrderDetailEntity purOrderDetailEntity) {
|
|
||||||
return purOrderDetailDao.update(purOrderDetailEntity);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteByIds(List<Long> ids) {
|
|
||||||
return purOrderDetailDao.deleteByIds(ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteByOrderId(String orderIdfK) {
|
|
||||||
return purOrderDetailDao.deleteByOrderId(orderIdfK);
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean insertPurOrderDetailEntity(List<PurOrderDetailEntity> purOrderDetailEntityList) {
|
|
||||||
return purOrderDetailDao.insertPurOrderDetailEntity(purOrderDetailEntityList);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public BasicProductsEntity selectIoOrderDetailBiz(long id) {
|
|
||||||
return purOrderDetailDao.selectIoOrderDetailBiz(id);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurOrderDetailResponse> getDetailList(PurOrderDetailRequest purOrderDetailRequest) {
|
|
||||||
if (null == purOrderDetailRequest) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (null != purOrderDetailRequest.getPage() && null != purOrderDetailRequest.getLimit()) {
|
|
||||||
PageHelper.offsetPage((purOrderDetailRequest.getPage() - 1) * purOrderDetailRequest.getLimit(), purOrderDetailRequest.getLimit());
|
|
||||||
}
|
|
||||||
return purOrderDetailDao.selectDetailList(purOrderDetailRequest);
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,105 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase.impl;
|
|
||||||
|
|
||||||
import com.github.pagehelper.PageHelper;
|
|
||||||
import com.glxp.api.dao.purchase.PurPlanDetailDao;
|
|
||||||
import com.glxp.api.entity.basic.BasicProductsEntity;
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanDetailEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurPlanDetailRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurOrderDetailResponse;
|
|
||||||
import com.glxp.api.service.purchase.PurPlanDetailService;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Service
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
|
||||||
public class PurPlanDetailServiceImpl implements PurPlanDetailService {
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
PurPlanDetailDao purPlanDetailDao;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurOrderDetailResponse> joinQueryList(PurPlanDetailRequest purApplyRequest) {
|
|
||||||
if (purApplyRequest == null) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (purApplyRequest.getPage() != null) {
|
|
||||||
int offset = (purApplyRequest.getPage() - 1) * purApplyRequest.getLimit();
|
|
||||||
PageHelper.offsetPage(offset, purApplyRequest.getLimit());
|
|
||||||
}
|
|
||||||
List<PurOrderDetailResponse> data = purPlanDetailDao.joinQueryList(purApplyRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurPlanDetailEntity> findByOrderId(String orderId) {
|
|
||||||
PurPlanDetailRequest purPlanDetailRequest = new PurPlanDetailRequest();
|
|
||||||
purPlanDetailRequest.setOrderIdFk(orderId);
|
|
||||||
List<PurPlanDetailEntity> data = purPlanDetailDao.queryPageList(purPlanDetailRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurPlanDetailEntity> queryPageList(PurPlanDetailRequest purPlanDetailRequest) {
|
|
||||||
if (purPlanDetailRequest == null) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (purPlanDetailRequest.getPage() != null) {
|
|
||||||
int offset = (purPlanDetailRequest.getPage() - 1) * purPlanDetailRequest.getLimit();
|
|
||||||
PageHelper.offsetPage(offset, purPlanDetailRequest.getLimit());
|
|
||||||
}
|
|
||||||
List<PurPlanDetailEntity> data = purPlanDetailDao.queryPageList(purPlanDetailRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurPlanDetailEntity> getPurPlanDetailEntityList(PurPlanDetailRequest purPlanDetailRequest) {
|
|
||||||
return purPlanDetailDao.queryPageList(purPlanDetailRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean insert(PurPlanDetailEntity purPlanDetailRequest) {
|
|
||||||
return purPlanDetailDao.insert(purPlanDetailRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean update(PurPlanDetailEntity purPlanDetailRequest) {
|
|
||||||
return purPlanDetailDao.update(purPlanDetailRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteByIds(List<Long> ids) {
|
|
||||||
return purPlanDetailDao.deleteByIds(ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteByOrderId(String orderIdfK) {
|
|
||||||
return purPlanDetailDao.deleteByOrderId(orderIdfK);
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean insertPurPlanDetailEntity(List<PurPlanDetailEntity> purPlanDetailEntityList) {
|
|
||||||
return purPlanDetailDao.insertPurPlanDetailEntity(purPlanDetailEntityList);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public BasicProductsEntity selectIoOrderDetailBiz(long id) {
|
|
||||||
return purPlanDetailDao.selectIoOrderDetailBiz(id);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurOrderDetailResponse> getDetailList(PurPlanDetailRequest purPlanDetailRequest) {
|
|
||||||
if (null == purPlanDetailRequest) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (null != purPlanDetailRequest.getPage() && null != purPlanDetailRequest.getLimit()) {
|
|
||||||
PageHelper.offsetPage((purPlanDetailRequest.getPage() - 1) * purPlanDetailRequest.getLimit(), purPlanDetailRequest.getLimit());
|
|
||||||
}
|
|
||||||
return purPlanDetailDao.seletDetaiList(purPlanDetailRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,55 +0,0 @@
|
|||||||
package com.glxp.api.service.purchase.impl;
|
|
||||||
|
|
||||||
import com.github.pagehelper.PageHelper;
|
|
||||||
import com.glxp.api.dao.purchase.PurPlanDao;
|
|
||||||
import com.glxp.api.entity.purchase.PurPlanEntity;
|
|
||||||
import com.glxp.api.req.purchase.PurPlanRequest;
|
|
||||||
import com.glxp.api.res.purchase.PurPlanResponse;
|
|
||||||
import com.glxp.api.service.purchase.PurPlanService;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Service
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
|
||||||
public class PurPlanServiceImpl implements PurPlanService {
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
PurPlanDao purPlanDao;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<PurPlanResponse> queryPageList(PurPlanRequest purPlanRequest) {
|
|
||||||
if (purPlanRequest == null) {
|
|
||||||
return Collections.emptyList();
|
|
||||||
}
|
|
||||||
if (purPlanRequest.getPage() != null) {
|
|
||||||
int offset = (purPlanRequest.getPage() - 1) * purPlanRequest.getLimit();
|
|
||||||
PageHelper.offsetPage(offset, purPlanRequest.getLimit());
|
|
||||||
}
|
|
||||||
List<PurPlanResponse> data = purPlanDao.queryPageList(purPlanRequest);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean insert(PurPlanEntity purPlanRequest) {
|
|
||||||
return purPlanDao.insert(purPlanRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean update(PurPlanEntity purPlanRequest) {
|
|
||||||
return purPlanDao.update(purPlanRequest);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteByIds(List<Integer> ids) {
|
|
||||||
return purPlanDao.deleteByIds(ids);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean deleteById(long id) {
|
|
||||||
return purPlanDao.deleteById(id);
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,12 +0,0 @@
|
|||||||
package com.glxp.api.service.system;
|
|
||||||
|
|
||||||
import com.glxp.api.entity.system.SysRemindMsgEntity;
|
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
|
||||||
import com.glxp.api.req.system.FilterSysRemindMsgRequest;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public interface SysRemindMsgService {
|
|
||||||
|
|
||||||
List<SysRemindMsgEntity> filterList(FilterSysRemindMsgRequest filterSysRemindMsgRequest);
|
|
||||||
}
|
|
@ -1,33 +0,0 @@
|
|||||||
package com.glxp.api.service.system.impl;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
||||||
import com.github.pagehelper.PageHelper;
|
|
||||||
import com.glxp.api.req.system.FilterSysRemindMsgRequest;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
|
|
||||||
import com.glxp.api.dao.system.SysRemindMsgMapper;
|
|
||||||
import com.glxp.api.entity.system.SysRemindMsgEntity;
|
|
||||||
import com.glxp.api.service.system.SysRemindMsgService;
|
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Service
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
|
||||||
public class SysRemindMsgServiceImpl implements SysRemindMsgService {
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
SysRemindMsgMapper sysRemindMsgMapper;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public List<SysRemindMsgEntity> filterList(FilterSysRemindMsgRequest filterSysRemindMsgRequest) {
|
|
||||||
|
|
||||||
if (filterSysRemindMsgRequest.getPage() != null) {
|
|
||||||
int offset = (filterSysRemindMsgRequest.getPage() - 1) * filterSysRemindMsgRequest.getLimit();
|
|
||||||
PageHelper.offsetPage(offset, filterSysRemindMsgRequest.getLimit());
|
|
||||||
}
|
|
||||||
return sysRemindMsgMapper.filterList(filterSysRemindMsgRequest);
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,31 +0,0 @@
|
|||||||
<?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.glxp.api.dao.basic.BasicBusTypeChangeDao">
|
|
||||||
<select id="filterList" resultType="com.glxp.api.res.basic.BasicBusTypeChangeResponse">
|
|
||||||
SELECT bc.*,
|
|
||||||
bu.name targetName,
|
|
||||||
(select originName from basic_bustype_change where originAction = bc.targetBusAction) as targetBusName
|
|
||||||
FROM basic_bustype_change bc
|
|
||||||
LEFT JOIN basic_bussiness_type bu ON bc.targetAction = bu.action
|
|
||||||
<where>
|
|
||||||
<if test="originAction != null and originAction != ''">
|
|
||||||
AND bc.originAction = #{originAction}
|
|
||||||
</if>
|
|
||||||
<if test="originName != null and originName != ''">
|
|
||||||
AND bc.originName = #{originName}
|
|
||||||
</if>
|
|
||||||
<if test="type != null">
|
|
||||||
AND bc.type = #{type}
|
|
||||||
</if>
|
|
||||||
<if test="enable != null">
|
|
||||||
AND bc.enable = #{enable}
|
|
||||||
</if>
|
|
||||||
<if test="lastUpdateTime != null and lastUpdateTime != ''">
|
|
||||||
<![CDATA[
|
|
||||||
and DATE_FORMAT(bc.updateTime, '%Y-%m-%d %H:%i:%S') >=
|
|
||||||
DATE_FORMAT(#{lastUpdateTime}, '%Y-%m-%d %H:%i:%S')
|
|
||||||
]]>
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
</select>
|
|
||||||
</mapper>
|
|
@ -1,150 +0,0 @@
|
|||||||
<?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.glxp.api.dao.basic.BasicBusTypePreDao">
|
|
||||||
<select id="filterList" resultType="com.glxp.api.entity.basic.BasicBusTypePreEntity">
|
|
||||||
select *
|
|
||||||
from basic_bustype_pre
|
|
||||||
<where>
|
|
||||||
<if test="originAction != null and originAction != ''">
|
|
||||||
AND originAction like concat('%', #{originAction}, '%')
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<delete id="deleteByAction">
|
|
||||||
delete
|
|
||||||
from basic_bustype_pre
|
|
||||||
where action = #{action}
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
<select id="findByAction" resultType="com.glxp.api.entity.basic.BasicBusTypePreEntity">
|
|
||||||
select basic_bustype_pre.*,
|
|
||||||
basic_bussiness_type.name
|
|
||||||
from basic_bustype_pre
|
|
||||||
left join basic_bussiness_type on basic_bustype_pre.originAction = basic_bussiness_type.action
|
|
||||||
left join auth_dept on basic_bustype_pre.defaultDeptCode = auth_dept.code
|
|
||||||
left join auth_warehouse on basic_bustype_pre.defaultInvCode = auth_warehouse.code
|
|
||||||
where basic_bustype_pre.action = #{action}
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="selectBusTypePreResList" resultType="com.glxp.api.res.basic.BasicBusTypePreResponse">
|
|
||||||
SELECT basic_bustype_pre.*,
|
|
||||||
awA.name defaultInvName,
|
|
||||||
awB.name invName,
|
|
||||||
(select name from basic_bussiness_type where action = basic_bustype_pre.originAction) originName,
|
|
||||||
(select name
|
|
||||||
from basic_bussiness_type
|
|
||||||
where basic_bussiness_type.action = basic_bustype_pre.action) targetName,
|
|
||||||
(select basic_bustype_change.originName
|
|
||||||
from basic_bustype_change
|
|
||||||
where basic_bustype_change.originAction = basic_bustype_pre.targetBusAction) targetBusName
|
|
||||||
FROM basic_bustype_pre
|
|
||||||
left JOIN auth_warehouse awA on basic_bustype_pre.defaultInvCode = awA.code
|
|
||||||
left JOIN auth_warehouse awB on basic_bustype_pre.invCode = awB.code
|
|
||||||
left JOIN basic_bussiness_type busTypeA on basic_bustype_pre.originAction = busTypeA.action
|
|
||||||
left join basic_bussiness_type busTypeB on basic_bustype_pre.action = busTypeB.action
|
|
||||||
<where>
|
|
||||||
<if test="action != ''and action != null">
|
|
||||||
AND basic_bustype_pre.`action` = #{action}
|
|
||||||
</if>
|
|
||||||
<if test="originName != ''and originName != null">
|
|
||||||
AND busTypeA.NAME LIKE CONCAT(#{originName}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="targetName != ''and targetName != null">
|
|
||||||
AND busTypeA.name LIKE CONCAT(#{targetName}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="name != null and name != ''">
|
|
||||||
and (busTypeA.name like concat('%', #{name}, '%') or busTypeB.name like concat('%', #{name}, '%'))
|
|
||||||
</if>
|
|
||||||
<if test="originAction != ''and originAction != null">
|
|
||||||
AND basic_bustype_pre.`originAction` = #{originAction}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<insert id="insertOrUpdateEntity" keyColumn="id" keyProperty="id" parameterType="com.glxp.api.entity.basic.BasicBusTypePreEntity" useGeneratedKeys="true">
|
|
||||||
insert into basic_bustype_pre
|
|
||||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
||||||
<if test="id != null">
|
|
||||||
id,
|
|
||||||
</if>
|
|
||||||
intro,
|
|
||||||
`action`,
|
|
||||||
`index`,
|
|
||||||
beforeTime,
|
|
||||||
changeType,
|
|
||||||
defaultDeptCode,
|
|
||||||
defaultInvCode,
|
|
||||||
deptCode,
|
|
||||||
invCode,
|
|
||||||
originAction,
|
|
||||||
changeEnable,
|
|
||||||
supplementAll,
|
|
||||||
`createUser`,
|
|
||||||
updateUser,
|
|
||||||
createTime,
|
|
||||||
updateTime,
|
|
||||||
remark,
|
|
||||||
targetBusAction,
|
|
||||||
busBeforeTime,
|
|
||||||
auditStatus,
|
|
||||||
busAuditStatus,createType,
|
|
||||||
</trim>
|
|
||||||
values
|
|
||||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
||||||
<if test="id != null">
|
|
||||||
#{id,jdbcType=INTEGER},
|
|
||||||
</if>
|
|
||||||
#{intro,jdbcType=VARCHAR},
|
|
||||||
#{action,jdbcType=VARCHAR},
|
|
||||||
#{index,jdbcType=TINYINT},
|
|
||||||
#{beforeTime,jdbcType=INTEGER},
|
|
||||||
#{changeType,jdbcType=TINYINT},
|
|
||||||
#{defaultDeptCode,jdbcType=VARCHAR},
|
|
||||||
#{defaultInvCode,jdbcType=VARCHAR},
|
|
||||||
#{deptCode,jdbcType=VARCHAR},
|
|
||||||
#{invCode,jdbcType=VARCHAR},
|
|
||||||
#{originAction,jdbcType=VARCHAR},
|
|
||||||
#{changeEnable,jdbcType=TINYINT},
|
|
||||||
#{supplementAll,jdbcType=TINYINT},
|
|
||||||
#{createUser,jdbcType=VARCHAR},
|
|
||||||
#{updateUser,jdbcType=VARCHAR},
|
|
||||||
#{createTime,jdbcType=TIMESTAMP},
|
|
||||||
#{updateTime,jdbcType=TIMESTAMP},
|
|
||||||
#{remark,jdbcType=VARCHAR},
|
|
||||||
#{targetBusAction,jdbcType=VARCHAR},
|
|
||||||
#{busBeforeTime,jdbcType=TINYINT},
|
|
||||||
#{auditStatus,jdbcType=TINYINT},
|
|
||||||
#{busAuditStatus,jdbcType=TINYINT}, #{createType,jdbcType=TINYINT},
|
|
||||||
</trim>
|
|
||||||
on duplicate key update
|
|
||||||
<trim suffixOverrides=",">
|
|
||||||
<if test="id != null">
|
|
||||||
id = #{id,jdbcType=INTEGER},
|
|
||||||
</if>
|
|
||||||
intro = #{intro,jdbcType=VARCHAR},
|
|
||||||
`action` = #{action,jdbcType=VARCHAR},
|
|
||||||
`index` = #{index,jdbcType=TINYINT},
|
|
||||||
beforeTime = #{beforeTime,jdbcType=INTEGER},
|
|
||||||
changeType = #{changeType,jdbcType=TINYINT},
|
|
||||||
defaultDeptCode = #{defaultDeptCode,jdbcType=VARCHAR},
|
|
||||||
defaultInvCode = #{defaultInvCode,jdbcType=VARCHAR},
|
|
||||||
deptCode = #{deptCode,jdbcType=VARCHAR},
|
|
||||||
invCode = #{invCode,jdbcType=VARCHAR},
|
|
||||||
originAction = #{originAction,jdbcType=VARCHAR},
|
|
||||||
changeEnable = #{changeEnable,jdbcType=TINYINT},
|
|
||||||
supplementAll = #{supplementAll,jdbcType=TINYINT},
|
|
||||||
`createUser` = #{createUser,jdbcType=VARCHAR},
|
|
||||||
updateUser = #{updateUser,jdbcType=VARCHAR},
|
|
||||||
createTime = #{createTime,jdbcType=TIMESTAMP},
|
|
||||||
updateTime = #{updateTime,jdbcType=TIMESTAMP},
|
|
||||||
remark = #{remark,jdbcType=VARCHAR},
|
|
||||||
targetBusAction = #{targetBusAction,jdbcType=VARCHAR},
|
|
||||||
busBeforeTime = #{busBeforeTime,jdbcType=TINYINT},
|
|
||||||
auditStatus = #{auditStatus,jdbcType=TINYINT},
|
|
||||||
busAuditStatus = #{busAuditStatus,jdbcType=TINYINT},
|
|
||||||
createType = #{createType,jdbcType=TINYINT},
|
|
||||||
</trim>
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
</mapper>
|
|
@ -1,288 +0,0 @@
|
|||||||
<?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.glxp.api.dao.basic.BasicBussinessTypeDao">
|
|
||||||
<select id="filterList" resultType="com.glxp.api.res.basic.BasicBussinessTypeResponse">
|
|
||||||
select *
|
|
||||||
from basic_bussiness_type bu
|
|
||||||
<where>
|
|
||||||
<if test="name != null and name != ''">
|
|
||||||
AND bu.name like concat('%', #{name}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="action != null and action != ''">
|
|
||||||
AND bu.action like concat('%', #{action}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="inStock != null">
|
|
||||||
AND bu.inStock = #{inStock}
|
|
||||||
</if>
|
|
||||||
<if test="enable != null">
|
|
||||||
AND bu.enable = #{enable}
|
|
||||||
</if>
|
|
||||||
<if test="mainAction != null and mainAction != ''">
|
|
||||||
AND bu.mainAction = #{mainAction}
|
|
||||||
</if>
|
|
||||||
<if test="thirdAction != null and thirdAction != ''">
|
|
||||||
AND bu.thirdSysFk like concat('%', #{thirdAction}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="checkEnable != null">
|
|
||||||
AND bu.checkEnable = #{checkEnable}
|
|
||||||
</if>
|
|
||||||
<if test="spUse != null">
|
|
||||||
AND bu.spUse = #{spUse}
|
|
||||||
</if>
|
|
||||||
<if test="secCheckEnable != null">
|
|
||||||
AND bu.secCheckEnable = #{secCheckEnable}
|
|
||||||
</if>
|
|
||||||
<if test="actionType != null">
|
|
||||||
AND bu.actionType = #{actionType}
|
|
||||||
</if>
|
|
||||||
<if test="busType != null">
|
|
||||||
AND bu.busType = #{busType}
|
|
||||||
</if>
|
|
||||||
<if test="preIn != null">
|
|
||||||
AND bu.preIn = #{preIn}
|
|
||||||
</if>
|
|
||||||
<if test="actionList != null and actionList.size() != 0">
|
|
||||||
AND bu.action in
|
|
||||||
<foreach collection="actionList" index="index" item="item" separator="," open="(" close=")">
|
|
||||||
#{item}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
<if test="lastUpdateTime != null and lastUpdateTime != ''">
|
|
||||||
<![CDATA[
|
|
||||||
and DATE_FORMAT(bu.updateTime, '%Y-%m-%d %H:%i:%S') >=
|
|
||||||
DATE_FORMAT(#{lastUpdateTime}, '%Y-%m-%d %H:%i:%S')
|
|
||||||
]]>
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
order by bu.sortNum
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<insert id="insertIgnoreBussinessType" parameterType="com.glxp.api.entity.basic.BasicBussinessTypeEntity">
|
|
||||||
insert
|
|
||||||
ignore
|
|
||||||
into basic_bussiness_type (mainAction, action, name, enable, remark, thirdSysFk, genUnit, innerOrder,
|
|
||||||
secCheckEnable, checkEnable, checkUdims, checkPdaEd, checkPdaUn, checkPc,
|
|
||||||
checkWebNew, checkSp, checkChange, secCheckUdims, secCheckPdaEd, secCheckPdaUn,
|
|
||||||
secCheckPc, secCheckWebNew, secCheckChange, secCheckSp, corpType,
|
|
||||||
supplementOrderType, checkBalance, secCheckBalance, useDyCount, expireTip,
|
|
||||||
updateTime, defaultUnit, prefix, outToSpms, ullageFill, scanPreIn, vailInv,
|
|
||||||
entrutSpms, codeFillCheck, defaultSubInv, defaultInv, orderVisibleType,
|
|
||||||
preInBack, supplementAll, createUser, createTime, updateUser, vailDispatch,
|
|
||||||
vailGroupBuy, busType, inStock, actionType, thrCheckEnable, thrCheckWebNew,
|
|
||||||
thrCheckPdaUn, thrCheckPdaEd, thrCheckUdims, thrCheckPc, thrCheckSp,
|
|
||||||
thrCheckChange, thrCheckBalance, thrCheckCopy, fillCodeRel, checkVailDate,
|
|
||||||
checkExpire, checkCertExpire, preInBackAction, backPreinType,
|
|
||||||
sortNum, spaceOut)
|
|
||||||
values (#{mainAction}, #{action}, #{name}, #{enable}, #{remark}, #{thirdSysFk}, #{genUnit}, #{innerOrder},
|
|
||||||
#{secCheckEnable}, #{checkEnable}, #{checkUdims}, #{checkPdaEd}, #{checkPdaUn}, #{checkPc},
|
|
||||||
#{checkWebNew}, #{checkSp}, #{checkChange}, #{secCheckUdims}, #{secCheckPdaEd}, #{secCheckPdaUn},
|
|
||||||
#{secCheckPc}, #{secCheckWebNew}, #{secCheckChange}, #{secCheckSp}, #{corpType},
|
|
||||||
#{supplementOrderType}, #{checkBalance}, #{secCheckBalance}, #{useDyCount}, #{expireTip},
|
|
||||||
#{updateTime}, #{defaultUnit}, #{prefix}, #{outToSpms}, #{ullageFill}, #{scanPreIn}, #{vailInv},
|
|
||||||
#{entrutSpms}, #{codeFillCheck}, #{defaultSubInv}, #{defaultInv}, #{orderVisibleType},
|
|
||||||
#{preInBack}, #{supplementAll}, #{createUser}, #{createTime}, #{updateUser}, #{vailDispatch},
|
|
||||||
#{vailGroupBuy}, #{busType}, #{inStock}, #{actionType}, #{thrCheckEnable}, #{thrCheckWebNew},
|
|
||||||
#{thrCheckPdaUn}, #{thrCheckPdaEd}, #{thrCheckUdims}, #{thrCheckPc}, #{thrCheckSp},
|
|
||||||
#{thrCheckChange}, #{thrCheckBalance}, #{thrCheckCopy}, #{fillCodeRel}, #{checkVailDate},
|
|
||||||
#{checkExpire}, #{checkCertExpire}, #{preInBackAction}, #{backPreinType},
|
|
||||||
#{sortNum}, #{spaceOut})
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
<select id="selectBusList" resultType="com.glxp.api.entity.basic.BasicBussinessTypeEntity">
|
|
||||||
select *
|
|
||||||
from basic_bussiness_type bu
|
|
||||||
<where>
|
|
||||||
<if test="name != null and name != ''">
|
|
||||||
AND bu.name like concat('%', #{name}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="action != null and action != ''">
|
|
||||||
AND bu.action like concat('%', #{action}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="enable != null">
|
|
||||||
AND bu.enable = #{enable}
|
|
||||||
</if>
|
|
||||||
<if test="mainAction != null and mainAction != ''">
|
|
||||||
AND bu.mainAction = #{mainAction}
|
|
||||||
</if>
|
|
||||||
<if test="thirdAction != null and thirdAction != ''">
|
|
||||||
AND bu.thirdSysFk like concat('%', #{thirdAction}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="checkEnable != null">
|
|
||||||
AND bu.checkEnable = #{checkEnable}
|
|
||||||
</if>
|
|
||||||
<if test="spUse != null">
|
|
||||||
AND bu.spUse = #{spUse}
|
|
||||||
</if>
|
|
||||||
<if test="secCheckEnable != null">
|
|
||||||
AND bu.secCheckEnable = #{secCheckEnable}
|
|
||||||
</if>
|
|
||||||
<if test="preIn != null">
|
|
||||||
AND bu.preIn = #{preIn}
|
|
||||||
</if>
|
|
||||||
<if test="busType != null">
|
|
||||||
AND bu.busType = #{busType}
|
|
||||||
</if>
|
|
||||||
<if test="corpType != null">
|
|
||||||
AND bu.corpType = #{corpType}
|
|
||||||
</if>
|
|
||||||
<if test="sortNum != null">
|
|
||||||
AND bu.sortNum = #{sortNum}
|
|
||||||
</if>
|
|
||||||
<if test="actionType != null">
|
|
||||||
AND bu.actionType = #{actionType}
|
|
||||||
</if>
|
|
||||||
<if test="actionList != null and actionList.size() != 0">
|
|
||||||
AND bu.action in
|
|
||||||
<foreach collection="actionList" index="index" item="item" separator="," open="(" close=")">
|
|
||||||
#{item}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
<if test="lastUpdateTime != null and lastUpdateTime != ''">
|
|
||||||
<![CDATA[
|
|
||||||
and DATE_FORMAT(bu.updateTime, '%Y-%m-%d %H:%i:%S') >=
|
|
||||||
DATE_FORMAT(#{lastUpdateTime}, '%Y-%m-%d %H:%i:%S')
|
|
||||||
]]>
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="selectForThirdSys" resultType="com.glxp.api.entity.basic.BasicBussinessTypeEntity">
|
|
||||||
select action, name
|
|
||||||
from basic_bussiness_type
|
|
||||||
where action not in (select code
|
|
||||||
from thr_system_bus_api)
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="selectCandidateBusType" resultType="com.glxp.api.entity.basic.BasicBussinessTypeEntity">
|
|
||||||
select name, action
|
|
||||||
from basic_bussiness_type
|
|
||||||
where mainAction = #{mainAction}
|
|
||||||
and corpType = 3
|
|
||||||
and (supplementOrderType is null
|
|
||||||
or supplementOrderType = '')
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="selectByUser" resultType="com.glxp.api.entity.basic.BasicBussinessTypeEntity">
|
|
||||||
select basic_bussiness_type.*
|
|
||||||
from basic_bussiness_type
|
|
||||||
inner join auth_user_bustype on basic_bussiness_type.action = auth_user_bustype.scAction
|
|
||||||
<where>
|
|
||||||
<if test="name != null and name != ''">
|
|
||||||
AND basic_bussiness_type.name like concat('%', #{name}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="action != null and action != ''">
|
|
||||||
AND basic_bussiness_type.action like concat('%', #{action}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="enable != null">
|
|
||||||
AND basic_bussiness_type.enable = #{enable}
|
|
||||||
</if>
|
|
||||||
<if test="spUse != null">
|
|
||||||
AND basic_bussiness_type.spUse = #{spUse}
|
|
||||||
</if>
|
|
||||||
<if test="code != null and code != ''">
|
|
||||||
AND auth_user_bustype.subInvCode = #{code}
|
|
||||||
</if>
|
|
||||||
<if test="userId != null">
|
|
||||||
AND auth_user_bustype.userId = #{userId}
|
|
||||||
</if>
|
|
||||||
<if test="busType != null">
|
|
||||||
AND busType = #{busType}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
group by basic_bussiness_type.action
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="filterJoinByUser" parameterType="com.glxp.api.req.basic.FilterBussinessTypeRequest"
|
|
||||||
resultType="com.glxp.api.res.basic.BasicBussinessTypeResponse">
|
|
||||||
SELECT basic_bussiness_type.*
|
|
||||||
FROM basic_bussiness_type
|
|
||||||
left JOIN auth_user_bustype ON basic_bussiness_type.action = auth_user_bustype.scAction
|
|
||||||
<where>
|
|
||||||
<if test="name != ''and name != null">
|
|
||||||
AND basic_bussiness_type.name LIKE concat('%', #{name}, '%')
|
|
||||||
</if>
|
|
||||||
|
|
||||||
<if test="inStock != null">
|
|
||||||
AND basic_bussiness_type.inStock = #{inStock}
|
|
||||||
</if>
|
|
||||||
<if test="action != ''and action != null">
|
|
||||||
AND basic_bussiness_type.action = #{action}
|
|
||||||
</if>
|
|
||||||
<if test="enable != null">
|
|
||||||
AND basic_bussiness_type.enable = #{enable}
|
|
||||||
</if>
|
|
||||||
<if test="spUse == 3">
|
|
||||||
AND basic_bussiness_type.spUse > 0
|
|
||||||
</if>
|
|
||||||
<if test="spUse != null and spUse != 3">
|
|
||||||
AND basic_bussiness_type.spUse = #{spUse}
|
|
||||||
</if>
|
|
||||||
<if test="code != ''and code != null">
|
|
||||||
AND subInvCode = #{code}
|
|
||||||
</if>
|
|
||||||
<if test="invCode != ''and invCode != null">
|
|
||||||
AND subInvCode = #{code}
|
|
||||||
</if>
|
|
||||||
<if test="userId != ''and userId != null">
|
|
||||||
AND auth_user_bustype.`userId` = #{userId}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
group by basic_bussiness_type.action
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="filterJoinByInv" parameterType="com.glxp.api.req.basic.FilterBussinessTypeRequest"
|
|
||||||
resultType="com.glxp.api.res.basic.BasicBussinessTypeResponse">
|
|
||||||
SELECT basic_bussiness_type.*
|
|
||||||
FROM basic_bussiness_type
|
|
||||||
left JOIN auth_warehouse_bustype ON basic_bussiness_type.action = auth_warehouse_bustype.action
|
|
||||||
<where>
|
|
||||||
<if test="name != ''and name != null">
|
|
||||||
AND basic_bussiness_type.name LIKE concat('%', #{name}, '%')
|
|
||||||
</if>
|
|
||||||
|
|
||||||
<if test="inStock != null">
|
|
||||||
AND basic_bussiness_type.inStock = #{inStock}
|
|
||||||
</if>
|
|
||||||
<if test="action != ''and action != null">
|
|
||||||
AND basic_bussiness_type.action = #{action}
|
|
||||||
</if>
|
|
||||||
<if test="enable != null">
|
|
||||||
AND basic_bussiness_type.enable = #{enable}
|
|
||||||
</if>
|
|
||||||
<if test="spUse == 3">
|
|
||||||
AND basic_bussiness_type.spUse > 0
|
|
||||||
</if>
|
|
||||||
<if test="spUse != null and spUse != 3">
|
|
||||||
AND basic_bussiness_type.spUse = #{spUse}
|
|
||||||
</if>
|
|
||||||
<if test="code != ''and code != null">
|
|
||||||
AND auth_warehouse_bustype.code = #{code}
|
|
||||||
</if>
|
|
||||||
<if test="invCode != ''and invCode != null">
|
|
||||||
AND auth_warehouse_bustype.code = #{code}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
group by basic_bussiness_type.action
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="selectNameByAction" resultType="java.lang.String">
|
|
||||||
select name
|
|
||||||
from basic_bussiness_type
|
|
||||||
where action = #{action}
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="selectbyNotAction" parameterType="list"
|
|
||||||
resultType="com.glxp.api.entity.basic.BasicBussinessTypeEntity">
|
|
||||||
select *
|
|
||||||
from basic_bussiness_type
|
|
||||||
<where>
|
|
||||||
<if test="list != null and list.size() != 0">
|
|
||||||
and action not in
|
|
||||||
<foreach collection="list" item="item" open="(" separator="," close=")">
|
|
||||||
#{item}
|
|
||||||
</foreach>
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
</select>
|
|
||||||
</mapper>
|
|
@ -1,165 +0,0 @@
|
|||||||
<?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.glxp.api.dao.basic.EntrustReceDao">
|
|
||||||
<select id="filterEntrustRec" parameterType="com.glxp.api.req.basic.BasicEntrustRecRequest"
|
|
||||||
resultType="com.glxp.api.entity.basic.EntrustReceEntity">
|
|
||||||
select *
|
|
||||||
from basic_entrust_accept
|
|
||||||
<where>
|
|
||||||
<if test="id != '' and id != null">
|
|
||||||
and id = #{id}
|
|
||||||
</if>
|
|
||||||
<if test="action != null">
|
|
||||||
and `action` = #{action}
|
|
||||||
</if>
|
|
||||||
<if test="entrustInv != null">
|
|
||||||
and entrustInv = #{entrustInv}
|
|
||||||
</if>
|
|
||||||
<if test="entrustUser != '' and entrustUser != null">
|
|
||||||
and entrustUser = #{entrustUser}
|
|
||||||
</if>
|
|
||||||
<if test="userId != null">
|
|
||||||
and userId = #{userId}
|
|
||||||
</if>
|
|
||||||
<if test="curInv != null">
|
|
||||||
and curInv = #{curInv}
|
|
||||||
</if>
|
|
||||||
<if test="entrustDept != null">
|
|
||||||
and entrustDept = #{entrustDept}
|
|
||||||
</if>
|
|
||||||
<if test="curDept != null">
|
|
||||||
and curDept = #{curDept}
|
|
||||||
</if>
|
|
||||||
<if test="lastUpdateTime != null and lastUpdateTime != ''">
|
|
||||||
<![CDATA[
|
|
||||||
and DATE_FORMAT(updateTime
|
|
||||||
, '%Y-%m-%d %H:%i:%S') >= DATE_FORMAT(#{lastUpdateTime}
|
|
||||||
, '%Y-%m-%d %H:%i:%S')
|
|
||||||
]]>
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
order by updateTime desc
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
<select id="findByUnique" parameterType="com.glxp.api.req.basic.BasicEntrustRecRequest"
|
|
||||||
resultType="com.glxp.api.entity.basic.EntrustReceEntity">
|
|
||||||
select *
|
|
||||||
from basic_entrust_accept
|
|
||||||
where `action` = #{action}
|
|
||||||
and `entrustUser` = #{entrustUser}
|
|
||||||
limit 1
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
<select id="downloadEntrustRec" parameterType="com.glxp.api.req.basic.BasicEntrustRecRequest"
|
|
||||||
resultType="com.glxp.api.entity.basic.DlEntrustReceEntity">
|
|
||||||
select basic_entrust_accept.id,
|
|
||||||
b.name,
|
|
||||||
b.action,
|
|
||||||
b.mainAction
|
|
||||||
from basic_entrust_accept
|
|
||||||
INNER JOIN basic_bussiness_type b on basic_entrust_accept.action = b.action
|
|
||||||
LEFT JOIN auth_user on basic_entrust_accept.entrustUser = auth_user.id
|
|
||||||
<where>
|
|
||||||
<if test="id != '' and id != null">
|
|
||||||
and id = #{id}
|
|
||||||
</if>
|
|
||||||
<if test="action != null">
|
|
||||||
and basic_entrust_accept.action = #{action}
|
|
||||||
</if>
|
|
||||||
<if test="entrustInv != null">
|
|
||||||
and basic_entrust_accept.entrustInv = #{entrustInv}
|
|
||||||
</if>
|
|
||||||
<if test="entrustUser != '' and entrustUser != null">
|
|
||||||
and basic_entrust_accept.entrustUser = #{entrustUser}
|
|
||||||
</if>
|
|
||||||
<if test="userId != null">
|
|
||||||
and basic_entrust_accept.userId = #{userId}
|
|
||||||
</if>
|
|
||||||
<if test="lastUpdateTime != null and lastUpdateTime != ''">
|
|
||||||
<![CDATA[
|
|
||||||
and DATE_FORMAT(updateTime, '%Y-%m-%d %H:%i:%S') >= DATE_FORMAT(#{lastUpdateTime}, '%Y-%m-%d %H:%i:%S')
|
|
||||||
]]>
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
<select id="filterJoinEntrustRec" parameterType="com.glxp.api.req.basic.BasicEntrustRecRequest"
|
|
||||||
resultType="com.glxp.api.res.basic.EntrustReceResponse">
|
|
||||||
select basic_entrust_accept.*,
|
|
||||||
a.name as curName,
|
|
||||||
b.name as entrustName,
|
|
||||||
auth_user.employeeName,
|
|
||||||
c.name as entrustInvName,
|
|
||||||
d.name as curInvName
|
|
||||||
from basic_entrust_accept
|
|
||||||
LEFT JOIN basic_bussiness_type a on basic_entrust_accept.action = a.action
|
|
||||||
LEFT JOIN basic_bussiness_type b on basic_entrust_accept.entrustAction = b.action
|
|
||||||
LEFT JOIN auth_user on basic_entrust_accept.entrustUser = auth_user.id
|
|
||||||
LEFT JOIN auth_warehouse c on basic_entrust_accept.entrustInv = c.`code`
|
|
||||||
LEFT JOIN auth_warehouse d on basic_entrust_accept.curInv = d.`code`
|
|
||||||
<where>
|
|
||||||
<if test="id != '' and id != null">
|
|
||||||
and id = #{id}
|
|
||||||
</if>
|
|
||||||
<if test="action != null">
|
|
||||||
and action = #{action}
|
|
||||||
</if>
|
|
||||||
<if test="entrustInv != null">
|
|
||||||
and entrustInv = #{entrustInv}
|
|
||||||
</if>
|
|
||||||
<if test="entrustUser != '' and entrustUser != null">
|
|
||||||
and entrustUser = #{entrustUser}
|
|
||||||
</if>
|
|
||||||
<if test="userId != null">
|
|
||||||
and userId = #{userId}
|
|
||||||
</if>
|
|
||||||
<if test="curInv != null">
|
|
||||||
and curInv = #{curInv}
|
|
||||||
</if>
|
|
||||||
<if test="name != null and name != ''">
|
|
||||||
and a.name like concat('%'
|
|
||||||
, #{name}
|
|
||||||
, '%')
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
group by basic_entrust_accept.id
|
|
||||||
order by updateTime desc
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
<insert id="insertEntrustRec" keyProperty="id"
|
|
||||||
parameterType="com.glxp.api.entity.basic.EntrustReceEntity">
|
|
||||||
replace
|
|
||||||
INTO basic_entrust_accept(`action`, curDept, entrustInv, `entrustUser`, userId,
|
|
||||||
updateTime, remark, entrustAction, finishRece, curInv, entrustDept, entrustInv,
|
|
||||||
entrustEnd)
|
|
||||||
values (#{action},
|
|
||||||
#{entrustInv},
|
|
||||||
#{entrustUser},
|
|
||||||
#{userId},
|
|
||||||
#{updateTime},
|
|
||||||
#{remark},
|
|
||||||
#{entrustAction},
|
|
||||||
#{finishRece},
|
|
||||||
#{curInv},
|
|
||||||
#{entrustDept},
|
|
||||||
#{entrustInv},
|
|
||||||
#{entrustEnd})
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteById" parameterType="Map">
|
|
||||||
DELETE
|
|
||||||
FROM basic_entrust_accept
|
|
||||||
WHERE id = #{id}
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
<delete id="deleteAll" parameterType="Map">
|
|
||||||
DELETE
|
|
||||||
FROM basic_entrust_accept
|
|
||||||
</delete>
|
|
||||||
</mapper>
|
|
@ -1,148 +0,0 @@
|
|||||||
<?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.glxp.api.dao.purchase.PurApplyDao">
|
|
||||||
|
|
||||||
<select id="queryPageList" parameterType="com.glxp.api.req.purchase.PurApplyRequest"
|
|
||||||
resultType="com.glxp.api.res.purchase.PurApplyResponse">
|
|
||||||
SELECT
|
|
||||||
pur_apply.*,
|
|
||||||
cb.employeeName createByName,
|
|
||||||
ab.employeeName auditByName,
|
|
||||||
auth_warehouse.`name` targetInvName,
|
|
||||||
auth_dept.`name` targetDeptName
|
|
||||||
FROM
|
|
||||||
pur_apply
|
|
||||||
LEFT JOIN auth_user cb ON pur_apply.createUser = cb.id
|
|
||||||
LEFT JOIN auth_user ab ON pur_apply.auditUser = ab.id
|
|
||||||
LEFT JOIN auth_warehouse ON pur_apply.targetInvCode = auth_warehouse.`code`
|
|
||||||
LEFT JOIN auth_dept ON auth_dept.`code` = pur_apply.targetDeptCode
|
|
||||||
<where>
|
|
||||||
<if test="billNo != '' and billNo != null">
|
|
||||||
AND billNo = #{billNo}
|
|
||||||
</if>
|
|
||||||
<if test="startDate != null and startDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_apply.createTime,'%Y-%m-%d')>= #{startDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="endDate != null and endDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_apply.createTime,'%Y-%m-%d') <= #{endDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="startAuditDate != null and startAuditDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_apply.auditTime,'%Y-%m-%d')>= #{startAuditDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="endAuditDate != null and endAuditDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_apply.auditTime,'%Y-%m-%d') <= #{endAuditDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="status!=null and status!=10 and status!=11">
|
|
||||||
and pur_apply.status = #{status}
|
|
||||||
</if>
|
|
||||||
<if test="status ==10">
|
|
||||||
and ( pur_apply.status = 3 or pur_apply.status=2 or pur_apply.status=4)
|
|
||||||
</if>
|
|
||||||
<if test="status ==11">
|
|
||||||
and ( pur_apply.status = 1 or pur_apply.status=2 or pur_apply.status=4)
|
|
||||||
</if>
|
|
||||||
|
|
||||||
<if test="deptCode != '' and deptCode != null">
|
|
||||||
AND deptCode = #{deptCode}
|
|
||||||
</if>
|
|
||||||
<if test="invCode != '' and invCode != null">
|
|
||||||
AND invCode = #{invCode}
|
|
||||||
</if>
|
|
||||||
<if test="targetInvCode != '' and targetInvCode != null">
|
|
||||||
AND targetInvCode = #{targetInvCode}
|
|
||||||
</if>
|
|
||||||
<if test="targetDeptCode != '' and targetDeptCode != null">
|
|
||||||
AND targetDeptCode = #{targetDeptCode}
|
|
||||||
</if>
|
|
||||||
<if test="auditUser != '' and auditUser != null">
|
|
||||||
AND auditUser = #{auditUser}
|
|
||||||
</if>
|
|
||||||
<if test="createUser != '' and createUser != null">
|
|
||||||
AND createUser = #{createUser}
|
|
||||||
</if>
|
|
||||||
<if test="applyType != null">
|
|
||||||
AND generatePlan = 1
|
|
||||||
</if>
|
|
||||||
<if test="emergency != null">
|
|
||||||
AND emergency = #{emergency}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<insert id="insert" keyProperty="id" keyColumn="id"
|
|
||||||
parameterType="com.glxp.api.entity.purchase.PurApplyEntity" useGeneratedKeys="true">
|
|
||||||
replace
|
|
||||||
INTO pur_apply
|
|
||||||
(
|
|
||||||
billNo,billDate,status,billType,remark,invCode,
|
|
||||||
deptCode,createUser,createTime,auditUser,auditTime,updateTime,updateUser ,auditRemark,
|
|
||||||
targetInvCode,targetDeptCode,planBillNo,generatePlan,emergency,arrivalTime
|
|
||||||
)
|
|
||||||
values (
|
|
||||||
#{billNo},
|
|
||||||
#{billDate},
|
|
||||||
#{status},
|
|
||||||
#{billType},
|
|
||||||
#{remark},
|
|
||||||
#{invCode},
|
|
||||||
#{deptCode},
|
|
||||||
#{createUser},
|
|
||||||
#{createTime},
|
|
||||||
#{auditUser},
|
|
||||||
#{auditTime},
|
|
||||||
#{updateTime},
|
|
||||||
#{updateUser},
|
|
||||||
#{auditRemark},
|
|
||||||
#{targetInvCode},
|
|
||||||
#{targetDeptCode},
|
|
||||||
#{planBillNo},#{generatePlan},
|
|
||||||
#{emergency},#{arrivalTime}
|
|
||||||
)
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteByIds" parameterType="java.util.List">
|
|
||||||
DELETE FROM pur_apply WHERE id in
|
|
||||||
<foreach collection="ids" item="item" open="(" separator="," close=")">
|
|
||||||
#{item}
|
|
||||||
</foreach>
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
<delete id="deleteById" parameterType="long">
|
|
||||||
DELETE FROM pur_apply
|
|
||||||
WHERE id = #{id}
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<update id="update" parameterType="com.glxp.api.entity.purchase.PurApplyEntity">
|
|
||||||
UPDATE pur_apply
|
|
||||||
<trim prefix="set" suffixOverrides=",">
|
|
||||||
<if test="billNo != null">billNo=#{billNo},</if>
|
|
||||||
<if test="billDate != null">billDate=#{billDate},</if>
|
|
||||||
<if test="status != null">status=#{status},</if>
|
|
||||||
<if test="billType != null">billType=#{billType},</if>
|
|
||||||
<if test="remark != null">remark=#{remark},</if>
|
|
||||||
<if test="invCode != null">invCode=#{invCode},</if>
|
|
||||||
<if test="deptCode != null">deptCode=#{deptCode},</if>
|
|
||||||
<if test="auditUser != null">auditUser=#{auditUser},</if>
|
|
||||||
<if test="auditTime != null">auditTime=#{auditTime},</if>
|
|
||||||
<if test="createUser != null">createUser=#{createUser},</if>
|
|
||||||
<if test="createTime != null">createTime=#{createTime},</if>
|
|
||||||
<if test="updateTime != null">updateTime=#{updateTime},</if>
|
|
||||||
<if test="updateUser != null">updateUser=#{updateUser},</if>
|
|
||||||
<if test="auditRemark != null">auditRemark=#{auditRemark},</if>
|
|
||||||
<if test="targetInvCode != null">targetInvCode=#{targetInvCode},</if>
|
|
||||||
<if test="targetDeptCode != null">targetDeptCode=#{targetDeptCode},</if>
|
|
||||||
<if test="planBillNo != null">planBillNo=#{planBillNo},</if>
|
|
||||||
<if test="generatePlan != null">generatePlan=#{generatePlan},</if>
|
|
||||||
<if test="emergency != null">emergency=#{emergency},</if>
|
|
||||||
<if test="arrivalTime != null">arrivalTime=#{arrivalTime},</if>
|
|
||||||
</trim>
|
|
||||||
WHERE id = #{id}
|
|
||||||
</update>
|
|
||||||
|
|
||||||
</mapper>
|
|
@ -1,160 +0,0 @@
|
|||||||
<?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.glxp.api.dao.purchase.PurApplyDetailDao">
|
|
||||||
|
|
||||||
<select id="queryPageList" parameterType="com.glxp.api.req.purchase.PurApplyDetailRequest"
|
|
||||||
resultType="com.glxp.api.entity.purchase.PurApplyDetailEntity">
|
|
||||||
select *
|
|
||||||
FROM pur_apply_detail
|
|
||||||
<where>
|
|
||||||
<if test="orderIdFk != '' and orderIdFk != null">
|
|
||||||
AND orderIdFk = #{orderIdFk}
|
|
||||||
</if>
|
|
||||||
<if test="productId != null">
|
|
||||||
AND productId = #{productId}
|
|
||||||
</if>
|
|
||||||
<if test="supId != '' and supId != null">
|
|
||||||
AND supId = #{supId}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="joinQueryList" parameterType="com.glxp.api.req.purchase.PurApplyDetailRequest"
|
|
||||||
resultType="com.glxp.api.res.purchase.PurOrderDetailResponse">
|
|
||||||
SELECT
|
|
||||||
pur_apply_detail.*,
|
|
||||||
basic_products.nameCode nameCode,
|
|
||||||
basic_products.ggxh spec,
|
|
||||||
basic_products.measname,
|
|
||||||
basic_products.manufactory,
|
|
||||||
basic_products.ylqxzcrbarmc,
|
|
||||||
basic_corp.`name` supName
|
|
||||||
FROM
|
|
||||||
pur_apply_detail
|
|
||||||
INNER JOIN basic_udirel ON pur_apply_detail.productId = basic_udirel.id
|
|
||||||
INNER JOIN basic_products ON basic_udirel.uuid = basic_products.uuid
|
|
||||||
INNER JOIN basic_corp ON pur_apply_detail.supId = basic_corp.erpId
|
|
||||||
<where>
|
|
||||||
<if test="orderIdFk != '' and orderIdFk != null">
|
|
||||||
AND orderIdFk = #{orderIdFk}
|
|
||||||
</if>
|
|
||||||
<if test="productId != null">
|
|
||||||
AND productId = #{productId}
|
|
||||||
</if>
|
|
||||||
<if test="supId != '' and supId != null">
|
|
||||||
AND supId = #{supId}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
GROUP BY basic_products.uuid
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<insert id="insert" keyProperty="id"
|
|
||||||
parameterType="com.glxp.api.entity.purchase.PurApplyDetailEntity">
|
|
||||||
replace
|
|
||||||
INTO pur_apply_detail
|
|
||||||
(
|
|
||||||
orderIdFk,productId,productName,`count`,supId,zczbhhzbapzbh
|
|
||||||
)
|
|
||||||
values (
|
|
||||||
#{orderIdFk},
|
|
||||||
#{productId},
|
|
||||||
#{productName},
|
|
||||||
#{count},
|
|
||||||
#{supId},#{zczbhhzbapzbh}
|
|
||||||
)
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteByIds" parameterType="java.util.List">
|
|
||||||
DELETE FROM pur_apply_detail WHERE id in
|
|
||||||
<foreach collection="ids" item="item" open="(" separator="," close=")">
|
|
||||||
#{item}
|
|
||||||
</foreach>
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteByOrderId" parameterType="map">
|
|
||||||
DELETE
|
|
||||||
FROM pur_apply_detail
|
|
||||||
WHERE orderIdFk = #{orderIdFk}
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
|
|
||||||
<update id="update" parameterType="com.glxp.api.entity.purchase.PurApplyDetailEntity">
|
|
||||||
UPDATE pur_apply_detail
|
|
||||||
<trim prefix="set" suffixOverrides=",">
|
|
||||||
<if test="orderIdFk != null">orderIdFk=#{orderIdFk},</if>
|
|
||||||
<if test="productId != null">productId=#{productId},</if>
|
|
||||||
<if test="productName != null">productName=#{productName},</if>
|
|
||||||
<if test="count != null">`count`=#{count},</if>
|
|
||||||
<if test="supId != null">supId=#{supId},</if>
|
|
||||||
<if test="zczbhhzbapzbh != null">zczbhhzbapzbh=#{zczbhhzbapzbh},</if>
|
|
||||||
</trim>
|
|
||||||
WHERE id = #{id}
|
|
||||||
</update>
|
|
||||||
|
|
||||||
|
|
||||||
<insert id="insertPurApplyDetailEntity" keyProperty="id" parameterType="com.glxp.api.entity.purchase.PurApplyDetailEntity">
|
|
||||||
REPLACE INTO pur_apply_detail
|
|
||||||
( orderIdFk,productId,productName,count,supId,zczbhhzbapzbh) values
|
|
||||||
|
|
||||||
<foreach collection="datas" item="item" index="index" separator=",">
|
|
||||||
(
|
|
||||||
#{item.orderIdFk},
|
|
||||||
#{item.productId},
|
|
||||||
#{item.productName},
|
|
||||||
#{item.count},
|
|
||||||
#{item.supId},
|
|
||||||
#{item.zczbhhzbapzbh}
|
|
||||||
)
|
|
||||||
</foreach>
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
<select id="selectPurApplyDetailList" resultType="com.glxp.api.res.purchase.PurOrderDetailResponse">
|
|
||||||
SELECT
|
|
||||||
pur_apply_detail.*,
|
|
||||||
pur_apply.billNo,
|
|
||||||
basic_products.ggxh spec,
|
|
||||||
basic_products.measname,
|
|
||||||
basic_products.manufactory,
|
|
||||||
basic_products.ylqxzcrbarmc,
|
|
||||||
basic_corp.`name` supName
|
|
||||||
FROM
|
|
||||||
pur_apply_detail
|
|
||||||
INNER JOIN basic_udirel ON pur_apply_detail.productId = basic_udirel.id
|
|
||||||
INNER JOIN basic_products ON basic_udirel.uuid = basic_products.uuid
|
|
||||||
INNER JOIN basic_corp ON pur_apply_detail.supId = basic_corp.erpId
|
|
||||||
left join pur_apply on pur_apply.id = pur_apply_detail.orderIdFk
|
|
||||||
<where>
|
|
||||||
<if test="billNo != null and billNo != ''">
|
|
||||||
AND pur_apply.billNo like concat('%', #{billNo}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="productId != null">
|
|
||||||
AND productId like concat('%', #{productId}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="productName != null and productName != ''">
|
|
||||||
AND productName like concat('%', #{productName}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="spec != null and spec != ''">
|
|
||||||
AND basic_products.ggxh like concat('%', #{spec}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="zczbhhzbapzbh != null and zczbhhzbapzbh != ''">
|
|
||||||
AND pur_apply_detail.zczbhhzbapzbh like concat('%', #{zczbhhzbapzbh}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="manufactory != null and manufactory != ''">
|
|
||||||
AND basic_products.manufactory like concat('%', #{manufactory}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="startDate != null and startDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_apply.createTime,'%Y-%m-%d')>= #{startDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="endDate != null and endDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_apply.createTime,'%Y-%m-%d') <= #{endDate}]]>
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
GROUP BY basic_products.uuid
|
|
||||||
</select>
|
|
||||||
</mapper>
|
|
@ -1,97 +0,0 @@
|
|||||||
<?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.glxp.api.dao.purchase.PurOrderDao">
|
|
||||||
<resultMap id="BaseResultMap" type="com.glxp.api.entity.purchase.PurOrderEntity">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
<!--@Table pur_order-->
|
|
||||||
<id column="id" jdbcType="BIGINT" property="id" />
|
|
||||||
<result column="billNo" jdbcType="VARCHAR" property="billNo" />
|
|
||||||
<result column="billDate" jdbcType="TIMESTAMP" property="billDate" />
|
|
||||||
<result column="status" jdbcType="TINYINT" property="status" />
|
|
||||||
<result column="billType" jdbcType="VARCHAR" property="billType" />
|
|
||||||
<result column="remark" jdbcType="VARCHAR" property="remark" />
|
|
||||||
<result column="invCode" jdbcType="VARCHAR" property="invCode" />
|
|
||||||
<result column="deptCode" jdbcType="VARCHAR" property="deptCode" />
|
|
||||||
<result column="createUser" jdbcType="VARCHAR" property="createUser" />
|
|
||||||
<result column="createTime" jdbcType="TIMESTAMP" property="createTime" />
|
|
||||||
<result column="auditUser" jdbcType="VARCHAR" property="auditUser" />
|
|
||||||
<result column="auditTime" jdbcType="TIMESTAMP" property="auditTime" />
|
|
||||||
<result column="auditRemark" jdbcType="VARCHAR" property="auditRemark" />
|
|
||||||
<result column="updateTime" jdbcType="TIMESTAMP" property="updateTime" />
|
|
||||||
<result column="updateUser" jdbcType="VARCHAR" property="updateUser" />
|
|
||||||
<result column="applyCreateUser" jdbcType="VARCHAR" property="applyCreateUser" />
|
|
||||||
<result column="applyAuditUser" jdbcType="VARCHAR" property="applyAuditUser" />
|
|
||||||
<result column="applyRemark" jdbcType="VARCHAR" property="applyRemark" />
|
|
||||||
<result column="applyBillNo" jdbcType="VARCHAR" property="applyBillNo" />
|
|
||||||
<result column="stockOrderNo" jdbcType="VARCHAR" property="stockOrderNo" />
|
|
||||||
</resultMap>
|
|
||||||
<sql id="Base_Column_List">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
id, billNo, billDate, `status`, billType, remark, invCode, deptCode, `createUser`,
|
|
||||||
createTime, auditUser, auditTime, auditRemark, updateTime, updateUser, applyCreateUser,
|
|
||||||
applyAuditUser, applyRemark, applyBillNo, stockOrderNo
|
|
||||||
</sql>
|
|
||||||
|
|
||||||
|
|
||||||
<select id="queryPageList" parameterType="com.glxp.api.req.purchase.PurOrderRequest"
|
|
||||||
resultType="com.glxp.api.res.purchase.PurOrderResponse">
|
|
||||||
|
|
||||||
SELECT
|
|
||||||
pur_order.*,
|
|
||||||
cb.employeeName createUserName,
|
|
||||||
ab.employeeName auditUserName,
|
|
||||||
auth_warehouse.NAME invName,
|
|
||||||
auth_dept.`name` deptName
|
|
||||||
FROM
|
|
||||||
pur_order
|
|
||||||
LEFT JOIN auth_user cb ON pur_order.createUser = cb.id
|
|
||||||
LEFT JOIN auth_user ab ON pur_order.auditUser = ab.id
|
|
||||||
LEFT JOIN auth_warehouse ON pur_order.invCode = auth_warehouse.`code`
|
|
||||||
LEFT JOIN auth_dept ON auth_dept.CODE = pur_order.deptCode
|
|
||||||
<where>
|
|
||||||
<if test="billNo != '' and billNo != null">
|
|
||||||
AND billNo = #{billNo}
|
|
||||||
</if>
|
|
||||||
<if test="startDate != null and startDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_order.createTime,'%Y-%m-%d')>= #{startDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="endDate != null and endDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_order.createTime,'%Y-%m-%d') <= #{endDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="startAuditDate != null and startAuditDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_order.auditTime,'%Y-%m-%d')>= #{startAuditDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="endAuditDate != null and endAuditDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_order.auditTime,'%Y-%m-%d') <= #{endAuditDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="status!=null and status!=10 and status!=11">
|
|
||||||
and pur_order.status = #{status}
|
|
||||||
</if>
|
|
||||||
<if test="status ==10">
|
|
||||||
and ( pur_order.status = 3 or pur_order.status=2 or pur_order.status=4)
|
|
||||||
</if>
|
|
||||||
<if test="status ==11">
|
|
||||||
and ( pur_order.status = 1 or pur_order.status=2 or pur_order.status=4)
|
|
||||||
</if>
|
|
||||||
|
|
||||||
<if test="deptCode != '' and deptCode != null">
|
|
||||||
AND deptCode = #{deptCode}
|
|
||||||
</if>
|
|
||||||
<if test="invCode != '' and invCode != null">
|
|
||||||
AND invCode = #{invCode}
|
|
||||||
</if>
|
|
||||||
<if test="auditUser != '' and auditUser != null">
|
|
||||||
AND auditUser = #{auditUser}
|
|
||||||
</if>
|
|
||||||
<if test="createUser != '' and createUser != null">
|
|
||||||
AND createUser = #{createUser}
|
|
||||||
</if>
|
|
||||||
<if test="emergency != null">
|
|
||||||
AND emergency = #{emergency}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
</mapper>
|
|
@ -1,176 +0,0 @@
|
|||||||
<?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.glxp.api.dao.purchase.PurOrderDetailDao">
|
|
||||||
<resultMap id="BaseResultMap" autoMapping="true" type="com.glxp.api.entity.purchase.PurOrderDetailEntity">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
<!--@Table pur_order_detail-->
|
|
||||||
<!-- <id column="id" jdbcType="INTEGER" property="id" />-->
|
|
||||||
<result column="orderIdFk" jdbcType="VARCHAR" property="orderIdFk" />
|
|
||||||
<result column="productId" jdbcType="INTEGER" property="productId" />
|
|
||||||
<result column="productName" jdbcType="VARCHAR" property="productName" />
|
|
||||||
<result column="count" jdbcType="INTEGER" property="count" />
|
|
||||||
<result column="supId" jdbcType="VARCHAR" property="supId" />
|
|
||||||
<result column="zczbhhzbapzbh" jdbcType="VARCHAR" property="zczbhhzbapzbh" />
|
|
||||||
</resultMap>
|
|
||||||
<sql id="Base_Column_List">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
id, orderIdFk, productId, productName, `count`, supId, zczbhhzbapzbh
|
|
||||||
</sql>
|
|
||||||
|
|
||||||
|
|
||||||
<select id="queryPageList" parameterType="com.glxp.api.req.purchase.PurOrderDetailRequest"
|
|
||||||
resultType="com.glxp.api.entity.purchase.PurOrderDetailEntity">
|
|
||||||
select *
|
|
||||||
FROM pur_order_detail
|
|
||||||
<where>
|
|
||||||
<if test="orderIdFk != '' and orderIdFk != null">
|
|
||||||
AND orderIdFk = #{orderIdFk}
|
|
||||||
</if>
|
|
||||||
<if test="productId != null">
|
|
||||||
AND productId = #{productId}
|
|
||||||
</if>
|
|
||||||
<if test="supId != '' and supId != null">
|
|
||||||
AND supId = #{supId}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="joinQueryList" parameterType="com.glxp.api.req.purchase.PurOrderDetailRequest"
|
|
||||||
resultType="com.glxp.api.res.purchase.PurOrderDetailResponse">
|
|
||||||
SELECT
|
|
||||||
pur_order_detail.*,
|
|
||||||
basic_products.ggxh spec,
|
|
||||||
basic_products.nameCode nameCode,
|
|
||||||
basic_products.measname,
|
|
||||||
basic_products.manufactory,
|
|
||||||
basic_products.ylqxzcrbarmc,
|
|
||||||
basic_corp.`name` supName
|
|
||||||
FROM
|
|
||||||
pur_order_detail
|
|
||||||
INNER JOIN basic_udirel ON pur_order_detail.productId = basic_udirel.id
|
|
||||||
INNER JOIN basic_products ON basic_udirel.uuid = basic_products.uuid
|
|
||||||
INNER JOIN basic_corp ON pur_order_detail.supId = basic_corp.erpId
|
|
||||||
<where>
|
|
||||||
<if test="orderIdFk != '' and orderIdFk != null">
|
|
||||||
AND orderIdFk = #{orderIdFk}
|
|
||||||
AND basic_products.diType=1
|
|
||||||
</if>
|
|
||||||
<if test="productId != null">
|
|
||||||
AND productId = #{productId}
|
|
||||||
</if>
|
|
||||||
<if test="supId != '' and supId != null">
|
|
||||||
AND supId = #{supId}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteByIds" parameterType="java.util.List">
|
|
||||||
DELETE FROM pur_order_detail WHERE id in
|
|
||||||
<foreach collection="ids" item="item" open="(" separator="," close=")">
|
|
||||||
#{item}
|
|
||||||
</foreach>
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteByOrderId" parameterType="map">
|
|
||||||
DELETE
|
|
||||||
FROM pur_order_detail
|
|
||||||
WHERE orderIdFk = #{orderIdFk}
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
<update id="update" parameterType="com.glxp.api.entity.purchase.PurOrderDetailEntity">
|
|
||||||
UPDATE pur_order_detail
|
|
||||||
<trim prefix="set" suffixOverrides=",">
|
|
||||||
<if test="orderIdFk != null">orderIdFk=#{orderIdFk},</if>
|
|
||||||
<if test="productId != null">productId=#{productId},</if>
|
|
||||||
<if test="productName != null">productName=#{productName},</if>
|
|
||||||
<if test="count != null">`count`=#{count},</if>
|
|
||||||
<if test="supId != null">supId=#{supId},</if>
|
|
||||||
<if test="zczbhhzbapzbh != null">zczbhhzbapzbh=#{zczbhhzbapzbh},</if>
|
|
||||||
</trim>
|
|
||||||
WHERE id = #{id}
|
|
||||||
</update>
|
|
||||||
|
|
||||||
|
|
||||||
<insert id="insertPurOrderDetailEntity" keyProperty="id" parameterType="com.glxp.api.entity.purchase.PurOrderDetailEntity">
|
|
||||||
REPLACE INTO pur_order_detail
|
|
||||||
( orderIdFk,productId,productName,count,supId,zczbhhzbapzbh) values
|
|
||||||
|
|
||||||
<foreach collection="datas" item="item" index="index" separator=",">
|
|
||||||
(
|
|
||||||
#{item.orderIdFk},
|
|
||||||
#{item.productId},
|
|
||||||
#{item.productName},
|
|
||||||
#{item.count},
|
|
||||||
#{item.supId},
|
|
||||||
#{item.zczbhhzbapzbh}
|
|
||||||
)
|
|
||||||
</foreach>
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
<select id="selectIoOrderDetailBiz" parameterType="long"
|
|
||||||
resultType="com.glxp.api.entity.basic.BasicProductsEntity">
|
|
||||||
SELECT
|
|
||||||
b2.*
|
|
||||||
FROM
|
|
||||||
pur_order_detail p1
|
|
||||||
LEFT JOIN basic_udirel b1 on b1.id=p1.productId
|
|
||||||
LEFT JOIN basic_products b2 on b1.uuid = b2 .uuid
|
|
||||||
<where>
|
|
||||||
<if test="id != null and id!='' ">
|
|
||||||
AND p1.id = #{id}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
GROUP BY uuid
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="selectDetailList" resultType="com.glxp.api.res.purchase.PurOrderDetailResponse">
|
|
||||||
SELECT
|
|
||||||
pur_order_detail.*,
|
|
||||||
pur_order.billNo,
|
|
||||||
basic_products.ggxh spec,
|
|
||||||
basic_products.measname,
|
|
||||||
basic_products.manufactory,
|
|
||||||
basic_products.ylqxzcrbarmc,
|
|
||||||
basic_corp.`name` supName
|
|
||||||
FROM
|
|
||||||
pur_order_detail
|
|
||||||
INNER JOIN basic_udirel ON pur_order_detail.productId = basic_udirel.id
|
|
||||||
INNER JOIN basic_products ON basic_udirel.uuid = basic_products.uuid
|
|
||||||
INNER JOIN basic_corp ON pur_order_detail.supId = basic_corp.erpId
|
|
||||||
left join pur_order on pur_order.id = pur_order_detail.orderIdFk
|
|
||||||
<where>
|
|
||||||
<if test="billNo != null and billNo != ''">
|
|
||||||
AND pur_order.billNo like concat('%', #{billNo}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="productId != null">
|
|
||||||
AND productId like concat('%', #{productId}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="productName != null and productName != ''">
|
|
||||||
AND productName like concat('%', #{productName}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="spec != null and spec != ''">
|
|
||||||
AND basic_products.ggxh like concat('%', #{spec}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="zczbhhzbapzbh != null and zczbhhzbapzbh != ''">
|
|
||||||
AND pur_order_detail.zczbhhzbapzbh like concat('%', #{zczbhhzbapzbh}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="manufactory != null and manufactory != ''">
|
|
||||||
AND basic_products.manufactory like concat('%', #{manufactory}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="startDate != null and startDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_order.createTime,'%Y-%m-%d')>= #{startDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="endDate != null and endDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_order.createTime,'%Y-%m-%d') <= #{endDate}]]>
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
</select>
|
|
||||||
</mapper>
|
|
@ -1,144 +0,0 @@
|
|||||||
<?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.glxp.api.dao.purchase.PurPlanDao">
|
|
||||||
|
|
||||||
<select id="queryPageList" parameterType="com.glxp.api.req.purchase.PurPlanRequest"
|
|
||||||
resultType="com.glxp.api.res.purchase.PurPlanResponse">
|
|
||||||
|
|
||||||
SELECT
|
|
||||||
pur_plan.*,
|
|
||||||
cb.employeeName createUserName,
|
|
||||||
ab.employeeName auditUserName,
|
|
||||||
auth_warehouse.NAME invName,
|
|
||||||
auth_dept.`name` deptName
|
|
||||||
FROM
|
|
||||||
pur_plan
|
|
||||||
LEFT JOIN auth_user cb ON pur_plan.createUser = cb.id
|
|
||||||
LEFT JOIN auth_user ab ON pur_plan.auditUser = ab.id
|
|
||||||
LEFT JOIN auth_warehouse ON pur_plan.invCode = auth_warehouse.`code`
|
|
||||||
LEFT JOIN auth_dept ON auth_dept.CODE = pur_plan.deptCode
|
|
||||||
<where>
|
|
||||||
<if test="billNo != '' and billNo != null">
|
|
||||||
AND billNo = #{billNo}
|
|
||||||
</if>
|
|
||||||
<if test="startDate != null and startDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_plan.createTime,'%Y-%m-%d')>= #{startDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="endDate != null and endDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_plan.createTime,'%Y-%m-%d') <= #{endDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="startAuditDate != null and startAuditDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_plan.auditTime,'%Y-%m-%d')>= #{startAuditDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="endAuditDate != null and endAuditDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_plan.auditTime,'%Y-%m-%d') <= #{endAuditDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="status!=null and status!=10 and status!=11">
|
|
||||||
and pur_plan.status = #{status}
|
|
||||||
</if>
|
|
||||||
<if test="status ==10">
|
|
||||||
and ( pur_plan.status = 3 or pur_plan.status=2 or pur_plan.status=4)
|
|
||||||
</if>
|
|
||||||
<if test="status ==11">
|
|
||||||
and ( pur_plan.status = 1 or pur_plan.status=2 or pur_plan.status=4)
|
|
||||||
</if>
|
|
||||||
<if test="status ==12">
|
|
||||||
and (pur_plan.status=3)
|
|
||||||
</if>
|
|
||||||
<if test="deptCode != '' and deptCode != null">
|
|
||||||
AND deptCode = #{deptCode}
|
|
||||||
</if>
|
|
||||||
<if test="invCode != '' and invCode != null">
|
|
||||||
AND invCode = #{invCode}
|
|
||||||
</if>
|
|
||||||
<if test="auditUser != '' and auditUser != null">
|
|
||||||
AND auditUser = #{auditUser}
|
|
||||||
</if>
|
|
||||||
<if test="createUser != '' and createUser != null">
|
|
||||||
AND createUser = #{createUser}
|
|
||||||
</if>
|
|
||||||
<if test="emergency != null">
|
|
||||||
AND emergency = #{emergency}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<insert id="insert" keyProperty="id"
|
|
||||||
parameterType="com.glxp.api.entity.purchase.PurPlanEntity" useGeneratedKeys="true">
|
|
||||||
replace
|
|
||||||
INTO pur_plan
|
|
||||||
(
|
|
||||||
billNo,billDate,status,billType,remark,invCode,
|
|
||||||
deptCode,createUser,createTime,auditUser,auditTime,updateTime,auditRemark
|
|
||||||
,applyCreateUser,applyAuditUser,applyRemark,applyBillNo,stockOrderNo,emergency,arrivalTime
|
|
||||||
)
|
|
||||||
values (
|
|
||||||
#{billNo},
|
|
||||||
#{billDate},
|
|
||||||
#{status},
|
|
||||||
#{billType},
|
|
||||||
#{remark},
|
|
||||||
#{invCode},
|
|
||||||
#{deptCode},
|
|
||||||
#{createUser},
|
|
||||||
#{createTime},
|
|
||||||
#{auditUser},
|
|
||||||
#{auditTime},
|
|
||||||
#{updateTime},
|
|
||||||
#{auditRemark},
|
|
||||||
#{applyCreateUser},
|
|
||||||
#{applyAuditUser},
|
|
||||||
#{applyRemark},
|
|
||||||
#{applyBillNo},
|
|
||||||
#{stockOrderNo},
|
|
||||||
#{emergency},#{arrivalTime}
|
|
||||||
)
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteByIds" parameterType="java.util.List">
|
|
||||||
DELETE FROM pur_plan WHERE id in
|
|
||||||
<foreach collection="ids" item="item" open="(" separator="," close=")">
|
|
||||||
#{item}
|
|
||||||
</foreach>
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<update id="update" parameterType="com.glxp.api.entity.purchase.PurPlanEntity">
|
|
||||||
UPDATE pur_plan
|
|
||||||
<trim prefix="set" suffixOverrides=",">
|
|
||||||
<if test="billNo != null">billNo=#{billNo},</if>
|
|
||||||
<if test="billDate != null">billDate=#{billDate},</if>
|
|
||||||
<if test="status != null">status=#{status},</if>
|
|
||||||
<if test="billType != null">billType=#{billType},</if>
|
|
||||||
<if test="remark != null">remark=#{remark},</if>
|
|
||||||
<if test="invCode != null">invCode=#{invCode},</if>
|
|
||||||
<if test="deptCode != null">deptCode=#{deptCode},</if>
|
|
||||||
<if test="auditUser != null">auditUser=#{auditUser},</if>
|
|
||||||
<if test="auditTime != null">auditTime=#{auditTime},</if>
|
|
||||||
<if test="createUser != null">createUser=#{createUser},</if>
|
|
||||||
<if test="createTime != null">createTime=#{createTime},</if>
|
|
||||||
<if test="updateTime != null">updateTime=#{updateTime},</if>
|
|
||||||
<if test="updateUser != null">updateUser=#{updateUser},</if>
|
|
||||||
<if test="auditRemark != null">auditRemark=#{auditRemark},</if>
|
|
||||||
<if test="applyCreateUser != null">applyCreateUser=#{applyCreateUser},</if>
|
|
||||||
<if test="applyAuditUser != null">applyAuditUser=#{applyAuditUser},</if>
|
|
||||||
<if test="applyRemark != null">applyRemark=#{applyRemark},</if>
|
|
||||||
<if test="applyBillNo != null">applyBillNo=#{applyBillNo},</if>
|
|
||||||
<if test="stockOrderNo != null">stockOrderNo=#{stockOrderNo},</if>
|
|
||||||
<if test="emergency != null">emergency=#{emergency},</if>
|
|
||||||
<if test="arrivalTime != null">arrivalTime=#{arrivalTime},</if>
|
|
||||||
</trim>
|
|
||||||
WHERE id = #{id}
|
|
||||||
</update>
|
|
||||||
|
|
||||||
<delete id="deleteById" parameterType="long">
|
|
||||||
DELETE FROM pur_plan
|
|
||||||
WHERE id = #{id}
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
</mapper>
|
|
@ -1,176 +0,0 @@
|
|||||||
<?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.glxp.api.dao.purchase.PurPlanDetailDao">
|
|
||||||
|
|
||||||
<select id="queryPageList" parameterType="com.glxp.api.req.purchase.PurPlanDetailRequest"
|
|
||||||
resultType="com.glxp.api.entity.purchase.PurPlanDetailEntity">
|
|
||||||
select *
|
|
||||||
FROM pur_plan_detail
|
|
||||||
<where>
|
|
||||||
<if test="orderIdFk != '' and orderIdFk != null">
|
|
||||||
AND orderIdFk = #{orderIdFk}
|
|
||||||
</if>
|
|
||||||
<if test="productId != null">
|
|
||||||
AND productId = #{productId}
|
|
||||||
</if>
|
|
||||||
<if test="supId != '' and supId != null">
|
|
||||||
AND supId = #{supId}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="joinQueryList" parameterType="com.glxp.api.req.purchase.PurPlanDetailRequest"
|
|
||||||
resultType="com.glxp.api.res.purchase.PurOrderDetailResponse">
|
|
||||||
SELECT
|
|
||||||
pur_plan_detail.*,
|
|
||||||
basic_products.ggxh spec,
|
|
||||||
basic_products.nameCode nameCode,
|
|
||||||
basic_products.measname,
|
|
||||||
basic_products.manufactory,
|
|
||||||
basic_products.ylqxzcrbarmc,
|
|
||||||
basic_corp.`name` supName
|
|
||||||
FROM
|
|
||||||
pur_plan_detail
|
|
||||||
INNER JOIN basic_udirel ON pur_plan_detail.productId = basic_udirel.id
|
|
||||||
INNER JOIN basic_products ON basic_udirel.uuid = basic_products.uuid
|
|
||||||
INNER JOIN basic_corp ON pur_plan_detail.supId = basic_corp.erpId
|
|
||||||
<where>
|
|
||||||
<if test="orderIdFk != '' and orderIdFk != null">
|
|
||||||
AND orderIdFk = #{orderIdFk}
|
|
||||||
AND basic_products.diType=1
|
|
||||||
</if>
|
|
||||||
<if test="productId != null">
|
|
||||||
AND productId = #{productId}
|
|
||||||
</if>
|
|
||||||
<if test="supId != '' and supId != null">
|
|
||||||
AND supId = #{supId}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
<insert id="insert" keyProperty="id"
|
|
||||||
parameterType="com.glxp.api.entity.purchase.PurPlanDetailEntity">
|
|
||||||
replace
|
|
||||||
INTO pur_plan_detail
|
|
||||||
(
|
|
||||||
orderIdFk,productId,productName,`count`,supId,zczbhhzbapzbh
|
|
||||||
)
|
|
||||||
values (
|
|
||||||
#{orderIdFk},
|
|
||||||
#{productId},
|
|
||||||
#{productName},
|
|
||||||
#{count},
|
|
||||||
#{supId},#{zczbhhzbapzbh}
|
|
||||||
)
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteByIds" parameterType="java.util.List">
|
|
||||||
DELETE FROM pur_plan_detail WHERE id in
|
|
||||||
<foreach collection="ids" item="item" open="(" separator="," close=")">
|
|
||||||
#{item}
|
|
||||||
</foreach>
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteByOrderId" parameterType="map">
|
|
||||||
DELETE
|
|
||||||
FROM pur_plan_detail
|
|
||||||
WHERE orderIdFk = #{orderIdFk}
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
<update id="update" parameterType="com.glxp.api.entity.purchase.PurPlanDetailEntity">
|
|
||||||
UPDATE pur_plan_detail
|
|
||||||
<trim prefix="set" suffixOverrides=",">
|
|
||||||
<if test="orderIdFk != null">orderIdFk=#{orderIdFk},</if>
|
|
||||||
<if test="productId != null">productId=#{productId},</if>
|
|
||||||
<if test="productName != null">productName=#{productName},</if>
|
|
||||||
<if test="count != null">`count`=#{count},</if>
|
|
||||||
<if test="supId != null">supId=#{supId},</if>
|
|
||||||
<if test="zczbhhzbapzbh != null">zczbhhzbapzbh=#{zczbhhzbapzbh},</if>
|
|
||||||
</trim>
|
|
||||||
WHERE id = #{id}
|
|
||||||
</update>
|
|
||||||
|
|
||||||
|
|
||||||
<insert id="insertPurPlanDetailEntity" keyProperty="id" parameterType="com.glxp.api.entity.purchase.PurPlanDetailEntity">
|
|
||||||
REPLACE INTO pur_plan_detail
|
|
||||||
( orderIdFk,productId,productName,count,supId,zczbhhzbapzbh) values
|
|
||||||
|
|
||||||
<foreach collection="datas" item="item" index="index" separator=",">
|
|
||||||
(
|
|
||||||
#{item.orderIdFk},
|
|
||||||
#{item.productId},
|
|
||||||
#{item.productName},
|
|
||||||
#{item.count},
|
|
||||||
#{item.supId},
|
|
||||||
#{item.zczbhhzbapzbh}
|
|
||||||
)
|
|
||||||
</foreach>
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
<select id="selectIoOrderDetailBiz" parameterType="long"
|
|
||||||
resultType="com.glxp.api.entity.basic.BasicProductsEntity">
|
|
||||||
SELECT
|
|
||||||
b2.*
|
|
||||||
FROM
|
|
||||||
pur_plan_detail p1
|
|
||||||
LEFT JOIN basic_udirel b1 on b1.id=p1.productId
|
|
||||||
LEFT JOIN basic_products b2 on b1.uuid = b2 .uuid
|
|
||||||
<where>
|
|
||||||
<if test="id != null and id!='' ">
|
|
||||||
AND p1.id = #{id}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
GROUP BY uuid
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<select id="seletDetaiList" resultType="com.glxp.api.res.purchase.PurOrderDetailResponse">
|
|
||||||
SELECT
|
|
||||||
pur_plan_detail.*,
|
|
||||||
pur_plan.billNo,
|
|
||||||
basic_products.ggxh spec,
|
|
||||||
basic_products.measname,
|
|
||||||
basic_products.manufactory,
|
|
||||||
basic_products.ylqxzcrbarmc,
|
|
||||||
basic_corp.`name` supName
|
|
||||||
FROM
|
|
||||||
pur_plan_detail
|
|
||||||
INNER JOIN basic_udirel ON pur_plan_detail.productId = basic_udirel.id
|
|
||||||
INNER JOIN basic_products ON basic_udirel.uuid = basic_products.uuid
|
|
||||||
INNER JOIN basic_corp ON pur_plan_detail.supId = basic_corp.erpId
|
|
||||||
left join pur_plan on pur_plan.id = pur_plan_detail.orderIdFk
|
|
||||||
<where>
|
|
||||||
<if test="billNo != null and billNo != ''">
|
|
||||||
AND pur_plan.billNo like concat('%', #{billNo}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="productId != null">
|
|
||||||
AND productId like concat('%', #{productId}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="productName != null and productName != ''">
|
|
||||||
AND productName like concat('%', #{productName}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="spec != null and spec != ''">
|
|
||||||
AND basic_products.ggxh like concat('%', #{spec}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="zczbhhzbapzbh != null and zczbhhzbapzbh != ''">
|
|
||||||
AND pur_plan_detail.zczbhhzbapzbh like concat('%', #{zczbhhzbapzbh}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="manufactory != null and manufactory != ''">
|
|
||||||
AND basic_products.manufactory like concat('%', #{manufactory}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="startDate != null and startDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_plan.createTime,'%Y-%m-%d')>= #{startDate}]]>
|
|
||||||
</if>
|
|
||||||
<if test="endDate != null and endDate !=''">
|
|
||||||
<![CDATA[ and DATE_FORMAT(pur_plan.createTime,'%Y-%m-%d') <= #{endDate}]]>
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
</select>
|
|
||||||
</mapper>
|
|
@ -1,23 +0,0 @@
|
|||||||
<?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.glxp.api.dao.sync.SyncDataBustypeDao">
|
|
||||||
<select id="findAll"
|
|
||||||
resultType="com.glxp.api.entity.system.SyncDataBustypeEntity">
|
|
||||||
SELECT *
|
|
||||||
FROM sync_data_bustypes
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
<insert id="inserts" parameterType="com.glxp.api.entity.system.SyncDataBustypeEntity" useGeneratedKeys="true">
|
|
||||||
replace INTO sync_data_bustypes
|
|
||||||
(id, `action`, `name`, outChange, orderStatus, direct, syncStatus, syncChange)
|
|
||||||
values
|
|
||||||
|
|
||||||
<foreach collection="syncDataBustypeEntities" item="item" index="index"
|
|
||||||
separator=",">
|
|
||||||
(#{item.id}, #{item.action}, #{item.name},
|
|
||||||
#{item.outChange}, #{item.orderStatus}, #{item.direct}, #{item.syncStatus}, #{item.syncChange})
|
|
||||||
</foreach>
|
|
||||||
</insert>
|
|
||||||
</mapper>
|
|
@ -1,17 +0,0 @@
|
|||||||
<?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.glxp.api.dao.system.SyncDataChangeBustypesDao">
|
|
||||||
<resultMap id="BaseResultMap" autoMapping="true" type="com.glxp.api.entity.system.SyncDataChangeBustypesEntity">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
<!--@Table sync_data_change_bustypes-->
|
|
||||||
<!-- <id column="id" jdbcType="INTEGER" property="id"/>-->
|
|
||||||
<result column="action" jdbcType="VARCHAR" property="action"/>
|
|
||||||
<result column="name" jdbcType="VARCHAR" property="name"/>
|
|
||||||
<result column="outChange" jdbcType="TINYINT" property="outChange"/>
|
|
||||||
<result column="orderStatus" jdbcType="TINYINT" property="orderStatus"/>
|
|
||||||
</resultMap>
|
|
||||||
<sql id="Base_Column_List">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
id, `action`, `name`, outChange, orderStatus
|
|
||||||
</sql>
|
|
||||||
</mapper>
|
|
@ -1,35 +0,0 @@
|
|||||||
<?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.glxp.api.dao.system.SyncUploadDataBustypeDao">
|
|
||||||
|
|
||||||
|
|
||||||
<select id="findAll"
|
|
||||||
resultType="com.glxp.api.entity.system.SyncDataBustypeEntity">
|
|
||||||
SELECT *
|
|
||||||
FROM thr_order_upload_bustypes
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
<delete id="deleteAll">
|
|
||||||
DELETE
|
|
||||||
FROM thr_order_upload_bustypes
|
|
||||||
</delete>
|
|
||||||
|
|
||||||
<insert id="inserts" parameterType="com.glxp.api.entity.system.SyncDataBustypeEntity">
|
|
||||||
insert INTO thr_order_upload_bustypes
|
|
||||||
( `action`, `name`)
|
|
||||||
values
|
|
||||||
|
|
||||||
<foreach collection="syncDataBustypeEntities" item="item" index="index"
|
|
||||||
separator=",">
|
|
||||||
(
|
|
||||||
#{item.action}, #{item.name}
|
|
||||||
)
|
|
||||||
</foreach>
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
<select id="selectCountByAction" resultType="int">
|
|
||||||
select count(*) from thr_order_upload_bustypes where action = #{action}
|
|
||||||
</select>
|
|
||||||
</mapper>
|
|
@ -1,38 +0,0 @@
|
|||||||
<?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.glxp.api.dao.system.SyncUploadDataSetDao">
|
|
||||||
|
|
||||||
|
|
||||||
<select id="selectSet"
|
|
||||||
resultType="com.glxp.api.entity.system.SyncUploadDataSetEntity">
|
|
||||||
SELECT *
|
|
||||||
FROM thr_order_upload limit 1
|
|
||||||
</select>
|
|
||||||
|
|
||||||
|
|
||||||
<insert id="insert" parameterType="com.glxp.api.entity.system.SyncUploadDataSetEntity">
|
|
||||||
replace
|
|
||||||
INTO thr_order_upload(id,autoUpload, orderSyncTime,orderUnCheck,orderUnReceive,
|
|
||||||
orderScanFinish, checkUdims, checkPdaEd, checkPdaUn, checkPc,
|
|
||||||
checkWebNew, checkChange, checkSp,checkBalacne,orderStartTime)
|
|
||||||
values (
|
|
||||||
#{id},
|
|
||||||
#{autoUpload},
|
|
||||||
#{orderSyncTime},
|
|
||||||
#{orderUnCheck},
|
|
||||||
#{orderUnReceive},
|
|
||||||
#{orderScanFinish},
|
|
||||||
#{checkUdims},
|
|
||||||
#{checkPdaEd},
|
|
||||||
#{checkPdaUn},
|
|
||||||
#{checkPc},
|
|
||||||
#{checkWebNew},
|
|
||||||
#{checkChange},
|
|
||||||
#{checkSp},
|
|
||||||
#{checkBalacne},#{orderStartTime}
|
|
||||||
)
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
|
|
||||||
</mapper>
|
|
@ -1,10 +0,0 @@
|
|||||||
<?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.glxp.api.dao.system.SysErpLogDao">
|
|
||||||
<delete id="deleteByDate">
|
|
||||||
delete
|
|
||||||
from sys_erp_log
|
|
||||||
where date_format(#{date}, '%Y-%m-%d') >= date_format(createTime, '%Y-%m-%d')
|
|
||||||
</delete>
|
|
||||||
</mapper>
|
|
@ -1,15 +0,0 @@
|
|||||||
<?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.glxp.api.dao.system.SysRemindMsgMapper">
|
|
||||||
<select id="filterList" parameterType="com.glxp.api.req.system.FilterSysRemindMsgRequest"
|
|
||||||
resultType="com.glxp.api.entity.system.SysRemindMsgEntity">
|
|
||||||
SELECT *
|
|
||||||
FROM sys_remind_msg
|
|
||||||
<where>
|
|
||||||
<if test="key != null and key != ''">
|
|
||||||
AND `key` like CONCAT('%', #{key}, '%')
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
order BY id
|
|
||||||
</select>
|
|
||||||
</mapper>
|
|
@ -1,15 +0,0 @@
|
|||||||
<?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.glxp.api.dao.system.SysRemindSetMapper">
|
|
||||||
<select id="filterList" parameterType="com.glxp.api.req.system.FilterSysRemindSetRequest"
|
|
||||||
resultType="com.glxp.api.entity.system.SysRemindSetEntity">
|
|
||||||
SELECT *
|
|
||||||
FROM sys_remind_set
|
|
||||||
<where>
|
|
||||||
<if test="key != null and key != ''">
|
|
||||||
AND `key` like CONCAT('%', #{key}, '%')
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
order BY id
|
|
||||||
</select>
|
|
||||||
</mapper>
|
|
@ -1,27 +0,0 @@
|
|||||||
<?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.glxp.api.dao.system.ThirdSysApiDao">
|
|
||||||
|
|
||||||
|
|
||||||
<select id="findSysApi" parameterType="com.glxp.api.req.system.FilterSysApiRequest"
|
|
||||||
resultType="com.glxp.api.entity.system.ThirdSysApiEntity">
|
|
||||||
SELECT * FROM sys_thirdsys_api
|
|
||||||
<where>
|
|
||||||
<if test="type != '' and type != null">
|
|
||||||
AND type = #{type}
|
|
||||||
</if>
|
|
||||||
</where>
|
|
||||||
</select>
|
|
||||||
|
|
||||||
<update id="modifySysApi" parameterType="com.glxp.api.entity.system.ThirdSysApiEntity">
|
|
||||||
UPDATE sys_thirdsys_api SET
|
|
||||||
name = #{name},
|
|
||||||
apiUrl = #{apiUrl},
|
|
||||||
guideUrl = #{guideUrl},
|
|
||||||
remark = #{remark}
|
|
||||||
where id = #{id}
|
|
||||||
</update>
|
|
||||||
|
|
||||||
|
|
||||||
</mapper>
|
|
Loading…
Reference in New Issue