# FMS Admin Backend ## 설치 .Net Core 설치 .appsettings.Development.json 파일생성 ``` .appsettings.Development.json.example 복사 ``` Trust the HTTPS ``` dotnet dev-certs https --trust ``` ## EF Tool 설치 ``` dotnet tool install --global dotnet-ef ``` ## 패키지 설치 (빌드시 자동설치됨) EF Core Package 추가 ``` dotnet add package Microsoft.EntityFrameworkCore.Design --version 3.1.0 dotnet add package Microsoft.EntityFrameworkCore.Sqlite --version 3.1.0 dotnet add package Microsoft.EntityFrameworkCore.SqlServer --version 3.1.0 dotnet add package Microsoft.EntityFrameworkCore.Proxies --version 3.1.0 ``` EPPlus (Excel 출력) ``` dotnet add package EPPlus --version 4.5.3.2 ``` Linq Dynamic (Core) ``` dotnet add package System.Linq.Dynamic.Core --version 1.0.19 ``` LinqKit (Core) ``` dotnet add package LinqKit.Microsoft.EntityFrameworkCore --version 3.0.0 ``` Versioning 패키지 ``` dotnet add package Microsoft.AspNetCore.Mvc.Versioning --version 4.1.0 ``` Quartz Job Scheduler ``` dotnet add package Quartz --version 3.0.7 ``` QR Code Generator (QrCode.Net) ``` dotnet add package QRCoder ``` SixLabors ImageSharp (이미지 프로세싱) ``` dotnet add package SixLabors.ImageSharp ``` Serilog (로거) ``` dotnet add package Serilog.AspNetCore --version 3.4.0 ``` ActiveReports Viewer (레포트 프로그램, 상용) ``` dotnet add package GrapeCity.ActiveReports.Aspnetcore.Viewer ``` Select Pdf (PDF 이미지 컨버터 모듈, 상용) ``` dotnet add package Select.Pdf.NetCore ``` ## test database 생성 ``` appsettings.Development.json 수정 "Server": "Sqlite" dotnet ef migrations add init dotnet ef database update ``` ## 환경설정 포트 설정 appsettings.Development.json ``` "Kestrel": { "EndPoints": { "Http": { "Url": "http://0.0.0.0:9090" } } } ``` ## 추가 도움툴 DB Browser for SQLite : QLite 클라이언트 - RestClient : API 테스트 클라이언트 - PostMan : API 테스트 클라이언트 - ## 참고자료 ASP.NET Core MVC Tutorial - Entity Framework Core - ASP.NET Core Web API - JWT 인증 - - C# 새로운 기능 (8.0 ~ 6) - ## 기타 SQL 제네레이터 (ef migrations) ``` ※ dotnet ef migrations add init 등 마이그레이션 작업후 dotnet ef migrations script | out-file ./script.sql ``` 서버 설치 - Core Runtime 설치 (dotnet-hosting-3.1.1-win.exe) - IIS URL Rewrite 모듈