Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
N
nyx
概览
Overview
Details
Activity
Cycle Analytics
版本库
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
问题
0
Issues
0
列表
Board
标记
里程碑
合并请求
0
Merge Requests
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
Snippets
成员
Collapse sidebar
Close sidebar
活动
图像
聊天
创建新问题
作业
提交
Issue Boards
Open sidebar
发现
nyx
Commits
aa91d073
Commit
aa91d073
authored
Aug 05, 2020
by
jscat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
nyx javaapp 功能更新
1. 添加用activityId获取view_activity_info的功能及接口
parent
5075d32a
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
58 行增加
和
8 行删除
+58
-8
增值产品-小程序及app/nyx_app_key/api/src/main/java/cn/com/fun/nyxkey/api/repository/Rockwell_keyMapper.java
+2
-1
增值产品-小程序及app/nyx_app_key/api/src/main/java/cn/com/fun/nyxkey/api/service/Rockwell_keyService.java
+3
-1
增值产品-小程序及app/nyx_app_key/api/src/main/java/cn/com/fun/nyxkey/api/service/impl/Rockwell_keyServiceImpl.java
+26
-1
增值产品-小程序及app/nyx_app_key/api/src/main/java/cn/com/fun/nyxkey/api/web/controller/NyxApiController.java
+14
-2
增值产品-小程序及app/nyx_app_key/api/src/main/resources/cn/com/fun/nyxkey/api/repository/Rockwell_keyMapper.xml
+13
-3
没有找到文件。
增值产品-小程序及app/nyx_app_key/api/src/main/java/cn/com/fun/nyxkey/api/repository/Rockwell_keyMapper.java
查看文件 @
aa91d073
packa
ge
cn
.
com
.
fun
.
nyxkey
.
api
.
repository
;
packa
ge
cn
.
com
.
fun
.
nyxkey
.
api
.
repository
;
...
...
@@ -35,6 +35,7 @@ public interface Rockwell_keyMapper {
/* activity api */
List
<
Rockwell_keyV_activity_info
>
getV_activity_info_by_page
(
Rockwell_keyT_activityQuery
rockwell_keyT_activityQuery
);
List
<
Rockwell_keyV_activity_info
>
getV_activity_info_by_id
(
Rockwell_keyT_activityQuery
rockwell_keyT_activityQuery
);
/* post api */
...
...
增值产品-小程序及app/nyx_app_key/api/src/main/java/cn/com/fun/nyxkey/api/service/Rockwell_keyService.java
查看文件 @
aa91d073
packa
ge
cn
.
com
.
fun
.
nyxkey
.
api
.
service
;
packa
ge
cn
.
com
.
fun
.
nyxkey
.
api
.
service
;
...
...
@@ -45,6 +45,8 @@ public interface Rockwell_keyService {
String
memberId
,
String
memberName
,
String
memberStatus
,
int
pageNum
,
int
pageCount
);
JSONResult
Rockwell_keyServiceGetV_activity_info_by_id
(
String
activityId
);
/* post api */
JSONResult
Rockwell_keyServiceGetV_post_info
(
String
tag
,
String
title
,
String
top
,
int
pageNum
,
int
pageCount
);
/* todo 添加新增pos功能
...
...
增值产品-小程序及app/nyx_app_key/api/src/main/java/cn/com/fun/nyxkey/api/service/impl/Rockwell_keyServiceImpl.java
查看文件 @
aa91d073
packa
ge
cn
.
com
.
fun
.
nyxkey
.
api
.
service
.
impl
;
packa
ge
cn
.
com
.
fun
.
nyxkey
.
api
.
service
.
impl
;
...
...
@@ -289,6 +289,31 @@ public class Rockwell_keyServiceImpl implements Rockwell_keyService {
return
jsonResult
;
}
/* activity api
* 通过 activityId 来获取 view_activity_info 的详细信息
*
* */
public
JSONResult
Rockwell_keyServiceGetV_activity_info_by_id
(
String
activityId
)
{
LOGGER
.
debug
(
"find Rockwell_keyServiceGetV_activity_info_by_id"
);
List
<
Rockwell_keyV_activity_info
>
listRockwell_keyV_activity_info
=
new
ArrayList
<>();
Rockwell_keyT_activityQuery
rockwell_keyT_activityQuery
=
new
Rockwell_keyT_activityQuery
();
//判断某字符串是否为空,为空的标准是 str==null 或 str.length()==0
//默认设置memberStatus=="01"
if
(
StringUtils
.
isEmpty
(
activityId
)
||
activityId
.
equals
(
"0"
))
{
return
new
JSONResult
(
ExceptionMsg
.
ParamError
);
}
rockwell_keyT_activityQuery
.
setActivityId
(
activityId
);
listRockwell_keyV_activity_info
=
rockwell_keyMapper
.
getV_activity_info_by_id
(
rockwell_keyT_activityQuery
);
int
totalCount
=
listRockwell_keyV_activity_info
.
size
();
JSONResult
jsonResult
=
new
JSONResult
(
totalCount
,
listRockwell_keyV_activity_info
);
return
jsonResult
;
}
/* post api */
// getV_post_info
public
JSONResult
Rockwell_keyServiceGetV_post_info
(
String
tag
,
String
title
,
String
top
,
int
pageNum
,
int
pageCount
)
...
...
增值产品-小程序及app/nyx_app_key/api/src/main/java/cn/com/fun/nyxkey/api/web/controller/NyxApiController.java
查看文件 @
aa91d073
packa
ge
cn
.
com
.
fun
.
nyxkey
.
api
.
web
.
controller
;
packa
ge
cn
.
com
.
fun
.
nyxkey
.
api
.
web
.
controller
;
...
...
@@ -242,7 +242,7 @@ public class NyxApiController {
}
// APi3 tbl_activity接口 jscat 20200804
// 3.1 获取 view_activity_info的数据 by page, not by activityId
// 3.1 获取 view_activity_info
的数据 by page, not by activityId
@ApiOperation
(
value
=
"获取商家的activity info"
,
notes
=
"获取商家的activity info"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
name
=
"tag"
,
value
=
"按标签查找; 饮事"
,
required
=
false
,
dataType
=
"String"
),
...
...
@@ -266,6 +266,18 @@ public class NyxApiController {
return
keyService
.
Rockwell_keyServiceGetV_activity_info
(
tag
,
title
,
memberId
,
memberName
,
memberStatus
,
pageNum
,
pageCount
);
}
// 3.2 获取 view_activity_info 的数据 by activityId
@ApiOperation
(
value
=
"获取商家的activity info by activityId"
,
notes
=
"获取商家的activity info by activityId"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
name
=
"activityId"
,
value
=
"按活动id查找"
,
required
=
true
,
dataType
=
"String"
)
})
@RequestMapping
(
value
=
"/nyx/activity/query/id"
,
method
=
RequestMethod
.
GET
)
public
JSONResult
RockwellQueryActivityById
(
@RequestParam
(
value
=
"activityId"
,
required
=
true
,
defaultValue
=
"0"
)
String
activityId
)
{
return
keyService
.
Rockwell_keyServiceGetV_activity_info_by_id
(
activityId
);
}
// 4.0 post info api
@ApiOperation
(
value
=
"获取用户的post info"
,
notes
=
"获取用户的post info"
)
@ApiImplicitParams
({
...
...
增值产品-小程序及app/nyx_app_key/api/src/main/resources/cn/com/fun/nyxkey/api/repository/Rockwell_keyMapper.xml
查看文件 @
aa91d073
<?xml
version="1.0" encoding="UTF-8"?>
<?xml
version="1.0" encoding="UTF-8"?>
...
...
@@ -214,7 +214,7 @@ limitations under the License.
</if>
</select>
<!-- activity api 2-1 获取 v_activity_info 的值 update jscat 20200804 -->
<!-- activity api 2-1 获取 v_activity_info 的值
by page
update jscat 20200804 -->
<select
id=
"getV_activity_info_by_page"
parameterType=
"cn.com.fun.nyxkey.api.domain.query.Rockwell_keyT_activityQuery"
resultType=
"cn.com.fun.nyxkey.api.domain.Rockwell_keyV_activity_info"
>
select * from view_activity_info
...
...
@@ -229,7 +229,7 @@ limitations under the License.
AND member_name=#{memberName}
</if>
<if
test=
"tag != null and tag != '' "
>
AND tag
=#{tag}
AND tag
LIKE CONCAT('%', #{tag} ,'%')
</if>
<if
test=
"title != null and title != '' "
>
AND ( tag LIKE CONCAT('%', #{title} ,'%') OR title LIKE CONCAT('%', #{title} ,'%') OR member_name LIKE CONCAT('%', #{title} ,'%') )
...
...
@@ -239,6 +239,16 @@ limitations under the License.
</if>
</select>
<!-- activity api 2-2 获取 v_activity_info 的值 by id update jscat 20200805 -->
<select
id=
"getV_activity_info_by_id"
parameterType=
"cn.com.fun.nyxkey.api.domain.query.Rockwell_keyT_activityQuery"
resultType=
"cn.com.fun.nyxkey.api.domain.Rockwell_keyV_activity_info"
>
select * from view_activity_info
where 1=1
<if
test=
"activityId != null and activityId != '' "
>
AND activity_id=#{activityId}
</if>
</select>
<!-- post api 4.1 从 view_post_info 获取 post信息
-->
<select
id=
"getV_post_info"
parameterType=
"cn.com.fun.nyxkey.api.domain.query.Rockwell_keyT_postQuery"
resultType=
"cn.com.fun.nyxkey.api.domain.Rockwell_keyV_post_info"
>
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论