improved warehouse module

This commit is contained in:
Luca Haid
2025-08-04 15:28:12 +02:00
parent 3979f907b0
commit 1ac95214b2
15 changed files with 117 additions and 26 deletions

View File

@@ -1,23 +1,11 @@
<?php
class WarehouseCategory extends TTCrudBaseModel {
public int $id;
public string $name;
public string $description;
public ?int $articleNumberPrefix;
public int $create;
public int $create_by;
public ?int $edit;
public ?int $edit_by;
}
// SQL:
// CREATE TABLE `WarehouseCategory` (
// `id` INT NOT NULL AUTO_INCREMENT,
// `name` VARCHAR(255) NOT NULL,
// `description` TEXT NOT NULL,
// `create` INT NOT NULL,
// `create_by` INT NOT NULL,
// `edit` INT DEFAULT NULL,
// `edit_by` INT DEFAULT NULL,
// PRIMARY KEY (`id`)
// ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
}

View File

@@ -9,10 +9,9 @@ class WarehouseCategoryController extends TTCrud {
protected array $columns = [
['key' => 'name', 'text' => 'Name', 'required' => true,],
['key' => 'description', 'text' => 'Beschreibung', 'required' => true],
['key' => 'articleNumberPrefix', 'text' => 'Artikelnummerprefix', 'required' => true],
['key' => 'create', 'text' => 'Erstellt am', 'required' => false, 'modal' => false, 'table' => ['filter' => false, 'sortable' => false, 'class' => 'text-center']],
['key' => 'create_by', 'text' => 'Erstellt von', 'required' => false, 'modal' => false, 'table' => ['filter' => false, 'sortable' => false, 'class' => 'text-center']],
['key' => 'edit', 'text' => 'Bearbeitet am', 'required' => false, 'modal' => false, 'table' => ['filter' => false, 'sortable' => false, 'class' => 'text-center']],
['key' => 'edit_by', 'text' => 'Bearbeitet von', 'required' => false, 'modal' => false, 'table' => ['filter' => false, 'sortable' => false, 'class' => 'text-center']],
['key' => 'actions', 'text' => 'Aktionen', 'required' => false, 'modal' => false, 'table' => ['filter' => false, 'sortable' => false, 'class' => 'text-center', 'priority' => 10]],
];
// @formatter:on