40 lines
1.2 KiB
C#
40 lines
1.2 KiB
C#
using Microsoft.AspNetCore.Mvc;
|
|
using UniversityContracts.BindingModels;
|
|
using UniversityContracts.BusinessLogicContracts;
|
|
using UniversityContracts.ViewModels;
|
|
|
|
namespace UniversityRestAPI.Controllers
|
|
{
|
|
[Route("api/[controller]/[action]")]
|
|
[ApiController]
|
|
public class ReportProviderController : Controller
|
|
{
|
|
private readonly IReportProviderLogic reportLogic;
|
|
|
|
public ReportProviderController(IReportProviderLogic reportLogic)
|
|
{
|
|
this.reportLogic = reportLogic;
|
|
}
|
|
|
|
[HttpPost]
|
|
public byte[] StudentDisciplineList(StudentDisciplineListBindingModel listModel)
|
|
{
|
|
byte[] file = reportLogic.SaveListFile(listModel);
|
|
return file;
|
|
}
|
|
|
|
[HttpPost]
|
|
public List<ReportStreamStudentEdStatPeriodViewModel> GetReportData(ReportBindingModel reportModel)
|
|
{
|
|
var list = reportLogic.GetStreamStudentEdStatPeriod(reportModel);
|
|
return list;
|
|
}
|
|
|
|
[HttpPost]
|
|
public void SendByMailStatusReport(ReportBindingModel reportModel)
|
|
{
|
|
reportLogic.SendByMailStatusReport(reportModel);
|
|
}
|
|
}
|
|
}
|