order by fix

This commit is contained in:
MaxKey
2021-07-31 12:37:11 +08:00
parent a34d838b8e
commit 735717387e
8 changed files with 22 additions and 5 deletions

View File

@@ -16,9 +16,12 @@
package org.maxkey.persistence.mapper;
import java.util.List;
import org.apache.mybatis.jpa.persistence.IJpaBaseMapper;
import org.maxkey.entity.Organizations;
public interface OrganizationsMapper extends IJpaBaseMapper<Organizations> {
public List<Organizations> queryOrgs(Organizations organization);
}

View File

@@ -83,6 +83,10 @@ public class OrganizationsService extends JpaBaseService<Organizations>{
return false;
}
public List<Organizations> queryOrgs(Organizations organization){
return getMapper().queryOrgs(organization);
}
public boolean delete(Organizations organization) {
if(super.delete(organization)){
kafkaPersistService.send(

View File

@@ -207,7 +207,7 @@
type
)
select
concat_ws('-','UD','${id}',u.id) id,
concat('${id}',u.id) id,
'${id}' groupid,
u.id memberid,
'USER-DYNAMIC' TYPE

View File

@@ -20,14 +20,24 @@
<select id="queryPageResults" parameterType="Organizations" resultType="Organizations">
<select id="queryOrgs" parameterType="Organizations" resultType="Organizations">
select
*
from mxk_organizations
where 1 = 1
<include refid="dao_where_statement"/>
order by sortindex
</select>
<select id="queryPageResults" parameterType="Organizations" resultType="Organizations">
select
*
from mxk_organizations
where 1 = 1
<include refid="dao_where_statement"/>
order by sortindex
</select>
<update id="logisticDelete" parameterType="Organizations" >
update mxk_organizations set status = '2'

View File

@@ -209,7 +209,7 @@
type
)
select
concat_ws('-','UD','${id}',u.id) id,
concat('${id}',u.id) id,
'${id}' ROLEID,
u.id memberid,
'USER-DYNAMIC' type

View File

@@ -68,7 +68,7 @@
<if test="departmentId != null and departmentId != ''">
and departmentid = #{departmentId}
</if>
order by sortorder
order by sortorder,id
</select>
<update id="locked" parameterType="UserInfo" >