Merge branch 'develop_master' into develop_migration
This commit is contained in:
@@ -74,6 +74,10 @@ public class WebMvcConfig implements WebMvcConfigurer {
|
|||||||
//企业标准导出
|
//企业标准导出
|
||||||
addInterceptor.excludePathPatterns("/api/lawss/sarBussionessStand/exportSarBussionessStand");
|
addInterceptor.excludePathPatterns("/api/lawss/sarBussionessStand/exportSarBussionessStand");
|
||||||
|
|
||||||
|
//预警导出
|
||||||
|
addInterceptor.excludePathPatterns("/api/sys/EarlyWarning/exportWarning");
|
||||||
|
|
||||||
|
|
||||||
//OCR回调存储文件
|
//OCR回调存储文件
|
||||||
addInterceptor.excludePathPatterns("/api/ocr/OCRRestful/OcrHandleResult");
|
addInterceptor.excludePathPatterns("/api/ocr/OCRRestful/OcrHandleResult");
|
||||||
|
|
||||||
@@ -94,7 +98,7 @@ public class WebMvcConfig implements WebMvcConfigurer {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
// 添加自定义拦截器,并拦截对应 url
|
// // 添加自定义拦截器,并拦截对应 url
|
||||||
addInterceptor.addPathPatterns("/**");
|
// addInterceptor.addPathPatterns("/**");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+5
-2
@@ -131,9 +131,11 @@ public class EarlyWarningEOController extends BaseController<EarlyWarningEO> {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
@GetMapping("/exprotWarning")
|
@GetMapping("/exportWarning")
|
||||||
@ApiOperation("导出预警")
|
@ApiOperation("导出预警")
|
||||||
public void exportStandardsInfoExcel(WarningExcelVO excelVO, HttpServletResponse response) throws Exception {
|
public void exportStandardsInfoExcel(WarningExcelVO excelVO, HttpServletResponse response) throws Exception {
|
||||||
|
|
||||||
|
|
||||||
// 这里注意 有同学反应使用swagger 会导致各种问题,请直接用浏览器或者用postman
|
// 这里注意 有同学反应使用swagger 会导致各种问题,请直接用浏览器或者用postman
|
||||||
try {
|
try {
|
||||||
response.setContentType("application/vnd.ms-excel");
|
response.setContentType("application/vnd.ms-excel");
|
||||||
@@ -145,11 +147,12 @@ public class EarlyWarningEOController extends BaseController<EarlyWarningEO> {
|
|||||||
String fileName = URLEncoder.encode(excelVO.getExportName(), "UTF-8").replaceAll("\\+", "%20");
|
String fileName = URLEncoder.encode(excelVO.getExportName(), "UTF-8").replaceAll("\\+", "%20");
|
||||||
response.setHeader("Content-disposition", "attachment;filename*=utf-8''" + fileName + ".xlsx");
|
response.setHeader("Content-disposition", "attachment;filename*=utf-8''" + fileName + ".xlsx");
|
||||||
|
|
||||||
|
// List<StandWarningEO> exportExcel = earlyWarningEOService.getExportExcel(excelVO);
|
||||||
List<StandWarningEO> exportExcel = earlyWarningEOService.getExportExcel(excelVO);
|
List<StandWarningEO> exportExcel = earlyWarningEOService.getExportExcel(excelVO);
|
||||||
|
|
||||||
|
|
||||||
// 这里需要设置不关闭流
|
// 这里需要设置不关闭流
|
||||||
EasyExcel.write(response.getOutputStream(), SarStandIssueControlProduct.class).autoCloseStream(Boolean.FALSE).sheet("sheet1")
|
EasyExcel.write(response.getOutputStream(), StandWarningEO.class).autoCloseStream(Boolean.FALSE).sheet("sheet1")
|
||||||
.doWrite(exportExcel);
|
.doWrite(exportExcel);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
System.out.println(e);
|
System.out.println(e);
|
||||||
|
|||||||
+4
-1
@@ -11,6 +11,9 @@ import java.util.List;
|
|||||||
|
|
||||||
public interface EarlyWarningEODao extends BaseMapper<EarlyWarningEO> {
|
public interface EarlyWarningEODao extends BaseMapper<EarlyWarningEO> {
|
||||||
|
|
||||||
IPage<StandWarningEO> selectWarningPage(IPage<StandWarningEO> page, @Param("waringEO") StandWarningEO warningEO,@Param("idList") List<String> ids);
|
IPage<StandWarningEO> selectWarningPage(IPage<StandWarningEO> page, @Param("waringEO") StandWarningEO warningEO);
|
||||||
|
|
||||||
|
|
||||||
|
List<StandWarningEO> exportWarning(@Param("idList") List<String> ids);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -37,6 +37,11 @@ public class EarlyWarningEO extends BaseEntity {
|
|||||||
@TableField("STAND_ID")
|
@TableField("STAND_ID")
|
||||||
private String standId;
|
private String standId;
|
||||||
|
|
||||||
|
@ExcelIgnore
|
||||||
|
@ApiModelProperty("分解单条款id")
|
||||||
|
@TableField("ITEM_ID")
|
||||||
|
private String itemId;
|
||||||
|
|
||||||
@ExcelIgnore
|
@ExcelIgnore
|
||||||
@ApiModelProperty("标准类别")
|
@ApiModelProperty("标准类别")
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
|
|||||||
@@ -14,6 +14,9 @@ public class WarningDate {
|
|||||||
@TableField("law_id")
|
@TableField("law_id")
|
||||||
private String lawId;
|
private String lawId;
|
||||||
|
|
||||||
|
@TableField("itemId")
|
||||||
|
private String itemId;
|
||||||
|
|
||||||
@TableField("SSRQ")
|
@TableField("SSRQ")
|
||||||
private String SSRQ;
|
private String SSRQ;
|
||||||
|
|
||||||
|
|||||||
+5
-3
@@ -112,7 +112,7 @@ public class EarlyWarningEOServiceImpl extends ServiceImpl<EarlyWarningEODao, Ea
|
|||||||
@Override
|
@Override
|
||||||
public IPage<StandWarningEO> getStandWarning(StandWarningEO queryPage) {
|
public IPage<StandWarningEO> getStandWarning(StandWarningEO queryPage) {
|
||||||
IPage<StandWarningEO> iPage = new Page<>(queryPage.getPage(),queryPage.getPageSize());
|
IPage<StandWarningEO> iPage = new Page<>(queryPage.getPage(),queryPage.getPageSize());
|
||||||
return earlyWarningEODao.selectWarningPage(iPage,queryPage,null);
|
return earlyWarningEODao.selectWarningPage(iPage,queryPage);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -121,8 +121,10 @@ public class EarlyWarningEOServiceImpl extends ServiceImpl<EarlyWarningEODao, Ea
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<StandWarningEO> getExportExcel(WarningExcelVO excelVO){
|
public List<StandWarningEO> getExportExcel(WarningExcelVO excelVO){
|
||||||
IPage<StandWarningEO> standWarningEOIPage = earlyWarningEODao.selectWarningPage(null, null, excelVO.getIds());
|
List<StandWarningEO> standWarningEOList = earlyWarningEODao.exportWarning( excelVO.getIds());
|
||||||
return standWarningEOIPage.getRecords();
|
// IPage<StandWarningEO> standWarningEOIPage = earlyWarningEODao.selectWarningPage(null, null, null);
|
||||||
|
|
||||||
|
return standWarningEOList;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+38
@@ -127,6 +127,44 @@ public class SarStandardsInfoController extends BaseController<SarStandardsInfo>
|
|||||||
return Result.success(getPageInfo(page.getPager(), rows));
|
return Result.success(getPageInfo(page.getPager(), rows));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "|SarStandardsInfoEO|自定义分页查询")
|
||||||
|
@GetMapping("/getSarStandardsInfoPageByWk1")
|
||||||
|
//@RequiresPermissions("lawss:sarStandardsInfo:getSarStandardsInfoPage")
|
||||||
|
public ResponseMessage<PageInfo<SarStandardsInfo>> getSarStandardsInfoPageByWk1(SarStandardsInfoEOPage page,@RequestParam(defaultValue = "0") String mark) throws Exception {
|
||||||
|
if (null != page.getNowOrderBy()) {
|
||||||
|
nowOrderFunc(page);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (StringUtils.isNotBlank(page.getAdvanceSearchVOStr())) {
|
||||||
|
List<SarAdvanceSearchVO> searchList = JSONObject.parseArray(page.getAdvanceSearchVOStr(),SarAdvanceSearchVO.class);
|
||||||
|
String advanceStr = SarAdvanceSearchUtil.createStandSql(searchList);
|
||||||
|
if (StringUtils.isNotBlank(advanceStr)) {
|
||||||
|
page.setAdvanceSearchStr(advanceStr);
|
||||||
|
} else {
|
||||||
|
page.setAdvanceSearchStr(null);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(page.getUserId() == null || page.getUserId().equals("")){
|
||||||
|
page.setUserId(LoginUserUtil.getUserId());
|
||||||
|
}
|
||||||
|
List<SarStandardsInfo> rows = sarStandardsInfoEOService.getSarStandardsInfoPageByWk1(page);
|
||||||
|
|
||||||
|
// 去掉日期时分秒
|
||||||
|
rows.forEach(item->{
|
||||||
|
|
||||||
|
Optional.ofNullable(item.getSSRQ())
|
||||||
|
.ifPresent(SSRQ -> item.setSSRQ(item.getSSRQ().replaceAll("\\s[0-6][0-9]\\:[0-6][0-9]\\:[0-6][0-9]", "")));
|
||||||
|
Optional.ofNullable(item.getXCXSSRQ())
|
||||||
|
.ifPresent(SSRQ ->item.setXCXSSRQ(item.getXCXSSRQ().replaceAll("\\s[0-6][0-9]\\:[0-6][0-9]\\:[0-6][0-9]", "")));
|
||||||
|
Optional.ofNullable(item.getZCCSSRQ())
|
||||||
|
.ifPresent(SSRQ ->item.setZCCSSRQ(item.getZCCSSRQ().replaceAll("\\s[0-6][0-9]\\:[0-6][0-9]\\:[0-6][0-9]", "")));
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
return Result.success(getPageInfo(page.getPager(), rows));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private void nowOrderFunc(SarStandardsInfoEOPage page) {
|
private void nowOrderFunc(SarStandardsInfoEOPage page) {
|
||||||
|
|||||||
+2
@@ -21,6 +21,8 @@ public interface ISarStandardsInfoService extends IService<SarStandardsInfo> {
|
|||||||
|
|
||||||
List<SarStandardsInfo> getSarStandardsInfoPage(SarStandardsInfoEOPage page) throws Exception;
|
List<SarStandardsInfo> getSarStandardsInfoPage(SarStandardsInfoEOPage page) throws Exception;
|
||||||
|
|
||||||
|
List<SarStandardsInfo> getSarStandardsInfoPageByWk1(SarStandardsInfoEOPage page) throws Exception;
|
||||||
|
|
||||||
List<SarStandardsInfo> getSarStandardsInfoPageBak(SarStandardsInfoEOPage page) throws Exception;
|
List<SarStandardsInfo> getSarStandardsInfoPageBak(SarStandardsInfoEOPage page) throws Exception;
|
||||||
|
|
||||||
List<SarStandardsInfo> getSarStandardsInfoPageBak1(SarStandardsInfoEOPage page) throws Exception;
|
List<SarStandardsInfo> getSarStandardsInfoPageBak1(SarStandardsInfoEOPage page) throws Exception;
|
||||||
|
|||||||
+28
@@ -321,6 +321,34 @@ public class SarStandardsInfoServiceImpl extends ServiceImpl<SarStandardsInfoDao
|
|||||||
return sarlist;
|
return sarlist;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<SarStandardsInfo> getSarStandardsInfoPageByWk1(SarStandardsInfoEOPage page) throws Exception {
|
||||||
|
//查询当前登录人角色拥有权限的菜单
|
||||||
|
if(page.getMenuId() != null && page.getUserId() != null && StringUtils.isNotBlank(page.getUserId())){
|
||||||
|
QueryWrapper<TsResource> qw = new QueryWrapper<>();
|
||||||
|
qw.eq("ID",page.getMenuId());
|
||||||
|
qw.isNull("PARENT_ID");
|
||||||
|
List<TsResource> children = iTsResourceService.list(qw);
|
||||||
|
if(children.isEmpty() && !page.getMenuId().equals("nomenu")){
|
||||||
|
// List<String> getMenuIdList = tsUserService.getResourceUserId(page.getUserId());
|
||||||
|
// if (getMenuIdList != null && !getMenuIdList.isEmpty()) {
|
||||||
|
// page.setMenuRoleList(getMenuIdList);
|
||||||
|
// } else {
|
||||||
|
// page.setMenuRoleList(null);
|
||||||
|
// }
|
||||||
|
List<String> ids = iTsResourceService.getChildMenuList(page.getMenuId());
|
||||||
|
if (ids != null && !ids.isEmpty()) {
|
||||||
|
page.setMenuAllChildrenIdList(ids);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Integer rowCount = dao.getSarStandardsInfoCount(page);
|
||||||
|
page.getPager().setRowCount(rowCount);
|
||||||
|
List<SarStandardsInfo> sarlist = dao.getSarStandardsInfoPage(page,"996");
|
||||||
|
attrInfoCollect(sarlist);
|
||||||
|
return sarlist;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<SarStandardsInfo> getSarStandardsInfoPageBak(SarStandardsInfoEOPage page) throws Exception {
|
public List<SarStandardsInfo> getSarStandardsInfoPageBak(SarStandardsInfoEOPage page) throws Exception {
|
||||||
//查询当前登录人角色拥有权限的菜单
|
//查询当前登录人角色拥有权限的菜单
|
||||||
|
|||||||
+86
-9
@@ -38,16 +38,7 @@
|
|||||||
|
|
||||||
<sql id="stand_where">
|
<sql id="stand_where">
|
||||||
|
|
||||||
<if test="idList != null and idList.size() > 0">
|
|
||||||
|
|
||||||
warning.ID
|
|
||||||
IN
|
|
||||||
<foreach collection="idList" item="id" open="and (" close=")" separator=",">
|
|
||||||
<!-- 每个遍历需要生成的串 -->
|
|
||||||
#{id}
|
|
||||||
</foreach>
|
|
||||||
|
|
||||||
</if>
|
|
||||||
|
|
||||||
<if test="waringEO.standCode != null and waringEO.standCode != ''">
|
<if test="waringEO.standCode != null and waringEO.standCode != ''">
|
||||||
AND trim(replace(CONCAT(
|
AND trim(replace(CONCAT(
|
||||||
@@ -83,6 +74,92 @@
|
|||||||
)
|
)
|
||||||
</if>
|
</if>
|
||||||
</sql>
|
</sql>
|
||||||
|
<select id="exportWarning" resultType="com.adc.da.slrs.sarStandWarning.entity.StandWarningEO">
|
||||||
|
|
||||||
|
SELECT WARNING_RESULT.* FROM
|
||||||
|
(
|
||||||
|
|
||||||
|
SELECT
|
||||||
|
<include refid="stand_column"/>
|
||||||
|
,
|
||||||
|
attr.CLLX AS
|
||||||
|
APPLY_TYPE ,
|
||||||
|
attr
|
||||||
|
.ZRGCS AS DUTY_ENGINEER ,
|
||||||
|
NULL AS ITEMS_ID ,
|
||||||
|
NULL AS ITEMS_NUM , NULL AS ITEMS_NAME ,
|
||||||
|
NULL AS POLICY_ID ,
|
||||||
|
NULL AS POLICY_NAME ,
|
||||||
|
MARK ,
|
||||||
|
POWER,
|
||||||
|
attr.XCXSSRQ AS XCXSSRQ ,
|
||||||
|
attr.ZCCSSRQ AS ZCCSSRQ
|
||||||
|
FROM sar_stand_warning AS warning
|
||||||
|
LEFT JOIN sar_standards_info AS sarInfo on sarInfo.id=warning.STAND_ID
|
||||||
|
LEFT JOIN sar_stand_attr_info AS attr on attr.STAND_ID=warning.STAND_ID
|
||||||
|
<where>
|
||||||
|
POWER = '1'
|
||||||
|
AND (MARK = 'stand')
|
||||||
|
<if test="idList != null and idList.size() > 0">
|
||||||
|
AND
|
||||||
|
warning.ID
|
||||||
|
IN
|
||||||
|
<foreach collection="idList" item="id" open="(" close=")" separator=",">
|
||||||
|
<!-- 每个遍历需要生成的串 -->
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
|
||||||
|
|
||||||
|
UNION ALL
|
||||||
|
|
||||||
|
SELECT
|
||||||
|
<include refid="stand_column"/> ,
|
||||||
|
items.APPLY_ARCTIC AS APPLY_TYPE ,
|
||||||
|
items.DUTY_ENGINEER AS DUTY_ENGINEER ,
|
||||||
|
items.ID AS ITEMS_ID ,
|
||||||
|
items.ITEMS_NUM ,
|
||||||
|
items.ITEMS_NAME ,
|
||||||
|
NULL AS POLICY_ID ,
|
||||||
|
NULL AS POLICY_NAME ,
|
||||||
|
MARK ,
|
||||||
|
POWER,
|
||||||
|
items.XCXSSRQ AS XCXSSRQ ,
|
||||||
|
items.ZCCSSRQ AS ZCCSSRQ
|
||||||
|
FROM
|
||||||
|
sar_stand_warning AS warning
|
||||||
|
LEFT JOIN sar_standards_info AS sarInfo ON sarInfo.id = warning.STAND_ID
|
||||||
|
LEFT JOIN sar_stand_items AS items ON items.STAND_ID = warning.STAND_ID
|
||||||
|
LEFT JOIN sar_stand_attr_info AS attr ON attr.STAND_ID = warning.STAND_ID
|
||||||
|
<where>
|
||||||
|
POWER = '1'
|
||||||
|
AND (MARK = 'item')
|
||||||
|
<if test="idList != null and idList.size() > 0">
|
||||||
|
AND
|
||||||
|
warning.ID
|
||||||
|
IN
|
||||||
|
<foreach collection="idList" item="id" open="(" close=")" separator=",">
|
||||||
|
<!-- 每个遍历需要生成的串 -->
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
)
|
||||||
|
WARNING_RESULT
|
||||||
|
LEFT JOIN
|
||||||
|
(
|
||||||
|
SELECT law_id,MIN(SSRQ) SSRQ_MIN FROM warning_date
|
||||||
|
GROUP BY warning_date.law_id
|
||||||
|
) warning_date
|
||||||
|
ON warning_date.law_id = WARNING_RESULT.STAND_ID
|
||||||
|
ORDER BY warning_date.SSRQ_MIN
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</select>
|
||||||
|
|
||||||
<select id="selectWarningPage" resultMap="resultMap">
|
<select id="selectWarningPage" resultMap="resultMap">
|
||||||
SELECT WARNING_RESULT.* FROM
|
SELECT WARNING_RESULT.* FROM
|
||||||
|
|||||||
+50
-23
@@ -51,15 +51,23 @@
|
|||||||
|
|
||||||
<select id="getWarningId" resultType="com.adc.da.slrs.sarStandWarning.entity.EarlyWarningEO">
|
<select id="getWarningId" resultType="com.adc.da.slrs.sarStandWarning.entity.EarlyWarningEO">
|
||||||
SELECT
|
SELECT
|
||||||
law_id as STAND_ID,
|
law_id AS standId,
|
||||||
'-1' AS itemsId,
|
item_id AS itemId,
|
||||||
'stand' AS mark,
|
CASE
|
||||||
'1' as power
|
WHEN item_id = '-1' THEN
|
||||||
|
'stand'
|
||||||
|
WHEN
|
||||||
|
item_id IS NULL THEN
|
||||||
|
'stand'
|
||||||
|
ELSE
|
||||||
|
'item'
|
||||||
|
END AS mark,
|
||||||
|
'1' as power
|
||||||
FROM
|
FROM
|
||||||
warning_date AS warning
|
warning_date AS warning
|
||||||
WHERE
|
WHERE
|
||||||
DATE_FORMAT(warning.SSRQ,'%Y-%m-%d') BETWEEN DATE_FORMAT(#{startDate}, '%Y-%m-%d') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d')
|
DATE_FORMAT(warning.SSRQ,'%Y-%m-%d') BETWEEN DATE_FORMAT(#{startDate}, '%Y-%m-%d') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d')
|
||||||
UNION
|
<!-- UNION
|
||||||
SELECT
|
SELECT
|
||||||
STAND_ID,
|
STAND_ID,
|
||||||
ID AS itemsId,
|
ID AS itemsId,
|
||||||
@@ -70,7 +78,7 @@
|
|||||||
WHERE
|
WHERE
|
||||||
DATE_FORMAT(item.XCXSSRQ,'%Y-%m-%d') BETWEEN DATE_FORMAT(#{startDate}, '%Y-%m-%d') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d')
|
DATE_FORMAT(item.XCXSSRQ,'%Y-%m-%d') BETWEEN DATE_FORMAT(#{startDate}, '%Y-%m-%d') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d')
|
||||||
OR
|
OR
|
||||||
DATE_FORMAT(item.ZCCSSRQ,'%Y-%m-%d') BETWEEN DATE_FORMAT(#{startDate}, '%Y-%m-%d') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d')
|
DATE_FORMAT(item.ZCCSSRQ,'%Y-%m-%d') BETWEEN DATE_FORMAT(#{startDate}, '%Y-%m-%d') AND DATE_FORMAT(#{endDate}, '%Y-%m-%d') -->
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
@@ -79,25 +87,44 @@
|
|||||||
|
|
||||||
SELECT lawId,timeName,DATE_FORMAT(SSRQ,'%Y-%m-%d') as SSRQ FROM
|
SELECT lawId,timeName,DATE_FORMAT(SSRQ,'%Y-%m-%d') as SSRQ FROM
|
||||||
(
|
(
|
||||||
select attr.STAND_ID as lawId,'SSRQ' as timeName,
|
select attr.STAND_ID as lawId,'-1' as itemId,'SSRQ' as timeName,
|
||||||
substring_index(substring_index(attr.SSRQ,',',b.help_topic_id+1),',',-1) SSRQ
|
substring_index(substring_index(attr.SSRQ,',',b.help_topic_id+1),',',-1) SSRQ
|
||||||
from sar_stand_attr_info attr
|
from sar_stand_attr_info attr
|
||||||
join mysql.help_topic b
|
join mysql.help_topic b
|
||||||
on b.help_topic_id < (length(attr.SSRQ) - length(replace(attr.SSRQ,',',''))+1)
|
on b.help_topic_id > (length(attr.SSRQ) - length(replace(attr.SSRQ,',',''))+1)
|
||||||
|
|
||||||
UNION ALL
|
UNION ALL
|
||||||
|
|
||||||
select attr.STAND_ID as lawId,'XCXSSRQ' as timeName,
|
select attr.STAND_ID as lawId,'-1' as itemId,'XCXSSRQ' as timeName,
|
||||||
substring_index(substring_index(attr.SSRQ,',',b.help_topic_id+1),',',-1) SSRQ
|
substring_index(substring_index(attr.SSRQ,',',b.help_topic_id+1),',',-1) SSRQ
|
||||||
from sar_stand_attr_info attr
|
from sar_stand_attr_info attr
|
||||||
join mysql.help_topic b
|
join mysql.help_topic b
|
||||||
on b.help_topic_id < (length(attr.XCXSSRQ) - length(replace(attr.SSRQ,',',''))+1)
|
on b.help_topic_id > (length(attr.XCXSSRQ) - length(replace(attr.XCXSSRQ,',',''))+1)
|
||||||
UNION ALL
|
|
||||||
select attr.STAND_ID as lawId,'ZCCSSRQ' as timeName,
|
|
||||||
substring_index(substring_index(attr.ZCCSSRQ,',',b.help_topic_id+1),',',-1) SSRQ
|
|
||||||
from sar_stand_attr_info attr
|
UNION ALL
|
||||||
join mysql.help_topic b
|
select attr.STAND_ID as lawId,'-1' as itemId,'ZCCSSRQ' as timeName,
|
||||||
on b.help_topic_id < (length(attr.SSRQ) - length(replace(attr.SSRQ,',',''))+1)
|
substring_index(substring_index(attr.ZCCSSRQ,',',b.help_topic_id+1),',',-1) SSRQ
|
||||||
|
from sar_stand_attr_info attr
|
||||||
|
join mysql.help_topic b
|
||||||
|
on b.help_topic_id > (length(attr.SSRQ) - length(replace(attr.ZCCSSRQ,',',''))+1)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
UNION All
|
||||||
|
select item.STAND_ID as lawId,item.ID as itemId,'ZCCSSRQ' as timeName,
|
||||||
|
substring_index(substring_index(item.ZCCSSRQ,',',b.help_topic_id+1),',',-1) SSRQ
|
||||||
|
from sar_stand_items item
|
||||||
|
join mysql.help_topic b
|
||||||
|
on b.help_topic_id > (length(item.ZCCSSRQ) - length(replace(item.ZCCSSRQ,',',''))+1)
|
||||||
|
|
||||||
|
UNION All
|
||||||
|
select item.STAND_ID as lawId,item.ID as itemId,'XCXSSRQ' as timeName,
|
||||||
|
substring_index(substring_index(item.XCXSSRQ,',',b.help_topic_id+1),',',-1) SSRQ
|
||||||
|
from sar_stand_items item
|
||||||
|
join mysql.help_topic b
|
||||||
|
on b.help_topic_id > (length(item.XCXSSRQ) - length(replace(item.XCXSSRQ,',',''))+1)
|
||||||
|
|
||||||
) as T
|
) as T
|
||||||
WHERE
|
WHERE
|
||||||
|
|||||||
+3
@@ -758,6 +758,9 @@
|
|||||||
(trim(replace(concat(SAR_STANDARDS_INFO.STAND_SORT,' ',SAR_STANDARDS_INFO.STAND_NUMBER,'-',
|
(trim(replace(concat(SAR_STANDARDS_INFO.STAND_SORT,' ',SAR_STANDARDS_INFO.STAND_NUMBER,'-',
|
||||||
SAR_STANDARDS_INFO.STAND_YEAR),' ','')) like trim(replace(concat(concat('%',#{page.standNumber}),'%'),' ','')) and SAR_STANDARDS_INFO.STAND_YEAR != '')
|
SAR_STANDARDS_INFO.STAND_YEAR),' ','')) like trim(replace(concat(concat('%',#{page.standNumber}),'%'),' ','')) and SAR_STANDARDS_INFO.STAND_YEAR != '')
|
||||||
or (trim(replace(concat(SAR_STANDARDS_INFO.STAND_SORT,' ',SAR_STANDARDS_INFO.STAND_NUMBER),' ','')) like trim(replace(concat(concat('%',#{page.standNumber}),'%'),' ',''))
|
or (trim(replace(concat(SAR_STANDARDS_INFO.STAND_SORT,' ',SAR_STANDARDS_INFO.STAND_NUMBER),' ','')) like trim(replace(concat(concat('%',#{page.standNumber}),'%'),' ',''))
|
||||||
|
<if test="mark == 996">
|
||||||
|
or (stand_name like concat(concat('%',#{page.standNumber}),'%'))
|
||||||
|
</if>
|
||||||
)
|
)
|
||||||
<!-- and SAR_STANDARDS_INFO.STAND_YEAR = ''-->
|
<!-- and SAR_STANDARDS_INFO.STAND_YEAR = ''-->
|
||||||
<!-- or (stand_name like concat(concat('%',#{page.standNumber}),'%')) -->
|
<!-- or (stand_name like concat(concat('%',#{page.standNumber}),'%')) -->
|
||||||
|
|||||||
Reference in New Issue
Block a user