diff --git "a/\346\235\216\350\202\262\345\245\207/.gitignore" "b/\346\235\216\350\202\262\345\245\207/.gitignore" new file mode 100644 index 0000000000000000000000000000000000000000..3e8a1553fcff7845c779d3cb8014e151a9931506 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/.gitignore" @@ -0,0 +1,341 @@ +## Ignore Visual Studio temporary files, build results, and +## files generated by popular Visual Studio add-ons. +## +## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore + +# User-specific files +*.rsuser +*.suo +*.user +*.userosscache +*.sln.docstates + +# User-specific files (MonoDevelop/Xamarin Studio) +*.userprefs + +# Build results +[Dd]ebug/ +[Dd]ebugPublic/ +[Rr]elease/ +[Rr]eleases/ +x64/ +x86/ +[Aa][Rr][Mm]/ +[Aa][Rr][Mm]64/ +bld/ +[Bb]in/ +[Oo]bj/ +[Ll]og/ + +# Visual Studio 2015/2017 cache/options directory +.vs/ +# Uncomment if you have tasks that create the project's static files in wwwroot +#wwwroot/ + +# Visual Studio 2017 auto generated files +Generated\ Files/ + +# MSTest test Results +[Tt]est[Rr]esult*/ +[Bb]uild[Ll]og.* + +# NUNIT +*.VisualState.xml +TestResult.xml + +# Build Results of an ATL Project +[Dd]ebugPS/ +[Rr]eleasePS/ +dlldata.c + +# Benchmark Results +BenchmarkDotNet.Artifacts/ + +# .NET Core +project.lock.json +project.fragment.lock.json +artifacts/ + +# StyleCop +StyleCopReport.xml + +# Files built by Visual Studio +*_i.c +*_p.c +*_h.h +*.ilk +*.meta +*.obj +*.iobj +*.pch +*.pdb +*.ipdb +*.pgc +*.pgd +*.rsp +*.sbr +*.tlb +*.tli +*.tlh +*.tmp +*.tmp_proj +*_wpftmp.csproj +*.log +*.vspscc +*.vssscc +.builds +*.pidb +*.svclog +*.scc + +# Chutzpah Test files +_Chutzpah* + +# Visual C++ cache files +ipch/ +*.aps +*.ncb +*.opendb +*.opensdf +*.sdf +*.cachefile +*.VC.db +*.VC.VC.opendb + +# Visual Studio profiler +*.psess +*.vsp +*.vspx +*.sap + +# Visual Studio Trace Files +*.e2e + +# TFS 2012 Local Workspace +$tf/ + +# Guidance Automation Toolkit +*.gpState + +# ReSharper is a .NET coding add-in +_ReSharper*/ +*.[Rr]e[Ss]harper +*.DotSettings.user + +# JustCode is a .NET coding add-in +.JustCode + +# TeamCity is a build add-in +_TeamCity* + +# DotCover is a Code Coverage Tool +*.dotCover + +# AxoCover is a Code Coverage Tool +.axoCover/* +!.axoCover/settings.json + +# Visual Studio code coverage results +*.coverage +*.coveragexml + +# NCrunch +_NCrunch_* +.*crunch*.local.xml +nCrunchTemp_* + +# MightyMoose +*.mm.* +AutoTest.Net/ + +# Web workbench (sass) +.sass-cache/ + +# Installshield output folder +[Ee]xpress/ + +# DocProject is a documentation generator add-in +DocProject/buildhelp/ +DocProject/Help/*.HxT +DocProject/Help/*.HxC +DocProject/Help/*.hhc +DocProject/Help/*.hhk +DocProject/Help/*.hhp +DocProject/Help/Html2 +DocProject/Help/html + +# Click-Once directory +publish/ + +# Publish Web Output +*.[Pp]ublish.xml +*.azurePubxml +# Note: Comment the next line if you want to checkin your web deploy settings, +# but database connection strings (with potential passwords) will be unencrypted +*.pubxml +*.publishproj + +# Microsoft Azure Web App publish settings. Comment the next line if you want to +# checkin your Azure Web App publish settings, but sensitive information contained +# in these scripts will be unencrypted +PublishScripts/ + +# NuGet Packages +*.nupkg +# The packages folder can be ignored because of Package Restore +**/[Pp]ackages/* +# except build/, which is used as an MSBuild target. +!**/[Pp]ackages/build/ +# Uncomment if necessary however generally it will be regenerated when needed +#!**/[Pp]ackages/repositories.config +# NuGet v3's project.json files produces more ignorable files +*.nuget.props +*.nuget.targets + +# Microsoft Azure Build Output +csx/ +*.build.csdef + +# Microsoft Azure Emulator +ecf/ +rcf/ + +# Windows Store app package directories and files +AppPackages/ +BundleArtifacts/ +Package.StoreAssociation.xml +_pkginfo.txt +*.appx + +# Visual Studio cache files +# files ending in .cache can be ignored +*.[Cc]ache +# but keep track of directories ending in .cache +!?*.[Cc]ache/ + +# Others +ClientBin/ +~$* +*~ +*.dbmdl +*.dbproj.schemaview +*.jfm +*.pfx +*.publishsettings +orleans.codegen.cs + +# Including strong name files can present a security risk +# (https://github.com/github/gitignore/pull/2483#issue-259490424) +#*.snk + +# Since there are multiple workflows, uncomment next line to ignore bower_components +# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) +#bower_components/ +# ASP.NET Core default setup: bower directory is configured as wwwroot/lib/ and bower restore is true +**/wwwroot/lib/ + +# RIA/Silverlight projects +Generated_Code/ + +# Backup & report files from converting an old project file +# to a newer Visual Studio version. Backup files are not needed, +# because we have git ;-) +_UpgradeReport_Files/ +Backup*/ +UpgradeLog*.XML +UpgradeLog*.htm +ServiceFabricBackup/ +*.rptproj.bak + +# SQL Server files +*.mdf +*.ldf +*.ndf + +# Business Intelligence projects +*.rdl.data +*.bim.layout +*.bim_*.settings +*.rptproj.rsuser + +# Microsoft Fakes +FakesAssemblies/ + +# GhostDoc plugin setting file +*.GhostDoc.xml + +# Node.js Tools for Visual Studio +.ntvs_analysis.dat +node_modules/ + +# Visual Studio 6 build log +*.plg + +# Visual Studio 6 workspace options file +*.opt + +# Visual Studio 6 auto-generated workspace file (contains which files were open etc.) +*.vbw + +# Visual Studio LightSwitch build output +**/*.HTMLClient/GeneratedArtifacts +**/*.DesktopClient/GeneratedArtifacts +**/*.DesktopClient/ModelManifest.xml +**/*.Server/GeneratedArtifacts +**/*.Server/ModelManifest.xml +_Pvt_Extensions + +# Paket dependency manager +.paket/paket.exe +paket-files/ + +# FAKE - F# Make +.fake/ + +# JetBrains Rider +.idea/ +*.sln.iml + +# CodeRush personal settings +.cr/personal + +# Python Tools for Visual Studio (PTVS) +__pycache__/ +*.pyc + +# Cake - Uncomment if you are using it +# tools/** +# !tools/packages.config + +# Tabs Studio +*.tss + +# Telerik's JustMock configuration file +*.jmconfig + +# BizTalk build output +*.btp.cs +*.btm.cs +*.odx.cs +*.xsd.cs + +# OpenCover UI analysis results +OpenCover/ + +# Azure Stream Analytics local run output +ASALocalRun/ + +# MSBuild Binary and Structured Log +*.binlog + +# NVidia Nsight GPU debugger configuration file +*.nvuser + +# MFractors (Xamarin productivity tool) working folder +.mfractor/ + +# Local History for Visual Studio +.localhistory/ + +# BeatPulse healthcheck temp database +healthchecksdb diff --git "a/\346\235\216\350\202\262\345\245\207/Controllers/TestController.cs" "b/\346\235\216\350\202\262\345\245\207/Controllers/TestController.cs" new file mode 100644 index 0000000000000000000000000000000000000000..0ac4ace82925ffd14691b7331f616bfead683f04 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Controllers/TestController.cs" @@ -0,0 +1,37 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Http; +using Microsoft.AspNetCore.Mvc; +using WebApi.Domain.Entity; +using WebApi.Helper; +using WebApi.Interface; + +namespace WebApi.Controllers +{ + [Route("api/[controller]")] + [ApiController] + public class TestController : ControllerBase + { + private readonly IRespository _respository; + public TestController(IRespository respository) + { + _respository = respository; + + } + + public string Get() + { + var list = _respository.Table.ToList(); + return JsonHelper.SerializeObject(list); + } + + + + + + + + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Controllers/WeatherForecastController.cs" "b/\346\235\216\350\202\262\345\245\207/Controllers/WeatherForecastController.cs" new file mode 100644 index 0000000000000000000000000000000000000000..570b43f156d3b2075060720306368e30ba6916b7 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Controllers/WeatherForecastController.cs" @@ -0,0 +1,59 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Microsoft.Extensions.Logging; +using WebApi.Domain; +using WebApi.Domain.Entity; +using Microsoft.Extensions.DependencyInjection; +using System.Reflection; +using Microsoft.EntityFrameworkCore; +using Newtonsoft.Json; +using WebApi.Helper; + +namespace WebApi.Controllers +{ + [ApiController] + [Route("[controller]")] + public class WeatherForecastController : ControllerBase + { + + private static readonly string[] Summaries = new[] + { + "Freezing", "Bracing", "Chilly", "Cool", "Mild", "Warm", "Balmy", "Hot", "Sweltering", "Scorching" + }; + + + protected readonly Admin3000 _db; + //[ActivatorUtilitiesConstructor] + //public WeatherForecastController(Admin3000 dbContext) + //{ + // _db = dbContext; + //} + + private readonly ILogger _logger; + // + public WeatherForecastController(ILogger logger,Admin3000 dbContext) + { + _logger = logger; + _db = dbContext; + } + // + [HttpGet] + //public IEnumerable Get() + //{ + // var list = new List(); + // using (var db=new Admin3000()) + // { + // list = db.Users.ToList(); + // } + // return list; + //} + public string Get() + { + var list =_db.Users.Include(x=>x.Class).ToList(); + return JsonHelper.SerializeObject(list); + } + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Domain/Admin3000.cs" "b/\346\235\216\350\202\262\345\245\207/Domain/Admin3000.cs" new file mode 100644 index 0000000000000000000000000000000000000000..0360d38621ebd69a74c4963aeb8d1ba4eb8c9db0 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Domain/Admin3000.cs" @@ -0,0 +1,23 @@ +using Microsoft.EntityFrameworkCore; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using WebApi.Domain.Entity; + +namespace WebApi.Domain +{ + public class Admin3000:DbContext + { + public DbSet Classes { get; set; } + public DbSet Users { get; set; } + + + + protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder) + { + optionsBuilder.UseSqlServer("server=.;database=Admin4000;uid=sa;pwd=123456"); + } + + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Domain/BaseEntity.cs" "b/\346\235\216\350\202\262\345\245\207/Domain/BaseEntity.cs" new file mode 100644 index 0000000000000000000000000000000000000000..ff4e1364e5bc53e397076d04396ec1f18d9b5c4d --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Domain/BaseEntity.cs" @@ -0,0 +1,26 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; + +namespace WebApi.Domain +{ + public class BaseEntity + { + public BaseEntity() + { + CreatedTime = DateTime.Now; + UpdateTime = DateTime.Now; + IsActived = true; + IsDeleted = false; + Remarks = "Nothing"; + + } + public int Id { get; set; } + public DateTime CreatedTime { get; set; } + public DateTime UpdateTime { get; set; } + public bool IsActived { get; set; } + public bool IsDeleted { get; set; } + public string Remarks { get; set; } + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Domain/DbHeper.cs" "b/\346\235\216\350\202\262\345\245\207/Domain/DbHeper.cs" new file mode 100644 index 0000000000000000000000000000000000000000..be34343351c486259d2d1433f2edd5b4b88ccc03 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Domain/DbHeper.cs" @@ -0,0 +1,56 @@ +using Microsoft.EntityFrameworkCore.Diagnostics; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using WebApi.Domain.Entity; + +namespace WebApi.Domain +{ + public class DbHeper + { + public static void Initilize() + { + using (var db = new Admin3000()) + { + // db.Database.EnsureCreated(); + if(!db.Database.EnsureCreated()){ + var Class = new Class() + { + ClassName = "计算机一班", + ClassType = "信息与制造学院", + + }; + var Class1 = new Class() + { + ClassName = "电商三班", + ClassType = "财经商贸学院", + + }; + db.Classes.AddRange(Class, Class1); + db.SaveChanges(); + db.Users.AddRange(new Users[] + { + new Users + { + UsersName="张三", + Where="广西", + ClassId=Class.Id + }, + new Users + { + UsersName="李氏", + Where="江西", + ClassId=Class1.Id + } + + }); + db.SaveChanges(); + + } + + } + + } + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Domain/Entity/Class.cs" "b/\346\235\216\350\202\262\345\245\207/Domain/Entity/Class.cs" new file mode 100644 index 0000000000000000000000000000000000000000..c2728d381b226b86550535fdeb3a9d93e62189e3 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Domain/Entity/Class.cs" @@ -0,0 +1,14 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; + +namespace WebApi.Domain.Entity +{ + public class Class:BaseEntity + { + public string ClassName { get; set; } + public string ClassType { get; set; } + public IEnumerable Users { get; set; } + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Domain/Entity/Users.cs" "b/\346\235\216\350\202\262\345\245\207/Domain/Entity/Users.cs" new file mode 100644 index 0000000000000000000000000000000000000000..25b72e28a35d670af80afcc615ad2eec45aebd55 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Domain/Entity/Users.cs" @@ -0,0 +1,19 @@ +using Microsoft.AspNetCore.SignalR; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; + +namespace WebApi.Domain.Entity +{ + public class Users:BaseEntity + { + public string UsersName { get; set; } + public string Where { get; set; } + + + public int ClassId { get; set; } + + public Class Class { get; set; } + } +} \ No newline at end of file diff --git "a/\346\235\216\350\202\262\345\245\207/Helper/JsonHelper.cs" "b/\346\235\216\350\202\262\345\245\207/Helper/JsonHelper.cs" new file mode 100644 index 0000000000000000000000000000000000000000..fd0abf85388a9f5ca449f9b480eb273c0421afbf --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Helper/JsonHelper.cs" @@ -0,0 +1,23 @@ +using Newtonsoft.Json; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; + +namespace WebApi.Helper +{ + public class JsonHelper + { + + public static string SerializeObject(object obj) + { + return JsonConvert.SerializeObject(obj, Formatting.Indented, new JsonSerializerSettings + { + ReferenceLoopHandling = ReferenceLoopHandling.Ignore, + DateFormatString = "yyyy-MM-dd HH:mm:ss" + + }); + } + + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Interface/IRespository.cs" "b/\346\235\216\350\202\262\345\245\207/Interface/IRespository.cs" new file mode 100644 index 0000000000000000000000000000000000000000..81926fba9fc8107fbd43bab03d69d855ccbe55fa --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Interface/IRespository.cs" @@ -0,0 +1,21 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; + +namespace WebApi.Interface +{ + public interface IRespository + { + IQueryable Table { get; } + T GetbyId(int id); + + void Insert(T entity); + + void MoreInsert(IEnumerable list); + + void Update(T entity); + void Deleted(T entity); + void Deleted(int id); + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Program.cs" "b/\346\235\216\350\202\262\345\245\207/Program.cs" new file mode 100644 index 0000000000000000000000000000000000000000..a469b601b24060303cafe658ef979d01333fd0b5 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Program.cs" @@ -0,0 +1,26 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Hosting; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.Hosting; +using Microsoft.Extensions.Logging; + +namespace WebApi +{ + public class Program + { + public static void Main(string[] args) + { + CreateHostBuilder(args).Build().Run(); + } + + public static IHostBuilder CreateHostBuilder(string[] args) => + Host.CreateDefaultBuilder(args) + .ConfigureWebHostDefaults(webBuilder => + { + webBuilder.UseStartup(); + }); + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Properties/launchSettings.json" "b/\346\235\216\350\202\262\345\245\207/Properties/launchSettings.json" new file mode 100644 index 0000000000000000000000000000000000000000..e9f17b41b64f12363134f16a6b2ff08234d148cd --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Properties/launchSettings.json" @@ -0,0 +1,30 @@ +{ + "$schema": "http://json.schemastore.org/launchsettings.json", + "iisSettings": { + "windowsAuthentication": false, + "anonymousAuthentication": true, + "iisExpress": { + "applicationUrl": "http://localhost:54528", + "sslPort": 0 + } + }, + "profiles": { + "IIS Express": { + "commandName": "IISExpress", + "launchBrowser": true, + "launchUrl": "weatherforecast", + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + }, + "WebApi": { + "commandName": "Project", + "launchBrowser": true, + "launchUrl": "weatherforecast", + "applicationUrl": "http://localhost:5000", + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + } + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Realize/EfRepository.cs" "b/\346\235\216\350\202\262\345\245\207/Realize/EfRepository.cs" new file mode 100644 index 0000000000000000000000000000000000000000..c6d431b07912b64a9b7be3823f456233a39fd4b0 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Realize/EfRepository.cs" @@ -0,0 +1,80 @@ +using Microsoft.EntityFrameworkCore; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Security.Cryptography.X509Certificates; +using System.Threading.Tasks; +using WebApi.Domain; +using WebApi.Interface; + +namespace WebApi.Realize +{ + public class EfRepository : IRespository where T : BaseEntity + { + + protected readonly Admin3000 db; + + private DbSet _entity; + + private DbSet Entity + { + get + { + if (_entity == null) + { + _entity = db.Set(); + + } + return _entity; + } + } + + public IQueryable Table => Entity; + + public EfRepository(Admin3000 dbContext) + { + db = dbContext; + } + + + public void Deleted(T entity) + { + this._entity.Remove(entity); + db.SaveChanges(); + } + + public void Deleted(int id) + { + var row = Table.Where(x => x.Id == id).FirstOrDefault(); + Deleted(row); + db.SaveChanges(); + } + + + public T GetbyId(int id) + { + return _entity.Where(x => x.Id == id).FirstOrDefault(); + + + + } + + public void Insert(T entity) + { + _entity.Add(entity); + db.SaveChanges(); + } + + public void MoreInsert(IEnumerable list) + { + _entity.Add((T)list); + db.SaveChanges(); + } + + public void Update(T entity) + { + _entity.Update(entity); + db.SaveChanges(); + } + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/Startup.cs" "b/\346\235\216\350\202\262\345\245\207/Startup.cs" new file mode 100644 index 0000000000000000000000000000000000000000..0b1dfa45130f19d643c0deef0391ed5e3113bccf --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/Startup.cs" @@ -0,0 +1,56 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Builder; +using Microsoft.AspNetCore.Hosting; +using Microsoft.AspNetCore.Mvc; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.DependencyInjection; +using Microsoft.Extensions.Hosting; +using Microsoft.Extensions.Logging; +using WebApi.Domain; +using WebApi.Interface; +using WebApi.Realize; + +namespace WebApi +{ + public class Startup + { + public Startup(IConfiguration configuration) + { + Configuration = configuration; + } + + public IConfiguration Configuration { get; } + + // This method gets called by the runtime. Use this method to add services to the container. + public void ConfigureServices(IServiceCollection services) + { + services.AddDbContext(); + services.AddScoped(typeof(IRespository<>),typeof(EfRepository<>)); + services.AddControllers(); + } + + // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. + public void Configure(IApplicationBuilder app, IWebHostEnvironment env) + { + if (env.IsDevelopment()) + { + app.UseDeveloperExceptionPage(); + } + + app.UseRouting(); + + app.UseAuthorization(); + + app.UseEndpoints(endpoints => + { + endpoints.MapControllers(); + }); + + DbHeper.Initilize(); + + } + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/WeatherForecast.cs" "b/\346\235\216\350\202\262\345\245\207/WeatherForecast.cs" new file mode 100644 index 0000000000000000000000000000000000000000..5871af2a184c32297d627c31779fab837fdfb2a9 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/WeatherForecast.cs" @@ -0,0 +1,15 @@ +using System; + +namespace WebApi +{ + public class WeatherForecast + { + public DateTime Date { get; set; } + + public int TemperatureC { get; set; } + + public int TemperatureF => 32 + (int)(TemperatureC / 0.5556); + + public string Summary { get; set; } + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/WebApi.csproj" "b/\346\235\216\350\202\262\345\245\207/WebApi.csproj" new file mode 100644 index 0000000000000000000000000000000000000000..da10d50a32b4ec10963d789edcdb8d045c0da572 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/WebApi.csproj" @@ -0,0 +1,14 @@ + + + + netcoreapp3.1 + + + + + + + + + + diff --git "a/\346\235\216\350\202\262\345\245\207/WebApi.sln" "b/\346\235\216\350\202\262\345\245\207/WebApi.sln" new file mode 100644 index 0000000000000000000000000000000000000000..3b0ba12f45c708db97ef60bac187301d9872af27 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/WebApi.sln" @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.30128.74 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WebApi", "WebApi.csproj", "{EAC343D2-626A-4524-8822-F500C82A910B}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {EAC343D2-626A-4524-8822-F500C82A910B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {EAC343D2-626A-4524-8822-F500C82A910B}.Debug|Any CPU.Build.0 = Debug|Any CPU + {EAC343D2-626A-4524-8822-F500C82A910B}.Release|Any CPU.ActiveCfg = Release|Any CPU + {EAC343D2-626A-4524-8822-F500C82A910B}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {9C8BD802-2825-494F-81B3-D22FA79C207E} + EndGlobalSection +EndGlobal diff --git "a/\346\235\216\350\202\262\345\245\207/appsettings.Development.json" "b/\346\235\216\350\202\262\345\245\207/appsettings.Development.json" new file mode 100644 index 0000000000000000000000000000000000000000..8983e0fc1c5e2795ccfde0c771c6d66c88ef4a42 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/appsettings.Development.json" @@ -0,0 +1,9 @@ +{ + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft": "Warning", + "Microsoft.Hosting.Lifetime": "Information" + } + } +} diff --git "a/\346\235\216\350\202\262\345\245\207/appsettings.json" "b/\346\235\216\350\202\262\345\245\207/appsettings.json" new file mode 100644 index 0000000000000000000000000000000000000000..d9d9a9bff6fd6f3ee7ea00de958f135a4a28c6e6 --- /dev/null +++ "b/\346\235\216\350\202\262\345\245\207/appsettings.json" @@ -0,0 +1,10 @@ +{ + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft": "Warning", + "Microsoft.Hosting.Lifetime": "Information" + } + }, + "AllowedHosts": "*" +}