This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class GlobalMiddleware | |
| { | |
| private readonly RequestDelegate _next; | |
| public GlobalMiddleware(RequestDelegate next ) | |
| { | |
| _next = next; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class GlobalMiddleware | |
| { | |
| private readonly RequestDelegate _next; | |
| private string _requestBody; | |
| public GlobalMiddleware(RequestDelegate next) | |
| { | |
| _next = next; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [HttpGet] | |
| [ProducesDefaultResponseType(typeof(ApiResponse<List<NotificationItem>>))] | |
| public async Task<IActionResult> Notifications(){} | |
| [HttpPost("{productId}")] | |
| [ProducesDefaultResponseType(typeof(ApiResponse))] | |
| public async Task<IActionResult> PostFeedback([FromRoute] long productId, [FromBody] ProductPostFeedback model){} | |
| [HttpPost] | |
| [ProducesDefaultResponseType(typeof(ApiResponse))] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class ApiResponse<T> | |
| { | |
| public ApiResponse() | |
| { | |
| Success = true; | |
| } | |
| public ApiResponse(string error) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| worker_processes auto; | |
| events { | |
| worker_connections 1024; | |
| } | |
| http { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #if NET8_0 | |
| // Code specific to .NET 8 | |
| #elif NET6_0 | |
| // Code specific to .NET 6 | |
| #else | |
| // Default code for other versions | |
| #endif | |
| <ItemGroup Condition="'$(TargetFramework)' == 'net8.0'"> | |
| ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| create user demo identified by 123456; | |
| grant connect to demo; | |
| grant connect to demo identified by 123456; | |
| grant all privileges to demo identified by 123456; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Visual Studio 2022 | |
| Enterprise : | |
| VHF9H-NXBBB-638P6-6JHCY-88JWH | |
| Professional: | |
| TD244-P4NB7-YQ6XK-Y8MMM-YWV2J |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System; | |
| using System.Collections.Generic; | |
| using System.Diagnostics; | |
| using System.Linq; | |
| using System.Runtime.InteropServices; | |
| using System.Text; | |
| using System.Threading; | |
| using System.Threading.Tasks; | |
| namespace TestCtrlEvent |