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
16e45ee4
Commit
16e45ee4
authored
Nov 02, 2020
by
lanpingxiong
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev/lanpingxiong' into 'master'
# 商家端优惠行程修改接口 See merge request hewei/Jumeirah!61
parents
c41cfb42
7751572e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
5 deletions
+13
-5
api-app/src/main/java/com/jumeirah/api/app/controller/AppUserController.java
+1
-1
api-merchant/src/main/java/com/jumeirah/api/merchant/controller/plain/McStrokeDiscountController.java
+7
-4
api-merchant/src/main/java/com/jumeirah/api/merchant/entity/param/McStrokeDiscountAddParam.java
+5
-0
No files found.
api-app/src/main/java/com/jumeirah/api/app/controller/AppUserController.java
View file @
16e45ee4
...
@@ -18,7 +18,6 @@ import io.geekidea.springbootplus.framework.shiro.util.JwtUtil;
...
@@ -18,7 +18,6 @@ import io.geekidea.springbootplus.framework.shiro.util.JwtUtil;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
lombok.extern.slf4j.Slf4j
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.ibatis.annotations.Param
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.GetMapping
;
...
@@ -26,6 +25,7 @@ import org.springframework.web.bind.annotation.PostMapping;
...
@@ -26,6 +25,7 @@ import org.springframework.web.bind.annotation.PostMapping;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestHeader
;
import
org.springframework.web.bind.annotation.RequestHeader
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.util.List
;
import
java.util.List
;
...
...
api-merchant/src/main/java/com/jumeirah/api/merchant/controller/plain/McStrokeDiscountController.java
View file @
16e45ee4
...
@@ -9,6 +9,7 @@ import io.geekidea.springbootplus.framework.common.api.ApiResult;
...
@@ -9,6 +9,7 @@ import io.geekidea.springbootplus.framework.common.api.ApiResult;
import
io.geekidea.springbootplus.framework.common.controller.BaseController
;
import
io.geekidea.springbootplus.framework.common.controller.BaseController
;
import
io.geekidea.springbootplus.framework.core.pagination.Paging
;
import
io.geekidea.springbootplus.framework.core.pagination.Paging
;
import
io.geekidea.springbootplus.framework.core.validator.groups.Add
;
import
io.geekidea.springbootplus.framework.core.validator.groups.Add
;
import
io.geekidea.springbootplus.framework.core.validator.groups.Update
;
import
io.geekidea.springbootplus.framework.log.annotation.OperationLog
;
import
io.geekidea.springbootplus.framework.log.annotation.OperationLog
;
import
io.geekidea.springbootplus.framework.log.enums.OperationLogType
;
import
io.geekidea.springbootplus.framework.log.enums.OperationLogType
;
import
io.geekidea.springbootplus.framework.shiro.jwt.JwtToken
;
import
io.geekidea.springbootplus.framework.shiro.jwt.JwtToken
;
...
@@ -50,7 +51,7 @@ public class McStrokeDiscountController extends BaseController {
...
@@ -50,7 +51,7 @@ public class McStrokeDiscountController extends BaseController {
@RequiresPermissions
(
"merchant:aircraft:management:edit"
)
@RequiresPermissions
(
"merchant:aircraft:management:edit"
)
public
ApiResult
<
Boolean
>
addStrokeDiscount
(
@Validated
(
Add
.
class
)
@RequestBody
McStrokeDiscountAddParam
mcStrokeDiscountAddParam
)
throws
Exception
{
public
ApiResult
<
Boolean
>
addStrokeDiscount
(
@Validated
(
Add
.
class
)
@RequestBody
McStrokeDiscountAddParam
mcStrokeDiscountAddParam
)
throws
Exception
{
StrokeDiscount
strokeDiscount
=
new
StrokeDiscount
();
StrokeDiscount
strokeDiscount
=
new
StrokeDiscount
();
BeanUtils
.
copyProperties
(
mcStrokeDiscountAddParam
,
strokeDiscount
);
BeanUtils
.
copyProperties
(
mcStrokeDiscountAddParam
,
strokeDiscount
);
JwtToken
jwtToken
=
(
JwtToken
)
SecurityUtils
.
getSubject
().
getPrincipal
();
JwtToken
jwtToken
=
(
JwtToken
)
SecurityUtils
.
getSubject
().
getPrincipal
();
strokeDiscount
.
setMcId
(
jwtToken
.
getMcId
());
strokeDiscount
.
setMcId
(
jwtToken
.
getMcId
());
boolean
flag
=
strokeDiscountService
.
saveStrokeDiscount
(
strokeDiscount
);
boolean
flag
=
strokeDiscountService
.
saveStrokeDiscount
(
strokeDiscount
);
...
@@ -60,13 +61,15 @@ public class McStrokeDiscountController extends BaseController {
...
@@ -60,13 +61,15 @@ public class McStrokeDiscountController extends BaseController {
/**
/**
* 修改优惠行程表
* 修改优惠行程表
*/
*/
/*
@PostMapping("/update")
@PostMapping
(
"/update"
)
@OperationLog
(
name
=
"修改优惠行程表"
,
type
=
OperationLogType
.
UPDATE
)
@OperationLog
(
name
=
"修改优惠行程表"
,
type
=
OperationLogType
.
UPDATE
)
@ApiOperation
(
value
=
"修改优惠行程表"
)
@ApiOperation
(
value
=
"修改优惠行程表"
)
public ApiResult<Boolean> updateStrokeDiscount(@Validated(Update.class) @RequestBody StrokeDiscount strokeDiscount) throws Exception {
public
ApiResult
<
Boolean
>
updateStrokeDiscount
(
@Validated
(
Update
.
class
)
@RequestBody
McStrokeDiscountAddParam
mcStrokeDiscountAddParam
)
throws
Exception
{
StrokeDiscount
strokeDiscount
=
new
StrokeDiscount
();
BeanUtils
.
copyProperties
(
mcStrokeDiscountAddParam
,
strokeDiscount
);
boolean
flag
=
strokeDiscountService
.
updateStrokeDiscount
(
strokeDiscount
);
boolean
flag
=
strokeDiscountService
.
updateStrokeDiscount
(
strokeDiscount
);
return
ApiResult
.
result
(
flag
);
return
ApiResult
.
result
(
flag
);
}
*/
}
/**
/**
* 删除优惠行程表
* 删除优惠行程表
...
...
api-merchant/src/main/java/com/jumeirah/api/merchant/entity/param/McStrokeDiscountAddParam.java
View file @
16e45ee4
package
com
.
jumeirah
.
api
.
merchant
.
entity
.
param
;
package
com
.
jumeirah
.
api
.
merchant
.
entity
.
param
;
import
io.geekidea.springbootplus.framework.common.entity.BaseEntity
;
import
io.geekidea.springbootplus.framework.common.entity.BaseEntity
;
import
io.geekidea.springbootplus.framework.core.validator.groups.Update
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -23,6 +24,10 @@ import java.math.BigDecimal;
...
@@ -23,6 +24,10 @@ import java.math.BigDecimal;
public
class
McStrokeDiscountAddParam
extends
BaseEntity
{
public
class
McStrokeDiscountAddParam
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
@NotNull
(
message
=
"id不能为空"
,
groups
=
{
Update
.
class
})
@ApiModelProperty
(
"主键ID"
)
private
Long
id
;
@NotNull
(
message
=
"出发城市id不能为空"
)
@NotNull
(
message
=
"出发城市id不能为空"
)
@ApiModelProperty
(
"出发城市id"
)
@ApiModelProperty
(
"出发城市id"
)
private
Long
cityOutsetId
;
private
Long
cityOutsetId
;
...
...
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