78 lines
2.8 KiB
Text
78 lines
2.8 KiB
Text
@using Kreta.Framework;
|
|
@using Kreta.Web.Helpers.Grid;
|
|
@using Kreta.Web.Areas.Intezmeny.Models;
|
|
@using Kreta.Web.Helpers;
|
|
@model IntezmenyModel
|
|
|
|
<div id="Intezmeny_Adatok_Partial">
|
|
@Html.Partial("Intezmeny_Adatok_Partial", Model)
|
|
</div>
|
|
|
|
<div>
|
|
<h3>@StringResourcesUtil.GetString(3247 /*Működési helyek*/)</h3>
|
|
</div>
|
|
|
|
<div>
|
|
@(Html.KretaGrid<IntezmenyMukodesiHelyGridModel>
|
|
(
|
|
name: "IntezmenyMukodesiHelyGrid",
|
|
getUrl: new GridApiUrl("IntezmenyApi", "GetIntezmenyMukodesiHelyGrid", new Dictionary<string, string> { }),
|
|
clientTemplate: "detailGrid-template",
|
|
allowScrolling: true,
|
|
clientTemplateUrl: @Url.Action("IntezmenyFeladatEllatasiHelyDetailGrid", "Intezmeny", new { area = "Intezmeny" })
|
|
)
|
|
.LinkButtonColumn(string.Empty, c => c.Nev, "IntezmenyHelper.onInfoMukodesiHely", Kreta.Enums.ManualEnums.GridButtonsEnum.Kivalasztas)
|
|
.Columns(columns =>
|
|
{
|
|
columns.Bound(c => c.Iranyitoszam).Width("10%");
|
|
columns.Bound(c => c.Varos);
|
|
columns.Bound(c => c.Telefon).Width("15%");
|
|
columns.Bound(c => c.Email);
|
|
})
|
|
.RowFunction(Html, new List<RowFunction> {
|
|
new RowFunction { NameResourceId = 118 /*Adatok*/, ClientAction = "IntezmenyHelper.onInfoMukodesiHely" }
|
|
})
|
|
.Sortable(sortable => sortable
|
|
.AllowUnsort(true)
|
|
.SortMode(GridSortMode.MultipleColumn))
|
|
)
|
|
</div>
|
|
|
|
@Html.KretaGridTemplate("detailGrid-template")
|
|
|
|
<script type="text/javascript">
|
|
var IntezmenyHelper = (function () {
|
|
var intezmenyHelper = function () { };
|
|
|
|
var _url = {
|
|
InfoMukodesiHelyPopUp: "@Url.Action("InfoMukodesiHelyPopUp", "Intezmeny", new { area = "Intezmeny" })",
|
|
}
|
|
|
|
var _window = {
|
|
InfoMukodesiHelyWindow: "infoMukodesiHelyWindow",
|
|
}
|
|
|
|
intezmenyHelper.onInfoMukodesiHely = function (data) {
|
|
var postData = { pID: parseInt(data.ID) };
|
|
AjaxHelper.DoPost(_url.InfoMukodesiHelyPopUp, postData, infoMukodesiHelyPopUp);
|
|
}
|
|
|
|
intezmenyHelper.infoMukodesiHelyPopUpCancel = function () {
|
|
KretaWindowHelper.destroyWindow(_window.InfoMukodesiHelyWindow);
|
|
}
|
|
|
|
function infoMukodesiHelyPopUp(data) {
|
|
var config = KretaWindowHelper.getWindowConfigContainer();
|
|
config.title = "@(StringResourcesUtil.GetString(3258))"; /*Működési hely adatai*/
|
|
config.content = data;
|
|
var modal = KretaWindowHelper.createWindow(_window.InfoMukodesiHelyWindow, config);
|
|
KretaWindowHelper.openWindow(modal, true);
|
|
}
|
|
|
|
return intezmenyHelper;
|
|
})();
|
|
|
|
$(document).ready(function () {
|
|
KretaGridHelper.openAllGrid();
|
|
});
|
|
</script>
|