File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
sample/EntityFrameworkCore.DataEncryption.Sample/Controllers Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -15,11 +15,16 @@ public AuthorController(SampleDbContext context)
1515 _context = context ;
1616 }
1717
18- [ HttpGet ( Name = "Filter " ) ]
19- public Task < IActionResult > FilterAsync ( [ FromQuery ] string phone )
18+ [ HttpGet ( "equal" , Name = "Equal " ) ]
19+ public Task < IActionResult > EqualAsync ( [ FromQuery ] string phone )
2020 {
2121 return Task . FromResult < IActionResult > ( Ok ( _context . Authors . Where ( a=> a . Phone == phone ) . ToList ( ) ) ) ;
2222 }
23+ [ HttpGet ( "contains" , Name = "Contains" ) ]
24+ public Task < IActionResult > ContainsAsync ( [ FromQuery ] string phone )
25+ {
26+ return Task . FromResult < IActionResult > ( Ok ( _context . Authors . Where ( a=> a . Phone . Contains ( phone ) ) . ToList ( ) ) ) ;
27+ }
2328
2429 [ HttpPost ( Name = "Insert" ) ]
2530 public async Task < IActionResult > InsertAsync ( [ FromBody ] Author author )
You can’t perform that action at this time.
0 commit comments