add test page

This commit is contained in:
2025-12-29 00:00:20 +03:30
parent b69691c84f
commit 3ca7b7df9a
6 changed files with 2017 additions and 21 deletions

View File

@@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>net9.0</TargetFramework>

View File

@@ -0,0 +1 @@
TY09192530212#ghback.nabaksoft.ir/calltest.amr

View File

@@ -0,0 +1 @@
TT09192530212#سلام خوبی

View File

@@ -5,6 +5,7 @@ using GreenHome.Infrastructure;
using GreenHome.Sms.Ippanel;
using GreenHome.VoiceCall.Avanak;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.FileProviders;
using Scalar.AspNetCore;
var builder = WebApplication.CreateBuilder(args);
@@ -98,17 +99,21 @@ using (var scope = app.Services.CreateScope())
// Configure the HTTP request pipeline.
app.MapOpenApi();
app.MapScalarApiReference();
// HTTPS Redirection فقط در Production
if (!app.Environment.IsDevelopment())
{
app.UseHttpsRedirection();
}
app.UseCors(CorsPolicy);
app.UseAuthorization();
app.UseStaticFiles(new StaticFileOptions
{
FileProvider = new PhysicalFileProvider(
Path.Combine(builder.Environment.ContentRootPath, "My_StaticFiles")),
RequestPath = "/My_StaticFiles"
});
app.MapControllers();
app.Run();
app.Run();