Can't make a new Entity in a Module. No Table in Database

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Irenicus
    Junior Member
    • Mar 2026
    • 1

    #1

    Can't make a new Entity in a Module. No Table in Database

    I use EspoCRM 9.3.3

    I tried to build a new Modul and i can not make a new Entity named: Seminar""
    It apears in the entity-manager, but ist no selectable. I can't see it in the Layout manager.
    There is no Database-Entry.
    I have given the rights to the Role of my User.
    I have rebuild and cleared cache.

    I have made the following paths:

    ../data/espocrm/custom/Espo/Modules/WB

    Module.php
    Code:
    <?php
    
    namespace Espo\Modules\WB;
    
    use Espo\Core\Module as BaseModule;
    
    class Module extends BaseModule
    {
        /**
         * Diese Funktion wird beim Laden des Moduls aufgerufen.
         * Hier können zusätzliche Initialisierungen erfolgen.
         */
        public function init()
        {
            // Optional: hier eigene Logik, Hooks oder Events hinzufügen
        }
    }
    
    ?>
    ../data/espocrm/custom/Espo/Modules/WB/Resources/metadata/entityDefs/Seminar.json
    Code:
    ​{
      "type": "Base",
      "fields": {
        "name": {
          "type": "varchar",
          "required": true
         },
        "thema": {
          "type": "varchar",
          "required": true
        },
        "beschreibung": {
          "type": "text"
        },
        "startDatum": {
          "type": "datetime",
          "required": true
        },
          "endDatum": {
          "type": "datetime"
        },
        "dozent": {
          "type": "varchar"
        }
      },
      "collection": {
        "orderBy": "startDatum",
        "order": "asc"
      }
    }
    .../data/espocrm/custom/Espo/Modules/WB/Resources/metadata/clientDefs/Seminar.json
    Code:
    {
      "controller": "controllers/record"
    }
    /data/espocrm/custom/Espo/Modules/WB/Resources/metadata/layouts/Seminar.json
    Code:
    {
      "panels": [
        {
          "name": "main",
          "label": "LBL_PANEL_DEFAULT",
          "fields": [
            "name",
            "thema",
            "beschreibung",
            "startDatum",
            "endDatum",
            "dozent"
          ]
        }
      ]
    }​
    .../data/espocrm/custom/Espo/Modules/WB/Resources/metadata/layouts/SeminarList.json
    Code:
    {
      "panels": [
        {
          "name": "main",
          "label": "LBL_PANEL_DEFAULT",
          "fields": [
            "name",
            "thema",
            "startDatum",
            "endDatum",
            "dozent"
          ]
        }
      ]
    }​​
    .../data/espocrm/custom/Espo/Modules/WB/Resources/metadata/scopes/Seminar.json
    Code:
    {
      "entity": true,
      "object": true,
      "module": "WB",
      "type": "Base",
      "stream": true,
      "tab": true,
      "acl": true
    }
    .../data/espocrm/custom/Espo/Modules/WB/Resources/i18n/de_D​E/
    Code:
    {
      "labels": {
        "plural": "Seminare",
        "singular": "Seminar"
      },
      "fields": {
        "name": "Titel",
        "thema": "Thema",
        "beschreibung": "Beschreibung",
        "startDatum": "Startdatum",
        "endDatum": "Enddatum",
        "dozent": "Dozent"
      }
    }
Working...