Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Q
qk_backend
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
quanku
qk_backend
Commits
d7fcce8e
Commit
d7fcce8e
authored
May 23, 2024
by
shiyu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
小程序分析数据获取2
parent
5365ef1e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
ch-core/src/main/java/com/wwdz/ch/core/api/WxAppletApi.java
ch-core/src/main/java/com/wwdz/ch/core/api/WxAppletApi.java
+1
-1
ch-core/src/main/java/com/wwdz/ch/core/util/TimeUtil.java
ch-core/src/main/java/com/wwdz/ch/core/util/TimeUtil.java
+6
-6
No files found.
ch-core/src/main/java/com/wwdz/ch/core/api/WxAppletApi.java
View file @
d7fcce8e
...
...
@@ -105,7 +105,7 @@ public class WxAppletApi {
* 获取小程序访问数据
* @param startTime
* @param endTime
* @param
type
* @param
key
* @return
*/
public
Result
getAccessData
(
String
startTime
,
String
endTime
,
String
key
)
{
...
...
ch-core/src/main/java/com/wwdz/ch/core/util/TimeUtil.java
View file @
d7fcce8e
...
...
@@ -47,10 +47,10 @@ public final class TimeUtil {
Calendar
calStart
=
Calendar
.
getInstance
();
Calendar
calEnd
=
Calendar
.
getInstance
();
calStart
.
set
(
Calendar
.
DAY_OF_WEEK
,
Calendar
.
MONDAY
);
calEnd
.
setFirstDayOfWeek
(
Calendar
.
MONDAY
);
calEnd
.
set
(
Calendar
.
DAY_OF_WEEK
,
calEnd
.
getFirstDayOfWeek
()
+
6
);
/*
calEnd.setFirstDayOfWeek(Calendar.MONDAY);
calEnd.set(Calendar.DAY_OF_WEEK, calEnd.getFirstDayOfWeek() + 6);
*/
String
beginDate
=
format
.
format
(
calStart
.
getTime
());
String
endDate
=
format
.
format
(
calEnd
.
getTim
e
());
String
endDate
=
format
.
format
(
new
Dat
e
());
return
Pair
.
of
(
beginDate
,
endDate
);
}
...
...
@@ -96,9 +96,9 @@ public final class TimeUtil {
Calendar
calStart
=
Calendar
.
getInstance
();
Calendar
calEnd
=
Calendar
.
getInstance
();
calStart
.
set
(
Calendar
.
DAY_OF_MONTH
,
1
);
calEnd
.
set
(
Calendar
.
DAY_OF_MONTH
,
calEnd
.
getActualMaximum
(
Calendar
.
DAY_OF_MONTH
));
//
calEnd.set(Calendar.DAY_OF_MONTH, calEnd.getActualMaximum(Calendar.DAY_OF_MONTH));
String
beginDate
=
format
.
format
(
calStart
.
getTime
());
String
endDate
=
format
.
format
(
calEnd
.
getTim
e
());
String
endDate
=
format
.
format
(
new
Dat
e
());
return
Pair
.
of
(
beginDate
,
endDate
);
}
...
...
@@ -123,7 +123,7 @@ public final class TimeUtil {
public
static
void
main
(
String
[]
args
)
{
Pair
<
String
,
String
>
pair
=
getAccessDate
(
5
);
Pair
<
String
,
String
>
pair
=
getAccessDate
(
3
);
System
.
out
.
println
(
pair
.
getFirst
());
System
.
out
.
println
(
pair
.
getSecond
());
}
...
...
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