This commit is contained in:
mmrbnjd
2024-04-13 15:03:27 +03:30
parent 3818cb7636
commit eaf3264c6c
7 changed files with 70 additions and 7 deletions

View File

@@ -34,7 +34,7 @@
<ItemGroup>
<Reference Include="Service">
<HintPath>..\..\Dlls\Service.dll</HintPath>
<HintPath>..\..\..\LocalGit\TaxPayerTools\Service\bin\Debug\Service.dll</HintPath>
</Reference>
</ItemGroup>

View File

@@ -0,0 +1,23 @@
using Back.Common.Enums;
using Back.Data.Models;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Shared.DTOs;
namespace Back.Controllers
{
[Route("api/[controller]")]
[Authorize]
[ApiController]
public class TicketController : ControllerBase
{
[HttpPost("NewTicketNoAuthentication")]
[AllowAnonymous]
public async Task<ActionResult<int>> NewTicketNoAuthentication(CTicketNoAuthenticationDto item)
{
return Ok();
}
}
}

18
Shared/DTOs/CTicketDto.cs Normal file
View File

@@ -0,0 +1,18 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Shared.DTOs
{
public class CTicketDto
{
public string CompanyID { get; set; }
[Required]
public string Title { get; set; }
[Required]
public string Text { get; set; }
}
}

View File

@@ -0,0 +1,17 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Shared.DTOs
{
public class CTicketNoAuthenticationDto:CTicketDto
{
[Required]
public string Mobile { get; set; }
[Required]
public string FullName { get; set; }
}
}

View File

@@ -35,25 +35,25 @@
<div class="col-12">
<div class="postbox__comment-input mb-30">
<InputText @bind-Value="modelTaxTools.cn" id="cn" type="text" class="inputText" required="" />
<span class="floating-label">cn</span>
<span class="floating-label">نام شرکت به حالت فینگلیش</span>
</div>
</div>
<div class="col-12">
<div class="postbox__comment-input mb-30">
<InputText @bind-Value="modelTaxTools.sn" id="sn" type="text" class="inputText" required="" />
<span class="floating-label">sn</span>
<span class="floating-label">شناسه ملی شرکت</span>
</div>
</div>
<div class="col-12">
<div class="postbox__comment-input mb-35">
<InputText @bind-Value="modelTaxTools.company" id="company" type="text" class="inputText" required="" />
<span class="floating-label">Company</span>
<span class="floating-label">نام شرکت به فارسی</span>
</div>
</div>
<div class="col-12">
<div class="postbox__comment-input mb-35">
<InputText @bind-Value="modelTaxTools.Mobile" id="Mobile" type="text" class="inputText" required="" />
<span class="floating-label">Mobile</span>
<span class="floating-label">موبایل</span>
</div>
</div>
<div class="col-xxl-6">

View File

@@ -0,0 +1,5 @@
<h3>Verification</h3>
@code {
}

View File

@@ -7,9 +7,9 @@ var builder = WebAssemblyHostBuilder.CreateDefault(args);
builder.RootComponents.Add<App>("#app");
builder.RootComponents.Add<HeadOutlet>("head::after");
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");