给计量单位表增加三个字段
This commit is contained in:
@@ -1,130 +1,72 @@
|
||||
package com.jsh.erp.datasource.entities;
|
||||
|
||||
public class Unit {
|
||||
/**
|
||||
* This field was generated by MyBatis Generator.
|
||||
* This field corresponds to the database column jsh_unit.id
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* This field was generated by MyBatis Generator.
|
||||
* This field corresponds to the database column jsh_unit.UName
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
private String uname;
|
||||
|
||||
/**
|
||||
* This field was generated by MyBatis Generator.
|
||||
* This field corresponds to the database column jsh_unit.tenant_id
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
private String basicUnit;
|
||||
|
||||
private String otherUnit;
|
||||
|
||||
private Integer ratio;
|
||||
|
||||
private Long tenantId;
|
||||
|
||||
/**
|
||||
* This field was generated by MyBatis Generator.
|
||||
* This field corresponds to the database column jsh_unit.delete_Flag
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
private String deleteFlag;
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method returns the value of the database column jsh_unit.id
|
||||
*
|
||||
* @return the value of jsh_unit.id
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method sets the value of the database column jsh_unit.id
|
||||
*
|
||||
* @param id the value for jsh_unit.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_unit.UName
|
||||
*
|
||||
* @return the value of jsh_unit.UName
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public String getUname() {
|
||||
return uname;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method sets the value of the database column jsh_unit.UName
|
||||
*
|
||||
* @param uname the value for jsh_unit.UName
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public void setUname(String uname) {
|
||||
this.uname = uname == null ? null : uname.trim();
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method returns the value of the database column jsh_unit.tenant_id
|
||||
*
|
||||
* @return the value of jsh_unit.tenant_id
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public String getBasicUnit() {
|
||||
return basicUnit;
|
||||
}
|
||||
|
||||
public void setBasicUnit(String basicUnit) {
|
||||
this.basicUnit = basicUnit == null ? null : basicUnit.trim();
|
||||
}
|
||||
|
||||
public String getOtherUnit() {
|
||||
return otherUnit;
|
||||
}
|
||||
|
||||
public void setOtherUnit(String otherUnit) {
|
||||
this.otherUnit = otherUnit == null ? null : otherUnit.trim();
|
||||
}
|
||||
|
||||
public Integer getRatio() {
|
||||
return ratio;
|
||||
}
|
||||
|
||||
public void setRatio(Integer ratio) {
|
||||
this.ratio = ratio;
|
||||
}
|
||||
|
||||
public Long getTenantId() {
|
||||
return tenantId;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method sets the value of the database column jsh_unit.tenant_id
|
||||
*
|
||||
* @param tenantId the value for jsh_unit.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_unit.delete_Flag
|
||||
*
|
||||
* @return the value of jsh_unit.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_unit.delete_Flag
|
||||
*
|
||||
* @param deleteFlag the value for jsh_unit.delete_Flag
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public void setDeleteFlag(String deleteFlag) {
|
||||
this.deleteFlag = deleteFlag == null ? null : deleteFlag.trim();
|
||||
}
|
||||
|
||||
@@ -4,118 +4,46 @@ import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class UnitExample {
|
||||
/**
|
||||
* This field was generated by MyBatis Generator.
|
||||
* This field corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
protected String orderByClause;
|
||||
|
||||
/**
|
||||
* This field was generated by MyBatis Generator.
|
||||
* This field corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
protected boolean distinct;
|
||||
|
||||
/**
|
||||
* This field was generated by MyBatis Generator.
|
||||
* This field corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
protected List<Criteria> oredCriteria;
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public UnitExample() {
|
||||
oredCriteria = new ArrayList<Criteria>();
|
||||
oredCriteria = new ArrayList<>();
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public void setOrderByClause(String orderByClause) {
|
||||
this.orderByClause = orderByClause;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public String getOrderByClause() {
|
||||
return orderByClause;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public void setDistinct(boolean distinct) {
|
||||
this.distinct = distinct;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public boolean isDistinct() {
|
||||
return distinct;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public List<Criteria> getOredCriteria() {
|
||||
return oredCriteria;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public void or(Criteria criteria) {
|
||||
oredCriteria.add(criteria);
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @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_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public Criteria createCriteria() {
|
||||
Criteria criteria = createCriteriaInternal();
|
||||
if (oredCriteria.size() == 0) {
|
||||
@@ -124,41 +52,23 @@ public class UnitExample {
|
||||
return criteria;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @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_unit
|
||||
*
|
||||
* @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_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
protected abstract static class GeneratedCriteria {
|
||||
protected List<Criterion> criteria;
|
||||
|
||||
protected GeneratedCriteria() {
|
||||
super();
|
||||
criteria = new ArrayList<Criterion>();
|
||||
criteria = new ArrayList<>();
|
||||
}
|
||||
|
||||
public boolean isValid() {
|
||||
@@ -324,6 +234,206 @@ public class UnitExample {
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitIsNull() {
|
||||
addCriterion("basic_unit is null");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitIsNotNull() {
|
||||
addCriterion("basic_unit is not null");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitEqualTo(String value) {
|
||||
addCriterion("basic_unit =", value, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitNotEqualTo(String value) {
|
||||
addCriterion("basic_unit <>", value, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitGreaterThan(String value) {
|
||||
addCriterion("basic_unit >", value, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitGreaterThanOrEqualTo(String value) {
|
||||
addCriterion("basic_unit >=", value, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitLessThan(String value) {
|
||||
addCriterion("basic_unit <", value, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitLessThanOrEqualTo(String value) {
|
||||
addCriterion("basic_unit <=", value, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitLike(String value) {
|
||||
addCriterion("basic_unit like", value, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitNotLike(String value) {
|
||||
addCriterion("basic_unit not like", value, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitIn(List<String> values) {
|
||||
addCriterion("basic_unit in", values, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitNotIn(List<String> values) {
|
||||
addCriterion("basic_unit not in", values, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitBetween(String value1, String value2) {
|
||||
addCriterion("basic_unit between", value1, value2, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andBasicUnitNotBetween(String value1, String value2) {
|
||||
addCriterion("basic_unit not between", value1, value2, "basicUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitIsNull() {
|
||||
addCriterion("other_unit is null");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitIsNotNull() {
|
||||
addCriterion("other_unit is not null");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitEqualTo(String value) {
|
||||
addCriterion("other_unit =", value, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitNotEqualTo(String value) {
|
||||
addCriterion("other_unit <>", value, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitGreaterThan(String value) {
|
||||
addCriterion("other_unit >", value, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitGreaterThanOrEqualTo(String value) {
|
||||
addCriterion("other_unit >=", value, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitLessThan(String value) {
|
||||
addCriterion("other_unit <", value, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitLessThanOrEqualTo(String value) {
|
||||
addCriterion("other_unit <=", value, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitLike(String value) {
|
||||
addCriterion("other_unit like", value, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitNotLike(String value) {
|
||||
addCriterion("other_unit not like", value, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitIn(List<String> values) {
|
||||
addCriterion("other_unit in", values, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitNotIn(List<String> values) {
|
||||
addCriterion("other_unit not in", values, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitBetween(String value1, String value2) {
|
||||
addCriterion("other_unit between", value1, value2, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andOtherUnitNotBetween(String value1, String value2) {
|
||||
addCriterion("other_unit not between", value1, value2, "otherUnit");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioIsNull() {
|
||||
addCriterion("ratio is null");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioIsNotNull() {
|
||||
addCriterion("ratio is not null");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioEqualTo(Integer value) {
|
||||
addCriterion("ratio =", value, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioNotEqualTo(Integer value) {
|
||||
addCriterion("ratio <>", value, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioGreaterThan(Integer value) {
|
||||
addCriterion("ratio >", value, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioGreaterThanOrEqualTo(Integer value) {
|
||||
addCriterion("ratio >=", value, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioLessThan(Integer value) {
|
||||
addCriterion("ratio <", value, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioLessThanOrEqualTo(Integer value) {
|
||||
addCriterion("ratio <=", value, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioIn(List<Integer> values) {
|
||||
addCriterion("ratio in", values, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioNotIn(List<Integer> values) {
|
||||
addCriterion("ratio not in", values, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioBetween(Integer value1, Integer value2) {
|
||||
addCriterion("ratio between", value1, value2, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andRatioNotBetween(Integer value1, Integer value2) {
|
||||
addCriterion("ratio not between", value1, value2, "ratio");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andTenantIdIsNull() {
|
||||
addCriterion("tenant_id is null");
|
||||
return (Criteria) this;
|
||||
@@ -455,25 +565,12 @@ public class UnitExample {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* This class was generated by MyBatis Generator.
|
||||
* This class corresponds to the database table jsh_unit
|
||||
*
|
||||
* @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_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
public static class Criterion {
|
||||
private String condition;
|
||||
|
||||
|
||||
@@ -6,91 +6,25 @@ import java.util.List;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
public interface UnitMapper {
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
int countByExample(UnitExample example);
|
||||
long countByExample(UnitExample example);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
int deleteByExample(UnitExample example);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
int deleteByPrimaryKey(Long id);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
int insert(Unit record);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
int insertSelective(Unit record);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
List<Unit> selectByExample(UnitExample example);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
Unit selectByPrimaryKey(Long id);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
int updateByExampleSelective(@Param("record") Unit record, @Param("example") UnitExample example);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
int updateByExample(@Param("record") Unit record, @Param("example") UnitExample example);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
int updateByPrimaryKeySelective(Unit record);
|
||||
|
||||
/**
|
||||
* This method was generated by MyBatis Generator.
|
||||
* This method corresponds to the database table jsh_unit
|
||||
*
|
||||
* @mbggenerated
|
||||
*/
|
||||
int updateByPrimaryKey(Unit record);
|
||||
}
|
||||
@@ -1,256 +1,243 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.jsh.erp.datasource.mappers.UnitMapper">
|
||||
<resultMap id="BaseResultMap" type="com.jsh.erp.datasource.entities.Unit">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
<id column="id" jdbcType="BIGINT" property="id" />
|
||||
<result column="UName" jdbcType="VARCHAR" property="uname" />
|
||||
<result column="tenant_id" jdbcType="BIGINT" property="tenantId" />
|
||||
<result column="delete_Flag" jdbcType="VARCHAR" property="deleteFlag" />
|
||||
</resultMap>
|
||||
<sql id="Example_Where_Clause">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
<where>
|
||||
<foreach collection="oredCriteria" item="criteria" separator="or">
|
||||
<if test="criteria.valid">
|
||||
<trim prefix="(" prefixOverrides="and" suffix=")">
|
||||
<foreach collection="criteria.criteria" item="criterion">
|
||||
<choose>
|
||||
<when test="criterion.noValue">
|
||||
and ${criterion.condition}
|
||||
</when>
|
||||
<when test="criterion.singleValue">
|
||||
and ${criterion.condition} #{criterion.value}
|
||||
</when>
|
||||
<when test="criterion.betweenValue">
|
||||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
||||
</when>
|
||||
<when test="criterion.listValue">
|
||||
and ${criterion.condition}
|
||||
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
||||
#{listItem}
|
||||
</foreach>
|
||||
</when>
|
||||
</choose>
|
||||
</foreach>
|
||||
</trim>
|
||||
</if>
|
||||
</foreach>
|
||||
</where>
|
||||
</sql>
|
||||
<sql id="Update_By_Example_Where_Clause">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
<where>
|
||||
<foreach collection="example.oredCriteria" item="criteria" separator="or">
|
||||
<if test="criteria.valid">
|
||||
<trim prefix="(" prefixOverrides="and" suffix=")">
|
||||
<foreach collection="criteria.criteria" item="criterion">
|
||||
<choose>
|
||||
<when test="criterion.noValue">
|
||||
and ${criterion.condition}
|
||||
</when>
|
||||
<when test="criterion.singleValue">
|
||||
and ${criterion.condition} #{criterion.value}
|
||||
</when>
|
||||
<when test="criterion.betweenValue">
|
||||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
||||
</when>
|
||||
<when test="criterion.listValue">
|
||||
and ${criterion.condition}
|
||||
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
||||
#{listItem}
|
||||
</foreach>
|
||||
</when>
|
||||
</choose>
|
||||
</foreach>
|
||||
</trim>
|
||||
</if>
|
||||
</foreach>
|
||||
</where>
|
||||
</sql>
|
||||
<sql id="Base_Column_List">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
id, UName, tenant_id, delete_Flag
|
||||
</sql>
|
||||
<select id="selectByExample" parameterType="com.jsh.erp.datasource.entities.UnitExample" resultMap="BaseResultMap">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
select
|
||||
<if test="distinct">
|
||||
distinct
|
||||
</if>
|
||||
<include refid="Base_Column_List" />
|
||||
from jsh_unit
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause" />
|
||||
</if>
|
||||
<if test="orderByClause != null">
|
||||
order by ${orderByClause}
|
||||
</if>
|
||||
</select>
|
||||
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
select
|
||||
<include refid="Base_Column_List" />
|
||||
from jsh_unit
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</select>
|
||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
delete from jsh_unit
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</delete>
|
||||
<delete id="deleteByExample" parameterType="com.jsh.erp.datasource.entities.UnitExample">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
delete from jsh_unit
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause" />
|
||||
</if>
|
||||
</delete>
|
||||
<insert id="insert" parameterType="com.jsh.erp.datasource.entities.Unit">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
insert into jsh_unit (id, UName, tenant_id,
|
||||
delete_Flag)
|
||||
values (#{id,jdbcType=BIGINT}, #{uname,jdbcType=VARCHAR}, #{tenantId,jdbcType=BIGINT},
|
||||
#{deleteFlag,jdbcType=VARCHAR})
|
||||
</insert>
|
||||
<insert id="insertSelective" parameterType="com.jsh.erp.datasource.entities.Unit">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
insert into jsh_unit
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">
|
||||
id,
|
||||
</if>
|
||||
<if test="uname != null">
|
||||
UName,
|
||||
</if>
|
||||
<if test="tenantId != null">
|
||||
tenant_id,
|
||||
</if>
|
||||
<if test="deleteFlag != null">
|
||||
delete_Flag,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">
|
||||
#{id,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="uname != null">
|
||||
#{uname,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="tenantId != null">
|
||||
#{tenantId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="deleteFlag != null">
|
||||
#{deleteFlag,jdbcType=VARCHAR},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
<select id="countByExample" parameterType="com.jsh.erp.datasource.entities.UnitExample" resultType="java.lang.Integer">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
select count(*) from jsh_unit
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause" />
|
||||
</if>
|
||||
</select>
|
||||
<update id="updateByExampleSelective" parameterType="map">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
update jsh_unit
|
||||
<set>
|
||||
<if test="record.id != null">
|
||||
id = #{record.id,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="record.uname != null">
|
||||
UName = #{record.uname,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.tenantId != null">
|
||||
tenant_id = #{record.tenantId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="record.deleteFlag != null">
|
||||
delete_Flag = #{record.deleteFlag,jdbcType=VARCHAR},
|
||||
</if>
|
||||
</set>
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
</if>
|
||||
</update>
|
||||
<update id="updateByExample" parameterType="map">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
update jsh_unit
|
||||
set id = #{record.id,jdbcType=BIGINT},
|
||||
UName = #{record.uname,jdbcType=VARCHAR},
|
||||
tenant_id = #{record.tenantId,jdbcType=BIGINT},
|
||||
delete_Flag = #{record.deleteFlag,jdbcType=VARCHAR}
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
</if>
|
||||
</update>
|
||||
<update id="updateByPrimaryKeySelective" parameterType="com.jsh.erp.datasource.entities.Unit">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
update jsh_unit
|
||||
<set>
|
||||
<if test="uname != null">
|
||||
UName = #{uname,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="tenantId != null">
|
||||
tenant_id = #{tenantId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="deleteFlag != null">
|
||||
delete_Flag = #{deleteFlag,jdbcType=VARCHAR},
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
<update id="updateByPrimaryKey" parameterType="com.jsh.erp.datasource.entities.Unit">
|
||||
<!--
|
||||
WARNING - @mbggenerated
|
||||
This element is automatically generated by MyBatis Generator, do not modify.
|
||||
-->
|
||||
update jsh_unit
|
||||
set UName = #{uname,jdbcType=VARCHAR},
|
||||
tenant_id = #{tenantId,jdbcType=BIGINT},
|
||||
delete_Flag = #{deleteFlag,jdbcType=VARCHAR}
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
<mapper namespace="com.jsh.erp.datasource.mappers.UnitMapper">
|
||||
<resultMap id="BaseResultMap" type="com.jsh.erp.datasource.entities.Unit">
|
||||
<id column="id" jdbcType="BIGINT" property="id" />
|
||||
<result column="UName" jdbcType="VARCHAR" property="uname" />
|
||||
<result column="basic_unit" jdbcType="VARCHAR" property="basicUnit" />
|
||||
<result column="other_unit" jdbcType="VARCHAR" property="otherUnit" />
|
||||
<result column="ratio" jdbcType="INTEGER" property="ratio" />
|
||||
<result column="tenant_id" jdbcType="BIGINT" property="tenantId" />
|
||||
<result column="delete_Flag" jdbcType="VARCHAR" property="deleteFlag" />
|
||||
</resultMap>
|
||||
<sql id="Example_Where_Clause">
|
||||
<where>
|
||||
<foreach collection="oredCriteria" item="criteria" separator="or">
|
||||
<if test="criteria.valid">
|
||||
<trim prefix="(" prefixOverrides="and" suffix=")">
|
||||
<foreach collection="criteria.criteria" item="criterion">
|
||||
<choose>
|
||||
<when test="criterion.noValue">
|
||||
and ${criterion.condition}
|
||||
</when>
|
||||
<when test="criterion.singleValue">
|
||||
and ${criterion.condition} #{criterion.value}
|
||||
</when>
|
||||
<when test="criterion.betweenValue">
|
||||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
||||
</when>
|
||||
<when test="criterion.listValue">
|
||||
and ${criterion.condition}
|
||||
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
||||
#{listItem}
|
||||
</foreach>
|
||||
</when>
|
||||
</choose>
|
||||
</foreach>
|
||||
</trim>
|
||||
</if>
|
||||
</foreach>
|
||||
</where>
|
||||
</sql>
|
||||
<sql id="Update_By_Example_Where_Clause">
|
||||
<where>
|
||||
<foreach collection="example.oredCriteria" item="criteria" separator="or">
|
||||
<if test="criteria.valid">
|
||||
<trim prefix="(" prefixOverrides="and" suffix=")">
|
||||
<foreach collection="criteria.criteria" item="criterion">
|
||||
<choose>
|
||||
<when test="criterion.noValue">
|
||||
and ${criterion.condition}
|
||||
</when>
|
||||
<when test="criterion.singleValue">
|
||||
and ${criterion.condition} #{criterion.value}
|
||||
</when>
|
||||
<when test="criterion.betweenValue">
|
||||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
||||
</when>
|
||||
<when test="criterion.listValue">
|
||||
and ${criterion.condition}
|
||||
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
||||
#{listItem}
|
||||
</foreach>
|
||||
</when>
|
||||
</choose>
|
||||
</foreach>
|
||||
</trim>
|
||||
</if>
|
||||
</foreach>
|
||||
</where>
|
||||
</sql>
|
||||
<sql id="Base_Column_List">
|
||||
id, UName, basic_unit, other_unit, ratio, tenant_id, delete_Flag
|
||||
</sql>
|
||||
<select id="selectByExample" parameterType="com.jsh.erp.datasource.entities.UnitExample" resultMap="BaseResultMap">
|
||||
select
|
||||
<if test="distinct">
|
||||
distinct
|
||||
</if>
|
||||
<include refid="Base_Column_List" />
|
||||
from jsh_unit
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause" />
|
||||
</if>
|
||||
<if test="orderByClause != null">
|
||||
order by ${orderByClause}
|
||||
</if>
|
||||
</select>
|
||||
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
|
||||
select
|
||||
<include refid="Base_Column_List" />
|
||||
from jsh_unit
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</select>
|
||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
|
||||
delete from jsh_unit
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</delete>
|
||||
<delete id="deleteByExample" parameterType="com.jsh.erp.datasource.entities.UnitExample">
|
||||
delete from jsh_unit
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause" />
|
||||
</if>
|
||||
</delete>
|
||||
<insert id="insert" parameterType="com.jsh.erp.datasource.entities.Unit">
|
||||
insert into jsh_unit (id, UName, basic_unit,
|
||||
other_unit, ratio, tenant_id,
|
||||
delete_Flag)
|
||||
values (#{id,jdbcType=BIGINT}, #{uname,jdbcType=VARCHAR}, #{basicUnit,jdbcType=VARCHAR},
|
||||
#{otherUnit,jdbcType=VARCHAR}, #{ratio,jdbcType=INTEGER}, #{tenantId,jdbcType=BIGINT},
|
||||
#{deleteFlag,jdbcType=VARCHAR})
|
||||
</insert>
|
||||
<insert id="insertSelective" parameterType="com.jsh.erp.datasource.entities.Unit">
|
||||
insert into jsh_unit
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">
|
||||
id,
|
||||
</if>
|
||||
<if test="uname != null">
|
||||
UName,
|
||||
</if>
|
||||
<if test="basicUnit != null">
|
||||
basic_unit,
|
||||
</if>
|
||||
<if test="otherUnit != null">
|
||||
other_unit,
|
||||
</if>
|
||||
<if test="ratio != null">
|
||||
ratio,
|
||||
</if>
|
||||
<if test="tenantId != null">
|
||||
tenant_id,
|
||||
</if>
|
||||
<if test="deleteFlag != null">
|
||||
delete_Flag,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">
|
||||
#{id,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="uname != null">
|
||||
#{uname,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="basicUnit != null">
|
||||
#{basicUnit,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="otherUnit != null">
|
||||
#{otherUnit,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="ratio != null">
|
||||
#{ratio,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="tenantId != null">
|
||||
#{tenantId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="deleteFlag != null">
|
||||
#{deleteFlag,jdbcType=VARCHAR},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
<select id="countByExample" parameterType="com.jsh.erp.datasource.entities.UnitExample" resultType="java.lang.Long">
|
||||
select count(*) from jsh_unit
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause" />
|
||||
</if>
|
||||
</select>
|
||||
<update id="updateByExampleSelective" parameterType="map">
|
||||
update jsh_unit
|
||||
<set>
|
||||
<if test="record.id != null">
|
||||
id = #{record.id,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="record.uname != null">
|
||||
UName = #{record.uname,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.basicUnit != null">
|
||||
basic_unit = #{record.basicUnit,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.otherUnit != null">
|
||||
other_unit = #{record.otherUnit,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.ratio != null">
|
||||
ratio = #{record.ratio,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="record.tenantId != null">
|
||||
tenant_id = #{record.tenantId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="record.deleteFlag != null">
|
||||
delete_Flag = #{record.deleteFlag,jdbcType=VARCHAR},
|
||||
</if>
|
||||
</set>
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
</if>
|
||||
</update>
|
||||
<update id="updateByExample" parameterType="map">
|
||||
update jsh_unit
|
||||
set id = #{record.id,jdbcType=BIGINT},
|
||||
UName = #{record.uname,jdbcType=VARCHAR},
|
||||
basic_unit = #{record.basicUnit,jdbcType=VARCHAR},
|
||||
other_unit = #{record.otherUnit,jdbcType=VARCHAR},
|
||||
ratio = #{record.ratio,jdbcType=INTEGER},
|
||||
tenant_id = #{record.tenantId,jdbcType=BIGINT},
|
||||
delete_Flag = #{record.deleteFlag,jdbcType=VARCHAR}
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
</if>
|
||||
</update>
|
||||
<update id="updateByPrimaryKeySelective" parameterType="com.jsh.erp.datasource.entities.Unit">
|
||||
update jsh_unit
|
||||
<set>
|
||||
<if test="uname != null">
|
||||
UName = #{uname,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="basicUnit != null">
|
||||
basic_unit = #{basicUnit,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="otherUnit != null">
|
||||
other_unit = #{otherUnit,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="ratio != null">
|
||||
ratio = #{ratio,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="tenantId != null">
|
||||
tenant_id = #{tenantId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="deleteFlag != null">
|
||||
delete_Flag = #{deleteFlag,jdbcType=VARCHAR},
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
<update id="updateByPrimaryKey" parameterType="com.jsh.erp.datasource.entities.Unit">
|
||||
update jsh_unit
|
||||
set UName = #{uname,jdbcType=VARCHAR},
|
||||
basic_unit = #{basicUnit,jdbcType=VARCHAR},
|
||||
other_unit = #{otherUnit,jdbcType=VARCHAR},
|
||||
ratio = #{ratio,jdbcType=INTEGER},
|
||||
tenant_id = #{tenantId,jdbcType=BIGINT},
|
||||
delete_Flag = #{deleteFlag,jdbcType=VARCHAR}
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user