This commit is contained in:
2021-06-01 10:55:21 +08:00
2 changed files with 4 additions and 5 deletions

View File

@@ -358,9 +358,9 @@ namespace Ewide.Core.Service
{
var org = await _sysOrgRep.FirstOrDefaultAsync(o => o.Id == orgId);
if (dataScopeType == (int)DataScopeType.AREA_WITH_CHILD)
return await _sysOrgRep.DetachedEntities.Where(p => p.AreaCode.StartsWith(org.Code)).Select(p => p.Id).ToListAsync();
return await _sysOrgRep.DetachedEntities.Where(p => p.AreaCode.StartsWith(org.AreaCode)).Select(p => p.Id).ToListAsync();
if (dataScopeType == (int)DataScopeType.AREA)
return await _sysOrgRep.DetachedEntities.Where(p => p.AreaCode == org.Code).Select(p => p.Id).ToListAsync();
return await _sysOrgRep.DetachedEntities.Where(p => p.AreaCode == org.AreaCode).Select(p => p.Id).ToListAsync();
return new List<string>();
}
public async Task<List<string>> GetAreaDataScopeIdListWithoutChildrenArea(string areaNumberCode)