发票登记
parent
6feaa85616
commit
0b79be5350
@ -1,9 +1,13 @@
|
||||
package com.glxp.api.dao.inout;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
import com.glxp.api.dao.BaseMapperPlus;
|
||||
import com.glxp.api.entity.inout.IoOrderInvoiceEntity;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
@Mapper
|
||||
public interface IoOrderInvoiceMapper extends BaseMapper<IoOrderInvoiceEntity> {
|
||||
public interface IoOrderInvoiceMapper extends BaseMapperPlus<IoOrderInvoiceMapper, IoOrderInvoiceEntity, IoOrderInvoiceEntity> {
|
||||
|
||||
boolean insertInvoice(IoOrderInvoiceEntity ioOrderInvoiceEntity);
|
||||
|
||||
}
|
||||
|
@ -0,0 +1,93 @@
|
||||
package com.glxp.api.req.inout;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.glxp.api.entity.inout.IoOrderDetailResultEntity;
|
||||
import com.glxp.api.entity.inout.IoOrderInvoiceEntity;
|
||||
import com.glxp.api.entity.purchase.SupCertSetEntity;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author : zhangsan
|
||||
* @date : 2023/3/15 10:02
|
||||
* @modyified By :
|
||||
*/
|
||||
@Data
|
||||
public class IoOrderInvoiceRequest {
|
||||
|
||||
private Integer id;
|
||||
|
||||
|
||||
private String orderIdFk;
|
||||
|
||||
|
||||
private String machineNo;
|
||||
|
||||
|
||||
private String invoiceCode;
|
||||
|
||||
|
||||
private String invoiceEncode;
|
||||
|
||||
|
||||
private String invoiceDate;
|
||||
|
||||
|
||||
private String price;
|
||||
|
||||
|
||||
private Date updateTime;
|
||||
|
||||
|
||||
private String createUser;
|
||||
|
||||
|
||||
private Date createTime;
|
||||
|
||||
|
||||
private String updateUser;
|
||||
|
||||
|
||||
private String bindRlFk;
|
||||
|
||||
|
||||
private String batchNo;
|
||||
|
||||
|
||||
private String productDate;
|
||||
|
||||
|
||||
private String expireDate;
|
||||
|
||||
private String licenseUrl;
|
||||
|
||||
private String remark;
|
||||
|
||||
public static final String COL_ID = "id";
|
||||
|
||||
public static final String COL_ORDERIDFK = "orderIdFk";
|
||||
|
||||
public static final String COL_MACHINENO = "machineNo";
|
||||
|
||||
public static final String COL_INVOICECODE = "invoiceCode";
|
||||
|
||||
public static final String COL_INVOICEENCODE = "invoiceEncode";
|
||||
|
||||
public static final String COL_INVOICEDATE = "invoiceDate";
|
||||
|
||||
public static final String COL_PRICE = "price";
|
||||
|
||||
public static final String COL_UPDATETIME = "updateTime";
|
||||
|
||||
public static final String COL_CREATEUSER = "createUser";
|
||||
|
||||
public static final String COL_CREATETIME = "createTime";
|
||||
|
||||
public static final String COL_UPDATEUSER = "updateUser";
|
||||
|
||||
public static final String COL_REMARK = "remark";
|
||||
}
|
@ -0,0 +1,114 @@
|
||||
package com.glxp.api.res.inout;
|
||||
|
||||
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;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@TableName(value = "io_order_invoice")
|
||||
public class IoOrderInvoiceResponse {
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 订单号外键
|
||||
*/
|
||||
private String orderIdFk;
|
||||
|
||||
/**
|
||||
* 机器编码
|
||||
*/
|
||||
private String machineNo;
|
||||
|
||||
/**
|
||||
* 发票代码
|
||||
*/
|
||||
private String invoiceCode;
|
||||
|
||||
/**
|
||||
* 发票编码
|
||||
*/
|
||||
private String invoiceEncode;
|
||||
|
||||
/**
|
||||
* 开票日期
|
||||
*/
|
||||
private String invoiceDate;
|
||||
|
||||
/**
|
||||
* 发票价格
|
||||
*/
|
||||
private String price;
|
||||
|
||||
/**
|
||||
* 更新是日期
|
||||
*/
|
||||
private Date updateTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
private String createUser;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 更新人
|
||||
*/
|
||||
private String updateUser;
|
||||
|
||||
private String bindRlFk;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 生产日期
|
||||
*/
|
||||
private String productDate;
|
||||
|
||||
/**
|
||||
* 失效日期
|
||||
*/
|
||||
private String expireDate;
|
||||
|
||||
private String remark;
|
||||
|
||||
private String cpmctymc;
|
||||
|
||||
private String ggxh;
|
||||
private String licenseUrl;
|
||||
|
||||
|
||||
public static final String COL_ID = "id";
|
||||
|
||||
public static final String COL_ORDERIDFK = "orderIdFk";
|
||||
|
||||
public static final String COL_MACHINENO = "machineNo";
|
||||
|
||||
public static final String COL_INVOICECODE = "invoiceCode";
|
||||
|
||||
public static final String COL_INVOICEENCODE = "invoiceEncode";
|
||||
|
||||
public static final String COL_INVOICEDATE = "invoiceDate";
|
||||
|
||||
public static final String COL_PRICE = "price";
|
||||
|
||||
public static final String COL_UPDATETIME = "updateTime";
|
||||
|
||||
public static final String COL_CREATEUSER = "createUser";
|
||||
|
||||
public static final String COL_CREATETIME = "createTime";
|
||||
|
||||
public static final String COL_UPDATEUSER = "updateUser";
|
||||
|
||||
public static final String COL_REMARK = "remark";
|
||||
}
|
@ -1,4 +1,14 @@
|
||||
package com.glxp.api.service.inout;
|
||||
|
||||
import com.glxp.api.entity.inout.IoOrderInvoiceEntity;
|
||||
import com.glxp.api.req.inout.IoOrderInvoiceRequest;
|
||||
|
||||
public interface IoOrderInvoiceService {
|
||||
|
||||
boolean deleteByInvId(Integer id);
|
||||
|
||||
boolean updateByInvId(IoOrderInvoiceRequest ioOrderInvoiceRequest);
|
||||
|
||||
boolean insertInvoice(IoOrderInvoiceEntity ioOrderInvoiceEntity);
|
||||
|
||||
}
|
||||
|
@ -1,10 +1,34 @@
|
||||
package com.glxp.api.service.inout.impl;
|
||||
|
||||
import com.glxp.api.dao.inout.IoOrderInvoiceMapper;
|
||||
import com.glxp.api.entity.inout.IoOrderInvoiceEntity;
|
||||
import com.glxp.api.req.inout.IoOrderInvoiceRequest;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.glxp.api.service.inout.IoOrderInvoiceService;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
@Service
|
||||
public class IoOrderInvoiceServiceImpl implements IoOrderInvoiceService {
|
||||
@Resource
|
||||
IoOrderInvoiceMapper ioOrderInvoiceMapper;
|
||||
|
||||
@Override
|
||||
public boolean deleteByInvId(Integer id) {
|
||||
return this.ioOrderInvoiceMapper.deleteById(id)>0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean updateByInvId(IoOrderInvoiceRequest ioOrderInvoiceRequest) {
|
||||
IoOrderInvoiceEntity ioOrderInvoiceEntity = new IoOrderInvoiceEntity();
|
||||
BeanUtils.copyProperties(ioOrderInvoiceRequest,ioOrderInvoiceEntity);
|
||||
return this.ioOrderInvoiceMapper.updateById(ioOrderInvoiceEntity)>0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean insertInvoice(IoOrderInvoiceEntity ioOrderInvoiceEntity) {
|
||||
return ioOrderInvoiceMapper.insertInvoice(ioOrderInvoiceEntity);
|
||||
}
|
||||
}
|
||||
|
@ -1,4 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.glxp.api.dao.inout.IoOrderInvoiceMapper">
|
||||
|
||||
<insert id="insertInvoice" parameterType="com.glxp.api.entity.inout.IoOrderInvoiceEntity">
|
||||
INSERT INTO io_order_invoice( orderIdFk, bindRlFk,batchNo, productDate, expireDate
|
||||
)
|
||||
values (#{orderIdFk},
|
||||
#{bindRlFk},
|
||||
#{batchNo},
|
||||
#{productDate},
|
||||
#{expireDate}
|
||||
)
|
||||
</insert>
|
||||
|
||||
</mapper>
|
||||
|
Loading…
Reference in New Issue