28 lines
1.1 KiB
C#
28 lines
1.1 KiB
C#
using System.Web.Http;
|
|
using System.Web.Http.ModelBinding;
|
|
using Kendo.Mvc.UI;
|
|
using Kreta.BusinessLogic.Helpers;
|
|
using Kreta.BusinessLogic.Security;
|
|
using Kreta.Web.Areas.Hianyzas.Models;
|
|
using Kreta.Web.Helpers;
|
|
using Kreta.Web.Helpers.Grid;
|
|
using Kreta.Web.Security;
|
|
using Newtonsoft.Json;
|
|
|
|
namespace Kreta.Web.Areas.Hianyzas.ApiControllers
|
|
{
|
|
[ApiRoleClaimsAuthorize(true)]
|
|
[ApiRolePackageAuthorize(KretaClaimPackages.Ellenorzo.ClaimValue)]
|
|
public class InformaciokIgazolasokApiController : ApiController
|
|
{
|
|
public DataSourceResult GetIgazolasGrid(string data, [ModelBinder(typeof(ModelBinder.DataSourceRequestModelBinder))] DataSourceRequest request)
|
|
{
|
|
var model = JsonConvert.DeserializeObject<InformaciokIgazolasSearchModel>(data);
|
|
var helper = new IgazolasHelper(ConnectionTypeExtensions.GetActiveSessionConnectionType());
|
|
helper.GridParameters = Converter.GridParameter(request);
|
|
var ds = helper.GetInformaciokIgazolasGrid(model.ConvertToCo());
|
|
|
|
return ds.ToDataSourceResult();
|
|
}
|
|
}
|
|
}
|