This commit is contained in:
MaxKey
2021-07-18 18:49:32 +08:00
parent 7377112465
commit 27f1243402
46 changed files with 747 additions and 141 deletions

View File

@@ -0,0 +1,30 @@
/*
* Copyright [2020] [MaxKey of copyright http://www.maxkey.top]
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.maxkey.persistence.mapper;
import org.apache.mybatis.jpa.persistence.IJpaBaseMapper;
import org.maxkey.entity.HistoryConnector;
/**
* @author Crystal.sea
*
*/
public interface HistoryConnectorMapper extends IJpaBaseMapper<HistoryConnector> {
}

View File

@@ -0,0 +1,40 @@
/*
* Copyright [2021] [MaxKey of copyright http://www.maxkey.top]
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.maxkey.persistence.service;
import org.apache.mybatis.jpa.persistence.JpaBaseService;
import org.maxkey.entity.HistoryConnector;
import org.maxkey.persistence.mapper.HistoryConnectorMapper;
import org.springframework.stereotype.Repository;
@Repository
public class HistoryConnectorService extends JpaBaseService<HistoryConnector>{
public HistoryConnectorService() {
super(HistoryConnectorMapper.class);
}
/* (non-Javadoc)
* @see com.connsec.db.service.BaseService#getMapper()
*/
@Override
public HistoryConnectorMapper getMapper() {
// TODO Auto-generated method stub
return (HistoryConnectorMapper)super.getMapper();
}
}

View File

@@ -45,11 +45,7 @@
u.jobtitle,
u.joblevel,
u.createdby,
u.createddate,
u.modifiedby,
u.modifieddate,
u.status
from
@@ -89,16 +85,12 @@
u.jobtitle,
u.joblevel,
u.createdby,
u.createddate,
u.modifiedby,
u.modifieddate,
gm.createddate,
u.status
from
mxk_userinfo u,
`mxk_groups` g,
mxk_groups g,
mxk_group_member gm
where 1 = 1
<if test="groupId != null and groupId != ''">

View File

@@ -0,0 +1,62 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.maxkey.persistence.mapper.HistoryConnectorMapper" >
<sql id="where_statement">
<if test="id != null and id != ''">
and id = #{id}
</if>
<if test="conName != null and conName != ''">
and conName = #{conName}
</if>
<if test="conType != null and conType != ''">
and conType = #{conType}
</if>
<if test="sourceId != null and sourceId != ''">
and sourceId = #{sourceId}
</if>
<if test="sourceName != null and sourceName != ''">
and sourceName = #{sourceName}
</if>
<if test="objectId != null and objectId != ''">
and objectId = #{objectId}
</if>
<if test="objectName != null and objectName != ''">
and objectname = #{objectName}
</if>
<if test="result != null and result != ''">
and result = #{result}
</if>
<if test="startDate != null and startDate != ''">
and synctime >= #{startDate}
</if>
<if test="endDate != null and endDate != ''">
and #{endDate} >= synctime
</if>
<if test="description != null and description != ''">
and description like '%${description}%'
</if>
</sql>
<select id="queryPageResults" parameterType="HistoryConnector" resultType="HistoryConnector">
select
*
from mxk_history_connector
where 1 = 1
<include refid="where_statement"/>
order by synctime desc
</select>
</mapper>

View File

@@ -45,11 +45,7 @@
u.jobtitle,
u.joblevel,
u.createdby,
u.createddate,
u.modifiedby,
u.modifieddate,
u.status
from
@@ -90,10 +86,7 @@
u.joblevel,
u.createdby,
u.createddate,
u.modifiedby,
u.modifieddate,
rm.createddate,
u.status
from