using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using WebApiExplorer.Models;
namespace WebApiExplorer.Controllers
{
public partial class Wijmo5FlexGridController : Controller
{
private readonly GridExportImportOptions _flexGridPagingModel = new GridExportImportOptions
{
NeedExport = true,
NeedImport = false,
IncludeColumnHeaders = true,
OnlyCurrentPage = false
};
public ActionResult Paging()
{
ViewBag.Options = _flexGridPagingModel;
return View();
}
}
}
@using WebApiExplorer.Models
@{
GridExportImportOptions optionsModel = ViewBag.Options;
ViewBag.DemoSettings = true;
}
<div id="@(optionsModel.ControlId)" style="height:300px"></div>
@section Settings{
@Html.Partial("_FlexGridOptions", optionsModel)
}
<script>
var grid = new wijmo.grid.FlexGrid('#@(optionsModel.ControlId)');
initializeFlexGrid(grid);
grid.collectionView.pageSize = 10;
</script>
@(Html.C1().Pager().Owner(optionsModel.ControlId))
@section Description{
@Html.Raw(Resources.Wijmo5FlexGrid.Paging_Text0)
}