Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
SiEn
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hewei
SiEn
Commits
57911cfe
Commit
57911cfe
authored
Oct 23, 2020
by
giaogiao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
用户付款: 添加付款时间
parent
180c4693
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
39 additions
and
0 deletions
+39
-0
api-app/src/main/java/com/jumeirah/api/app/controller/StrokeController.java
+3
-0
bootstrap/src/test/java/io/geekidea/springbootplus/test/TimestampTest.java
+33
-0
common/src/main/java/com/jumeirah/common/entity/Stroke.java
+3
-0
No files found.
api-app/src/main/java/com/jumeirah/api/app/controller/StrokeController.java
View file @
57911cfe
...
@@ -38,6 +38,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
...
@@ -38,6 +38,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.sql.Timestamp
;
import
java.time.Instant
;
/**
/**
* 行程表 控制器
* 行程表 控制器
...
@@ -66,6 +68,7 @@ public class StrokeController extends BaseController {
...
@@ -66,6 +68,7 @@ public class StrokeController extends BaseController {
Stroke
stroke
=
new
Stroke
();
Stroke
stroke
=
new
Stroke
();
BeanUtils
.
copyProperties
(
strokePaymentInfoParam
,
stroke
);
BeanUtils
.
copyProperties
(
strokePaymentInfoParam
,
stroke
);
stroke
.
setPaymentStatus
(
StatePaymentStatusEnum
.
PAYING
.
getCode
());
stroke
.
setPaymentStatus
(
StatePaymentStatusEnum
.
PAYING
.
getCode
());
stroke
.
setUserRechargeTime
(
Timestamp
.
from
(
Instant
.
now
()));
boolean
flag
=
strokeService
.
update
(
stroke
,
new
UpdateWrapper
<
Stroke
>().
lambda
()
boolean
flag
=
strokeService
.
update
(
stroke
,
new
UpdateWrapper
<
Stroke
>().
lambda
()
.
eq
(
Stroke:
:
getUserId
,
jwtToken
.
getUserId
())
.
eq
(
Stroke:
:
getUserId
,
jwtToken
.
getUserId
())
.
eq
(
Stroke:
:
getId
,
strokePaymentInfoParam
.
getId
())
.
eq
(
Stroke:
:
getId
,
strokePaymentInfoParam
.
getId
())
...
...
bootstrap/src/test/java/io/geekidea/springbootplus/test/TimestampTest.java
0 → 100755
View file @
57911cfe
/*
* Copyright 2019-2029 geekidea(https://github.com/geekidea)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
io
.
geekidea
.
springbootplus
.
test
;
import
java.sql.Timestamp
;
import
java.time.Instant
;
/**
* @author geekidea
* @date 2020/3/16
**/
public
class
TimestampTest
{
public
static
void
main
(
String
[]
args
)
{
// 获取当前时间戳
Timestamp
from
=
Timestamp
.
from
(
Instant
.
now
());
System
.
out
.
println
(
from
);
}
}
common/src/main/java/com/jumeirah/common/entity/Stroke.java
View file @
57911cfe
...
@@ -81,6 +81,9 @@ public class Stroke extends BaseEntity {
...
@@ -81,6 +81,9 @@ public class Stroke extends BaseEntity {
@ApiModelProperty
(
"更新时间"
)
@ApiModelProperty
(
"更新时间"
)
private
Timestamp
updateTime
;
private
Timestamp
updateTime
;
@ApiModelProperty
(
"付款时间"
)
private
Timestamp
userRechargeTime
;
@ApiModelProperty
(
"货物名称"
)
@ApiModelProperty
(
"货物名称"
)
private
String
goodsName
;
private
String
goodsName
;
...
...
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