Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-enterprise-base
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
base_platform_enterprise
gic-enterprise-base
Commits
35c0ced1
Commit
35c0ced1
authored
Jan 09, 2020
by
陶光胜
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
init
parent
ea495937
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
3 deletions
+33
-3
QrcodeTypeEnum.java
.../main/java/com/gic/download/constants/QrcodeTypeEnum.java
+30
-0
QrcodeDownload.java
.../src/main/java/com/gic/download/utils/QrcodeDownload.java
+3
-3
No files found.
gic-enterprise-download/src/main/java/com/gic/download/constants/QrcodeTypeEnum.java
0 → 100644
View file @
35c0ced1
package
com
.
gic
.
download
.
constants
;
public
enum
QrcodeTypeEnum
{
STORE
(
1
,
"门店二维码"
),
CLERK
(
2
,
"导购二维码"
);
QrcodeTypeEnum
(
Integer
type
,
String
desc
){
this
.
type
=
type
;
this
.
desc
=
desc
;
}
private
Integer
type
;
private
String
desc
;
public
Integer
getType
()
{
return
type
;
}
public
void
setType
(
Integer
type
)
{
this
.
type
=
type
;
}
public
String
getDesc
()
{
return
desc
;
}
public
void
setDesc
(
String
desc
)
{
this
.
desc
=
desc
;
}
}
gic-enterprise-download/src/main/java/com/gic/download/utils/QrcodeDownload.java
View file @
35c0ced1
...
...
@@ -56,7 +56,7 @@ public abstract class QrcodeDownload {
private
WeixinWxaFunService
weixinWxaFunService
;
private
QrCodeApiService
qrCodeApiService
;
p
rotected
void
takeQrcode
(
QrcodeQO
qrcodeQO
,
int
total
,
p
ublic
void
takeQrcode
(
QrcodeQO
qrcodeQO
,
int
total
,
DownloadReportApiService
downloadReportApiService
,
WeixinBaseFunService
weixinBaseFunService
,
WeixinWxaFunService
weixinWxaFunService
,
...
...
@@ -87,7 +87,7 @@ public abstract class QrcodeDownload {
ZipOutputStream
zipOutputStream
=
new
ZipOutputStream
(
new
FileOutputStream
(
file
));
int
pages
=
total
%
pageSize
>
0
?
total
/
pageSize
+
1
:
total
/
pageSize
;
for
(
int
i
=
1
;
i
<=
pages
;
i
++){
List
<
QrcodeContent
>
contentList
=
getContent
(
pageSize
);
List
<
QrcodeContent
>
contentList
=
getContent
(
i
,
pageSize
);
if
(
CollectionUtils
.
isEmpty
(
contentList
)){
break
;
}
...
...
@@ -196,7 +196,7 @@ public abstract class QrcodeDownload {
}
protected
abstract
List
<
QrcodeContent
>
getContent
(
int
pageNum
);
protected
abstract
List
<
QrcodeContent
>
getContent
(
int
page
Size
,
int
page
Num
);
private
byte
[]
createQrcode
(
String
url
,
String
logoPic
,
String
logoName
)
{
byte
[]
imageByte
=
null
;
...
...
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