เพิ่มบิ้วไฟล์excel
This commit is contained in:
parent
4b7715cc8a
commit
bd695abf24
8 changed files with 3127 additions and 332 deletions
|
|
@ -1,29 +1,31 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using BMA.EHR.Recurit.Exam.Service.Data;
|
||||
using BMA.EHR.Recurit.Exam.Service.Models.Disables;
|
||||
using System.Data;
|
||||
|
||||
namespace BMA.EHR.Recurit.Exam.Service.Services
|
||||
{
|
||||
public class DisableService
|
||||
{
|
||||
private readonly ApplicationDbContext _context;
|
||||
private readonly IConfiguration _configuration;
|
||||
private readonly IWebHostEnvironment _webHostEnvironment;
|
||||
|
||||
public DisableService(ApplicationDbContext context)
|
||||
public DisableService(ApplicationDbContext context,
|
||||
IConfiguration configuration,
|
||||
IWebHostEnvironment webHostEnvironment)
|
||||
{
|
||||
_context = context;
|
||||
_configuration = configuration;
|
||||
_webHostEnvironment = webHostEnvironment;
|
||||
}
|
||||
|
||||
public int GetExamCount(string citizenId)
|
||||
{
|
||||
try
|
||||
{
|
||||
var count = _context.Disables.AsQueryable()
|
||||
.Where(x => x.CitizenId == citizenId)
|
||||
.Count();
|
||||
var count = _context.Candidates.AsQueryable()
|
||||
.Where(x => x.CitizenId == citizenId)
|
||||
.Count();
|
||||
|
||||
return count;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue