Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gogirl-miniapp-backend
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
huluobin
gogirl-miniapp-backend
Commits
64d781b1
Commit
64d781b1
authored
Apr 07, 2020
by
huluobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
后台访问请求头
parent
a77a7c1d
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
30 additions
and
23 deletions
+30
-23
Career.java
src/main/java/com/gogirl/domain/store/career/Career.java
+9
-8
GetTechnicianPageRequest.java
...n/java/com/gogirl/dto/admin/GetTechnicianPageRequest.java
+7
-2
Schedule.java
...ain/java/com/gogirl/infrastructure/schedule/Schedule.java
+13
-12
application-pre.yml
src/main/resources/application-pre.yml
+1
-1
No files found.
src/main/java/com/gogirl/domain/store/career/Career.java
View file @
64d781b1
...
@@ -10,6 +10,7 @@ import lombok.Builder;
...
@@ -10,6 +10,7 @@ import lombok.Builder;
import
lombok.Data
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
lombok.NoArgsConstructor
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
java.util.Date
;
@TableName
(
"career"
)
@TableName
(
"career"
)
...
@@ -58,28 +59,28 @@ public class Career {
...
@@ -58,28 +59,28 @@ public class Career {
private
Integer
totalBalanceCardNum
;
private
Integer
totalBalanceCardNum
;
@ApiModelProperty
(
"客户好评率"
)
@ApiModelProperty
(
"客户好评率"
)
private
Double
monthPraisePercent
;
private
BigDecimal
monthPraisePercent
;
@ApiModelProperty
(
"复购率"
)
@ApiModelProperty
(
"复购率"
)
private
Double
monthRepurchasePercent
;
private
BigDecimal
monthRepurchasePercent
;
@ApiModelProperty
(
"信息录入完整度"
)
@ApiModelProperty
(
"信息录入完整度"
)
private
Double
monthInfoPercent
;
private
BigDecimal
monthInfoPercent
;
@ApiModelProperty
(
"考勤准时率"
)
@ApiModelProperty
(
"考勤准时率"
)
private
Double
monthAttendancePercent
;
private
BigDecimal
monthAttendancePercent
;
@ApiModelProperty
(
"客户好评率"
)
@ApiModelProperty
(
"客户好评率"
)
private
Double
totalPraisePercent
;
private
BigDecimal
totalPraisePercent
;
@ApiModelProperty
(
"复购率"
)
@ApiModelProperty
(
"复购率"
)
private
Double
totalRepurchasePercent
;
private
BigDecimal
totalRepurchasePercent
;
@ApiModelProperty
(
"信息录入完整度"
)
@ApiModelProperty
(
"信息录入完整度"
)
private
Double
totalInfoPercent
;
private
BigDecimal
totalInfoPercent
;
@ApiModelProperty
(
"考勤准时率"
)
@ApiModelProperty
(
"考勤准时率"
)
private
Double
totalAttendancePercent
;
private
BigDecimal
totalAttendancePercent
;
@ApiModelProperty
(
"美甲师评分"
)
@ApiModelProperty
(
"美甲师评分"
)
...
...
src/main/java/com/gogirl/dto/admin/GetTechnicianPageRequest.java
View file @
64d781b1
...
@@ -3,7 +3,6 @@ package com.gogirl.dto.admin;
...
@@ -3,7 +3,6 @@ package com.gogirl.dto.admin;
import
lombok.Builder
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.Data
;
import
java.time.LocalDateTime
;
import
java.util.List
;
import
java.util.List
;
@Data
@Data
...
@@ -39,8 +38,14 @@ public class GetTechnicianPageRequest {
...
@@ -39,8 +38,14 @@ public class GetTechnicianPageRequest {
private
String
sord
;
private
String
sord
;
private
List
<
LocalDateTime
>
date_utc
;
/**
* 时间区间
*/
private
List
<
String
>
date_utc
;
/**
* 美甲师id
*/
private
Integer
technician_id
;
private
Integer
technician_id
;
...
...
src/main/java/com/gogirl/infrastructure/schedule/Schedule.java
View file @
64d781b1
...
@@ -26,6 +26,7 @@ import com.gogirl.dto.admin.AdminPage;
...
@@ -26,6 +26,7 @@ import com.gogirl.dto.admin.AdminPage;
import
com.gogirl.dto.admin.AdminResult
;
import
com.gogirl.dto.admin.AdminResult
;
import
com.gogirl.dto.admin.AdminTechnicianScore
;
import
com.gogirl.dto.admin.AdminTechnicianScore
;
import
com.gogirl.dto.admin.GetTechnicianPageRequest
;
import
com.gogirl.dto.admin.GetTechnicianPageRequest
;
import
com.gogirl.infrastructure.common.util.JsonUtilByJackson
;
import
com.gogirl.infrastructure.common.util.ListUtil
;
import
com.gogirl.infrastructure.common.util.ListUtil
;
import
com.gogirl.infrastructure.config.property.GogirlProperties
;
import
com.gogirl.infrastructure.config.property.GogirlProperties
;
import
com.gogirl.infrastructure.mapper.market.coupon.CouponCustomerRelevanceMapper
;
import
com.gogirl.infrastructure.mapper.market.coupon.CouponCustomerRelevanceMapper
;
...
@@ -383,12 +384,12 @@ public class Schedule {
...
@@ -383,12 +384,12 @@ public class Schedule {
.
sord
(
"asc"
)
.
sord
(
"asc"
)
//在职
//在职
.
status
(
1
)
.
status
(
1
)
.
date_utc
(
Lists
.
newArrayList
(
LocalDateTime
.
of
(
LocalDate
.
of
(
2020
,
4
,
1
),
LocalTime
.
of
(
0
,
0
))
,
LocalDateTime
.
now
()))
.
date_utc
(
Lists
.
newArrayList
(
LocalDateTime
.
of
(
LocalDate
.
of
(
2020
,
4
,
1
),
LocalTime
.
of
(
0
,
0
))
.
toString
(),
LocalDateTime
.
now
().
toString
()))
.
technician_id
(
storeTechnician
.
getId
())
.
technician_id
(
storeTechnician
.
getId
())
.
build
();
.
build
();
HttpEntity
<
GetTechnicianPageRequest
>
monthHttpEntity
=
new
HttpEntity
<>(
monthRequest
,
headers
);
HttpEntity
<
GetTechnicianPageRequest
>
monthHttpEntity
=
new
HttpEntity
<>(
monthRequest
,
headers
);
log
.
debug
(
JsonUtilByJackson
.
writeValueAsString
(
monthRequest
));
AdminTechnicianScore
allAdminResult
=
restTemplate
.
exchange
(
gogirlProperties
.
getAdminBackendUrl
(),
HttpMethod
.
POST
,
monthHttpEntity
,
responseBodyType
)
AdminTechnicianScore
allAdminResult
=
restTemplate
.
exchange
(
gogirlProperties
.
getAdminBackendUrl
(),
HttpMethod
.
POST
,
monthHttpEntity
,
responseBodyType
)
.
getBody
()
.
getBody
()
.
getData
()
.
getData
()
...
@@ -422,22 +423,22 @@ public class Schedule {
...
@@ -422,22 +423,22 @@ public class Schedule {
//考勤准时
//考勤准时
career
.
setMonthAttendancePercent
(
null
);
career
.
setMonthAttendancePercent
(
null
);
//信息录入完整度
//信息录入完整度
career
.
setMonthInfoPercent
(
monthAdminResult
.
getAvg_data_integrity
()
.
doubleValue
()
);
career
.
setMonthInfoPercent
(
monthAdminResult
.
getAvg_data_integrity
());
//当月订单总数
//当月订单总数
Integer
monthOrderNum
=
careerMapper
.
queryMonthOrderNum
(
storeTechnician
.
getId
(),
month
);
Integer
monthOrderNum
=
careerMapper
.
queryMonthOrderNum
(
storeTechnician
.
getId
(),
month
);
career
.
setMonthOrderNum
(
monthOrderNum
);
career
.
setMonthOrderNum
(
monthOrderNum
);
//客户好评率
//客户好评率
career
.
setMonthPraisePercent
(
monthAdminResult
.
getPraise_proportion
()
.
doubleValue
()
);
career
.
setMonthPraisePercent
(
monthAdminResult
.
getPraise_proportion
());
//当月复购率
//当月复购率
//复购率
//复购率
Integer
monthRepurchaseNum
=
careerMapper
.
queryMonthAgainOrderNum
(
storeTechnician
.
getId
(),
month
);
Integer
monthRepurchaseNum
=
careerMapper
.
queryMonthAgainOrderNum
(
storeTechnician
.
getId
(),
month
);
if
(
monthOrderNum
!=
null
&&
monthOrderNum
!=
0
)
{
if
(
monthOrderNum
!=
null
&&
monthOrderNum
!=
0
)
{
career
.
setMonthRepurchasePercent
((
double
)
monthRepurchaseNum
/
monthOrderNum
);
//
career.setMonthRepurchasePercent((double) monthRepurchaseNum / monthOrderNum);
}
}
career
.
setMonthRepurchasePercent
(
monthAdminResult
.
getRepeat_purchase_client_roportion
()
.
doubleValue
()
);
career
.
setMonthRepurchasePercent
(
monthAdminResult
.
getRepeat_purchase_client_roportion
());
//当月服务客户总数
//当月服务客户总数
Integer
monthServeCustomerNum
=
careerMapper
.
queryMonthServeCustomerNum
(
storeTechnician
.
getId
(),
month
);
Integer
monthServeCustomerNum
=
careerMapper
.
queryMonthServeCustomerNum
(
storeTechnician
.
getId
(),
month
);
...
@@ -447,7 +448,7 @@ public class Schedule {
...
@@ -447,7 +448,7 @@ public class Schedule {
career
.
setMonthServeNum
(
monthAdminResult
.
getTotal_service_count
());
career
.
setMonthServeNum
(
monthAdminResult
.
getTotal_service_count
());
//信息录入完整度
//信息录入完整度
career
.
setMonthInfoPercent
(
monthAdminResult
.
getAvg_data_integrity
()
.
doubleValue
()
);
career
.
setMonthInfoPercent
(
monthAdminResult
.
getAvg_data_integrity
());
//总考勤准时率
//总考勤准时率
career
.
setTotalAttendancePercent
(
null
);
career
.
setTotalAttendancePercent
(
null
);
...
@@ -459,7 +460,7 @@ public class Schedule {
...
@@ -459,7 +460,7 @@ public class Schedule {
career
.
setTotalBalanceCardNum
(
allAdminResult
.
getCard_count
());
career
.
setTotalBalanceCardNum
(
allAdminResult
.
getCard_count
());
//信息录入完整度
//信息录入完整度
career
.
setTotalInfoPercent
(
allAdminResult
.
getAvg_data_integrity
()
.
doubleValue
()
);
career
.
setTotalInfoPercent
(
allAdminResult
.
getAvg_data_integrity
());
//订单总数
//订单总数
Integer
totalOrderNum
=
careerMapper
.
queryTotalOrderNum
(
storeTechnician
.
getId
(),
month
);
Integer
totalOrderNum
=
careerMapper
.
queryTotalOrderNum
(
storeTechnician
.
getId
(),
month
);
...
@@ -469,17 +470,17 @@ public class Schedule {
...
@@ -469,17 +470,17 @@ public class Schedule {
Double
totalPraisePercent
=
careerMapper
.
queryTotalPraisePercent
(
storeTechnician
.
getId
());
Double
totalPraisePercent
=
careerMapper
.
queryTotalPraisePercent
(
storeTechnician
.
getId
());
//总好评率
//总好评率
career
.
setTotalPraisePercent
(
allAdminResult
.
getPraise_proportion
()
.
doubleValue
()
);
career
.
setTotalPraisePercent
(
allAdminResult
.
getPraise_proportion
());
//总考勤准时比率
//总考勤准时比率
career
.
setTotalAttendancePercent
(
storeTechnician
.
getInformationIntegrity
()
);
career
.
setTotalAttendancePercent
(
null
);
//复购率
//复购率
Integer
totalRepurchaseNum
=
careerMapper
.
queryTotalAgainOrderNum
(
storeTechnician
.
getId
(),
month
);
Integer
totalRepurchaseNum
=
careerMapper
.
queryTotalAgainOrderNum
(
storeTechnician
.
getId
(),
month
);
if
(
totalOrderNum
!=
null
&&
totalOrderNum
!=
0
)
{
if
(
totalOrderNum
!=
null
&&
totalOrderNum
!=
0
)
{
career
.
setTotalRepurchasePercent
((
double
)
totalRepurchaseNum
/
totalOrderNum
);
//
career.setTotalRepurchasePercent((double) totalRepurchaseNum / totalOrderNum);
}
}
career
.
setTotalRepurchasePercent
(
allAdminResult
.
getRepeat_purchase_client_roportion
()
.
doubleValue
()
);
career
.
setTotalRepurchasePercent
(
allAdminResult
.
getRepeat_purchase_client_roportion
());
//服务客户总数
//服务客户总数
Integer
totalServeCustomerNum
=
careerMapper
.
queryTotalServeCustomerNum
(
storeTechnician
.
getId
(),
month
);
Integer
totalServeCustomerNum
=
careerMapper
.
queryTotalServeCustomerNum
(
storeTechnician
.
getId
(),
month
);
...
...
src/main/resources/application-pre.yml
View file @
64d781b1
...
@@ -80,7 +80,7 @@ gogirl:
...
@@ -80,7 +80,7 @@ gogirl:
#门店上班时间
#门店上班时间
start-time
:
"
10:00:00"
start-time
:
"
10:00:00"
#评论延迟时间
#评论延迟时间
test-paper-time
:
1
440
test-paper-time
:
1
#后台后端接口访问地址
#后台后端接口访问地址
admin-backend-url
:
http://test.admin.begogirls.com:7712/api/ReportTable/GetTechnicianPage
admin-backend-url
:
http://test.admin.begogirls.com:7712/api/ReportTable/GetTechnicianPage
wx
:
wx
:
...
...
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