Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
afanti-open-api
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
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
java-ms
afanti-open-api
Commits
170980d3
Commit
170980d3
authored
Dec 05, 2024
by
许润龙
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev-20241205' into 'master'
add:红旗项目门店月度预值接口 See merge request
!67
parents
758c684c
78912ee1
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
91 additions
and
4 deletions
+91
-4
FawOpenController.java
...afanticar/afantiopenapi/controller/FawOpenController.java
+16
-0
HongqiProjectStoreExpectedValueInfoMapper.java
...api/mapper/HongqiProjectStoreExpectedValueInfoMapper.java
+12
-0
HongqiProjectStoreExpectedValueInfo.java
...api/model/entity/HongqiProjectStoreExpectedValueInfo.java
+44
-0
FawOpenService.java
...a/com/afanticar/afantiopenapi/service/FawOpenService.java
+19
-4
No files found.
src/main/java/com/afanticar/afantiopenapi/controller/FawOpenController.java
View file @
170980d3
...
...
@@ -8,6 +8,7 @@ import com.afanticar.activity.domain.vo.ApiActivityInfoVO;
import
com.afanticar.afantiopenapi.constant.Constant
;
import
com.afanticar.afantiopenapi.model.BaseResponse
;
import
com.afanticar.afantiopenapi.model.dto.FawActivityDTO
;
import
com.afanticar.afantiopenapi.model.entity.HongqiProjectStoreExpectedValueInfo
;
import
com.afanticar.afantiopenapi.model.vo.*
;
import
com.afanticar.afantiopenapi.service.BaseService
;
import
com.afanticar.afantiopenapi.service.FawOpenService
;
...
...
@@ -87,6 +88,21 @@ public class FawOpenController extends BaseController {
static
String
monthly
=
"monthly"
,
quarter
=
"quarter"
;
@ApiOperation
(
value
=
"红旗项目门店月度预值"
,
notes
=
"红旗项目门店月度预值"
,
produces
=
"application/json"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
name
=
"store_code"
,
value
=
"门店编码"
,
paramType
=
"path"
,
dataType
=
"String"
),
@ApiImplicitParam
(
name
=
"expected_month"
,
value
=
"预值月份"
,
paramType
=
"path"
,
dataType
=
"Integer"
),
@ApiImplicitParam
(
name
=
"current_page"
,
value
=
"页码"
,
paramType
=
"path"
,
dataType
=
"Integer"
),
@ApiImplicitParam
(
name
=
"page_size"
,
value
=
"页数"
,
paramType
=
"path"
,
dataType
=
"Integer"
),
})
@GetMapping
(
"/statistics"
)
public
BaseResponse
<
BasePageVO
<
HongqiProjectStoreExpectedValueInfo
>>
getStatisticsInfo
(
@Max
(
value
=
500
,
message
=
"单页数据page_size过大"
)
@RequestParam
(
name
=
"page_size"
,
defaultValue
=
"100"
,
required
=
false
)
Integer
pageSize
,
@RequestParam
(
name
=
"current_page"
,
defaultValue
=
"1"
,
required
=
false
)
Integer
pageNum
,
@RequestParam
(
name
=
"store_code"
,
required
=
false
)
String
storeCode
,
@RequestParam
(
name
=
"expected_month"
,
required
=
false
)
Integer
expectedMonth
)
{
return
success
(
fawOpenService
.
getStatisticsInfo
(
storeCode
,
expectedMonth
,
pageNum
,
pageSize
));
}
@ApiOperation
(
value
=
"视频数据信息"
,
notes
=
"视频数据"
,
produces
=
"application/json"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
name
=
"publish_date_start"
,
value
=
"开始时间,格式:2023-02-01 00:00:00"
,
required
=
true
,
paramType
=
"path"
,
dataType
=
"Date"
),
...
...
src/main/java/com/afanticar/afantiopenapi/mapper/HongqiProjectStoreExpectedValueInfoMapper.java
0 → 100644
View file @
170980d3
package
com
.
afanticar
.
afantiopenapi
.
mapper
;
import
com.afanticar.afantiopenapi.model.entity.HongqiProjectStoreExpectedValueInfo
;
import
com.baomidou.dynamic.datasource.annotation.DS
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
org.apache.ibatis.annotations.Mapper
;
@Mapper
@DS
(
"tmp"
)
public
interface
HongqiProjectStoreExpectedValueInfoMapper
extends
BaseMapper
<
HongqiProjectStoreExpectedValueInfo
>
{
}
src/main/java/com/afanticar/afantiopenapi/model/entity/HongqiProjectStoreExpectedValueInfo.java
0 → 100644
View file @
170980d3
package
com
.
afanticar
.
afantiopenapi
.
model
.
entity
;
import
com.alibaba.fastjson.annotation.JSONType
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.fasterxml.jackson.databind.annotation.JsonNaming
;
import
lombok.Data
;
import
org.springframework.data.annotation.Id
;
import
java.math.BigDecimal
;
import
java.util.Date
;
/**
* 红旗项目门店月度预值表
*/
@Data
@TableName
(
"hongqi_project_store_expected_value_info"
)
@JsonNaming
(
value
=
com
.
fasterxml
.
jackson
.
databind
.
PropertyNamingStrategy
.
SnakeCaseStrategy
.
class
)
@JSONType
(
naming
=
com
.
alibaba
.
fastjson
.
PropertyNamingStrategy
.
SnakeCase
)
public
class
HongqiProjectStoreExpectedValueInfo
{
@Id
private
Integer
id
;
private
String
groupName
;
private
String
storeCode
;
private
String
storeName
;
private
Integer
expectedMonth
;
private
BigDecimal
dailyAwemeValue
;
private
BigDecimal
dailyLiveValue
;
private
BigDecimal
hotAwemeValue
;
private
BigDecimal
hotLiveValue
;
private
BigDecimal
growthIncentiveValue
;
private
BigDecimal
negativeIncentiveValue
;
private
BigDecimal
teamIncentiveValue
;
private
BigDecimal
specialProjectValue
;
private
BigDecimal
innovateAwemeRechargeValue
;
private
BigDecimal
replyMinute3Rate
;
private
BigDecimal
msgConversionRate
;
private
BigDecimal
cpl
;
private
BigDecimal
innovateAwemeValue
;
private
BigDecimal
hotLiveLineValue
;
private
Date
ctime
;
private
Date
mtime
;
}
src/main/java/com/afanticar/afantiopenapi/service/FawOpenService.java
View file @
170980d3
...
...
@@ -4,16 +4,14 @@ import com.afanticar.afantiopenapi.mapper.*;
import
com.afanticar.afantiopenapi.mapper.struct.HongqiAwemeIncentiveStructMapper
;
import
com.afanticar.afantiopenapi.mapper.struct.HongqiLiveIncentiveStructMapper
;
import
com.afanticar.afantiopenapi.model.dto.FawActivityDTO
;
import
com.afanticar.afantiopenapi.model.entity.HongqiAwemeIncentiveMonthly
;
import
com.afanticar.afantiopenapi.model.entity.HongqiAwemeIncentiveQuarter
;
import
com.afanticar.afantiopenapi.model.entity.HongqiLiveIncentiveMonthly
;
import
com.afanticar.afantiopenapi.model.entity.HongqiLiveIncentiveQuarter
;
import
com.afanticar.afantiopenapi.model.entity.*
;
import
com.afanticar.afantiopenapi.model.vo.*
;
import
com.afanticar.afantiopenapi.utils.BaseUtils
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.github.pagehelper.PageHelper
;
import
org.apache.commons.lang3.StringUtils
;
import
org.mapstruct.factory.Mappers
;
import
org.springframework.stereotype.Service
;
...
...
@@ -45,10 +43,27 @@ public class FawOpenService {
@Resource
DwdKuaishouAuthorInfoMapper
dwdKuaishouAuthorInfoMapper
;
@Resource
HongqiProjectStoreExpectedValueInfoMapper
hongqiProjectStoreExpectedValueInfoMapper
;
static
String
monthly
=
"monthly"
;
static
String
quarter
=
"quarter"
;
public
BasePageVO
<
HongqiProjectStoreExpectedValueInfo
>
getStatisticsInfo
(
String
storeCode
,
Integer
expectedMonth
,
Integer
pageNum
,
Integer
pageSize
)
{
PageHelper
.
orderBy
(
" expected_month desc "
);
IPage
<
HongqiProjectStoreExpectedValueInfo
>
page
=
new
Page
<>(
pageNum
,
pageSize
);
QueryWrapper
<
HongqiProjectStoreExpectedValueInfo
>
queryWrapper
=
new
QueryWrapper
<>();
if
(
StringUtils
.
isNotBlank
(
storeCode
))
{
queryWrapper
.
eq
(
"store_code"
,
storeCode
);
}
if
(
expectedMonth
!=
null
)
{
queryWrapper
.
eq
(
"expected_month"
,
expectedMonth
);
}
IPage
<
HongqiProjectStoreExpectedValueInfo
>
awemePage
=
hongqiProjectStoreExpectedValueInfoMapper
.
selectPage
(
page
,
queryWrapper
);
return
BasePageVO
.
restPage
(
pageNum
,
(
int
)
awemePage
.
getSize
(),
(
int
)
awemePage
.
getTotal
(),
(
int
)
awemePage
.
getPages
(),
awemePage
.
getRecords
());
}
public
BasePageVO
<
HongqiAwemeIncentiveVO
>
awemes
(
Date
publishDateStart
,
Date
publishDateEnd
,
String
type
,
Integer
pageNum
,
Integer
pageSize
)
{
try
{
TimeUnit
.
MILLISECONDS
.
sleep
(
500L
);
...
...
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