...
This commit is contained in:
@@ -36,7 +36,7 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Service">
|
<Reference Include="Service">
|
||||||
<HintPath>..\..\Dlls\Service.dll</HintPath>
|
<HintPath>..\..\..\LocalGit\TaxPayerTools\Service\bin\Debug\Service.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
@@ -12,6 +12,7 @@ namespace Front
|
|||||||
private List<CODIdName<int>>? Cods = null;
|
private List<CODIdName<int>>? Cods = null;
|
||||||
private CompanyDTO? InfoCompany = null;
|
private CompanyDTO? InfoCompany = null;
|
||||||
public InvoiceDTO? invoice { get; set; }=null;
|
public InvoiceDTO? invoice { get; set; }=null;
|
||||||
|
private DashBoardDTO? dashBoard { get; set; } = null;
|
||||||
public Fixedvalues(HttpClientController hc)
|
public Fixedvalues(HttpClientController hc)
|
||||||
{
|
{
|
||||||
_hc = hc;
|
_hc = hc;
|
||||||
@@ -73,5 +74,20 @@ namespace Front
|
|||||||
|
|
||||||
return InfoCompany;
|
return InfoCompany;
|
||||||
}
|
}
|
||||||
|
public async Task<DashBoardDTO?> GetDashBoard()
|
||||||
|
{
|
||||||
|
|
||||||
|
if (dashBoard == null)
|
||||||
|
{
|
||||||
|
var rsp = await _hc.Get("User/GetDashBoard");
|
||||||
|
if (rsp.IsSuccessStatusCode)
|
||||||
|
{
|
||||||
|
dashBoard = await rsp.Content.ReadFromJsonAsync<DashBoardDTO>();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
return dashBoard;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -6,6 +6,7 @@
|
|||||||
@inject HttpClient _hc
|
@inject HttpClient _hc
|
||||||
@inject NavigationManager nav
|
@inject NavigationManager nav
|
||||||
@inject localService localserv;
|
@inject localService localserv;
|
||||||
|
@inject Fixedvalues fv;
|
||||||
<HeadContent>
|
<HeadContent>
|
||||||
<link rel="canonical" href="#">
|
<link rel="canonical" href="#">
|
||||||
<!-- Favicon -->
|
<!-- Favicon -->
|
||||||
@@ -180,7 +181,11 @@
|
|||||||
<footer class="content-footer footer bg-footer-theme">
|
<footer class="content-footer footer bg-footer-theme">
|
||||||
<div class="container-xxl d-flex flex-wrap justify-content-between py-2 flex-md-row flex-column">
|
<div class="container-xxl d-flex flex-wrap justify-content-between py-2 flex-md-row flex-column">
|
||||||
<div class="mb-2 mb-md-0">
|
<div class="mb-2 mb-md-0">
|
||||||
<span>کپی رایت با <a href="#">مهدی</a> – 2023</span>
|
@if (@dashBoard!=null)
|
||||||
|
{
|
||||||
|
<span>آخرین ورود : @dashBoard?.LastLoginDate</span>
|
||||||
|
}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<NavLink style="cursor:pointer" onclick="@Logout">
|
<NavLink style="cursor:pointer" onclick="@Logout">
|
||||||
@@ -200,8 +205,17 @@
|
|||||||
<div class="layout-overlay layout-menu-toggle"></div>
|
<div class="layout-overlay layout-menu-toggle"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@code {
|
||||||
|
public DashBoardDTO? dashBoard { get; set; }
|
||||||
|
protected override async Task OnInitializedAsync()
|
||||||
|
{
|
||||||
|
if (!await localserv.OnlineUser())
|
||||||
|
nav.NavigateTo("/");
|
||||||
|
|
||||||
|
dashBoard = await fv.GetDashBoard();
|
||||||
|
await base.OnInitializedAsync();
|
||||||
|
}
|
||||||
|
}
|
||||||
@functions {
|
@functions {
|
||||||
private async Task Logout()
|
private async Task Logout()
|
||||||
{
|
{
|
||||||
|
@@ -71,6 +71,20 @@
|
|||||||
tsstamArray = fv.invoice.items.Select(s => s.tsstam?.ToString("N0")).ToArray();
|
tsstamArray = fv.invoice.items.Select(s => s.tsstam?.ToString("N0")).ToArray();
|
||||||
vraArray = fv.invoice.items.Select(s => s.vra?.ToString("N0")).ToArray();
|
vraArray = fv.invoice.items.Select(s => s.vra?.ToString("N0")).ToArray();
|
||||||
|
|
||||||
|
|
||||||
|
//How to activate
|
||||||
|
Stimulsoft.Base.StiLicense.Key =
|
||||||
|
"6vJhGtLLLz2GNviWmUTrhSqnOItdDwjBylQzQcAOiHn0s4gy0Fr5YoUZ9V00Y0igCSFQzwEqYBh/N77k" +
|
||||||
|
"4f0fWXTHW5rqeBNLkaurJDenJ9o97TyqHs9HfvINK18Uwzsc/bG01Rq+x3H3Rf+g7AY92gvWmp7VA2Ux" +
|
||||||
|
"a30Q97f61siWz2dE5kdBVcCnSFzC6awE74JzDcJMj8OuxplqB1CYcpoPcOjKy1PiATlC3UsBaLEXsok1" +
|
||||||
|
"xxtRMQ283r282tkh8XQitsxtTczAJBxijuJNfziYhci2jResWXK51ygOOEbVAxmpflujkJ8oEVHkOA/C" +
|
||||||
|
"jX6bGx05pNZ6oSIu9H8deF94MyqIwcdeirCe60GbIQByQtLimfxbIZnO35X3fs/94av0ODfELqrQEpLr" +
|
||||||
|
"pU6FNeHttvlMc5UVrT4K+8lPbqR8Hq0PFWmFrbVIYSi7tAVFMMe2D1C59NWyLu3AkrD3No7YhLVh7LV0" +
|
||||||
|
"Tttr/8FrcZ8xirBPcMZCIGrRIesrHxOsZH2V8t/t0GXCnLLAWX+TNvdNXkB8cF2y9ZXf1enI064yE5dw" +
|
||||||
|
"Ms2fQ0yOUG/xornE";
|
||||||
|
//var licenseStream = await Http.GetStreamAsync("Secret/license.key");
|
||||||
|
//Stimulsoft.Base.StiLicense.LoadFromStream(licenseStream);
|
||||||
|
|
||||||
//Create empty report object
|
//Create empty report object
|
||||||
this.Report = new StiReport();
|
this.Report = new StiReport();
|
||||||
|
|
||||||
|
@@ -6,6 +6,7 @@
|
|||||||
@inject NavigationManager nav
|
@inject NavigationManager nav
|
||||||
@layout PanelLayout
|
@layout PanelLayout
|
||||||
@inject HttpClientController hc;
|
@inject HttpClientController hc;
|
||||||
|
@inject Fixedvalues fv;
|
||||||
<PageTitle>کاربری</PageTitle>
|
<PageTitle>کاربری</PageTitle>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@@ -641,12 +642,12 @@
|
|||||||
if (!await localserv.OnlineUser())
|
if (!await localserv.OnlineUser())
|
||||||
nav.NavigateTo("/");
|
nav.NavigateTo("/");
|
||||||
|
|
||||||
|
dashBoard =await fv.GetDashBoard();
|
||||||
var rsp = await hc.Get("User/GetDashBoard");
|
//var rsp = await hc.Get("User/GetDashBoard");
|
||||||
if (rsp.IsSuccessStatusCode)
|
// if (rsp.IsSuccessStatusCode)
|
||||||
{
|
// {
|
||||||
dashBoard = await rsp.Content.ReadFromJsonAsync<DashBoardDTO>();
|
// dashBoard = await rsp.Content.ReadFromJsonAsync<DashBoardDTO>();
|
||||||
}
|
// }
|
||||||
|
|
||||||
await base.OnInitializedAsync();
|
await base.OnInitializedAsync();
|
||||||
}
|
}
|
||||||
|
@@ -34,9 +34,9 @@ builder.Services.AddScoped(sp => new UserAuthenticationDTO()
|
|||||||
}) ;
|
}) ;
|
||||||
|
|
||||||
|
|
||||||
builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri("https://localhost:7075/api/") });
|
//builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri("https://localhost:7075/api/") });
|
||||||
|
|
||||||
//builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri("http://localhost:5271/api/") });
|
builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri("http://localhost:5271/api/") });
|
||||||
|
|
||||||
CultureInfo.DefaultThreadCurrentCulture = new CultureInfo("fa-Ir");
|
CultureInfo.DefaultThreadCurrentCulture = new CultureInfo("fa-Ir");
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user