| | |
| | |
|
| | | import javax.annotation.Resource;
|
| | |
|
| | | import com.yeshi.fanli.entity.SystemEnum;
|
| | | import org.springframework.cache.annotation.Cacheable;
|
| | | import org.springframework.stereotype.Service;
|
| | |
|
| | |
| | | }
|
| | |
|
| | | @Override
|
| | | public BusinessSystem getBusinessSystem(String platform, String packages) {
|
| | | public BusinessSystem getBusinessSystem(String platform, String packages, SystemEnum system) {
|
| | | if (platform == null || packages == null) {
|
| | | return null;
|
| | | }
|
| | | platform = platform.toUpperCase();
|
| | | Integer platformInt = map.get(platform);
|
| | |
|
| | | List<BusinessSystem> list = businessSystemMapper.listByPlatformAndPackage(platformInt, packages);
|
| | | List<BusinessSystem> list = businessSystemMapper.listByPlatformAndPackage(platformInt, packages,system);
|
| | | if (list == null || list.size() == 0) {
|
| | | return null;
|
| | | }
|
| | | return list.get(0);
|
| | | }
|
| | |
|
| | | @Cacheable(value = "sysCache", key = "'getBusinessSystem-'+#platform+'-'+#packages")
|
| | | @Cacheable(value = "sysCache", key = "'getBusinessSystem-'+#platform+'-'+#packages+'-'+#system")
|
| | | @Override
|
| | | public BusinessSystem getBusinessSystemCache(String platform, String packages) {
|
| | | return getBusinessSystem(platform, packages);
|
| | | public BusinessSystem getBusinessSystemCache(String platform, String packages, SystemEnum system) {
|
| | | return getBusinessSystem(platform, packages,system);
|
| | | }
|
| | |
|
| | | @Override
|