Skip to content

Commit e54b57f

Browse files
committed
Make global js variable name public
1 parent ca95f58 commit e54b57f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Mvc.JQuery.Datatables.Templates/Views/Shared/DataTable.cshtml

+1-1
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@
9292
9393
@if (Model.GlobalJsVariableName != null)
9494
{
95-
@Html.Raw("window['@Model.GlobalJsVariableName'] = dt;")
95+
@Html.Raw("window['" + Model.GlobalJsVariableName + "'] = dt;")
9696
}
9797
})();
9898
</script>

Mvc.JQuery.Datatables/DataTableConfigVm.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ public string ColumnSortingString
105105
public string DrawCallback { get; set; }
106106
public LengthMenuVm LengthMenu { get; set; }
107107
public int? PageLength { get; set; }
108-
public string GlobalJsVariableName { get; private set; }
108+
public string GlobalJsVariableName { get; set; }
109109

110110
private bool _columnFilter;
111111

0 commit comments

Comments
 (0)