Skip to content

Commit

Permalink
Merge pull request thinkgem#217 from fengxiang1990/master
Browse files Browse the repository at this point in the history
更新一些小BUG
  • Loading branch information
think-gem committed Dec 3, 2015
2 parents 6c5ea82 + b3612e8 commit 55383cc
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
*/
package com.thinkgem.jeesite.modules.sys.service;

import java.util.ArrayList;
import java.util.List;

import org.springframework.stereotype.Service;
Expand Down Expand Up @@ -36,8 +37,11 @@ public List<Office> findList(Boolean isAll){

@Transactional(readOnly = true)
public List<Office> findList(Office office){
office.setParentIds(office.getParentIds()+"%");
return dao.findByParentIdsLike(office);
if(office != null){
office.setParentIds(office.getParentIds()+"%");
return dao.findByParentIdsLike(office);
}
return new ArrayList<Office>();
}

@Transactional(readOnly = false)
Expand Down
8 changes: 4 additions & 4 deletions src/main/resources/mappings/modules/sys/UserDao.xml
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,10 @@
</sql>

<sql id="userJoins">
JOIN sys_office c ON c.id = a.company_id
JOIN sys_area ca ON ca.id = c.area_id
JOIN sys_office o ON o.id = a.office_id
JOIN sys_area oa ON oa.id = o.area_id
LEFT JOIN sys_office c ON c.id = a.company_id
LEFT JOIN sys_area ca ON ca.id = c.area_id
LEFT JOIN sys_office o ON o.id = a.office_id
LEFT JOIN sys_area oa ON oa.id = o.area_id
LEFT JOIN sys_user cu ON cu.id = c.primary_person
LEFT JOIN sys_user cu2 ON cu2.id = c.deputy_person
LEFT JOIN sys_user ou ON ou.id = o.primary_person
Expand Down

0 comments on commit 55383cc

Please sign in to comment.