Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
JSH ERP
Commits
5a1d4bf5
Commit
5a1d4bf5
authored
Aug 26, 2022
by
季圣华
Browse files
给部分表增加启用状态和排序字段
parent
fb79e174
Changes
25
Show whitespace changes
Inline
Side-by-side
jshERP-boot/src/main/resources/mapper_xml/PersonMapper.xml
View file @
5a1d4bf5
...
...
@@ -5,6 +5,8 @@
<id
column=
"id"
jdbcType=
"BIGINT"
property=
"id"
/>
<result
column=
"type"
jdbcType=
"VARCHAR"
property=
"type"
/>
<result
column=
"name"
jdbcType=
"VARCHAR"
property=
"name"
/>
<result
column=
"enabled"
jdbcType=
"BIT"
property=
"enabled"
/>
<result
column=
"sort"
jdbcType=
"VARCHAR"
property=
"sort"
/>
<result
column=
"tenant_id"
jdbcType=
"BIGINT"
property=
"tenantId"
/>
<result
column=
"delete_flag"
jdbcType=
"VARCHAR"
property=
"deleteFlag"
/>
</resultMap>
...
...
@@ -67,7 +69,7 @@
</where>
</sql>
<sql
id=
"Base_Column_List"
>
id, type, name, tenant_id, delete_flag
id, type, name,
enabled, sort,
tenant_id, delete_flag
</sql>
<select
id=
"selectByExample"
parameterType=
"com.jsh.erp.datasource.entities.PersonExample"
resultMap=
"BaseResultMap"
>
select
...
...
@@ -101,9 +103,11 @@
</delete>
<insert
id=
"insert"
parameterType=
"com.jsh.erp.datasource.entities.Person"
>
insert into jsh_person (id, type, name,
tenant_id, delete_flag)
enabled, sort, tenant_id,
delete_flag)
values (#{id,jdbcType=BIGINT}, #{type,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR})
#{enabled,jdbcType=BIT}, #{sort,jdbcType=VARCHAR}, #{tenantId,jdbcType=BIGINT},
#{deleteFlag,jdbcType=VARCHAR})
</insert>
<insert
id=
"insertSelective"
parameterType=
"com.jsh.erp.datasource.entities.Person"
>
insert into jsh_person
...
...
@@ -117,6 +121,12 @@
<if
test=
"name != null"
>
name,
</if>
<if
test=
"enabled != null"
>
enabled,
</if>
<if
test=
"sort != null"
>
sort,
</if>
<if
test=
"tenantId != null"
>
tenant_id,
</if>
...
...
@@ -134,6 +144,12 @@
<if
test=
"name != null"
>
#{name,jdbcType=VARCHAR},
</if>
<if
test=
"enabled != null"
>
#{enabled,jdbcType=BIT},
</if>
<if
test=
"sort != null"
>
#{sort,jdbcType=VARCHAR},
</if>
<if
test=
"tenantId != null"
>
#{tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -160,6 +176,12 @@
<if
test=
"record.name != null"
>
name = #{record.name,jdbcType=VARCHAR},
</if>
<if
test=
"record.enabled != null"
>
enabled = #{record.enabled,jdbcType=BIT},
</if>
<if
test=
"record.sort != null"
>
sort = #{record.sort,jdbcType=VARCHAR},
</if>
<if
test=
"record.tenantId != null"
>
tenant_id = #{record.tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -176,6 +198,8 @@
set id = #{record.id,jdbcType=BIGINT},
type = #{record.type,jdbcType=VARCHAR},
name = #{record.name,jdbcType=VARCHAR},
enabled = #{record.enabled,jdbcType=BIT},
sort = #{record.sort,jdbcType=VARCHAR},
tenant_id = #{record.tenantId,jdbcType=BIGINT},
delete_flag = #{record.deleteFlag,jdbcType=VARCHAR}
<if
test=
"_parameter != null"
>
...
...
@@ -191,6 +215,12 @@
<if
test=
"name != null"
>
name = #{name,jdbcType=VARCHAR},
</if>
<if
test=
"enabled != null"
>
enabled = #{enabled,jdbcType=BIT},
</if>
<if
test=
"sort != null"
>
sort = #{sort,jdbcType=VARCHAR},
</if>
<if
test=
"tenantId != null"
>
tenant_id = #{tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -204,6 +234,8 @@
update jsh_person
set type = #{type,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
enabled = #{enabled,jdbcType=BIT},
sort = #{sort,jdbcType=VARCHAR},
tenant_id = #{tenantId,jdbcType=BIGINT},
delete_flag = #{deleteFlag,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
...
...
jshERP-boot/src/main/resources/mapper_xml/RoleMapper.xml
View file @
5a1d4bf5
...
...
@@ -7,6 +7,8 @@
<result
column=
"type"
jdbcType=
"VARCHAR"
property=
"type"
/>
<result
column=
"value"
jdbcType=
"VARCHAR"
property=
"value"
/>
<result
column=
"description"
jdbcType=
"VARCHAR"
property=
"description"
/>
<result
column=
"enabled"
jdbcType=
"BIT"
property=
"enabled"
/>
<result
column=
"sort"
jdbcType=
"VARCHAR"
property=
"sort"
/>
<result
column=
"tenant_id"
jdbcType=
"BIGINT"
property=
"tenantId"
/>
<result
column=
"delete_flag"
jdbcType=
"VARCHAR"
property=
"deleteFlag"
/>
</resultMap>
...
...
@@ -69,7 +71,7 @@
</where>
</sql>
<sql
id=
"Base_Column_List"
>
id, name, type, value, description, tenant_id, delete_flag
id, name, type, value, description,
enabled, sort,
tenant_id, delete_flag
</sql>
<select
id=
"selectByExample"
parameterType=
"com.jsh.erp.datasource.entities.RoleExample"
resultMap=
"BaseResultMap"
>
select
...
...
@@ -103,11 +105,13 @@
</delete>
<insert
id=
"insert"
parameterType=
"com.jsh.erp.datasource.entities.Role"
>
insert into jsh_role (id, name, type,
value, description, tenant_id,
delete_flag)
value, description, enabled,
sort, tenant_id, delete_flag
)
values (#{id,jdbcType=BIGINT}, #{name,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR},
#{value,jdbcType=VARCHAR}, #{description,jdbcType=VARCHAR}, #{tenantId,jdbcType=BIGINT},
#{deleteFlag,jdbcType=VARCHAR})
#{value,jdbcType=VARCHAR}, #{description,jdbcType=VARCHAR}, #{enabled,jdbcType=BIT},
#{sort,jdbcType=VARCHAR}, #{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR}
)
</insert>
<insert
id=
"insertSelective"
parameterType=
"com.jsh.erp.datasource.entities.Role"
>
insert into jsh_role
...
...
@@ -127,6 +131,12 @@
<if
test=
"description != null"
>
description,
</if>
<if
test=
"enabled != null"
>
enabled,
</if>
<if
test=
"sort != null"
>
sort,
</if>
<if
test=
"tenantId != null"
>
tenant_id,
</if>
...
...
@@ -150,6 +160,12 @@
<if
test=
"description != null"
>
#{description,jdbcType=VARCHAR},
</if>
<if
test=
"enabled != null"
>
#{enabled,jdbcType=BIT},
</if>
<if
test=
"sort != null"
>
#{sort,jdbcType=VARCHAR},
</if>
<if
test=
"tenantId != null"
>
#{tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -182,6 +198,12 @@
<if
test=
"record.description != null"
>
description = #{record.description,jdbcType=VARCHAR},
</if>
<if
test=
"record.enabled != null"
>
enabled = #{record.enabled,jdbcType=BIT},
</if>
<if
test=
"record.sort != null"
>
sort = #{record.sort,jdbcType=VARCHAR},
</if>
<if
test=
"record.tenantId != null"
>
tenant_id = #{record.tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -200,6 +222,8 @@
type = #{record.type,jdbcType=VARCHAR},
value = #{record.value,jdbcType=VARCHAR},
description = #{record.description,jdbcType=VARCHAR},
enabled = #{record.enabled,jdbcType=BIT},
sort = #{record.sort,jdbcType=VARCHAR},
tenant_id = #{record.tenantId,jdbcType=BIGINT},
delete_flag = #{record.deleteFlag,jdbcType=VARCHAR}
<if
test=
"_parameter != null"
>
...
...
@@ -221,6 +245,12 @@
<if
test=
"description != null"
>
description = #{description,jdbcType=VARCHAR},
</if>
<if
test=
"enabled != null"
>
enabled = #{enabled,jdbcType=BIT},
</if>
<if
test=
"sort != null"
>
sort = #{sort,jdbcType=VARCHAR},
</if>
<if
test=
"tenantId != null"
>
tenant_id = #{tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -236,6 +266,8 @@
type = #{type,jdbcType=VARCHAR},
value = #{value,jdbcType=VARCHAR},
description = #{description,jdbcType=VARCHAR},
enabled = #{enabled,jdbcType=BIT},
sort = #{sort,jdbcType=VARCHAR},
tenant_id = #{tenantId,jdbcType=BIGINT},
delete_flag = #{deleteFlag,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
...
...
jshERP-boot/src/main/resources/mapper_xml/SupplierMapper.xml
View file @
5a1d4bf5
...
...
@@ -23,6 +23,7 @@
<result
column=
"bank_name"
jdbcType=
"VARCHAR"
property=
"bankName"
/>
<result
column=
"account_number"
jdbcType=
"VARCHAR"
property=
"accountNumber"
/>
<result
column=
"tax_rate"
jdbcType=
"DECIMAL"
property=
"taxRate"
/>
<result
column=
"sort"
jdbcType=
"VARCHAR"
property=
"sort"
/>
<result
column=
"tenant_id"
jdbcType=
"BIGINT"
property=
"tenantId"
/>
<result
column=
"delete_flag"
jdbcType=
"VARCHAR"
property=
"deleteFlag"
/>
</resultMap>
...
...
@@ -87,7 +88,7 @@
<sql
id=
"Base_Column_List"
>
id, supplier, contacts, phone_num, email, description, isystem, type, enabled, advance_in,
begin_need_get, begin_need_pay, all_need_get, all_need_pay, fax, telephone, address,
tax_num, bank_name, account_number, tax_rate, tenant_id, delete_flag
tax_num, bank_name, account_number, tax_rate,
sort,
tenant_id, delete_flag
</sql>
<select
id=
"selectByExample"
parameterType=
"com.jsh.erp.datasource.entities.SupplierExample"
resultMap=
"BaseResultMap"
>
select
...
...
@@ -127,7 +128,8 @@
all_need_get, all_need_pay, fax,
telephone, address, tax_num,
bank_name, account_number, tax_rate,
tenant_id, delete_flag)
sort, tenant_id, delete_flag
)
values (#{id,jdbcType=BIGINT}, #{supplier,jdbcType=VARCHAR}, #{contacts,jdbcType=VARCHAR},
#{phoneNum,jdbcType=VARCHAR}, #{email,jdbcType=VARCHAR}, #{description,jdbcType=VARCHAR},
#{isystem,jdbcType=TINYINT}, #{type,jdbcType=VARCHAR}, #{enabled,jdbcType=BIT},
...
...
@@ -135,7 +137,8 @@
#{allNeedGet,jdbcType=DECIMAL}, #{allNeedPay,jdbcType=DECIMAL}, #{fax,jdbcType=VARCHAR},
#{telephone,jdbcType=VARCHAR}, #{address,jdbcType=VARCHAR}, #{taxNum,jdbcType=VARCHAR},
#{bankName,jdbcType=VARCHAR}, #{accountNumber,jdbcType=VARCHAR}, #{taxRate,jdbcType=DECIMAL},
#{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR})
#{sort,jdbcType=VARCHAR}, #{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR}
)
</insert>
<insert
id=
"insertSelective"
parameterType=
"com.jsh.erp.datasource.entities.Supplier"
>
insert into jsh_supplier
...
...
@@ -203,6 +206,9 @@
<if
test=
"taxRate != null"
>
tax_rate,
</if>
<if
test=
"sort != null"
>
sort,
</if>
<if
test=
"tenantId != null"
>
tenant_id,
</if>
...
...
@@ -274,6 +280,9 @@
<if
test=
"taxRate != null"
>
#{taxRate,jdbcType=DECIMAL},
</if>
<if
test=
"sort != null"
>
#{sort,jdbcType=VARCHAR},
</if>
<if
test=
"tenantId != null"
>
#{tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -354,6 +363,9 @@
<if
test=
"record.taxRate != null"
>
tax_rate = #{record.taxRate,jdbcType=DECIMAL},
</if>
<if
test=
"record.sort != null"
>
sort = #{record.sort,jdbcType=VARCHAR},
</if>
<if
test=
"record.tenantId != null"
>
tenant_id = #{record.tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -388,6 +400,7 @@
bank_name = #{record.bankName,jdbcType=VARCHAR},
account_number = #{record.accountNumber,jdbcType=VARCHAR},
tax_rate = #{record.taxRate,jdbcType=DECIMAL},
sort = #{record.sort,jdbcType=VARCHAR},
tenant_id = #{record.tenantId,jdbcType=BIGINT},
delete_flag = #{record.deleteFlag,jdbcType=VARCHAR}
<if
test=
"_parameter != null"
>
...
...
@@ -457,6 +470,9 @@
<if
test=
"taxRate != null"
>
tax_rate = #{taxRate,jdbcType=DECIMAL},
</if>
<if
test=
"sort != null"
>
sort = #{sort,jdbcType=VARCHAR},
</if>
<if
test=
"tenantId != null"
>
tenant_id = #{tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -488,6 +504,7 @@
bank_name = #{bankName,jdbcType=VARCHAR},
account_number = #{accountNumber,jdbcType=VARCHAR},
tax_rate = #{taxRate,jdbcType=DECIMAL},
sort = #{sort,jdbcType=VARCHAR},
tenant_id = #{tenantId,jdbcType=BIGINT},
delete_flag = #{deleteFlag,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
...
...
jshERP-boot/src/main/resources/mapper_xml/UnitMapper.xml
View file @
5a1d4bf5
...
...
@@ -11,6 +11,7 @@
<result
column=
"ratio"
jdbcType=
"INTEGER"
property=
"ratio"
/>
<result
column=
"ratio_two"
jdbcType=
"INTEGER"
property=
"ratioTwo"
/>
<result
column=
"ratio_three"
jdbcType=
"INTEGER"
property=
"ratioThree"
/>
<result
column=
"enabled"
jdbcType=
"BIT"
property=
"enabled"
/>
<result
column=
"tenant_id"
jdbcType=
"BIGINT"
property=
"tenantId"
/>
<result
column=
"delete_flag"
jdbcType=
"VARCHAR"
property=
"deleteFlag"
/>
</resultMap>
...
...
@@ -74,7 +75,7 @@
</sql>
<sql
id=
"Base_Column_List"
>
id, name, basic_unit, other_unit, other_unit_two, other_unit_three, ratio, ratio_two,
ratio_three, tenant_id, delete_flag
ratio_three,
enabled,
tenant_id, delete_flag
</sql>
<select
id=
"selectByExample"
parameterType=
"com.jsh.erp.datasource.entities.UnitExample"
resultMap=
"BaseResultMap"
>
select
...
...
@@ -110,11 +111,13 @@
insert into jsh_unit (id, name, basic_unit,
other_unit, other_unit_two, other_unit_three,
ratio, ratio_two, ratio_three,
tenant_id, delete_flag)
enabled, tenant_id, delete_flag
)
values (#{id,jdbcType=BIGINT}, #{name,jdbcType=VARCHAR}, #{basicUnit,jdbcType=VARCHAR},
#{otherUnit,jdbcType=VARCHAR}, #{otherUnitTwo,jdbcType=VARCHAR}, #{otherUnitThree,jdbcType=VARCHAR},
#{ratio,jdbcType=INTEGER}, #{ratioTwo,jdbcType=INTEGER}, #{ratioThree,jdbcType=INTEGER},
#{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR})
#{enabled,jdbcType=BIT}, #{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR}
)
</insert>
<insert
id=
"insertSelective"
parameterType=
"com.jsh.erp.datasource.entities.Unit"
>
insert into jsh_unit
...
...
@@ -146,6 +149,9 @@
<if
test=
"ratioThree != null"
>
ratio_three,
</if>
<if
test=
"enabled != null"
>
enabled,
</if>
<if
test=
"tenantId != null"
>
tenant_id,
</if>
...
...
@@ -181,6 +187,9 @@
<if
test=
"ratioThree != null"
>
#{ratioThree,jdbcType=INTEGER},
</if>
<if
test=
"enabled != null"
>
#{enabled,jdbcType=BIT},
</if>
<if
test=
"tenantId != null"
>
#{tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -225,6 +234,9 @@
<if
test=
"record.ratioThree != null"
>
ratio_three = #{record.ratioThree,jdbcType=INTEGER},
</if>
<if
test=
"record.enabled != null"
>
enabled = #{record.enabled,jdbcType=BIT},
</if>
<if
test=
"record.tenantId != null"
>
tenant_id = #{record.tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -247,6 +259,7 @@
ratio = #{record.ratio,jdbcType=INTEGER},
ratio_two = #{record.ratioTwo,jdbcType=INTEGER},
ratio_three = #{record.ratioThree,jdbcType=INTEGER},
enabled = #{record.enabled,jdbcType=BIT},
tenant_id = #{record.tenantId,jdbcType=BIGINT},
delete_flag = #{record.deleteFlag,jdbcType=VARCHAR}
<if
test=
"_parameter != null"
>
...
...
@@ -280,6 +293,9 @@
<if
test=
"ratioThree != null"
>
ratio_three = #{ratioThree,jdbcType=INTEGER},
</if>
<if
test=
"enabled != null"
>
enabled = #{enabled,jdbcType=BIT},
</if>
<if
test=
"tenantId != null"
>
tenant_id = #{tenantId,jdbcType=BIGINT},
</if>
...
...
@@ -299,6 +315,7 @@
ratio = #{ratio,jdbcType=INTEGER},
ratio_two = #{ratioTwo,jdbcType=INTEGER},
ratio_three = #{ratioThree,jdbcType=INTEGER},
enabled = #{enabled,jdbcType=BIT},
tenant_id = #{tenantId,jdbcType=BIGINT},
delete_flag = #{deleteFlag,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
...
...
jshERP-boot/src/test/resources/generatorConfig.xml
View file @
5a1d4bf5
...
...
@@ -48,7 +48,7 @@
<table tableName="jsh_depot_head" domainObjectName="DepotHead"></table>
<table tableName="jsh_depot_item" domainObjectName="DepotItem"></table>
<table tableName="jsh_function" domainObjectName="Function"></table>
<table tableName="jsh_inoutitem" domainObjectName="InOutItem"></table>
<table tableName="jsh_in
_
out
_
item" domainObjectName="InOutItem"></table>
<table tableName="jsh_log" domainObjectName="Log"></table>
<table tableName="jsh_material" domainObjectName="Material"></table>
<table tableName="jsh_material_attribute" domainObjectName="MaterialAttribute"></table>
...
...
Prev
1
2
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment