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
d21e6a4f
Commit
d21e6a4f
authored
Aug 22, 2021
by
季圣华
Browse files
增加防御代码,防止恶意攻击(优化)
parent
95dfcbea
Changes
2
Show whitespace changes
Inline
Side-by-side
jshERP-boot/src/main/java/com/jsh/erp/controller/SupplierController.java
View file @
d21e6a4f
...
...
@@ -52,26 +52,6 @@ public class SupplierController {
@Resource
private
UserService
userService
;
/**
* 更新供应商-只更新预付款,其余用原来的值
* @param supplierId
* @param advanceIn
* @param request
* @return
*/
@PostMapping
(
value
=
"/updateAdvanceIn"
)
public
String
updateAdvanceIn
(
@RequestParam
(
"supplierId"
)
Long
supplierId
,
@RequestParam
(
"advanceIn"
)
BigDecimal
advanceIn
,
HttpServletRequest
request
)
throws
Exception
{
Map
<
String
,
Object
>
objectMap
=
new
HashMap
<
String
,
Object
>();
int
res
=
supplierService
.
updateAdvanceIn
(
supplierId
,
advanceIn
);
if
(
res
>
0
)
{
return
returnJson
(
objectMap
,
ErpInfo
.
OK
.
name
,
ErpInfo
.
OK
.
code
);
}
else
{
return
returnJson
(
objectMap
,
ErpInfo
.
ERROR
.
name
,
ErpInfo
.
ERROR
.
code
);
}
}
/**
* 查找客户信息-下拉框
* @param request
...
...
jshERP-boot/src/main/java/com/jsh/erp/service/supplier/SupplierService.java
View file @
d21e6a4f
...
...
@@ -240,9 +240,6 @@ public class SupplierService {
@Transactional
(
value
=
"transactionManager"
,
rollbackFor
=
Exception
.
class
)
public
int
updateAdvanceIn
(
Long
supplierId
,
BigDecimal
advanceIn
)
throws
Exception
{
logService
.
insertLog
(
"商家"
,
new
StringBuffer
(
BusinessConstants
.
LOG_OPERATION_TYPE_EDIT
).
append
(
supplierId
).
toString
(),
((
ServletRequestAttributes
)
RequestContextHolder
.
getRequestAttributes
()).
getRequest
());
Supplier
supplier
=
null
;
try
{
supplier
=
supplierMapper
.
selectByPrimaryKey
(
supplierId
);
...
...
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