init
This commit is contained in:
commit
e124a47765
19374 changed files with 9806149 additions and 0 deletions
|
@ -0,0 +1,79 @@
|
|||
@using Kreta.BusinessLogic.Classes
|
||||
@using Kreta.Enums.ManualEnums
|
||||
@using Kreta.Resources
|
||||
@using Kreta.Web.Areas.Feljegyzes.Controllers
|
||||
@using Kreta.Web.Areas.Feljegyzes.Models
|
||||
@using Kreta.Web.Helpers
|
||||
@using Kreta.Web.Helpers.Grid
|
||||
|
||||
@model KozossegiSzolgalatokGridModel
|
||||
|
||||
@{
|
||||
string tdStart = "<td class=\"rowFunction\" data-rowfunctionparent=\"KozossegiSzolgalatokReszletekGrid_" + Model.TanuloId + "\" style=\"min-width: 80px;\" role=\"gridcell\">";
|
||||
string rowFnModifyString = "<a title=\"Módosítás\" href=\"javascript:void(0)\" onclick=\"KretaGridHelper.rowFunctionCall($(this),'KozossegiSzolgalatokReszletekGrid_" + Model.TanuloId + "',KozossegiSzolgalatokHelper.openEditorPopup);\"><i style=\"font-size: 22px;\" class=\"fa fa-pencil\" aria-hidden=\"true\"></i></a>";
|
||||
string rowFnDeleteString = "<a title=\"Törlés\" href=\"javascript: void(0)\" onclick=\"KretaGridHelper.rowFunctionCall($(this), 'KozossegiSzolgalatokReszletekGrid_" + Model.TanuloId + "', KozossegiSzolgalatokHelper.deleteConfirmWindow); \" ><i style=\"font-size: 22px;\" class=\"fa fa-trash\" aria-hidden=\"true\"></i></a>";
|
||||
string designFixString = "<i style=\"padding-left:22px;\" aria-hidden=\"true\"></i>";
|
||||
string detailGridNamePrefix = KozossegiSzolgalatokController.DetailGridNamePrefix;
|
||||
}
|
||||
<script>
|
||||
|
||||
var DetailGridHelper = (function () {
|
||||
var detailGridHelper = function () { };
|
||||
|
||||
detailGridHelper.setAthuzas = function () {
|
||||
var gridName = "@detailGridNamePrefix" + "@Model.TanuloId";
|
||||
var dataSource = KretaGridHelper.getKendoGridData(gridName).dataSource.data();
|
||||
$.each(dataSource, function (index, value) {
|
||||
if (value.Torolt_BOOL) {
|
||||
$('#' + gridName).find('[data-uid= ' + value.uid + ']').addClass("kretaStrikedGridRow disabledItem");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
detailGridHelper.setRowEditing = function (rowData) {
|
||||
return !rowData.Torolt_BOOL && rowData.Modosithato_BOOL;
|
||||
}
|
||||
|
||||
return detailGridHelper;
|
||||
})();
|
||||
|
||||
</script>
|
||||
|
||||
<div id="partialDetailGrid_@Model.TanuloId">
|
||||
@(
|
||||
Html.KretaGrid<KozossegiSzolgalatokReszletekGridModel>(
|
||||
detailGridNamePrefix + Model.TanuloId,
|
||||
new GridApiUrl("KozossegiSzolgalatokApi", "GetKozossegiSzolgalatokReszletekGrid", new Dictionary<string, string> { { "tanuloId", Model.TanuloId } }),
|
||||
useToolBar: false,
|
||||
dataBoundAdditionalFunction: "DetailGridHelper.setAthuzas();",
|
||||
sort: sort => sort.Add(s => s.IntervallumKezdete).Descending(),
|
||||
allowPaging: false,
|
||||
allowScrolling:false,
|
||||
pageSizes: null
|
||||
)
|
||||
.Columns(columns =>
|
||||
{
|
||||
columns.Bound(c => c.ID).Hidden();
|
||||
columns.Bound(c => c.TanuloId).Hidden();
|
||||
columns.Bound(c => c.IntervallumKezdete).Format(SDAFormat.Format[SDAFormat.FormatType.ShortDate]).Width("10%");
|
||||
columns.Bound(c => c.IntervallumVege).Format(SDAFormat.Format[SDAFormat.FormatType.ShortDate]).Width("10%");
|
||||
columns.Bound(c => c.TeljesitesiHelye).Width("15%").SetDisplayPropertyWithToolip("TeljesitesiHelye");
|
||||
columns.Bound(c => c.Oraszam).Width("5%");
|
||||
columns.Bound(c => c.KozossegiSzolgalatTipusa_DNAME).Width("20%").SetDisplayPropertyWithToolip("KozossegiSzolgalatTipusa_DNAME");
|
||||
columns.Bound(c => c.Megjegyzes).Width("30%").SetDisplayPropertyWithToolip("Megjegyzes");
|
||||
columns.Bound(c => c.RogzitesDatuma).Format(SDAFormat.Format[SDAFormat.FormatType.ShortDate]).Width("10%");
|
||||
})
|
||||
.Columns(c => c.Template(t => t.ToString()).Title(" ").ClientTemplate(
|
||||
tdStart + @"
|
||||
#if(Modosithato_BOOL == true && Torolt_BOOL == false)
|
||||
{ #" +
|
||||
rowFnModifyString
|
||||
+ @" # } else { # " + designFixString + @"# } #" +
|
||||
|
||||
@"#if (Torolheto_BOOL == true && Torolt_BOOL == false) { #" +
|
||||
rowFnDeleteString
|
||||
+ @" # } #" + "</td >"
|
||||
|
||||
))
|
||||
)
|
||||
</div>
|
Loading…
Add table
Add a link
Reference in a new issue