Showing
8 changed files
with
62 additions
and
2 deletions
| @@ -154,11 +154,13 @@ create table if not exists `tbl_contract_distributor_line` | @@ -154,11 +154,13 @@ create table if not exists `tbl_contract_distributor_line` | ||
| 154 | `length_tol_neg` DECIMAL(10, 4) COMMENT '长度公差负', | 154 | `length_tol_neg` DECIMAL(10, 4) COMMENT '长度公差负', |
| 155 | `status` VARCHAR(50) COMMENT '状态', | 155 | `status` VARCHAR(50) COMMENT '状态', |
| 156 | `quantity` DECIMAL(15, 4) COMMENT '数量', | 156 | `quantity` DECIMAL(15, 4) COMMENT '数量', |
| 157 | + `processing_fee` DECIMAL(15, 4) COMMENT '加工费', | ||
| 157 | `unit_price` DECIMAL(15, 4) COMMENT '单价', | 158 | `unit_price` DECIMAL(15, 4) COMMENT '单价', |
| 158 | `amount_excluding_tax` DECIMAL(15, 2) COMMENT '不含税金额', | 159 | `amount_excluding_tax` DECIMAL(15, 2) COMMENT '不含税金额', |
| 159 | `total_amount` DECIMAL(15, 2) COMMENT '总金额', | 160 | `total_amount` DECIMAL(15, 2) COMMENT '总金额', |
| 160 | `delivery_date` DATE COMMENT '发货日期', | 161 | `delivery_date` DATE COMMENT '发货日期', |
| 161 | `show_order` INT DEFAULT 0 COMMENT '排序', | 162 | `show_order` INT DEFAULT 0 COMMENT '排序', |
| 163 | + `item_id` varchar(50) COMMENT '前端用ID', | ||
| 162 | `create_by_id` varchar(32) not null comment '创建人ID', | 164 | `create_by_id` varchar(32) not null comment '创建人ID', |
| 163 | `create_by` varchar(20) not null comment '创建人', | 165 | `create_by` varchar(20) not null comment '创建人', |
| 164 | `update_by_id` varchar(32) not null comment '更新人ID', | 166 | `update_by_id` varchar(32) not null comment '更新人ID', |
| @@ -3,6 +3,8 @@ package com.lframework.xingyun.sc.bo.contract; | @@ -3,6 +3,8 @@ package com.lframework.xingyun.sc.bo.contract; | ||
| 3 | import com.fasterxml.jackson.annotation.JsonFormat; | 3 | import com.fasterxml.jackson.annotation.JsonFormat; |
| 4 | import com.lframework.starter.common.constants.StringPool; | 4 | import com.lframework.starter.common.constants.StringPool; |
| 5 | import com.lframework.starter.web.core.bo.BaseBo; | 5 | import com.lframework.starter.web.core.bo.BaseBo; |
| 6 | +import com.lframework.starter.web.core.components.validation.IsNumberPrecision; | ||
| 7 | +import com.lframework.starter.web.core.components.validation.TypeMismatch; | ||
| 6 | import com.lframework.xingyun.sc.entity.ContractDistributorLine; | 8 | import com.lframework.xingyun.sc.entity.ContractDistributorLine; |
| 7 | import io.swagger.annotations.ApiModelProperty; | 9 | import io.swagger.annotations.ApiModelProperty; |
| 8 | import lombok.Data; | 10 | import lombok.Data; |
| @@ -79,6 +81,12 @@ public class GetContractDistributorLineBo extends BaseBo<ContractDistributorLine | @@ -79,6 +81,12 @@ public class GetContractDistributorLineBo extends BaseBo<ContractDistributorLine | ||
| 79 | private BigDecimal quantity; | 81 | private BigDecimal quantity; |
| 80 | 82 | ||
| 81 | /** | 83 | /** |
| 84 | + * 加工费 | ||
| 85 | + */ | ||
| 86 | + @ApiModelProperty(value = "加工费") | ||
| 87 | + private BigDecimal processingFee; | ||
| 88 | + | ||
| 89 | + /** | ||
| 82 | * 单价 | 90 | * 单价 |
| 83 | */ | 91 | */ |
| 84 | @ApiModelProperty("单价") | 92 | @ApiModelProperty("单价") |
| @@ -157,6 +165,12 @@ public class GetContractDistributorLineBo extends BaseBo<ContractDistributorLine | @@ -157,6 +165,12 @@ public class GetContractDistributorLineBo extends BaseBo<ContractDistributorLine | ||
| 157 | @ApiModelProperty("长度公差负") | 165 | @ApiModelProperty("长度公差负") |
| 158 | private BigDecimal lengthTolNeg; | 166 | private BigDecimal lengthTolNeg; |
| 159 | 167 | ||
| 168 | + /** | ||
| 169 | + * 前端用ID | ||
| 170 | + */ | ||
| 171 | + @ApiModelProperty(value = "前端用ID") | ||
| 172 | + private String itemId; | ||
| 173 | + | ||
| 160 | public GetContractDistributorLineBo() { | 174 | public GetContractDistributorLineBo() { |
| 161 | 175 | ||
| 162 | } | 176 | } |
| @@ -454,7 +454,6 @@ public class ContractDistributorStandardController extends DefaultBaseController | @@ -454,7 +454,6 @@ public class ContractDistributorStandardController extends DefaultBaseController | ||
| 454 | throw new DefaultClientException("参数错误!"); | 454 | throw new DefaultClientException("参数错误!"); |
| 455 | } | 455 | } |
| 456 | 456 | ||
| 457 | - // todo ymk 锁规接口待完善 | ||
| 458 | contractDistributorStandardService.specificationLock(vo); | 457 | contractDistributorStandardService.specificationLock(vo); |
| 459 | 458 | ||
| 460 | contractDistributorStandardService.cleanCacheByKey(vo.getId()); | 459 | contractDistributorStandardService.cleanCacheByKey(vo.getId()); |
| @@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.annotation.TableField; | @@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.annotation.TableField; | ||
| 5 | import com.baomidou.mybatisplus.annotation.TableName; | 5 | import com.baomidou.mybatisplus.annotation.TableName; |
| 6 | import com.lframework.starter.web.core.dto.BaseDto; | 6 | import com.lframework.starter.web.core.dto.BaseDto; |
| 7 | import com.lframework.starter.web.core.entity.BaseEntity; | 7 | import com.lframework.starter.web.core.entity.BaseEntity; |
| 8 | +import io.swagger.annotations.ApiModelProperty; | ||
| 8 | import lombok.Data; | 9 | import lombok.Data; |
| 9 | 10 | ||
| 10 | import java.math.BigDecimal; | 11 | import java.math.BigDecimal; |
| @@ -75,6 +76,11 @@ public class ContractDistributorLine extends BaseEntity implements BaseDto { | @@ -75,6 +76,11 @@ public class ContractDistributorLine extends BaseEntity implements BaseDto { | ||
| 75 | private BigDecimal quantity; | 76 | private BigDecimal quantity; |
| 76 | 77 | ||
| 77 | /** | 78 | /** |
| 79 | + * 加工费 | ||
| 80 | + */ | ||
| 81 | + private BigDecimal processingFee; | ||
| 82 | + | ||
| 83 | + /** | ||
| 78 | * 单价 | 84 | * 单价 |
| 79 | */ | 85 | */ |
| 80 | private BigDecimal unitPrice; | 86 | private BigDecimal unitPrice; |
| @@ -100,6 +106,11 @@ public class ContractDistributorLine extends BaseEntity implements BaseDto { | @@ -100,6 +106,11 @@ public class ContractDistributorLine extends BaseEntity implements BaseDto { | ||
| 100 | private Integer showOrder; | 106 | private Integer showOrder; |
| 101 | 107 | ||
| 102 | /** | 108 | /** |
| 109 | + * 前端用ID | ||
| 110 | + */ | ||
| 111 | + private String itemId; | ||
| 112 | + | ||
| 113 | + /** | ||
| 103 | * 创建人ID | 114 | * 创建人ID |
| 104 | */ | 115 | */ |
| 105 | @TableField(fill = FieldFill.INSERT) | 116 | @TableField(fill = FieldFill.INSERT) |
| @@ -73,6 +73,7 @@ public class ContractDistributorLineServiceImpl extends BaseMpServiceImpl<Contra | @@ -73,6 +73,7 @@ public class ContractDistributorLineServiceImpl extends BaseMpServiceImpl<Contra | ||
| 73 | data.setLength(vo.getLength()); | 73 | data.setLength(vo.getLength()); |
| 74 | data.setStatus(vo.getStatus()); | 74 | data.setStatus(vo.getStatus()); |
| 75 | data.setQuantity(vo.getQuantity()); | 75 | data.setQuantity(vo.getQuantity()); |
| 76 | + data.setProcessingFee(vo.getProcessingFee()); | ||
| 76 | data.setUnitPrice(vo.getUnitPrice()); | 77 | data.setUnitPrice(vo.getUnitPrice()); |
| 77 | data.setAmountExcludingTax(vo.getAmountExcludingTax()); | 78 | data.setAmountExcludingTax(vo.getAmountExcludingTax()); |
| 78 | data.setTotalAmount(vo.getTotalAmount()); | 79 | data.setTotalAmount(vo.getTotalAmount()); |
| @@ -85,6 +86,7 @@ public class ContractDistributorLineServiceImpl extends BaseMpServiceImpl<Contra | @@ -85,6 +86,7 @@ public class ContractDistributorLineServiceImpl extends BaseMpServiceImpl<Contra | ||
| 85 | data.setWidthTolNeg(vo.getWidthTolNeg()); | 86 | data.setWidthTolNeg(vo.getWidthTolNeg()); |
| 86 | data.setLengthTolPos(vo.getLengthTolPos()); | 87 | data.setLengthTolPos(vo.getLengthTolPos()); |
| 87 | data.setLengthTolNeg(vo.getLengthTolNeg()); | 88 | data.setLengthTolNeg(vo.getLengthTolNeg()); |
| 89 | + data.setItemId(vo.getItemId()); | ||
| 88 | 90 | ||
| 89 | getBaseMapper().insert(data); | 91 | getBaseMapper().insert(data); |
| 90 | 92 | ||
| @@ -114,6 +116,7 @@ public class ContractDistributorLineServiceImpl extends BaseMpServiceImpl<Contra | @@ -114,6 +116,7 @@ public class ContractDistributorLineServiceImpl extends BaseMpServiceImpl<Contra | ||
| 114 | .set(ContractDistributorLine::getLength, vo.getLength()) | 116 | .set(ContractDistributorLine::getLength, vo.getLength()) |
| 115 | .set(ContractDistributorLine::getStatus, vo.getStatus()) | 117 | .set(ContractDistributorLine::getStatus, vo.getStatus()) |
| 116 | .set(ContractDistributorLine::getQuantity, vo.getQuantity()) | 118 | .set(ContractDistributorLine::getQuantity, vo.getQuantity()) |
| 119 | + .set(ContractDistributorLine::getProcessingFee, vo.getProcessingFee()) | ||
| 117 | .set(ContractDistributorLine::getUnitPrice, vo.getUnitPrice()) | 120 | .set(ContractDistributorLine::getUnitPrice, vo.getUnitPrice()) |
| 118 | .set(ContractDistributorLine::getAmountExcludingTax, vo.getAmountExcludingTax()) | 121 | .set(ContractDistributorLine::getAmountExcludingTax, vo.getAmountExcludingTax()) |
| 119 | .set(ContractDistributorLine::getTotalAmount, vo.getTotalAmount()) | 122 | .set(ContractDistributorLine::getTotalAmount, vo.getTotalAmount()) |
| @@ -126,6 +129,7 @@ public class ContractDistributorLineServiceImpl extends BaseMpServiceImpl<Contra | @@ -126,6 +129,7 @@ public class ContractDistributorLineServiceImpl extends BaseMpServiceImpl<Contra | ||
| 126 | .set(ContractDistributorLine::getWidthTolNeg, vo.getWidthTolNeg()) | 129 | .set(ContractDistributorLine::getWidthTolNeg, vo.getWidthTolNeg()) |
| 127 | .set(ContractDistributorLine::getLengthTolPos, vo.getLengthTolPos()) | 130 | .set(ContractDistributorLine::getLengthTolPos, vo.getLengthTolPos()) |
| 128 | .set(ContractDistributorLine::getLengthTolNeg, vo.getLengthTolNeg()) | 131 | .set(ContractDistributorLine::getLengthTolNeg, vo.getLengthTolNeg()) |
| 132 | + .set(ContractDistributorLine::getItemId, vo.getItemId()) | ||
| 129 | .eq(ContractDistributorLine::getId, vo.getId()); | 133 | .eq(ContractDistributorLine::getId, vo.getId()); |
| 130 | 134 | ||
| 131 | getBaseMapper().update(updateWrapper); | 135 | getBaseMapper().update(updateWrapper); |
| @@ -92,6 +92,14 @@ public class CreateContractDistributorLineVo implements BaseVo, Serializable { | @@ -92,6 +92,14 @@ public class CreateContractDistributorLineVo implements BaseVo, Serializable { | ||
| 92 | private BigDecimal quantity; | 92 | private BigDecimal quantity; |
| 93 | 93 | ||
| 94 | /** | 94 | /** |
| 95 | + * 加工费 | ||
| 96 | + */ | ||
| 97 | + @ApiModelProperty(value = "加工费") | ||
| 98 | + @TypeMismatch(message = "加工费格式有误!") | ||
| 99 | + @IsNumberPrecision(message = "加工费最多允许4位小数!", value = 4) | ||
| 100 | + private BigDecimal processingFee; | ||
| 101 | + | ||
| 102 | + /** | ||
| 95 | * 单价 | 103 | * 单价 |
| 96 | */ | 104 | */ |
| 97 | @ApiModelProperty(value = "单价") | 105 | @ApiModelProperty(value = "单价") |
| @@ -178,4 +186,9 @@ public class CreateContractDistributorLineVo implements BaseVo, Serializable { | @@ -178,4 +186,9 @@ public class CreateContractDistributorLineVo implements BaseVo, Serializable { | ||
| 178 | @TypeMismatch(message = "长度公差负格式有误!") | 186 | @TypeMismatch(message = "长度公差负格式有误!") |
| 179 | private BigDecimal lengthTolNeg; | 187 | private BigDecimal lengthTolNeg; |
| 180 | 188 | ||
| 189 | + /** | ||
| 190 | + * 前端用ID | ||
| 191 | + */ | ||
| 192 | + @ApiModelProperty(value = "前端用ID") | ||
| 193 | + private String itemId; | ||
| 181 | } | 194 | } |
| @@ -96,6 +96,14 @@ public class UpdateContractDistributorLineVo implements BaseVo, Serializable { | @@ -96,6 +96,14 @@ public class UpdateContractDistributorLineVo implements BaseVo, Serializable { | ||
| 96 | private BigDecimal quantity; | 96 | private BigDecimal quantity; |
| 97 | 97 | ||
| 98 | /** | 98 | /** |
| 99 | + * 加工费 | ||
| 100 | + */ | ||
| 101 | + @ApiModelProperty(value = "加工费") | ||
| 102 | + @TypeMismatch(message = "加工费格式有误!") | ||
| 103 | + @IsNumberPrecision(message = "加工费最多允许4位小数!", value = 4) | ||
| 104 | + private BigDecimal processingFee; | ||
| 105 | + | ||
| 106 | + /** | ||
| 99 | * 单价 | 107 | * 单价 |
| 100 | */ | 108 | */ |
| 101 | @ApiModelProperty(value = "单价") | 109 | @ApiModelProperty(value = "单价") |
| @@ -181,5 +189,10 @@ public class UpdateContractDistributorLineVo implements BaseVo, Serializable { | @@ -181,5 +189,10 @@ public class UpdateContractDistributorLineVo implements BaseVo, Serializable { | ||
| 181 | @TypeMismatch(message = "长度公差负格式有误!") | 189 | @TypeMismatch(message = "长度公差负格式有误!") |
| 182 | private BigDecimal lengthTolNeg; | 190 | private BigDecimal lengthTolNeg; |
| 183 | 191 | ||
| 192 | + /** | ||
| 193 | + * 前端用ID | ||
| 194 | + */ | ||
| 195 | + @ApiModelProperty(value = "前端用ID") | ||
| 196 | + private String itemId; | ||
| 184 | } | 197 | } |
| 185 | 198 |
| @@ -13,6 +13,7 @@ | @@ -13,6 +13,7 @@ | ||
| 13 | <result column="length" property="length"/> | 13 | <result column="length" property="length"/> |
| 14 | <result column="status" property="status"/> | 14 | <result column="status" property="status"/> |
| 15 | <result column="quantity" property="quantity"/> | 15 | <result column="quantity" property="quantity"/> |
| 16 | + <result column="processing_fee" property="processingFee"/> | ||
| 16 | <result column="unit_price" property="unitPrice"/> | 17 | <result column="unit_price" property="unitPrice"/> |
| 17 | <result column="amount_excluding_tax" property="amountExcludingTax"/> | 18 | <result column="amount_excluding_tax" property="amountExcludingTax"/> |
| 18 | <result column="total_amount" property="totalAmount"/> | 19 | <result column="total_amount" property="totalAmount"/> |
| @@ -31,6 +32,7 @@ | @@ -31,6 +32,7 @@ | ||
| 31 | <result column="width_tol_neg" property="widthTolNeg"/> | 32 | <result column="width_tol_neg" property="widthTolNeg"/> |
| 32 | <result column="length_tol_pos" property="lengthTolPos"/> | 33 | <result column="length_tol_pos" property="lengthTolPos"/> |
| 33 | <result column="length_tol_neg" property="lengthTolNeg"/> | 34 | <result column="length_tol_neg" property="lengthTolNeg"/> |
| 35 | + <result column="item_id" property="itemId"/> | ||
| 34 | </resultMap> | 36 | </resultMap> |
| 35 | 37 | ||
| 36 | <sql id="ContractDistributorLine_sql"> | 38 | <sql id="ContractDistributorLine_sql"> |
| @@ -44,6 +46,7 @@ | @@ -44,6 +46,7 @@ | ||
| 44 | tb.length, | 46 | tb.length, |
| 45 | tb.status, | 47 | tb.status, |
| 46 | tb.quantity, | 48 | tb.quantity, |
| 49 | + tb.processing_fee, | ||
| 47 | tb.unit_price, | 50 | tb.unit_price, |
| 48 | tb.amount_excluding_tax, | 51 | tb.amount_excluding_tax, |
| 49 | tb.total_amount, | 52 | tb.total_amount, |
| @@ -61,7 +64,8 @@ | @@ -61,7 +64,8 @@ | ||
| 61 | tb.width_tol_pos, | 64 | tb.width_tol_pos, |
| 62 | tb.width_tol_neg, | 65 | tb.width_tol_neg, |
| 63 | tb.length_tol_pos, | 66 | tb.length_tol_pos, |
| 64 | - tb.length_tol_neg | 67 | + tb.length_tol_neg, |
| 68 | + tb.item_id | ||
| 65 | FROM tbl_contract_distributor_line AS tb | 69 | FROM tbl_contract_distributor_line AS tb |
| 66 | </sql> | 70 | </sql> |
| 67 | 71 |