Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
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
youjj
cloud-platform
Commits
37487322
Commit
37487322
authored
Aug 03, 2019
by
周健威
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/base-modify' into base-modify
parents
dbe6fe0e
22ffd63e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
13 deletions
+18
-13
CofigBiz.java
...ver/src/main/java/com/xxfc/platform/app/biz/CofigBiz.java
+18
-13
No files found.
xx-app/xx-app-server/src/main/java/com/xxfc/platform/app/biz/CofigBiz.java
View file @
37487322
...
...
@@ -27,38 +27,43 @@ import java.util.Map;
* @date 2019-06-03 15:57:13
*/
@Service
public
class
CofigBiz
extends
BaseBiz
<
CofigMapper
,
Cofig
>
{
public
class
CofigBiz
extends
BaseBiz
<
CofigMapper
,
Cofig
>
{
public
List
<
Cofig
>
getConfigByType
(
List
<
Integer
>
list
){
return
mapper
.
getAllByType
(
list
);
public
List
<
Cofig
>
getConfigByType
(
List
<
Integer
>
list
)
{
Example
example
=
new
Example
(
Cofig
.
class
);
Example
.
Criteria
criteria
=
example
.
createCriteria
();
criteria
.
andEqualTo
(
"isDel"
,
0
);
criteria
.
andIn
(
"type"
,
list
);
return
mapper
.
selectByExample
(
example
);
}
/**
* 修改配置
*
* @param cofig
* @return
*/
@CacheClear
(
pre
=
"app:withdrawrule{1.type}"
)
public
int
updateConfig
(
Cofig
cofig
)
{
EntityUtils
.
setUpdatedInfo
(
cofig
);
return
mapper
.
updateByPrimaryKeySelective
(
cofig
);
return
mapper
.
updateByPrimaryKeySelective
(
cofig
);
}
@Cache
(
key
=
"app:withdrawrule:88"
)
public
WithDrawRuleVo
getWithDrawRule
(){
public
WithDrawRuleVo
getWithDrawRule
()
{
WithDrawRuleVo
withDrawRuleVo
=
new
WithDrawRuleVo
();
Example
example
=
new
Example
(
Cofig
.
class
);
Example
example
=
new
Example
(
Cofig
.
class
);
Example
.
Criteria
criteria
=
example
.
createCriteria
();
criteria
.
andEqualTo
(
"type"
,
88
);
criteria
.
andEqualTo
(
"type"
,
88
);
List
<
Cofig
>
cofigs
=
mapper
.
selectByExample
(
example
);
if
(
CollectionUtils
.
isEmpty
(
cofigs
)){
if
(
CollectionUtils
.
isEmpty
(
cofigs
))
{
return
withDrawRuleVo
;
}
Cofig
cofig
=
cofigs
.
get
(
0
);
withDrawRuleVo
=
JSON
.
parseObject
(
cofig
.
getParams
(),
WithDrawRuleVo
.
class
);
withDrawRuleVo
.
setDescription
(
cofig
.
getValue
());
return
withDrawRuleVo
;
withDrawRuleVo
=
JSON
.
parseObject
(
cofig
.
getParams
(),
WithDrawRuleVo
.
class
);
withDrawRuleVo
.
setDescription
(
cofig
.
getValue
());
return
withDrawRuleVo
;
}
public
void
updateConfigStatus
(
int
id
)
{
...
...
@@ -72,10 +77,10 @@ public class CofigBiz extends BaseBiz<CofigMapper,Cofig> {
Query
query
=
new
Query
(
params
);
Example
example
=
new
Example
(
Cofig
.
class
);
Example
.
Criteria
criteria
=
example
.
createCriteria
();
criteria
.
andEqualTo
(
"isDel"
,
0
);
criteria
.
andEqualTo
(
"isDel"
,
0
);
PageDataVO
<
Cofig
>
cofigPage
=
PageDataVO
.
pageInfo
(
query
.
getPage
(),
query
.
getLimit
(),
()
->
mapper
.
selectByExample
(
example
));
return
new
TableResultResponse
<>(
cofigPage
.
getTotalCount
(),
cofigPage
.
getData
())
;
return
new
TableResultResponse
<>(
cofigPage
.
getTotalCount
(),
cofigPage
.
getData
())
;
}
}
\ 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