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
d5cd48c1
Commit
d5cd48c1
authored
Feb 21, 2019
by
cjl
Browse files
商品类别操作添加事务控制
parent
898285ec
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/main/java/com/jsh/erp/service/materialCategory/MaterialCategoryService.java
View file @
d5cd48c1
...
@@ -111,6 +111,7 @@ public class MaterialCategoryService {
...
@@ -111,6 +111,7 @@ public class MaterialCategoryService {
* @Param: mc
* @Param: mc
* @return void
* @return void
*/
*/
@Transactional
(
value
=
"transactionManager"
,
rollbackFor
=
Exception
.
class
)
public
int
addMaterialCategory
(
MaterialCategory
mc
)
throws
Exception
{
public
int
addMaterialCategory
(
MaterialCategory
mc
)
throws
Exception
{
if
(
mc
==
null
){
if
(
mc
==
null
){
return
0
;
return
0
;
...
@@ -135,7 +136,7 @@ public class MaterialCategoryService {
...
@@ -135,7 +136,7 @@ public class MaterialCategoryService {
mc
.
setUpdater
(
userInfo
==
null
?
null
:
userInfo
.
getId
());
mc
.
setUpdater
(
userInfo
==
null
?
null
:
userInfo
.
getId
());
return
materialCategoryMapperEx
.
addMaterialCategory
(
mc
);
return
materialCategoryMapperEx
.
addMaterialCategory
(
mc
);
}
}
@Transactional
(
value
=
"transactionManager"
,
rollbackFor
=
Exception
.
class
)
public
int
batchDeleteMaterialCategoryByIds
(
String
ids
)
throws
Exception
{
public
int
batchDeleteMaterialCategoryByIds
(
String
ids
)
throws
Exception
{
//更新时间
//更新时间
Date
updateDate
=
new
Date
();
Date
updateDate
=
new
Date
();
...
@@ -149,7 +150,7 @@ public class MaterialCategoryService {
...
@@ -149,7 +150,7 @@ public class MaterialCategoryService {
}
}
return
materialCategoryMapperEx
.
batchDeleteMaterialCategoryByIds
(
updateDate
,
updater
,
strArray
);
return
materialCategoryMapperEx
.
batchDeleteMaterialCategoryByIds
(
updateDate
,
updater
,
strArray
);
}
}
@Transactional
(
value
=
"transactionManager"
,
rollbackFor
=
Exception
.
class
)
public
int
editMaterialCategory
(
MaterialCategory
mc
)
{
public
int
editMaterialCategory
(
MaterialCategory
mc
)
{
//检查商品类型编号是否已存在
//检查商品类型编号是否已存在
checkMaterialCategorySerialNo
(
mc
);
checkMaterialCategorySerialNo
(
mc
);
...
...
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