Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
T
tcm-system
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
TCM
tcm-system
Commits
693800b5
Commit
693800b5
authored
Jan 16, 2023
by
tangfang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改用户二维码生成
parent
9759fb71
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
7 deletions
+37
-7
FinanceController.java
.../pangding/web/authority/controller/FinanceController.java
+37
-7
No files found.
src/main/java/com/pangding/web/authority/controller/FinanceController.java
View file @
693800b5
...
...
@@ -4,13 +4,16 @@ import com.pangding.web.authority.service.CompanyMoneyService;
import
com.pangding.web.authority.service.FinanceService
;
import
com.pangding.web.authority.vo.reqvo.WithdrawalReqVo
;
import
com.pangding.web.authority.vo.resvo.WithdrawalResVo
;
import
com.pangding.web.util.DateUtil
;
import
com.pangding.web.vo.order.req.CapitalFlowReqVo
;
import
com.pangding.web.vo.order.req.back.CashWithdrawalBackReqVo
;
import
com.pangding.web.vo.order.res.CapitalFlowListResVo
;
import
com.pangding.web.vo.system.pd.company.CompanyMoneyVo
;
import
com.pangding.web.vo.system.req.company.CompanyMoneyReqVo
;
import
com.pangding.web.vo.system.res.company.CompanyMoneyTotalResVo
;
import
com.yanzuoguang.util.exception.CodeException
;
import
com.yanzuoguang.util.helper.CheckerHelper
;
import
com.yanzuoguang.util.helper.DateHelper
;
import
com.yanzuoguang.util.helper.StringHelper
;
import
com.yanzuoguang.util.vo.ResponseResult
;
import
io.swagger.annotations.Api
;
...
...
@@ -19,13 +22,17 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.http.MediaType
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.Date
;
import
static
com
.
yanzuoguang
.
util
.
helper
.
DateHelper
.
getCurDate
;
/**
* @Author zhangjinyao
* @create 2019/6/18 19:53
*/
@RestController
@RequestMapping
(
value
=
"/finance"
,
method
=
RequestMethod
.
POST
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
@RequestMapping
(
value
=
"/finance"
,
method
=
RequestMethod
.
POST
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
@Api
(
value
=
"余额"
,
description
=
"余额"
)
public
class
FinanceController
{
@Autowired
...
...
@@ -44,7 +51,7 @@ public class FinanceController {
CheckerHelper
.
newInstance
()
.
notBlankCheck
(
"companyId"
,
req
.
getCompanyId
())
.
checkException
();
if
(
"10001"
.
equals
(
req
.
getCompanyId
()))
{
if
(
"10001"
.
equals
(
req
.
getCompanyId
()))
{
req
.
setCompanyId
(
""
);
}
if
(!
StringHelper
.
isEmpty
(
req
.
getDateType
())
&&
1
==
req
.
getDateType
())
{
...
...
@@ -66,15 +73,16 @@ public class FinanceController {
@PostMapping
(
value
=
"/withdrawal"
)
@ApiOperation
(
value
=
"公司余额查询"
,
notes
=
"返回公司余额信息"
)
public
ResponseResult
<
WithdrawalResVo
>
withdrawal
(
@RequestBody
WithdrawalReqVo
reqVo
){
public
ResponseResult
<
WithdrawalResVo
>
withdrawal
(
@RequestBody
WithdrawalReqVo
reqVo
)
{
CheckerHelper
.
newInstance
()
.
notBlankCheck
(
"companyId"
,
reqVo
.
getCompanyId
())
.
notBlankCheck
(
"companyId"
,
reqVo
.
getCompanyId
())
.
checkException
();
return
ResponseResult
.
result
(
financeService
.
withdrawal
(
reqVo
));
}
/**
* 提现申请
*
* @param req
* @return
*/
...
...
@@ -95,12 +103,13 @@ public class FinanceController {
* 提现回调
*/
@RequestMapping
(
value
=
"/withdrawalBack"
)
public
ResponseResult
<
String
>
withdrawalBack
(
@RequestBody
CashWithdrawalBackReqVo
req
){
public
ResponseResult
<
String
>
withdrawalBack
(
@RequestBody
CashWithdrawalBackReqVo
req
)
{
return
financeService
.
withdrawalBack
(
req
);
}
/**
* 转账
*
* @param req
* @return
*/
...
...
@@ -118,13 +127,34 @@ public class FinanceController {
@RequestMapping
(
value
=
"findCompanyMoneyList"
)
@ApiOperation
(
value
=
"找到公司资金汇总列表"
,
notes
=
"返回公司资金汇总列表"
)
public
ResponseResult
<
CompanyMoneyTotalResVo
>
findCompanyMoneyList
(
@RequestBody
CompanyMoneyReqVo
req
){
public
ResponseResult
<
CompanyMoneyTotalResVo
>
findCompanyMoneyList
(
@RequestBody
CompanyMoneyReqVo
req
)
{
// CheckerHelper.newInstance()
// .notBlankCheck("companyId", req.getCompanyId())
// .notBlankCheck("startDate", req.getStartDate())
// .notBlankCheck("endDate", req.getEndDate())
// .checkException();
Date
now
=
DateHelper
.
getDateTime
(
DateHelper
.
toDay
(
DateHelper
.
getDateTime
(
getCurDate
())));
if
(!
StringHelper
.
isEmpty
(
req
.
getStartDate
())){
req
.
setStartDate
(
"2023-01-16"
);
Date
start
=
DateHelper
.
getDateTime
(
DateHelper
.
toDay
(
DateHelper
.
getDateTime
(
req
.
getStartDate
())));
System
.
out
.
println
(
DateHelper
.
compare
(
start
,
now
));
if
(
DateHelper
.
compare
(
start
,
now
)
==
0
)
{
req
.
setStartDate
(
DateUtil
.
getBeforDateStr
(
req
.
getStartDate
()));
}
}
if
(!
StringHelper
.
isEmpty
(
req
.
getEndDate
())){
Date
end
=
DateHelper
.
getDateTime
(
DateHelper
.
toDay
(
DateHelper
.
getDateTime
(
req
.
getEndDate
())));
if
(
DateHelper
.
compare
(
now
,
end
)
==
0
)
{
req
.
setEndDate
(
DateUtil
.
getBeforDateStr
(
req
.
getEndDate
()));
}
}
return
ResponseResult
.
result
(
companyMoneyService
.
findCompanyMoney
(
req
));
}
@RequestMapping
(
value
=
"/findLastInfo"
)
@ApiOperation
(
value
=
"查询最后一条数据的finalMoney"
,
notes
=
"查询最后一条数据的finalMoney"
)
public
ResponseResult
<
CompanyMoneyVo
>
findLastInfo
(
@RequestBody
CompanyMoneyReqVo
req
){
public
ResponseResult
<
CompanyMoneyVo
>
findLastInfo
(
@RequestBody
CompanyMoneyReqVo
req
)
{
return
ResponseResult
.
result
(
companyMoneyService
.
findLastInfo
(
req
));
}
...
...
Write
Preview
Markdown
is supported
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