Commit 35c0ced1 by 陶光胜

init

parent ea495937
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;
}
}
...@@ -56,7 +56,7 @@ public abstract class QrcodeDownload { ...@@ -56,7 +56,7 @@ public abstract class QrcodeDownload {
private WeixinWxaFunService weixinWxaFunService; private WeixinWxaFunService weixinWxaFunService;
private QrCodeApiService qrCodeApiService; private QrCodeApiService qrCodeApiService;
protected void takeQrcode(QrcodeQO qrcodeQO, int total, public void takeQrcode(QrcodeQO qrcodeQO, int total,
DownloadReportApiService downloadReportApiService, DownloadReportApiService downloadReportApiService,
WeixinBaseFunService weixinBaseFunService, WeixinBaseFunService weixinBaseFunService,
WeixinWxaFunService weixinWxaFunService, WeixinWxaFunService weixinWxaFunService,
...@@ -87,7 +87,7 @@ public abstract class QrcodeDownload { ...@@ -87,7 +87,7 @@ public abstract class QrcodeDownload {
ZipOutputStream zipOutputStream = new ZipOutputStream(new FileOutputStream(file)); ZipOutputStream zipOutputStream = new ZipOutputStream(new FileOutputStream(file));
int pages = total%pageSize > 0 ? total/pageSize+1 : total/pageSize; int pages = total%pageSize > 0 ? total/pageSize+1 : total/pageSize;
for(int i = 1; i<= pages; i++){ for(int i = 1; i<= pages; i++){
List<QrcodeContent> contentList = getContent(pageSize); List<QrcodeContent> contentList = getContent(i, pageSize);
if(CollectionUtils.isEmpty(contentList)){ if(CollectionUtils.isEmpty(contentList)){
break; break;
} }
...@@ -196,7 +196,7 @@ public abstract class QrcodeDownload { ...@@ -196,7 +196,7 @@ public abstract class QrcodeDownload {
} }
protected abstract List<QrcodeContent> getContent(int pageNum); protected abstract List<QrcodeContent> getContent(int pageSize, int pageNum);
private byte[] createQrcode(String url, String logoPic, String logoName) { private byte[] createQrcode(String url, String logoPic, String logoName) {
byte[] imageByte = null; byte[] imageByte = null;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment