This commit is contained in:
MeysamMoghaddam
2025-10-13 22:40:23 +03:30
parent 560694fc28
commit 8abb5dcd5b
9 changed files with 50 additions and 45 deletions

View File

@@ -0,0 +1,5 @@
namespace FrontOffice.Main.Shared;
internal class OrganizationChartLevel
{
}

View File

@@ -1,6 +1,4 @@
@inject IJSRuntime JSRuntime
<div class="org-chart-container">
<div class="org-chart-container">
<div class="org-tree">
<div class="org-node root-node" id="root-node">
<div class="node-card">
@@ -41,6 +39,3 @@
}
</div>
</div>

View File

@@ -1,6 +1,6 @@
using static FrontOffice.Main.Shared.OrganizationChartLevel;
using static FrontOffice.Main.Pages.Profile.Components.OrganizationChartLevel;
namespace FrontOffice.Main.Shared;
namespace FrontOffice.Main.Pages.Profile.Components;
public partial class OrganizationChart
{
private UserNode? _currentUser;

View File

@@ -1,4 +1,4 @@
.org-chart-container {
.org-chart-container {
width: 100%;
height: 600px;
overflow: auto;

View File

@@ -1,4 +1,4 @@

<div class="org-level" id="level-@Level">
@foreach (var node in Nodes)
{

View File

@@ -1,7 +1,7 @@
using Microsoft.AspNetCore.Components;
using MudBlazor;
namespace FrontOffice.Main.Shared;
namespace FrontOffice.Main.Pages.Profile.Components;
public partial class OrganizationChartLevel
{
[Parameter] public List<UserNode>? Nodes { get; set; }

View File

@@ -1,4 +1,4 @@
/* Organization Chart Level Styles */
/* Organization Chart Level Styles */
.org-level {
display: flex;
justify-content: center;
@@ -10,7 +10,7 @@
margin-right: auto;
}
.org-level::before {
.org-level::before {
content: '';
position: absolute;
top: -80px;
@@ -19,9 +19,9 @@
width: 2px;
height: 40px;
background: #ddd;
}
}
.org-level::after {
.org-level::after {
content: '';
position: absolute;
top: -40px;
@@ -30,7 +30,7 @@
height: 2px;
background: #ddd;
z-index: 1;
}
}
/* Node styles for levels */
.org-node {
@@ -63,10 +63,10 @@
transition: all 0.3s ease;
}
.node-card:hover {
.node-card:hover {
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
border-color: #e0e0e0;
}
}
.node-avatar {
position: relative;
@@ -93,10 +93,10 @@
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}
.expand-btn:hover {
.expand-btn:hover {
background: #026a9e;
transform: translateX(-50%) scale(1.1);
}
}
.node-info {
text-align: center;
@@ -113,9 +113,9 @@
font-size: 12px;
}
.node-amounts > div {
.node-amounts > div {
margin-bottom: 4px;
}
}
.personal-amount {
color: #0380C0;
@@ -171,6 +171,7 @@
opacity: 0;
transform: translateY(-10px);
}
to {
opacity: 1;
transform: translateY(0);

View File

@@ -8,6 +8,7 @@
@using Microsoft.JSInterop
@using FrontOffice.Main
@using FrontOffice.Main.Shared
@using FrontOffice.Main.Pages.Profile.Components
@using MudBlazor
@using FrontOffice.Main.Utilities
@using DateTimeConverterCL

View File

@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FrontOffice.Main", "FrontOffice.Main\FrontOffice.Main.csproj", "{D9407E46-027D-4D44-B9FB-1F8DECB14270}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FrontOffice.Main", "FrontOffice.Main\FrontOffice.Main.csproj", "{D9407E46-027D-4D44-B9FB-1F8DECB14270}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -19,4 +19,7 @@ Global
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {1181A173-0937-4AB5-981F-593546434A02}
EndGlobalSection
EndGlobal