diff --git a/Layout/default/Device/Form.php b/Layout/default/Device/Form.php index e34c7bf3d..8d63108cb 100644 --- a/Layout/default/Device/Form.php +++ b/Layout/default/Device/Form.php @@ -1,4 +1,6 @@ + + id] = $devicetype->devicemanufactor->name . " " . $devicetype->name; diff --git a/Layout/default/Devicemanufactor/Form.php b/Layout/default/Devicemanufactor/Form.php index 796309910..e06d6f61b 100644 --- a/Layout/default/Devicemanufactor/Form.php +++ b/Layout/default/Devicemanufactor/Form.php @@ -1,4 +1,6 @@ + +
diff --git a/Layout/default/Devicemanufactor/Index.php b/Layout/default/Devicemanufactor/Index.php index a8fe21d29..c0687a36f 100644 --- a/Layout/default/Devicemanufactor/Index.php +++ b/Layout/default/Devicemanufactor/Index.php @@ -57,8 +57,8 @@ $pagination_entity_name = "Devicemanufactor"; - name ?> - creator->name ?> + name ?> + creator->name ?> (create) ?>) diff --git a/Layout/default/Devicetype/Form.php b/Layout/default/Devicetype/Form.php index cfa545f18..f972b291a 100644 --- a/Layout/default/Devicetype/Form.php +++ b/Layout/default/Devicetype/Form.php @@ -1,5 +1,6 @@ +
diff --git a/Layout/default/Devicetype/Index.php b/Layout/default/Devicetype/Index.php index 8e0be3aa5..88f7861bb 100644 --- a/Layout/default/Devicetype/Index.php +++ b/Layout/default/Devicetype/Index.php @@ -63,7 +63,7 @@ $pagination_entity_name = "Devicetype"; - name ?> + name ?> devicemanufactor->name ?> price ?> € diff --git a/Layout/default/Pop/Index.php b/Layout/default/Pop/Index.php index 50628acd3..2014a1c18 100644 --- a/Layout/default/Pop/Index.php +++ b/Layout/default/Pop/Index.php @@ -25,7 +25,7 @@ $pagination_entity_name = "Pops";
-
+
diff --git a/Layout/default/User/Index.php b/Layout/default/User/Index.php index cfbb1b3d1..90329031b 100644 --- a/Layout/default/User/Index.php +++ b/Layout/default/User/Index.php @@ -59,10 +59,10 @@ $pagination_entity_name = "Benutzer"; $filter['address_id']]) ?>"> Neuen Benutzer anlegen + class="fas fa-plus"> Neuen Benutzer anlegen "> Neuen Benutzer anlegen + class="fas fa-plus"> Neuen Benutzer anlegen
diff --git a/application/Pop/Pop.php b/application/Pop/Pop.php index 446777a7f..e57334483 100644 --- a/application/Pop/Pop.php +++ b/application/Pop/Pop.php @@ -5,18 +5,49 @@ class Pop extends mfBaseModel { private $network; public function getProperty($name) { - if($this->$name == null) { + if ($this->$name == null) { + + if (!$this->id) { + return null; + } + + if($name == "creator") { + $this->creator = mfValuecache::singleton()->get("Worker-id-".$this->create_by); + if($this->creator === null) { + $this->creator = new User($this->create_by); + if($this->creator->id) { + mfValuecache::singleton()->set("Worker-id-".$this->create_by, $this->creator); + } + } + return $this->creator; + } + + if($name == "editor") { + $this->editor = mfValuecache::singleton()->get("Worker-id-".$this->edit_by); + if($this->editor === null) { + $this->editor = new User($this->edit_by); + if($this->editor->id) { + mfValuecache::singleton()->set("Worker-id-".$this->edit_by, $this->editor); + } + } + return $this->editor; + } + + $classname = ucfirst($name); + $idfield = $name."_id"; + $this->$name = mfValuecache::singleton()->get("mfObjectmodel-$name-".$this->$idfield); + if(!$this->$name) { + $this->$name = new $classname($this->$idfield); + } + + if($this->$name->id) { + mfValuecache::singleton()->set("mfObjectmodel-$name-".$this->$name->id, $this->$name); + return $this->$name; + } else { + return null; + } - $classname = ucfirst($name); - $idfield = $name."_id"; - $this->$name = new $classname($this->$idfield); - - if($this->$name->id) { - return $this->$name; - } else { - return null; } - } return $this->$name; } diff --git a/public/assets/css/datatables-std.css b/public/assets/css/datatables-std.css index 2eaac518a..f1855707d 100644 --- a/public/assets/css/datatables-std.css +++ b/public/assets/css/datatables-std.css @@ -141,6 +141,7 @@ table.dataTable.table-sm > thead > tr > th:not(.sorting_disabled) { } .card-body { + padding-top: 5px; padding-left: 5px; padding-right: 5px; } @@ -165,6 +166,33 @@ table.dataTable.table-sm > thead > tr > th:not(.sorting_disabled) { #datatable { width: 100% !important; } + + li.paginate_button.previous, li.paginate_button.next { + display: inline-block; + font-size: 1.0rem; + } + + .dataTables_length .form-select { + margin-right: 0px; + padding: 4px 7px; + font-size: .875rem; + } + + div.dataTables_wrapper div.dataTables_filter input { + margin-left: 0.5em; + display: inline-block; + /* width: auto; */ + width: 150px; + } + + .dataTables_length { + margin-top: 4px; + } + + .header-title { + font-size: 14px; + margin: 12px 3px 7px 0px; + } } table.dataTable > tbody > tr.child span.dtr-data { @@ -194,3 +222,20 @@ table.dataTable.dtr-inline.collapsed > tbody > tr.parent > td:first-child:before top: 0.85rem; } + +.dataTables_length .form-select { + margin-right: 10px; + padding: 4px 7px; + font-size: .875rem; + font-weight: 400; + line-height: 1.5; + color: #6c757d; + background-color: #fff; + background-clip: padding-box; + border: 1px solid #ced4da; + border-radius: 0.2rem; + -webkit-transition: border-color .15s ease-in-out, -webkit-box-shadow .15s ease-in-out; + transition: border-color .15s ease-in-out, -webkit-box-shadow .15s ease-in-out; + transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out; + transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out, -webkit-box-shadow .15s ease-in-out; +} diff --git a/public/assets/js/datatables-std.js b/public/assets/js/datatables-std.js index 3131e2411..940e96466 100644 --- a/public/assets/js/datatables-std.js +++ b/public/assets/js/datatables-std.js @@ -38,18 +38,21 @@ $('#filterrow th').each(function (i) { }); table = $('#datatable').DataTable({ + responsive: true, buttons: [ { extend: 'excelHtml5', text: 'XLSX Export', - className: 'btn-success margina' - + className: 'btn-success margina d-none d-lg-block', + exportOptions: { + columns: ['th:not(:last-child)'] + } } ], columnDefs: [ columndefs ], "language": { - "url": "/datatables/json/german.json" + "url": "/datatables/json/german.json?v1" }, orderCellsTop: true, stateSave: true,