แก้บั้กออกคำสั่งบรรจุ
This commit is contained in:
parent
7d88274dae
commit
99485f64e0
4 changed files with 33 additions and 10 deletions
|
|
@ -28,7 +28,7 @@ namespace BMA.EHR.Application.Repositories
|
|||
|
||||
#region " Methods "
|
||||
|
||||
public string GetOrganizationNameFullPath(Guid id, bool showRoot = false, bool descending = false)
|
||||
public string GetOrganizationNameFullPath(Guid id, bool showRoot = false, bool descending = false,string seperator = " ")
|
||||
{
|
||||
try
|
||||
{
|
||||
|
|
@ -39,7 +39,7 @@ namespace BMA.EHR.Application.Repositories
|
|||
var ret = String.Empty;
|
||||
foreach (var oc in ocList)
|
||||
{
|
||||
ret = oc.Name + " " + ret;
|
||||
ret = oc.Name + seperator + ret;
|
||||
}
|
||||
if (ret.Length > 2)
|
||||
ret = ret.Substring(0, ret.Length - 1);
|
||||
|
|
@ -65,7 +65,7 @@ namespace BMA.EHR.Application.Repositories
|
|||
{
|
||||
Id = x.Id,
|
||||
Name = x.OrganizationOrganization!.Name,
|
||||
ParentId = x.Parent!.Id
|
||||
ParentId = x.Parent == null ? Guid.Empty : x.Parent!.Id
|
||||
})
|
||||
.FirstOrDefault(x => x.Id == id);
|
||||
|
||||
|
|
@ -81,7 +81,7 @@ namespace BMA.EHR.Application.Repositories
|
|||
//else
|
||||
// ocList.Add(new OrganizationItem { Id = oc.OCId, Name = oc.OrganizationName });
|
||||
|
||||
if (ocData.ParentId != null)
|
||||
if (ocData.ParentId != Guid.Empty)
|
||||
{
|
||||
ocList.AddRange(GetOCWithFullPath(ocData.ParentId, showRoot));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue