diff --git a/ds-wms-service/DS.WMS.Core/Sys/Method/ClientCommonService.cs b/ds-wms-service/DS.WMS.Core/Sys/Method/ClientCommonService.cs index 13120682..1b4c496d 100644 --- a/ds-wms-service/DS.WMS.Core/Sys/Method/ClientCommonService.cs +++ b/ds-wms-service/DS.WMS.Core/Sys/Method/ClientCommonService.cs @@ -1727,7 +1727,13 @@ public class ClientCommonService : IClientCommonService /// public DataResult> GetDeptList(string orgId = "", string queryKey = "") { - var ids = GetOrgIdsByParent(long.Parse(orgId), db); + + //var ids = GetOrgIdsByParent(long.Parse(orgId), db); + var ids = new List(); + if (orgId.IsNotEmptyOrNull()) + { + ids = GetOrgIdsByParent(long.Parse(orgId), db); + } //a.ParentId == long.Parse(orgId) var list = db.Queryable() .WhereIF(orgId.IsNotEmptyOrNull(), a => ids.Contains(a.Id) )