diff --git a/docs/jsh_erp.sql b/docs/jsh_erp.sql index cc557ad9..dc7c911b 100644 --- a/docs/jsh_erp.sql +++ b/docs/jsh_erp.sql @@ -570,21 +570,13 @@ CREATE TABLE `jsh_material` ( `CategoryId` bigint(20) DEFAULT NULL COMMENT '产品类型', `Name` varchar(50) DEFAULT NULL COMMENT '名称', `Mfrs` varchar(50) DEFAULT NULL COMMENT '制造商', - `Packing` decimal(24,6) DEFAULT NULL COMMENT '包装(KG/包)', `SafetyStock` decimal(24,6) DEFAULT NULL COMMENT '安全存量(KG)', `Model` varchar(50) DEFAULT NULL COMMENT '型号', `Standard` varchar(50) DEFAULT NULL COMMENT '规格', `Color` varchar(50) DEFAULT NULL COMMENT '颜色', `Unit` varchar(50) DEFAULT NULL COMMENT '单位-单个', `Remark` varchar(100) DEFAULT NULL COMMENT '备注', - `RetailPrice` decimal(24,6) DEFAULT NULL COMMENT '零售价', - `LowPrice` decimal(24,6) DEFAULT NULL COMMENT '最低售价', - `PresetPriceOne` decimal(24,6) DEFAULT NULL COMMENT '预设售价一', - `PresetPriceTwo` decimal(24,6) DEFAULT NULL COMMENT '预设售价二', `UnitId` bigint(20) DEFAULT NULL COMMENT '计量单位Id', - `FirstOutUnit` varchar(50) DEFAULT NULL COMMENT '首选出库单位', - `FirstInUnit` varchar(50) DEFAULT NULL COMMENT '首选入库单位', - `PriceStrategy` varchar(500) DEFAULT NULL COMMENT '价格策略', `Enabled` bit(1) DEFAULT NULL COMMENT '启用 0-禁用 1-启用', `OtherField1` varchar(50) DEFAULT NULL COMMENT '自定义1', `OtherField2` varchar(50) DEFAULT NULL COMMENT '自定义2', @@ -600,30 +592,30 @@ CREATE TABLE `jsh_material` ( -- ---------------------------- -- Records of jsh_material -- ---------------------------- -INSERT INTO `jsh_material` VALUES ('564', '14', '商品1', '', null, null, 'sp1', '', '', '个', '', '22.000000', '22.000000', '22.000000', '22.000000', null, null, null, '[{\"basic\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"enableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '1', '0'); -INSERT INTO `jsh_material` VALUES ('565', '14', '商品2', '', null, null, 'sp2', '', '', '个', '', '44.000000', '44.000000', '44.000000', '44.000000', null, null, null, '[{\"basic\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"1\"}},{\"other\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '1', '1', '0'); -INSERT INTO `jsh_material` VALUES ('566', '15', '商品666', '', null, null, 'sp666', '', '', '个', '', '5.000000', '4.000000', '3.000000', '2.000000', null, null, null, '[{\"basic\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '117', '0'); -INSERT INTO `jsh_material` VALUES ('567', null, '商品1', '', null, null, 'dsp1', '', '', '个', '', '11.000000', '11.000000', '11.000000', '11.000000', null, null, null, '[{\"basic\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '115', '0'); -INSERT INTO `jsh_material` VALUES ('568', '17', '商品1', '', null, '100.000000', 'sp1', '', '', '个', '', null, null, null, null, null, null, null, '[{\"basic\":{\"Unit\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\"}}]', '', '', '', '', '0', '63', '0'); -INSERT INTO `jsh_material` VALUES ('569', '17', '商品2', '', null, '200.000000', 'sp2', '', '', '只', '', '5.000000', '5.000000', '5.000000', '5.000000', null, null, null, '[{\"basic\":{\"Unit\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\"}}]', '', '', '', '', '0', '63', '0'); -INSERT INTO `jsh_material` VALUES ('570', '17', '商品3', '', null, '300.000000', 'sp3', '', '', '个', '', null, null, null, null, null, null, null, '[{\"basic\":{\"Unit\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\"}}]', '', '', '', '', '0', '63', '0'); -INSERT INTO `jsh_material` VALUES ('571', null, '商品4', '', null, null, 'sp4', '', '', '', '', null, null, null, null, '15', '个', '箱', '[{\"basic\":{\"Unit\":\"个\",\"RetailPrice\":\"3\",\"LowPrice\":\"2\",\"PresetPriceOne\":\"2\",\"PresetPriceTwo\":\"2\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"箱\",\"RetailPrice\":\"36\",\"LowPrice\":\"24\",\"PresetPriceOne\":\"24\",\"PresetPriceTwo\":\"24\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('572', null, '234234', '', null, null, '234234', '', '', '', '', null, null, null, null, null, null, null, '[{\"basic\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('573', null, '12312', '', null, null, '12', '', '', '', '', null, null, null, null, null, null, null, '[{\"basic\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('574', null, '商品5', '', null, null, '213qw', '', '', '个', '', null, null, null, null, null, null, null, '[{\"basic\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('575', null, '商品6', '', null, null, 'sp6', '', '', '', '', null, null, null, null, '15', '', '', '[{\"basic\":{\"Unit\":\"个\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"箱\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('576', null, '商品7', '', null, null, 'sp7', '', '', '', '', null, null, null, null, '15', '', '', '[{\"basic\":{\"Unit\":\"个\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"箱\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('577', null, '商品8', '', null, null, 'sp8', '', '', '', '', null, null, null, null, '15', '', '', '[{\"basic\":{\"Unit\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\"}}]', '', '', '', '', '0', '63', '0'); -INSERT INTO `jsh_material` VALUES ('578', '17', '商品9', '', null, null, 'sp9', '', '', '', '', null, null, null, null, '15', '', '', '[{\"basic\":{\"Unit\":\"个\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"箱\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('579', null, '商品17', '', null, null, 'sp17', '', '', '', '', null, null, null, null, '15', '', '', '[{\"basic\":{\"Unit\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\"}}]', '', '', '', '', '0', '63', '0'); -INSERT INTO `jsh_material` VALUES ('580', null, '15', '', null, null, '15', '', '', '', '', null, null, null, null, '15', '', '', '[{\"basic\":{\"Unit\":\"个\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"箱\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('581', null, '16', '', null, null, '16', '', '', '', '', null, null, null, null, '15', '', '', '[{\"basic\":{\"Unit\":\"个\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"箱\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('582', null, '商品20', '', null, null, 'sp2', '', '', '个', '', null, null, null, null, null, '', '', '[{\"basic\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('583', null, 'wer', '', null, null, 'rqwe', '', '', '', '', null, null, null, null, '15', '', '', '[{\"basic\":{\"Unit\":\"个\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"箱\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('584', null, 'sfds', '', null, null, 'a2233', '12', '2', 'ge', '', '1.000000', '2.000000', '3.000000', '4.000000', null, '', '', '[{\"basic\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('585', null, 'asdf', '', null, null, 'adsfasdf', '', '', '', '', null, null, null, null, '15', '', '', '[{\"basic\":{\"Unit\":\"个\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"箱\",\"RetailPrice\":\"\",\"LowPrice\":\"\",\"PresetPriceOne\":\"\",\"PresetPriceTwo\":\"\"}}]', '', '', '', '', '0', '63', '1'); -INSERT INTO `jsh_material` VALUES ('586', null, '序列号商品测试', '', null, null, 'xlh123', '', '', '个', '', null, null, null, null, null, null, null, '[{\"basic\":{\"Unit\":\"\",\"EnableSerialNumber\":\"1\"}},{\"other\":{\"Unit\":\"\"}}]', '', '', '', '', '1', '63', '0'); -INSERT INTO `jsh_material` VALUES ('587', null, '商品test1', '', null, null, '', 'test1', '', '个', '', null, null, null, null, null, null, null, '[{\"basic\":{\"Unit\":\"\",\"EnableSerialNumber\":\"0\"}},{\"other\":{\"Unit\":\"\"}}]', '', '', '', '', '0', '63', '0'); +INSERT INTO `jsh_material` VALUES ('564', '14', '商品1', '', null, 'sp1', '', '', '个', '', null, '', '', '', '', '0', '1', '0'); +INSERT INTO `jsh_material` VALUES ('565', '14', '商品2', '', null, 'sp2', '', '', '个', '', null, '', '', '', '', '1', '1', '0'); +INSERT INTO `jsh_material` VALUES ('566', '15', '商品666', '', null, 'sp666', '', '', '个', '', null, '', '', '', '', '0', '117', '0'); +INSERT INTO `jsh_material` VALUES ('567', null, '商品1', '', null, 'dsp1', '', '', '个', '', null, '', '', '', '', '0', '115', '0'); +INSERT INTO `jsh_material` VALUES ('568', '17', '商品1', '', '100.000000', 'sp1', '', '', '个', '', null, '', '', '', '', '0', '63', '0'); +INSERT INTO `jsh_material` VALUES ('569', '17', '商品2', '', '200.000000', 'sp2', '', '', '只', '', null, '', '', '', '', '0', '63', '0'); +INSERT INTO `jsh_material` VALUES ('570', '17', '商品3', '', '300.000000', 'sp3', '', '', '个', '', null, '', '', '', '', '0', '63', '0'); +INSERT INTO `jsh_material` VALUES ('571', null, '商品4', '', null, 'sp4', '', '', '', '', '15', '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('572', null, '234234', '', null, '234234', '', '', '', '', null, '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('573', null, '12312', '', null, '12', '', '', '', '', null, '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('574', null, '商品5', '', null, '213qw', '', '', '个', '', null, '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('575', null, '商品6', '', null, 'sp6', '', '', '', '', '15', '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('576', null, '商品7', '', null, 'sp7', '', '', '', '', '15', '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('577', null, '商品8', '', null, 'sp8', '', '', '', '', '15', '', '', '', '', '0', '63', '0'); +INSERT INTO `jsh_material` VALUES ('578', '17', '商品9', '', null, 'sp9', '', '', '', '', '15', '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('579', null, '商品17', '', null, 'sp17', '', '', '', '', '15', '', '', '', '', '0', '63', '0'); +INSERT INTO `jsh_material` VALUES ('580', null, '15', '', null, '15', '', '', '', '', '15', '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('581', null, '16', '', null, '16', '', '', '', '', '15', '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('582', null, '商品20', '', null, 'sp2', '', '', '个', '', null, '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('583', null, 'wer', '', null, 'rqwe', '', '', '', '', '15', '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('584', null, 'sfds', '', null, 'a2233', '12', '2', 'ge', '', null, '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('585', null, 'asdf', '', null, 'adsfasdf', '', '', '', '', '15', '', '', '', '', '0', '63', '1'); +INSERT INTO `jsh_material` VALUES ('586', null, '序列号商品测试', '', null, 'xlh123', '', '', '个', '', null, '', '', '', '', '1', '63', '0'); +INSERT INTO `jsh_material` VALUES ('587', null, '商品test1', '', null, '', 'test1', '', '个', '', null, '', '', '', '', '0', '63', '0'); -- ---------------------------- -- Table structure for jsh_materialcategory diff --git a/docs/数据库更新记录-方便升级.txt b/docs/数据库更新记录-方便升级.txt index a8746712..2e77b7eb 100644 --- a/docs/数据库更新记录-方便升级.txt +++ b/docs/数据库更新记录-方便升级.txt @@ -771,3 +771,17 @@ INSERT INTO `jsh_functions` VALUES (245,'000107', '插件管理', '0001', '/page -- 给商品扩展表增加 是否默认基础单位 字段 -- ---------------------------- alter table jsh_material_extend add default_flag VARCHAR(1) DEFAULT 1 COMMENT '是否为默认单位,1是,0否' after low_decimal; + +-- ---------------------------- +-- 时间:2020年05月04日 +-- by jishenghua +-- 删除商品表的多价格相关的字段 +-- ---------------------------- +alter table jsh_material drop Packing; +alter table jsh_material drop RetailPrice; +alter table jsh_material drop LowPrice; +alter table jsh_material drop PresetPriceOne; +alter table jsh_material drop PresetPriceTwo; +alter table jsh_material drop FirstOutUnit; +alter table jsh_material drop FirstInUnit; +alter table jsh_material drop PriceStrategy; \ No newline at end of file diff --git a/src/main/java/com/jsh/erp/controller/MaterialController.java b/src/main/java/com/jsh/erp/controller/MaterialController.java index 55fab120..074b4a80 100644 --- a/src/main/java/com/jsh/erp/controller/MaterialController.java +++ b/src/main/java/com/jsh/erp/controller/MaterialController.java @@ -331,10 +331,10 @@ public class MaterialController { objs[2] = m.getModel(); objs[3] = m.getSafetystock() == null? "" : m.getSafetystock().toString(); objs[4] = m.getUnit(); - objs[5] = m.getRetailprice() == null ? "" : m.getRetailprice().toString(); - objs[6] = m.getLowprice() == null ? "" : m.getLowprice().toString(); - objs[7] = m.getPresetpriceone() == null ? "" : m.getPresetpriceone().toString(); - objs[8] = m.getPresetpricetwo() == null ? "" : m.getPresetpricetwo().toString(); + objs[5] = ""; + objs[6] = ""; + objs[7] = ""; + objs[8] = ""; objs[9] = m.getRemark(); objs[10] = m.getEnabled() ? "启用" : "禁用"; objects.add(objs); diff --git a/src/main/java/com/jsh/erp/datasource/entities/DepotItemVo4WithInfoEx.java b/src/main/java/com/jsh/erp/datasource/entities/DepotItemVo4WithInfoEx.java index 74d3a54c..79f3ea45 100644 --- a/src/main/java/com/jsh/erp/datasource/entities/DepotItemVo4WithInfoEx.java +++ b/src/main/java/com/jsh/erp/datasource/entities/DepotItemVo4WithInfoEx.java @@ -36,6 +36,8 @@ public class DepotItemVo4WithInfoEx extends DepotItem{ private String priceStrategy; + private BigDecimal purchaseDecimal; + private String barCode; public Long getMId() { @@ -166,6 +168,14 @@ public class DepotItemVo4WithInfoEx extends DepotItem{ this.priceStrategy = priceStrategy; } + public BigDecimal getPurchaseDecimal() { + return purchaseDecimal; + } + + public void setPurchaseDecimal(BigDecimal purchaseDecimal) { + this.purchaseDecimal = purchaseDecimal; + } + public String getBarCode() { return barCode; } diff --git a/src/main/java/com/jsh/erp/datasource/entities/Material.java b/src/main/java/com/jsh/erp/datasource/entities/Material.java index 8c119684..19c33819 100644 --- a/src/main/java/com/jsh/erp/datasource/entities/Material.java +++ b/src/main/java/com/jsh/erp/datasource/entities/Material.java @@ -3,834 +3,182 @@ package com.jsh.erp.datasource.entities; import java.math.BigDecimal; public class Material { - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Id - * - * @mbggenerated - */ private Long id; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.CategoryId - * - * @mbggenerated - */ private Long categoryid; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Name - * - * @mbggenerated - */ private String name; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Mfrs - * - * @mbggenerated - */ private String mfrs; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Packing - * - * @mbggenerated - */ - private BigDecimal packing; - - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.SafetyStock - * - * @mbggenerated - */ private BigDecimal safetystock; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Model - * - * @mbggenerated - */ private String model; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Standard - * - * @mbggenerated - */ private String standard; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Color - * - * @mbggenerated - */ private String color; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Unit - * - * @mbggenerated - */ private String unit; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Remark - * - * @mbggenerated - */ private String remark; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.RetailPrice - * - * @mbggenerated - */ - private BigDecimal retailprice; - - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.LowPrice - * - * @mbggenerated - */ - private BigDecimal lowprice; - - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.PresetPriceOne - * - * @mbggenerated - */ - private BigDecimal presetpriceone; - - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.PresetPriceTwo - * - * @mbggenerated - */ - private BigDecimal presetpricetwo; - - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.UnitId - * - * @mbggenerated - */ private Long unitid; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.FirstOutUnit - * - * @mbggenerated - */ - private String firstoutunit; - - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.FirstInUnit - * - * @mbggenerated - */ - private String firstinunit; - - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.PriceStrategy - * - * @mbggenerated - */ - private String pricestrategy; - - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.Enabled - * - * @mbggenerated - */ private Boolean enabled; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.OtherField1 - * - * @mbggenerated - */ private String otherfield1; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.OtherField2 - * - * @mbggenerated - */ private String otherfield2; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.OtherField3 - * - * @mbggenerated - */ private String otherfield3; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.enableSerialNumber - * - * @mbggenerated - */ private String enableserialnumber; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.tenant_id - * - * @mbggenerated - */ private Long tenantId; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database column jsh_material.delete_Flag - * - * @mbggenerated - */ private String deleteFlag; - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Id - * - * @return the value of jsh_material.Id - * - * @mbggenerated - */ public Long getId() { return id; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Id - * - * @param id the value for jsh_material.Id - * - * @mbggenerated - */ public void setId(Long id) { this.id = id; } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.CategoryId - * - * @return the value of jsh_material.CategoryId - * - * @mbggenerated - */ public Long getCategoryid() { return categoryid; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.CategoryId - * - * @param categoryid the value for jsh_material.CategoryId - * - * @mbggenerated - */ public void setCategoryid(Long categoryid) { this.categoryid = categoryid; } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Name - * - * @return the value of jsh_material.Name - * - * @mbggenerated - */ public String getName() { return name; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Name - * - * @param name the value for jsh_material.Name - * - * @mbggenerated - */ public void setName(String name) { this.name = name == null ? null : name.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Mfrs - * - * @return the value of jsh_material.Mfrs - * - * @mbggenerated - */ public String getMfrs() { return mfrs; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Mfrs - * - * @param mfrs the value for jsh_material.Mfrs - * - * @mbggenerated - */ public void setMfrs(String mfrs) { this.mfrs = mfrs == null ? null : mfrs.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Packing - * - * @return the value of jsh_material.Packing - * - * @mbggenerated - */ - public BigDecimal getPacking() { - return packing; - } - - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Packing - * - * @param packing the value for jsh_material.Packing - * - * @mbggenerated - */ - public void setPacking(BigDecimal packing) { - this.packing = packing; - } - - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.SafetyStock - * - * @return the value of jsh_material.SafetyStock - * - * @mbggenerated - */ public BigDecimal getSafetystock() { return safetystock; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.SafetyStock - * - * @param safetystock the value for jsh_material.SafetyStock - * - * @mbggenerated - */ public void setSafetystock(BigDecimal safetystock) { this.safetystock = safetystock; } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Model - * - * @return the value of jsh_material.Model - * - * @mbggenerated - */ public String getModel() { return model; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Model - * - * @param model the value for jsh_material.Model - * - * @mbggenerated - */ public void setModel(String model) { this.model = model == null ? null : model.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Standard - * - * @return the value of jsh_material.Standard - * - * @mbggenerated - */ public String getStandard() { return standard; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Standard - * - * @param standard the value for jsh_material.Standard - * - * @mbggenerated - */ public void setStandard(String standard) { this.standard = standard == null ? null : standard.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Color - * - * @return the value of jsh_material.Color - * - * @mbggenerated - */ public String getColor() { return color; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Color - * - * @param color the value for jsh_material.Color - * - * @mbggenerated - */ public void setColor(String color) { this.color = color == null ? null : color.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Unit - * - * @return the value of jsh_material.Unit - * - * @mbggenerated - */ public String getUnit() { return unit; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Unit - * - * @param unit the value for jsh_material.Unit - * - * @mbggenerated - */ public void setUnit(String unit) { this.unit = unit == null ? null : unit.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Remark - * - * @return the value of jsh_material.Remark - * - * @mbggenerated - */ public String getRemark() { return remark; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Remark - * - * @param remark the value for jsh_material.Remark - * - * @mbggenerated - */ public void setRemark(String remark) { this.remark = remark == null ? null : remark.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.RetailPrice - * - * @return the value of jsh_material.RetailPrice - * - * @mbggenerated - */ - public BigDecimal getRetailprice() { - return retailprice; - } - - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.RetailPrice - * - * @param retailprice the value for jsh_material.RetailPrice - * - * @mbggenerated - */ - public void setRetailprice(BigDecimal retailprice) { - this.retailprice = retailprice; - } - - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.LowPrice - * - * @return the value of jsh_material.LowPrice - * - * @mbggenerated - */ - public BigDecimal getLowprice() { - return lowprice; - } - - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.LowPrice - * - * @param lowprice the value for jsh_material.LowPrice - * - * @mbggenerated - */ - public void setLowprice(BigDecimal lowprice) { - this.lowprice = lowprice; - } - - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.PresetPriceOne - * - * @return the value of jsh_material.PresetPriceOne - * - * @mbggenerated - */ - public BigDecimal getPresetpriceone() { - return presetpriceone; - } - - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.PresetPriceOne - * - * @param presetpriceone the value for jsh_material.PresetPriceOne - * - * @mbggenerated - */ - public void setPresetpriceone(BigDecimal presetpriceone) { - this.presetpriceone = presetpriceone; - } - - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.PresetPriceTwo - * - * @return the value of jsh_material.PresetPriceTwo - * - * @mbggenerated - */ - public BigDecimal getPresetpricetwo() { - return presetpricetwo; - } - - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.PresetPriceTwo - * - * @param presetpricetwo the value for jsh_material.PresetPriceTwo - * - * @mbggenerated - */ - public void setPresetpricetwo(BigDecimal presetpricetwo) { - this.presetpricetwo = presetpricetwo; - } - - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.UnitId - * - * @return the value of jsh_material.UnitId - * - * @mbggenerated - */ public Long getUnitid() { return unitid; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.UnitId - * - * @param unitid the value for jsh_material.UnitId - * - * @mbggenerated - */ public void setUnitid(Long unitid) { this.unitid = unitid; } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.FirstOutUnit - * - * @return the value of jsh_material.FirstOutUnit - * - * @mbggenerated - */ - public String getFirstoutunit() { - return firstoutunit; - } - - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.FirstOutUnit - * - * @param firstoutunit the value for jsh_material.FirstOutUnit - * - * @mbggenerated - */ - public void setFirstoutunit(String firstoutunit) { - this.firstoutunit = firstoutunit == null ? null : firstoutunit.trim(); - } - - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.FirstInUnit - * - * @return the value of jsh_material.FirstInUnit - * - * @mbggenerated - */ - public String getFirstinunit() { - return firstinunit; - } - - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.FirstInUnit - * - * @param firstinunit the value for jsh_material.FirstInUnit - * - * @mbggenerated - */ - public void setFirstinunit(String firstinunit) { - this.firstinunit = firstinunit == null ? null : firstinunit.trim(); - } - - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.PriceStrategy - * - * @return the value of jsh_material.PriceStrategy - * - * @mbggenerated - */ - public String getPricestrategy() { - return pricestrategy; - } - - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.PriceStrategy - * - * @param pricestrategy the value for jsh_material.PriceStrategy - * - * @mbggenerated - */ - public void setPricestrategy(String pricestrategy) { - this.pricestrategy = pricestrategy == null ? null : pricestrategy.trim(); - } - - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.Enabled - * - * @return the value of jsh_material.Enabled - * - * @mbggenerated - */ public Boolean getEnabled() { return enabled; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.Enabled - * - * @param enabled the value for jsh_material.Enabled - * - * @mbggenerated - */ public void setEnabled(Boolean enabled) { this.enabled = enabled; } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.OtherField1 - * - * @return the value of jsh_material.OtherField1 - * - * @mbggenerated - */ public String getOtherfield1() { return otherfield1; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.OtherField1 - * - * @param otherfield1 the value for jsh_material.OtherField1 - * - * @mbggenerated - */ public void setOtherfield1(String otherfield1) { this.otherfield1 = otherfield1 == null ? null : otherfield1.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.OtherField2 - * - * @return the value of jsh_material.OtherField2 - * - * @mbggenerated - */ public String getOtherfield2() { return otherfield2; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.OtherField2 - * - * @param otherfield2 the value for jsh_material.OtherField2 - * - * @mbggenerated - */ public void setOtherfield2(String otherfield2) { this.otherfield2 = otherfield2 == null ? null : otherfield2.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.OtherField3 - * - * @return the value of jsh_material.OtherField3 - * - * @mbggenerated - */ public String getOtherfield3() { return otherfield3; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.OtherField3 - * - * @param otherfield3 the value for jsh_material.OtherField3 - * - * @mbggenerated - */ public void setOtherfield3(String otherfield3) { this.otherfield3 = otherfield3 == null ? null : otherfield3.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.enableSerialNumber - * - * @return the value of jsh_material.enableSerialNumber - * - * @mbggenerated - */ public String getEnableserialnumber() { return enableserialnumber; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.enableSerialNumber - * - * @param enableserialnumber the value for jsh_material.enableSerialNumber - * - * @mbggenerated - */ public void setEnableserialnumber(String enableserialnumber) { this.enableserialnumber = enableserialnumber == null ? null : enableserialnumber.trim(); } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.tenant_id - * - * @return the value of jsh_material.tenant_id - * - * @mbggenerated - */ public Long getTenantId() { return tenantId; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.tenant_id - * - * @param tenantId the value for jsh_material.tenant_id - * - * @mbggenerated - */ public void setTenantId(Long tenantId) { this.tenantId = tenantId; } - /** - * This method was generated by MyBatis Generator. - * This method returns the value of the database column jsh_material.delete_Flag - * - * @return the value of jsh_material.delete_Flag - * - * @mbggenerated - */ public String getDeleteFlag() { return deleteFlag; } - /** - * This method was generated by MyBatis Generator. - * This method sets the value of the database column jsh_material.delete_Flag - * - * @param deleteFlag the value for jsh_material.delete_Flag - * - * @mbggenerated - */ public void setDeleteFlag(String deleteFlag) { this.deleteFlag = deleteFlag == null ? null : deleteFlag.trim(); } diff --git a/src/main/java/com/jsh/erp/datasource/entities/MaterialExample.java b/src/main/java/com/jsh/erp/datasource/entities/MaterialExample.java index 777a49ba..5e4e1278 100644 --- a/src/main/java/com/jsh/erp/datasource/entities/MaterialExample.java +++ b/src/main/java/com/jsh/erp/datasource/entities/MaterialExample.java @@ -5,118 +5,46 @@ import java.util.ArrayList; import java.util.List; public class MaterialExample { - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database table jsh_material - * - * @mbggenerated - */ protected String orderByClause; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database table jsh_material - * - * @mbggenerated - */ protected boolean distinct; - /** - * This field was generated by MyBatis Generator. - * This field corresponds to the database table jsh_material - * - * @mbggenerated - */ protected List oredCriteria; - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public MaterialExample() { - oredCriteria = new ArrayList(); + oredCriteria = new ArrayList<>(); } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public void setOrderByClause(String orderByClause) { this.orderByClause = orderByClause; } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public String getOrderByClause() { return orderByClause; } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public void setDistinct(boolean distinct) { this.distinct = distinct; } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public boolean isDistinct() { return distinct; } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public List getOredCriteria() { return oredCriteria; } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public void or(Criteria criteria) { oredCriteria.add(criteria); } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public Criteria or() { Criteria criteria = createCriteriaInternal(); oredCriteria.add(criteria); return criteria; } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public Criteria createCriteria() { Criteria criteria = createCriteriaInternal(); if (oredCriteria.size() == 0) { @@ -125,41 +53,23 @@ public class MaterialExample { return criteria; } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ protected Criteria createCriteriaInternal() { Criteria criteria = new Criteria(); return criteria; } - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ public void clear() { oredCriteria.clear(); orderByClause = null; distinct = false; } - /** - * This class was generated by MyBatis Generator. - * This class corresponds to the database table jsh_material - * - * @mbggenerated - */ protected abstract static class GeneratedCriteria { protected List criteria; protected GeneratedCriteria() { super(); - criteria = new ArrayList(); + criteria = new ArrayList<>(); } public boolean isValid() { @@ -455,66 +365,6 @@ public class MaterialExample { return (Criteria) this; } - public Criteria andPackingIsNull() { - addCriterion("Packing is null"); - return (Criteria) this; - } - - public Criteria andPackingIsNotNull() { - addCriterion("Packing is not null"); - return (Criteria) this; - } - - public Criteria andPackingEqualTo(BigDecimal value) { - addCriterion("Packing =", value, "packing"); - return (Criteria) this; - } - - public Criteria andPackingNotEqualTo(BigDecimal value) { - addCriterion("Packing <>", value, "packing"); - return (Criteria) this; - } - - public Criteria andPackingGreaterThan(BigDecimal value) { - addCriterion("Packing >", value, "packing"); - return (Criteria) this; - } - - public Criteria andPackingGreaterThanOrEqualTo(BigDecimal value) { - addCriterion("Packing >=", value, "packing"); - return (Criteria) this; - } - - public Criteria andPackingLessThan(BigDecimal value) { - addCriterion("Packing <", value, "packing"); - return (Criteria) this; - } - - public Criteria andPackingLessThanOrEqualTo(BigDecimal value) { - addCriterion("Packing <=", value, "packing"); - return (Criteria) this; - } - - public Criteria andPackingIn(List values) { - addCriterion("Packing in", values, "packing"); - return (Criteria) this; - } - - public Criteria andPackingNotIn(List values) { - addCriterion("Packing not in", values, "packing"); - return (Criteria) this; - } - - public Criteria andPackingBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("Packing between", value1, value2, "packing"); - return (Criteria) this; - } - - public Criteria andPackingNotBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("Packing not between", value1, value2, "packing"); - return (Criteria) this; - } - public Criteria andSafetystockIsNull() { addCriterion("SafetyStock is null"); return (Criteria) this; @@ -925,246 +775,6 @@ public class MaterialExample { return (Criteria) this; } - public Criteria andRetailpriceIsNull() { - addCriterion("RetailPrice is null"); - return (Criteria) this; - } - - public Criteria andRetailpriceIsNotNull() { - addCriterion("RetailPrice is not null"); - return (Criteria) this; - } - - public Criteria andRetailpriceEqualTo(BigDecimal value) { - addCriterion("RetailPrice =", value, "retailprice"); - return (Criteria) this; - } - - public Criteria andRetailpriceNotEqualTo(BigDecimal value) { - addCriterion("RetailPrice <>", value, "retailprice"); - return (Criteria) this; - } - - public Criteria andRetailpriceGreaterThan(BigDecimal value) { - addCriterion("RetailPrice >", value, "retailprice"); - return (Criteria) this; - } - - public Criteria andRetailpriceGreaterThanOrEqualTo(BigDecimal value) { - addCriterion("RetailPrice >=", value, "retailprice"); - return (Criteria) this; - } - - public Criteria andRetailpriceLessThan(BigDecimal value) { - addCriterion("RetailPrice <", value, "retailprice"); - return (Criteria) this; - } - - public Criteria andRetailpriceLessThanOrEqualTo(BigDecimal value) { - addCriterion("RetailPrice <=", value, "retailprice"); - return (Criteria) this; - } - - public Criteria andRetailpriceIn(List values) { - addCriterion("RetailPrice in", values, "retailprice"); - return (Criteria) this; - } - - public Criteria andRetailpriceNotIn(List values) { - addCriterion("RetailPrice not in", values, "retailprice"); - return (Criteria) this; - } - - public Criteria andRetailpriceBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("RetailPrice between", value1, value2, "retailprice"); - return (Criteria) this; - } - - public Criteria andRetailpriceNotBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("RetailPrice not between", value1, value2, "retailprice"); - return (Criteria) this; - } - - public Criteria andLowpriceIsNull() { - addCriterion("LowPrice is null"); - return (Criteria) this; - } - - public Criteria andLowpriceIsNotNull() { - addCriterion("LowPrice is not null"); - return (Criteria) this; - } - - public Criteria andLowpriceEqualTo(BigDecimal value) { - addCriterion("LowPrice =", value, "lowprice"); - return (Criteria) this; - } - - public Criteria andLowpriceNotEqualTo(BigDecimal value) { - addCriterion("LowPrice <>", value, "lowprice"); - return (Criteria) this; - } - - public Criteria andLowpriceGreaterThan(BigDecimal value) { - addCriterion("LowPrice >", value, "lowprice"); - return (Criteria) this; - } - - public Criteria andLowpriceGreaterThanOrEqualTo(BigDecimal value) { - addCriterion("LowPrice >=", value, "lowprice"); - return (Criteria) this; - } - - public Criteria andLowpriceLessThan(BigDecimal value) { - addCriterion("LowPrice <", value, "lowprice"); - return (Criteria) this; - } - - public Criteria andLowpriceLessThanOrEqualTo(BigDecimal value) { - addCriterion("LowPrice <=", value, "lowprice"); - return (Criteria) this; - } - - public Criteria andLowpriceIn(List values) { - addCriterion("LowPrice in", values, "lowprice"); - return (Criteria) this; - } - - public Criteria andLowpriceNotIn(List values) { - addCriterion("LowPrice not in", values, "lowprice"); - return (Criteria) this; - } - - public Criteria andLowpriceBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("LowPrice between", value1, value2, "lowprice"); - return (Criteria) this; - } - - public Criteria andLowpriceNotBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("LowPrice not between", value1, value2, "lowprice"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneIsNull() { - addCriterion("PresetPriceOne is null"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneIsNotNull() { - addCriterion("PresetPriceOne is not null"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneEqualTo(BigDecimal value) { - addCriterion("PresetPriceOne =", value, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneNotEqualTo(BigDecimal value) { - addCriterion("PresetPriceOne <>", value, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneGreaterThan(BigDecimal value) { - addCriterion("PresetPriceOne >", value, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneGreaterThanOrEqualTo(BigDecimal value) { - addCriterion("PresetPriceOne >=", value, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneLessThan(BigDecimal value) { - addCriterion("PresetPriceOne <", value, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneLessThanOrEqualTo(BigDecimal value) { - addCriterion("PresetPriceOne <=", value, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneIn(List values) { - addCriterion("PresetPriceOne in", values, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneNotIn(List values) { - addCriterion("PresetPriceOne not in", values, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("PresetPriceOne between", value1, value2, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpriceoneNotBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("PresetPriceOne not between", value1, value2, "presetpriceone"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoIsNull() { - addCriterion("PresetPriceTwo is null"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoIsNotNull() { - addCriterion("PresetPriceTwo is not null"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoEqualTo(BigDecimal value) { - addCriterion("PresetPriceTwo =", value, "presetpricetwo"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoNotEqualTo(BigDecimal value) { - addCriterion("PresetPriceTwo <>", value, "presetpricetwo"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoGreaterThan(BigDecimal value) { - addCriterion("PresetPriceTwo >", value, "presetpricetwo"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoGreaterThanOrEqualTo(BigDecimal value) { - addCriterion("PresetPriceTwo >=", value, "presetpricetwo"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoLessThan(BigDecimal value) { - addCriterion("PresetPriceTwo <", value, "presetpricetwo"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoLessThanOrEqualTo(BigDecimal value) { - addCriterion("PresetPriceTwo <=", value, "presetpricetwo"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoIn(List values) { - addCriterion("PresetPriceTwo in", values, "presetpricetwo"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoNotIn(List values) { - addCriterion("PresetPriceTwo not in", values, "presetpricetwo"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("PresetPriceTwo between", value1, value2, "presetpricetwo"); - return (Criteria) this; - } - - public Criteria andPresetpricetwoNotBetween(BigDecimal value1, BigDecimal value2) { - addCriterion("PresetPriceTwo not between", value1, value2, "presetpricetwo"); - return (Criteria) this; - } - public Criteria andUnitidIsNull() { addCriterion("UnitId is null"); return (Criteria) this; @@ -1225,216 +835,6 @@ public class MaterialExample { return (Criteria) this; } - public Criteria andFirstoutunitIsNull() { - addCriterion("FirstOutUnit is null"); - return (Criteria) this; - } - - public Criteria andFirstoutunitIsNotNull() { - addCriterion("FirstOutUnit is not null"); - return (Criteria) this; - } - - public Criteria andFirstoutunitEqualTo(String value) { - addCriterion("FirstOutUnit =", value, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitNotEqualTo(String value) { - addCriterion("FirstOutUnit <>", value, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitGreaterThan(String value) { - addCriterion("FirstOutUnit >", value, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitGreaterThanOrEqualTo(String value) { - addCriterion("FirstOutUnit >=", value, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitLessThan(String value) { - addCriterion("FirstOutUnit <", value, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitLessThanOrEqualTo(String value) { - addCriterion("FirstOutUnit <=", value, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitLike(String value) { - addCriterion("FirstOutUnit like", value, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitNotLike(String value) { - addCriterion("FirstOutUnit not like", value, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitIn(List values) { - addCriterion("FirstOutUnit in", values, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitNotIn(List values) { - addCriterion("FirstOutUnit not in", values, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitBetween(String value1, String value2) { - addCriterion("FirstOutUnit between", value1, value2, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstoutunitNotBetween(String value1, String value2) { - addCriterion("FirstOutUnit not between", value1, value2, "firstoutunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitIsNull() { - addCriterion("FirstInUnit is null"); - return (Criteria) this; - } - - public Criteria andFirstinunitIsNotNull() { - addCriterion("FirstInUnit is not null"); - return (Criteria) this; - } - - public Criteria andFirstinunitEqualTo(String value) { - addCriterion("FirstInUnit =", value, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitNotEqualTo(String value) { - addCriterion("FirstInUnit <>", value, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitGreaterThan(String value) { - addCriterion("FirstInUnit >", value, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitGreaterThanOrEqualTo(String value) { - addCriterion("FirstInUnit >=", value, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitLessThan(String value) { - addCriterion("FirstInUnit <", value, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitLessThanOrEqualTo(String value) { - addCriterion("FirstInUnit <=", value, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitLike(String value) { - addCriterion("FirstInUnit like", value, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitNotLike(String value) { - addCriterion("FirstInUnit not like", value, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitIn(List values) { - addCriterion("FirstInUnit in", values, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitNotIn(List values) { - addCriterion("FirstInUnit not in", values, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitBetween(String value1, String value2) { - addCriterion("FirstInUnit between", value1, value2, "firstinunit"); - return (Criteria) this; - } - - public Criteria andFirstinunitNotBetween(String value1, String value2) { - addCriterion("FirstInUnit not between", value1, value2, "firstinunit"); - return (Criteria) this; - } - - public Criteria andPricestrategyIsNull() { - addCriterion("PriceStrategy is null"); - return (Criteria) this; - } - - public Criteria andPricestrategyIsNotNull() { - addCriterion("PriceStrategy is not null"); - return (Criteria) this; - } - - public Criteria andPricestrategyEqualTo(String value) { - addCriterion("PriceStrategy =", value, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyNotEqualTo(String value) { - addCriterion("PriceStrategy <>", value, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyGreaterThan(String value) { - addCriterion("PriceStrategy >", value, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyGreaterThanOrEqualTo(String value) { - addCriterion("PriceStrategy >=", value, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyLessThan(String value) { - addCriterion("PriceStrategy <", value, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyLessThanOrEqualTo(String value) { - addCriterion("PriceStrategy <=", value, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyLike(String value) { - addCriterion("PriceStrategy like", value, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyNotLike(String value) { - addCriterion("PriceStrategy not like", value, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyIn(List values) { - addCriterion("PriceStrategy in", values, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyNotIn(List values) { - addCriterion("PriceStrategy not in", values, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyBetween(String value1, String value2) { - addCriterion("PriceStrategy between", value1, value2, "pricestrategy"); - return (Criteria) this; - } - - public Criteria andPricestrategyNotBetween(String value1, String value2) { - addCriterion("PriceStrategy not between", value1, value2, "pricestrategy"); - return (Criteria) this; - } - public Criteria andEnabledIsNull() { addCriterion("Enabled is null"); return (Criteria) this; @@ -1906,25 +1306,12 @@ public class MaterialExample { } } - /** - * This class was generated by MyBatis Generator. - * This class corresponds to the database table jsh_material - * - * @mbggenerated do_not_delete_during_merge - */ public static class Criteria extends GeneratedCriteria { - protected Criteria() { super(); } } - /** - * This class was generated by MyBatis Generator. - * This class corresponds to the database table jsh_material - * - * @mbggenerated - */ public static class Criterion { private String condition; diff --git a/src/main/java/com/jsh/erp/datasource/mappers/MaterialMapper.java b/src/main/java/com/jsh/erp/datasource/mappers/MaterialMapper.java index f7848bbe..cb61c590 100644 --- a/src/main/java/com/jsh/erp/datasource/mappers/MaterialMapper.java +++ b/src/main/java/com/jsh/erp/datasource/mappers/MaterialMapper.java @@ -6,91 +6,25 @@ import java.util.List; import org.apache.ibatis.annotations.Param; public interface MaterialMapper { - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ - int countByExample(MaterialExample example); + long countByExample(MaterialExample example); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ int deleteByExample(MaterialExample example); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ int deleteByPrimaryKey(Long id); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ int insert(Material record); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ int insertSelective(Material record); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ List selectByExample(MaterialExample example); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ Material selectByPrimaryKey(Long id); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ int updateByExampleSelective(@Param("record") Material record, @Param("example") MaterialExample example); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ int updateByExample(@Param("record") Material record, @Param("example") MaterialExample example); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ int updateByPrimaryKeySelective(Material record); - /** - * This method was generated by MyBatis Generator. - * This method corresponds to the database table jsh_material - * - * @mbggenerated - */ int updateByPrimaryKey(Material record); } \ No newline at end of file diff --git a/src/main/java/com/jsh/erp/datasource/mappers/MaterialMapperEx.java b/src/main/java/com/jsh/erp/datasource/mappers/MaterialMapperEx.java index 80bbef9f..46bfc8a9 100644 --- a/src/main/java/com/jsh/erp/datasource/mappers/MaterialMapperEx.java +++ b/src/main/java/com/jsh/erp/datasource/mappers/MaterialMapperEx.java @@ -47,10 +47,6 @@ public interface MaterialMapperEx { int findBySelectWithBarCodeCount(@Param("q") String q); - int updatePriceNullByPrimaryKey(Long id); - - int updateUnitIdNullByPrimaryKey(Long id); - List findByAll( @Param("name") String name, @Param("model") String model, diff --git a/src/main/java/com/jsh/erp/service/material/MaterialService.java b/src/main/java/com/jsh/erp/service/material/MaterialService.java index 63a20c3e..0fe50d33 100644 --- a/src/main/java/com/jsh/erp/service/material/MaterialService.java +++ b/src/main/java/com/jsh/erp/service/material/MaterialService.java @@ -186,12 +186,6 @@ public class MaterialService { material.setId(id); try{ materialMapper.updateByPrimaryKeySelective(material); - Long unitId = material.getUnitid(); - if(unitId != null) { - materialMapperEx.updatePriceNullByPrimaryKey(id); //将价格置空 - } else { - materialMapperEx.updateUnitIdNullByPrimaryKey(id); //将多单位置空 - } JSONObject mObj = JSON.parseObject(beanJson); materialExtendService.saveDetials(mObj.getString("inserted"),mObj.getString("deleted"),mObj.getString("updated"),mObj.getString("sortList"),id); if(mObj.get("stock")!=null) { @@ -435,8 +429,8 @@ public class MaterialService { String manyUnitAll = unit + "," + manyUnit + "(1:" + ratio + ")"; Long unitId = unitService.getUnitIdByName(manyUnitAll); m.setUnitid(unitId); - m.setFirstoutunit(unit); //首选出库单位 - m.setFirstinunit(manyUnit); //首选入库单位 + //m.setFirstoutunit(unit); //首选出库单位 + //m.setFirstinunit(manyUnit); //首选入库单位 JSONArray arr = new JSONArray(); JSONObject basicObj = new JSONObject(); basicObj.put("Unit", unit); @@ -456,13 +450,13 @@ public class MaterialService { otherObjEx.put("other", otherObj); arr.add(basicObjEx); arr.add(otherObjEx); - m.setPricestrategy(arr.toJSONString()); + //m.setPricestrategy(arr.toJSONString()); } else { m.setUnit(unit); - m.setRetailprice(parseBigDecimalEx(retailPrice)); - m.setLowprice(parseBigDecimalEx(lowPrice)); - m.setPresetpriceone(parseBigDecimalEx(presetpriceone)); - m.setPresetpricetwo(parseBigDecimalEx(presetpricetwo)); + //m.setRetailprice(parseBigDecimalEx(retailPrice)); + //m.setLowprice(parseBigDecimalEx(lowPrice)); + //m.setPresetpriceone(parseBigDecimalEx(presetpriceone)); + //m.setPresetpricetwo(parseBigDecimalEx(presetpricetwo)); } String enabled = ExcelUtils.getContent(src, i, 12); //状态 m.setEnabled(enabled.equals("1")? true: false); diff --git a/src/main/resources/mapper_xml/DepotItemMapperEx.xml b/src/main/resources/mapper_xml/DepotItemMapperEx.xml index b1e6f063..14d95fca 100644 --- a/src/main/resources/mapper_xml/DepotItemMapperEx.xml +++ b/src/main/resources/mapper_xml/DepotItemMapperEx.xml @@ -38,8 +38,7 @@ - - + @@ -149,11 +148,13 @@ - - select - - distinct - - - from jsh_material - - - - - order by ${orderByClause} - - - - - - delete from jsh_material - where Id = #{id,jdbcType=BIGINT} - - - - delete from jsh_material - - - - - - - insert into jsh_material (Id, CategoryId, Name, - Mfrs, Packing, SafetyStock, - Model, Standard, Color, - Unit, Remark, RetailPrice, - LowPrice, PresetPriceOne, PresetPriceTwo, - UnitId, FirstOutUnit, FirstInUnit, - PriceStrategy, Enabled, OtherField1, - OtherField2, OtherField3, enableSerialNumber, - tenant_id, delete_Flag) - values (#{id,jdbcType=BIGINT}, #{categoryid,jdbcType=BIGINT}, #{name,jdbcType=VARCHAR}, - #{mfrs,jdbcType=VARCHAR}, #{packing,jdbcType=DECIMAL}, #{safetystock,jdbcType=DECIMAL}, - #{model,jdbcType=VARCHAR}, #{standard,jdbcType=VARCHAR}, #{color,jdbcType=VARCHAR}, - #{unit,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{retailprice,jdbcType=DECIMAL}, - #{lowprice,jdbcType=DECIMAL}, #{presetpriceone,jdbcType=DECIMAL}, #{presetpricetwo,jdbcType=DECIMAL}, - #{unitid,jdbcType=BIGINT}, #{firstoutunit,jdbcType=VARCHAR}, #{firstinunit,jdbcType=VARCHAR}, - #{pricestrategy,jdbcType=VARCHAR}, #{enabled,jdbcType=BIT}, #{otherfield1,jdbcType=VARCHAR}, - #{otherfield2,jdbcType=VARCHAR}, #{otherfield3,jdbcType=VARCHAR}, #{enableserialnumber,jdbcType=VARCHAR}, - #{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR}) - - - - insert into jsh_material - - - Id, - - - CategoryId, - - - Name, - - - Mfrs, - - - Packing, - - - SafetyStock, - - - Model, - - - Standard, - - - Color, - - - Unit, - - - Remark, - - - RetailPrice, - - - LowPrice, - - - PresetPriceOne, - - - PresetPriceTwo, - - - UnitId, - - - FirstOutUnit, - - - FirstInUnit, - - - PriceStrategy, - - - Enabled, - - - OtherField1, - - - OtherField2, - - - OtherField3, - - - enableSerialNumber, - - - tenant_id, - - - delete_Flag, - - - - - #{id,jdbcType=BIGINT}, - - - #{categoryid,jdbcType=BIGINT}, - - - #{name,jdbcType=VARCHAR}, - - - #{mfrs,jdbcType=VARCHAR}, - - - #{packing,jdbcType=DECIMAL}, - - - #{safetystock,jdbcType=DECIMAL}, - - - #{model,jdbcType=VARCHAR}, - - - #{standard,jdbcType=VARCHAR}, - - - #{color,jdbcType=VARCHAR}, - - - #{unit,jdbcType=VARCHAR}, - - - #{remark,jdbcType=VARCHAR}, - - - #{retailprice,jdbcType=DECIMAL}, - - - #{lowprice,jdbcType=DECIMAL}, - - - #{presetpriceone,jdbcType=DECIMAL}, - - - #{presetpricetwo,jdbcType=DECIMAL}, - - - #{unitid,jdbcType=BIGINT}, - - - #{firstoutunit,jdbcType=VARCHAR}, - - - #{firstinunit,jdbcType=VARCHAR}, - - - #{pricestrategy,jdbcType=VARCHAR}, - - - #{enabled,jdbcType=BIT}, - - - #{otherfield1,jdbcType=VARCHAR}, - - - #{otherfield2,jdbcType=VARCHAR}, - - - #{otherfield3,jdbcType=VARCHAR}, - - - #{enableserialnumber,jdbcType=VARCHAR}, - - - #{tenantId,jdbcType=BIGINT}, - - - #{deleteFlag,jdbcType=VARCHAR}, - - - - - - - update jsh_material - - - Id = #{record.id,jdbcType=BIGINT}, - - - CategoryId = #{record.categoryid,jdbcType=BIGINT}, - - - Name = #{record.name,jdbcType=VARCHAR}, - - - Mfrs = #{record.mfrs,jdbcType=VARCHAR}, - - - Packing = #{record.packing,jdbcType=DECIMAL}, - - - SafetyStock = #{record.safetystock,jdbcType=DECIMAL}, - - - Model = #{record.model,jdbcType=VARCHAR}, - - - Standard = #{record.standard,jdbcType=VARCHAR}, - - - Color = #{record.color,jdbcType=VARCHAR}, - - - Unit = #{record.unit,jdbcType=VARCHAR}, - - - Remark = #{record.remark,jdbcType=VARCHAR}, - - - RetailPrice = #{record.retailprice,jdbcType=DECIMAL}, - - - LowPrice = #{record.lowprice,jdbcType=DECIMAL}, - - - PresetPriceOne = #{record.presetpriceone,jdbcType=DECIMAL}, - - - PresetPriceTwo = #{record.presetpricetwo,jdbcType=DECIMAL}, - - - UnitId = #{record.unitid,jdbcType=BIGINT}, - - - FirstOutUnit = #{record.firstoutunit,jdbcType=VARCHAR}, - - - FirstInUnit = #{record.firstinunit,jdbcType=VARCHAR}, - - - PriceStrategy = #{record.pricestrategy,jdbcType=VARCHAR}, - - - Enabled = #{record.enabled,jdbcType=BIT}, - - - OtherField1 = #{record.otherfield1,jdbcType=VARCHAR}, - - - OtherField2 = #{record.otherfield2,jdbcType=VARCHAR}, - - - OtherField3 = #{record.otherfield3,jdbcType=VARCHAR}, - - - enableSerialNumber = #{record.enableserialnumber,jdbcType=VARCHAR}, - - - tenant_id = #{record.tenantId,jdbcType=BIGINT}, - - - delete_Flag = #{record.deleteFlag,jdbcType=VARCHAR}, - - - - - - - - - update jsh_material - set Id = #{record.id,jdbcType=BIGINT}, - CategoryId = #{record.categoryid,jdbcType=BIGINT}, - Name = #{record.name,jdbcType=VARCHAR}, - Mfrs = #{record.mfrs,jdbcType=VARCHAR}, - Packing = #{record.packing,jdbcType=DECIMAL}, - SafetyStock = #{record.safetystock,jdbcType=DECIMAL}, - Model = #{record.model,jdbcType=VARCHAR}, - Standard = #{record.standard,jdbcType=VARCHAR}, - Color = #{record.color,jdbcType=VARCHAR}, - Unit = #{record.unit,jdbcType=VARCHAR}, - Remark = #{record.remark,jdbcType=VARCHAR}, - RetailPrice = #{record.retailprice,jdbcType=DECIMAL}, - LowPrice = #{record.lowprice,jdbcType=DECIMAL}, - PresetPriceOne = #{record.presetpriceone,jdbcType=DECIMAL}, - PresetPriceTwo = #{record.presetpricetwo,jdbcType=DECIMAL}, - UnitId = #{record.unitid,jdbcType=BIGINT}, - FirstOutUnit = #{record.firstoutunit,jdbcType=VARCHAR}, - FirstInUnit = #{record.firstinunit,jdbcType=VARCHAR}, - PriceStrategy = #{record.pricestrategy,jdbcType=VARCHAR}, - Enabled = #{record.enabled,jdbcType=BIT}, - OtherField1 = #{record.otherfield1,jdbcType=VARCHAR}, - OtherField2 = #{record.otherfield2,jdbcType=VARCHAR}, - OtherField3 = #{record.otherfield3,jdbcType=VARCHAR}, - enableSerialNumber = #{record.enableserialnumber,jdbcType=VARCHAR}, - tenant_id = #{record.tenantId,jdbcType=BIGINT}, - delete_Flag = #{record.deleteFlag,jdbcType=VARCHAR} - - - - - - - update jsh_material - - - CategoryId = #{categoryid,jdbcType=BIGINT}, - - - Name = #{name,jdbcType=VARCHAR}, - - - Mfrs = #{mfrs,jdbcType=VARCHAR}, - - - Packing = #{packing,jdbcType=DECIMAL}, - - - SafetyStock = #{safetystock,jdbcType=DECIMAL}, - - - Model = #{model,jdbcType=VARCHAR}, - - - Standard = #{standard,jdbcType=VARCHAR}, - - - Color = #{color,jdbcType=VARCHAR}, - - - Unit = #{unit,jdbcType=VARCHAR}, - - - Remark = #{remark,jdbcType=VARCHAR}, - - - RetailPrice = #{retailprice,jdbcType=DECIMAL}, - - - LowPrice = #{lowprice,jdbcType=DECIMAL}, - - - PresetPriceOne = #{presetpriceone,jdbcType=DECIMAL}, - - - PresetPriceTwo = #{presetpricetwo,jdbcType=DECIMAL}, - - - UnitId = #{unitid,jdbcType=BIGINT}, - - - FirstOutUnit = #{firstoutunit,jdbcType=VARCHAR}, - - - FirstInUnit = #{firstinunit,jdbcType=VARCHAR}, - - - PriceStrategy = #{pricestrategy,jdbcType=VARCHAR}, - - - Enabled = #{enabled,jdbcType=BIT}, - - - OtherField1 = #{otherfield1,jdbcType=VARCHAR}, - - - OtherField2 = #{otherfield2,jdbcType=VARCHAR}, - - - OtherField3 = #{otherfield3,jdbcType=VARCHAR}, - - - enableSerialNumber = #{enableserialnumber,jdbcType=VARCHAR}, - - - tenant_id = #{tenantId,jdbcType=BIGINT}, - - - delete_Flag = #{deleteFlag,jdbcType=VARCHAR}, - - - where Id = #{id,jdbcType=BIGINT} - - - - update jsh_material - set CategoryId = #{categoryid,jdbcType=BIGINT}, - Name = #{name,jdbcType=VARCHAR}, - Mfrs = #{mfrs,jdbcType=VARCHAR}, - Packing = #{packing,jdbcType=DECIMAL}, - SafetyStock = #{safetystock,jdbcType=DECIMAL}, - Model = #{model,jdbcType=VARCHAR}, - Standard = #{standard,jdbcType=VARCHAR}, - Color = #{color,jdbcType=VARCHAR}, - Unit = #{unit,jdbcType=VARCHAR}, - Remark = #{remark,jdbcType=VARCHAR}, - RetailPrice = #{retailprice,jdbcType=DECIMAL}, - LowPrice = #{lowprice,jdbcType=DECIMAL}, - PresetPriceOne = #{presetpriceone,jdbcType=DECIMAL}, - PresetPriceTwo = #{presetpricetwo,jdbcType=DECIMAL}, - UnitId = #{unitid,jdbcType=BIGINT}, - FirstOutUnit = #{firstoutunit,jdbcType=VARCHAR}, - FirstInUnit = #{firstinunit,jdbcType=VARCHAR}, - PriceStrategy = #{pricestrategy,jdbcType=VARCHAR}, - Enabled = #{enabled,jdbcType=BIT}, - OtherField1 = #{otherfield1,jdbcType=VARCHAR}, - OtherField2 = #{otherfield2,jdbcType=VARCHAR}, - OtherField3 = #{otherfield3,jdbcType=VARCHAR}, - enableSerialNumber = #{enableserialnumber,jdbcType=VARCHAR}, - tenant_id = #{tenantId,jdbcType=BIGINT}, - delete_Flag = #{deleteFlag,jdbcType=VARCHAR} - where Id = #{id,jdbcType=BIGINT} - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + and ${criterion.condition} + + + and ${criterion.condition} #{criterion.value} + + + and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} + + + and ${criterion.condition} + + #{listItem} + + + + + + + + + + + + + + + + + + and ${criterion.condition} + + + and ${criterion.condition} #{criterion.value} + + + and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} + + + and ${criterion.condition} + + #{listItem} + + + + + + + + + + + Id, CategoryId, Name, Mfrs, SafetyStock, Model, Standard, Color, Unit, Remark, UnitId, + Enabled, OtherField1, OtherField2, OtherField3, enableSerialNumber, tenant_id, delete_Flag + + + + + delete from jsh_material + where Id = #{id,jdbcType=BIGINT} + + + delete from jsh_material + + + + + + insert into jsh_material (Id, CategoryId, Name, + Mfrs, SafetyStock, Model, + Standard, Color, Unit, + Remark, UnitId, Enabled, + OtherField1, OtherField2, OtherField3, + enableSerialNumber, tenant_id, delete_Flag + ) + values (#{id,jdbcType=BIGINT}, #{categoryid,jdbcType=BIGINT}, #{name,jdbcType=VARCHAR}, + #{mfrs,jdbcType=VARCHAR}, #{safetystock,jdbcType=DECIMAL}, #{model,jdbcType=VARCHAR}, + #{standard,jdbcType=VARCHAR}, #{color,jdbcType=VARCHAR}, #{unit,jdbcType=VARCHAR}, + #{remark,jdbcType=VARCHAR}, #{unitid,jdbcType=BIGINT}, #{enabled,jdbcType=BIT}, + #{otherfield1,jdbcType=VARCHAR}, #{otherfield2,jdbcType=VARCHAR}, #{otherfield3,jdbcType=VARCHAR}, + #{enableserialnumber,jdbcType=VARCHAR}, #{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR} + ) + + + insert into jsh_material + + + Id, + + + CategoryId, + + + Name, + + + Mfrs, + + + SafetyStock, + + + Model, + + + Standard, + + + Color, + + + Unit, + + + Remark, + + + UnitId, + + + Enabled, + + + OtherField1, + + + OtherField2, + + + OtherField3, + + + enableSerialNumber, + + + tenant_id, + + + delete_Flag, + + + + + #{id,jdbcType=BIGINT}, + + + #{categoryid,jdbcType=BIGINT}, + + + #{name,jdbcType=VARCHAR}, + + + #{mfrs,jdbcType=VARCHAR}, + + + #{safetystock,jdbcType=DECIMAL}, + + + #{model,jdbcType=VARCHAR}, + + + #{standard,jdbcType=VARCHAR}, + + + #{color,jdbcType=VARCHAR}, + + + #{unit,jdbcType=VARCHAR}, + + + #{remark,jdbcType=VARCHAR}, + + + #{unitid,jdbcType=BIGINT}, + + + #{enabled,jdbcType=BIT}, + + + #{otherfield1,jdbcType=VARCHAR}, + + + #{otherfield2,jdbcType=VARCHAR}, + + + #{otherfield3,jdbcType=VARCHAR}, + + + #{enableserialnumber,jdbcType=VARCHAR}, + + + #{tenantId,jdbcType=BIGINT}, + + + #{deleteFlag,jdbcType=VARCHAR}, + + + + + + update jsh_material + + + Id = #{record.id,jdbcType=BIGINT}, + + + CategoryId = #{record.categoryid,jdbcType=BIGINT}, + + + Name = #{record.name,jdbcType=VARCHAR}, + + + Mfrs = #{record.mfrs,jdbcType=VARCHAR}, + + + SafetyStock = #{record.safetystock,jdbcType=DECIMAL}, + + + Model = #{record.model,jdbcType=VARCHAR}, + + + Standard = #{record.standard,jdbcType=VARCHAR}, + + + Color = #{record.color,jdbcType=VARCHAR}, + + + Unit = #{record.unit,jdbcType=VARCHAR}, + + + Remark = #{record.remark,jdbcType=VARCHAR}, + + + UnitId = #{record.unitid,jdbcType=BIGINT}, + + + Enabled = #{record.enabled,jdbcType=BIT}, + + + OtherField1 = #{record.otherfield1,jdbcType=VARCHAR}, + + + OtherField2 = #{record.otherfield2,jdbcType=VARCHAR}, + + + OtherField3 = #{record.otherfield3,jdbcType=VARCHAR}, + + + enableSerialNumber = #{record.enableserialnumber,jdbcType=VARCHAR}, + + + tenant_id = #{record.tenantId,jdbcType=BIGINT}, + + + delete_Flag = #{record.deleteFlag,jdbcType=VARCHAR}, + + + + + + + + update jsh_material + set Id = #{record.id,jdbcType=BIGINT}, + CategoryId = #{record.categoryid,jdbcType=BIGINT}, + Name = #{record.name,jdbcType=VARCHAR}, + Mfrs = #{record.mfrs,jdbcType=VARCHAR}, + SafetyStock = #{record.safetystock,jdbcType=DECIMAL}, + Model = #{record.model,jdbcType=VARCHAR}, + Standard = #{record.standard,jdbcType=VARCHAR}, + Color = #{record.color,jdbcType=VARCHAR}, + Unit = #{record.unit,jdbcType=VARCHAR}, + Remark = #{record.remark,jdbcType=VARCHAR}, + UnitId = #{record.unitid,jdbcType=BIGINT}, + Enabled = #{record.enabled,jdbcType=BIT}, + OtherField1 = #{record.otherfield1,jdbcType=VARCHAR}, + OtherField2 = #{record.otherfield2,jdbcType=VARCHAR}, + OtherField3 = #{record.otherfield3,jdbcType=VARCHAR}, + enableSerialNumber = #{record.enableserialnumber,jdbcType=VARCHAR}, + tenant_id = #{record.tenantId,jdbcType=BIGINT}, + delete_Flag = #{record.deleteFlag,jdbcType=VARCHAR} + + + + + + update jsh_material + + + CategoryId = #{categoryid,jdbcType=BIGINT}, + + + Name = #{name,jdbcType=VARCHAR}, + + + Mfrs = #{mfrs,jdbcType=VARCHAR}, + + + SafetyStock = #{safetystock,jdbcType=DECIMAL}, + + + Model = #{model,jdbcType=VARCHAR}, + + + Standard = #{standard,jdbcType=VARCHAR}, + + + Color = #{color,jdbcType=VARCHAR}, + + + Unit = #{unit,jdbcType=VARCHAR}, + + + Remark = #{remark,jdbcType=VARCHAR}, + + + UnitId = #{unitid,jdbcType=BIGINT}, + + + Enabled = #{enabled,jdbcType=BIT}, + + + OtherField1 = #{otherfield1,jdbcType=VARCHAR}, + + + OtherField2 = #{otherfield2,jdbcType=VARCHAR}, + + + OtherField3 = #{otherfield3,jdbcType=VARCHAR}, + + + enableSerialNumber = #{enableserialnumber,jdbcType=VARCHAR}, + + + tenant_id = #{tenantId,jdbcType=BIGINT}, + + + delete_Flag = #{deleteFlag,jdbcType=VARCHAR}, + + + where Id = #{id,jdbcType=BIGINT} + + + update jsh_material + set CategoryId = #{categoryid,jdbcType=BIGINT}, + Name = #{name,jdbcType=VARCHAR}, + Mfrs = #{mfrs,jdbcType=VARCHAR}, + SafetyStock = #{safetystock,jdbcType=DECIMAL}, + Model = #{model,jdbcType=VARCHAR}, + Standard = #{standard,jdbcType=VARCHAR}, + Color = #{color,jdbcType=VARCHAR}, + Unit = #{unit,jdbcType=VARCHAR}, + Remark = #{remark,jdbcType=VARCHAR}, + UnitId = #{unitid,jdbcType=BIGINT}, + Enabled = #{enabled,jdbcType=BIT}, + OtherField1 = #{otherfield1,jdbcType=VARCHAR}, + OtherField2 = #{otherfield2,jdbcType=VARCHAR}, + OtherField3 = #{otherfield3,jdbcType=VARCHAR}, + enableSerialNumber = #{enableserialnumber,jdbcType=VARCHAR}, + tenant_id = #{tenantId,jdbcType=BIGINT}, + delete_Flag = #{deleteFlag,jdbcType=VARCHAR} + where Id = #{id,jdbcType=BIGINT} + \ No newline at end of file diff --git a/src/main/resources/mapper_xml/MaterialMapperEx.xml b/src/main/resources/mapper_xml/MaterialMapperEx.xml index 9f0e667d..1022483f 100644 --- a/src/main/resources/mapper_xml/MaterialMapperEx.xml +++ b/src/main/resources/mapper_xml/MaterialMapperEx.xml @@ -116,23 +116,6 @@ and ifnull(m.delete_Flag,'0') !='1' - - update jsh_material - set - RetailPrice = null, - LowPrice = null, - PresetPriceOne = null, - PresetPriceTwo = null - where Id = #{id,jdbcType=BIGINT} - - - - update jsh_material - set - UnitId = null - where Id = #{id,jdbcType=BIGINT} - - select - Id, CategoryId, name, Mfrs, Packing, SafetyStock, Model, Standard, Color, Unit, Remark, - RetailPrice, LowPrice, PresetPriceOne, PresetPriceTwo, UnitId, FirstOutUnit, FirstInUnit, - PriceStrategy, Enabled,enableSerialNumber + Id, CategoryId, name, Mfrs, SafetyStock, Model, Standard, Color, Unit, Remark, + UnitId, Enabled,enableSerialNumber FROM jsh_material where 1=1 and enabled ='1'