Commit 817bb91e authored by hezhuozhi's avatar hezhuozhi

27467 人大金仓数据库适配 将所有的`去除

parent 0b52b1d4
......@@ -87,8 +87,6 @@ public class PreparationMoneyServiceImpl extends BaseService<PreparationMoneyDto
@Autowired
PeasantHouseholdMapper peasantHouseholdMapper;
@Autowired
HygfReplenishmentMapper hygfReplenishmentMapper;
@Autowired
private WorkFlowService workFlowService;
@Autowired
private HygfPreparationMoneyAuditingServiceImpl hygfPreparationMoneyAuditingService;
......
......@@ -2,9 +2,7 @@ package com.yeejoin.amos.boot.module.jxiop.api.entity;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yeejoin.amos.boot.biz.common.entity.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import java.util.Date;
......@@ -36,8 +34,8 @@ public class Region {
/**
* 等级
*/
@TableField("\"LEVEL\"")
private String level;
@TableField("LEVEL_")
private String level_;
/**
* 上级编码
......
......@@ -7,7 +7,7 @@
hp.sequence_nbr as id,
hp.platform_company_id AS platformCompanyId,
hp.number,
hp.`name`,
hp.name,
hp.sex,
hp.ID_number AS idNumber,
hp.expiry_time AS expiryTime,
......@@ -106,7 +106,7 @@
resultType="com.yeejoin.amos.boot.module.jxiop.api.dto.EquipMessageExport">
SELECT
(@i:= @i+1) as numSort,
hp.`name`,
hp.name,
hp.ID_number AS idNumber,
hpd.type,
hpd.name as equipName,
......
......@@ -20,12 +20,12 @@
<select id="getBoosterStationInfo" resultType="java.util.Map">
select
`sequence_nbr` as id,
`gateway_id` as gatewayId,
`booster_name` as text,
sequence_nbr as id,
gateway_id as gatewayId,
booster_name as text,
booster_name as boosterName,
`booster_code` as boosterCode,
`sort` as value
booster_code as boosterCode,
sort as value
from booster_station_info
<where>
<if test="gatewayId != null and gatewayId != ''">
......@@ -44,12 +44,12 @@
<select id="getBoosterStationInfo2" resultType="java.util.Map">
select * from
((select
`sequence_nbr` as id,
`gateway_id` as gatewayId,
`booster_name` as text,
sequence_nbr as id,
gateway_id as gatewayId,
booster_name as text,
booster_name as boosterName,
`booster_code` as boosterCode,
`sort` as value
booster_code as boosterCode,
sort as value
from booster_station_info
<where>
sort != 2
......@@ -66,7 +66,7 @@
union all
(select
'99999' as id,
`gateway_id` as gatewayId,
gateway_id as gatewayId,
'1主变' as text,
'1主变' as boosterName,
'2' as boosterCode,
......@@ -84,12 +84,12 @@
<select id="getMajorBoosterStationInfo" resultType="java.util.Map">
select
`sequence_nbr` as id,
`gateway_id` as gatewayId,
`booster_name` as text,
sequence_nbr as id,
gateway_id as gatewayId,
booster_name as text,
booster_name as boosterName,
`booster_code` as boosterCode,
`sort` as value
booster_code as boosterCode,
sort as value
from booster_station_info
<where>
<if test="gatewayId != null and gatewayId != ''">
......@@ -103,12 +103,12 @@
<select id="getMajorBoosterStationInfoBySort" resultType="java.util.Map">
select
`sequence_nbr` as id,
`gateway_id` as gatewayId,
`booster_name` as text,
sequence_nbr as id,
gateway_id as gatewayId,
booster_name as text,
booster_name as boosterName,
`booster_code` as boosterCode,
`sort` as value
booster_code as boosterCode,
sort as value
from booster_station_info
where
sort = #{sort}
......@@ -119,12 +119,12 @@
<select id="getBoosterStationInfoNormal" resultType="java.util.Map">
select
`sequence_nbr` as id,
`gateway_id` as gatewayId,
`booster_name` as text,
sequence_nbr as id,
gateway_id as gatewayId,
booster_name as text,
booster_name as boosterName,
`booster_code` as boosterCode,
`sort` as value
booster_code as boosterCode,
sort as value
from booster_station_info
<where>
<if test="gatewayId != null and gatewayId != ''">
......
......@@ -83,7 +83,7 @@
<select id="getEXPersonUser" resultType="com.yeejoin.amos.boot.module.jxiop.api.dto.EXPersonUser">
select
person_account.`name` name,
person_account.name name,
person_account.job_number jobNumber,
person_account.project_name projectName,
person_account.project_department_name departmentName,
......@@ -116,7 +116,7 @@
<select id="getEXPersonUserAll" resultType="com.yeejoin.amos.boot.module.jxiop.api.dto.EXPersonUser">
select
person_account.`name` name,
person_account.name name,
person_account.job_number jobNumber,
person_account.project_name projectName,
person_account.project_department_name departmentName,
......@@ -296,7 +296,7 @@
<select id="getPersonStatistics" resultType="com.yeejoin.amos.boot.module.jxiop.api.entity.StationQrCodeStatistics">
SELECT
project_org_code AS `code`,
project_org_code AS code,
count( qrcode_color = 'red' OR NULL ) AS redNum,
count( qrcode_color = 'yellow' OR NULL ) AS yellowNum,
count( qrcode_color = 'green' OR NULL ) AS greenNum,
......@@ -310,7 +310,7 @@
<select id="getPersonDetailInfoByObjectId" resultType="java.util.Map">
SELECT
IFNULL(b.`name`, '') as `name`,
IFNULL(b.name, '') as name,
IFNULL(a.phone, '') as phone,
IFNULL(a.post_name, '') as postName,
IFNULL(b.project_name, '') as stationName,
......
......@@ -173,9 +173,9 @@
<update id="updateYardByProjectOrgCode">
<foreach collection="list" item="item" separator=";">
update
`station_basic`
station_basic
set
`qrcode_color` = #{item.qrcodeColor},
qrcode_color = #{item.qrcodeColor},
<if test="item.level != null and item.level != ''">
risk_Level = #{item.level},
</if>
......
......@@ -14,7 +14,7 @@
AND privilege_company.COMPANY_TYPE=#{companyType}
</if>
<if test="level != null and level != ''">
AND privilege_company.`LEVEL`=#{level}
AND privilege_company.LEVEL_=#{level}
</if>
<if test="companyOrgCode != null ">
AND privilege_company.ORG_CODE IN
......
......@@ -359,8 +359,8 @@
)
SELECT
a.SEQUENCE_NBR AS sequenceNbr,
COALESCE(a.NAME, '') AS `name`,
COALESCE(a.CODE, '') AS `code`,
COALESCE(a.NAME, '') AS name,
COALESCE(a.CODE, '') AS code,
COALESCE(a.PARENT_ID, '') AS parentId,
COALESCE(a.LONGITUDE, '') AS longitude,
COALESCE(a.LATITUDE, '') AS latitude,
......@@ -391,7 +391,7 @@
count( 1 ) AS yearNum
FROM
amos_mcb.mcb_warning_warning_info
Left join mcb_warning_base_source_attribution mwbsa on mwbsa.`CODE` = mcb_warning_warning_info.SOURCE_ATTRIBUTION
Left join mcb_warning_base_source_attribution mwbsa on mwbsa.CODE = mcb_warning_warning_info.SOURCE_ATTRIBUTION
WHERE
YEAR(CREATE_DATE) = YEAR(CURDATE())
<if test="province != null and province != '' ">
......@@ -408,7 +408,7 @@
count( 1 ) AS monNum
FROM
amos_mcb.mcb_warning_warning_info
Left join mcb_warning_base_source_attribution mwbsa on mwbsa.`CODE` = mcb_warning_warning_info.SOURCE_ATTRIBUTION
Left join mcb_warning_base_source_attribution mwbsa on mwbsa.CODE = mcb_warning_warning_info.SOURCE_ATTRIBUTION
WHERE
MONTH(CREATE_DATE) = MONTH(CURDATE())
<if test="province != null and province != '' ">
......@@ -425,7 +425,7 @@
mwbsa.PROVINCE
FROM
amos_mcb.mcb_warning_warning_info
Left join mcb_warning_base_source_attribution mwbsa on mwbsa.`CODE` = mcb_warning_warning_info.SOURCE_ATTRIBUTION
Left join mcb_warning_base_source_attribution mwbsa on mwbsa.CODE = mcb_warning_warning_info.SOURCE_ATTRIBUTION
WHERE
DATE_FORMAT(CREATE_DATE,'%Y-%m-%d') = CURDATE()
<if test="province != null and province != '' ">
......
package com.yeejoin.amos.boot.module.jxiop.biz.service.impl;
import com.alibaba.fastjson.JSON;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
......@@ -19,13 +18,10 @@ import com.yeejoin.amos.boot.module.jxiop.biz.initdata.StationCacheDataInit;
import com.yeejoin.amos.boot.module.jxiop.biz.mapper2.SjglZsjZsbtzMapper;
import lombok.extern.slf4j.Slf4j;
import org.elasticsearch.action.search.SearchRequestBuilder;
import org.elasticsearch.action.search.SearchResponse;
import org.elasticsearch.index.query.BoolQueryBuilder;
import org.elasticsearch.index.query.MatchPhraseQueryBuilder;
import org.elasticsearch.index.query.QueryBuilders;
import org.elasticsearch.search.aggregations.Aggregation;
import org.elasticsearch.search.aggregations.AggregationBuilder;
import org.elasticsearch.search.aggregations.AggregationBuilders;
import org.elasticsearch.search.aggregations.Aggregations;
import org.elasticsearch.search.aggregations.bucket.terms.ParsedStringTerms;
......@@ -229,7 +225,7 @@ public class CommonServiceImpl {
public List<StationCacheInfoDto> getListStationCacheInfoDto() {
List<StationCacheInfoDto> stationCacheInfoDtos = new ArrayList<>();
List<Region> regionList = regionMapper.selectList(new LambdaQueryWrapper<Region>().eq(Region::getLevel, 1));
List<Region> regionList = regionMapper.selectList(new LambdaQueryWrapper<Region>().eq(Region::getLevel_, 1));
List<MapRegion> mapRegionList = mapRegionMapper.selectList(new QueryWrapper<MapRegion>().isNotNull("name"));
List<StationBasic> stationBasicList = stationBasicMapper.selectList(new QueryWrapper<StationBasic>().isNotNull("belong_area").isNotNull("fan_gateway_id"));
for (int i = 0; i < stationBasicList.size(); i++) {
......
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