Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
rs-cloud-platform
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
周健威
rs-cloud-platform
Commits
0588dc12
Commit
0588dc12
authored
Dec 22, 2020
by
unset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加意见反馈添加信息
parent
dfc09604
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
89 additions
and
2 deletions
+89
-2
FeedbackInfoDto.java
...a/com/upyuns/platform/rs/website/dto/FeedbackInfoDto.java
+21
-0
FeedbackInfoBiz.java
...a/com/upyuns/platform/rs/website/biz/FeedbackInfoBiz.java
+52
-1
FeedbackInfoController.java
...latform/rs/website/controller/FeedbackInfoController.java
+8
-1
FeedbackInfoWebController.java
.../rs/website/controller/web/FeedbackInfoWebController.java
+8
-0
No files found.
rs-website/rs-website-api/src/main/java/com/upyuns/platform/rs/website/dto/FeedbackInfoDto.java
0 → 100644
View file @
0588dc12
package
com
.
upyuns
.
platform
.
rs
.
website
.
dto
;
import
com.github.wxiaoqi.security.common.vo.PageParam
;
import
lombok.Data
;
/**
* @ClassName : FeedbackInfoDto
* @Description : 反馈信息
* @Author : jiaoruizhen
* @Date: 2020-12-22 13:51
*/
@Data
public
class
FeedbackInfoDto
extends
PageParam
{
Integer
type
;
Integer
userId
;
String
keywords
;
}
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/biz/FeedbackInfoBiz.java
View file @
0588dc12
package
com
.
upyuns
.
platform
.
rs
.
website
.
biz
;
package
com
.
upyuns
.
platform
.
rs
.
website
.
biz
;
import
com.github.wxiaoqi.security.admin.feign.UserFeign
;
import
com.github.wxiaoqi.security.admin.feign.dto.AppUserDTO
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.util.Query
;
import
com.github.wxiaoqi.security.common.util.process.ResultCode
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.upyuns.platform.rs.website.dto.FeedbackInfoDto
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
com.upyuns.platform.rs.website.entity.FeedbackInfo
;
import
com.upyuns.platform.rs.website.entity.FeedbackInfo
;
import
com.upyuns.platform.rs.website.mapper.FeedbackInfoMapper
;
import
com.upyuns.platform.rs.website.mapper.FeedbackInfoMapper
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
tk.mybatis.mapper.entity.Example
;
import
javax.servlet.http.HttpServletRequest
;
/**
/**
* 反馈信息
* 反馈信息
...
@@ -14,5 +26,44 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
...
@@ -14,5 +26,44 @@ import com.github.wxiaoqi.security.common.biz.BaseBiz;
* @date 2020-12-22 13:38:56
* @date 2020-12-22 13:38:56
*/
*/
@Service
@Service
public
class
FeedbackInfoBiz
extends
BaseBiz
<
FeedbackInfoMapper
,
FeedbackInfo
>
{
public
class
FeedbackInfoBiz
extends
BaseBiz
<
FeedbackInfoMapper
,
FeedbackInfo
>
{
@Autowired
UserFeign
userFeign
;
@Autowired
HttpServletRequest
request
;
public
ObjectRestResponse
addObj
(
FeedbackInfo
feedbackInfo
)
{
if
(
feedbackInfo
==
null
)
{
return
ObjectRestResponse
.
paramIsEmpty
();
}
AppUserDTO
appUserDTO
=
userFeign
.
userDetailByToken
(
request
.
getHeader
(
"Authorization"
)).
getData
();
if
(
appUserDTO
==
null
)
{
return
ObjectRestResponse
.
createFailedResult
(
ResultCode
.
RSTOKEN_EXPIRED_CODE
,
ResultCode
.
getMsg
(
ResultCode
.
RSTOKEN_EXPIRED_CODE
));
}
feedbackInfo
.
setUserId
(
appUserDTO
.
getUserid
());
insertSelectiveRe
(
feedbackInfo
);
return
ObjectRestResponse
.
succ
();
}
public
ObjectRestResponse
getAll
(
FeedbackInfoDto
feedbackInfoDto
)
{
Query
query
=
new
Query
(
feedbackInfoDto
);
Example
example
=
new
Example
(
FeedbackInfo
.
class
);
Example
.
Criteria
criteria
=
example
.
createCriteria
();
if
(
feedbackInfoDto
.
getType
()
!=
null
)
{
criteria
.
andEqualTo
(
"type"
,
feedbackInfoDto
.
getType
());
}
if
(
feedbackInfoDto
.
getUserId
()
!=
null
)
{
criteria
.
andEqualTo
(
"userId"
,
feedbackInfoDto
.
getUserId
());
}
if
(
StringUtils
.
isNotBlank
(
feedbackInfoDto
.
getKeywords
()))
{
criteria
.
andLike
(
"name"
,
"%"
+
feedbackInfoDto
.
getKeywords
()
+
"%"
)
.
orLike
(
"phone"
,
"%"
+
feedbackInfoDto
.
getKeywords
()
+
"%"
);
}
PageDataVO
<
FeedbackInfo
>
pageDataVO
=
PageDataVO
.
pageInfo
(
query
,
()
->
mapper
.
selectByExample
(
example
));
return
ObjectRestResponse
.
succ
(
pageDataVO
);
}
}
}
\ No newline at end of file
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/controller/FeedbackInfoController.java
View file @
0588dc12
package
com
.
upyuns
.
platform
.
rs
.
website
.
controller
;
package
com
.
upyuns
.
platform
.
rs
.
website
.
controller
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.upyuns.platform.rs.website.biz.FeedbackInfoBiz
;
import
com.upyuns.platform.rs.website.biz.FeedbackInfoBiz
;
import
com.upyuns.platform.rs.website.dto.FeedbackInfoDto
;
import
com.upyuns.platform.rs.website.entity.FeedbackInfo
;
import
com.upyuns.platform.rs.website.entity.FeedbackInfo
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.bind.annotation.RestController
;
@RestController
@RestController
@RequestMapping
(
"feedbackInfo"
)
@RequestMapping
(
"feedbackInfo"
)
public
class
FeedbackInfoController
extends
BaseController
<
FeedbackInfoBiz
,
FeedbackInfo
>
{
public
class
FeedbackInfoController
extends
BaseController
<
FeedbackInfoBiz
,
FeedbackInfo
>
{
@GetMapping
(
value
=
"getAll"
)
public
ObjectRestResponse
getAll
(
FeedbackInfoDto
feedbackInfoDto
)
{
return
baseBiz
.
getAll
(
feedbackInfoDto
);
}
}
}
\ No newline at end of file
rs-website/rs-website-server/src/main/java/com/upyuns/platform/rs/website/controller/web/FeedbackInfoWebController.java
View file @
0588dc12
package
com
.
upyuns
.
platform
.
rs
.
website
.
controller
.
web
;
package
com
.
upyuns
.
platform
.
rs
.
website
.
controller
.
web
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.upyuns.platform.rs.website.biz.FeedbackInfoBiz
;
import
com.upyuns.platform.rs.website.biz.FeedbackInfoBiz
;
import
com.upyuns.platform.rs.website.entity.FeedbackInfo
;
import
com.upyuns.platform.rs.website.entity.FeedbackInfo
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.bind.annotation.RestController
;
...
@@ -10,4 +13,9 @@ import org.springframework.web.bind.annotation.RestController;
...
@@ -10,4 +13,9 @@ import org.springframework.web.bind.annotation.RestController;
@RequestMapping
(
"feedbackInfo/web"
)
@RequestMapping
(
"feedbackInfo/web"
)
public
class
FeedbackInfoWebController
extends
BaseController
<
FeedbackInfoBiz
,
FeedbackInfo
>
{
public
class
FeedbackInfoWebController
extends
BaseController
<
FeedbackInfoBiz
,
FeedbackInfo
>
{
@PostMapping
(
value
=
"addObj"
)
public
ObjectRestResponse
addObj
(
@RequestBody
FeedbackInfo
feedbackInfo
)
{
return
baseBiz
.
addObj
(
feedbackInfo
);
}
}
}
\ No newline at end of file
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