add qrcode log

master
wangning 7 years ago
parent 2f1abf902a
commit c221156029

@ -4,7 +4,7 @@ import org.springframework.data.mongodb.core.mapping.Document;
import java.util.Date;
@Document(collection = "client_config_log") // here is solution
@Document(collection = "client_config_log")
public class ClientConfigLog {
private long id;

@ -164,7 +164,7 @@ public interface ClientManager {
JSONObject getQRCode(JSONObject manager, String clientMoniker, QRCodeConfig config);
String getQrCodeBoard(JSONObject client, QRCodeConfig config);
String getQrCodeBoard(JSONObject client, QRCodeConfig config,JSONObject account);
void writeAggregateQrCodeBoard(JSONObject manager, String clientMoniker, QRCodeConfig config, OutputStream ous);

@ -120,6 +120,7 @@ import org.springframework.cache.annotation.Cacheable;
import org.springframework.context.ApplicationEventPublisher;
import org.springframework.context.ApplicationEventPublisherAware;
import org.springframework.context.MessageSource;
import org.springframework.data.mongodb.core.MongoTemplate;
import org.springframework.data.redis.core.StringRedisTemplate;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
@ -252,6 +253,8 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
private ClientsOperationLogMapper clientsOperationLogMapper;
@Resource
private ClientInfoCacheSupport clientInfoCacheSupport;
@Resource
private MongoTemplate mongoTemplate;
private static final String SOURCE_AGREE_FILE = "source_agree_file";
private static final String CLIENT_BANK_FILE = "client_bank_file";
@ -1519,9 +1522,9 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
}
@Override
public String getQrCodeBoard(JSONObject client, QRCodeConfig config) {
public String getQrCodeBoard(JSONObject client, QRCodeConfig config,JSONObject account) {
// JSONObject org = orgMapper.findOne(client.getIntValue("org_id"));
return merchantInfoProvider.getQrCodeBoard(client, config);
return merchantInfoProvider.getQrCodeBoard(client, config,account);
}
@Override
@ -1545,7 +1548,7 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
qrboardConfig.put("brandw", "600");
qrboardConfig.put("brandh", "200");
String type = qrboardConfig.getString("type");
QRBoard board = QRBoardProvider.getQRBoard(type, qrboardConfig, client, config);
QRBoard board = QRBoardProvider.getQRBoard(type, qrboardConfig, client, config,mongoTemplate,manager);
board.drawBoardImage(ous);
} catch (Exception e) {
throw new ServerErrorException("QR board config not set for current organize", e);
@ -1565,7 +1568,7 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
JSONObject qrboardConfig = JSON.parseObject(qrBoardConfigString);
String type = qrboardConfig.getString("type");
QRBoard board = QRBoardProvider.getQRBoard(type, qrboardConfig, client, config);
QRBoard board = QRBoardProvider.getQRBoard(type, qrboardConfig, client, config,mongoTemplate,manager);
board.drawBoardImage(ous);
} catch (Exception e) {
throw new ServerErrorException("QR board config not set for current organize", e);

Loading…
Cancel
Save