mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 11:05:18 +08:00
update 对接lianlian平台
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package com.jsowell.pile.mapper;
|
||||
|
||||
import com.jsowell.pile.domain.ThirdPartyPlatformConfig;
|
||||
import com.jsowell.pile.vo.ThirdPartySecretInfoVO;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
@@ -68,4 +69,6 @@ public interface ThirdPartyPlatformConfigMapper {
|
||||
* @return
|
||||
*/
|
||||
ThirdPartyPlatformConfig getInfoByOperatorId(String operatorId);
|
||||
|
||||
ThirdPartySecretInfoVO queryThirdPartySecretInfo(String operatorId);
|
||||
}
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
package com.jsowell.pile.service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.jsowell.pile.domain.ThirdPartySettingInfo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 第三方平台配置Service接口
|
||||
*
|
||||
@@ -67,18 +67,5 @@ public interface ThirdPartySettingInfoService {
|
||||
*/
|
||||
public int deleteThirdPartySettingInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 根据站点id 查询配置列表
|
||||
*
|
||||
* @param stationId
|
||||
* @return
|
||||
*/
|
||||
public ThirdPartySettingInfo getInfoByStationId(Long stationId);
|
||||
|
||||
/**
|
||||
* 修改站点互联互通配置
|
||||
* @param info
|
||||
* @return
|
||||
*/
|
||||
int updateStationSettingInfo(ThirdPartySettingInfo info);
|
||||
}
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
package com.jsowell.pile.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.jsowell.common.util.DateUtils;
|
||||
import com.jsowell.pile.domain.ThirdPartyPlatformConfig;
|
||||
import com.jsowell.pile.mapper.ThirdPartyPlatformConfigMapper;
|
||||
import com.jsowell.pile.service.ThirdPartyPlatformConfigService;
|
||||
import com.jsowell.pile.vo.ThirdPartySecretInfoVO;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.jsowell.pile.mapper.ThirdPartyPlatformConfigMapper;
|
||||
import com.jsowell.pile.domain.ThirdPartyPlatformConfig;
|
||||
import com.jsowell.pile.service.ThirdPartyPlatformConfigService;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 对接平台配置信息Service业务层处理
|
||||
@@ -98,4 +99,12 @@ public class ThirdPartyPlatformConfigServiceImpl implements ThirdPartyPlatformCo
|
||||
public ThirdPartyPlatformConfig getInfoByOperatorId(String operatorId) {
|
||||
return thirdPartyPlatformConfigMapper.getInfoByOperatorId(operatorId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询第三方平台配置的密钥信息
|
||||
* @return
|
||||
*/
|
||||
public ThirdPartySecretInfoVO queryThirdPartySecretInfo(String operatorId) {
|
||||
return thirdPartyPlatformConfigMapper.queryThirdPartySecretInfo(operatorId);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
package com.jsowell.pile.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.jsowell.common.util.DateUtils;
|
||||
import com.jsowell.pile.domain.ThirdPartySettingInfo;
|
||||
import com.jsowell.pile.mapper.ThirdPartySettingInfoMapper;
|
||||
import com.jsowell.pile.service.ThirdPartySettingInfoService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.jsowell.pile.mapper.ThirdPartySettingInfoMapper;
|
||||
import com.jsowell.pile.domain.ThirdPartySettingInfo;
|
||||
import com.jsowell.pile.service.ThirdPartySettingInfoService;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 第三方平台配置Service业务层处理
|
||||
@@ -98,33 +98,5 @@ public class ThirdPartySettingInfoServiceImpl implements ThirdPartySettingInfoSe
|
||||
return thirdPartySettingInfoMapper.deleteThirdPartySettingInfoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据站点id 查询配置列表
|
||||
*
|
||||
* @param stationId
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ThirdPartySettingInfo getInfoByStationId(Long stationId) {
|
||||
return thirdPartySettingInfoMapper.getInfoByStationId(stationId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改站点互联互通配置
|
||||
* @param info
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public int updateStationSettingInfo(ThirdPartySettingInfo info) {
|
||||
Long stationId = info.getStationId();
|
||||
ThirdPartySettingInfo infoByStationId = getInfoByStationId(stationId);
|
||||
if (infoByStationId == null) {
|
||||
// 新增
|
||||
return insertThirdPartySettingInfo(info);
|
||||
}else {
|
||||
// 修改
|
||||
info.setId(infoByStationId.getId());
|
||||
return updateThirdPartySettingInfo(info);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
package com.jsowell.pile.vo;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* 第三方平台配置的密钥信息
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
public class ThirdPartySecretInfoVO {
|
||||
// 我方的组织机构代码
|
||||
private String ourOperatorId;
|
||||
|
||||
// 我方生成的唯一识别密钥
|
||||
private String ourOperatorSecret;
|
||||
|
||||
// 我方生成的消息密钥
|
||||
private String ourDataSecret;
|
||||
|
||||
// 我方生成的初始化向量
|
||||
private String ourDataSecretIv;
|
||||
|
||||
// 我方生成的签名密钥
|
||||
private String ourSigSecret;
|
||||
|
||||
// 对接平台的组织机构代码
|
||||
private String theirOperatorId;
|
||||
|
||||
// 对接平台生成的唯一识别密钥
|
||||
private String theirOperatorSecret;
|
||||
|
||||
// 对接平台生成的消息密钥
|
||||
private String theirDataSecret;
|
||||
|
||||
// 对接平台的初始化向量
|
||||
private String theirDataSecretIv;
|
||||
|
||||
// 对接平台生成的签名密钥
|
||||
private String theirSigSecret;
|
||||
|
||||
// 对接平台接口前缀
|
||||
private String theirUrlPrefix;
|
||||
}
|
||||
Reference in New Issue
Block a user