mirror of
https://github.com/grocy/grocy.git
synced 2026-04-05 12:26:15 +02:00
This commit's contents were auto-generated. They wrap all viewjs
in functions and define a common prologue.
New file contents:
```js
function VIEWNAMEView(Grocy, scope = null)
{
var $scope = $;
if(scope != null)
{
$scope = $(scope).find;
}
// original contents indented with \t
}
```
28 lines
697 B
JavaScript
28 lines
697 B
JavaScript
function userentitiesView(Grocy, scope = null)
|
|
{
|
|
var $scope = $;
|
|
if (scope != null)
|
|
{
|
|
$scope = $(scope).find;
|
|
}
|
|
|
|
var userentitiesTable = $('#userentities-table').DataTable({
|
|
'order': [[1, 'asc']],
|
|
'columnDefs': [
|
|
{ 'orderable': false, 'targets': 0 },
|
|
{ 'searchable': false, "targets": 0 }
|
|
].concat($.fn.dataTable.defaults.columnDefs)
|
|
});
|
|
$('#userentities-table tbody').removeClass("d-none");
|
|
Grocy.FrontendHelpers.InitDataTable(userentitiesTable);
|
|
|
|
Grocy.FrontendHelpers.MakeDeleteConfirmBox(
|
|
'Are you sure to delete userentity "%s"?',
|
|
'.userentity-delete-button',
|
|
'data-userentity-name',
|
|
'data-userentity-id',
|
|
'objects/userentities/',
|
|
'/userentities'
|
|
);
|
|
}
|