made private server tested and bug fixed

This commit is contained in:
strawmanbobi
2019-06-26 22:49:30 +08:00
parent 5c6d46f04d
commit 5120dbbc94
3 changed files with 9 additions and 8 deletions

View File

@@ -32,7 +32,7 @@ public class IndexingLogic {
private CityMapper cityMapper;
@Autowired
private OperatorMapper operatorMapper;
private StbOperatorMapper stbOperatorMapper;
@Autowired
private RemoteIndexMapper remoteIndexMapper;
@@ -81,11 +81,12 @@ public class IndexingLogic {
}
public List<City> listCities(String provincePrefix) {
return cityMapper.listCities(provincePrefix);
String provincePrefixText = provincePrefix + "__00";
return cityMapper.listCities(provincePrefixText);
}
public List<StbOperator> listOperators(String cityCode) {
return operatorMapper.listOperators(cityCode);
return stbOperatorMapper.listOperators(cityCode);
}
public List<RemoteIndex> listRemoteIndexes(int categoryId, int brandId, String cityCode, int from, int count) {
@@ -105,7 +106,7 @@ public class IndexingLogic {
}
RemoteIndex remote = remoteIndexList.get(0);
String downloadPath = "/data/irext/";
String downloadPath = "/home/strawmanbobi/";
String fileName = IR_BIN_FILE_PREFIX + remote.getRemoteMap() + IR_BIN_FILE_SUFFIX;
String localFilePath = downloadPath + fileName;
return new File(localFilePath);

View File

@@ -23,7 +23,7 @@ public interface CityMapper {
@ResultMap("BaseResultMap")
List<City> listProvinces();
@Select("SELECT * FROM city WHERE code like '#{provincePrefix}__00' and code not like '__0000'")
@Select("SELECT * FROM city WHERE code LIKE #{provincePrefix} AND code NOT LIKE '__0000'")
@ResultMap("BaseResultMap")
List<City> listCities(String provincePrefix);
}

View File

@@ -8,17 +8,17 @@ import org.apache.ibatis.annotations.Select;
import java.util.List;
/**
* Filename: OperatorMapper.java
* Filename: StbOperatorMapper.java
* Revised: Date: 2019-06-21
* Revision: Revision: 1.0
* <p>
* Description: OperatorMapper
* Description: StbOperatorMapper
* <p>
* Revision log:
* 2019-06-21: created by strawmanbobi
*/
@Mapper
public interface OperatorMapper {
public interface StbOperatorMapper {
@Select("SELECT * FROM stb_operator WHERE city_code = #{cityCode}")
@ResultMap("BaseResultMap")
List<StbOperator> listOperators(String cityCode);